@rogieking/figui3 8.9.10 → 8.9.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-editor.css CHANGED
@@ -692,6 +692,15 @@ fig-select {
692
692
  }
693
693
  }
694
694
 
695
+ &[variant="ghost"] {
696
+ box-shadow: none;
697
+ background-color: transparent;
698
+
699
+ &:hover:not([disabled]):not([disabled="false"]) {
700
+ background-color: var(--figma-color-bg-secondary);
701
+ }
702
+ }
703
+
695
704
  &::after {
696
705
  content: "";
697
706
  position: absolute;
package/fig-editor.js CHANGED
@@ -454,6 +454,10 @@ class FigSelectOptions extends HTMLElement {
454
454
  }
455
455
  figEditorDefineElement("fig-select-options", FigSelectOptions);
456
456
 
457
+ /**
458
+ * A dropdown-styled select.
459
+ * @attr {string} variant - Visual style. Use `ghost` for a borderless control.
460
+ */
457
461
  class FigSelect extends HTMLElement {
458
462
  #button = null;
459
463
  #popup = null;
@@ -492,6 +496,7 @@ class FigSelect extends HTMLElement {
492
496
  "offset",
493
497
  "closedby",
494
498
  "open",
499
+ "variant",
495
500
  ];
496
501
  }
497
502
 
package/fig.js CHANGED
@@ -673,6 +673,7 @@ figDefineElement("fig-button", FigButton);
673
673
  * A custom dropdown/select element.
674
674
  * @attr {string} type - The dropdown type: "select" (default) or "dropdown"
675
675
  * @attr {string} value - The currently selected value
676
+ * @attr {string} variant - Visual style. Use `ghost` for a borderless control.
676
677
  */
677
678
  class FigDropdown extends HTMLElement {
678
679
  #label = "Menu";
@@ -871,7 +872,7 @@ class FigDropdown extends HTMLElement {
871
872
  this.setAttribute("value", value);
872
873
  }
873
874
  static get observedAttributes() {
874
- return ["value", "type", "label", "disabled"];
875
+ return ["value", "type", "label", "disabled", "variant"];
875
876
  }
876
877
  #syncDisabled() {
877
878
  const disabled =
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rogieking/figui3",
3
- "version": "8.9.10",
3
+ "version": "8.9.11",
4
4
  "description": "A lightweight web components library for building Figma plugin and widget UIs with native look and feel",
5
5
  "author": "Rogie King",
6
6
  "license": "MIT",