@rogieking/figui3 4.11.0 → 4.12.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/README.md CHANGED
@@ -609,7 +609,6 @@ A selection list controller. `<fig-choice>` elements are selectable options with
609
609
  | `drag` | boolean | `false` | Enable drag-to-scroll |
610
610
  | `overflow` | string | — | Overflow behavior |
611
611
  | `loop` | boolean | `false` | Loop keyboard navigation |
612
- | `padding` | boolean | `true` | Internal padding (`padding="false"` removes it) |
613
612
 
614
613
  **fig-choice attributes:**
615
614
 
package/components.css CHANGED
@@ -669,7 +669,7 @@ input[type="text"][list] {
669
669
  & > button {
670
670
  display: inline-block;
671
671
  align-items: center;
672
- gap: var(--spacer-1);
672
+ gap: var(--spacer-1, 0.25rem);
673
673
  width: 100%;
674
674
  border: 0;
675
675
  background: transparent;
@@ -4665,13 +4665,6 @@ fig-chooser {
4665
4665
  }
4666
4666
  }
4667
4667
 
4668
- &[padding="false"] {
4669
- gap: var(--fig-chooser-gap);
4670
- fig-choice {
4671
- --fig-choice-padding: 0px;
4672
- }
4673
- }
4674
-
4675
4668
  &[overflow="scrollbar"] {
4676
4669
  scrollbar-width: thin;
4677
4670
  scrollbar-color: var(--figma-color-border) transparent;
@@ -4743,25 +4736,21 @@ fig-chooser {
4743
4736
  color: var(--figma-color-icon);
4744
4737
  background: var(--figma-color-bg) !important;
4745
4738
 
4739
+ .fig-chooser-nav-chevron{
4740
+ position: relative;
4741
+ }
4746
4742
 
4747
- &::after {
4748
- content: "";
4749
- display: block;
4750
- width: 1rem;
4751
- height: 1rem;
4752
- mask-image: var(--icon-chevron);
4753
- mask-size: contain;
4754
- mask-repeat: no-repeat;
4755
- mask-position: center;
4756
- background: currentColor;
4743
+ &:active .fig-chooser-nav-chevron {
4744
+ transform: translateY(1px);
4757
4745
  }
4758
4746
  }
4759
4747
 
4760
4748
  .fig-chooser-nav-start {
4761
4749
  top: 0;
4762
4750
  margin-bottom: calc(var(--chooser-fade-size) * -1);
4763
- box-shadow: 0 1px 0 0 var(--figma-color-border);
4764
- &::after {
4751
+ box-shadow: 0 1px 0 0 var(--figma-color-bordertranslucent);
4752
+
4753
+ .fig-chooser-nav-chevron {
4765
4754
  rotate: 180deg;
4766
4755
  }
4767
4756
  }
@@ -4769,7 +4758,7 @@ fig-chooser {
4769
4758
  .fig-chooser-nav-end {
4770
4759
  bottom: 0;
4771
4760
  margin-top: calc(var(--chooser-fade-size) * -1);
4772
- box-shadow: 0 -1px 0 0 var(--figma-color-border);
4761
+ box-shadow: 0 -1px 0 0 var(--figma-color-bordertranslucent);
4773
4762
  }
4774
4763
 
4775
4764
  &[layout="horizontal"] {
@@ -4787,10 +4776,9 @@ fig-chooser {
4787
4776
  left: 0;
4788
4777
  right: auto;
4789
4778
  margin-right: calc(var(--chooser-fade-size) * -1);
4790
- box-shadow: 1px 0 0 0 var(--figma-color-border);
4791
-
4779
+ box-shadow: 1px 0 0 0 var(--figma-color-bordertranslucent);
4792
4780
 
4793
- &::after {
4781
+ .fig-chooser-nav-chevron {
4794
4782
  rotate: 90deg;
4795
4783
  }
4796
4784
  }
@@ -4799,10 +4787,9 @@ fig-chooser {
4799
4787
  right: 0;
4800
4788
  left: auto;
4801
4789
  margin-left: calc(var(--chooser-fade-size) * -1);
4802
- box-shadow: -1px 0 0 0 var(--figma-color-border);
4790
+ box-shadow: -1px 0 0 0 var(--figma-color-bordertranslucent);
4803
4791
 
4804
-
4805
- &::after {
4792
+ .fig-chooser-nav-chevron {
4806
4793
  rotate: -90deg;
4807
4794
  }
4808
4795
  }
@@ -4832,15 +4819,14 @@ fig-choice {
4832
4819
  gap: var(--spacer-2);
4833
4820
  outline: none;
4834
4821
  cursor: default;
4835
-
4836
4822
  padding: var(--fig-choice-padding);
4837
4823
 
4838
4824
  &:hover:not([selected]):not([disabled]):not([aria-disabled="true"]) {
4839
4825
  background-color: var(--figma-color-bg-secondary);
4840
4826
  }
4841
4827
 
4842
- &[padding="false"] {
4843
- --fig-choice-padding: 0px;
4828
+ &[padding]:not([padding="false"]) {
4829
+ --fig-choice-padding: var(--spacer-2);
4844
4830
  }
4845
4831
 
4846
4832
  &[selected] {
@@ -4852,7 +4838,7 @@ fig-choice {
4852
4838
  border-radius: var(--fig-choice-border-radius);
4853
4839
  pointer-events: none;
4854
4840
  z-index: 1;
4855
- box-shadow: inset 0 0 0 4px var(--figma-color-bg);
4841
+ box-shadow: inset 0 0 0 calc(var(--fig-choice-selection-ring-width)*2) var(--figma-color-bg);
4856
4842
  outline: var(--fig-choice-selection-ring-width) solid
4857
4843
  var(--figma-color-border-selected);
4858
4844
  outline-offset: calc(var(--fig-choice-selection-ring-width) * -1);