@taprootio/espalier 4.13.0 → 4.13.2

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.
@@ -32988,6 +32988,17 @@
32988
32988
  "privacy": "private",
32989
32989
  "default": "false"
32990
32990
  },
32991
+ {
32992
+ "kind": "field",
32993
+ "name": "promotedToggleFrame",
32994
+ "privacy": "private",
32995
+ "default": "new RafThrottle(() => this.positionPromotedToggle())"
32996
+ },
32997
+ {
32998
+ "kind": "field",
32999
+ "name": "handlePromotedViewportResize",
33000
+ "privacy": "private"
33001
+ },
32991
33002
  {
32992
33003
  "kind": "field",
32993
33004
  "name": "lastDrawerBrandKey",
@@ -33055,7 +33066,7 @@
33055
33066
  "text": "void"
33056
33067
  }
33057
33068
  },
33058
- "description": "Lift the menu toggle into the top layer as a manual popover positioned\nat the rectangle it occupies in the header, so the burger animates to\nits X in place above a full-screen drawer. The header's flow closes up\nbehind it, which the drawer hides."
33069
+ "description": "Lift the menu toggle into the top layer as a manual popover positioned\nat its header rectangle when visible, constrained to the viewport when\nthe header has scrolled away. The header's flow closes up behind it,\nwhich the drawer hides."
33059
33070
  },
33060
33071
  {
33061
33072
  "kind": "method",
@@ -33068,6 +33079,48 @@
33068
33079
  },
33069
33080
  "description": "Keep a promoted toggle where it belongs while the viewport changes:\nat the inline end of the buttons section, which the section itself\nstill reports because only the toggle left the flow."
33070
33081
  },
33082
+ {
33083
+ "kind": "method",
33084
+ "name": "setPromotedTogglePosition",
33085
+ "privacy": "private",
33086
+ "return": {
33087
+ "type": {
33088
+ "text": "void"
33089
+ }
33090
+ },
33091
+ "parameters": [
33092
+ {
33093
+ "name": "toggle",
33094
+ "type": {
33095
+ "text": "HTMLElement"
33096
+ }
33097
+ },
33098
+ {
33099
+ "name": "left",
33100
+ "type": {
33101
+ "text": "number"
33102
+ }
33103
+ },
33104
+ {
33105
+ "name": "top",
33106
+ "type": {
33107
+ "text": "number"
33108
+ }
33109
+ },
33110
+ {
33111
+ "name": "width",
33112
+ "type": {
33113
+ "text": "number"
33114
+ }
33115
+ },
33116
+ {
33117
+ "name": "height",
33118
+ "type": {
33119
+ "text": "number"
33120
+ }
33121
+ }
33122
+ ]
33123
+ },
33071
33124
  {
33072
33125
  "kind": "method",
33073
33126
  "name": "demoteMenuToggle",
@@ -63679,203 +63732,274 @@
63679
63732
  },
63680
63733
  {
63681
63734
  "kind": "javascript-module",
63682
- "path": "dist/progress/esp-progress.js",
63735
+ "path": "dist/radio-button/esp-radio-button-group.js",
63683
63736
  "declarations": [
63684
63737
  {
63685
63738
  "kind": "class",
63686
- "description": "A progress indicator that supports both determinate and\nindeterminate modes, rendered as a linear bar or a circle.\n\nIn **determinate** mode, set `value` and optionally `max` to\nshow a fill bar representing progress toward completion:\n\n```html\n<esp-progress value=\"42\" show-value label=\"Upload progress\"></esp-progress>\n```\n\nIn **indeterminate** mode (the default when no `value` is set),\nan animated bar communicates that work is happening\nwithout a known endpoint:\n\n```html\n<esp-progress label=\"Loading data...\"></esp-progress>\n```\n\nThe three size presets:\n\n```html\n<div style=\"display: grid; gap: var(--esp-size-small);\">\n <esp-progress value=\"60\" label=\"Small\" size=\"small\"></esp-progress>\n <esp-progress value=\"60\" label=\"Medium\" size=\"medium\"></esp-progress>\n <esp-progress value=\"60\" label=\"Large\" size=\"large\" show-value></esp-progress>\n</div>\n```\n\nIntent colors match the design system:\n\n```html\n<div style=\"display: grid; gap: var(--esp-size-padding);\">\n <esp-progress value=\"80\" label=\"Primary\" show-value></esp-progress>\n <esp-progress value=\"60\" label=\"Success\" intent=\"success\" show-value></esp-progress>\n <esp-progress value=\"40\" label=\"Warning\" intent=\"warning\" show-value></esp-progress>\n <esp-progress value=\"20\" label=\"Danger\" intent=\"danger\" show-value></esp-progress>\n</div>\n```\n\nClick the button to watch the progress bar fill over ten seconds:\n\n```html\n<esp-box>\n <esp-progress id=\"demo-progress\" value=\"0\" label=\"Demo progress\" intent=\"success\" size=\"large\" show-value></esp-progress>\n <div style=\"display: flex; gap: var(--esp-size-small); margin-top: var(--esp-size-small);\">\n <esp-button id=\"start-btn\" label=\"Start\" collapsed></esp-button>\n <esp-button id=\"reset-btn\" label=\"Reset\" collapsed></esp-button>\n </div>\n</esp-box>\n<script>\n const progress = findById(\"demo-progress\");\n const startBtn = findById(\"start-btn\");\n const resetBtn = findById(\"reset-btn\");\n let running = false;\n startBtn.addEventListener(\"esp-clicked\", () => {\n if (running) return;\n running = true;\n progress.value = 0;\n const start = performance.now();\n const duration = 10000;\n function step(now) {\n const elapsed = now - start;\n progress.value = Math.min((elapsed / duration) * 100, 100);\n if (elapsed < duration) {\n requestAnimationFrame(step);\n } else {\n running = false;\n showToast({ message: \"Complete!\", intent: \"success\", icon: \"bread\" });\n }\n }\n requestAnimationFrame(step);\n });\n resetBtn.addEventListener(\"esp-clicked\", () => {\n running = false;\n progress.value = 0;\n });\n</script>\n```\n\nIndeterminate mode with different intents:\n\n```html\n<div style=\"display: grid; gap: var(--esp-size-small);\">\n <esp-progress label=\"Primary loading\"></esp-progress>\n <esp-progress label=\"Success loading\" intent=\"success\"></esp-progress>\n <esp-progress label=\"Warning loading\" intent=\"warning\"></esp-progress>\n <esp-progress label=\"Danger loading\" intent=\"danger\"></esp-progress>\n</div>\n```\n\nCircle mode displays a ring that fills clockwise. Set\n`mode=\"circle\"` and optionally `show-value` to display\nthe percentage in the center:\n\n```html\n<div style=\"display: flex; gap: var(--esp-size-padding); align-items: center; flex-wrap: wrap;\">\n <esp-progress mode=\"circle\" value=\"80\" label=\"Primary\" show-value></esp-progress>\n <esp-progress mode=\"circle\" value=\"60\" label=\"Success\" intent=\"success\" show-value></esp-progress>\n <esp-progress mode=\"circle\" value=\"40\" label=\"Warning\" intent=\"warning\" show-value></esp-progress>\n <esp-progress mode=\"circle\" value=\"20\" label=\"Danger\" intent=\"danger\" show-value></esp-progress>\n</div>\n```\n\nCircle size presets:\n\n```html\n<div style=\"display: flex; gap: var(--esp-size-padding); align-items: center;\">\n <esp-progress mode=\"circle\" value=\"60\" label=\"Small\" size=\"small\"></esp-progress>\n <esp-progress mode=\"circle\" value=\"60\" label=\"Medium\" size=\"medium\" show-value></esp-progress>\n <esp-progress mode=\"circle\" value=\"60\" label=\"Large\" size=\"large\" show-value></esp-progress>\n</div>\n```\n\nIndeterminate circle mode:\n\n```html\n<div style=\"display: flex; gap: var(--esp-size-padding); align-items: center;\">\n <esp-progress mode=\"circle\" label=\"Primary loading\"></esp-progress>\n <esp-progress mode=\"circle\" label=\"Success loading\" intent=\"success\"></esp-progress>\n</div>\n```\n\nClick the button to watch the circle fill over ten seconds:\n\n```html\n<esp-box>\n <div style=\"display: flex; align-items: center; gap: var(--esp-size-padding);\">\n <esp-progress id=\"demo-circle\" mode=\"circle\" value=\"0\" label=\"Circle demo\" intent=\"success\" size=\"large\" show-value></esp-progress>\n <div style=\"display: flex; gap: var(--esp-size-small);\">\n <esp-button id=\"start-circle-btn\" label=\"Start\" collapsed></esp-button>\n <esp-button id=\"reset-circle-btn\" label=\"Reset\" collapsed></esp-button>\n </div>\n </div>\n</esp-box>\n<script>\n const circleProgress = findById(\"demo-circle\");\n const startCircleBtn = findById(\"start-circle-btn\");\n const resetCircleBtn = findById(\"reset-circle-btn\");\n let circleRunning = false;\n startCircleBtn.addEventListener(\"esp-clicked\", () => {\n if (circleRunning) return;\n circleRunning = true;\n circleProgress.value = 0;\n const start = performance.now();\n const duration = 10000;\n function step(now) {\n const elapsed = now - start;\n circleProgress.value = Math.min((elapsed / duration) * 100, 100);\n if (elapsed < duration) {\n requestAnimationFrame(step);\n } else {\n circleRunning = false;\n showToast({ message: \"Complete!\", intent: \"success\", icon: \"bread\" });\n }\n }\n requestAnimationFrame(step);\n });\n resetCircleBtn.addEventListener(\"esp-clicked\", () => {\n circleRunning = false;\n circleProgress.value = 0;\n });\n</script>\n```",
63687
- "name": "EspalierProgress",
63688
- "cssProperties": [
63689
- {
63690
- "description": "Border color of the track outline. Defaults to `var(--esp-color-border)`.",
63691
- "name": "--esp-progress-border-color"
63692
- },
63693
- {
63694
- "description": "Border radius of the track and fill. Defaults to `var(--esp-size-border-radius)`.",
63695
- "name": "--esp-progress-border-radius"
63696
- },
63697
- {
63698
- "description": "Diameter of the circular progress ring in circle mode. Automatically set by the `size` attribute.",
63699
- "name": "--esp-progress-circle-size"
63700
- },
63701
- {
63702
- "description": "Color of the progress fill. Defaults to the active action hue at the semantic muted lightness so the filled and unfilled portions remain distinguishable in light and dark themes.",
63703
- "name": "--esp-progress-fill-color"
63704
- },
63705
- {
63706
- "description": "Font size for the value text. Defaults to `var(--esp-type-small)`.",
63707
- "name": "--esp-progress-font-size"
63708
- },
63709
- {
63710
- "description": "Height of the progress bar track. Automatically set by the `size` attribute.",
63711
- "name": "--esp-progress-height"
63712
- },
63739
+ "description": "Groups multiple [esp-radio-button](/components/radio-button)\ncomponents and ensures only one can be selected at a time.\nWorks with [esp-form-item](/components/form-item) for label\nand error message integration.\n\n```html\n<esp-box>\n <esp-form-item label=\"Choose a size\">\n <esp-radio-button-group>\n <esp-radio-button value=\"small\">Small</esp-radio-button>\n <esp-radio-button value=\"medium\" checked>Medium</esp-radio-button>\n <esp-radio-button value=\"large\">Large</esp-radio-button>\n </esp-radio-button-group>\n </esp-form-item>\n</esp-box>\n```\n\n```html\n<esp-box>\n <esp-form-item label=\"Disabled group\">\n <esp-radio-button-group disabled>\n <esp-radio-button value=\"a\">Option A</esp-radio-button>\n <esp-radio-button value=\"b\" checked>Option B</esp-radio-button>\n <esp-radio-button value=\"c\">Option C</esp-radio-button>\n </esp-radio-button-group>\n </esp-form-item>\n</esp-box>\n```",
63740
+ "name": "EspalierRadioButtonGroup",
63741
+ "slots": [
63713
63742
  {
63714
- "description": "Color of the percentage text in both bar and circle modes. Defaults to `var(--esp-color-text)`.",
63715
- "name": "--esp-progress-text-color"
63716
- },
63743
+ "description": "Place `esp-radio-button` elements in the default slot.",
63744
+ "name": ""
63745
+ }
63746
+ ],
63747
+ "members": [
63717
63748
  {
63718
- "description": "Background color of the shared field shell. Defaults to `var(--esp-color-layer-2)`.",
63719
- "name": "--esp-field-background",
63720
- "inheritedFrom": {
63721
- "name": "EspalierElementBase",
63722
- "module": "dist/shared/esp-element-base.js"
63723
- }
63749
+ "kind": "field",
63750
+ "name": "formAssociated",
63751
+ "type": {
63752
+ "text": "boolean"
63753
+ },
63754
+ "static": true,
63755
+ "default": "true"
63724
63756
  },
63725
63757
  {
63726
- "description": "Border color of the shared field shell. Defaults to `var(--esp-color-border)`.",
63727
- "name": "--esp-field-border-color",
63728
- "inheritedFrom": {
63729
- "name": "EspalierElementBase",
63730
- "module": "dist/shared/esp-element-base.js"
63731
- }
63758
+ "kind": "field",
63759
+ "name": "internals",
63760
+ "privacy": "private"
63732
63761
  },
63733
63762
  {
63734
- "description": "Border width of the shared field shell. Defaults to `1px`.",
63735
- "name": "--esp-field-border-width",
63736
- "inheritedFrom": {
63737
- "name": "EspalierElementBase",
63738
- "module": "dist/shared/esp-element-base.js"
63739
- }
63763
+ "kind": "field",
63764
+ "name": "formCtrl",
63765
+ "privacy": "private",
63766
+ "default": "new FormFieldController({ host: this, internals: this.internals, getFormValue: () => this.value || null, getValidity: () => { if (this.required && !this.value) { return { flags: { valueMissing: true }, message: this.requiredMessage || \"Please select an option.\", }; } return null; }, onReset: () => { for (const rb of this.getRadioButtons()) { rb.checked = false; } }, onRestore: (state: string) => { for (const rb of this.getRadioButtons()) { rb.checked = rb.value === state; } }, onDisabled: (isDisabled: boolean) => { this.disabled = isDisabled; }, })"
63740
63767
  },
63741
63768
  {
63742
- "description": "Text color used inside the shared field shell. Defaults to `var(--esp-color-text)`.",
63743
- "name": "--esp-field-text-color",
63744
- "inheritedFrom": {
63745
- "name": "EspalierElementBase",
63746
- "module": "dist/shared/esp-element-base.js"
63747
- }
63769
+ "kind": "field",
63770
+ "name": "itemsSlot",
63771
+ "privacy": "private"
63748
63772
  },
63749
63773
  {
63750
- "description": "Hover background color of the shared field shell. Derived from `--esp-field-background`.",
63751
- "name": "--esp-field-hover-bg",
63752
- "inheritedFrom": {
63753
- "name": "EspalierElementBase",
63754
- "module": "dist/shared/esp-element-base.js"
63755
- }
63774
+ "kind": "field",
63775
+ "name": "formItemDescription",
63776
+ "type": {
63777
+ "text": "string | null"
63778
+ },
63779
+ "privacy": "private",
63780
+ "default": "null"
63756
63781
  },
63757
63782
  {
63758
- "description": "Focus background color of the shared field shell. Derived from `--esp-field-background`.",
63759
- "name": "--esp-field-focus-bg",
63760
- "inheritedFrom": {
63761
- "name": "EspalierElementBase",
63762
- "module": "dist/shared/esp-element-base.js"
63763
- }
63783
+ "kind": "field",
63784
+ "name": "describedRadios",
63785
+ "privacy": "private",
63786
+ "default": "new Set<EspalierRadioButton>()"
63764
63787
  },
63765
- {
63766
- "description": "Shadow color used for shared field focus treatment. Defaults to `var(--esp-color-shadow)`.",
63767
- "name": "--esp-field-focus-shadow",
63768
- "inheritedFrom": {
63769
- "name": "EspalierElementBase",
63770
- "module": "dist/shared/esp-element-base.js"
63771
- }
63772
- }
63773
- ],
63774
- "members": [
63775
63788
  {
63776
63789
  "kind": "field",
63777
- "name": "value",
63790
+ "name": "name",
63778
63791
  "type": {
63779
- "text": "number | null"
63792
+ "text": "string"
63780
63793
  },
63781
63794
  "privacy": "public",
63782
- "default": "null",
63783
- "description": "The current progress value. Set to `null` (or omit) for\nindeterminate mode. Values are clamped to `0..max`.",
63784
- "attribute": "value"
63795
+ "default": "\"\"",
63796
+ "description": "The name used when the group participates in a `<form>`.",
63797
+ "attribute": "name",
63798
+ "reflects": true
63785
63799
  },
63786
63800
  {
63787
63801
  "kind": "field",
63788
- "name": "max",
63802
+ "name": "required",
63789
63803
  "type": {
63790
- "text": "number"
63804
+ "text": "boolean"
63791
63805
  },
63792
63806
  "privacy": "public",
63793
- "default": "100",
63794
- "description": "The maximum value. Defaults to `100`.",
63795
- "attribute": "max"
63807
+ "default": "false",
63808
+ "description": "When true, one radio button must be selected before the\nform can be submitted.",
63809
+ "attribute": "required",
63810
+ "reflects": true
63796
63811
  },
63797
63812
  {
63798
63813
  "kind": "field",
63799
- "name": "label",
63814
+ "name": "requiredMessage",
63800
63815
  "type": {
63801
63816
  "text": "string"
63802
63817
  },
63803
63818
  "privacy": "public",
63804
63819
  "default": "\"\"",
63805
- "description": "An accessible label describing what the progress bar\nrepresents. Required for screen readers.",
63806
- "attribute": "label"
63820
+ "description": "A custom message to display when the group is required but no\nradio button is selected. Defaults to\n`\"Please select an option.\"` when not set.",
63821
+ "attribute": "required-message"
63807
63822
  },
63808
63823
  {
63809
63824
  "kind": "field",
63810
- "name": "showValue",
63825
+ "name": "disabled",
63811
63826
  "type": {
63812
63827
  "text": "boolean"
63813
63828
  },
63814
63829
  "privacy": "public",
63815
63830
  "default": "false",
63816
- "description": "Show the percentage value as text. In bar mode the text\nappears below the track; in circle mode it appears in the\ncenter of the ring.",
63817
- "attribute": "show-value"
63831
+ "description": "Disables all child radio buttons in the group.",
63832
+ "attribute": "disabled",
63833
+ "reflects": true
63818
63834
  },
63819
63835
  {
63820
63836
  "kind": "field",
63821
- "name": "size",
63837
+ "name": "value",
63822
63838
  "type": {
63823
- "text": "\"small\" | \"medium\" | \"large\""
63839
+ "text": "string"
63824
63840
  },
63825
63841
  "privacy": "public",
63826
- "default": "\"medium\"",
63827
- "description": "Size preset for the progress indicator.\n\nIn bar mode:\n- `small` — 6px\n- `medium` — 12px (default)\n- `large` — 20px\n\nIn circle mode:\n- `small` — 48px diameter\n- `medium` — 80px diameter (default)\n- `large` — 120px diameter",
63828
- "attribute": "size",
63829
- "reflects": true
63842
+ "description": "Returns the value of the currently selected radio button,\nor an empty string if none is selected.",
63843
+ "readonly": true
63830
63844
  },
63831
63845
  {
63832
- "kind": "field",
63833
- "name": "mode",
63834
- "type": {
63835
- "text": "\"bar\" | \"circle\""
63846
+ "kind": "method",
63847
+ "name": "focus",
63848
+ "privacy": "public",
63849
+ "return": {
63850
+ "type": {
63851
+ "text": "void"
63852
+ }
63836
63853
  },
63854
+ "parameters": [
63855
+ {
63856
+ "name": "options",
63857
+ "optional": true,
63858
+ "type": {
63859
+ "text": "FocusOptions"
63860
+ }
63861
+ }
63862
+ ],
63863
+ "description": "Focus the checked radio button, or the first non-disabled\nradio button if none is checked."
63864
+ },
63865
+ {
63866
+ "kind": "method",
63867
+ "name": "validate",
63837
63868
  "privacy": "public",
63838
- "default": "\"bar\"",
63839
- "description": "Display mode for the progress indicator.\n\n- `bar` — linear progress bar (default)\n- `circle` — circular SVG ring",
63840
- "attribute": "mode",
63841
- "reflects": true
63869
+ "return": {
63870
+ "type": {
63871
+ "text": "void"
63872
+ }
63873
+ },
63874
+ "description": "Re-run constraint validation and dispatch `esp-validity-changed`."
63842
63875
  },
63843
63876
  {
63844
- "kind": "field",
63845
- "name": "isIndeterminate",
63846
- "type": {
63847
- "text": "boolean"
63877
+ "kind": "method",
63878
+ "name": "checkValidity",
63879
+ "privacy": "public",
63880
+ "return": {
63881
+ "type": {
63882
+ "text": "boolean"
63883
+ }
63848
63884
  },
63885
+ "description": "Check whether the current state is valid (delegates to ElementInternals)."
63886
+ },
63887
+ {
63888
+ "kind": "method",
63889
+ "name": "getRadioButtons",
63849
63890
  "privacy": "private",
63850
- "readonly": true
63891
+ "return": {
63892
+ "type": {
63893
+ "text": "EspalierRadioButton[]"
63894
+ }
63895
+ }
63851
63896
  },
63852
63897
  {
63853
- "kind": "field",
63854
- "name": "clampedValue",
63855
- "type": {
63856
- "text": "number"
63857
- },
63898
+ "kind": "method",
63899
+ "name": "applyDisabledState",
63858
63900
  "privacy": "private",
63859
- "readonly": true
63901
+ "return": {
63902
+ "type": {
63903
+ "text": "void"
63904
+ }
63905
+ }
63906
+ },
63907
+ {
63908
+ "kind": "method",
63909
+ "name": "applyFormItemDescription",
63910
+ "privacy": "private",
63911
+ "return": {
63912
+ "type": {
63913
+ "text": "void"
63914
+ }
63915
+ }
63860
63916
  },
63861
63917
  {
63862
63918
  "kind": "field",
63863
- "name": "percentage",
63864
- "type": {
63865
- "text": "number"
63919
+ "name": "handleItemsSlotChange",
63920
+ "privacy": "private"
63921
+ },
63922
+ {
63923
+ "kind": "method",
63924
+ "name": "handleChildChanged",
63925
+ "privacy": "private",
63926
+ "return": {
63927
+ "type": {
63928
+ "text": "void"
63929
+ }
63866
63930
  },
63931
+ "parameters": [
63932
+ {
63933
+ "name": "ev",
63934
+ "type": {
63935
+ "text": "Event"
63936
+ }
63937
+ }
63938
+ ]
63939
+ },
63940
+ {
63941
+ "kind": "method",
63942
+ "name": "handleKeyDown",
63867
63943
  "privacy": "private",
63868
- "readonly": true
63944
+ "return": {
63945
+ "type": {
63946
+ "text": "void"
63947
+ }
63948
+ },
63949
+ "parameters": [
63950
+ {
63951
+ "name": "ev",
63952
+ "type": {
63953
+ "text": "KeyboardEvent"
63954
+ }
63955
+ }
63956
+ ]
63869
63957
  },
63870
63958
  {
63871
63959
  "kind": "method",
63872
- "name": "renderBar",
63873
- "privacy": "private"
63960
+ "name": "formResetCallback",
63961
+ "return": {
63962
+ "type": {
63963
+ "text": "void"
63964
+ }
63965
+ },
63966
+ "description": "Called by the browser when the owning `<form>` is reset."
63874
63967
  },
63875
63968
  {
63876
63969
  "kind": "method",
63877
- "name": "renderCircle",
63878
- "privacy": "private"
63970
+ "name": "formStateRestoreCallback",
63971
+ "return": {
63972
+ "type": {
63973
+ "text": "void"
63974
+ }
63975
+ },
63976
+ "parameters": [
63977
+ {
63978
+ "name": "state",
63979
+ "type": {
63980
+ "text": "string"
63981
+ }
63982
+ }
63983
+ ],
63984
+ "description": "Called by the browser to restore form state (bfcache, etc.)."
63985
+ },
63986
+ {
63987
+ "kind": "method",
63988
+ "name": "formDisabledCallback",
63989
+ "return": {
63990
+ "type": {
63991
+ "text": "void"
63992
+ }
63993
+ },
63994
+ "parameters": [
63995
+ {
63996
+ "name": "isDisabled",
63997
+ "type": {
63998
+ "text": "boolean"
63999
+ }
64000
+ }
64001
+ ],
64002
+ "description": "Called by the browser when a parent `<fieldset>` is enabled or disabled."
63879
64003
  },
63880
64004
  {
63881
64005
  "kind": "field",
@@ -64602,60 +64726,58 @@
64602
64726
  }
64603
64727
  }
64604
64728
  ],
64605
- "attributes": [
64729
+ "events": [
64606
64730
  {
64607
- "name": "value",
64608
64731
  "type": {
64609
- "text": "number | null"
64732
+ "text": "CustomEvent<string>"
64610
64733
  },
64611
- "default": "null",
64612
- "description": "The current progress value. Set to `null` (or omit) for\nindeterminate mode. Values are clamped to `0..max`.",
64613
- "fieldName": "value"
64734
+ "description": "Fired when the selected radio button changes. The detail is the value of the newly selected radio button.",
64735
+ "name": "esp-value-changed"
64614
64736
  },
64615
64737
  {
64616
- "name": "max",
64617
64738
  "type": {
64618
- "text": "number"
64739
+ "text": "CustomEvent<{ valid: boolean; message: string }>"
64619
64740
  },
64620
- "default": "100",
64621
- "description": "The maximum value. Defaults to `100`.",
64622
- "fieldName": "max"
64623
- },
64741
+ "description": "Fired whenever constraint validation runs.",
64742
+ "name": "esp-validity-changed"
64743
+ }
64744
+ ],
64745
+ "attributes": [
64624
64746
  {
64625
- "name": "label",
64747
+ "name": "name",
64626
64748
  "type": {
64627
64749
  "text": "string"
64628
64750
  },
64629
64751
  "default": "\"\"",
64630
- "description": "An accessible label describing what the progress bar\nrepresents. Required for screen readers.",
64631
- "fieldName": "label"
64752
+ "description": "The name used when the group participates in a `<form>`.",
64753
+ "fieldName": "name"
64632
64754
  },
64633
64755
  {
64634
- "name": "show-value",
64756
+ "name": "required",
64635
64757
  "type": {
64636
64758
  "text": "boolean"
64637
64759
  },
64638
64760
  "default": "false",
64639
- "description": "Show the percentage value as text. In bar mode the text\nappears below the track; in circle mode it appears in the\ncenter of the ring.",
64640
- "fieldName": "showValue"
64761
+ "description": "When true, one radio button must be selected before the\nform can be submitted.",
64762
+ "fieldName": "required"
64641
64763
  },
64642
64764
  {
64643
- "name": "size",
64765
+ "name": "required-message",
64644
64766
  "type": {
64645
- "text": "\"small\" | \"medium\" | \"large\""
64767
+ "text": "string"
64646
64768
  },
64647
- "default": "\"medium\"",
64648
- "description": "Size preset for the progress indicator.\n\nIn bar mode:\n- `small` 6px\n- `medium` — 12px (default)\n- `large` 20px\n\nIn circle mode:\n- `small` — 48px diameter\n- `medium` 80px diameter (default)\n- `large` 120px diameter",
64649
- "fieldName": "size"
64769
+ "default": "\"\"",
64770
+ "description": "A custom message to display when the group is required but no\nradio button is selected. Defaults to\n`\"Please select an option.\"` when not set.",
64771
+ "fieldName": "requiredMessage"
64650
64772
  },
64651
64773
  {
64652
- "name": "mode",
64774
+ "name": "disabled",
64653
64775
  "type": {
64654
- "text": "\"bar\" | \"circle\""
64776
+ "text": "boolean"
64655
64777
  },
64656
- "default": "\"bar\"",
64657
- "description": "Display mode for the progress indicator.\n\n- `bar` — linear progress bar (default)\n- `circle` — circular SVG ring",
64658
- "fieldName": "mode"
64778
+ "default": "false",
64779
+ "description": "Disables all child radio buttons in the group.",
64780
+ "fieldName": "disabled"
64659
64781
  },
64660
64782
  {
64661
64783
  "name": "scheme",
@@ -64700,142 +64822,211 @@
64700
64822
  "module": "dist/shared/esp-element-base.js"
64701
64823
  },
64702
64824
  "docPageTitle": {
64703
- "name": "Progress",
64704
- "description": ""
64825
+ "name": "Radio",
64826
+ "description": "Button Group"
64705
64827
  },
64706
64828
  "docUrl": {
64707
- "name": "/components/progress",
64829
+ "name": "/components/radio-button/group",
64708
64830
  "description": ""
64709
64831
  },
64710
64832
  "menuGroup": {
64711
- "name": "Feedback",
64712
- "description": ""
64713
- },
64714
- "menuLabel": {
64715
- "name": "Progress",
64716
- "description": ""
64717
- },
64718
- "menuIcon": {
64719
- "name": "progress",
64720
- "description": ""
64833
+ "name": "Form",
64834
+ "description": "Controls"
64721
64835
  },
64722
- "tagName": "esp-progress",
64836
+ "tagName": "esp-radio-button-group",
64723
64837
  "customElement": true,
64724
- "events": []
64725
- },
64726
- {
64727
- "kind": "variable",
64728
- "name": "indeterminate"
64838
+ "cssProperties": [
64839
+ {
64840
+ "description": "Background color of the shared field shell. Defaults to `var(--esp-color-layer-2)`.",
64841
+ "name": "--esp-field-background",
64842
+ "inheritedFrom": {
64843
+ "name": "EspalierElementBase",
64844
+ "module": "dist/shared/esp-element-base.js"
64845
+ }
64846
+ },
64847
+ {
64848
+ "description": "Border color of the shared field shell. Defaults to `var(--esp-color-border)`.",
64849
+ "name": "--esp-field-border-color",
64850
+ "inheritedFrom": {
64851
+ "name": "EspalierElementBase",
64852
+ "module": "dist/shared/esp-element-base.js"
64853
+ }
64854
+ },
64855
+ {
64856
+ "description": "Border width of the shared field shell. Defaults to `1px`.",
64857
+ "name": "--esp-field-border-width",
64858
+ "inheritedFrom": {
64859
+ "name": "EspalierElementBase",
64860
+ "module": "dist/shared/esp-element-base.js"
64861
+ }
64862
+ },
64863
+ {
64864
+ "description": "Text color used inside the shared field shell. Defaults to `var(--esp-color-text)`.",
64865
+ "name": "--esp-field-text-color",
64866
+ "inheritedFrom": {
64867
+ "name": "EspalierElementBase",
64868
+ "module": "dist/shared/esp-element-base.js"
64869
+ }
64870
+ },
64871
+ {
64872
+ "description": "Hover background color of the shared field shell. Derived from `--esp-field-background`.",
64873
+ "name": "--esp-field-hover-bg",
64874
+ "inheritedFrom": {
64875
+ "name": "EspalierElementBase",
64876
+ "module": "dist/shared/esp-element-base.js"
64877
+ }
64878
+ },
64879
+ {
64880
+ "description": "Focus background color of the shared field shell. Derived from `--esp-field-background`.",
64881
+ "name": "--esp-field-focus-bg",
64882
+ "inheritedFrom": {
64883
+ "name": "EspalierElementBase",
64884
+ "module": "dist/shared/esp-element-base.js"
64885
+ }
64886
+ },
64887
+ {
64888
+ "description": "Shadow color used for shared field focus treatment. Defaults to `var(--esp-color-shadow)`.",
64889
+ "name": "--esp-field-focus-shadow",
64890
+ "inheritedFrom": {
64891
+ "name": "EspalierElementBase",
64892
+ "module": "dist/shared/esp-element-base.js"
64893
+ }
64894
+ }
64895
+ ]
64729
64896
  }
64730
64897
  ],
64731
64898
  "exports": [
64732
64899
  {
64733
64900
  "kind": "js",
64734
- "name": "EspalierProgress",
64901
+ "name": "EspalierRadioButtonGroup",
64735
64902
  "declaration": {
64736
- "name": "EspalierProgress",
64737
- "module": "dist/progress/esp-progress.js"
64903
+ "name": "EspalierRadioButtonGroup",
64904
+ "module": "dist/radio-button/esp-radio-button-group.js"
64738
64905
  }
64739
64906
  },
64740
64907
  {
64741
64908
  "kind": "custom-element-definition",
64742
- "name": "esp-progress",
64909
+ "name": "esp-radio-button-group",
64743
64910
  "declaration": {
64744
- "name": "EspalierProgress",
64745
- "module": "dist/progress/esp-progress.js"
64911
+ "name": "EspalierRadioButtonGroup",
64912
+ "module": "dist/radio-button/esp-radio-button-group.js"
64746
64913
  }
64747
64914
  }
64748
64915
  ]
64749
64916
  },
64750
64917
  {
64751
64918
  "kind": "javascript-module",
64752
- "path": "dist/radio-button/esp-radio-button-group.js",
64919
+ "path": "dist/radio-button/esp-radio-button.js",
64753
64920
  "declarations": [
64754
64921
  {
64755
64922
  "kind": "class",
64756
- "description": "Groups multiple [esp-radio-button](/components/radio-button)\ncomponents and ensures only one can be selected at a time.\nWorks with [esp-form-item](/components/form-item) for label\nand error message integration.\n\n```html\n<esp-box>\n <esp-form-item label=\"Choose a size\">\n <esp-radio-button-group>\n <esp-radio-button value=\"small\">Small</esp-radio-button>\n <esp-radio-button value=\"medium\" checked>Medium</esp-radio-button>\n <esp-radio-button value=\"large\">Large</esp-radio-button>\n </esp-radio-button-group>\n </esp-form-item>\n</esp-box>\n```\n\n```html\n<esp-box>\n <esp-form-item label=\"Disabled group\">\n <esp-radio-button-group disabled>\n <esp-radio-button value=\"a\">Option A</esp-radio-button>\n <esp-radio-button value=\"b\" checked>Option B</esp-radio-button>\n <esp-radio-button value=\"c\">Option C</esp-radio-button>\n </esp-radio-button-group>\n </esp-form-item>\n</esp-box>\n```",
64757
- "name": "EspalierRadioButtonGroup",
64758
- "slots": [
64923
+ "description": "A radio button control for choosing one option from a set.\nUses Tabler SVG icons for selected and unselected states.\nShould be used inside an\n[esp-radio-button-group](/components/radio-button/group)\nfor single-select behavior.\n\n```html\n<esp-box>\n <esp-form-item label=\"Favorite color\">\n <esp-radio-button-group>\n <esp-radio-button value=\"red\">Red</esp-radio-button>\n <esp-radio-button value=\"green\">Green</esp-radio-button>\n <esp-radio-button value=\"blue\">Blue</esp-radio-button>\n </esp-radio-button-group>\n </esp-form-item>\n</esp-box>\n```\n\n```html\n<esp-box>\n <esp-radio-button-group>\n <esp-radio-button checked value=\"small\">Small</esp-radio-button>\n <esp-radio-button value=\"medium\">Medium</esp-radio-button>\n <esp-radio-button disabled value=\"large\">Large</esp-radio-button>\n </esp-radio-button-group>\n</esp-box>\n```",
64924
+ "name": "EspalierRadioButton",
64925
+ "cssProperties": [
64759
64926
  {
64760
- "description": "Place `esp-radio-button` elements in the default slot.",
64761
- "name": ""
64762
- }
64763
- ],
64764
- "members": [
64927
+ "description": "The width and height of the radio icon. Defaults to `var(--esp-size-normal-to-medium)`.",
64928
+ "name": "--esp-radio-button-size"
64929
+ },
64765
64930
  {
64766
- "kind": "field",
64767
- "name": "formAssociated",
64768
- "type": {
64769
- "text": "boolean"
64770
- },
64771
- "static": true,
64772
- "default": "true"
64931
+ "description": "The stroke color of the radio icon. Defaults to `var(--esp-color-text)`.",
64932
+ "name": "--esp-radio-button-icon-color"
64773
64933
  },
64774
64934
  {
64775
- "kind": "field",
64776
- "name": "internals",
64777
- "privacy": "private"
64935
+ "description": "The color of the focus ring shadow. Defaults to `var(--esp-color-shadow)`.",
64936
+ "name": "--esp-radio-button-focus-shadow"
64778
64937
  },
64779
64938
  {
64780
- "kind": "field",
64781
- "name": "formCtrl",
64782
- "privacy": "private",
64783
- "default": "new FormFieldController({ host: this, internals: this.internals, getFormValue: () => this.value || null, getValidity: () => { if (this.required && !this.value) { return { flags: { valueMissing: true }, message: this.requiredMessage || \"Please select an option.\", }; } return null; }, onReset: () => { for (const rb of this.getRadioButtons()) { rb.checked = false; } }, onRestore: (state: string) => { for (const rb of this.getRadioButtons()) { rb.checked = rb.value === state; } }, onDisabled: (isDisabled: boolean) => { this.disabled = isDisabled; }, })"
64939
+ "description": "Background color of the shared field shell. Defaults to `var(--esp-color-layer-2)`.",
64940
+ "name": "--esp-field-background",
64941
+ "inheritedFrom": {
64942
+ "name": "EspalierElementBase",
64943
+ "module": "dist/shared/esp-element-base.js"
64944
+ }
64784
64945
  },
64785
64946
  {
64786
- "kind": "field",
64787
- "name": "itemsSlot",
64788
- "privacy": "private"
64947
+ "description": "Border color of the shared field shell. Defaults to `var(--esp-color-border)`.",
64948
+ "name": "--esp-field-border-color",
64949
+ "inheritedFrom": {
64950
+ "name": "EspalierElementBase",
64951
+ "module": "dist/shared/esp-element-base.js"
64952
+ }
64789
64953
  },
64790
64954
  {
64791
- "kind": "field",
64792
- "name": "formItemDescription",
64793
- "type": {
64794
- "text": "string | null"
64795
- },
64796
- "privacy": "private",
64797
- "default": "null"
64955
+ "description": "Border width of the shared field shell. Defaults to `1px`.",
64956
+ "name": "--esp-field-border-width",
64957
+ "inheritedFrom": {
64958
+ "name": "EspalierElementBase",
64959
+ "module": "dist/shared/esp-element-base.js"
64960
+ }
64798
64961
  },
64799
64962
  {
64800
- "kind": "field",
64801
- "name": "describedRadios",
64802
- "privacy": "private",
64803
- "default": "new Set<EspalierRadioButton>()"
64963
+ "description": "Text color used inside the shared field shell. Defaults to `var(--esp-color-text)`.",
64964
+ "name": "--esp-field-text-color",
64965
+ "inheritedFrom": {
64966
+ "name": "EspalierElementBase",
64967
+ "module": "dist/shared/esp-element-base.js"
64968
+ }
64804
64969
  },
64970
+ {
64971
+ "description": "Hover background color of the shared field shell. Derived from `--esp-field-background`.",
64972
+ "name": "--esp-field-hover-bg",
64973
+ "inheritedFrom": {
64974
+ "name": "EspalierElementBase",
64975
+ "module": "dist/shared/esp-element-base.js"
64976
+ }
64977
+ },
64978
+ {
64979
+ "description": "Focus background color of the shared field shell. Derived from `--esp-field-background`.",
64980
+ "name": "--esp-field-focus-bg",
64981
+ "inheritedFrom": {
64982
+ "name": "EspalierElementBase",
64983
+ "module": "dist/shared/esp-element-base.js"
64984
+ }
64985
+ },
64986
+ {
64987
+ "description": "Shadow color used for shared field focus treatment. Defaults to `var(--esp-color-shadow)`.",
64988
+ "name": "--esp-field-focus-shadow",
64989
+ "inheritedFrom": {
64990
+ "name": "EspalierElementBase",
64991
+ "module": "dist/shared/esp-element-base.js"
64992
+ }
64993
+ }
64994
+ ],
64995
+ "slots": [
64996
+ {
64997
+ "description": "The label text for the radio button.",
64998
+ "name": ""
64999
+ }
65000
+ ],
65001
+ "members": [
64805
65002
  {
64806
65003
  "kind": "field",
64807
- "name": "name",
64808
- "type": {
64809
- "text": "string"
64810
- },
64811
- "privacy": "public",
64812
- "default": "\"\"",
64813
- "description": "The name used when the group participates in a `<form>`.",
64814
- "attribute": "name",
64815
- "reflects": true
65004
+ "name": "formItemDescription",
65005
+ "privacy": "private",
65006
+ "default": "new FormFieldDescriptionController({ host: this, getTarget: () => this.shadowRoot?.querySelector<HTMLElement>(\".radio-control\"), })"
64816
65007
  },
64817
65008
  {
64818
65009
  "kind": "field",
64819
- "name": "required",
65010
+ "name": "checked",
64820
65011
  "type": {
64821
65012
  "text": "boolean"
64822
65013
  },
64823
65014
  "privacy": "public",
64824
65015
  "default": "false",
64825
- "description": "When true, one radio button must be selected before the\nform can be submitted.",
64826
- "attribute": "required",
65016
+ "description": "Whether the radio button is in the selected state.",
65017
+ "attribute": "checked",
64827
65018
  "reflects": true
64828
65019
  },
64829
65020
  {
64830
65021
  "kind": "field",
64831
- "name": "requiredMessage",
65022
+ "name": "value",
64832
65023
  "type": {
64833
65024
  "text": "string"
64834
65025
  },
64835
65026
  "privacy": "public",
64836
65027
  "default": "\"\"",
64837
- "description": "A custom message to display when the group is required but no\nradio button is selected. Defaults to\n`\"Please select an option.\"` when not set.",
64838
- "attribute": "required-message"
65028
+ "description": "The value associated with this radio button. Used by\n[esp-radio-button-group](/components/radio-button/group) to\ntrack which option is selected.",
65029
+ "attribute": "value"
64839
65030
  },
64840
65031
  {
64841
65032
  "kind": "field",
@@ -64845,20 +65036,10 @@
64845
65036
  },
64846
65037
  "privacy": "public",
64847
65038
  "default": "false",
64848
- "description": "Disables all child radio buttons in the group.",
65039
+ "description": "Controls whether the radio button is disabled.",
64849
65040
  "attribute": "disabled",
64850
65041
  "reflects": true
64851
65042
  },
64852
- {
64853
- "kind": "field",
64854
- "name": "value",
64855
- "type": {
64856
- "text": "string"
64857
- },
64858
- "privacy": "public",
64859
- "description": "Returns the value of the currently selected radio button,\nor an empty string if none is selected.",
64860
- "readonly": true
64861
- },
64862
65043
  {
64863
65044
  "kind": "method",
64864
65045
  "name": "focus",
@@ -64877,53 +65058,11 @@
64877
65058
  }
64878
65059
  }
64879
65060
  ],
64880
- "description": "Focus the checked radio button, or the first non-disabled\nradio button if none is checked."
64881
- },
64882
- {
64883
- "kind": "method",
64884
- "name": "validate",
64885
- "privacy": "public",
64886
- "return": {
64887
- "type": {
64888
- "text": "void"
64889
- }
64890
- },
64891
- "description": "Re-run constraint validation and dispatch `esp-validity-changed`."
64892
- },
64893
- {
64894
- "kind": "method",
64895
- "name": "checkValidity",
64896
- "privacy": "public",
64897
- "return": {
64898
- "type": {
64899
- "text": "boolean"
64900
- }
64901
- },
64902
- "description": "Check whether the current state is valid (delegates to ElementInternals)."
64903
- },
64904
- {
64905
- "kind": "method",
64906
- "name": "getRadioButtons",
64907
- "privacy": "private",
64908
- "return": {
64909
- "type": {
64910
- "text": "EspalierRadioButton[]"
64911
- }
64912
- }
64913
- },
64914
- {
64915
- "kind": "method",
64916
- "name": "applyDisabledState",
64917
- "privacy": "private",
64918
- "return": {
64919
- "type": {
64920
- "text": "void"
64921
- }
64922
- }
65061
+ "description": "Focus the radio button control."
64923
65062
  },
64924
65063
  {
64925
65064
  "kind": "method",
64926
- "name": "applyFormItemDescription",
65065
+ "name": "select",
64927
65066
  "privacy": "private",
64928
65067
  "return": {
64929
65068
  "type": {
@@ -64931,29 +65070,6 @@
64931
65070
  }
64932
65071
  }
64933
65072
  },
64934
- {
64935
- "kind": "field",
64936
- "name": "handleItemsSlotChange",
64937
- "privacy": "private"
64938
- },
64939
- {
64940
- "kind": "method",
64941
- "name": "handleChildChanged",
64942
- "privacy": "private",
64943
- "return": {
64944
- "type": {
64945
- "text": "void"
64946
- }
64947
- },
64948
- "parameters": [
64949
- {
64950
- "name": "ev",
64951
- "type": {
64952
- "text": "Event"
64953
- }
64954
- }
64955
- ]
64956
- },
64957
65073
  {
64958
65074
  "kind": "method",
64959
65075
  "name": "handleKeyDown",
@@ -64972,52 +65088,6 @@
64972
65088
  }
64973
65089
  ]
64974
65090
  },
64975
- {
64976
- "kind": "method",
64977
- "name": "formResetCallback",
64978
- "return": {
64979
- "type": {
64980
- "text": "void"
64981
- }
64982
- },
64983
- "description": "Called by the browser when the owning `<form>` is reset."
64984
- },
64985
- {
64986
- "kind": "method",
64987
- "name": "formStateRestoreCallback",
64988
- "return": {
64989
- "type": {
64990
- "text": "void"
64991
- }
64992
- },
64993
- "parameters": [
64994
- {
64995
- "name": "state",
64996
- "type": {
64997
- "text": "string"
64998
- }
64999
- }
65000
- ],
65001
- "description": "Called by the browser to restore form state (bfcache, etc.)."
65002
- },
65003
- {
65004
- "kind": "method",
65005
- "name": "formDisabledCallback",
65006
- "return": {
65007
- "type": {
65008
- "text": "void"
65009
- }
65010
- },
65011
- "parameters": [
65012
- {
65013
- "name": "isDisabled",
65014
- "type": {
65015
- "text": "boolean"
65016
- }
65017
- }
65018
- ],
65019
- "description": "Called by the browser when a parent `<fieldset>` is enabled or disabled."
65020
- },
65021
65091
  {
65022
65092
  "kind": "field",
65023
65093
  "name": "seedColorBacker",
@@ -65746,46 +65816,30 @@
65746
65816
  "events": [
65747
65817
  {
65748
65818
  "type": {
65749
- "text": "CustomEvent<string>"
65819
+ "text": "CustomEvent<{ checked: boolean; value: string }>"
65750
65820
  },
65751
- "description": "Fired when the selected radio button changes. The detail is the value of the newly selected radio button.",
65821
+ "description": "Fired when the radio button is selected. The detail contains the new `checked` state and the radio button `value`.",
65752
65822
  "name": "esp-value-changed"
65753
- },
65754
- {
65755
- "type": {
65756
- "text": "CustomEvent<{ valid: boolean; message: string }>"
65757
- },
65758
- "description": "Fired whenever constraint validation runs.",
65759
- "name": "esp-validity-changed"
65760
65823
  }
65761
65824
  ],
65762
65825
  "attributes": [
65763
65826
  {
65764
- "name": "name",
65765
- "type": {
65766
- "text": "string"
65767
- },
65768
- "default": "\"\"",
65769
- "description": "The name used when the group participates in a `<form>`.",
65770
- "fieldName": "name"
65771
- },
65772
- {
65773
- "name": "required",
65827
+ "name": "checked",
65774
65828
  "type": {
65775
65829
  "text": "boolean"
65776
65830
  },
65777
65831
  "default": "false",
65778
- "description": "When true, one radio button must be selected before the\nform can be submitted.",
65779
- "fieldName": "required"
65832
+ "description": "Whether the radio button is in the selected state.",
65833
+ "fieldName": "checked"
65780
65834
  },
65781
65835
  {
65782
- "name": "required-message",
65836
+ "name": "value",
65783
65837
  "type": {
65784
65838
  "text": "string"
65785
65839
  },
65786
65840
  "default": "\"\"",
65787
- "description": "A custom message to display when the group is required but no\nradio button is selected. Defaults to\n`\"Please select an option.\"` when not set.",
65788
- "fieldName": "requiredMessage"
65841
+ "description": "The value associated with this radio button. Used by\n[esp-radio-button-group](/components/radio-button/group) to\ntrack which option is selected.",
65842
+ "fieldName": "value"
65789
65843
  },
65790
65844
  {
65791
65845
  "name": "disabled",
@@ -65793,7 +65847,7 @@
65793
65847
  "text": "boolean"
65794
65848
  },
65795
65849
  "default": "false",
65796
- "description": "Disables all child radio buttons in the group.",
65850
+ "description": "Controls whether the radio button is disabled.",
65797
65851
  "fieldName": "disabled"
65798
65852
  },
65799
65853
  {
@@ -65840,117 +65894,83 @@
65840
65894
  },
65841
65895
  "docPageTitle": {
65842
65896
  "name": "Radio",
65843
- "description": "Button Group"
65897
+ "description": "Button"
65844
65898
  },
65845
65899
  "docUrl": {
65846
- "name": "/components/radio-button/group",
65900
+ "name": "/components/radio-button",
65847
65901
  "description": ""
65848
65902
  },
65849
65903
  "menuGroup": {
65850
65904
  "name": "Form",
65851
65905
  "description": "Controls"
65852
65906
  },
65853
- "tagName": "esp-radio-button-group",
65854
- "customElement": true,
65855
- "cssProperties": [
65856
- {
65857
- "description": "Background color of the shared field shell. Defaults to `var(--esp-color-layer-2)`.",
65858
- "name": "--esp-field-background",
65859
- "inheritedFrom": {
65860
- "name": "EspalierElementBase",
65861
- "module": "dist/shared/esp-element-base.js"
65862
- }
65863
- },
65864
- {
65865
- "description": "Border color of the shared field shell. Defaults to `var(--esp-color-border)`.",
65866
- "name": "--esp-field-border-color",
65867
- "inheritedFrom": {
65868
- "name": "EspalierElementBase",
65869
- "module": "dist/shared/esp-element-base.js"
65870
- }
65871
- },
65872
- {
65873
- "description": "Border width of the shared field shell. Defaults to `1px`.",
65874
- "name": "--esp-field-border-width",
65875
- "inheritedFrom": {
65876
- "name": "EspalierElementBase",
65877
- "module": "dist/shared/esp-element-base.js"
65878
- }
65879
- },
65880
- {
65881
- "description": "Text color used inside the shared field shell. Defaults to `var(--esp-color-text)`.",
65882
- "name": "--esp-field-text-color",
65883
- "inheritedFrom": {
65884
- "name": "EspalierElementBase",
65885
- "module": "dist/shared/esp-element-base.js"
65886
- }
65887
- },
65888
- {
65889
- "description": "Hover background color of the shared field shell. Derived from `--esp-field-background`.",
65890
- "name": "--esp-field-hover-bg",
65891
- "inheritedFrom": {
65892
- "name": "EspalierElementBase",
65893
- "module": "dist/shared/esp-element-base.js"
65894
- }
65895
- },
65896
- {
65897
- "description": "Focus background color of the shared field shell. Derived from `--esp-field-background`.",
65898
- "name": "--esp-field-focus-bg",
65899
- "inheritedFrom": {
65900
- "name": "EspalierElementBase",
65901
- "module": "dist/shared/esp-element-base.js"
65902
- }
65903
- },
65904
- {
65905
- "description": "Shadow color used for shared field focus treatment. Defaults to `var(--esp-color-shadow)`.",
65906
- "name": "--esp-field-focus-shadow",
65907
- "inheritedFrom": {
65908
- "name": "EspalierElementBase",
65909
- "module": "dist/shared/esp-element-base.js"
65910
- }
65911
- }
65912
- ]
65907
+ "menuLabel": {
65908
+ "name": "Radio",
65909
+ "description": "Button"
65910
+ },
65911
+ "menuIcon": {
65912
+ "name": "circle-dot",
65913
+ "description": ""
65914
+ },
65915
+ "tagName": "esp-radio-button",
65916
+ "customElement": true
65913
65917
  }
65914
65918
  ],
65915
65919
  "exports": [
65916
65920
  {
65917
65921
  "kind": "js",
65918
- "name": "EspalierRadioButtonGroup",
65922
+ "name": "EspalierRadioButton",
65919
65923
  "declaration": {
65920
- "name": "EspalierRadioButtonGroup",
65921
- "module": "dist/radio-button/esp-radio-button-group.js"
65924
+ "name": "EspalierRadioButton",
65925
+ "module": "dist/radio-button/esp-radio-button.js"
65922
65926
  }
65923
65927
  },
65924
65928
  {
65925
65929
  "kind": "custom-element-definition",
65926
- "name": "esp-radio-button-group",
65930
+ "name": "esp-radio-button",
65927
65931
  "declaration": {
65928
- "name": "EspalierRadioButtonGroup",
65929
- "module": "dist/radio-button/esp-radio-button-group.js"
65932
+ "name": "EspalierRadioButton",
65933
+ "module": "dist/radio-button/esp-radio-button.js"
65930
65934
  }
65931
65935
  }
65932
65936
  ]
65933
65937
  },
65934
65938
  {
65935
65939
  "kind": "javascript-module",
65936
- "path": "dist/radio-button/esp-radio-button.js",
65940
+ "path": "dist/progress/esp-progress.js",
65937
65941
  "declarations": [
65938
65942
  {
65939
65943
  "kind": "class",
65940
- "description": "A radio button control for choosing one option from a set.\nUses Tabler SVG icons for selected and unselected states.\nShould be used inside an\n[esp-radio-button-group](/components/radio-button/group)\nfor single-select behavior.\n\n```html\n<esp-box>\n <esp-form-item label=\"Favorite color\">\n <esp-radio-button-group>\n <esp-radio-button value=\"red\">Red</esp-radio-button>\n <esp-radio-button value=\"green\">Green</esp-radio-button>\n <esp-radio-button value=\"blue\">Blue</esp-radio-button>\n </esp-radio-button-group>\n </esp-form-item>\n</esp-box>\n```\n\n```html\n<esp-box>\n <esp-radio-button-group>\n <esp-radio-button checked value=\"small\">Small</esp-radio-button>\n <esp-radio-button value=\"medium\">Medium</esp-radio-button>\n <esp-radio-button disabled value=\"large\">Large</esp-radio-button>\n </esp-radio-button-group>\n</esp-box>\n```",
65941
- "name": "EspalierRadioButton",
65944
+ "description": "A progress indicator that supports both determinate and\nindeterminate modes, rendered as a linear bar or a circle.\n\nIn **determinate** mode, set `value` and optionally `max` to\nshow a fill bar representing progress toward completion:\n\n```html\n<esp-progress value=\"42\" show-value label=\"Upload progress\"></esp-progress>\n```\n\nIn **indeterminate** mode (the default when no `value` is set),\nan animated bar communicates that work is happening\nwithout a known endpoint:\n\n```html\n<esp-progress label=\"Loading data...\"></esp-progress>\n```\n\nThe three size presets:\n\n```html\n<div style=\"display: grid; gap: var(--esp-size-small);\">\n <esp-progress value=\"60\" label=\"Small\" size=\"small\"></esp-progress>\n <esp-progress value=\"60\" label=\"Medium\" size=\"medium\"></esp-progress>\n <esp-progress value=\"60\" label=\"Large\" size=\"large\" show-value></esp-progress>\n</div>\n```\n\nIntent colors match the design system:\n\n```html\n<div style=\"display: grid; gap: var(--esp-size-padding);\">\n <esp-progress value=\"80\" label=\"Primary\" show-value></esp-progress>\n <esp-progress value=\"60\" label=\"Success\" intent=\"success\" show-value></esp-progress>\n <esp-progress value=\"40\" label=\"Warning\" intent=\"warning\" show-value></esp-progress>\n <esp-progress value=\"20\" label=\"Danger\" intent=\"danger\" show-value></esp-progress>\n</div>\n```\n\nClick the button to watch the progress bar fill over ten seconds:\n\n```html\n<esp-box>\n <esp-progress id=\"demo-progress\" value=\"0\" label=\"Demo progress\" intent=\"success\" size=\"large\" show-value></esp-progress>\n <div style=\"display: flex; gap: var(--esp-size-small); margin-top: var(--esp-size-small);\">\n <esp-button id=\"start-btn\" label=\"Start\" collapsed></esp-button>\n <esp-button id=\"reset-btn\" label=\"Reset\" collapsed></esp-button>\n </div>\n</esp-box>\n<script>\n const progress = findById(\"demo-progress\");\n const startBtn = findById(\"start-btn\");\n const resetBtn = findById(\"reset-btn\");\n let running = false;\n startBtn.addEventListener(\"esp-clicked\", () => {\n if (running) return;\n running = true;\n progress.value = 0;\n const start = performance.now();\n const duration = 10000;\n function step(now) {\n const elapsed = now - start;\n progress.value = Math.min((elapsed / duration) * 100, 100);\n if (elapsed < duration) {\n requestAnimationFrame(step);\n } else {\n running = false;\n showToast({ message: \"Complete!\", intent: \"success\", icon: \"bread\" });\n }\n }\n requestAnimationFrame(step);\n });\n resetBtn.addEventListener(\"esp-clicked\", () => {\n running = false;\n progress.value = 0;\n });\n</script>\n```\n\nIndeterminate mode with different intents:\n\n```html\n<div style=\"display: grid; gap: var(--esp-size-small);\">\n <esp-progress label=\"Primary loading\"></esp-progress>\n <esp-progress label=\"Success loading\" intent=\"success\"></esp-progress>\n <esp-progress label=\"Warning loading\" intent=\"warning\"></esp-progress>\n <esp-progress label=\"Danger loading\" intent=\"danger\"></esp-progress>\n</div>\n```\n\nCircle mode displays a ring that fills clockwise. Set\n`mode=\"circle\"` and optionally `show-value` to display\nthe percentage in the center:\n\n```html\n<div style=\"display: flex; gap: var(--esp-size-padding); align-items: center; flex-wrap: wrap;\">\n <esp-progress mode=\"circle\" value=\"80\" label=\"Primary\" show-value></esp-progress>\n <esp-progress mode=\"circle\" value=\"60\" label=\"Success\" intent=\"success\" show-value></esp-progress>\n <esp-progress mode=\"circle\" value=\"40\" label=\"Warning\" intent=\"warning\" show-value></esp-progress>\n <esp-progress mode=\"circle\" value=\"20\" label=\"Danger\" intent=\"danger\" show-value></esp-progress>\n</div>\n```\n\nCircle size presets:\n\n```html\n<div style=\"display: flex; gap: var(--esp-size-padding); align-items: center;\">\n <esp-progress mode=\"circle\" value=\"60\" label=\"Small\" size=\"small\"></esp-progress>\n <esp-progress mode=\"circle\" value=\"60\" label=\"Medium\" size=\"medium\" show-value></esp-progress>\n <esp-progress mode=\"circle\" value=\"60\" label=\"Large\" size=\"large\" show-value></esp-progress>\n</div>\n```\n\nIndeterminate circle mode:\n\n```html\n<div style=\"display: flex; gap: var(--esp-size-padding); align-items: center;\">\n <esp-progress mode=\"circle\" label=\"Primary loading\"></esp-progress>\n <esp-progress mode=\"circle\" label=\"Success loading\" intent=\"success\"></esp-progress>\n</div>\n```\n\nClick the button to watch the circle fill over ten seconds:\n\n```html\n<esp-box>\n <div style=\"display: flex; align-items: center; gap: var(--esp-size-padding);\">\n <esp-progress id=\"demo-circle\" mode=\"circle\" value=\"0\" label=\"Circle demo\" intent=\"success\" size=\"large\" show-value></esp-progress>\n <div style=\"display: flex; gap: var(--esp-size-small);\">\n <esp-button id=\"start-circle-btn\" label=\"Start\" collapsed></esp-button>\n <esp-button id=\"reset-circle-btn\" label=\"Reset\" collapsed></esp-button>\n </div>\n </div>\n</esp-box>\n<script>\n const circleProgress = findById(\"demo-circle\");\n const startCircleBtn = findById(\"start-circle-btn\");\n const resetCircleBtn = findById(\"reset-circle-btn\");\n let circleRunning = false;\n startCircleBtn.addEventListener(\"esp-clicked\", () => {\n if (circleRunning) return;\n circleRunning = true;\n circleProgress.value = 0;\n const start = performance.now();\n const duration = 10000;\n function step(now) {\n const elapsed = now - start;\n circleProgress.value = Math.min((elapsed / duration) * 100, 100);\n if (elapsed < duration) {\n requestAnimationFrame(step);\n } else {\n circleRunning = false;\n showToast({ message: \"Complete!\", intent: \"success\", icon: \"bread\" });\n }\n }\n requestAnimationFrame(step);\n });\n resetCircleBtn.addEventListener(\"esp-clicked\", () => {\n circleRunning = false;\n circleProgress.value = 0;\n });\n</script>\n```",
65945
+ "name": "EspalierProgress",
65942
65946
  "cssProperties": [
65943
65947
  {
65944
- "description": "The width and height of the radio icon. Defaults to `var(--esp-size-normal-to-medium)`.",
65945
- "name": "--esp-radio-button-size"
65948
+ "description": "Border color of the track outline. Defaults to `var(--esp-color-border)`.",
65949
+ "name": "--esp-progress-border-color"
65946
65950
  },
65947
65951
  {
65948
- "description": "The stroke color of the radio icon. Defaults to `var(--esp-color-text)`.",
65949
- "name": "--esp-radio-button-icon-color"
65952
+ "description": "Border radius of the track and fill. Defaults to `var(--esp-size-border-radius)`.",
65953
+ "name": "--esp-progress-border-radius"
65950
65954
  },
65951
65955
  {
65952
- "description": "The color of the focus ring shadow. Defaults to `var(--esp-color-shadow)`.",
65953
- "name": "--esp-radio-button-focus-shadow"
65956
+ "description": "Diameter of the circular progress ring in circle mode. Automatically set by the `size` attribute.",
65957
+ "name": "--esp-progress-circle-size"
65958
+ },
65959
+ {
65960
+ "description": "Color of the progress fill. Defaults to the active action hue at the semantic muted lightness so the filled and unfilled portions remain distinguishable in light and dark themes.",
65961
+ "name": "--esp-progress-fill-color"
65962
+ },
65963
+ {
65964
+ "description": "Font size for the value text. Defaults to `var(--esp-type-small)`.",
65965
+ "name": "--esp-progress-font-size"
65966
+ },
65967
+ {
65968
+ "description": "Height of the progress bar track. Automatically set by the `size` attribute.",
65969
+ "name": "--esp-progress-height"
65970
+ },
65971
+ {
65972
+ "description": "Color of the percentage text in both bar and circle modes. Defaults to `var(--esp-color-text)`.",
65973
+ "name": "--esp-progress-text-color"
65954
65974
  },
65955
65975
  {
65956
65976
  "description": "Background color of the shared field shell. Defaults to `var(--esp-color-layer-2)`.",
@@ -66009,101 +66029,111 @@
66009
66029
  }
66010
66030
  }
66011
66031
  ],
66012
- "slots": [
66013
- {
66014
- "description": "The label text for the radio button.",
66015
- "name": ""
66016
- }
66017
- ],
66018
66032
  "members": [
66019
66033
  {
66020
66034
  "kind": "field",
66021
- "name": "formItemDescription",
66022
- "privacy": "private",
66023
- "default": "new FormFieldDescriptionController({ host: this, getTarget: () => this.shadowRoot?.querySelector<HTMLElement>(\".radio-control\"), })"
66035
+ "name": "value",
66036
+ "type": {
66037
+ "text": "number | null"
66038
+ },
66039
+ "privacy": "public",
66040
+ "default": "null",
66041
+ "description": "The current progress value. Set to `null` (or omit) for\nindeterminate mode. Values are clamped to `0..max`.",
66042
+ "attribute": "value"
66024
66043
  },
66025
66044
  {
66026
66045
  "kind": "field",
66027
- "name": "checked",
66046
+ "name": "max",
66028
66047
  "type": {
66029
- "text": "boolean"
66048
+ "text": "number"
66030
66049
  },
66031
66050
  "privacy": "public",
66032
- "default": "false",
66033
- "description": "Whether the radio button is in the selected state.",
66034
- "attribute": "checked",
66035
- "reflects": true
66051
+ "default": "100",
66052
+ "description": "The maximum value. Defaults to `100`.",
66053
+ "attribute": "max"
66036
66054
  },
66037
66055
  {
66038
66056
  "kind": "field",
66039
- "name": "value",
66057
+ "name": "label",
66040
66058
  "type": {
66041
66059
  "text": "string"
66042
66060
  },
66043
66061
  "privacy": "public",
66044
66062
  "default": "\"\"",
66045
- "description": "The value associated with this radio button. Used by\n[esp-radio-button-group](/components/radio-button/group) to\ntrack which option is selected.",
66046
- "attribute": "value"
66063
+ "description": "An accessible label describing what the progress bar\nrepresents. Required for screen readers.",
66064
+ "attribute": "label"
66047
66065
  },
66048
66066
  {
66049
66067
  "kind": "field",
66050
- "name": "disabled",
66068
+ "name": "showValue",
66051
66069
  "type": {
66052
66070
  "text": "boolean"
66053
66071
  },
66054
66072
  "privacy": "public",
66055
66073
  "default": "false",
66056
- "description": "Controls whether the radio button is disabled.",
66057
- "attribute": "disabled",
66058
- "reflects": true
66074
+ "description": "Show the percentage value as text. In bar mode the text\nappears below the track; in circle mode it appears in the\ncenter of the ring.",
66075
+ "attribute": "show-value"
66059
66076
  },
66060
66077
  {
66061
- "kind": "method",
66062
- "name": "focus",
66078
+ "kind": "field",
66079
+ "name": "size",
66080
+ "type": {
66081
+ "text": "\"small\" | \"medium\" | \"large\""
66082
+ },
66063
66083
  "privacy": "public",
66064
- "return": {
66065
- "type": {
66066
- "text": "void"
66067
- }
66084
+ "default": "\"medium\"",
66085
+ "description": "Size preset for the progress indicator.\n\nIn bar mode:\n- `small` — 6px\n- `medium` — 12px (default)\n- `large` — 20px\n\nIn circle mode:\n- `small` — 48px diameter\n- `medium` — 80px diameter (default)\n- `large` — 120px diameter",
66086
+ "attribute": "size",
66087
+ "reflects": true
66088
+ },
66089
+ {
66090
+ "kind": "field",
66091
+ "name": "mode",
66092
+ "type": {
66093
+ "text": "\"bar\" | \"circle\""
66068
66094
  },
66069
- "parameters": [
66070
- {
66071
- "name": "options",
66072
- "optional": true,
66073
- "type": {
66074
- "text": "FocusOptions"
66075
- }
66076
- }
66077
- ],
66078
- "description": "Focus the radio button control."
66095
+ "privacy": "public",
66096
+ "default": "\"bar\"",
66097
+ "description": "Display mode for the progress indicator.\n\n- `bar` — linear progress bar (default)\n- `circle` — circular SVG ring",
66098
+ "attribute": "mode",
66099
+ "reflects": true
66079
66100
  },
66080
66101
  {
66081
- "kind": "method",
66082
- "name": "select",
66102
+ "kind": "field",
66103
+ "name": "isIndeterminate",
66104
+ "type": {
66105
+ "text": "boolean"
66106
+ },
66083
66107
  "privacy": "private",
66084
- "return": {
66085
- "type": {
66086
- "text": "void"
66087
- }
66088
- }
66108
+ "readonly": true
66089
66109
  },
66090
66110
  {
66091
- "kind": "method",
66092
- "name": "handleKeyDown",
66111
+ "kind": "field",
66112
+ "name": "clampedValue",
66113
+ "type": {
66114
+ "text": "number"
66115
+ },
66093
66116
  "privacy": "private",
66094
- "return": {
66095
- "type": {
66096
- "text": "void"
66097
- }
66117
+ "readonly": true
66118
+ },
66119
+ {
66120
+ "kind": "field",
66121
+ "name": "percentage",
66122
+ "type": {
66123
+ "text": "number"
66098
66124
  },
66099
- "parameters": [
66100
- {
66101
- "name": "ev",
66102
- "type": {
66103
- "text": "KeyboardEvent"
66104
- }
66105
- }
66106
- ]
66125
+ "privacy": "private",
66126
+ "readonly": true
66127
+ },
66128
+ {
66129
+ "kind": "method",
66130
+ "name": "renderBar",
66131
+ "privacy": "private"
66132
+ },
66133
+ {
66134
+ "kind": "method",
66135
+ "name": "renderCircle",
66136
+ "privacy": "private"
66107
66137
  },
66108
66138
  {
66109
66139
  "kind": "field",
@@ -66830,42 +66860,60 @@
66830
66860
  }
66831
66861
  }
66832
66862
  ],
66833
- "events": [
66863
+ "attributes": [
66834
66864
  {
66865
+ "name": "value",
66835
66866
  "type": {
66836
- "text": "CustomEvent<{ checked: boolean; value: string }>"
66867
+ "text": "number | null"
66837
66868
  },
66838
- "description": "Fired when the radio button is selected. The detail contains the new `checked` state and the radio button `value`.",
66839
- "name": "esp-value-changed"
66840
- }
66841
- ],
66842
- "attributes": [
66869
+ "default": "null",
66870
+ "description": "The current progress value. Set to `null` (or omit) for\nindeterminate mode. Values are clamped to `0..max`.",
66871
+ "fieldName": "value"
66872
+ },
66843
66873
  {
66844
- "name": "checked",
66874
+ "name": "max",
66845
66875
  "type": {
66846
- "text": "boolean"
66876
+ "text": "number"
66847
66877
  },
66848
- "default": "false",
66849
- "description": "Whether the radio button is in the selected state.",
66850
- "fieldName": "checked"
66878
+ "default": "100",
66879
+ "description": "The maximum value. Defaults to `100`.",
66880
+ "fieldName": "max"
66851
66881
  },
66852
66882
  {
66853
- "name": "value",
66883
+ "name": "label",
66854
66884
  "type": {
66855
66885
  "text": "string"
66856
66886
  },
66857
66887
  "default": "\"\"",
66858
- "description": "The value associated with this radio button. Used by\n[esp-radio-button-group](/components/radio-button/group) to\ntrack which option is selected.",
66859
- "fieldName": "value"
66888
+ "description": "An accessible label describing what the progress bar\nrepresents. Required for screen readers.",
66889
+ "fieldName": "label"
66860
66890
  },
66861
66891
  {
66862
- "name": "disabled",
66892
+ "name": "show-value",
66863
66893
  "type": {
66864
66894
  "text": "boolean"
66865
66895
  },
66866
66896
  "default": "false",
66867
- "description": "Controls whether the radio button is disabled.",
66868
- "fieldName": "disabled"
66897
+ "description": "Show the percentage value as text. In bar mode the text\nappears below the track; in circle mode it appears in the\ncenter of the ring.",
66898
+ "fieldName": "showValue"
66899
+ },
66900
+ {
66901
+ "name": "size",
66902
+ "type": {
66903
+ "text": "\"small\" | \"medium\" | \"large\""
66904
+ },
66905
+ "default": "\"medium\"",
66906
+ "description": "Size preset for the progress indicator.\n\nIn bar mode:\n- `small` — 6px\n- `medium` — 12px (default)\n- `large` — 20px\n\nIn circle mode:\n- `small` — 48px diameter\n- `medium` — 80px diameter (default)\n- `large` — 120px diameter",
66907
+ "fieldName": "size"
66908
+ },
66909
+ {
66910
+ "name": "mode",
66911
+ "type": {
66912
+ "text": "\"bar\" | \"circle\""
66913
+ },
66914
+ "default": "\"bar\"",
66915
+ "description": "Display mode for the progress indicator.\n\n- `bar` — linear progress bar (default)\n- `circle` — circular SVG ring",
66916
+ "fieldName": "mode"
66869
66917
  },
66870
66918
  {
66871
66919
  "name": "scheme",
@@ -66910,44 +66958,49 @@
66910
66958
  "module": "dist/shared/esp-element-base.js"
66911
66959
  },
66912
66960
  "docPageTitle": {
66913
- "name": "Radio",
66914
- "description": "Button"
66961
+ "name": "Progress",
66962
+ "description": ""
66915
66963
  },
66916
66964
  "docUrl": {
66917
- "name": "/components/radio-button",
66965
+ "name": "/components/progress",
66918
66966
  "description": ""
66919
66967
  },
66920
66968
  "menuGroup": {
66921
- "name": "Form",
66922
- "description": "Controls"
66969
+ "name": "Feedback",
66970
+ "description": ""
66923
66971
  },
66924
66972
  "menuLabel": {
66925
- "name": "Radio",
66926
- "description": "Button"
66973
+ "name": "Progress",
66974
+ "description": ""
66927
66975
  },
66928
66976
  "menuIcon": {
66929
- "name": "circle-dot",
66977
+ "name": "progress",
66930
66978
  "description": ""
66931
66979
  },
66932
- "tagName": "esp-radio-button",
66933
- "customElement": true
66980
+ "tagName": "esp-progress",
66981
+ "customElement": true,
66982
+ "events": []
66983
+ },
66984
+ {
66985
+ "kind": "variable",
66986
+ "name": "indeterminate"
66934
66987
  }
66935
66988
  ],
66936
66989
  "exports": [
66937
66990
  {
66938
66991
  "kind": "js",
66939
- "name": "EspalierRadioButton",
66992
+ "name": "EspalierProgress",
66940
66993
  "declaration": {
66941
- "name": "EspalierRadioButton",
66942
- "module": "dist/radio-button/esp-radio-button.js"
66994
+ "name": "EspalierProgress",
66995
+ "module": "dist/progress/esp-progress.js"
66943
66996
  }
66944
66997
  },
66945
66998
  {
66946
66999
  "kind": "custom-element-definition",
66947
- "name": "esp-radio-button",
67000
+ "name": "esp-progress",
66948
67001
  "declaration": {
66949
- "name": "EspalierRadioButton",
66950
- "module": "dist/radio-button/esp-radio-button.js"
67002
+ "name": "EspalierProgress",
67003
+ "module": "dist/progress/esp-progress.js"
66951
67004
  }
66952
67005
  }
66953
67006
  ]
@@ -84352,60 +84405,40 @@
84352
84405
  },
84353
84406
  {
84354
84407
  "kind": "javascript-module",
84355
- "path": "dist/switch/esp-switch.js",
84408
+ "path": "dist/tabs/esp-tab-group.js",
84356
84409
  "declarations": [
84357
84410
  {
84358
84411
  "kind": "class",
84359
- "description": "A toggle switch for boolean on/off values. Uses a CSS-only\ntrack-and-thumb design with a smooth sliding transition.\nFunctionally equivalent to a checkbox but visually communicates\nan immediate state change rather than a deferred selection.\n\n```html\n<esp-box>\n <esp-form-item label=\"Notifications\">\n <esp-switch value=\"notifications\">\n Enable notifications\n </esp-switch>\n </esp-form-item>\n</esp-box>\n```\n\n```html\n<esp-box>\n <esp-switch checked value=\"dark-mode\">\n Dark mode\n </esp-switch>\n <esp-switch disabled value=\"disabled-opt\">\n Disabled option\n </esp-switch>\n</esp-box>\n```\n\n### Text mode\n\nSet `mode=\"text\"` with `off-label` and `on-label` to render a\ntwo-option text toggle instead of a track and thumb. This is\nideal for binary choices like a billing-period selector:\n\n```html\n<esp-box>\n <esp-switch\n mode=\"text\"\n off-label=\"Monthly\"\n on-label=\"Annual\"\n value=\"annual\"\n >Billing period</esp-switch>\n</esp-box>\n```\n\nThe slotted text is visually hidden in text mode and folded\ninto the control's accessible label together with the current\nselected option. Screen readers will announce both the label\nand the active choice while the `off-label` / `on-label`\ntext is presented visually.",
84360
- "name": "EspalierSwitch",
84412
+ "description": "A tabbed interface that groups multiple\n[esp-tab](/components/tabs) elements. The tab strip is\ngenerated automatically from each child's `label` attribute.\nOnly one tab panel is visible at a time.\n\n```html\n<esp-tab-group>\n <esp-tab label=\"Overview\">\n <p>Overview content goes here.</p>\n </esp-tab>\n <esp-tab label=\"Details\">\n <p>Detailed information lives here.</p>\n </esp-tab>\n <esp-tab label=\"Settings\">\n <p>Configuration options.</p>\n </esp-tab>\n</esp-tab-group>\n```\n\n### Pre-selected tab\n\nSet `active` on a child `esp-tab` to make it the initially\nvisible panel:\n\n```html\n<esp-tab-group>\n <esp-tab label=\"Alpha\">\n <p>Alpha panel.</p>\n </esp-tab>\n <esp-tab label=\"Beta\" active>\n <p>Beta starts active.</p>\n </esp-tab>\n</esp-tab-group>\n```\n\n### Disabled tab\n\nIndividual tabs can be disabled:\n\n```html\n<esp-tab-group>\n <esp-tab label=\"Available\">\n <p>You can select this tab.</p>\n </esp-tab>\n <esp-tab label=\"Locked\" disabled>\n <p>This tab cannot be reached.</p>\n </esp-tab>\n <esp-tab label=\"Also available\">\n <p>This tab works too.</p>\n </esp-tab>\n</esp-tab-group>\n```\n\n### Disabled group\n\nSet `disabled` on the group to disable all tabs at once:\n\n```html\n<esp-tab-group disabled>\n <esp-tab label=\"One\">\n <p>All tabs are disabled.</p>\n </esp-tab>\n <esp-tab label=\"Two\">\n <p>Cannot switch to this.</p>\n </esp-tab>\n</esp-tab-group>\n```\n\n### Zone theming\n\nTab groups pick up zone theming from a `context` attribute:\n\n```html\n<esp-tab-group context=\"quiet\">\n <esp-tab label=\"First\">\n <p>Zone-correct content.</p>\n </esp-tab>\n <esp-tab label=\"Second\">\n <p>More content.</p>\n </esp-tab>\n</esp-tab-group>\n```\n\n### Listening for tab changes\n\n```html\n<esp-tab-group>\n <esp-tab label=\"Tab 1\">\n <p>First panel.</p>\n </esp-tab>\n <esp-tab label=\"Tab 2\">\n <p>Second panel.</p>\n </esp-tab>\n</esp-tab-group>\n<script>\n const tabs = findByTagName(\"esp-tab-group\")[0];\n tabs.addEventListener(\"esp-tab-group-changed\", (ev) => {\n console.log(\"Switched to:\", ev.detail.label, \"at index\", ev.detail.index);\n });\n</script>\n```",
84413
+ "name": "EspalierTabGroup",
84361
84414
  "cssProperties": [
84362
84415
  {
84363
- "description": "The width of the switch track. Defaults to `calc(var(--esp-size-normal-to-medium) * 1.75)`.",
84364
- "name": "--esp-switch-width"
84365
- },
84366
- {
84367
- "description": "The height of the switch track. Defaults to `var(--esp-size-normal-to-medium)`.",
84368
- "name": "--esp-switch-height"
84369
- },
84370
- {
84371
- "description": "The diameter of the thumb. Defaults to `calc(var(--esp-switch-height) - 4px)`.",
84372
- "name": "--esp-switch-thumb-size"
84373
- },
84374
- {
84375
- "description": "The track background color when the switch is off. Defaults to `var(--esp-color-border)`.",
84376
- "name": "--esp-switch-track-color"
84377
- },
84378
- {
84379
- "description": "The track background color when the switch is on. Defaults to `var(--esp-color-action-background)`.",
84380
- "name": "--esp-switch-track-color-on"
84381
- },
84382
- {
84383
- "description": "The thumb color. Defaults to `var(--esp-color-layer-1)`.",
84384
- "name": "--esp-switch-thumb-color"
84416
+ "description": "Border color of the tab group container.",
84417
+ "name": "--esp-tab-color-border"
84385
84418
  },
84386
84419
  {
84387
- "description": "The color of the focus ring shadow. Defaults to `var(--esp-color-shadow)`.",
84388
- "name": "--esp-switch-focus-shadow"
84420
+ "description": "Background color of the overall component.",
84421
+ "name": "--esp-tab-color-background"
84389
84422
  },
84390
84423
  {
84391
- "description": "Padding inside each text-mode label cell. Defaults to `var(--esp-size-tiny) var(--esp-size-small)`.",
84392
- "name": "--esp-switch-text-padding"
84424
+ "description": "Background color of the tab strip.",
84425
+ "name": "--esp-tab-color-strip-background"
84393
84426
  },
84394
84427
  {
84395
- "description": "Font size for text-mode labels. Defaults to `var(--esp-size-font)`.",
84396
- "name": "--esp-switch-text-font-size"
84428
+ "description": "Tab button hover background.",
84429
+ "name": "--esp-tab-color-button-hover"
84397
84430
  },
84398
84431
  {
84399
- "description": "Text color of the active label in text mode. Defaults to `var(--esp-color-action-text)`.",
84400
- "name": "--esp-switch-text-active-color"
84432
+ "description": "Active tab button background.",
84433
+ "name": "--esp-tab-color-button-active"
84401
84434
  },
84402
84435
  {
84403
- "description": "Text color of the inactive label in text mode. Defaults to `var(--esp-color-layer-1)`.",
84404
- "name": "--esp-switch-text-inactive-color"
84436
+ "description": "Text color for tab buttons.",
84437
+ "name": "--esp-tab-color-text"
84405
84438
  },
84406
84439
  {
84407
- "description": "Background color of the sliding highlight in text mode. Defaults to `var(--esp-color-action-background)`.",
84408
- "name": "--esp-switch-text-highlight-color"
84440
+ "description": "Padding inside the panel area and tab buttons.",
84441
+ "name": "--esp-tab-size-padding"
84409
84442
  },
84410
84443
  {
84411
84444
  "description": "Background color of the shared field shell. Defaults to `var(--esp-color-layer-2)`.",
@@ -84464,194 +84497,108 @@
84464
84497
  }
84465
84498
  }
84466
84499
  ],
84500
+ "cssParts": [
84501
+ {
84502
+ "description": "The tab strip container.",
84503
+ "name": "tab-list"
84504
+ },
84505
+ {
84506
+ "description": "Each individual tab button in the strip.",
84507
+ "name": "tab-button"
84508
+ },
84509
+ {
84510
+ "description": "The panel area below the tab strip.",
84511
+ "name": "panels"
84512
+ }
84513
+ ],
84467
84514
  "slots": [
84468
84515
  {
84469
- "description": "The label text for the switch. In default mode this renders beside the track; in text mode it is visually hidden and included in the control's accessible label.",
84516
+ "description": "Place `esp-tab` elements in the default slot.",
84470
84517
  "name": ""
84471
84518
  }
84472
84519
  ],
84473
84520
  "members": [
84474
84521
  {
84475
84522
  "kind": "field",
84476
- "name": "formAssociated",
84477
- "type": {
84478
- "text": "boolean"
84479
- },
84480
- "static": true,
84481
- "default": "true"
84482
- },
84483
- {
84484
- "kind": "field",
84485
- "name": "internals",
84523
+ "name": "panelsSlot",
84486
84524
  "privacy": "private"
84487
84525
  },
84488
84526
  {
84489
84527
  "kind": "field",
84490
- "name": "formCtrl",
84491
- "privacy": "private",
84492
- "default": "new FormFieldController({ host: this, internals: this.internals, getFormValue: () => (this.checked ? this.value || \"on\" : null), getValidity: () => { if (this.required && !this.checked) { return { flags: { valueMissing: true }, message: this.requiredMessage || \"Please toggle this switch to continue.\", }; } return null; }, onReset: () => { this.checked = false; }, onRestore: (state: string) => { this.checked = state === \"on\" || state === this.value; }, onDisabled: (isDisabled: boolean) => { this.disabled = isDisabled; }, })"
84493
- },
84494
- {
84495
- "kind": "field",
84496
- "name": "formItemDescription",
84497
- "privacy": "private",
84498
- "default": "new FormFieldDescriptionController({ host: this, getTarget: () => this.shadowRoot?.querySelector<HTMLElement>(\".switch-control\"), })"
84499
- },
84500
- {
84501
- "kind": "field",
84502
- "name": "mode",
84503
- "type": {
84504
- "text": "\"switch\" | \"text\""
84505
- },
84506
- "privacy": "public",
84507
- "default": "\"switch\"",
84508
- "description": "The visual presentation of the switch.\n- `\"switch\"` (default) renders a track-and-thumb toggle.\n- `\"text\"` renders two side-by-side text labels with a\n sliding highlight behind the active one.",
84509
- "attribute": "mode",
84510
- "reflects": true
84511
- },
84512
- {
84513
- "kind": "field",
84514
- "name": "offLabel",
84515
- "type": {
84516
- "text": "string"
84517
- },
84518
- "privacy": "public",
84519
- "default": "\"\"",
84520
- "description": "Label shown for the unchecked (off) state when\n`mode=\"text\"`.",
84521
- "attribute": "off-label"
84522
- },
84523
- {
84524
- "kind": "field",
84525
- "name": "onLabel",
84526
- "type": {
84527
- "text": "string"
84528
- },
84529
- "privacy": "public",
84530
- "default": "\"\"",
84531
- "description": "Label shown for the checked (on) state when\n`mode=\"text\"`.",
84532
- "attribute": "on-label"
84533
- },
84534
- {
84535
- "kind": "field",
84536
- "name": "checked",
84537
- "type": {
84538
- "text": "boolean"
84539
- },
84540
- "privacy": "public",
84541
- "default": "false",
84542
- "description": "Whether the switch is in the on state.",
84543
- "attribute": "checked",
84544
- "reflects": true
84545
- },
84546
- {
84547
- "kind": "field",
84548
- "name": "value",
84549
- "type": {
84550
- "text": "string"
84551
- },
84552
- "privacy": "public",
84553
- "default": "\"\"",
84554
- "description": "The value associated with this switch. Submitted with the\nform when the switch is on.",
84555
- "attribute": "value"
84556
- },
84557
- {
84558
- "kind": "field",
84559
- "name": "name",
84560
- "type": {
84561
- "text": "string"
84562
- },
84563
- "privacy": "public",
84564
- "default": "\"\"",
84565
- "description": "The name used when the switch participates in a `<form>`.",
84566
- "attribute": "name",
84567
- "reflects": true
84568
- },
84569
- {
84570
- "kind": "field",
84571
- "name": "required",
84528
+ "name": "disabled",
84572
84529
  "type": {
84573
84530
  "text": "boolean"
84574
84531
  },
84575
84532
  "privacy": "public",
84576
84533
  "default": "false",
84577
- "description": "When true, the switch must be on before the form can\nbe submitted.",
84578
- "attribute": "required",
84534
+ "description": "Disables all tabs in the group, preventing any tab from\nbeing selected.",
84535
+ "attribute": "disabled",
84579
84536
  "reflects": true
84580
84537
  },
84581
84538
  {
84582
84539
  "kind": "field",
84583
- "name": "requiredMessage",
84584
- "type": {
84585
- "text": "string"
84586
- },
84587
- "privacy": "public",
84588
- "default": "\"\"",
84589
- "description": "A custom message to display when the switch is required but\nnot on. Defaults to `\"Please toggle this switch to continue.\"`\nwhen not set.\n\n```html\n<esp-switch required required-message=\"You must accept the terms.\">\n I accept\n</esp-switch>\n```",
84590
- "attribute": "required-message"
84591
- },
84592
- {
84593
- "kind": "field",
84594
- "name": "disabled",
84540
+ "name": "tabData",
84595
84541
  "type": {
84596
- "text": "boolean"
84542
+ "text": "TabData[]"
84597
84543
  },
84598
- "privacy": "public",
84599
- "default": "false",
84600
- "description": "Controls whether the switch is disabled.",
84601
- "attribute": "disabled",
84602
- "reflects": true
84544
+ "privacy": "private",
84545
+ "default": "[]"
84603
84546
  },
84604
84547
  {
84605
84548
  "kind": "method",
84606
- "name": "focus",
84607
- "privacy": "public",
84549
+ "name": "getTabs",
84550
+ "privacy": "private",
84608
84551
  "return": {
84609
84552
  "type": {
84610
- "text": "void"
84611
- }
84612
- },
84613
- "parameters": [
84614
- {
84615
- "name": "options",
84616
- "optional": true,
84617
- "type": {
84618
- "text": "FocusOptions"
84619
- }
84553
+ "text": "EspalierTab[]"
84620
84554
  }
84621
- ],
84622
- "description": "Focus the switch control."
84555
+ }
84623
84556
  },
84624
84557
  {
84625
84558
  "kind": "method",
84626
- "name": "validate",
84627
- "privacy": "public",
84559
+ "name": "syncTabData",
84560
+ "privacy": "private",
84628
84561
  "return": {
84629
84562
  "type": {
84630
84563
  "text": "void"
84631
84564
  }
84632
- },
84633
- "description": "Re-run constraint validation and dispatch `esp-validity-changed`."
84565
+ }
84634
84566
  },
84635
84567
  {
84636
84568
  "kind": "method",
84637
- "name": "checkValidity",
84638
- "privacy": "public",
84569
+ "name": "activateTab",
84570
+ "privacy": "private",
84639
84571
  "return": {
84640
84572
  "type": {
84641
- "text": "boolean"
84573
+ "text": "void"
84642
84574
  }
84643
84575
  },
84644
- "description": "Check whether the current state is valid (delegates to ElementInternals)."
84576
+ "parameters": [
84577
+ {
84578
+ "name": "index",
84579
+ "type": {
84580
+ "text": "number"
84581
+ }
84582
+ }
84583
+ ]
84645
84584
  },
84646
84585
  {
84647
84586
  "kind": "method",
84648
- "name": "toggle",
84587
+ "name": "handleTabClick",
84649
84588
  "privacy": "private",
84650
84589
  "return": {
84651
84590
  "type": {
84652
84591
  "text": "void"
84653
84592
  }
84654
- }
84593
+ },
84594
+ "parameters": [
84595
+ {
84596
+ "name": "index",
84597
+ "type": {
84598
+ "text": "number"
84599
+ }
84600
+ }
84601
+ ]
84655
84602
  },
84656
84603
  {
84657
84604
  "kind": "method",
@@ -84673,7 +84620,7 @@
84673
84620
  },
84674
84621
  {
84675
84622
  "kind": "method",
84676
- "name": "handleLabelSlotChange",
84623
+ "name": "handleChildUpdated",
84677
84624
  "privacy": "private",
84678
84625
  "return": {
84679
84626
  "type": {
@@ -84683,69 +84630,13 @@
84683
84630
  },
84684
84631
  {
84685
84632
  "kind": "method",
84686
- "name": "getCurrentTextModeLabel",
84687
- "privacy": "private",
84688
- "return": {
84689
- "type": {
84690
- "text": "string"
84691
- }
84692
- }
84693
- },
84694
- {
84695
- "kind": "method",
84696
- "name": "getTextModeAriaLabel",
84633
+ "name": "handleSlotChange",
84697
84634
  "privacy": "private",
84698
- "return": {
84699
- "type": {
84700
- "text": "string"
84701
- }
84702
- }
84703
- },
84704
- {
84705
- "kind": "method",
84706
- "name": "formResetCallback",
84707
84635
  "return": {
84708
84636
  "type": {
84709
84637
  "text": "void"
84710
84638
  }
84711
- },
84712
- "description": "Called by the browser when the owning `<form>` is reset."
84713
- },
84714
- {
84715
- "kind": "method",
84716
- "name": "formStateRestoreCallback",
84717
- "return": {
84718
- "type": {
84719
- "text": "void"
84720
- }
84721
- },
84722
- "parameters": [
84723
- {
84724
- "name": "state",
84725
- "type": {
84726
- "text": "string"
84727
- }
84728
- }
84729
- ],
84730
- "description": "Called by the browser to restore form state (bfcache, etc.)."
84731
- },
84732
- {
84733
- "kind": "method",
84734
- "name": "formDisabledCallback",
84735
- "return": {
84736
- "type": {
84737
- "text": "void"
84738
- }
84739
- },
84740
- "parameters": [
84741
- {
84742
- "name": "isDisabled",
84743
- "type": {
84744
- "text": "boolean"
84745
- }
84746
- }
84747
- ],
84748
- "description": "Called by the browser when a parent `<fieldset>` is enabled or disabled."
84639
+ }
84749
84640
  },
84750
84641
  {
84751
84642
  "kind": "field",
@@ -85475,99 +85366,20 @@
85475
85366
  "events": [
85476
85367
  {
85477
85368
  "type": {
85478
- "text": "CustomEvent<{ checked: boolean; value: string }>"
85479
- },
85480
- "description": "Fired when the switch is toggled. The detail contains the new `checked` state and the switch `value`.",
85481
- "name": "esp-value-changed"
85482
- },
85483
- {
85484
- "type": {
85485
- "text": "CustomEvent<{ valid: boolean; message: string }>"
85369
+ "text": "CustomEvent<{ index: number; label: string }>"
85486
85370
  },
85487
- "description": "Fired whenever constraint validation runs.",
85488
- "name": "esp-validity-changed"
85371
+ "description": "Fired when the active tab changes. The detail contains the `index` and `label` of the newly active tab.",
85372
+ "name": "esp-tab-group-changed"
85489
85373
  }
85490
85374
  ],
85491
85375
  "attributes": [
85492
- {
85493
- "name": "mode",
85494
- "type": {
85495
- "text": "\"switch\" | \"text\""
85496
- },
85497
- "default": "\"switch\"",
85498
- "description": "The visual presentation of the switch.\n- `\"switch\"` (default) renders a track-and-thumb toggle.\n- `\"text\"` renders two side-by-side text labels with a\n sliding highlight behind the active one.",
85499
- "fieldName": "mode"
85500
- },
85501
- {
85502
- "name": "off-label",
85503
- "type": {
85504
- "text": "string"
85505
- },
85506
- "default": "\"\"",
85507
- "description": "Label shown for the unchecked (off) state when\n`mode=\"text\"`.",
85508
- "fieldName": "offLabel"
85509
- },
85510
- {
85511
- "name": "on-label",
85512
- "type": {
85513
- "text": "string"
85514
- },
85515
- "default": "\"\"",
85516
- "description": "Label shown for the checked (on) state when\n`mode=\"text\"`.",
85517
- "fieldName": "onLabel"
85518
- },
85519
- {
85520
- "name": "checked",
85521
- "type": {
85522
- "text": "boolean"
85523
- },
85524
- "default": "false",
85525
- "description": "Whether the switch is in the on state.",
85526
- "fieldName": "checked"
85527
- },
85528
- {
85529
- "name": "value",
85530
- "type": {
85531
- "text": "string"
85532
- },
85533
- "default": "\"\"",
85534
- "description": "The value associated with this switch. Submitted with the\nform when the switch is on.",
85535
- "fieldName": "value"
85536
- },
85537
- {
85538
- "name": "name",
85539
- "type": {
85540
- "text": "string"
85541
- },
85542
- "default": "\"\"",
85543
- "description": "The name used when the switch participates in a `<form>`.",
85544
- "fieldName": "name"
85545
- },
85546
- {
85547
- "name": "required",
85548
- "type": {
85549
- "text": "boolean"
85550
- },
85551
- "default": "false",
85552
- "description": "When true, the switch must be on before the form can\nbe submitted.",
85553
- "fieldName": "required"
85554
- },
85555
- {
85556
- "name": "required-message",
85557
- "type": {
85558
- "text": "string"
85559
- },
85560
- "default": "\"\"",
85561
- "description": "A custom message to display when the switch is required but\nnot on. Defaults to `\"Please toggle this switch to continue.\"`\nwhen not set.\n\n```html\n<esp-switch required required-message=\"You must accept the terms.\">\n I accept\n</esp-switch>\n```",
85562
- "fieldName": "requiredMessage"
85563
- },
85564
85376
  {
85565
85377
  "name": "disabled",
85566
85378
  "type": {
85567
85379
  "text": "boolean"
85568
85380
  },
85569
85381
  "default": "false",
85570
- "description": "Controls whether the switch is disabled.",
85382
+ "description": "Disables all tabs in the group, preventing any tab from\nbeing selected.",
85571
85383
  "fieldName": "disabled"
85572
85384
  },
85573
85385
  {
@@ -85612,84 +85424,60 @@
85612
85424
  "name": "EspalierElementBase",
85613
85425
  "module": "dist/shared/esp-element-base.js"
85614
85426
  },
85427
+ "tagName": "esp-tab-group",
85428
+ "customElement": true,
85615
85429
  "docPageTitle": {
85616
- "name": "Switch",
85617
- "description": ""
85430
+ "name": "Tab",
85431
+ "description": "Group"
85618
85432
  },
85619
85433
  "docUrl": {
85620
- "name": "/components/switch",
85434
+ "name": "/components/tabs",
85621
85435
  "description": ""
85622
85436
  },
85623
85437
  "menuGroup": {
85624
- "name": "Form",
85625
- "description": "Controls"
85438
+ "name": "Navigation",
85439
+ "description": ""
85626
85440
  },
85627
85441
  "menuLabel": {
85628
- "name": "Switch",
85629
- "description": ""
85442
+ "name": "Tab",
85443
+ "description": "Group"
85630
85444
  },
85631
85445
  "menuIcon": {
85632
- "name": "button",
85446
+ "name": "layout-navbar",
85633
85447
  "description": ""
85634
- },
85635
- "tagName": "esp-switch",
85636
- "customElement": true
85448
+ }
85637
85449
  }
85638
85450
  ],
85639
85451
  "exports": [
85640
85452
  {
85641
85453
  "kind": "js",
85642
- "name": "EspalierSwitch",
85454
+ "name": "EspalierTabGroup",
85643
85455
  "declaration": {
85644
- "name": "EspalierSwitch",
85645
- "module": "dist/switch/esp-switch.js"
85456
+ "name": "EspalierTabGroup",
85457
+ "module": "dist/tabs/esp-tab-group.js"
85646
85458
  }
85647
85459
  },
85648
85460
  {
85649
85461
  "kind": "custom-element-definition",
85650
- "name": "esp-switch",
85462
+ "name": "esp-tab-group",
85651
85463
  "declaration": {
85652
- "name": "EspalierSwitch",
85653
- "module": "dist/switch/esp-switch.js"
85464
+ "name": "EspalierTabGroup",
85465
+ "module": "dist/tabs/esp-tab-group.js"
85654
85466
  }
85655
85467
  }
85656
85468
  ]
85657
85469
  },
85658
85470
  {
85659
85471
  "kind": "javascript-module",
85660
- "path": "dist/tabs/esp-tab-group.js",
85472
+ "path": "dist/tabs/esp-tab.js",
85661
85473
  "declarations": [
85662
85474
  {
85663
85475
  "kind": "class",
85664
- "description": "A tabbed interface that groups multiple\n[esp-tab](/components/tabs) elements. The tab strip is\ngenerated automatically from each child's `label` attribute.\nOnly one tab panel is visible at a time.\n\n```html\n<esp-tab-group>\n <esp-tab label=\"Overview\">\n <p>Overview content goes here.</p>\n </esp-tab>\n <esp-tab label=\"Details\">\n <p>Detailed information lives here.</p>\n </esp-tab>\n <esp-tab label=\"Settings\">\n <p>Configuration options.</p>\n </esp-tab>\n</esp-tab-group>\n```\n\n### Pre-selected tab\n\nSet `active` on a child `esp-tab` to make it the initially\nvisible panel:\n\n```html\n<esp-tab-group>\n <esp-tab label=\"Alpha\">\n <p>Alpha panel.</p>\n </esp-tab>\n <esp-tab label=\"Beta\" active>\n <p>Beta starts active.</p>\n </esp-tab>\n</esp-tab-group>\n```\n\n### Disabled tab\n\nIndividual tabs can be disabled:\n\n```html\n<esp-tab-group>\n <esp-tab label=\"Available\">\n <p>You can select this tab.</p>\n </esp-tab>\n <esp-tab label=\"Locked\" disabled>\n <p>This tab cannot be reached.</p>\n </esp-tab>\n <esp-tab label=\"Also available\">\n <p>This tab works too.</p>\n </esp-tab>\n</esp-tab-group>\n```\n\n### Disabled group\n\nSet `disabled` on the group to disable all tabs at once:\n\n```html\n<esp-tab-group disabled>\n <esp-tab label=\"One\">\n <p>All tabs are disabled.</p>\n </esp-tab>\n <esp-tab label=\"Two\">\n <p>Cannot switch to this.</p>\n </esp-tab>\n</esp-tab-group>\n```\n\n### Zone theming\n\nTab groups pick up zone theming from a `context` attribute:\n\n```html\n<esp-tab-group context=\"quiet\">\n <esp-tab label=\"First\">\n <p>Zone-correct content.</p>\n </esp-tab>\n <esp-tab label=\"Second\">\n <p>More content.</p>\n </esp-tab>\n</esp-tab-group>\n```\n\n### Listening for tab changes\n\n```html\n<esp-tab-group>\n <esp-tab label=\"Tab 1\">\n <p>First panel.</p>\n </esp-tab>\n <esp-tab label=\"Tab 2\">\n <p>Second panel.</p>\n </esp-tab>\n</esp-tab-group>\n<script>\n const tabs = findByTagName(\"esp-tab-group\")[0];\n tabs.addEventListener(\"esp-tab-group-changed\", (ev) => {\n console.log(\"Switched to:\", ev.detail.label, \"at index\", ev.detail.index);\n });\n</script>\n```",
85665
- "name": "EspalierTabGroup",
85476
+ "description": "A single tab panel used inside\n[esp-tab-group](/components/tabs). Each tab provides a\n`label` that appears in the generated tab strip and a default\nslot for the panel content.\n\n```html\n<esp-tab-group>\n <esp-tab label=\"First\">\n <p>Content for the first tab.</p>\n </esp-tab>\n <esp-tab label=\"Second\">\n <p>Content for the second tab.</p>\n </esp-tab>\n</esp-tab-group>\n```\n\n### Pre-selected tab\n\nSet the `active` attribute to make a tab active on load:\n\n```html\n<esp-tab-group>\n <esp-tab label=\"One\">\n <p>Not active by default.</p>\n </esp-tab>\n <esp-tab label=\"Two\" active>\n <p>This tab starts active.</p>\n </esp-tab>\n</esp-tab-group>\n```\n\n### Disabled tab\n\n```html\n<esp-tab-group>\n <esp-tab label=\"Enabled\">\n <p>This tab works normally.</p>\n </esp-tab>\n <esp-tab label=\"Disabled\" disabled>\n <p>Cannot reach this panel.</p>\n </esp-tab>\n</esp-tab-group>\n```",
85477
+ "name": "EspalierTab",
85666
85478
  "cssProperties": [
85667
85479
  {
85668
- "description": "Border color of the tab group container.",
85669
- "name": "--esp-tab-color-border"
85670
- },
85671
- {
85672
- "description": "Background color of the overall component.",
85673
- "name": "--esp-tab-color-background"
85674
- },
85675
- {
85676
- "description": "Background color of the tab strip.",
85677
- "name": "--esp-tab-color-strip-background"
85678
- },
85679
- {
85680
- "description": "Tab button hover background.",
85681
- "name": "--esp-tab-color-button-hover"
85682
- },
85683
- {
85684
- "description": "Active tab button background.",
85685
- "name": "--esp-tab-color-button-active"
85686
- },
85687
- {
85688
- "description": "Text color for tab buttons.",
85689
- "name": "--esp-tab-color-text"
85690
- },
85691
- {
85692
- "description": "Padding inside the panel area and tab buttons.",
85480
+ "description": "Padding inside the panel area.",
85693
85481
  "name": "--esp-tab-size-padding"
85694
85482
  },
85695
85483
  {
@@ -85751,144 +85539,51 @@
85751
85539
  ],
85752
85540
  "cssParts": [
85753
85541
  {
85754
- "description": "The tab strip container.",
85755
- "name": "tab-list"
85756
- },
85757
- {
85758
- "description": "Each individual tab button in the strip.",
85759
- "name": "tab-button"
85760
- },
85761
- {
85762
- "description": "The panel area below the tab strip.",
85763
- "name": "panels"
85542
+ "description": "The panel wrapper element.",
85543
+ "name": "panel"
85764
85544
  }
85765
85545
  ],
85766
85546
  "slots": [
85767
85547
  {
85768
- "description": "Place `esp-tab` elements in the default slot.",
85548
+ "description": "The default slot holds the panel content displayed when this tab is active. Label, active-state, and disabled-state updates are reported through a private coordination event consumed by the parent tab group.",
85769
85549
  "name": ""
85770
85550
  }
85771
85551
  ],
85772
85552
  "members": [
85773
85553
  {
85774
85554
  "kind": "field",
85775
- "name": "panelsSlot",
85776
- "privacy": "private"
85555
+ "name": "label",
85556
+ "type": {
85557
+ "text": "string"
85558
+ },
85559
+ "privacy": "public",
85560
+ "default": "\"\"",
85561
+ "description": "The text displayed in the tab button within the tab strip.",
85562
+ "attribute": "label"
85777
85563
  },
85778
85564
  {
85779
85565
  "kind": "field",
85780
- "name": "disabled",
85566
+ "name": "active",
85781
85567
  "type": {
85782
85568
  "text": "boolean"
85783
85569
  },
85784
85570
  "privacy": "public",
85785
85571
  "default": "false",
85786
- "description": "Disables all tabs in the group, preventing any tab from\nbeing selected.",
85787
- "attribute": "disabled",
85572
+ "description": "Whether this tab is currently active (its panel is visible).",
85573
+ "attribute": "active",
85788
85574
  "reflects": true
85789
85575
  },
85790
85576
  {
85791
85577
  "kind": "field",
85792
- "name": "tabData",
85578
+ "name": "disabled",
85793
85579
  "type": {
85794
- "text": "TabData[]"
85795
- },
85796
- "privacy": "private",
85797
- "default": "[]"
85798
- },
85799
- {
85800
- "kind": "method",
85801
- "name": "getTabs",
85802
- "privacy": "private",
85803
- "return": {
85804
- "type": {
85805
- "text": "EspalierTab[]"
85806
- }
85807
- }
85808
- },
85809
- {
85810
- "kind": "method",
85811
- "name": "syncTabData",
85812
- "privacy": "private",
85813
- "return": {
85814
- "type": {
85815
- "text": "void"
85816
- }
85817
- }
85818
- },
85819
- {
85820
- "kind": "method",
85821
- "name": "activateTab",
85822
- "privacy": "private",
85823
- "return": {
85824
- "type": {
85825
- "text": "void"
85826
- }
85827
- },
85828
- "parameters": [
85829
- {
85830
- "name": "index",
85831
- "type": {
85832
- "text": "number"
85833
- }
85834
- }
85835
- ]
85836
- },
85837
- {
85838
- "kind": "method",
85839
- "name": "handleTabClick",
85840
- "privacy": "private",
85841
- "return": {
85842
- "type": {
85843
- "text": "void"
85844
- }
85845
- },
85846
- "parameters": [
85847
- {
85848
- "name": "index",
85849
- "type": {
85850
- "text": "number"
85851
- }
85852
- }
85853
- ]
85854
- },
85855
- {
85856
- "kind": "method",
85857
- "name": "handleKeyDown",
85858
- "privacy": "private",
85859
- "return": {
85860
- "type": {
85861
- "text": "void"
85862
- }
85580
+ "text": "boolean"
85863
85581
  },
85864
- "parameters": [
85865
- {
85866
- "name": "ev",
85867
- "type": {
85868
- "text": "KeyboardEvent"
85869
- }
85870
- }
85871
- ]
85872
- },
85873
- {
85874
- "kind": "method",
85875
- "name": "handleChildUpdated",
85876
- "privacy": "private",
85877
- "return": {
85878
- "type": {
85879
- "text": "void"
85880
- }
85881
- }
85882
- },
85883
- {
85884
- "kind": "method",
85885
- "name": "handleSlotChange",
85886
- "privacy": "private",
85887
- "return": {
85888
- "type": {
85889
- "text": "void"
85890
- }
85891
- }
85582
+ "privacy": "public",
85583
+ "default": "false",
85584
+ "description": "Whether this tab is disabled (cannot be selected).",
85585
+ "attribute": "disabled",
85586
+ "reflects": true
85892
85587
  },
85893
85588
  {
85894
85589
  "kind": "field",
@@ -86615,23 +86310,33 @@
86615
86310
  }
86616
86311
  }
86617
86312
  ],
86618
- "events": [
86313
+ "events": [],
86314
+ "attributes": [
86619
86315
  {
86316
+ "name": "label",
86620
86317
  "type": {
86621
- "text": "CustomEvent<{ index: number; label: string }>"
86318
+ "text": "string"
86622
86319
  },
86623
- "description": "Fired when the active tab changes. The detail contains the `index` and `label` of the newly active tab.",
86624
- "name": "esp-tab-group-changed"
86625
- }
86626
- ],
86627
- "attributes": [
86320
+ "default": "\"\"",
86321
+ "description": "The text displayed in the tab button within the tab strip.",
86322
+ "fieldName": "label"
86323
+ },
86324
+ {
86325
+ "name": "active",
86326
+ "type": {
86327
+ "text": "boolean"
86328
+ },
86329
+ "default": "false",
86330
+ "description": "Whether this tab is currently active (its panel is visible).",
86331
+ "fieldName": "active"
86332
+ },
86628
86333
  {
86629
86334
  "name": "disabled",
86630
86335
  "type": {
86631
86336
  "text": "boolean"
86632
86337
  },
86633
86338
  "default": "false",
86634
- "description": "Disables all tabs in the group, preventing any tab from\nbeing selected.",
86339
+ "description": "Whether this tab is disabled (cannot be selected).",
86635
86340
  "fieldName": "disabled"
86636
86341
  },
86637
86342
  {
@@ -86676,61 +86381,97 @@
86676
86381
  "name": "EspalierElementBase",
86677
86382
  "module": "dist/shared/esp-element-base.js"
86678
86383
  },
86679
- "tagName": "esp-tab-group",
86384
+ "tagName": "esp-tab",
86680
86385
  "customElement": true,
86681
86386
  "docPageTitle": {
86682
86387
  "name": "Tab",
86683
- "description": "Group"
86388
+ "description": ""
86684
86389
  },
86685
86390
  "docUrl": {
86686
- "name": "/components/tabs",
86391
+ "name": "/components/tabs/tab",
86687
86392
  "description": ""
86688
86393
  },
86689
86394
  "menuGroup": {
86690
86395
  "name": "Navigation",
86691
86396
  "description": ""
86692
- },
86693
- "menuLabel": {
86694
- "name": "Tab",
86695
- "description": "Group"
86696
- },
86697
- "menuIcon": {
86698
- "name": "layout-navbar",
86699
- "description": ""
86700
86397
  }
86701
86398
  }
86702
86399
  ],
86703
86400
  "exports": [
86704
86401
  {
86705
86402
  "kind": "js",
86706
- "name": "EspalierTabGroup",
86403
+ "name": "EspalierTab",
86707
86404
  "declaration": {
86708
- "name": "EspalierTabGroup",
86709
- "module": "dist/tabs/esp-tab-group.js"
86405
+ "name": "EspalierTab",
86406
+ "module": "dist/tabs/esp-tab.js"
86710
86407
  }
86711
86408
  },
86712
86409
  {
86713
86410
  "kind": "custom-element-definition",
86714
- "name": "esp-tab-group",
86411
+ "name": "esp-tab",
86715
86412
  "declaration": {
86716
- "name": "EspalierTabGroup",
86717
- "module": "dist/tabs/esp-tab-group.js"
86413
+ "name": "EspalierTab",
86414
+ "module": "dist/tabs/esp-tab.js"
86718
86415
  }
86719
86416
  }
86720
86417
  ]
86721
86418
  },
86722
86419
  {
86723
86420
  "kind": "javascript-module",
86724
- "path": "dist/tabs/esp-tab.js",
86421
+ "path": "dist/switch/esp-switch.js",
86725
86422
  "declarations": [
86726
86423
  {
86727
86424
  "kind": "class",
86728
- "description": "A single tab panel used inside\n[esp-tab-group](/components/tabs). Each tab provides a\n`label` that appears in the generated tab strip and a default\nslot for the panel content.\n\n```html\n<esp-tab-group>\n <esp-tab label=\"First\">\n <p>Content for the first tab.</p>\n </esp-tab>\n <esp-tab label=\"Second\">\n <p>Content for the second tab.</p>\n </esp-tab>\n</esp-tab-group>\n```\n\n### Pre-selected tab\n\nSet the `active` attribute to make a tab active on load:\n\n```html\n<esp-tab-group>\n <esp-tab label=\"One\">\n <p>Not active by default.</p>\n </esp-tab>\n <esp-tab label=\"Two\" active>\n <p>This tab starts active.</p>\n </esp-tab>\n</esp-tab-group>\n```\n\n### Disabled tab\n\n```html\n<esp-tab-group>\n <esp-tab label=\"Enabled\">\n <p>This tab works normally.</p>\n </esp-tab>\n <esp-tab label=\"Disabled\" disabled>\n <p>Cannot reach this panel.</p>\n </esp-tab>\n</esp-tab-group>\n```",
86729
- "name": "EspalierTab",
86425
+ "description": "A toggle switch for boolean on/off values. Uses a CSS-only\ntrack-and-thumb design with a smooth sliding transition.\nFunctionally equivalent to a checkbox but visually communicates\nan immediate state change rather than a deferred selection.\n\n```html\n<esp-box>\n <esp-form-item label=\"Notifications\">\n <esp-switch value=\"notifications\">\n Enable notifications\n </esp-switch>\n </esp-form-item>\n</esp-box>\n```\n\n```html\n<esp-box>\n <esp-switch checked value=\"dark-mode\">\n Dark mode\n </esp-switch>\n <esp-switch disabled value=\"disabled-opt\">\n Disabled option\n </esp-switch>\n</esp-box>\n```\n\n### Text mode\n\nSet `mode=\"text\"` with `off-label` and `on-label` to render a\ntwo-option text toggle instead of a track and thumb. This is\nideal for binary choices like a billing-period selector:\n\n```html\n<esp-box>\n <esp-switch\n mode=\"text\"\n off-label=\"Monthly\"\n on-label=\"Annual\"\n value=\"annual\"\n >Billing period</esp-switch>\n</esp-box>\n```\n\nThe slotted text is visually hidden in text mode and folded\ninto the control's accessible label together with the current\nselected option. Screen readers will announce both the label\nand the active choice while the `off-label` / `on-label`\ntext is presented visually.",
86426
+ "name": "EspalierSwitch",
86730
86427
  "cssProperties": [
86731
86428
  {
86732
- "description": "Padding inside the panel area.",
86733
- "name": "--esp-tab-size-padding"
86429
+ "description": "The width of the switch track. Defaults to `calc(var(--esp-size-normal-to-medium) * 1.75)`.",
86430
+ "name": "--esp-switch-width"
86431
+ },
86432
+ {
86433
+ "description": "The height of the switch track. Defaults to `var(--esp-size-normal-to-medium)`.",
86434
+ "name": "--esp-switch-height"
86435
+ },
86436
+ {
86437
+ "description": "The diameter of the thumb. Defaults to `calc(var(--esp-switch-height) - 4px)`.",
86438
+ "name": "--esp-switch-thumb-size"
86439
+ },
86440
+ {
86441
+ "description": "The track background color when the switch is off. Defaults to `var(--esp-color-border)`.",
86442
+ "name": "--esp-switch-track-color"
86443
+ },
86444
+ {
86445
+ "description": "The track background color when the switch is on. Defaults to `var(--esp-color-action-background)`.",
86446
+ "name": "--esp-switch-track-color-on"
86447
+ },
86448
+ {
86449
+ "description": "The thumb color. Defaults to `var(--esp-color-layer-1)`.",
86450
+ "name": "--esp-switch-thumb-color"
86451
+ },
86452
+ {
86453
+ "description": "The color of the focus ring shadow. Defaults to `var(--esp-color-shadow)`.",
86454
+ "name": "--esp-switch-focus-shadow"
86455
+ },
86456
+ {
86457
+ "description": "Padding inside each text-mode label cell. Defaults to `var(--esp-size-tiny) var(--esp-size-small)`.",
86458
+ "name": "--esp-switch-text-padding"
86459
+ },
86460
+ {
86461
+ "description": "Font size for text-mode labels. Defaults to `var(--esp-size-font)`.",
86462
+ "name": "--esp-switch-text-font-size"
86463
+ },
86464
+ {
86465
+ "description": "Text color of the active label in text mode. Defaults to `var(--esp-color-action-text)`.",
86466
+ "name": "--esp-switch-text-active-color"
86467
+ },
86468
+ {
86469
+ "description": "Text color of the inactive label in text mode. Defaults to `var(--esp-color-layer-1)`.",
86470
+ "name": "--esp-switch-text-inactive-color"
86471
+ },
86472
+ {
86473
+ "description": "Background color of the sliding highlight in text mode. Defaults to `var(--esp-color-action-background)`.",
86474
+ "name": "--esp-switch-text-highlight-color"
86734
86475
  },
86735
86476
  {
86736
86477
  "description": "Background color of the shared field shell. Defaults to `var(--esp-color-layer-2)`.",
@@ -86789,42 +86530,131 @@
86789
86530
  }
86790
86531
  }
86791
86532
  ],
86792
- "cssParts": [
86793
- {
86794
- "description": "The panel wrapper element.",
86795
- "name": "panel"
86796
- }
86797
- ],
86798
86533
  "slots": [
86799
86534
  {
86800
- "description": "The default slot holds the panel content displayed when this tab is active. Label, active-state, and disabled-state updates are reported through a private coordination event consumed by the parent tab group.",
86535
+ "description": "The label text for the switch. In default mode this renders beside the track; in text mode it is visually hidden and included in the control's accessible label.",
86801
86536
  "name": ""
86802
86537
  }
86803
86538
  ],
86804
86539
  "members": [
86805
86540
  {
86806
86541
  "kind": "field",
86807
- "name": "label",
86542
+ "name": "formAssociated",
86543
+ "type": {
86544
+ "text": "boolean"
86545
+ },
86546
+ "static": true,
86547
+ "default": "true"
86548
+ },
86549
+ {
86550
+ "kind": "field",
86551
+ "name": "internals",
86552
+ "privacy": "private"
86553
+ },
86554
+ {
86555
+ "kind": "field",
86556
+ "name": "formCtrl",
86557
+ "privacy": "private",
86558
+ "default": "new FormFieldController({ host: this, internals: this.internals, getFormValue: () => (this.checked ? this.value || \"on\" : null), getValidity: () => { if (this.required && !this.checked) { return { flags: { valueMissing: true }, message: this.requiredMessage || \"Please toggle this switch to continue.\", }; } return null; }, onReset: () => { this.checked = false; }, onRestore: (state: string) => { this.checked = state === \"on\" || state === this.value; }, onDisabled: (isDisabled: boolean) => { this.disabled = isDisabled; }, })"
86559
+ },
86560
+ {
86561
+ "kind": "field",
86562
+ "name": "formItemDescription",
86563
+ "privacy": "private",
86564
+ "default": "new FormFieldDescriptionController({ host: this, getTarget: () => this.shadowRoot?.querySelector<HTMLElement>(\".switch-control\"), })"
86565
+ },
86566
+ {
86567
+ "kind": "field",
86568
+ "name": "mode",
86569
+ "type": {
86570
+ "text": "\"switch\" | \"text\""
86571
+ },
86572
+ "privacy": "public",
86573
+ "default": "\"switch\"",
86574
+ "description": "The visual presentation of the switch.\n- `\"switch\"` (default) renders a track-and-thumb toggle.\n- `\"text\"` renders two side-by-side text labels with a\n sliding highlight behind the active one.",
86575
+ "attribute": "mode",
86576
+ "reflects": true
86577
+ },
86578
+ {
86579
+ "kind": "field",
86580
+ "name": "offLabel",
86808
86581
  "type": {
86809
86582
  "text": "string"
86810
86583
  },
86811
86584
  "privacy": "public",
86812
86585
  "default": "\"\"",
86813
- "description": "The text displayed in the tab button within the tab strip.",
86814
- "attribute": "label"
86586
+ "description": "Label shown for the unchecked (off) state when\n`mode=\"text\"`.",
86587
+ "attribute": "off-label"
86815
86588
  },
86816
86589
  {
86817
86590
  "kind": "field",
86818
- "name": "active",
86591
+ "name": "onLabel",
86592
+ "type": {
86593
+ "text": "string"
86594
+ },
86595
+ "privacy": "public",
86596
+ "default": "\"\"",
86597
+ "description": "Label shown for the checked (on) state when\n`mode=\"text\"`.",
86598
+ "attribute": "on-label"
86599
+ },
86600
+ {
86601
+ "kind": "field",
86602
+ "name": "checked",
86819
86603
  "type": {
86820
86604
  "text": "boolean"
86821
86605
  },
86822
86606
  "privacy": "public",
86823
86607
  "default": "false",
86824
- "description": "Whether this tab is currently active (its panel is visible).",
86825
- "attribute": "active",
86608
+ "description": "Whether the switch is in the on state.",
86609
+ "attribute": "checked",
86610
+ "reflects": true
86611
+ },
86612
+ {
86613
+ "kind": "field",
86614
+ "name": "value",
86615
+ "type": {
86616
+ "text": "string"
86617
+ },
86618
+ "privacy": "public",
86619
+ "default": "\"\"",
86620
+ "description": "The value associated with this switch. Submitted with the\nform when the switch is on.",
86621
+ "attribute": "value"
86622
+ },
86623
+ {
86624
+ "kind": "field",
86625
+ "name": "name",
86626
+ "type": {
86627
+ "text": "string"
86628
+ },
86629
+ "privacy": "public",
86630
+ "default": "\"\"",
86631
+ "description": "The name used when the switch participates in a `<form>`.",
86632
+ "attribute": "name",
86633
+ "reflects": true
86634
+ },
86635
+ {
86636
+ "kind": "field",
86637
+ "name": "required",
86638
+ "type": {
86639
+ "text": "boolean"
86640
+ },
86641
+ "privacy": "public",
86642
+ "default": "false",
86643
+ "description": "When true, the switch must be on before the form can\nbe submitted.",
86644
+ "attribute": "required",
86826
86645
  "reflects": true
86827
86646
  },
86647
+ {
86648
+ "kind": "field",
86649
+ "name": "requiredMessage",
86650
+ "type": {
86651
+ "text": "string"
86652
+ },
86653
+ "privacy": "public",
86654
+ "default": "\"\"",
86655
+ "description": "A custom message to display when the switch is required but\nnot on. Defaults to `\"Please toggle this switch to continue.\"`\nwhen not set.\n\n```html\n<esp-switch required required-message=\"You must accept the terms.\">\n I accept\n</esp-switch>\n```",
86656
+ "attribute": "required-message"
86657
+ },
86828
86658
  {
86829
86659
  "kind": "field",
86830
86660
  "name": "disabled",
@@ -86833,10 +86663,156 @@
86833
86663
  },
86834
86664
  "privacy": "public",
86835
86665
  "default": "false",
86836
- "description": "Whether this tab is disabled (cannot be selected).",
86666
+ "description": "Controls whether the switch is disabled.",
86837
86667
  "attribute": "disabled",
86838
86668
  "reflects": true
86839
86669
  },
86670
+ {
86671
+ "kind": "method",
86672
+ "name": "focus",
86673
+ "privacy": "public",
86674
+ "return": {
86675
+ "type": {
86676
+ "text": "void"
86677
+ }
86678
+ },
86679
+ "parameters": [
86680
+ {
86681
+ "name": "options",
86682
+ "optional": true,
86683
+ "type": {
86684
+ "text": "FocusOptions"
86685
+ }
86686
+ }
86687
+ ],
86688
+ "description": "Focus the switch control."
86689
+ },
86690
+ {
86691
+ "kind": "method",
86692
+ "name": "validate",
86693
+ "privacy": "public",
86694
+ "return": {
86695
+ "type": {
86696
+ "text": "void"
86697
+ }
86698
+ },
86699
+ "description": "Re-run constraint validation and dispatch `esp-validity-changed`."
86700
+ },
86701
+ {
86702
+ "kind": "method",
86703
+ "name": "checkValidity",
86704
+ "privacy": "public",
86705
+ "return": {
86706
+ "type": {
86707
+ "text": "boolean"
86708
+ }
86709
+ },
86710
+ "description": "Check whether the current state is valid (delegates to ElementInternals)."
86711
+ },
86712
+ {
86713
+ "kind": "method",
86714
+ "name": "toggle",
86715
+ "privacy": "private",
86716
+ "return": {
86717
+ "type": {
86718
+ "text": "void"
86719
+ }
86720
+ }
86721
+ },
86722
+ {
86723
+ "kind": "method",
86724
+ "name": "handleKeyDown",
86725
+ "privacy": "private",
86726
+ "return": {
86727
+ "type": {
86728
+ "text": "void"
86729
+ }
86730
+ },
86731
+ "parameters": [
86732
+ {
86733
+ "name": "ev",
86734
+ "type": {
86735
+ "text": "KeyboardEvent"
86736
+ }
86737
+ }
86738
+ ]
86739
+ },
86740
+ {
86741
+ "kind": "method",
86742
+ "name": "handleLabelSlotChange",
86743
+ "privacy": "private",
86744
+ "return": {
86745
+ "type": {
86746
+ "text": "void"
86747
+ }
86748
+ }
86749
+ },
86750
+ {
86751
+ "kind": "method",
86752
+ "name": "getCurrentTextModeLabel",
86753
+ "privacy": "private",
86754
+ "return": {
86755
+ "type": {
86756
+ "text": "string"
86757
+ }
86758
+ }
86759
+ },
86760
+ {
86761
+ "kind": "method",
86762
+ "name": "getTextModeAriaLabel",
86763
+ "privacy": "private",
86764
+ "return": {
86765
+ "type": {
86766
+ "text": "string"
86767
+ }
86768
+ }
86769
+ },
86770
+ {
86771
+ "kind": "method",
86772
+ "name": "formResetCallback",
86773
+ "return": {
86774
+ "type": {
86775
+ "text": "void"
86776
+ }
86777
+ },
86778
+ "description": "Called by the browser when the owning `<form>` is reset."
86779
+ },
86780
+ {
86781
+ "kind": "method",
86782
+ "name": "formStateRestoreCallback",
86783
+ "return": {
86784
+ "type": {
86785
+ "text": "void"
86786
+ }
86787
+ },
86788
+ "parameters": [
86789
+ {
86790
+ "name": "state",
86791
+ "type": {
86792
+ "text": "string"
86793
+ }
86794
+ }
86795
+ ],
86796
+ "description": "Called by the browser to restore form state (bfcache, etc.)."
86797
+ },
86798
+ {
86799
+ "kind": "method",
86800
+ "name": "formDisabledCallback",
86801
+ "return": {
86802
+ "type": {
86803
+ "text": "void"
86804
+ }
86805
+ },
86806
+ "parameters": [
86807
+ {
86808
+ "name": "isDisabled",
86809
+ "type": {
86810
+ "text": "boolean"
86811
+ }
86812
+ }
86813
+ ],
86814
+ "description": "Called by the browser when a parent `<fieldset>` is enabled or disabled."
86815
+ },
86840
86816
  {
86841
86817
  "kind": "field",
86842
86818
  "name": "seedColorBacker",
@@ -87562,25 +87538,94 @@
87562
87538
  }
87563
87539
  }
87564
87540
  ],
87565
- "events": [],
87541
+ "events": [
87542
+ {
87543
+ "type": {
87544
+ "text": "CustomEvent<{ checked: boolean; value: string }>"
87545
+ },
87546
+ "description": "Fired when the switch is toggled. The detail contains the new `checked` state and the switch `value`.",
87547
+ "name": "esp-value-changed"
87548
+ },
87549
+ {
87550
+ "type": {
87551
+ "text": "CustomEvent<{ valid: boolean; message: string }>"
87552
+ },
87553
+ "description": "Fired whenever constraint validation runs.",
87554
+ "name": "esp-validity-changed"
87555
+ }
87556
+ ],
87566
87557
  "attributes": [
87567
87558
  {
87568
- "name": "label",
87559
+ "name": "mode",
87560
+ "type": {
87561
+ "text": "\"switch\" | \"text\""
87562
+ },
87563
+ "default": "\"switch\"",
87564
+ "description": "The visual presentation of the switch.\n- `\"switch\"` (default) renders a track-and-thumb toggle.\n- `\"text\"` renders two side-by-side text labels with a\n sliding highlight behind the active one.",
87565
+ "fieldName": "mode"
87566
+ },
87567
+ {
87568
+ "name": "off-label",
87569
87569
  "type": {
87570
87570
  "text": "string"
87571
87571
  },
87572
87572
  "default": "\"\"",
87573
- "description": "The text displayed in the tab button within the tab strip.",
87574
- "fieldName": "label"
87573
+ "description": "Label shown for the unchecked (off) state when\n`mode=\"text\"`.",
87574
+ "fieldName": "offLabel"
87575
87575
  },
87576
87576
  {
87577
- "name": "active",
87577
+ "name": "on-label",
87578
+ "type": {
87579
+ "text": "string"
87580
+ },
87581
+ "default": "\"\"",
87582
+ "description": "Label shown for the checked (on) state when\n`mode=\"text\"`.",
87583
+ "fieldName": "onLabel"
87584
+ },
87585
+ {
87586
+ "name": "checked",
87578
87587
  "type": {
87579
87588
  "text": "boolean"
87580
87589
  },
87581
87590
  "default": "false",
87582
- "description": "Whether this tab is currently active (its panel is visible).",
87583
- "fieldName": "active"
87591
+ "description": "Whether the switch is in the on state.",
87592
+ "fieldName": "checked"
87593
+ },
87594
+ {
87595
+ "name": "value",
87596
+ "type": {
87597
+ "text": "string"
87598
+ },
87599
+ "default": "\"\"",
87600
+ "description": "The value associated with this switch. Submitted with the\nform when the switch is on.",
87601
+ "fieldName": "value"
87602
+ },
87603
+ {
87604
+ "name": "name",
87605
+ "type": {
87606
+ "text": "string"
87607
+ },
87608
+ "default": "\"\"",
87609
+ "description": "The name used when the switch participates in a `<form>`.",
87610
+ "fieldName": "name"
87611
+ },
87612
+ {
87613
+ "name": "required",
87614
+ "type": {
87615
+ "text": "boolean"
87616
+ },
87617
+ "default": "false",
87618
+ "description": "When true, the switch must be on before the form can\nbe submitted.",
87619
+ "fieldName": "required"
87620
+ },
87621
+ {
87622
+ "name": "required-message",
87623
+ "type": {
87624
+ "text": "string"
87625
+ },
87626
+ "default": "\"\"",
87627
+ "description": "A custom message to display when the switch is required but\nnot on. Defaults to `\"Please toggle this switch to continue.\"`\nwhen not set.\n\n```html\n<esp-switch required required-message=\"You must accept the terms.\">\n I accept\n</esp-switch>\n```",
87628
+ "fieldName": "requiredMessage"
87584
87629
  },
87585
87630
  {
87586
87631
  "name": "disabled",
@@ -87588,7 +87633,7 @@
87588
87633
  "text": "boolean"
87589
87634
  },
87590
87635
  "default": "false",
87591
- "description": "Whether this tab is disabled (cannot be selected).",
87636
+ "description": "Controls whether the switch is disabled.",
87592
87637
  "fieldName": "disabled"
87593
87638
  },
87594
87639
  {
@@ -87633,37 +87678,45 @@
87633
87678
  "name": "EspalierElementBase",
87634
87679
  "module": "dist/shared/esp-element-base.js"
87635
87680
  },
87636
- "tagName": "esp-tab",
87637
- "customElement": true,
87638
87681
  "docPageTitle": {
87639
- "name": "Tab",
87682
+ "name": "Switch",
87640
87683
  "description": ""
87641
87684
  },
87642
87685
  "docUrl": {
87643
- "name": "/components/tabs/tab",
87686
+ "name": "/components/switch",
87644
87687
  "description": ""
87645
87688
  },
87646
87689
  "menuGroup": {
87647
- "name": "Navigation",
87690
+ "name": "Form",
87691
+ "description": "Controls"
87692
+ },
87693
+ "menuLabel": {
87694
+ "name": "Switch",
87648
87695
  "description": ""
87649
- }
87696
+ },
87697
+ "menuIcon": {
87698
+ "name": "button",
87699
+ "description": ""
87700
+ },
87701
+ "tagName": "esp-switch",
87702
+ "customElement": true
87650
87703
  }
87651
87704
  ],
87652
87705
  "exports": [
87653
87706
  {
87654
87707
  "kind": "js",
87655
- "name": "EspalierTab",
87708
+ "name": "EspalierSwitch",
87656
87709
  "declaration": {
87657
- "name": "EspalierTab",
87658
- "module": "dist/tabs/esp-tab.js"
87710
+ "name": "EspalierSwitch",
87711
+ "module": "dist/switch/esp-switch.js"
87659
87712
  }
87660
87713
  },
87661
87714
  {
87662
87715
  "kind": "custom-element-definition",
87663
- "name": "esp-tab",
87716
+ "name": "esp-switch",
87664
87717
  "declaration": {
87665
- "name": "EspalierTab",
87666
- "module": "dist/tabs/esp-tab.js"
87718
+ "name": "EspalierSwitch",
87719
+ "module": "dist/switch/esp-switch.js"
87667
87720
  }
87668
87721
  }
87669
87722
  ]