Skip to content

Commit

Permalink
fix number guardian
Browse files Browse the repository at this point in the history
  • Loading branch information
olton committed Sep 24, 2024
1 parent 753fb3f commit 94adb45
Show file tree
Hide file tree
Showing 8 changed files with 21 additions and 8 deletions.
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,9 @@
# Changelog

### 5.0.11
+ [x] Fix G.number()
+ [x] Bugs fixes

### 5.0.7
+ [x] Update components for themes
+ [x] Update Hooks
Expand Down
4 changes: 2 additions & 2 deletions lib/metro.css
Original file line number Diff line number Diff line change
Expand Up @@ -48927,7 +48927,7 @@ textarea {
flex-shrink: 0;
}
.theme-switcher .check::before {
content: "☾";
content: attr(data-dark-symbol);
display: block;
position: absolute;
color: inherit;
Expand Down Expand Up @@ -48980,7 +48980,7 @@ textarea {
transform: translateX(30px) translateY(-50%);
}
.theme-switcher input[type="checkbox"]:checked ~ .check::before {
content: "☼";
content: attr(data-light-symbol);
color: #ffffff;
left: 1px;
}
Expand Down
2 changes: 1 addition & 1 deletion lib/metro.css.map

Large diffs are not rendered by default.

6 changes: 5 additions & 1 deletion lib/metro.js
Original file line number Diff line number Diff line change
Expand Up @@ -11927,7 +11927,7 @@
var Metro = {

version: "5.0.11",
build_time: "22.09.2024, 21:41:51",
build_time: "24.09.2024, 13:01:41",
buildNumber: 0,
isTouchable: isTouch,
fullScreenEnabled: document.fullscreenEnabled,
Expand Down Expand Up @@ -40233,6 +40233,8 @@
saveState: true,
saveStateKey: "THEME:SWITCHER",
clsDark: "",
darkSymbol: "☾",
lightSymbol: "☼",
onThemeSwitcherCreate: Metro.noop
};

Expand Down Expand Up @@ -40271,6 +40273,8 @@
}

const check = $("<span>").addClass("check");
check.attr("data-light-symbol", o.lightSymbol);
check.attr("data-dark-symbol", o.darkSymbol);

element.attr("type", "checkbox");

Expand Down
2 changes: 1 addition & 1 deletion lib/metro.js.map

Large diffs are not rendered by default.

4 changes: 4 additions & 0 deletions source/components/theme-switcher/theme-switcher.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
saveState: true,
saveStateKey: "THEME:SWITCHER",
clsDark: "",
darkSymbol: "☾",
lightSymbol: "☼",
onThemeSwitcherCreate: Metro.noop
};

Expand Down Expand Up @@ -50,6 +52,8 @@
}

const check = $("<span>").addClass("check");
check.attr("data-light-symbol", o.lightSymbol);
check.attr("data-dark-symbol", o.darkSymbol);

element.attr("type", "checkbox")

Expand Down
4 changes: 2 additions & 2 deletions source/components/theme-switcher/theme-switcher.less
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@

.check {
&::before {
content: ""; // dark
content: attr(data-dark-symbol); // dark
display: block;
position: absolute;
color: inherit;
Expand Down Expand Up @@ -90,7 +90,7 @@
.translateY(-50%);
}
&::before {
content: ""; // light
content: attr(data-light-symbol); // light
color: @white;
left: 1px;
}
Expand Down
2 changes: 1 addition & 1 deletion source/core/metro.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
var Metro = {

version: "5.0.11",
build_time: "22.09.2024, 21:41:51",
build_time: "24.09.2024, 13:01:41",
buildNumber: 0,
isTouchable: isTouch,
fullScreenEnabled: document.fullscreenEnabled,
Expand Down

0 comments on commit 94adb45

Please sign in to comment.