@umbraco-ui/uui-color-swatch 1.6.0-rc.4 → 1.7.0-rc.0
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.
- package/lib/index.js +8 -6
- package/package.json +5 -5
package/lib/index.js
CHANGED
|
@@ -26,8 +26,7 @@ let UUIColorSwatchElement = class extends LabelMixin(
|
|
|
26
26
|
this.addEventListener("click", this._setAriaAttributes);
|
|
27
27
|
}
|
|
28
28
|
get value() {
|
|
29
|
-
|
|
30
|
-
return (_a = this._value) != null ? _a : "";
|
|
29
|
+
return this._value ?? "";
|
|
31
30
|
}
|
|
32
31
|
set value(newValue) {
|
|
33
32
|
const oldValue = this._value;
|
|
@@ -61,7 +60,6 @@ let UUIColorSwatchElement = class extends LabelMixin(
|
|
|
61
60
|
}
|
|
62
61
|
}
|
|
63
62
|
render() {
|
|
64
|
-
var _a, _b;
|
|
65
63
|
return html`
|
|
66
64
|
<button
|
|
67
65
|
id="swatch"
|
|
@@ -71,10 +69,10 @@ let UUIColorSwatchElement = class extends LabelMixin(
|
|
|
71
69
|
<div class="color-swatch color-swatch--transparent-bg">
|
|
72
70
|
<div
|
|
73
71
|
class="color-swatch__color"
|
|
74
|
-
style="background-color: var(--uui-swatch-color, ${
|
|
72
|
+
style="background-color: var(--uui-swatch-color, ${this.color ?? this.value})"></div>
|
|
75
73
|
<div
|
|
76
74
|
class="color-swatch__check"
|
|
77
|
-
style="color: var(--uui-swatch-color, ${
|
|
75
|
+
style="color: var(--uui-swatch-color, ${this.color ?? this.value})">
|
|
78
76
|
${iconCheck}
|
|
79
77
|
</div>
|
|
80
78
|
</div>
|
|
@@ -197,7 +195,11 @@ UUIColorSwatchElement.styles = [
|
|
|
197
195
|
linear-gradient(45deg, transparent 75%, var(--uui-palette-grey,#c4c4c4) 75%),
|
|
198
196
|
linear-gradient(45deg, var(--uui-palette-grey,#c4c4c4) 25%, transparent 25%);
|
|
199
197
|
background-size: 10px 10px;
|
|
200
|
-
background-position:
|
|
198
|
+
background-position:
|
|
199
|
+
0 0,
|
|
200
|
+
0 0,
|
|
201
|
+
-5px -5px,
|
|
202
|
+
5px 5px;
|
|
201
203
|
}
|
|
202
204
|
.color-swatch__color {
|
|
203
205
|
width: 100%;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@umbraco-ui/uui-color-swatch",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.7.0-rc.0",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"Umbraco",
|
|
@@ -30,12 +30,12 @@
|
|
|
30
30
|
"custom-elements.json"
|
|
31
31
|
],
|
|
32
32
|
"dependencies": {
|
|
33
|
-
"@umbraco-ui/uui-base": "1.
|
|
34
|
-
"@umbraco-ui/uui-icon-registry-essential": "1.
|
|
33
|
+
"@umbraco-ui/uui-base": "1.7.0-rc.0",
|
|
34
|
+
"@umbraco-ui/uui-icon-registry-essential": "1.7.0-rc.0",
|
|
35
35
|
"colord": "^2.9.3"
|
|
36
36
|
},
|
|
37
37
|
"scripts": {
|
|
38
|
-
"build": "npm run analyze && tsc --build
|
|
38
|
+
"build": "npm run analyze && tsc --build && rollup -c rollup.config.js",
|
|
39
39
|
"clean": "tsc --build --clean && rimraf -g dist lib/*.js lib/**/*.js *.tgz lib/**/*.d.ts custom-elements.json",
|
|
40
40
|
"analyze": "web-component-analyzer **/*.element.ts --outFile custom-elements.json"
|
|
41
41
|
},
|
|
@@ -43,5 +43,5 @@
|
|
|
43
43
|
"access": "public"
|
|
44
44
|
},
|
|
45
45
|
"homepage": "https://uui.umbraco.com/?path=/story/uui-color-swatch",
|
|
46
|
-
"gitHead": "
|
|
46
|
+
"gitHead": "a7166e62b37b609e74b96821d397c694a5f42458"
|
|
47
47
|
}
|