@rogieking/figui3 9.0.14 → 9.1.1

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.
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  name: fig-lab
3
3
  description: >-
4
- Guides FigUI3 experimental Lab components: fig-canvas-control, fig-input-angle,
4
+ Guides FigUI3 experimental Lab components: fig-canvas-control,
5
5
  fig-input-wheel, fig-reorder, and AI composer components, including React JSX usage.
6
6
  APIs are unstable.
7
7
  user-invocable: false
@@ -22,4 +22,4 @@ import "@rogieking/figui3/fig-lab.css";
22
22
  import "@rogieking/figui3/fig-lab.js";
23
23
  ```
24
24
 
25
- Use Lab for canvas handles, angle/wheel inputs, reorder behavior, and AI composition surfaces. Keep Lab out of `fig.js`.
25
+ Use Lab for canvas handles, wheel inputs, reorder behavior, and AI composition surfaces. Keep Lab out of `fig.js`.
@@ -26,19 +26,6 @@ Handlers below assume `onInput` / `onChange` from the React contract.
26
26
  - Attrs: `type`, `value` (JSON string), `color`, `name`, `tooltips`, `disabled`, `drag-surface`, `snapping` (`false` | `modifier` | `true`), `precision` (positions, radius, angle, and internal handles; default `2`)
27
27
  - React: JSON `value` as a string attr; do not remount during drag.
28
28
 
29
- ### `fig-input-angle`
30
-
31
- ```tsx
32
- <fig-input-angle
33
- value={String(deg)}
34
- text="true"
35
- units="°"
36
- onInput={onInput}
37
- />
38
- ```
39
-
40
- - Attrs: `value`, `precision`, `text`, `min`, `max`, `units`, `dial` (default true), `rotations`, `disabled`
41
-
42
29
  ### `fig-input-wheel`
43
30
 
44
31
  ```tsx
@@ -35,12 +35,6 @@ Parent must be `position: relative` (or similar) so the control can fill it. Wra
35
35
 
36
36
  Types: `point`, `color`, `point-radius`, `point-radius-angle`, `point-point`.
37
37
 
38
- ## `fig-input-angle`
39
-
40
- Observed include `value`, `precision`, `text`, `min`, `max`, `units`, `dial`, plus `rotations`.
41
-
42
- `dial` defaults true. `text="true"` shows the numeric field.
43
-
44
38
  ## `fig-reorder`
45
39
 
46
40
  Observed: `axis`, `handle`, `disabled`.
@@ -88,7 +88,7 @@ fig-menu change → detail { value }
88
88
  fig-dialog/popup native dialog close plus FigUI3 positioning attrs
89
89
  ```
90
90
 
91
- `fig-input-angle` and `fig-input-wheel` are **lab**, not core.
91
+ `fig-angle` is core. `fig-input-wheel` remains **lab**.
92
92
 
93
93
  ## Maintainer workflow
94
94
 
@@ -86,7 +86,26 @@ Handlers below assume `onInput` / `onChange` / `onClick` from [react.md](react.m
86
86
  />
87
87
  ```
88
88
 
89
- - Attrs: `min`, `max`, `step`, `precision`, `units`, `units-disallow`, `steppers`, `disabled`, `full`
89
+ - Attrs: `variant` (`ghost`), `min`, `max`, `step`, `precision`, `units`, `units-disallow`, `steppers`, `tabular`, `disabled`, `full`
90
+
91
+ ### `fig-angle`
92
+
93
+ ```tsx
94
+ <fig-angle
95
+ value={String(angle)}
96
+ units="deg"
97
+ onInput={onInput}
98
+ onChange={onChange}
99
+ />
100
+ ```
101
+
102
+ - Attrs: `value`, `default`, `precision` (defaults: deg/grad 0, rad 2, turn 3), `dial` (default true), optional `min`/`max`, `step` (defaults: deg/° 1, rad 0.01, turn 0.001, grad 0.1), `units` (`deg`, `°`, `rad`, `turn`, `grad`; degrees display as `°`), `rotations`, `disabled`, `full`
103
+ - Property: `defaultValue` returns the resolved default; values are unbounded unless `min`/`max` are authored.
104
+ - Changing `units` converts `value`, `default`, `min`, `max`, and `step` to preserve physical angles.
105
+ - The surface shows the shared focus outline for dial/input focus and dragging. Dial Arrow keys use `step`; Shift-drag and dial Shift+Arrow move in 15° increments. The internal number input retains built-in Up/Down, Shift×10, and Alt-drag scrubbing.
106
+ - An inset reset button appears when `value` differs from `default`; activating it emits `input` and `change`.
107
+ - Events: `input` while editing and `change` on commit, with `{ value, angle, units }`; event values are rounded to `precision` without reducing stored precision
108
+ - The arrow sweeps from zero to the signed angle directly over the outer dial boundary. `customElements.get("fig-angle").rotationIcon(angle, size)` returns a standalone SVG string (`size` defaults to 48).
90
109
 
91
110
  ### `fig-input-combo`
92
111
 
@@ -44,6 +44,7 @@ type FigAttrs = React.DetailedHTMLProps<
44
44
 
45
45
  type FigTag =
46
46
  | "fig-3d-rotate"
47
+ | "fig-angle"
47
48
  | "fig-ai-context"
48
49
  | "fig-ai-prompt"
49
50
  | "fig-attachment"
@@ -71,7 +72,6 @@ type FigTag =
71
72
  | "fig-header"
72
73
  | "fig-icon"
73
74
  | "fig-image"
74
- | "fig-input-angle"
75
75
  | "fig-input-color"
76
76
  | "fig-input-combo"
77
77
  | "fig-input-file"
@@ -23,6 +23,24 @@ Public API: `README.md`. React recipes: [components.md](components.md).
23
23
  - `value`, `placeholder`, `multiline`, `autoresize`, `resizable`, `disabled`, `readonly`, `full`
24
24
  - Adornments: `slot="prepend"` and `slot="append"`
25
25
 
26
+ ## `fig-input-number`
27
+
28
+ - `size`: `""`, `large` (32px tall)
29
+ - `variant`: `""`, `ghost`
30
+ - `value`, `placeholder`, `min`, `max`, `step`, `precision`, `units`, `units-disallow`, `steppers`, `tabular`, `disabled`, `full`
31
+ - Adornments: `slot="prepend"` and `slot="append"`
32
+
33
+ ## `fig-angle`
34
+
35
+ - `value`, `default`, `precision` (defaults: deg/grad `0`, rad `2`, turn `3`), `dial`, optional `min`/`max`, `step` (defaults: deg/° `1`, rad `0.01`, turn `0.001`, grad `0.1`), `rotations`, `disabled`, `full`
36
+ - `defaultValue`: resolved numeric default; values are otherwise unbounded
37
+ - `units`: `deg` (default; `°` alias), `rad`, `turn`, or `grad`. Degree units display as `°` in the number field.
38
+ - Changing `units` converts `value`, `default`, `min`, `max`, and `step`.
39
+ - Shared surface focus outline for dial/input focus and dragging; dial Arrow keys use `step`, Shift-drag/dial Shift+Arrow move by 15°, and the number input retains built-in Up/Down, Shift×10, and Alt-drag scrubbing
40
+ - An inset reset button appears when `value` differs from `default`
41
+ - Events: `input` while editing; `change` on commit; detail `{ value, angle, units }`, rounded to `precision` while stored values remain high precision
42
+ - Static `rotationIcon(angle, size)` returns the centered SVG arc/arrow swept from zero to the signed angle; `size` defaults to `48`.
43
+
26
44
  ## `fig-dropdown`
27
45
 
28
46
  - `value`, `type="select|dropdown"`, `variant="ghost"`, `size="large"` (32px), `full`, `disabled`
package/README.md CHANGED
@@ -105,7 +105,7 @@ Minimal example:
105
105
  | [Input Wheel](#input-wheel) | `<fig-input-wheel>` | Standalone SVG tick-and-handle numeric scrubber |
106
106
  | [Text Input](#text-input) | `<fig-input-text>` | Styled text/textarea input |
107
107
  | [Number Input](#number-input) | `<fig-input-number>` | Numeric input with units |
108
- | [Input Angle](#input-angle) | `<fig-input-angle>` | Angle/rotation dial and text input |
108
+ | [Angle](#angle) | `<fig-angle>` | Instrument-style angle/rotation dial |
109
109
  | [Swatch](#swatch) | `<fig-swatch>` | Color/gradient/image swatch |
110
110
  | [Color Tip](#color-tip) | `<fig-color-tip>` | Compact color tip with picker |
111
111
  | [Color Input](#color-input) | `<fig-input-color>` | Color picker with hex/alpha |
@@ -344,7 +344,7 @@ document.querySelector("fig-select").menuAnchor =
344
344
  | `precision` | number | — | Decimal places for output |
345
345
  | `disabled` | boolean | `false` | Disabled state |
346
346
 
347
- **Events:** `input` (continuous), `change` (on release).
347
+ **Events:** `input` (continuous), `change` (on release), with detail `{ value, angle, units }`. Event values are rounded to `precision`; the component retains its higher-precision internal value.
348
348
 
349
349
  ```html
350
350
  <fig-slider min="0" max="100" value="50" units="%"></fig-slider>
@@ -417,6 +417,7 @@ The `value`, `min`, `max`, and `step` properties mirror their attributes. `aria-
417
417
  | `value` | string | — | Numeric value |
418
418
  | `placeholder` | string | — | Placeholder text |
419
419
  | `size` | string | — | Set to `"large"` for a 32px-tall input |
420
+ | `variant` | string | — | Set to `"ghost"` for a borderless control |
420
421
  | `min` | number | — | Minimum |
421
422
  | `max` | number | — | Maximum |
422
423
  | `step` | number | — | Step increment |
@@ -426,39 +427,48 @@ The `value`, `min`, `max`, and `step` properties mirror their attributes. `aria-
426
427
  | `transform` | number | — | Display multiplier |
427
428
  | `precision` | number | — | Fixed displayed decimal places; omitted values use up to two places |
428
429
  | `steppers` | boolean | `false` | Show spin buttons |
430
+ | `tabular` | boolean | `false` | Tabular numerals (`font-variant-numeric: tabular-nums`) |
429
431
  | `disabled` | boolean | `false` | Disabled state |
430
432
 
431
433
  ```html
432
434
  <fig-input-number value="100" units="px"></fig-input-number>
433
435
  <fig-input-number size="large" value="100" units="px"></fig-input-number>
436
+ <fig-input-number variant="ghost" value="100" units="px"></fig-input-number>
437
+ <fig-input-number tabular value="100" units="px"></fig-input-number>
434
438
  <fig-input-number value="50" units="%" min="0" max="100"></fig-input-number>
435
439
  ```
436
440
 
437
441
  ---
438
442
 
439
- #### Input Angle
443
+ #### Angle
444
+
445
+ `<fig-angle>` — [demo](https://rog.ie/figui3/#angle)
440
446
 
441
- `<fig-input-angle>` — [demo](https://rog.ie/figui3/#angle-input)
447
+ Instrument-style angle/rotation control with an interactive dial, text input, CSS angle units, 15-degree Shift snapping, and unbounded positive/negative winding by default. Degree units display as `°` in the number field. Accepts unit suffixes in text input (`90°`, `90deg`, `3.14rad`, `0.5turn`, `100grad`). Add `min` and/or `max` to clamp the value. Changing `units` preserves the physical angle and converts `value`, `default`, `min`, `max`, and `step` (for example, `90deg` becomes `0.250turn`). When the value differs from `default`, an inset reset button restores the default and emits `input` and `change`.
442
448
 
443
- Angle/rotation input with circular dial, optional text input, multi-unit support, and unbounded winding past 360deg. Accepts unit suffixes in text input (`90deg`, `3.14rad`, `0.5turn`).
449
+ The rotation arrow starts at zero and sweeps along the outer dial boundary to the current angle, clockwise for positive values and counterclockwise for negative values. The surface receives the shared focus outline when the dial or number input is focused or dragged. Dial Arrow keys move by `step`, with Shift+Arrow moving by 15°. The internal number input keeps its built-in Up/Down stepping, Shift×10 stepping, and Alt-drag scrubbing. `customElements.get("fig-angle").rotationIcon(angle, size)` returns a standalone SVG version for reuse elsewhere; `size` defaults to `48`.
444
450
 
445
451
  | Attribute | Type | Default | Description |
446
452
  |---|---|---|---|
447
453
  | `value` | number | `0` | Angle value |
448
- | `precision` | number | `1` | Decimal places |
449
- | `text` | boolean | `false` | Show text input |
454
+ | `default` | number | `0` | Default/reset value, clamped to bounds |
455
+ | `precision` | number | unit-dependent | Decimal places (`0` deg/grad, `2` rad, `3` turn) |
450
456
  | `dial` | boolean | `true` | Show circular dial |
451
457
  | `min` | number | — | Minimum (omit for unbounded) |
452
458
  | `max` | number | — | Maximum (omit for unbounded) |
453
- | `units` | string | `"°"` | `"°"` / `"deg"`, `"rad"`, `"turn"` |
459
+ | `step` | number | unit-dependent | Keyboard and text-input step (`1` deg/°, `0.01` rad, `0.001` turn, `0.1` grad) |
460
+ | `units` | string | `"deg"` | `"deg"` / `"°"`, `"rad"`, `"turn"`, `"grad"` |
454
461
  | `rotations` | boolean | `false` | Show rotation counter |
455
462
 
463
+ The `defaultValue` property returns the resolved numeric default in the active unit.
464
+
456
465
  **Events:** `input` (continuous), `change` (on release).
457
466
 
458
467
  ```html
459
- <fig-input-angle value="90" text="true"></fig-input-angle>
460
- <fig-input-angle text="true" units="rad" value="3.14159"></fig-input-angle>
461
- <fig-input-angle text="true" rotations value="1080"></fig-input-angle>
468
+ <fig-angle value="90"></fig-angle>
469
+ <fig-angle units="rad" value="3.14159"></fig-angle>
470
+ <fig-angle units="grad" value="100"></fig-angle>
471
+ <fig-angle rotations value="1080"></fig-angle>
462
472
  ```
463
473
 
464
474
  ---
package/components.css CHANGED
@@ -14,7 +14,7 @@
14
14
  --figma-color-bg-brand-tertiary: light-dark(#e5f4ff, #394360);
15
15
  --figma-color-bg-component: light-dark(#9747ff, #8a38f5);
16
16
  --figma-color-bg-component-hover: light-dark(#8638e5, #7a2ed6);
17
- --figma-color-bg-component-pressed: light-dark(#8638e5, #7a2ed6);
17
+ --figma-color-bg-component-pressed: light-dark(#7c2bda, #652ca8);
18
18
  --figma-color-bg-component-secondary: light-dark(#7c2bda, #652ca8);
19
19
  --figma-color-bg-component-tertiary: light-dark(#f1e5ff, #473956);
20
20
  --figma-color-bg-danger: light-dark(#f24822, #e03e1a);
@@ -27,26 +27,26 @@
27
27
  --figma-color-bg-hover: light-dark(#f5f5f5, #383838);
28
28
  --figma-color-bg-active: var(--figma-color-bg-pressed);
29
29
  --figma-color-bg-inverse: light-dark(#2c2c2c, #ffffff);
30
- --figma-color-bg-onselected: light-dark(#bde3ff, #667799);
31
- --figma-color-bg-onselected-hover: light-dark(#bde3ff, #667799);
32
- --figma-color-bg-onselected-pressed: light-dark(#bde3ff, #667799);
30
+ --figma-color-bg-onselected: light-dark(#bde3ff, #4a5878);
31
+ --figma-color-bg-onselected-hover: light-dark(#bde3ff, #4a5878);
32
+ --figma-color-bg-onselected-pressed: light-dark(#bde3ff, #4a5878);
33
33
  --figma-color-bg-pressed: light-dark(#f5f5f5, #383838);
34
34
  --figma-color-bg-secondary: light-dark(#f5f5f5, #383838);
35
- --figma-color-bg-selected: light-dark(#e5f4ff, #4a5878);
36
- --figma-color-bg-selected-hover: light-dark(#bde3ff, #536383);
37
- --figma-color-bg-selected-pressed: light-dark(#bde3ff, #536383);
38
- --figma-color-bg-selected-secondary: light-dark(#f2f9ff, #394360);
35
+ --figma-color-bg-selected: light-dark(#e5f4ff, #394360);
36
+ --figma-color-bg-selected-hover: light-dark(#bde3ff, #4a5878);
37
+ --figma-color-bg-selected-pressed: light-dark(#80caff, #394360);
38
+ --figma-color-bg-selected-secondary: light-dark(#f2f9ff, #32394d);
39
39
  --figma-color-bg-selected-strong: light-dark(#0d99ff, #0c8ce9);
40
- --figma-color-bg-selected-tertiary: light-dark(#f2f9ff, #394360);
40
+ --figma-color-bg-selected-tertiary: light-dark(#f2f9ff, #32394d);
41
41
  --figma-color-bg-success: light-dark(#14ae5c, #198f51);
42
42
  --figma-color-bg-success-hover: light-dark(#009951, #078348);
43
- --figma-color-bg-success-pressed: light-dark(#009951, #078348);
43
+ --figma-color-bg-success-pressed: light-dark(#008043, #0a5c35);
44
44
  --figma-color-bg-success-secondary: light-dark(#008043, #0a5c35);
45
- --figma-color-bg-success-tertiary: light-dark(#cff7d3, #476656);
45
+ --figma-color-bg-success-tertiary: light-dark(#e0f6e5, #2f483c);
46
46
  --figma-color-bg-tertiary: light-dark(#e6e6e6, #444444);
47
47
  --figma-color-bg-warning: light-dark(#ffcd29, #f3c11b);
48
48
  --figma-color-bg-warning-hover: light-dark(#ffc21a, #f2b50d);
49
- --figma-color-bg-warning-pressed: light-dark(#ffc21a, #f2b50d);
49
+ --figma-color-bg-warning-pressed: light-dark(#fab815, #e4a711);
50
50
  --figma-color-bg-warning-secondary: light-dark(#fab815, #e4a711);
51
51
  --figma-color-bg-warning-tertiary: light-dark(#fff1c2, #5c4100);
52
52
  --figma-color-bg-switch: light-dark(#e6e6e6, #444444);
@@ -59,7 +59,7 @@
59
59
  --figma-color-border: light-dark(#e6e6e6, #444444);
60
60
  --figma-color-border-brand: light-dark(#bde3ff, #105cad);
61
61
  --figma-color-border-brand-strong: light-dark(#007be5, #7cc4f8);
62
- --figma-color-border-component: light-dark(#e4ccff, #652ca8);
62
+ --figma-color-border-component: light-dark(#e4ccff, #604d75);
63
63
  --figma-color-border-component-hover: light-dark(#9747ff, #8a38f5);
64
64
  --figma-color-border-component-strong: light-dark(#8638e5, #d6b6fb);
65
65
  --figma-color-border-danger: light-dark(#ffc7c2, #963323);
@@ -82,9 +82,9 @@
82
82
  --figma-color-border-selected: light-dark(#0d99ff, #0c8ce9);
83
83
  --figma-color-border-selected-strong: light-dark(#007be5, #7cc4f8);
84
84
  --figma-color-border-strong: light-dark(#2c2c2c, #ffffffe5);
85
- --figma-color-border-success: light-dark(#aff4c6, #0a5c35);
86
- --figma-color-border-success-strong: light-dark(#009951, #79d297);
87
- --figma-color-border-warning: light-dark(#ffe8a3, #925711);
85
+ --figma-color-border-success: light-dark(#b9ebc6, #517361);
86
+ --figma-color-border-success-strong: light-dark(#009951, #7cd797);
87
+ --figma-color-border-warning: light-dark(#f5dfa8, #7a5800);
88
88
  --figma-color-border-warning-strong: light-dark(#b86200, #f7d15f);
89
89
  --figma-color-border-slot: light-dark(#ff24bd, #f316b0);
90
90
 
@@ -101,8 +101,8 @@
101
101
  --figma-color-icon-brand-tertiary: light-dark(#bde3ff, #394360);
102
102
  --figma-color-icon-component: light-dark(#8638e5, #d1a8ff);
103
103
  --figma-color-icon-component-pressed: light-dark(#7c2bda, #d6b6fb);
104
- --figma-color-icon-component-secondary: light-dark(#6f3bb2, #d1a8ff);
105
- --figma-color-icon-component-tertiary: light-dark(#6f3bb2, #d1a8ff);
104
+ --figma-color-icon-component-secondary: light-dark(#a38cc0, #7f699b);
105
+ --figma-color-icon-component-tertiary: light-dark(#c5b2dc, #7f699b);
106
106
  --figma-color-icon-danger: light-dark(#f24822, #e03e1a);
107
107
  --figma-color-icon-danger-hover: light-dark(#bd2915, #fbbcb6);
108
108
  --figma-color-icon-danger-pressed: light-dark(#bd2915, #fbbcb6);
@@ -133,21 +133,21 @@
133
133
  --figma-color-icon-onwarning-secondary: #00000080;
134
134
  --figma-color-icon-onwarning-tertiary: #0000004d;
135
135
  --figma-color-icon-pressed: light-dark(#007be5, #0a6dc2);
136
- --figma-color-icon-secondary: light-dark(#00000080, #ffffffb3);
136
+ --figma-color-icon-secondary: light-dark(#00000080, #ffffffb2);
137
137
  --figma-color-icon-secondary-hover: light-dark(#000000e5, #ffffff);
138
138
  --figma-color-icon-selected: light-dark(#007be5, #7cc4f8);
139
- --figma-color-icon-selected-secondary: light-dark(#007be5, #7cc4f8);
140
- --figma-color-icon-selected-tertiary: light-dark(#007be5, #7cc4f8);
141
- --figma-color-icon-success: light-dark(#14ae5c, #198f51);
142
- --figma-color-icon-success-pressed: light-dark(#008043, #a1e8b9);
143
- --figma-color-icon-success-secondary: light-dark(#14ae5c, #198f51);
144
- --figma-color-icon-success-tertiary: light-dark(#14ae5c, #198f51);
145
- --figma-color-icon-tertiary: light-dark(#00000099, #ffffff99);
139
+ --figma-color-icon-selected-secondary: light-dark(#0d99ff, #0c8ce9);
140
+ --figma-color-icon-selected-tertiary: light-dark(#80caff, #0a6dc2);
141
+ --figma-color-icon-success: light-dark(#009951, #7cd797);
142
+ --figma-color-icon-success-pressed: light-dark(#008043, #a5e5b7);
143
+ --figma-color-icon-success-secondary: light-dark(#009951, #7cd797);
144
+ --figma-color-icon-success-tertiary: light-dark(#009951, #7cd797);
145
+ --figma-color-icon-tertiary: light-dark(#0000004d, #fff6);
146
146
  --figma-color-icon-tertiary-hover: light-dark(#000000e5, #ffffff);
147
- --figma-color-icon-warning: light-dark(#ffcd29, #f3c11b);
147
+ --figma-color-icon-warning: light-dark(#b86200, #f7d15f);
148
148
  --figma-color-icon-warning-pressed: light-dark(#b86200, #f7d15f);
149
- --figma-color-icon-warning-secondary: light-dark(#ffcd29, #f3c11b);
150
- --figma-color-icon-warning-tertiary: light-dark(#ffcd29, #f3c11b);
149
+ --figma-color-icon-warning-secondary: light-dark(#b86200, #f7d15f);
150
+ --figma-color-icon-warning-tertiary: light-dark(#b86200, #f7d15f);
151
151
 
152
152
  /* Text Colors */
153
153
  --figma-color-text: light-dark(#000000e5, #ffffff);
@@ -156,8 +156,8 @@
156
156
  --figma-color-text-brand-tertiary: light-dark(#007be5, #7cc4f8);
157
157
  --figma-color-text-component: light-dark(#8638e5, #d1a8ff);
158
158
  --figma-color-text-component-pressed: light-dark(#7c2bda, #d6b6fb);
159
- --figma-color-text-component-secondary: light-dark(#6f3bb2, #d1a8ff);
160
- --figma-color-text-component-tertiary: light-dark(#6f3bb2, #d1a8ff);
159
+ --figma-color-text-component-secondary: light-dark(#a38cc0, #a38cc0);
160
+ --figma-color-text-component-tertiary: light-dark(#c5b2dc, #7f699b);
161
161
  --figma-color-text-danger: light-dark(#dc3412, #fca397);
162
162
  --figma-color-text-danger-secondary: light-dark(#dc3412, #fca397);
163
163
  --figma-color-text-danger-tertiary: light-dark(#dc3412, #fca397);
@@ -184,16 +184,16 @@
184
184
  --figma-color-text-onwarning: #000000e5;
185
185
  --figma-color-text-onwarning-secondary: #00000080;
186
186
  --figma-color-text-onwarning-tertiary: #0000004d;
187
- --figma-color-text-secondary: light-dark(#00000099, #ffffffcc);
187
+ --figma-color-text-secondary: light-dark(#00000099, #ffffffb2);
188
188
  --figma-color-text-secondary-hover: light-dark(#000000e5, #ffffff);
189
189
  --figma-color-text-selection: rgba(13, 153, 255, 0.4);
190
190
  --figma-color-text-selected: light-dark(#007be5, #7cc4f8);
191
191
  --figma-color-text-selected-secondary: light-dark(#007be5, #7cc4f8);
192
192
  --figma-color-text-selected-tertiary: light-dark(#007be5, #7cc4f8);
193
- --figma-color-text-success: light-dark(#009951, #79d297);
194
- --figma-color-text-success-secondary: light-dark(#009951, #79d297);
195
- --figma-color-text-success-tertiary: light-dark(#009951, #79d297);
196
- --figma-color-text-tertiary: light-dark(#00000099, #ffffff99);
193
+ --figma-color-text-success: light-dark(#009951, #7cd797);
194
+ --figma-color-text-success-secondary: light-dark(#009951, #7cd797);
195
+ --figma-color-text-success-tertiary: light-dark(#009951, #7cd797);
196
+ --figma-color-text-tertiary: light-dark(#0000004d, #ffffff66);
197
197
  --figma-color-text-tertiary-hover: light-dark(#000000e5, #ffffff);
198
198
  --figma-color-text-warning: light-dark(#b86200, #f7d15f);
199
199
  --figma-color-text-warning-secondary: light-dark(#b86200, #f7d15f);
@@ -221,12 +221,13 @@
221
221
  --body-large-fontSize: var(--text-body-large-font-size);
222
222
  --body-letter-spacing: 0.055px;
223
223
  --body-medium-strong-fontWeight: 550;
224
- --body-large-strong-fontWeight: 500;
224
+ --body-large-strong-fontWeight: 550;
225
225
  --body-medium-fontWeight: 450;
226
226
 
227
227
  --line-height: 1rem;
228
228
 
229
229
  /* Spacing */
230
+ --spacer-0: 0;
230
231
  --spacer-1: 0.25rem;
231
232
  --spacer-2: 0.5rem;
232
233
  --spacer-2-5: 0.75rem;
@@ -242,11 +243,19 @@
242
243
  --radius-medium: 0.3125rem;
243
244
  --radius-medium-large: 0.5625rem;
244
245
  --radius-large: 0.8125rem;
246
+ --radius-xlarge: 1.3125rem;
247
+ --radius-xxlarge: 1.8125rem;
248
+ --radius-xxxlarge: 2.3125rem;
249
+ --radius-full: 9999px;
245
250
  --figma-radius-none: var(--radius-none);
246
251
  --figma-radius-small: var(--radius-small);
247
252
  --figma-radius-medium: var(--radius-medium);
248
253
  --figma-radius-medium-large: var(--radius-medium-large);
249
254
  --figma-radius-large: var(--radius-large);
255
+ --figma-radius-xlarge: var(--radius-xlarge);
256
+ --figma-radius-xxlarge: var(--radius-xxlarge);
257
+ --figma-radius-xxxlarge: var(--radius-xxxlarge);
258
+ --figma-radius-full: var(--radius-full);
250
259
 
251
260
  /* Transitions */
252
261
  --input-transition: all 0.08s ease-out;
@@ -281,8 +290,8 @@
281
290
  rgba(255, 255, 255, 0.1)
282
291
  );
283
292
  --figma-color-bg-transparent-secondary: light-dark(
284
- rgba(0, 0, 0, 0.2),
285
- rgba(255, 255, 255, 0.2)
293
+ rgba(0, 0, 0, 0.1),
294
+ rgba(255, 255, 255, 0.1)
286
295
  );
287
296
 
288
297
  /* Gradients */
@@ -1986,6 +1995,9 @@ fig-easing-curve {
1986
1995
  pointer-events: all;
1987
1996
  cursor: default;
1988
1997
  }
1998
+ fig-handle[type="minimal"] {
1999
+ --fig-handle-inner-bg: var(--figma-color-bg-secondary);
2000
+ }
1989
2001
  &.spring-mode .fig-easing-curve-handle[data-handle="bounce"],
1990
2002
  &.spring-mode .fig-easing-curve-handle[data-handle="bounce"] fig-handle,
1991
2003
  &.spring-mode .fig-easing-curve-handle[data-handle="bounce"] .fig-handle-hit-area {
@@ -1998,6 +2010,185 @@ fig-easing-curve {
1998
2010
  }
1999
2011
  }
2000
2012
 
2013
+ /* Angle */
2014
+ fig-angle {
2015
+ --stroke-width: 1.5;
2016
+ --aspect-ratio: 1 / 1;
2017
+ display: flex;
2018
+ flex-direction: column;
2019
+ gap: var(--spacer-2);
2020
+ width: 100%;
2021
+ min-width: 0;
2022
+ user-select: none;
2023
+
2024
+ .fig-angle-surface {
2025
+ position: relative;
2026
+ box-sizing: border-box;
2027
+ width: 100%;
2028
+ aspect-ratio: var(--aspect-ratio);
2029
+ display: grid;
2030
+ place-items: center;
2031
+ padding: var(--spacer-3);
2032
+ border-radius: var(--radius-medium);
2033
+ background: var(--figma-color-bg-secondary);
2034
+ overflow: hidden;
2035
+
2036
+ &:has(.fig-angle-svg:focus, .fig-angle-input:focus-within),
2037
+ &.dragging {
2038
+ outline: var(--figma-focus-outline);
2039
+ outline-offset: var(--figma-focus-outline-offset);
2040
+ }
2041
+
2042
+ &.dragging .fig-angle-svg {
2043
+ cursor: grabbing;
2044
+ }
2045
+ }
2046
+
2047
+ .fig-angle-svg {
2048
+ display: block;
2049
+ width: 100%;
2050
+ height: 100%;
2051
+ min-width: 0;
2052
+ min-height: 0;
2053
+ overflow: visible;
2054
+ cursor: grab;
2055
+ touch-action: none;
2056
+ pointer-events: auto;
2057
+
2058
+ &:focus {
2059
+ outline: 0;
2060
+ }
2061
+ }
2062
+
2063
+ .fig-angle-boundary,
2064
+ .fig-angle-tick,
2065
+ .fig-angle-indicator,
2066
+ .fig-angle-indicator-halo,
2067
+ .fig-angle-reference-path {
2068
+ vector-effect: non-scaling-stroke;
2069
+ stroke-linecap: round;
2070
+ stroke-linejoin: round;
2071
+ pointer-events: none;
2072
+ stroke-width: var(--stroke-width);
2073
+ }
2074
+
2075
+ .fig-angle-boundary {
2076
+ fill: none;
2077
+ stroke: var(--figma-color-bordertranslucent);
2078
+ stroke-width: var(--stroke-width);
2079
+ }
2080
+
2081
+ .fig-angle-tick {
2082
+ stroke: var(--figma-color-icon-tertiary);
2083
+ stroke-width: var(--stroke-width);
2084
+ }
2085
+
2086
+ .fig-angle-reference {
2087
+ color: var(--figma-color-icon-secondary);
2088
+ pointer-events: none;
2089
+ }
2090
+
2091
+ .fig-angle-indicator-halo {
2092
+ stroke: var(--figma-color-border);
2093
+ stroke-width: calc(var(--stroke-width) * 3);
2094
+ }
2095
+
2096
+ .fig-angle-indicator {
2097
+ stroke: var(--figma-color-icon);
2098
+ stroke-width: calc(var(--stroke-width) * 2);
2099
+ }
2100
+
2101
+ .fig-angle-input {
2102
+ flex: 0 0 auto;
2103
+ width: 100%;
2104
+ }
2105
+
2106
+ .fig-angle-surface > .fig-angle-input {
2107
+ position: absolute;
2108
+ z-index: 2;
2109
+ top: 50%;
2110
+ left: 50%;
2111
+ width: fit-content;
2112
+ transform: translate(-50%, -50%);
2113
+ outline: 0;
2114
+
2115
+ input {
2116
+ field-sizing: content;
2117
+ flex: 0 0 auto;
2118
+ }
2119
+ }
2120
+
2121
+ .fig-angle-reset {
2122
+ position: absolute;
2123
+ right: var(--spacer-1);
2124
+ bottom: var(--spacer-1);
2125
+ z-index: 3;
2126
+ background-color: var(--figma-color-bg-secondary) !important;
2127
+
2128
+ &:hover fig-icon {
2129
+ background-color: var(--figma-color-text);
2130
+ }
2131
+
2132
+ fig-icon {
2133
+ background-color: var(--figma-color-text-tertiary);
2134
+ }
2135
+ }
2136
+
2137
+ .fig-angle-rotations {
2138
+ font-variant-numeric: tabular-nums;
2139
+ color: var(--figma-color-text-secondary);
2140
+ }
2141
+
2142
+ &[full] {
2143
+ display: flex;
2144
+ width: 100%;
2145
+ }
2146
+
2147
+ &[disabled]:not([disabled="false"]) {
2148
+ .fig-angle-surface {
2149
+ .fig-angle-svg {
2150
+ cursor: default;
2151
+ }
2152
+ }
2153
+
2154
+ .fig-angle-boundary,
2155
+ .fig-angle-tick,
2156
+ .fig-angle-indicator-halo {
2157
+ stroke: var(--figma-color-border-disabled-strong);
2158
+ }
2159
+
2160
+ .fig-angle-reference {
2161
+ color: var(--figma-color-icon-disabled);
2162
+ }
2163
+
2164
+ .fig-angle-indicator {
2165
+ stroke: var(--figma-color-icon-disabled);
2166
+ }
2167
+ }
2168
+
2169
+ fig-field:not([direction="vertical"]) & {
2170
+ flex: 1;
2171
+ }
2172
+ }
2173
+
2174
+ @media (forced-colors: active) {
2175
+ fig-angle {
2176
+ .fig-angle-boundary,
2177
+ .fig-angle-tick,
2178
+ .fig-angle-indicator-halo {
2179
+ stroke: CanvasText;
2180
+ }
2181
+
2182
+ .fig-angle-reference {
2183
+ color: CanvasText;
2184
+ }
2185
+
2186
+ .fig-angle-indicator {
2187
+ stroke: Highlight;
2188
+ }
2189
+ }
2190
+ }
2191
+
2001
2192
  /* 3D Rotate */
2002
2193
  fig-3d-rotate {
2003
2194
  display: flex;
@@ -3726,6 +3917,9 @@ fig-content {
3726
3917
  &>p{
3727
3918
  padding-inline: var(--spacer-3);
3728
3919
  }
3920
+ &:empty{
3921
+ padding: 0;
3922
+ }
3729
3923
  }
3730
3924
 
3731
3925
  fig-content{
@@ -3805,6 +3999,13 @@ fig-input-number {
3805
3999
  flex: 1;
3806
4000
  width: 100%;
3807
4001
  }
4002
+ &[tabular]:not([tabular="false"]) {
4003
+ font-variant-numeric: tabular-nums;
4004
+
4005
+ & input {
4006
+ font-variant-numeric: tabular-nums;
4007
+ }
4008
+ }
3808
4009
  &[size="large"] {
3809
4010
  & > input,
3810
4011
  & > textarea {
@@ -3934,6 +4135,24 @@ fig-input-number {
3934
4135
  background-color: var(--figma-color-bg);
3935
4136
  box-shadow: inset 0 0 0 1px var(--figma-color-border-disabled);
3936
4137
  }
4138
+
4139
+ &:is(fig-input-number)[variant="ghost"] {
4140
+ background-color: transparent;
4141
+ box-shadow: none;
4142
+
4143
+ &:hover {
4144
+ box-shadow: none;
4145
+ }
4146
+
4147
+ &:is(:hover, :focus-within):not([disabled]):not([disabled="false"]) {
4148
+ background-color: var(--figma-color-bg-secondary);
4149
+ }
4150
+
4151
+ &[disabled]:not([disabled="false"]) {
4152
+ background-color: transparent;
4153
+ box-shadow: none;
4154
+ }
4155
+ }
3937
4156
  }
3938
4157
 
3939
4158
  fig-input-number > [slot],