aeico-components 0.1.8 → 0.1.10

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.
Files changed (233) hide show
  1. package/README.md +0 -0
  2. package/dist/alert.cjs +20 -29
  3. package/dist/alert.cjs.map +3 -3
  4. package/dist/alert.js +20 -29
  5. package/dist/alert.js.map +3 -3
  6. package/dist/badge.cjs +19 -28
  7. package/dist/badge.cjs.map +3 -3
  8. package/dist/badge.js +19 -28
  9. package/dist/badge.js.map +3 -3
  10. package/dist/breadcrumb.cjs +22 -33
  11. package/dist/breadcrumb.cjs.map +3 -3
  12. package/dist/breadcrumb.js +22 -33
  13. package/dist/breadcrumb.js.map +3 -3
  14. package/dist/button-group.cjs +19 -28
  15. package/dist/button-group.cjs.map +3 -3
  16. package/dist/button-group.js +19 -28
  17. package/dist/button-group.js.map +3 -3
  18. package/dist/button.cjs +19 -29
  19. package/dist/button.cjs.map +3 -3
  20. package/dist/button.js +19 -29
  21. package/dist/button.js.map +3 -3
  22. package/dist/card.cjs +19 -29
  23. package/dist/card.cjs.map +3 -3
  24. package/dist/card.js +19 -29
  25. package/dist/card.js.map +3 -3
  26. package/dist/checkbox.cjs +21 -31
  27. package/dist/checkbox.cjs.map +3 -3
  28. package/dist/checkbox.js +21 -31
  29. package/dist/checkbox.js.map +3 -3
  30. package/dist/copy-button.cjs +25 -33
  31. package/dist/copy-button.cjs.map +2 -2
  32. package/dist/copy-button.js +25 -33
  33. package/dist/copy-button.js.map +3 -3
  34. package/dist/detail-group.cjs +19 -29
  35. package/dist/detail-group.cjs.map +3 -3
  36. package/dist/detail-group.js +19 -29
  37. package/dist/detail-group.js.map +3 -3
  38. package/dist/detail.cjs +19 -29
  39. package/dist/detail.cjs.map +3 -3
  40. package/dist/detail.js +19 -29
  41. package/dist/detail.js.map +3 -3
  42. package/dist/dialog.cjs +24 -32
  43. package/dist/dialog.cjs.map +2 -2
  44. package/dist/dialog.js +24 -32
  45. package/dist/dialog.js.map +3 -3
  46. package/dist/divider.cjs +20 -30
  47. package/dist/divider.cjs.map +3 -3
  48. package/dist/divider.js +20 -30
  49. package/dist/divider.js.map +3 -3
  50. package/dist/drawer.cjs +24 -32
  51. package/dist/drawer.cjs.map +2 -2
  52. package/dist/drawer.js +24 -32
  53. package/dist/drawer.js.map +3 -3
  54. package/dist/dropdown.cjs +31 -43
  55. package/dist/dropdown.cjs.map +3 -3
  56. package/dist/dropdown.js +31 -43
  57. package/dist/dropdown.js.map +3 -3
  58. package/dist/icon-button.cjs +25 -35
  59. package/dist/icon-button.cjs.map +3 -3
  60. package/dist/icon-button.js +25 -35
  61. package/dist/icon-button.js.map +3 -3
  62. package/dist/icon.cjs +20 -26
  63. package/dist/icon.cjs.map +2 -2
  64. package/dist/icon.js +20 -26
  65. package/dist/icon.js.map +2 -2
  66. package/dist/index.cjs +75 -113
  67. package/dist/index.cjs.map +3 -3
  68. package/dist/index.js +75 -113
  69. package/dist/index.js.map +3 -3
  70. package/dist/menu.cjs +20 -31
  71. package/dist/menu.cjs.map +3 -3
  72. package/dist/menu.js +20 -31
  73. package/dist/menu.js.map +3 -3
  74. package/dist/navbar.cjs +19 -29
  75. package/dist/navbar.cjs.map +3 -3
  76. package/dist/navbar.js +19 -29
  77. package/dist/navbar.js.map +3 -3
  78. package/dist/number-input.cjs +21 -31
  79. package/dist/number-input.cjs.map +3 -3
  80. package/dist/number-input.js +21 -31
  81. package/dist/number-input.js.map +3 -3
  82. package/dist/pagination.cjs +24 -33
  83. package/dist/pagination.cjs.map +2 -2
  84. package/dist/pagination.js +24 -33
  85. package/dist/pagination.js.map +3 -3
  86. package/dist/progress-bar.cjs +19 -29
  87. package/dist/progress-bar.cjs.map +3 -3
  88. package/dist/progress-bar.js +19 -29
  89. package/dist/progress-bar.js.map +3 -3
  90. package/dist/radio-group.cjs +24 -35
  91. package/dist/radio-group.cjs.map +3 -3
  92. package/dist/radio-group.js +24 -35
  93. package/dist/radio-group.js.map +3 -3
  94. package/dist/select.cjs +23 -34
  95. package/dist/select.cjs.map +3 -3
  96. package/dist/select.js +23 -34
  97. package/dist/select.js.map +3 -3
  98. package/dist/slider.cjs +21 -32
  99. package/dist/slider.cjs.map +3 -3
  100. package/dist/slider.js +21 -32
  101. package/dist/slider.js.map +3 -3
  102. package/dist/spinner.cjs +19 -29
  103. package/dist/spinner.cjs.map +3 -3
  104. package/dist/spinner.js +19 -29
  105. package/dist/spinner.js.map +3 -3
  106. package/dist/styles/layout.cjs +1 -1
  107. package/dist/styles/layout.js +1 -1
  108. package/dist/styles/radius.cjs +1 -1
  109. package/dist/styles/radius.js +1 -1
  110. package/dist/styles/variables.cjs +1 -1
  111. package/dist/styles/variables.js +1 -1
  112. package/dist/switch.cjs +26 -35
  113. package/dist/switch.cjs.map +3 -3
  114. package/dist/switch.js +26 -35
  115. package/dist/switch.js.map +3 -3
  116. package/dist/tabs.cjs +21 -30
  117. package/dist/tabs.cjs.map +3 -3
  118. package/dist/tabs.js +21 -30
  119. package/dist/tabs.js.map +3 -3
  120. package/dist/tag.cjs +19 -28
  121. package/dist/tag.cjs.map +3 -3
  122. package/dist/tag.js +19 -28
  123. package/dist/tag.js.map +3 -3
  124. package/dist/text-input.cjs +21 -31
  125. package/dist/text-input.cjs.map +3 -3
  126. package/dist/text-input.js +21 -31
  127. package/dist/text-input.js.map +3 -3
  128. package/dist/textarea.cjs +21 -31
  129. package/dist/textarea.cjs.map +3 -3
  130. package/dist/textarea.js +21 -31
  131. package/dist/textarea.js.map +3 -3
  132. package/dist/tooltip.cjs +19 -28
  133. package/dist/tooltip.cjs.map +3 -3
  134. package/dist/tooltip.js +19 -28
  135. package/dist/tooltip.js.map +3 -3
  136. package/dist/tree.cjs +25 -35
  137. package/dist/tree.cjs.map +3 -3
  138. package/dist/tree.js +25 -35
  139. package/dist/tree.js.map +3 -3
  140. package/dist/types/aeico-component.d.ts +1 -1
  141. package/dist/types/aeico-field.d.ts +1 -1
  142. package/dist/types/breadcrumb/breadcrumb-item.d.ts +0 -1
  143. package/dist/types/breadcrumb/breadcrumb.d.ts +2 -3
  144. package/dist/types/button-group/button-group.d.ts +1 -1
  145. package/dist/types/card/card.d.ts +0 -1
  146. package/dist/types/checkbox/checkbox.d.ts +0 -1
  147. package/dist/types/detail/detail.d.ts +0 -1
  148. package/dist/types/detail-group/detail-group.d.ts +1 -2
  149. package/dist/types/divider/divider.d.ts +0 -1
  150. package/dist/types/dropdown/dropdown-button.d.ts +4 -5
  151. package/dist/types/dropdown/dropdown-item.d.ts +3 -4
  152. package/dist/types/dropdown/dropdown.d.ts +4 -5
  153. package/dist/types/icon/icon.d.ts +0 -1
  154. package/dist/types/icon/registry.d.ts +1 -1
  155. package/dist/types/icon-button/icon-button.d.ts +0 -1
  156. package/dist/types/index.d.ts +4 -4
  157. package/dist/types/menu/menu-item.d.ts +3 -4
  158. package/dist/types/menu/menu.d.ts +3 -4
  159. package/dist/types/navbar/navbar.d.ts +5 -6
  160. package/dist/types/number-input/number-input.d.ts +0 -1
  161. package/dist/types/pagination/pagination.d.ts +0 -1
  162. package/dist/types/progress-bar/progress-bar.d.ts +0 -1
  163. package/dist/types/radio-group/radio-group.d.ts +0 -1
  164. package/dist/types/radio-group/radio.d.ts +6 -7
  165. package/dist/types/select/select-option.d.ts +0 -1
  166. package/dist/types/select/select.d.ts +0 -1
  167. package/dist/types/slider/defines.d.ts +5 -5
  168. package/dist/types/slider/slider.d.ts +0 -1
  169. package/dist/types/spinner/spinner.d.ts +1 -2
  170. package/dist/types/switch/switch.d.ts +0 -1
  171. package/dist/types/text-input/text-input.d.ts +0 -1
  172. package/dist/types/textarea/textarea.d.ts +0 -1
  173. package/dist/types/tree/tree-item.d.ts +1 -2
  174. package/dist/types/tree/tree.d.ts +0 -1
  175. package/package.json +5 -3
  176. package/src/aeico-component.ts +6 -5
  177. package/src/aeico-field.ts +2 -2
  178. package/src/alert/alert.ts +2 -2
  179. package/src/badge/badge.ts +2 -2
  180. package/src/breadcrumb/breadcrumb-item.ts +2 -4
  181. package/src/breadcrumb/breadcrumb.ts +4 -6
  182. package/src/button/button.ts +2 -2
  183. package/src/button-group/button-group.ts +3 -3
  184. package/src/card/card.ts +2 -4
  185. package/src/card/defines.ts +1 -1
  186. package/src/card/index.ts +1 -1
  187. package/src/checkbox/checkbox.ts +2 -4
  188. package/src/copy-button/copy-button.ts +1 -1
  189. package/src/detail/detail.ts +2 -4
  190. package/src/detail-group/detail-group.ts +2 -4
  191. package/src/dialog/dialog.ts +2 -2
  192. package/src/divider/divider.ts +2 -4
  193. package/src/drawer/drawer.ts +2 -2
  194. package/src/dropdown/dropdown-button.ts +6 -8
  195. package/src/dropdown/dropdown-item.ts +5 -7
  196. package/src/dropdown/dropdown.ts +7 -9
  197. package/src/icon/icon.ts +2 -4
  198. package/src/icon/registry.ts +1 -1
  199. package/src/icon-button/icon-button.ts +2 -4
  200. package/src/index.ts +4 -4
  201. package/src/menu/menu-item.ts +5 -7
  202. package/src/menu/menu.ts +4 -6
  203. package/src/navbar/navbar.ts +7 -9
  204. package/src/number-input/number-input.ts +1 -3
  205. package/src/pagination/pagination.ts +1 -3
  206. package/src/progress-bar/progress-bar.ts +1 -2
  207. package/src/radio-group/radio-group.ts +5 -7
  208. package/src/radio-group/radio.ts +8 -10
  209. package/src/select/select-option.ts +2 -4
  210. package/src/select/select.ts +4 -6
  211. package/src/slider/defines.ts +5 -5
  212. package/src/slider/slider.ts +5 -8
  213. package/src/spinner/spinner.ts +2 -4
  214. package/src/styles/components/action-button.css +1 -1
  215. package/src/styles/components/alert.css +1 -1
  216. package/src/styles/components/breadcrumb-item.css +2 -2
  217. package/src/styles/components/button.css +0 -1
  218. package/src/styles/components/divider.css +1 -1
  219. package/src/styles/components/dropdown-item.css +2 -2
  220. package/src/styles/components/dropdown.css +1 -1
  221. package/src/styles/layout.css +14 -14
  222. package/src/styles/radius.css +1 -1
  223. package/src/styles/variables.css +14 -16
  224. package/src/switch/switch.ts +2 -4
  225. package/src/tabs/tab-panel.ts +2 -2
  226. package/src/tabs/tab.ts +2 -2
  227. package/src/tabs/tabs.ts +2 -2
  228. package/src/tag/tag.ts +2 -2
  229. package/src/text-input/text-input.ts +2 -4
  230. package/src/textarea/textarea.ts +1 -3
  231. package/src/tooltip/tooltip.ts +1 -1
  232. package/src/tree/tree-item.ts +3 -5
  233. package/src/tree/tree.ts +2 -4
@@ -1,4 +1,4 @@
1
- import AeicoComponent from '../aeico-component';
1
+ import AeicoComponent from '../aeico-component';
2
2
  import type { InferProps } from 'aeico';
3
3
  import { html } from 'aeico';
4
4
  import { prop } from 'aeico';
@@ -9,7 +9,7 @@ import './dropdown';
9
9
  import '../button/button';
10
10
 
11
11
  /**
12
- * DropdownButton a pre-composed trigger + dropdown panel.
12
+ * DropdownButton - a pre-composed trigger + dropdown panel.
13
13
  *
14
14
  * Renders an `ae-button`-styled trigger with a built-in chevron,
15
15
  * and a floating panel for `<ae-dropdown-item>` children.
@@ -35,13 +35,11 @@ import '../button/button';
35
35
  * ```
36
36
  *
37
37
  * Emits:
38
- * - `open` when the panel opens
39
- * - `close` when the panel closes
40
- * - `select` `{ detail: { value, label } }` when a menu item is selected
38
+ * - `open` - when the panel opens
39
+ * - `close` - when the panel closes
40
+ * - `select` - `{ detail: { value, label } }` when a menu item is selected
41
41
  */
42
42
  class DropdownButton extends AeicoComponent {
43
- static tagName = 'dropdown-button';
44
-
45
43
  // ae-button and ae-dropdown each carry their own shadow DOM styles.
46
44
  // Only the host display is set here so button-group compact layout works.
47
45
  protected static styles = [
@@ -118,7 +116,7 @@ class DropdownButton extends AeicoComponent {
118
116
  }
119
117
  }
120
118
 
121
- DropdownButton.register();
119
+ DropdownButton.define('dropdown-button');
122
120
 
123
121
  declare global {
124
122
  interface HTMLElementTagNameMap {
@@ -1,4 +1,4 @@
1
- import AeicoComponent from '../aeico-component';
1
+ import AeicoComponent from '../aeico-component';
2
2
  import type { InferProps } from 'aeico';
3
3
  import { html } from 'aeico';
4
4
  import style from '../styles/components/dropdown-item.css';
@@ -8,7 +8,7 @@ import { prop } from 'aeico';
8
8
  import '../icon/icon';
9
9
 
10
10
  /**
11
- * Dropdown menu item used as a direct child of `<ae-dropdown>`.
11
+ * Dropdown menu item - used as a direct child of `<ae-dropdown>`.
12
12
  *
13
13
  * Renders as a `<button>` by default, or as an `<a>` anchor when `href` is set.
14
14
  * Use `<ae-icon>` inside to add icons, and CSS `color` / `--dropdown-item-color`
@@ -22,13 +22,11 @@ import '../icon/icon';
22
22
  * ```
23
23
  */
24
24
  class DropdownItem extends AeicoComponent {
25
- static tagName = 'dropdown-item';
26
-
27
25
  /** Value emitted in the `select` event detail on the parent dropdown. */
28
26
  @prop({ type: String })
29
27
  accessor value: string | undefined;
30
28
 
31
- /** Disables the item it becomes non-interactive and visually dimmed. */
29
+ /** Disables the item - it becomes non-interactive and visually dimmed. */
32
30
  @prop({ type: Boolean })
33
31
  accessor disabled: boolean = false;
34
32
 
@@ -55,7 +53,7 @@ class DropdownItem extends AeicoComponent {
55
53
 
56
54
  /**
57
55
  * Marks the item as the currently active/selected option (e.g. current route,
58
- * current sort order). Purely visual applies a highlighted background and
56
+ * current sort order). Purely visual - applies a highlighted background and
59
57
  * accent colour.
60
58
  */
61
59
  @prop({ type: Boolean })
@@ -124,7 +122,7 @@ class DropdownItem extends AeicoComponent {
124
122
  }
125
123
  }
126
124
 
127
- DropdownItem.register();
125
+ DropdownItem.define('dropdown-item');
128
126
 
129
127
  declare global {
130
128
  interface HTMLElementTagNameMap {
@@ -1,4 +1,4 @@
1
- import AeicoComponent from '../aeico-component';
1
+ import AeicoComponent from '../aeico-component';
2
2
  import type { InferProps } from 'aeico';
3
3
  import { html } from 'aeico';
4
4
  import { prop } from 'aeico';
@@ -9,15 +9,15 @@ import type { DropdownPlacement } from './defines';
9
9
  import './dropdown-item';
10
10
 
11
11
  /**
12
- * Dropdown component renders a floating menu panel anchored to a trigger slot.
12
+ * Dropdown component - renders a floating menu panel anchored to a trigger slot.
13
13
  *
14
14
  * The trigger is provided via `slot="trigger"` (typically an `<ae-button>`).
15
15
  * Menu items are provided as `<ae-dropdown-item>` default-slot children.
16
16
  *
17
17
  * Emits:
18
- * - `open` when the panel opens
19
- * - `close` when the panel closes
20
- * - `select` `{ detail: { value, label } }` when a menu item is clicked
18
+ * - `open` - when the panel opens
19
+ * - `close` - when the panel closes
20
+ * - `select` - `{ detail: { value, label } }` when a menu item is clicked
21
21
  *
22
22
  * @example
23
23
  * ```html
@@ -42,8 +42,6 @@ import './dropdown-item';
42
42
  * ```
43
43
  */
44
44
  class Dropdown extends AeicoComponent {
45
- static tagName = 'dropdown';
46
-
47
45
  protected static styles = [variables, style];
48
46
 
49
47
  /**
@@ -133,7 +131,7 @@ class Dropdown extends AeicoComponent {
133
131
 
134
132
  // Called via declarative @click on the trigger-wrapper div inside the shadow DOM.
135
133
  // Events from slotted trigger content bubble through the shadow DOM slot path,
136
- // so this fires for trigger clicks only not for panel item clicks.
134
+ // so this fires for trigger clicks only - not for panel item clicks.
137
135
  private _handleTriggerClick = (): void => {
138
136
  this.toggle();
139
137
  };
@@ -199,7 +197,7 @@ class Dropdown extends AeicoComponent {
199
197
  }
200
198
  }
201
199
 
202
- Dropdown.register();
200
+ Dropdown.define('dropdown');
203
201
 
204
202
  declare global {
205
203
  interface HTMLElementTagNameMap {
package/src/icon/icon.ts CHANGED
@@ -1,4 +1,4 @@
1
- import type { InferProps, Props } from 'aeico';
1
+ import type { InferProps, Props } from 'aeico';
2
2
  import { SVG_NS } from '../utils';
3
3
  import AeicoComponent from '../aeico-component';
4
4
  import { html } from 'aeico';
@@ -12,8 +12,6 @@ import IconRegistry from './registry';
12
12
  import './built-in-icons';
13
13
 
14
14
  class Icon extends AeicoComponent {
15
- static tagName = 'icon';
16
-
17
15
  static props: Props = {
18
16
  name: { type: String },
19
17
  size: { type: String },
@@ -91,7 +89,7 @@ class Icon extends AeicoComponent {
91
89
  }
92
90
  }
93
91
 
94
- Icon.register();
92
+ Icon.define('icon');
95
93
 
96
94
  declare global {
97
95
  interface HTMLElementTagNameMap {
@@ -2,7 +2,7 @@ import { IconDefinition, IconRegistryData, defaultViewBox } from './defines';
2
2
 
3
3
  class IconRegistry {
4
4
  private static _icons: Map<string, IconDefinition> = new Map();
5
- /** Names registered via addBuiltIn can be overridden by user add() calls */
5
+ /** Names registered via addBuiltIn - can be overridden by user add() calls */
6
6
  private static _builtInKeys: Set<string> = new Set();
7
7
 
8
8
  /** Register user icons. Always takes priority over built-in icons. */
@@ -1,4 +1,4 @@
1
- import type { InferProps, Props } from 'aeico';
1
+ import type { InferProps, Props } from 'aeico';
2
2
  import AeicoComponent from '../aeico-component';
3
3
  import { html } from 'aeico';
4
4
  import type { IconColor } from '../icon/defines';
@@ -17,8 +17,6 @@ export type IconButtonSize = 'xs' | 'sm' | 'md' | 'lg';
17
17
  * ```
18
18
  */
19
19
  class IconButton extends AeicoComponent {
20
- static tagName = 'icon-button';
21
-
22
20
  static props: Props = {
23
21
  icon: { type: String },
24
22
  size: { type: String },
@@ -52,7 +50,7 @@ class IconButton extends AeicoComponent {
52
50
  }
53
51
  }
54
52
 
55
- IconButton.register();
53
+ IconButton.define('icon-button');
56
54
 
57
55
  declare global {
58
56
  interface HTMLElementTagNameMap {
package/src/index.ts CHANGED
@@ -9,12 +9,12 @@
9
9
  * import { SelectField, RangeField, Button } from 'aeico/components'
10
10
  *
11
11
  * // Manually register components
12
- * SelectField.register()
13
- * RangeField.register()
14
- * Button.register()
12
+ * SelectField.define()
13
+ * RangeField.define()
14
+ * Button.define()
15
15
  *
16
16
  * // Or use with custom names
17
- * SelectField.register('my-select')
17
+ * SelectField.define('my-select')
18
18
  * ```
19
19
  *
20
20
  * @example
@@ -12,7 +12,7 @@ import type {
12
12
  } from './defines';
13
13
 
14
14
  /**
15
- * Menu item used as a direct child of `<ae-menu>` or nested inside another
15
+ * Menu item - used as a direct child of `<ae-menu>` or nested inside another
16
16
  * `<ae-menu-item>` to create a two-level submenu.
17
17
  *
18
18
  * - **Leaf item**: omit `label`; slot contains the item text.
@@ -20,8 +20,8 @@ import type {
20
20
  * `<ae-menu-item>` elements that appear in the submenu panel/section.
21
21
  *
22
22
  * **Slots (parent items only)**
23
- * - `expand` icon shown when the submenu is closed (default: CSS triangle).
24
- * - `collapse` icon shown when the submenu is open (default: rotated CSS triangle).
23
+ * - `expand` - icon shown when the submenu is closed (default: CSS triangle).
24
+ * - `collapse` - icon shown when the submenu is open (default: rotated CSS triangle).
25
25
  *
26
26
  * @example
27
27
  * ```html
@@ -33,8 +33,6 @@ import type {
33
33
  * ```
34
34
  */
35
35
  class MenuItem extends AeicoComponent {
36
- static tagName = 'menu-item';
37
-
38
36
  protected static styles = [variables, style];
39
37
 
40
38
  @prop({ type: String })
@@ -68,7 +66,7 @@ class MenuItem extends AeicoComponent {
68
66
  const depth = this.parentElement?.closest('ae-menu-item') ? 1 : 0;
69
67
  this.dataset.depth = String(depth);
70
68
 
71
- // Hover listeners check mode/trigger at runtime
69
+ // Hover listeners - check mode/trigger at runtime
72
70
  this.listen('mouseenter', this._handleMouseEnter);
73
71
  this.listen('mouseleave', this._handleMouseLeave);
74
72
 
@@ -312,7 +310,7 @@ class MenuItem extends AeicoComponent {
312
310
  }
313
311
  }
314
312
 
315
- MenuItem.register();
313
+ MenuItem.define('menu-item');
316
314
 
317
315
  declare global {
318
316
  interface HTMLElementTagNameMap {
package/src/menu/menu.ts CHANGED
@@ -12,16 +12,14 @@ import './menu-item';
12
12
  * optional two-level flyout or inline (accordion) submenus.
13
13
  *
14
14
  * Two modes:
15
- * - `flyout` (default) submenus open as floating panels (like a nav bar or
15
+ * - `flyout` (default) - submenus open as floating panels (like a nav bar or
16
16
  * context menu).
17
- * - `inline` submenus expand in-place (accordion-style sidebar).
17
+ * - `inline` - submenus expand in-place (accordion-style sidebar).
18
18
  *
19
19
  * Emits:
20
- * - `select` `{ detail: { key, label, keyPath } }` when a leaf item is clicked.
20
+ * - `select` - `{ detail: { key, label, keyPath } }` when a leaf item is clicked.
21
21
  */
22
22
  class Menu extends AeicoComponent {
23
- static tagName = 'menu';
24
-
25
23
  protected static styles = [variables, style];
26
24
 
27
25
  @prop({ type: String })
@@ -72,7 +70,7 @@ class Menu extends AeicoComponent {
72
70
  }
73
71
  }
74
72
 
75
- Menu.register();
73
+ Menu.define('menu');
76
74
 
77
75
  declare global {
78
76
  interface HTMLElementTagNameMap {
@@ -1,4 +1,4 @@
1
- import type { InferProps } from 'aeico';
1
+ import type { InferProps } from 'aeico';
2
2
  import styleVariables from '../styles/variables.css';
3
3
  import colorCSS from '../styles/color.css';
4
4
  import navbarStyle from '../styles/components/navbar.css';
@@ -14,9 +14,9 @@ import type { NavbarColor, NavbarAppearance } from './defines';
14
14
  * mobile hamburger collapse.
15
15
  *
16
16
  * Slots:
17
- * - `brand` leftmost area, typically a logo or site name link
18
- * - `start` main navigation links / dropdowns
19
- * - `end` right-side actions (login button, avatar, etc.)
17
+ * - `brand` - leftmost area, typically a logo or site name link
18
+ * - `start` - main navigation links / dropdowns
19
+ * - `end` - right-side actions (login button, avatar, etc.)
20
20
  *
21
21
  * Slotted `<a>` elements receive default link styling controlled via
22
22
  * CSS custom properties. Mark the active link with `aria-current="page"`.
@@ -43,8 +43,6 @@ import type { NavbarColor, NavbarAppearance } from './defines';
43
43
  * ```
44
44
  */
45
45
  class Navbar extends AeicoComponent {
46
- static tagName = 'navbar';
47
-
48
46
  protected static styles = [styleVariables, colorCSS, navbarStyle];
49
47
 
50
48
  /** Background color using the design-system color token set. */
@@ -57,8 +55,8 @@ class Navbar extends AeicoComponent {
57
55
 
58
56
  /**
59
57
  * Hover style preset for slotted `<a>` links.
60
- * - `text` only the font color changes on hover (default)
61
- * - `block` a subtle filled background block appears on hover
58
+ * - `text` - only the font color changes on hover (default)
59
+ * - `block` - a subtle filled background block appears on hover
62
60
  *
63
61
  * Fine-tune further with `--ae-navbar-link-hover-color` /
64
62
  * `--ae-navbar-link-hover-bg` CSS variables.
@@ -148,7 +146,7 @@ class Navbar extends AeicoComponent {
148
146
  }
149
147
  }
150
148
 
151
- Navbar.register();
149
+ Navbar.define('navbar');
152
150
 
153
151
  declare global {
154
152
  interface HTMLElementTagNameMap {
@@ -10,8 +10,6 @@ import style from '../styles/components/number-input.css';
10
10
  class NumberInput extends AeicoField<number> {
11
11
  protected fieldElement: HTMLInputElement | null = null;
12
12
 
13
- static tagName = 'number-input';
14
-
15
13
  static props: Props = {
16
14
  placeholder: { type: String },
17
15
  min: { type: Number },
@@ -125,7 +123,7 @@ class NumberInput extends AeicoField<number> {
125
123
  }
126
124
  }
127
125
 
128
- NumberInput.register();
126
+ NumberInput.define('number-input');
129
127
 
130
128
  declare global {
131
129
  interface HTMLElementTagNameMap {
@@ -46,8 +46,6 @@ type PageItem = number | 'ellipsis-start' | 'ellipsis-end';
46
46
  * ```
47
47
  */
48
48
  class Pagination extends AeicoComponent {
49
- static tagName = 'pagination';
50
-
51
49
  protected static styles = [styleVariables, sizeCSS, paginationStyle];
52
50
 
53
51
  @prop({ type: Number })
@@ -298,7 +296,7 @@ class Pagination extends AeicoComponent {
298
296
  }
299
297
  }
300
298
 
301
- Pagination.register();
299
+ Pagination.define('pagination');
302
300
 
303
301
  declare global {
304
302
  interface HTMLElementTagNameMap {
@@ -25,7 +25,6 @@ import type { ProgressBarColor } from './defines';
25
25
  * When set, takes precedence over the `color` prop entirely.
26
26
  */
27
27
  class ProgressBar extends AeicoComponent {
28
- static tagName = 'progress-bar';
29
28
  protected static styles = [styleVariables, colorCSS, style];
30
29
 
31
30
  @prop({ type: Number })
@@ -68,7 +67,7 @@ class ProgressBar extends AeicoComponent {
68
67
  }
69
68
  }
70
69
 
71
- ProgressBar.register();
70
+ ProgressBar.define('progress-bar');
72
71
 
73
72
  declare global {
74
73
  interface HTMLElementTagNameMap {
@@ -1,4 +1,4 @@
1
- import AeicoField from '../aeico-field';
1
+ import AeicoField from '../aeico-field';
2
2
  import type { InferProps, Props } from 'aeico';
3
3
  import { html, tags } from 'aeico';
4
4
  import type { ButtonColor, ButtonVariant, ButtonSize } from '../button';
@@ -20,8 +20,6 @@ class RadioGroup extends AeicoField {
20
20
  private static _instanceCount = 0;
21
21
  private readonly _groupName: string;
22
22
 
23
- static tagName = 'radio-group';
24
-
25
23
  static props: Props = {
26
24
  options: { type: Array },
27
25
  mode: { type: String },
@@ -82,7 +80,7 @@ class RadioGroup extends AeicoField {
82
80
  this.update();
83
81
  }
84
82
 
85
- // Single handler for radio inputs handles both select and deselect.
83
+ // Single handler for radio inputs - handles both select and deselect.
86
84
  // Only uses `click` (not `change`) because `change` fires before `click`;
87
85
  // if we set value in `change`, the `click` handler would see the updated
88
86
  // value and immediately deselect.
@@ -155,7 +153,7 @@ class RadioGroup extends AeicoField {
155
153
  this.renderResetButton();
156
154
  }
157
155
 
158
- // Hidden slot captures <option> light DOM children
156
+ // Hidden slot - captures <option> light DOM children
159
157
  this._slotEl = slot({
160
158
  style: { display: 'none' },
161
159
  '@slotchange': () => this._onSlotChange(),
@@ -184,7 +182,7 @@ class RadioGroup extends AeicoField {
184
182
  required: Boolean(this.required),
185
183
  '@click': this._boundOnRadioClick,
186
184
  });
187
- // Sync DOM property directly setAttribute('checked') doesn't work
185
+ // Sync DOM property directly - setAttribute('checked') doesn't work
188
186
  // after user interaction; only the .checked property controls state.
189
187
  el.checked = isChecked;
190
188
  // Keep fieldElement pointing to first radio for base-class compat
@@ -226,7 +224,7 @@ class RadioGroup extends AeicoField {
226
224
  }
227
225
  }
228
226
 
229
- RadioGroup.register();
227
+ RadioGroup.define('radio-group');
230
228
 
231
229
  declare global {
232
230
  interface HTMLElementTagNameMap {
@@ -1,16 +1,16 @@
1
- import AeicoComponent from '../aeico-component';
1
+ import AeicoComponent from '../aeico-component';
2
2
  import type { InferProps, Props } from 'aeico';
3
3
 
4
4
  /**
5
- * AeRadio structured option element for ae-radio-group.
5
+ * AeRadio - structured option element for ae-radio-group.
6
6
  *
7
7
  * Replaces the native `<option>` approach with a custom element that is
8
8
  * fully extensible. Current surface:
9
- * - `value` option value submitted / matched against radio-group value
10
- * - `disabled` disables this individual option (independent of the group)
11
- * - Light DOM label content; can be plain text or rich HTML (icons, etc.)
9
+ * - `value` - option value submitted / matched against radio-group value
10
+ * - `disabled` - disables this individual option (independent of the group)
11
+ * - Light DOM - label content; can be plain text or rich HTML (icons, etc.)
12
12
  *
13
- * This element has **no shadow DOM** it is a pure data / content carrier.
13
+ * This element has **no shadow DOM** - it is a pure data / content carrier.
14
14
  * ae-radio-group reads its properties and light-DOM content, then renders
15
15
  * the appropriate UI (radio input, button, segmented pill, …).
16
16
  *
@@ -32,9 +32,7 @@ import type { InferProps, Props } from 'aeico';
32
32
  * ```
33
33
  */
34
34
  class Radio extends AeicoComponent {
35
- static tagName = 'radio';
36
-
37
- /** No shadow DOM — this element is a transparent data/content carrier. */
35
+ /** No shadow DOM - this element is a transparent data/content carrier. */
38
36
  static override useShadowDOM = false;
39
37
 
40
38
  static override props: Props = {
@@ -46,7 +44,7 @@ class Radio extends AeicoComponent {
46
44
  declare disabled?: boolean;
47
45
  }
48
46
 
49
- Radio.register();
47
+ Radio.define('radio');
50
48
 
51
49
  declare global {
52
50
  interface HTMLElementTagNameMap {
@@ -1,4 +1,4 @@
1
- import AeicoComponent from '../aeico-component';
1
+ import AeicoComponent from '../aeico-component';
2
2
  import type { InferProps } from 'aeico';
3
3
  import { html } from 'aeico';
4
4
  import style from '../styles/components/select-option.css';
@@ -6,8 +6,6 @@ import variables from '../styles/variables.css';
6
6
  import { prop } from 'aeico';
7
7
 
8
8
  class SelectOption extends AeicoComponent {
9
- static tagName = 'select-option';
10
-
11
9
  @prop({ type: String })
12
10
  accessor value: string | undefined;
13
11
 
@@ -47,7 +45,7 @@ class SelectOption extends AeicoComponent {
47
45
  }
48
46
  }
49
47
 
50
- SelectOption.register();
48
+ SelectOption.define('select-option');
51
49
 
52
50
  declare global {
53
51
  interface HTMLElementTagNameMap {
@@ -1,4 +1,4 @@
1
- import AeicoField from '../aeico-field';
1
+ import AeicoField from '../aeico-field';
2
2
  import type { InferProps } from 'aeico';
3
3
  import { html, tags } from 'aeico';
4
4
  import type {
@@ -37,8 +37,6 @@ class Select extends AeicoField<SelectOptionValue | SelectMultiValue> {
37
37
  private _slotOptionData: Array<{ value: string; label: string }> = [];
38
38
  private _selectedListEl: HTMLElement | null = null;
39
39
 
40
- static tagName = 'select';
41
-
42
40
  @prop({ type: Boolean, observe: false, reflect: false })
43
41
  accessor _expanded: boolean = false;
44
42
 
@@ -122,7 +120,7 @@ class Select extends AeicoField<SelectOptionValue | SelectMultiValue> {
122
120
  }
123
121
 
124
122
  protected onDisabledChanged(_newValue: boolean): void {
125
- // disabled is a reactive prop render() already picks it up automatically
123
+ // disabled is a reactive prop - render() already picks it up automatically
126
124
  }
127
125
 
128
126
  protected onUpdated(changedProps: Map<string, unknown>): void {
@@ -345,7 +343,7 @@ class Select extends AeicoField<SelectOptionValue | SelectMultiValue> {
345
343
  this.renderError();
346
344
 
347
345
  // Visually-hidden input so native form constraint validation works for `required`.
348
- // type="text" (not "hidden") is required type="hidden" is exempt from constraint validation.
346
+ // type="text" (not "hidden") is required - type="hidden" is exempt from constraint validation.
349
347
  const currentValue =
350
348
  this.value != null &&
351
349
  this.value !== '' &&
@@ -416,7 +414,7 @@ class Select extends AeicoField<SelectOptionValue | SelectMultiValue> {
416
414
  }
417
415
  }
418
416
 
419
- Select.register();
417
+ Select.define('select');
420
418
 
421
419
  declare global {
422
420
  interface HTMLElementTagNameMap {
@@ -15,8 +15,8 @@ export type NormalizedOption = {
15
15
 
16
16
  /**
17
17
  * A single mark on the slider track.
18
- * - `number` mark at that numeric position, no label
19
- * - `{ value, label? }` mark at `value` with optional label
18
+ * - `number` - mark at that numeric position, no label
19
+ * - `{ value, label? }` - mark at `value` with optional label
20
20
  *
21
21
  * Marks are purely visual; they do NOT constrain snapping.
22
22
  * The slider still snaps according to `step` / `options`.
@@ -26,8 +26,8 @@ export type MarkItem = number | { value: number; label?: string };
26
26
 
27
27
  /**
28
28
  * The `marks` prop accepts:
29
- * - `true` auto-generate marks (at option positions, or min+max in free mode)
30
- * - `MarkItem[]` custom marks at the given positions
31
- * - `false` / omitted no marks
29
+ * - `true` - auto-generate marks (at option positions, or min+max in free mode)
30
+ * - `MarkItem[]` - custom marks at the given positions
31
+ * - `false` / omitted - no marks
32
32
  */
33
33
  export type SliderMarks = boolean | MarkItem[];
@@ -1,4 +1,4 @@
1
- import AeicoField from '../aeico-field';
1
+ import AeicoField from '../aeico-field';
2
2
  import type { InferProps } from 'aeico';
3
3
  import { html, tags } from 'aeico';
4
4
  import type { NormalizedOption, SliderMarks, SliderOption, SliderOptions } from './defines';
@@ -18,8 +18,6 @@ class Slider extends AeicoField {
18
18
  private _boundOnRangeInput: () => void;
19
19
  private _boundOnNumberInput: () => void;
20
20
 
21
- static tagName = 'slider';
22
-
23
21
  @prop({ type: Array })
24
22
  accessor options: SliderOptions = [];
25
23
 
@@ -43,7 +41,6 @@ class Slider extends AeicoField {
43
41
 
44
42
  @prop({
45
43
  type: Array,
46
- // bare attribute (<ae-slider marks>) → true; JSON array → MarkItem[]
47
44
  parser: (value: string | null) => {
48
45
  if (value === null) return undefined;
49
46
  if (value === '' || value === 'true') return true;
@@ -180,7 +177,7 @@ class Slider extends AeicoField {
180
177
 
181
178
  const marks = this.marks;
182
179
 
183
- // Custom marks array purely visual, no snapping effect
180
+ // Custom marks array - purely visual, no snapping effect
184
181
  if (Array.isArray(marks)) {
185
182
  const result: Array<{ value: string; label: string; pct: number }> = [];
186
183
  for (const m of marks) {
@@ -198,7 +195,7 @@ class Slider extends AeicoField {
198
195
  return result;
199
196
  }
200
197
 
201
- // marks === true auto-generate from options or free-mode endpoints
198
+ // marks === true - auto-generate from options or free-mode endpoints
202
199
  if (normalized) {
203
200
  return normalized.map((o) => ({
204
201
  value: o.value,
@@ -207,7 +204,7 @@ class Slider extends AeicoField {
207
204
  }));
208
205
  }
209
206
 
210
- // Free mode show min and max endpoints only
207
+ // Free mode - show min and max endpoints only
211
208
  return [
212
209
  { value: attrs.min, label: this.percentage ? `${minVal}%` : String(minVal), pct: 0 },
213
210
  { value: attrs.max, label: this.percentage ? `${maxVal}%` : String(maxVal), pct: 100 },
@@ -359,7 +356,7 @@ class Slider extends AeicoField {
359
356
  }
360
357
  }
361
358
 
362
- Slider.register();
359
+ Slider.define('slider');
363
360
 
364
361
  declare global {
365
362
  interface HTMLElementTagNameMap {
@@ -8,7 +8,7 @@ import style from '../styles/components/spinner.css';
8
8
  import type { SpinnerColor, SpinnerSize, SpinnerVariant } from './defines';
9
9
 
10
10
  /**
11
- * Spinner animated loading indicator.
11
+ * Spinner - animated loading indicator.
12
12
  *
13
13
  * Supports two visual variants: a rotating ring (`border`, default) and
14
14
  * three bouncing dots (`dots`). Size and colour are driven by the shared
@@ -22,8 +22,6 @@ import type { SpinnerColor, SpinnerSize, SpinnerVariant } from './defines';
22
22
  * ```
23
23
  */
24
24
  class Spinner extends AeicoComponent {
25
- static tagName = 'spinner';
26
-
27
25
  @prop({ type: String })
28
26
  accessor variant: SpinnerVariant = 'border';
29
27
 
@@ -69,7 +67,7 @@ class Spinner extends AeicoComponent {
69
67
  }
70
68
  }
71
69
 
72
- Spinner.register();
70
+ Spinner.define('spinner');
73
71
 
74
72
  declare global {
75
73
  interface HTMLElementTagNameMap {
@@ -1,4 +1,4 @@
1
- /* Action button base styles shared by clear-btn and reset-btn (standalone mode) */
1
+ /* Action button base styles - shared by clear-btn and reset-btn (standalone mode) */
2
2
  .clear-btn:not(.action-btn),
3
3
  .reset-btn:not(.action-btn) {
4
4
  width: 1.333em;