@rogieking/figui3 1.0.9 → 1.0.11
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/fig.css +5 -8
- package/fig.js +2 -0
- package/package.json +1 -1
package/fig.css
CHANGED
|
@@ -637,20 +637,12 @@ input[type=button] {
|
|
|
637
637
|
background-color: var(--figma-color-bg-selected);
|
|
638
638
|
}
|
|
639
639
|
|
|
640
|
-
&[selected=true] {
|
|
641
|
-
background-color: var(--figma-color-bg-selected);
|
|
642
|
-
}
|
|
643
|
-
|
|
644
640
|
&:focus {
|
|
645
641
|
outline: 0;
|
|
646
642
|
background-color: transparent;
|
|
647
643
|
box-shadow: inset 0 0 0 1px var(--figma-color-border-selected);
|
|
648
644
|
}
|
|
649
|
-
}
|
|
650
645
|
|
|
651
|
-
&[variant="ghost"][icon][selected=true],
|
|
652
|
-
&[variant="ghost"][icon][selected=true]>button {
|
|
653
|
-
color: var(--figma-color-icon-brand);
|
|
654
646
|
}
|
|
655
647
|
|
|
656
648
|
&[variant="ghost"][disabled=true],
|
|
@@ -734,6 +726,11 @@ input[type=button] {
|
|
|
734
726
|
&[inline=false] {
|
|
735
727
|
padding: 0;
|
|
736
728
|
}
|
|
729
|
+
|
|
730
|
+
&[selected]:not([selected=false]) {
|
|
731
|
+
color: var(--figma-color-icon-brand);
|
|
732
|
+
background-color: var(--figma-color-bg-selected);
|
|
733
|
+
}
|
|
737
734
|
}
|
|
738
735
|
|
|
739
736
|
fig-button>button {
|
package/fig.js
CHANGED
|
@@ -910,6 +910,7 @@ class FigCheckbox extends HTMLElement {
|
|
|
910
910
|
super()
|
|
911
911
|
this.input = document.createElement("input")
|
|
912
912
|
this.input.setAttribute("id", uniqueId())
|
|
913
|
+
this.input.setAttribute("name", this.getAttribute("name") || "checkbox")
|
|
913
914
|
this.input.setAttribute("type", "checkbox")
|
|
914
915
|
this.labelElement = document.createElement("label")
|
|
915
916
|
this.labelElement.setAttribute("for", this.input.id)
|
|
@@ -977,6 +978,7 @@ class FigRadio extends FigCheckbox {
|
|
|
977
978
|
constructor() {
|
|
978
979
|
super()
|
|
979
980
|
this.input.setAttribute("type", "radio")
|
|
981
|
+
this.input.setAttribute("name", this.getAttribute("name") || "radio")
|
|
980
982
|
}
|
|
981
983
|
}
|
|
982
984
|
window.customElements.define('fig-radio', FigRadio);
|
package/package.json
CHANGED