@umbraco-ui/uui-toggle 1.6.0-rc.0 → 1.6.0-rc.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/lib/index.js +16 -16
  2. package/package.json +4 -4
package/lib/index.js CHANGED
@@ -1,7 +1,7 @@
1
1
  import { UUIHorizontalShakeKeyframes, UUIHorizontalShakeAnimationValue } from '@umbraco-ui/uui-base/lib/animations';
2
2
  import { defineElement } from '@umbraco-ui/uui-base/lib/registration';
3
3
  import { UUIBooleanInputElement } from '@umbraco-ui/uui-boolean-input/lib';
4
- import { iconCheck, iconWrong } from '@umbraco-ui/uui-icon-registry-essential/lib/svgs';
4
+ import { iconCheck, iconRemove } from '@umbraco-ui/uui-icon-registry-essential/lib/svgs';
5
5
  import { css, html } from 'lit';
6
6
 
7
7
  var __defProp = Object.defineProperty;
@@ -22,8 +22,8 @@ let UUIToggleElement = class extends UUIBooleanInputElement {
22
22
  renderCheckbox() {
23
23
  return html`
24
24
  <div id="slider">
25
- <div id="icon-check">${iconCheck}</div>
26
- <div id="icon-wrong">${iconWrong}</div>
25
+ <div id="icon-checked">${iconCheck}</div>
26
+ <div id="icon-unchecked">${iconRemove}</div>
27
27
  </div>
28
28
  `;
29
29
  }
@@ -90,29 +90,29 @@ UUIToggleElement.styles = [
90
90
  background-color: var(--uui-color-selected-emphasis,rgb(70, 86, 200));
91
91
  }
92
92
 
93
- #icon-check,
94
- #icon-wrong {
93
+ #icon-checked,
94
+ #icon-unchecked {
95
95
  position: absolute;
96
96
  vertical-align: middle;
97
97
  width: 1em;
98
98
  height: 1em;
99
99
  line-height: 0;
100
- transition: fill 120ms;
100
+ transition: color 120ms;
101
101
  }
102
102
 
103
- #icon-check {
103
+ #icon-checked {
104
104
  margin-left: -0.5em;
105
105
  left: calc(var(--uui-toggle-size) * 0.5);
106
- fill: var(--uui-color-interactive,#1b264f);
106
+ color: var(--uui-color-interactive,#1b264f);
107
107
  }
108
108
 
109
- #icon-wrong {
109
+ #icon-unchecked {
110
110
  margin-right: -0.5em;
111
111
  right: calc(var(--uui-toggle-size) * 0.5);
112
- fill: var(--uui-color-interactive,#1b264f);
112
+ color: var(--uui-color-interactive,#1b264f);
113
113
  }
114
- input:checked ~ #slider #icon-check {
115
- fill: var(--uui-color-selected-contrast,#fff);
114
+ input:checked ~ #slider #icon-checked {
115
+ color: var(--uui-color-selected-contrast,#fff);
116
116
  }
117
117
 
118
118
  #slider::after {
@@ -152,14 +152,14 @@ UUIToggleElement.styles = [
152
152
  :host([disabled]) #slider::after {
153
153
  background-color: var(--uui-color-disabled,#f3f3f5);
154
154
  }
155
- :host([disabled]) #slider #icon-wrong {
156
- fill: var(--uui-color-disabled-contrast,#c4c4c4);
155
+ :host([disabled]) #slider #icon-unchecked {
156
+ color: var(--uui-color-disabled-contrast,#c4c4c4);
157
157
  }
158
158
  :host([disabled]) label:active #slider {
159
159
  animation: ${UUIHorizontalShakeAnimationValue};
160
160
  }
161
- :host([disabled]) input:checked #slider #icon-check {
162
- fill: var(--uui-color-disabled-contrast,#c4c4c4);
161
+ :host([disabled]) input:checked #slider #icon-checked {
162
+ color: var(--uui-color-disabled-contrast,#c4c4c4);
163
163
  }
164
164
 
165
165
  :host(:not([pristine]):invalid) #slider,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@umbraco-ui/uui-toggle",
3
- "version": "1.6.0-rc.0",
3
+ "version": "1.6.0-rc.2",
4
4
  "license": "MIT",
5
5
  "keywords": [
6
6
  "Umbraco",
@@ -30,8 +30,8 @@
30
30
  "custom-elements.json"
31
31
  ],
32
32
  "dependencies": {
33
- "@umbraco-ui/uui-base": "1.6.0-rc.0",
34
- "@umbraco-ui/uui-boolean-input": "1.6.0-rc.0"
33
+ "@umbraco-ui/uui-base": "1.6.0-rc.2",
34
+ "@umbraco-ui/uui-boolean-input": "1.6.0-rc.2"
35
35
  },
36
36
  "scripts": {
37
37
  "build": "npm run analyze && tsc --build --force && rollup -c rollup.config.js",
@@ -42,5 +42,5 @@
42
42
  "access": "public"
43
43
  },
44
44
  "homepage": "https://uui.umbraco.com/?path=/story/uui-toggle",
45
- "gitHead": "04709c32cb81b058bdf7976b69533e5b793c49ab"
45
+ "gitHead": "5d4eefce4744802ab5bc40055b1a3136f0afc520"
46
46
  }