@reliability-design/web 1.0.2 → 1.0.3

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 (54) hide show
  1. package/dist/components/rel-accordion/rel-accordion.ts +27 -22
  2. package/dist/components/rel-alert/rel-alert.ts +98 -66
  3. package/dist/components/rel-avatar/rel-avatar.ts +8 -15
  4. package/dist/components/rel-badge/rel-badge.ts +23 -16
  5. package/dist/components/rel-breadcrumb/rel-breadcrumb.ts +12 -12
  6. package/dist/components/rel-button/rel-button.ts +39 -59
  7. package/dist/components/rel-card/rel-card.ts +11 -10
  8. package/dist/components/rel-cardmedia/rel-cardmedia.ts +11 -17
  9. package/dist/components/rel-checkbox/rel-checkbox.ts +18 -35
  10. package/dist/components/rel-chip/rel-chip.ts +37 -128
  11. package/dist/components/rel-container/rel-container.ts +1 -6
  12. package/dist/components/rel-divider/rel-divider.ts +37 -37
  13. package/dist/components/rel-layout/rel-layout.ts +12 -14
  14. package/dist/components/rel-progress/rel-progress.ts +26 -15
  15. package/dist/components/rel-radio/rel-radio.ts +32 -72
  16. package/dist/components/rel-snackbar/rel-snackbar.ts +6 -0
  17. package/dist/components/rel-stepper/rel-stepper.ts +23 -2
  18. package/dist/components/rel-switch/rel-switch.ts +7 -5
  19. package/dist/components/rel-tab/rel-tab.ts +10 -8
  20. package/dist/components/rel-textfield/rel-textfield.ts +2 -2
  21. package/dist/index.d.mts +11 -7
  22. package/dist/index.d.ts +11 -7
  23. package/dist/index.js +367 -475
  24. package/dist/index.js.map +1 -1
  25. package/dist/index.mjs +383 -489
  26. package/dist/index.mjs.map +1 -1
  27. package/dist/vars-6ZIUPIU4.css +184 -0
  28. package/package.json +2 -2
  29. package/dist/components/rel-accordion/rel-accordion.stories.ts +0 -313
  30. package/dist/components/rel-alert/rel-alert.stories.ts +0 -412
  31. package/dist/components/rel-avatar/rel-avatar.stories.ts +0 -327
  32. package/dist/components/rel-badge/rel-badge.stories.ts +0 -350
  33. package/dist/components/rel-breadcrumb/rel-breadcrumb.stories.ts +0 -306
  34. package/dist/components/rel-button/rel-button.stories.ts +0 -356
  35. package/dist/components/rel-card/rel-card.stories.ts +0 -299
  36. package/dist/components/rel-cardmedia/rel-cardmedia.stories.ts +0 -368
  37. package/dist/components/rel-checkbox/rel-checkbox.stories.ts +0 -414
  38. package/dist/components/rel-chip/rel-chip.stories.ts +0 -552
  39. package/dist/components/rel-container/rel-container.stories.ts +0 -239
  40. package/dist/components/rel-divider/rel-divider.stories.ts +0 -229
  41. package/dist/components/rel-layout/rel-layout.stories.ts +0 -713
  42. package/dist/components/rel-menu/rel-menu.stories.ts +0 -910
  43. package/dist/components/rel-progress/rel-progress.stories.ts +0 -817
  44. package/dist/components/rel-radio/rel-radio.stories.ts +0 -1048
  45. package/dist/components/rel-segmented-button/rel-segmented-button.stories.ts +0 -1079
  46. package/dist/components/rel-select/rel-select.stories.ts +0 -1201
  47. package/dist/components/rel-slider/rel-slider.stories.ts +0 -730
  48. package/dist/components/rel-snackbar/rel-snackbar.stories.ts +0 -808
  49. package/dist/components/rel-stepper/rel-stepper.stories.ts +0 -752
  50. package/dist/components/rel-switch/rel-switch.stories.ts +0 -441
  51. package/dist/components/rel-tab/rel-tab.stories.ts +0 -492
  52. package/dist/components/rel-textfield/rel-textfield.stories.ts +0 -710
  53. package/dist/components/rel-toast/rel-toast.stories.ts +0 -394
  54. package/dist/components/rel-tooltip/rel-tooltip.stories.ts +0 -364
package/dist/index.mjs CHANGED
@@ -9,6 +9,9 @@ var __decorateClass = (decorators, target, key, kind) => {
9
9
  return result;
10
10
  };
11
11
 
12
+ // src/index.ts
13
+ import "./vars-6ZIUPIU4.css";
14
+
12
15
  // src/components/rel-accordion/rel-accordion.ts
13
16
  import { LitElement, html, css } from "lit";
14
17
  import { customElement, property } from "lit/decorators.js";
@@ -20,6 +23,13 @@ var RelAccordion = class extends LitElement {
20
23
  }
21
24
  toggle() {
22
25
  this.open = !this.open;
26
+ this.dispatchEvent(
27
+ new CustomEvent("open-change", {
28
+ detail: this.open,
29
+ bubbles: true,
30
+ composed: true
31
+ })
32
+ );
23
33
  }
24
34
  chevron() {
25
35
  return html`
@@ -39,7 +49,10 @@ var RelAccordion = class extends LitElement {
39
49
  </div>
40
50
  </div>
41
51
 
42
- ${this.open ? html`<div class="body"><slot></slot></div>` : ""}
52
+ <!-- IMPORTANT: slot is ALWAYS rendered -->
53
+ <div class="body ${this.open ? "open" : ""}">
54
+ <slot></slot>
55
+ </div>
43
56
  </div>
44
57
  `;
45
58
  }
@@ -54,9 +67,8 @@ RelAccordion.styles = css`
54
67
  .accordion {
55
68
  background: var(--rel-colors-white);
56
69
  border: 1px solid var(--rel-border-default);
57
- border-radius: var(--rel-borders-radius-border-radius-200); /* 8px */
70
+ border-radius: var(--rel-borders-radius-border-radius-200);
58
71
  box-shadow: var(--rel-shadows-shadow-100);
59
- transition: all 0.2s ease;
60
72
  overflow: hidden;
61
73
  }
62
74
 
@@ -65,13 +77,13 @@ RelAccordion.styles = css`
65
77
  display: flex;
66
78
  justify-content: space-between;
67
79
  align-items: center;
68
- padding: var(--rel-spacing-space-md); /* 16px */
80
+ padding: var(--rel-spacing-space-md);
69
81
  cursor: pointer;
70
82
  user-select: none;
71
83
  }
72
84
 
73
85
  .title {
74
- font-size: var(--rel-fontSizes-lg); /* 20px */
86
+ font-size: var(--rel-fontSizes-lg);
75
87
  font-weight: var(--rel-fontWeights-medium);
76
88
  color: var(--rel-colors-black);
77
89
  }
@@ -96,36 +108,31 @@ RelAccordion.styles = css`
96
108
  stroke-linejoin: round;
97
109
  }
98
110
 
99
- .rotated {
111
+ .icon.rotated {
100
112
  transform: rotate(180deg);
101
113
  }
102
114
 
103
115
  /* BODY ------------------------------------------------------ */
104
116
  .body {
105
- padding: var(--rel-spacing-space-xl) var(--rel-spacing-space-md)
106
- var(--rel-spacing-space-lg);
107
- /* 24px 16px 20px */
108
- font-size: var(--rel-fontSizes-lg); /* 20px */
117
+ overflow: hidden;
118
+ max-height: 0;
119
+ padding: 0 var(--rel-spacing-space-md);
120
+ font-size: var(--rel-fontSizes-lg);
109
121
  color: var(--rel-colors-gray-primary);
110
- animation: fadeIn 0.2s ease;
122
+ transition: max-height 0.25s ease, padding 0.2s ease;
111
123
  }
112
124
 
113
- @keyframes fadeIn {
114
- from {
115
- opacity: 0;
116
- transform: translateY(-4px);
117
- }
118
- to {
119
- opacity: 1;
120
- transform: translateY(0);
121
- }
125
+ .body.open {
126
+ max-height: 1000px; /* sufficiently large */
127
+ padding: var(--rel-spacing-space-xl) var(--rel-spacing-space-md)
128
+ var(--rel-spacing-space-lg);
122
129
  }
123
130
  `;
124
131
  __decorateClass([
125
132
  property({ type: String })
126
133
  ], RelAccordion.prototype, "title", 2);
127
134
  __decorateClass([
128
- property({ type: Boolean })
135
+ property({ type: Boolean, reflect: true })
129
136
  ], RelAccordion.prototype, "open", 2);
130
137
  RelAccordion = __decorateClass([
131
138
  customElement("rel-accordion")
@@ -142,45 +149,95 @@ var RelAlert = class extends LitElement2 {
142
149
  this.dismissible = true;
143
150
  this.dismissed = false;
144
151
  }
152
+ dismissAlert() {
153
+ this.dismissed = true;
154
+ this.dispatchEvent(
155
+ new CustomEvent("dismiss", {
156
+ bubbles: true,
157
+ composed: true
158
+ })
159
+ );
160
+ }
145
161
  get iconSvg() {
146
162
  switch (this.type) {
147
163
  case "info":
148
- return html2`<svg viewBox="0 0 18 18" fill="none">
149
- <path
150
- d="M9 4.75c-.24 0-.44.08-.61.25-.16.16-.24.36-.24.6 0 .24.08.44.24.61.17.17.37.25.61.25.24 0 .44-.08.61-.25.17-.16.24-.36.24-.61 0-.24-.08-.44-.24-.6-.17-.17-.37-.25-.61-.25Zm.85 3.4h-1.7v5.1h1.7V8.15ZM9 .5c1.18 0 2.29.22 3.32.67 1.03.45 1.93 1.05 2.69 1.81.75.76 1.35 1.66 1.8 2.69.46 1.03.68 2.14.68 3.33 0 1.18-.22 2.29-.68 3.32-.45 1.04-1.05 1.93-1.8 2.69-.76.75-1.66 1.35-2.69 1.8-1.04.46-2.15.68-3.32.68-1.18 0-2.29-.22-3.32-.68-1.04-.45-1.93-1.05-2.69-1.8-.75-.76-1.35-1.66-1.8-2.69C1.92 11.28 1.7 10.17 1.7 9c0-1.18.22-2.29.68-3.32.45-1.04 1.05-1.93 1.8-2.69.76-.75 1.66-1.35 2.69-1.8C6.71.73 7.82.5 9 .5Z"
151
- fill="#4A90E2"
152
- />
153
- </svg>`;
164
+ return html2`
165
+ <svg
166
+ xmlns="http://www.w3.org/2000/svg"
167
+ width="18"
168
+ height="18"
169
+ viewBox="0 0 18 18"
170
+ fill="none"
171
+ >
172
+ <path
173
+ d="M9 4.75C8.75917 4.75 8.55715 4.8316 8.39395 4.9948C8.23132 5.15743 8.15 5.35917 8.15 5.6C8.15 5.84083 8.23132 6.04285 8.39395 6.20605C8.55715 6.36868 8.75917 6.45 9 6.45C9.24083 6.45 9.44257 6.36868 9.6052 6.20605C9.7684 6.04285 9.85 5.84083 9.85 5.6C9.85 5.35917 9.7684 5.15743 9.6052 4.9948C9.44257 4.8316 9.24083 4.75 9 4.75ZM9.85 8.15L8.15 8.15L8.15 13.25L9.85 13.25L9.85 8.15ZM9 0.499999C10.1758 0.499999 11.2808 0.723266 12.315 1.1698C13.3492 1.61633 14.2488 2.22182 15.0138 2.98625C15.7788 3.75068 16.3842 4.65027 16.8302 5.685C17.2762 6.71973 17.4994 7.82473 17.5 9C17.5006 10.1753 17.2773 11.2803 16.8302 12.315C16.3842 13.3492 15.7787 14.2487 15.0137 15.0137C14.2487 15.7787 13.3492 16.3845 12.315 16.831C11.2808 17.2776 10.1758 17.5006 9 17.5C7.82417 17.4994 6.71917 17.2764 5.685 16.831C4.65083 16.3845 3.75125 15.7787 2.98625 15.0137C2.22125 14.2487 1.61577 13.3492 1.1698 12.315C0.723834 11.2808 0.500567 10.1758 0.500001 9C0.499434 7.82417 0.722701 6.71917 1.1698 5.685C1.61577 4.65083 2.22125 3.75125 2.98625 2.98625C3.75125 2.22125 4.65084 1.61577 5.685 1.1698C6.71917 0.723832 7.82417 0.500566 9 0.499999ZM9 2.2C7.10167 2.2 5.49375 2.85875 4.17625 4.17625C2.85875 5.49375 2.2 7.10167 2.2 9C2.2 10.8983 2.85875 12.5062 4.17625 13.8237C5.49375 15.1412 7.10167 15.8 9 15.8C10.8983 15.8 12.5062 15.1412 13.8237 13.8237C15.1412 12.5062 15.8 10.8983 15.8 9C15.8 7.10167 15.1413 5.49375 13.8238 4.17625C12.5063 2.85875 10.8983 2.2 9 2.2Z"
174
+ fill="#4A90E2"
175
+ />
176
+ </svg>
177
+ `;
154
178
  case "success":
155
- return html2`<svg viewBox="0 0 18 18" fill="none">
156
- <path
157
- d="M7.81 12.91 13.8 6.92l-1.19-1.19L7.81 10.53 5.39 8.11 4.2 9.3l3.61 3.61ZM9 17.5a8.49 8.49 0 1 1 0-17 8.49 8.49 0 0 1 0 17Z"
158
- fill="#4CAA47"
159
- />
160
- </svg>`;
179
+ return html2`
180
+ <svg
181
+ xmlns="http://www.w3.org/2000/svg"
182
+ width="18"
183
+ height="18"
184
+ viewBox="0 0 18 18"
185
+ fill="none"
186
+ >
187
+ <path
188
+ d="M7.81 12.91L13.8025 6.9175L12.6125 5.7275L7.81 10.53L5.3875 8.1075L4.1975 9.2975L7.81 12.91ZM9 17.5C7.82417 17.5 6.71917 17.2767 5.685 16.8302C4.65083 16.3837 3.75125 15.7782 2.98625 15.0138C2.22125 14.2493 1.61577 13.3497 1.1698 12.315C0.723834 11.2803 0.500568 10.1753 0.500001 9C0.499434 7.82473 0.722701 6.71973 1.1698 5.685C1.61577 4.65083 2.22125 3.75125 2.98625 2.98625C3.75125 2.22125 4.65083 1.61548 5.685 1.16895C6.71917 0.722418 7.82417 0.499434 9 0.500001C10.1758 0.500568 11.2808 0.723551 12.315 1.16895C13.3492 1.61548 14.2488 2.22125 15.0138 2.98625C15.7788 3.75125 16.3842 4.65083 16.8302 5.685C17.2762 6.71917 17.4994 7.82417 17.5 9C17.5006 10.1758 17.2773 11.2808 16.8302 12.315C16.3842 13.3492 15.7788 14.2488 15.0138 15.0138C14.2488 15.7788 13.3492 16.3842 12.315 16.8302C11.2808 17.2762 10.1758 17.4994 9 17.5ZM9 15.8C10.8983 15.8 12.5062 15.1412 13.8237 13.8237C15.1412 12.5062 15.8 10.8983 15.8 9C15.8 7.10167 15.1412 5.49375 13.8237 4.17625C12.5062 2.85875 10.8983 2.2 9 2.2C7.10167 2.2 5.49375 2.85875 4.17625 4.17625C2.85875 5.49375 2.2 7.10167 2.2 9C2.2 10.8983 2.85875 12.5062 4.17625 13.8237C5.49375 15.1412 7.10167 15.8 9 15.8Z"
189
+ fill="#4CAA47"
190
+ />
191
+ </svg>
192
+ `;
161
193
  case "warning":
162
- return html2`<svg viewBox="0 0 16 14" fill="none">
163
- <path
164
- d="M0 14 8 0l8 14H0Zm2.51-1.47h10.98L8 2.95 2.51 12.53ZM8 11.79c.21 0 .38-.07.52-.21.14-.14.21-.31.21-.52 0-.21-.07-.38-.21-.52A.7.7 0 0 0 8 10.32a.7.7 0 0 0-.52.21c-.14.14-.21.31-.21.52 0 .21.07.38.21.52.14.14.31.21.52.21Zm-.73-2.21h1.46V5.89H7.27v3.69Z"
165
- fill="#FF6D00"
166
- />
167
- </svg>`;
194
+ return html2`
195
+ <svg
196
+ xmlns="http://www.w3.org/2000/svg"
197
+ width="16"
198
+ height="14"
199
+ viewBox="0 0 16 14"
200
+ fill="none"
201
+ >
202
+ <path
203
+ d="M0 14L8 0L16 14H0ZM2.50909 12.5263H13.4909L8 2.94737L2.50909 12.5263ZM8 11.7895C8.20606 11.7895 8.37891 11.7187 8.51855 11.5773C8.6577 11.4363 8.72727 11.2614 8.72727 11.0526C8.72727 10.8439 8.6577 10.669 8.51855 10.528C8.37891 10.3865 8.20606 10.3158 8 10.3158C7.79394 10.3158 7.62133 10.3865 7.48218 10.528C7.34255 10.669 7.27273 10.8439 7.27273 11.0526C7.27273 11.2614 7.34255 11.4363 7.48218 11.5773C7.62133 11.7187 7.79394 11.7895 8 11.7895ZM7.27273 9.57895H8.72727V5.89474H7.27273V9.57895Z"
204
+ fill="#FF6D00"
205
+ />
206
+ </svg>
207
+ `;
168
208
  case "error":
169
- return html2`<svg viewBox="0 0 18 18" fill="none">
170
- <path
171
- d="M9 13.25c.24 0 .44-.08.61-.24.17-.17.24-.38.24-.61 0-.24-.08-.44-.24-.61-.17-.16-.37-.24-.61-.24-.24 0-.44.08-.61.24-.17.17-.24.37-.24.61 0 .24.08.44.24.61.17.16.37.24.61.24Zm-.85-3.4h1.7V4.75h-1.7v5.1ZM9 17.5c-1.18 0-2.29-.23-3.32-.68C4.64 16.37 3.74 15.77 2.99 15.02c-.75-.75-1.35-1.65-1.8-2.69C.73 11.29.5 10.18.5 9c0-1.18.23-2.29.68-3.32.45-1.03 1.05-1.93 1.8-2.69C5.03 1.23 5.94.63 6.97.18 8 .72 9.12.5 10.3.5c1.17 0 2.28.23 3.32.68 1.03.45 1.93 1.05 2.68 1.8.75.76 1.35 1.66 1.8 2.69.46 1.03.68 2.14.68 3.33 0 1.18-.22 2.29-.68 3.32-.45 1.04-1.05 1.93-1.8 2.69-.76.75-1.66 1.35-2.69 1.8-1.04.46-2.15.68-3.32.68Z"
172
- fill="#C62828"
173
- />
174
- </svg>`;
209
+ return html2`
210
+ <svg
211
+ xmlns="http://www.w3.org/2000/svg"
212
+ width="18"
213
+ height="18"
214
+ viewBox="0 0 18 18"
215
+ fill="none"
216
+ >
217
+ <path
218
+ d="M9 13.25C9.24083 13.25 9.44285 13.1684 9.60605 13.0052C9.76868 12.8426 9.85 12.6408 9.85 12.4C9.85 12.1592 9.76868 11.9571 9.60605 11.7939C9.44285 11.6313 9.24083 11.55 9 11.55C8.75917 11.55 8.55743 11.6313 8.3948 11.7939C8.2316 11.9571 8.15 12.1592 8.15 12.4C8.15 12.6408 8.2316 12.8426 8.3948 13.0052C8.55743 13.1684 8.75917 13.25 9 13.25ZM8.15 9.85H9.85V4.75H8.15V9.85ZM9 17.5C7.82417 17.5 6.71917 17.2767 5.685 16.8302C4.65083 16.3837 3.75125 15.7782 2.98625 15.0138C2.22125 14.2493 1.61577 13.3497 1.1698 12.315C0.723834 11.2803 0.500568 10.1753 0.500001 9C0.499434 7.82473 0.722701 6.71973 1.1698 5.685C1.61577 4.65083 2.22125 3.75125 2.98625 2.98625C3.75125 2.22125 4.65083 1.61548 5.685 1.16895C6.71917 0.722418 7.82417 0.499434 9 0.500001C10.1758 0.500568 11.2808 0.723551 12.315 1.16895C13.3492 1.61548 14.2488 2.22125 15.0138 2.98625C15.7788 3.75125 16.3842 4.65083 16.8302 5.685C17.2762 6.71917 17.4994 7.82417 17.5 9C17.5006 10.1758 17.2773 11.2808 16.8302 12.315C16.3842 13.3492 15.7788 14.2488 15.0138 15.0138C14.2488 15.7788 13.3492 16.3842 12.315 16.8302C11.2808 17.2762 10.1758 17.4994 9 17.5ZM9 15.8C10.8983 15.8 12.5062 15.1412 13.8237 13.8237C15.1412 12.5062 15.8 10.8983 15.8 9C15.8 7.10167 15.1412 5.49375 13.8237 4.17625C12.5062 2.85875 10.8983 2.2 9 2.2C7.10167 2.2 5.49375 2.85875 4.17625 4.17625C2.85875 5.49375 2.2 7.10167 2.2 9C2.2 10.8983 2.85875 12.5062 4.17625 13.8237C5.49375 15.1412 7.10167 15.8 9 15.8Z"
219
+ fill="#C62828"
220
+ />
221
+ </svg>
222
+ `;
175
223
  default:
176
- return html2``;
224
+ return html2`
225
+ <svg
226
+ xmlns="http://www.w3.org/2000/svg"
227
+ width="18"
228
+ height="18"
229
+ viewBox="0 0 18 18"
230
+ fill="none"
231
+ >
232
+ <path
233
+ d="M9 4.75C8.75917 4.75 8.55715 4.8316 8.39395 4.9948C8.23132 5.15743 8.15 5.35917 8.15 5.6C8.15 5.84083 8.23132 6.04285 8.39395 6.20605C8.55715 6.36868 8.75917 6.45 9 6.45C9.24083 6.45 9.44257 6.36868 9.6052 6.20605C9.7684 6.04285 9.85 5.84083 9.85 5.6C9.85 5.35917 9.7684 5.15743 9.6052 4.9948C9.44257 4.8316 9.24083 4.75 9 4.75ZM9.85 8.15L8.15 8.15L8.15 13.25L9.85 13.25L9.85 8.15ZM9 0.499999C10.1758 0.499999 11.2808 0.723266 12.315 1.1698C13.3492 1.61633 14.2488 2.22182 15.0138 2.98625C15.7788 3.75068 16.3842 4.65027 16.8302 5.685C17.2762 6.71973 17.4994 7.82473 17.5 9C17.5006 10.1753 17.2773 11.2803 16.8302 12.315C16.3842 13.3492 15.7787 14.2487 15.0137 15.0137C14.2487 15.7787 13.3492 16.3845 12.315 16.831C11.2808 17.2776 10.1758 17.5006 9 17.5C7.82417 17.4994 6.71917 17.2764 5.685 16.831C4.65083 16.3845 3.75125 15.7787 2.98625 15.0137C2.22125 14.2487 1.61577 13.3492 1.1698 12.315C0.723834 11.2808 0.500567 10.1758 0.500001 9C0.499434 7.82417 0.722701 6.71917 1.1698 5.685C1.61577 4.65083 2.22125 3.75125 2.98625 2.98625C3.75125 2.22125 4.65084 1.61577 5.685 1.1698C6.71917 0.723832 7.82417 0.500566 9 0.499999ZM9 2.2C7.10167 2.2 5.49375 2.85875 4.17625 4.17625C2.85875 5.49375 2.2 7.10167 2.2 9C2.2 10.8983 2.85875 12.5062 4.17625 13.8237C5.49375 15.1412 7.10167 15.8 9 15.8C10.8983 15.8 12.5062 15.1412 13.8237 13.8237C15.1412 12.5062 15.8 10.8983 15.8 9C15.8 7.10167 15.1413 5.49375 13.8238 4.17625C12.5063 2.85875 10.8983 2.2 9 2.2Z"
234
+ fill="black"
235
+ />
236
+ </svg>
237
+ `;
177
238
  }
178
239
  }
179
- dismissAlert() {
180
- this.dismissed = true;
181
- }
182
240
  render() {
183
- if (this.dismissed) return null;
184
241
  return html2`
185
242
  <div class="rel-alert alert-${this.type}">
186
243
  <div class="rel-icon">${this.iconSvg}</div>
@@ -188,15 +245,15 @@ var RelAlert = class extends LitElement2 {
188
245
  <div class="rel-content">
189
246
  <p class="rel-message1">${this.message1}</p>
190
247
 
191
- ${this.message2 ? html2`<p class="rel-message2">${this.message2}</p>` : ""}
192
- ${this.urlText && this.urlHref ? html2`<a class="rel-link" href="${this.urlHref}"
193
- >${this.urlText}</a
194
- >` : ""}
248
+ ${this.message2 ? html2`<p class="rel-message2">${this.message2}</p>` : null}
249
+ ${this.urlText && this.urlHref ? html2`<a class="rel-link" href=${this.urlHref}>
250
+ ${this.urlText}
251
+ </a>` : null}
195
252
  </div>
196
253
 
197
254
  ${this.dismissible ? html2`<button class="rel-close" @click=${this.dismissAlert}>
198
255
  ✕
199
- </button>` : ""}
256
+ </button>` : null}
200
257
  </div>
201
258
  `;
202
259
  }
@@ -207,14 +264,16 @@ RelAlert.styles = css2`
207
264
  font-family: var(--rel-fontFamilies-primary);
208
265
  }
209
266
 
267
+ :host([dismissed]) {
268
+ display: none;
269
+ }
270
+
210
271
  .rel-alert {
211
272
  display: flex;
212
273
  align-items: center;
213
- gap: var(--rel-spacing-space-xs); /* 8px */
274
+ gap: var(--rel-spacing-space-xs);
214
275
  padding: var(--rel-spacing-space-sm) var(--rel-spacing-space-md);
215
- /* 12px vertical, 16px horizontal */
216
- border-radius: var(--rel-borders-radius-border-radius-200); /* 8px */
217
- width: fit-content;
276
+ border-radius: var(--rel-borders-radius-border-radius-200);
218
277
  min-width: 360px;
219
278
  box-sizing: border-box;
220
279
  }
@@ -226,8 +285,6 @@ RelAlert.styles = css2`
226
285
  }
227
286
 
228
287
  .rel-message1 {
229
- display: flex;
230
- align-items: center;
231
288
  margin: 0;
232
289
  font-size: var(--rel-fontSizes-md);
233
290
  font-weight: var(--rel-fontWeights-medium);
@@ -236,16 +293,9 @@ RelAlert.styles = css2`
236
293
  .rel-message2 {
237
294
  margin: 0;
238
295
  font-size: var(--rel-fontSizes-sm);
239
- font-weight: var(--rel-fontWeights-regular);
240
296
  opacity: 0.9;
241
297
  }
242
298
 
243
- .rel-icon {
244
- display: flex;
245
- align-items: center;
246
- justify-content: center;
247
- }
248
-
249
299
  .rel-icon svg {
250
300
  width: 16px;
251
301
  height: 16px;
@@ -255,8 +305,8 @@ RelAlert.styles = css2`
255
305
  font-size: var(--rel-fontSizes-sm);
256
306
  font-weight: var(--rel-fontWeights-medium);
257
307
  text-decoration: underline;
258
- margin-top: 2px;
259
308
  color: inherit;
309
+ margin-top: 2px;
260
310
  }
261
311
 
262
312
  .rel-close {
@@ -264,21 +314,14 @@ RelAlert.styles = css2`
264
314
  background: none;
265
315
  border: none;
266
316
  cursor: pointer;
267
- width: 16px;
268
- height: 16px;
269
317
  opacity: 0.6;
270
- padding: 0;
271
- display: flex;
272
- align-items: center;
273
- justify-content: center;
274
318
  }
275
319
 
276
320
  .rel-close:hover {
277
321
  opacity: 1;
278
322
  }
279
323
 
280
- /* COLORS — using token system */
281
-
324
+ /* COLORS */
282
325
  .alert-info {
283
326
  background: var(--rel-background-info);
284
327
  color: var(--rel-text-info);
@@ -324,7 +367,7 @@ __decorateClass([
324
367
  property2({ type: Boolean })
325
368
  ], RelAlert.prototype, "dismissible", 2);
326
369
  __decorateClass([
327
- property2({ type: Boolean })
370
+ property2({ type: Boolean, reflect: true })
328
371
  ], RelAlert.prototype, "dismissed", 2);
329
372
  RelAlert = __decorateClass([
330
373
  customElement2("rel-alert")
@@ -345,7 +388,7 @@ var RelAvatar = class extends LitElement3 {
345
388
  render() {
346
389
  return html3`
347
390
  <div class="avatar avatar-${this.size}">
348
- ${this.type === "image" ? html3`<img src=${this.src} alt=${this.alt} />` : this.type === "text" ? html3`<span>${this.text}</span>` : html3`<span class="icon-slot"><slot></slot></span>`}
391
+ ${this.type === "image" && this.src ? html3`<img src=${this.src} alt=${this.alt} />` : this.type === "text" ? html3`<span>${this.text}</span>` : html3`<span class="icon-slot"><slot></slot></span>`}
349
392
  </div>
350
393
  `;
351
394
  }
@@ -371,35 +414,29 @@ RelAvatar.styles = css3`
371
414
  text-transform: uppercase;
372
415
  }
373
416
 
374
- /* -------------------------
375
- CORRECTED SIZE CLASSES
376
- ------------------------- */
417
+ /* Sizes */
377
418
  .avatar-lg {
378
419
  width: 40px;
379
420
  height: 40px;
380
421
  font-size: var(--rel-fontSizes-xl);
381
- line-height: 38px;
382
422
  }
383
423
 
384
424
  .avatar-md {
385
425
  width: 32px;
386
426
  height: 32px;
387
427
  font-size: var(--rel-fontSizes-lg);
388
- line-height: 32px;
389
428
  }
390
429
 
391
430
  .avatar-sm {
392
431
  width: 24px;
393
432
  height: 24px;
394
433
  font-size: var(--rel-fontSizes-md);
395
- line-height: 24px;
396
434
  }
397
435
 
398
436
  .avatar-xs {
399
437
  width: 18px;
400
438
  height: 18px;
401
439
  font-size: var(--rel-fontSizes-xs);
402
- line-height: 18px;
403
440
  }
404
441
 
405
442
  img {
@@ -416,20 +453,16 @@ RelAvatar.styles = css3`
416
453
  justify-content: center;
417
454
  }
418
455
 
419
- .icon-slot ::slotted(*) {
420
- font-size: var(--rel-fontSizes-md);
421
- }
422
-
423
456
  .icon-slot ::slotted(svg) {
424
457
  width: 50%;
425
458
  height: 50%;
426
459
  }
427
460
  `;
428
461
  __decorateClass([
429
- property3({ type: String })
462
+ property3({ type: String, reflect: true })
430
463
  ], RelAvatar.prototype, "size", 2);
431
464
  __decorateClass([
432
- property3({ type: String })
465
+ property3({ type: String, reflect: true })
433
466
  ], RelAvatar.prototype, "type", 2);
434
467
  __decorateClass([
435
468
  property3({ type: String })
@@ -458,9 +491,10 @@ var RelBadge = class extends LitElement4 {
458
491
  return ["badge", `badge-${this.size}`, `badge-${this.variant}`].join(" ");
459
492
  }
460
493
  render() {
461
- const isDot = this.variant === "dot";
462
494
  return html4`
463
- <span class="${this.classes}">${isDot ? "" : this.number}</span>
495
+ <span class="${this.classes}">
496
+ ${this.variant === "number" ? this.number : null}
497
+ </span>
464
498
  `;
465
499
  }
466
500
  };
@@ -473,14 +507,14 @@ RelBadge.styles = css4`
473
507
  display: inline-flex;
474
508
  align-items: center;
475
509
  justify-content: center;
476
- font-family: "Poppins", sans-serif;
510
+ font-family: var(--rel-fontFamilies-primary);
477
511
  font-weight: 600;
478
512
  background-color: var(--rel-colors-red-primary);
479
513
  color: var(--rel-colors-white);
480
514
  border-radius: 50%;
481
515
  }
482
516
 
483
- /* PERFECT CIRCLES — FIXED SIZES */
517
+ /* NUMBER BADGES */
484
518
  .badge-sm {
485
519
  width: 20px;
486
520
  height: 20px;
@@ -499,27 +533,30 @@ RelBadge.styles = css4`
499
533
  font-size: 20px;
500
534
  }
501
535
 
502
- /* DOT — smaller circle */
503
- .badge-dot {
504
- width: 10px !important;
505
- height: 10px !important;
506
- padding: 0 !important;
536
+ /* DOT BADGES */
537
+ .badge-dot.badge-sm {
538
+ width: 8px;
539
+ height: 8px;
507
540
  }
508
541
 
509
- .badge-number {
510
- display: flex;
511
- align-items: center;
512
- justify-content: center;
542
+ .badge-dot.badge-md {
543
+ width: 10px;
544
+ height: 10px;
545
+ }
546
+
547
+ .badge-dot.badge-lg {
548
+ width: 12px;
549
+ height: 12px;
513
550
  }
514
551
  `;
515
552
  __decorateClass([
516
553
  property4({ type: String })
517
554
  ], RelBadge.prototype, "number", 2);
518
555
  __decorateClass([
519
- property4({ type: String })
556
+ property4({ type: String, reflect: true })
520
557
  ], RelBadge.prototype, "size", 2);
521
558
  __decorateClass([
522
- property4({ type: String })
559
+ property4({ type: String, reflect: true })
523
560
  ], RelBadge.prototype, "variant", 2);
524
561
  RelBadge = __decorateClass([
525
562
  customElement4("rel-badge")
@@ -538,22 +575,21 @@ var RelBreadcrumbs = class extends LitElement5 {
538
575
  <nav aria-label="Breadcrumb">
539
576
  <ol>
540
577
  ${this.items.map((item, index) => {
541
- const last = index === this.items.length - 1;
578
+ const isLast = index === this.items.length - 1;
542
579
  return html5`
543
580
  <li>
544
- ${item.url && !last ? html5`<a href="${item.url}">${item.label}</a>` : html5`<span class="current">${item.label}</span>`}
545
- ${!last ? html5`
546
- <svg viewBox="0 0 24 24">
581
+ ${item.url && !isLast ? html5`<a href=${item.url}>${item.label}</a>` : html5`<span class="current">${item.label}</span>`}
582
+ ${!isLast ? html5`
583
+ <svg viewBox="0 0 24 24" aria-hidden="true">
547
584
  <polyline
548
585
  points="9 18 15 12 9 6"
549
586
  fill="none"
550
- stroke="currentColor"
551
587
  stroke-width="2"
552
588
  stroke-linecap="round"
553
589
  stroke-linejoin="round"
554
- ></polyline>
590
+ />
555
591
  </svg>
556
- ` : ""}
592
+ ` : null}
557
593
  </li>
558
594
  `;
559
595
  })}
@@ -571,7 +607,6 @@ RelBreadcrumbs.styles = css5`
571
607
  }
572
608
 
573
609
  nav {
574
- display: block;
575
610
  width: 100%;
576
611
  }
577
612
 
@@ -607,7 +642,7 @@ RelBreadcrumbs.styles = css5`
607
642
  }
608
643
 
609
644
  svg {
610
- stroke: var(--rel-colors-gray-text);
645
+ stroke: currentColor;
611
646
  width: 16px;
612
647
  height: 16px;
613
648
  margin: 0 10px;
@@ -637,13 +672,30 @@ var RelButton = class extends LitElement6 {
637
672
  `btn-${this.variant}`,
638
673
  `tone-${this.tone}`,
639
674
  `size-${this.size}`,
640
- `border-${this.border}`,
641
- this.disabled ? "btn-disabled" : ""
675
+ `border-${this.border}`
642
676
  ].join(" ");
643
677
  }
678
+ handleClick(e) {
679
+ if (this.disabled) {
680
+ e.preventDefault();
681
+ e.stopImmediatePropagation();
682
+ return;
683
+ }
684
+ this.dispatchEvent(
685
+ new MouseEvent("click", {
686
+ bubbles: true,
687
+ composed: true
688
+ })
689
+ );
690
+ }
644
691
  render() {
645
692
  return html6`
646
- <button class="${this.classes}" ?disabled=${this.disabled}>
693
+ <button
694
+ class="${this.classes}"
695
+ ?disabled=${this.disabled}
696
+ @click=${this.handleClick}
697
+ aria-disabled=${this.disabled}
698
+ >
647
699
  <slot></slot>
648
700
  </button>
649
701
  `;
@@ -667,9 +719,7 @@ RelButton.styles = css6`
667
719
  outline: none;
668
720
  }
669
721
 
670
- /* -------------------------
671
- SIZES (Figma)
672
- -------------------------- */
722
+ /* Sizes */
673
723
  .size-small {
674
724
  height: 32px;
675
725
  padding: 0 var(--rel-spacing-space-md);
@@ -688,9 +738,7 @@ RelButton.styles = css6`
688
738
  font-size: var(--rel-fontSizes-lg);
689
739
  }
690
740
 
691
- /* -------------------------
692
- BORDER RADII (Tokens)
693
- -------------------------- */
741
+ /* Borders */
694
742
  .border-corner-radius {
695
743
  border-radius: var(--rel-borders-radius-border-radius-500);
696
744
  }
@@ -703,24 +751,15 @@ RelButton.styles = css6`
703
751
  border-radius: var(--rel-borders-radius-border-radius-0);
704
752
  }
705
753
 
706
- /* -------------------------
707
- DISABLED STATE
708
- -------------------------- */
709
- :host([disabled]) button,
710
- button:disabled {
754
+ /* Disabled */
755
+ :host([disabled]) button {
711
756
  cursor: not-allowed;
712
757
  background-color: var(--rel-colors-gray-border) !important;
713
758
  color: var(--rel-colors-gray-disabled-text) !important;
714
- border-color: var(--rel-colors-gray-border) !important;
715
- opacity: 1;
716
759
  pointer-events: none;
717
760
  }
718
761
 
719
- /* -------------------------
720
- VARIANTS & TONES
721
- -------------------------- */
722
-
723
- /* DEFAULT */
762
+ /* Variants & tones (unchanged) */
724
763
  .btn-default.tone-default {
725
764
  background: var(--rel-colors-gray-primary);
726
765
  color: var(--rel-colors-white);
@@ -734,7 +773,6 @@ RelButton.styles = css6`
734
773
  color: var(--rel-colors-white);
735
774
  }
736
775
 
737
- /* PRIMARY */
738
776
  .btn-primary.tone-default {
739
777
  background: var(--rel-colors-green-primary);
740
778
  color: var(--rel-colors-black);
@@ -748,27 +786,23 @@ RelButton.styles = css6`
748
786
  color: var(--rel-colors-white);
749
787
  }
750
788
 
751
- /* SECONDARY */
752
789
  .btn-secondary {
753
790
  background: var(--rel-colors-white);
754
791
  border: 1px solid var(--rel-colors-black);
755
792
  color: var(--rel-colors-black);
756
793
  }
757
794
 
758
- /* TEXT */
759
795
  .btn-text {
760
796
  background: transparent;
761
797
  color: var(--rel-colors-black);
762
798
  }
763
799
 
764
- /* LINK */
765
800
  .btn-link {
766
801
  background: transparent;
767
802
  color: var(--rel-colors-blue-primary);
768
803
  text-decoration: underline;
769
804
  }
770
805
 
771
- /* ICON */
772
806
  .btn-icon {
773
807
  width: 40px;
774
808
  height: 40px;
@@ -778,32 +812,14 @@ RelButton.styles = css6`
778
812
  color: var(--rel-colors-black);
779
813
  }
780
814
 
781
- /* -------------------------
782
- STATES: Hover / Active
783
- -------------------------- */
784
- button:hover:not(.btn-disabled) {
815
+ button:hover:not(:disabled) {
785
816
  filter: brightness(0.92);
786
817
  }
787
818
 
788
- button:active:not(.btn-disabled) {
819
+ button:active:not(:disabled) {
789
820
  transform: scale(0.97);
790
821
  }
791
822
 
792
- /* TEXT BUTTON — hover border */
793
- .btn-text:not(.btn-disabled):hover {
794
- border: 1px solid var(--rel-colors-black);
795
- text-decoration: none;
796
- }
797
-
798
- /* LINK BUTTON — hover border */
799
- .btn-link:not(.btn-disabled):hover {
800
- border: 1px solid var(--rel-colors-blue-primary);
801
- text-decoration: underline;
802
- }
803
-
804
- /* -------------------------
805
- FOCUS RING
806
- -------------------------- */
807
823
  button:focus-visible {
808
824
  outline: 2px solid var(--rel-colors-blue-primary);
809
825
  outline-offset: 2px;
@@ -833,30 +849,31 @@ import { LitElement as LitElement7, html as html7, css as css7 } from "lit";
833
849
  import { customElement as customElement7 } from "lit/decorators.js";
834
850
  var RelCard = class extends LitElement7 {
835
851
  render() {
836
- return html7` <div class="card"><slot></slot></div> `;
852
+ return html7`
853
+ <div class="card">
854
+ <slot></slot>
855
+ </div>
856
+ `;
837
857
  }
838
858
  };
839
859
  RelCard.styles = css7`
840
860
  :host {
841
861
  display: block;
862
+ font-family: var(--rel-fontFamilies-primary);
842
863
  }
843
864
 
844
865
  .card {
845
- background-color: var(--rel-colors-white, #ffffff);
846
- border-radius: var(--rel-borderRadius-lg, 12px);
847
- padding: var(--rel-spacing-space-md, 16px);
848
-
849
- box-shadow: 0px 3px 3px rgba(0, 0, 0, 0.3),
850
- 0px 6px 10px 4px rgba(0, 0, 0, 0.15);
866
+ background-color: var(--rel-colors-white);
867
+ border-radius: var(--rel-borders-radius-border-radius-300);
868
+ padding: var(--rel-spacing-space-md);
851
869
 
852
- font-family: var(--rel-fontFamilies-primary);
870
+ box-shadow: var(--rel-shadows-shadow-200);
853
871
  transition: transform 0.2s ease, box-shadow 0.2s ease;
854
872
  }
855
873
 
856
874
  .card:hover {
857
875
  transform: translateY(-3px);
858
- box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.35),
859
- 0px 8px 14px 4px rgba(0, 0, 0, 0.2);
876
+ box-shadow: var(--rel-shadows-shadow-300);
860
877
  }
861
878
  `;
862
879
  RelCard = __decorateClass([
@@ -879,15 +896,13 @@ var RelCardMedia = class extends LitElement8 {
879
896
  <div class="card-media">
880
897
  ${this.imageSrc ? html8`
881
898
  <div class="card-image">
882
- <img src="${this.imageSrc}" alt="${this.imageAlt}" />
899
+ <img src=${this.imageSrc} alt=${this.imageAlt} />
883
900
  </div>
884
901
  ` : null}
885
902
 
886
903
  <div class="card-content">
887
904
  ${this.title ? html8`<h3>${this.title}</h3>` : null}
888
905
  ${this.subtitle ? html8`<p>${this.subtitle}</p>` : null}
889
-
890
- <!-- Slot for extra content such as buttons, descriptions, etc -->
891
906
  <slot></slot>
892
907
  </div>
893
908
  </div>
@@ -901,20 +916,16 @@ RelCardMedia.styles = css8`
901
916
  }
902
917
 
903
918
  .card-media {
904
- background-color: var(--rel-colors-white, #ffffff);
905
- border-radius: var(--rel-borderRadius-lg, 12px);
919
+ background-color: var(--rel-colors-white);
920
+ border-radius: var(--rel-borders-radius-border-radius-300);
906
921
  overflow: hidden;
907
-
908
- box-shadow: 0px 4px 4px rgba(0, 0, 0, 0.3),
909
- 0px 8px 12px 6px rgba(0, 0, 0, 0.15);
910
-
922
+ box-shadow: var(--rel-shadows-shadow-200);
911
923
  transition: transform 0.2s ease, box-shadow 0.2s ease;
912
924
  }
913
925
 
914
926
  .card-media:hover {
915
927
  transform: translateY(-4px);
916
- box-shadow: 0px 6px 10px rgba(0, 0, 0, 0.35),
917
- 0px 10px 16px 6px rgba(0, 0, 0, 0.2);
928
+ box-shadow: var(--rel-shadows-shadow-300);
918
929
  }
919
930
 
920
931
  .card-image img {
@@ -925,20 +936,20 @@ RelCardMedia.styles = css8`
925
936
  }
926
937
 
927
938
  .card-content {
928
- padding: var(--rel-spacing-space-md, 16px);
939
+ padding: var(--rel-spacing-space-md);
929
940
  }
930
941
 
931
942
  .card-content h3 {
932
943
  margin: 0 0 4px 0;
933
- font-size: var(--rel-fontSizes-md, 16px);
934
- font-weight: var(--rel-fontWeights-semibold, 600);
935
- color: var(--rel-colors-gray-heading, #2b2b2b);
944
+ font-size: var(--rel-fontSizes-md);
945
+ font-weight: var(--rel-fontWeights-semibold);
946
+ color: var(--rel-colors-gray-heading);
936
947
  }
937
948
 
938
949
  .card-content p {
939
950
  margin: 0 0 8px 0;
940
- font-size: var(--rel-fontSizes-sm, 14px);
941
- color: var(--rel-colors-gray-text, #555);
951
+ font-size: var(--rel-fontSizes-sm);
952
+ color: var(--rel-colors-gray-text);
942
953
  }
943
954
  `;
944
955
  __decorateClass([
@@ -973,32 +984,34 @@ var RelCheckbox = class extends LitElement9 {
973
984
  if (this.status === "unchecked") this.status = "checked";
974
985
  else if (this.status === "checked") this.status = "indeterminate";
975
986
  else this.status = "unchecked";
976
- this.dispatchEvent(new CustomEvent("changed", { detail: this.status }));
987
+ this.dispatchEvent(
988
+ new CustomEvent("change", {
989
+ detail: {
990
+ checked: this.status === "checked",
991
+ indeterminate: this.status === "indeterminate"
992
+ },
993
+ bubbles: true,
994
+ composed: true
995
+ })
996
+ );
977
997
  }
978
998
  render() {
979
- const className = `
980
- wrapper
981
- ${this.state}
982
- ${this.status}
983
- `;
984
999
  return html9`
985
- <div class="${className}">
1000
+ <div class="wrapper ${this.state} ${this.status}">
986
1001
  <label class="row">
987
1002
  <input
988
1003
  type="checkbox"
989
- @change=${this.toggle}
1004
+ @click=${this.toggle}
990
1005
  ?disabled=${this.state === "disabled"}
991
1006
  />
992
1007
 
993
1008
  <span class="box">
994
- <!-- CHECK ICON -->
995
1009
  <svg class="check-icon" viewBox="0 0 18 14" fill="white">
996
1010
  <path
997
- d="M6.44479 14L0.5 7.36383L1.9862 5.70478L6.44479 10.6819L16.0138 0L17.5 1.65904L6.44479 14Z"
1011
+ d="M6.44 14L0.5 7.36l1.49-1.66L6.44 10.68 16.01 0 17.5 1.66z"
998
1012
  />
999
1013
  </svg>
1000
1014
 
1001
- <!-- INDETERMINATE ICON -->
1002
1015
  <svg class="indeterminate-icon" viewBox="0 0 16 2" fill="white">
1003
1016
  <rect width="16" height="2" />
1004
1017
  </svg>
@@ -1049,55 +1062,43 @@ RelCheckbox.styles = css9`
1049
1062
  transition: all 0.2s;
1050
1063
  }
1051
1064
 
1052
- /* ICONS FIXED SIZE */
1053
1065
  svg {
1054
1066
  width: 12px;
1055
1067
  height: 12px;
1056
1068
  display: none;
1057
- pointer-events: none;
1058
1069
  }
1059
1070
 
1060
- /* CHECKED */
1061
- .checked .box {
1071
+ .checked .box,
1072
+ .indeterminate .box {
1062
1073
  background: var(--rel-colors-gray-heading);
1063
1074
  border-color: var(--rel-colors-gray-heading);
1064
1075
  }
1076
+
1065
1077
  .checked .check-icon {
1066
1078
  display: block;
1067
1079
  }
1068
1080
 
1069
- /* INDETERMINATE */
1070
- .indeterminate .box {
1071
- background: var(--rel-colors-gray-heading);
1072
- border-color: var(--rel-colors-gray-heading);
1073
- }
1074
1081
  .indeterminate .indeterminate-icon {
1075
1082
  display: block;
1076
1083
  }
1077
1084
 
1078
- /* ERROR */
1079
1085
  .error .box {
1080
1086
  border-color: var(--rel-colors-red-primary);
1081
1087
  }
1088
+
1082
1089
  .error.checked .box,
1083
1090
  .error.indeterminate .box {
1084
1091
  background: var(--rel-colors-red-primary);
1085
1092
  border-color: var(--rel-colors-red-primary);
1086
1093
  }
1087
- .error .label,
1088
- .error .text {
1089
- color: var(--rel-colors-red-primary);
1090
- }
1091
1094
 
1092
- /* DISABLED */
1093
1095
  .disabled {
1094
1096
  opacity: 0.55;
1095
- cursor: not-allowed !important;
1097
+ cursor: not-allowed;
1096
1098
  }
1097
1099
 
1098
1100
  .label {
1099
1101
  font-size: var(--rel-fontSizes-md);
1100
- color: var(--rel-colors-gray-heading);
1101
1102
  font-weight: var(--rel-fontWeights-medium);
1102
1103
  }
1103
1104
 
@@ -1105,12 +1106,6 @@ RelCheckbox.styles = css9`
1105
1106
  font-size: var(--rel-fontSizes-sm);
1106
1107
  color: var(--rel-colors-gray-text);
1107
1108
  }
1108
-
1109
- /* Focus ring */
1110
- input:focus-visible + .box {
1111
- outline: 2px solid var(--rel-colors-blue-primary);
1112
- outline-offset: 2px;
1113
- }
1114
1109
  `;
1115
1110
  __decorateClass([
1116
1111
  property8({ type: String })
@@ -1130,7 +1125,7 @@ RelCheckbox = __decorateClass([
1130
1125
 
1131
1126
  // src/components/rel-chip/rel-chip.ts
1132
1127
  import { LitElement as LitElement10, html as html10, css as css10 } from "lit";
1133
- import { customElement as customElement10, property as property9, state as state2 } from "lit/decorators.js";
1128
+ import { customElement as customElement10, property as property9 } from "lit/decorators.js";
1134
1129
  var RelChip = class extends LitElement10 {
1135
1130
  constructor() {
1136
1131
  super(...arguments);
@@ -1157,49 +1152,39 @@ var RelChip = class extends LitElement10 {
1157
1152
  })
1158
1153
  );
1159
1154
  }
1160
- handleKeyDown(event) {
1161
- if (!this.removable) return;
1162
- if (event.key === "Backspace" || event.key === "Delete") {
1163
- event.preventDefault();
1164
- this.handleRemove(event);
1165
- }
1166
- }
1167
1155
  render() {
1168
- if (this.removed) {
1169
- return null;
1170
- }
1171
1156
  return html10`
1172
- <button
1157
+ <span
1173
1158
  class="${this.classes}"
1174
- type="button"
1175
1159
  role="button"
1176
- aria-label="${this.label}"
1177
- @keydown=${this.handleKeyDown}
1178
1160
  tabindex="0"
1161
+ aria-label="${this.label}"
1179
1162
  >
1180
- ${this.avatar ? html10`<img src="${this.avatar}" alt="avatar" class="chip-avatar" />` : ""}
1181
- ${this.leadingIcon ? html10`<span class="chip-icon leading">
1182
- <slot name="leading-icon">${this.renderIcon(this.leadingIcon)}</slot>
1183
- </span>` : ""}
1163
+ ${this.avatar ? html10`<img src=${this.avatar} alt="" class="chip-avatar" />` : null}
1164
+ ${this.leadingIcon ? html10`<span class="chip-icon">
1165
+ ${this.renderIcon(this.leadingIcon)}
1166
+ </span>` : null}
1167
+
1184
1168
  <span class="chip-label">${this.label}</span>
1185
- ${this.trailingIcon ? html10`<span class="chip-icon trailing">
1186
- <slot name="trailing-icon">${this.renderIcon(this.trailingIcon)}</slot>
1187
- </span>` : ""}
1188
- ${this.removable ? html10`<button
1189
- type="button"
1169
+
1170
+ ${this.trailingIcon ? html10`<span class="chip-icon">
1171
+ ${this.renderIcon(this.trailingIcon)}
1172
+ </span>` : null}
1173
+ ${this.removable ? html10`<span
1190
1174
  class="chip-remove"
1191
- @click=${this.handleRemove}
1175
+ role="button"
1192
1176
  aria-label="Remove chip"
1177
+ @click=${this.handleRemove}
1193
1178
  >
1194
- 
1195
- </button>` : ""}
1196
- </button>
1179
+ ✕
1180
+ </span>` : null}
1181
+ </span>
1197
1182
  `;
1198
1183
  }
1199
1184
  renderIcon(iconString) {
1200
1185
  const template = document.createElement("template");
1201
1186
  template.innerHTML = iconString.trim();
1202
- return html10`${template.content.cloneNode(true)}`;
1187
+ return template.content.cloneNode(true);
1203
1188
  }
1204
1189
  };
1205
1190
  RelChip.styles = css10`
@@ -1221,123 +1206,55 @@ RelChip.styles = css10`
1221
1206
  padding: var(--rel-spacing-space-2xs) var(--rel-spacing-space-sm);
1222
1207
  gap: var(--rel-spacing-space-2xs);
1223
1208
  cursor: pointer;
1224
- transition: all 0.2s ease-in-out;
1225
1209
  border: var(--rel-borders-width-stroke-100) solid transparent;
1226
1210
  user-select: none;
1227
1211
  white-space: nowrap;
1212
+ background: transparent;
1228
1213
  }
1229
1214
 
1230
1215
  .chip:hover {
1231
1216
  filter: brightness(0.92);
1232
- transform: translateY(-1px);
1233
1217
  box-shadow: var(--rel-shadows-shadow-100);
1234
1218
  }
1235
1219
 
1236
- .chip:focus:not(:focus-visible) {
1237
- outline: none;
1238
- }
1239
-
1240
- .chip:active {
1241
- transform: scale(0.97) translateY(0);
1242
- box-shadow: none;
1243
- filter: brightness(0.88);
1244
- }
1245
-
1246
- /* Tone Variants - Filled */
1220
+ /* TONES */
1247
1221
  .chip-default {
1248
1222
  background: var(--rel-colors-gray-border);
1249
1223
  color: var(--rel-colors-black);
1250
1224
  }
1251
1225
 
1252
- .chip-default:focus {
1253
- outline: var(--rel-borders-width-stroke-200) solid var(--rel-colors-gray-primary);
1254
- outline-offset: var(--rel-spacing-space-3xs);
1255
- }
1256
-
1257
1226
  .chip-blue {
1258
1227
  background: var(--rel-colors-blue-tertiary);
1259
1228
  color: var(--rel-colors-white);
1260
1229
  }
1261
1230
 
1262
- .chip-blue:focus {
1263
- outline: var(--rel-borders-width-stroke-200) solid var(--rel-colors-blue-tertiary);
1264
- outline-offset: var(--rel-spacing-space-3xs);
1265
- }
1266
-
1267
1231
  .chip-yellow {
1268
1232
  background: var(--rel-colors-yellow-pending);
1269
1233
  color: var(--rel-colors-black);
1270
1234
  }
1271
1235
 
1272
- .chip-yellow:focus {
1273
- outline: var(--rel-borders-width-stroke-200) solid var(--rel-colors-yellow-pending);
1274
- outline-offset: var(--rel-spacing-space-3xs);
1275
- }
1276
-
1277
1236
  .chip-red {
1278
1237
  background: var(--rel-colors-red-secondary);
1279
1238
  color: var(--rel-colors-white);
1280
1239
  }
1281
1240
 
1282
- .chip-red:focus {
1283
- outline: var(--rel-borders-width-stroke-200) solid var(--rel-colors-red-secondary);
1284
- outline-offset: var(--rel-spacing-space-3xs);
1285
- }
1286
-
1287
1241
  .chip-green {
1288
1242
  background: var(--rel-colors-green-success);
1289
1243
  color: var(--rel-colors-white);
1290
1244
  }
1291
1245
 
1292
- .chip-green:focus {
1293
- outline: var(--rel-borders-width-stroke-200) solid var(--rel-colors-green-success);
1294
- outline-offset: var(--rel-spacing-space-3xs);
1295
- }
1296
-
1297
- /* Outline Variants */
1298
- .chip-outline.chip-default {
1299
- background: transparent;
1300
- border-color: var(--rel-colors-gray-border);
1301
- color: var(--rel-colors-black);
1302
- }
1303
-
1304
- .chip-outline.chip-blue {
1305
- background: transparent;
1306
- border-color: var(--rel-colors-blue-tertiary);
1307
- color: var(--rel-colors-blue-tertiary);
1308
- }
1309
-
1310
- .chip-outline.chip-yellow {
1246
+ /* OUTLINE */
1247
+ .chip-outline {
1311
1248
  background: transparent;
1312
- border-color: var(--rel-colors-yellow-pending);
1313
- color: var(--rel-colors-yellow-pending);
1314
- }
1315
-
1316
- .chip-outline.chip-red {
1317
- background: transparent;
1318
- border-color: var(--rel-colors-red-secondary);
1319
- color: var(--rel-colors-red-secondary);
1320
- }
1321
-
1322
- .chip-outline.chip-green {
1323
- background: transparent;
1324
- border-color: var(--rel-colors-green-success);
1325
- color: var(--rel-colors-green-success);
1326
1249
  }
1327
1250
 
1328
1251
  .chip-avatar {
1329
1252
  width: 20px;
1330
1253
  height: 20px;
1331
- border-radius: var(--rel-borders-radius-border-radius-500);
1254
+ border-radius: 50%;
1332
1255
  object-fit: cover;
1333
1256
  }
1334
1257
 
1335
- .chip-icon {
1336
- display: flex;
1337
- align-items: center;
1338
- line-height: 0;
1339
- }
1340
-
1341
1258
  .chip-icon ::slotted(svg),
1342
1259
  .chip-icon svg {
1343
1260
  width: 16px;
@@ -1345,24 +1262,14 @@ RelChip.styles = css10`
1345
1262
  fill: currentColor;
1346
1263
  }
1347
1264
 
1348
- .chip-label {
1349
- line-height: var(--rel-lineHeights-md);
1350
- }
1351
-
1352
1265
  .chip-remove {
1353
- background: transparent;
1354
- border: none;
1355
- color: inherit;
1356
- font-size: var(--rel-fontSizes-md);
1357
- cursor: pointer;
1358
- display: flex;
1359
- align-items: center;
1360
- padding: 0;
1361
1266
  margin-left: var(--rel-spacing-space-3xs);
1267
+ cursor: pointer;
1268
+ opacity: 0.7;
1362
1269
  }
1363
1270
 
1364
1271
  .chip-remove:hover {
1365
- opacity: 0.6;
1272
+ opacity: 1;
1366
1273
  }
1367
1274
  `;
1368
1275
  __decorateClass([
@@ -1387,7 +1294,7 @@ __decorateClass([
1387
1294
  property9({ type: Boolean })
1388
1295
  ], RelChip.prototype, "outline", 2);
1389
1296
  __decorateClass([
1390
- state2()
1297
+ property9({ type: Boolean, reflect: true })
1391
1298
  ], RelChip.prototype, "removed", 2);
1392
1299
  RelChip = __decorateClass([
1393
1300
  customElement10("rel-chip")
@@ -1433,7 +1340,6 @@ RelContainer.styles = css11`
1433
1340
  box-sizing: border-box;
1434
1341
  }
1435
1342
 
1436
- /* Background Variants */
1437
1343
  .bg-white {
1438
1344
  background-color: var(--rel-colors-white);
1439
1345
  }
@@ -1446,7 +1352,6 @@ RelContainer.styles = css11`
1446
1352
  background: transparent;
1447
1353
  }
1448
1354
 
1449
- /* Padding Variants */
1450
1355
  .padding-sm {
1451
1356
  padding: var(--rel-spacing-space-xs);
1452
1357
  }
@@ -1459,7 +1364,6 @@ RelContainer.styles = css11`
1459
1364
  padding: var(--rel-spacing-space-2xl);
1460
1365
  }
1461
1366
 
1462
- /* Shadow */
1463
1367
  .shadow {
1464
1368
  box-shadow: var(--rel-shadows-shadow-300);
1465
1369
  }
@@ -1487,40 +1391,40 @@ var RelDivider = class extends LitElement12 {
1487
1391
  }
1488
1392
  render() {
1489
1393
  return html12`
1490
- <div class="rel-divider ${this.orientation}" role="separator"></div>
1491
- `;
1394
+ <div class="rel-divider ${this.orientation}" role="separator"></div>
1395
+ `;
1492
1396
  }
1493
1397
  };
1494
1398
  RelDivider.styles = css12`
1495
- :host {
1496
- display: block;
1497
- }
1399
+ :host {
1400
+ display: block;
1401
+ }
1498
1402
 
1499
- .rel-divider {
1500
- position: relative;
1501
- display: flex;
1502
- background: transparent;
1503
- font-family: var(--rel-fontFamilies-primary);
1504
- color: var(--rel-colors-gray-primary);
1505
- }
1403
+ .rel-divider {
1404
+ position: relative;
1405
+ display: flex;
1406
+ background: transparent;
1407
+ font-family: var(--rel-fontFamilies-primary);
1408
+ color: var(--rel-colors-gray-primary);
1409
+ }
1506
1410
 
1507
- /* Horizontal */
1508
- .rel-divider.horizontal {
1509
- width: 100%;
1510
- height: var(--rel-borders-width-stroke-100);
1511
- background-color: var(--rel-colors-gray-border);
1512
- margin: var(--rel-spacing-space-md) 0;
1513
- }
1411
+ /* Horizontal */
1412
+ .rel-divider.horizontal {
1413
+ width: 100%;
1414
+ height: var(--rel-borders-width-stroke-100);
1415
+ background-color: var(--rel-colors-gray-border);
1416
+ margin: var(--rel-spacing-space-md) 0;
1417
+ }
1514
1418
 
1515
- /* Vertical */
1516
- .rel-divider.vertical {
1517
- width: var(--rel-borders-width-stroke-100);
1518
- background-color: var(--rel-colors-gray-border);
1519
- margin: 0 var(--rel-spacing-space-md);
1520
- align-self: stretch;
1521
- height: 100%;
1522
- }
1523
- `;
1419
+ /* Vertical */
1420
+ .rel-divider.vertical {
1421
+ width: var(--rel-borders-width-stroke-100);
1422
+ background-color: var(--rel-colors-gray-border);
1423
+ margin: 0 var(--rel-spacing-space-md);
1424
+ align-self: stretch;
1425
+ height: 100%;
1426
+ }
1427
+ `;
1524
1428
  __decorateClass([
1525
1429
  property11({ type: String })
1526
1430
  ], RelDivider.prototype, "orientation", 2);
@@ -1539,12 +1443,14 @@ var RelLayout = class extends LitElement13 {
1539
1443
  this.responsive = true;
1540
1444
  }
1541
1445
  render() {
1542
- const gridStyle = `
1543
- gap: ${this.gap};
1544
- grid-template-columns: repeat(${this.columns}, 1fr);
1545
- `;
1546
1446
  return html13`
1547
- <div class="layout-grid" style="${gridStyle}">
1447
+ <div
1448
+ class="layout-grid"
1449
+ style="
1450
+ gap: ${this.gap};
1451
+ grid-template-columns: repeat(${this.columns}, 1fr);
1452
+ "
1453
+ >
1548
1454
  <slot></slot>
1549
1455
  </div>
1550
1456
  `;
@@ -1562,11 +1468,7 @@ RelLayout.styles = css13`
1562
1468
  font-family: var(--rel-fontFamilies-primary);
1563
1469
  }
1564
1470
 
1565
- /* Responsive breakpoints - only applied when responsive is true */
1566
- :host([responsive]) .layout-grid {
1567
- /* Default: use columns property */
1568
- }
1569
-
1471
+ /* Responsive breakpoints — only when attribute exists */
1570
1472
  @media (max-width: 1024px) {
1571
1473
  :host([responsive]) .layout-grid {
1572
1474
  grid-template-columns: repeat(3, 1fr) !important;
@@ -1592,7 +1494,7 @@ __decorateClass([
1592
1494
  property12({ type: Number })
1593
1495
  ], RelLayout.prototype, "columns", 2);
1594
1496
  __decorateClass([
1595
- property12({ type: Boolean })
1497
+ property12({ type: Boolean, reflect: true })
1596
1498
  ], RelLayout.prototype, "responsive", 2);
1597
1499
  RelLayout = __decorateClass([
1598
1500
  customElement13("rel-layout")
@@ -1600,7 +1502,7 @@ RelLayout = __decorateClass([
1600
1502
 
1601
1503
  // src/components/rel-menu/rel-menu.ts
1602
1504
  import { LitElement as LitElement14, html as html14, css as css14 } from "lit";
1603
- import { customElement as customElement14, property as property13, state as state3 } from "lit/decorators.js";
1505
+ import { customElement as customElement14, property as property13, state } from "lit/decorators.js";
1604
1506
  var RelMenu = class extends LitElement14 {
1605
1507
  constructor() {
1606
1508
  super(...arguments);
@@ -1887,7 +1789,7 @@ __decorateClass([
1887
1789
  property13({ type: Array })
1888
1790
  ], RelMenu.prototype, "items", 2);
1889
1791
  __decorateClass([
1890
- state3()
1792
+ state()
1891
1793
  ], RelMenu.prototype, "focusedIndex", 2);
1892
1794
  RelMenu = __decorateClass([
1893
1795
  customElement14("rel-menu")
@@ -1904,10 +1806,13 @@ var RelProgress = class extends LitElement15 {
1904
1806
  this.radius = 15.9155;
1905
1807
  this.circumference = 2 * Math.PI * this.radius;
1906
1808
  }
1809
+ get safeValue() {
1810
+ return Math.min(100, Math.max(0, this.value));
1811
+ }
1907
1812
  renderLinearDeterminate() {
1908
1813
  return html15`
1909
1814
  <div class="linear-track">
1910
- <div class="linear-bar" style="width: ${this.value}%"></div>
1815
+ <div class="linear-bar" style="width: ${this.safeValue}%"></div>
1911
1816
  </div>
1912
1817
  `;
1913
1818
  }
@@ -1919,18 +1824,19 @@ var RelProgress = class extends LitElement15 {
1919
1824
  `;
1920
1825
  }
1921
1826
  renderCircularDeterminate() {
1922
- const offset = this.circumference - this.value / 100 * this.circumference;
1827
+ const offset = this.circumference - this.safeValue / 100 * this.circumference;
1923
1828
  return html15`
1924
1829
  <div class="circular">
1925
1830
  <svg viewBox="0 0 36 36" class="circular-svg">
1926
- <circle class="circular-bg" cx="18" cy="18" r="15.9155" />
1831
+ <circle class="circular-bg" cx="18" cy="18" r="${this.radius}" />
1927
1832
  <circle
1928
1833
  class="circular-progress"
1929
1834
  cx="18"
1930
1835
  cy="18"
1931
- r="15.9155"
1836
+ r="${this.radius}"
1932
1837
  stroke-dasharray="${this.circumference}"
1933
- stroke-dashoffset="${offset}" />
1838
+ stroke-dashoffset="${offset}"
1839
+ />
1934
1840
  </svg>
1935
1841
  </div>
1936
1842
  `;
@@ -1939,15 +1845,20 @@ var RelProgress = class extends LitElement15 {
1939
1845
  return html15`
1940
1846
  <div class="circular">
1941
1847
  <svg viewBox="0 0 50 50" class="spinner">
1942
- <circle class="spinner-path" cx="25" cy="25" r="20" fill="none" stroke-width="4" />
1848
+ <circle
1849
+ class="spinner-path"
1850
+ cx="25"
1851
+ cy="25"
1852
+ r="20"
1853
+ fill="none"
1854
+ stroke-width="4"
1855
+ />
1943
1856
  </svg>
1944
1857
  </div>
1945
1858
  `;
1946
1859
  }
1947
1860
  render() {
1948
1861
  switch (this.mode) {
1949
- case "linear-determinate":
1950
- return this.renderLinearDeterminate();
1951
1862
  case "linear-indeterminate":
1952
1863
  return this.renderLinearIndeterminate();
1953
1864
  case "circular-determinate":
@@ -1969,7 +1880,7 @@ RelProgress.styles = css15`
1969
1880
  display: inline-block;
1970
1881
  }
1971
1882
 
1972
- /* Linear Progress */
1883
+ /* Linear */
1973
1884
  .linear-track {
1974
1885
  background: var(--rel-colors-gray-border);
1975
1886
  border-radius: var(--rel-borders-radius-border-radius-200);
@@ -2001,7 +1912,7 @@ RelProgress.styles = css15`
2001
1912
  }
2002
1913
  }
2003
1914
 
2004
- /* Circular Progress */
1915
+ /* Circular */
2005
1916
  .circular {
2006
1917
  display: inline-block;
2007
1918
  width: 48px;
@@ -2026,11 +1937,9 @@ RelProgress.styles = css15`
2026
1937
  stroke-width: 3;
2027
1938
  stroke-linecap: round;
2028
1939
  transition: stroke-dashoffset 0.35s;
2029
- transform: rotate(0deg);
2030
- transform-origin: center;
2031
1940
  }
2032
1941
 
2033
- /* Circular Indeterminate Spinner */
1942
+ /* Spinner */
2034
1943
  .spinner {
2035
1944
  animation: rotate 2s linear infinite;
2036
1945
  }
@@ -2063,7 +1972,7 @@ RelProgress.styles = css15`
2063
1972
  }
2064
1973
  `;
2065
1974
  __decorateClass([
2066
- property14({ type: String })
1975
+ property14({ type: String, reflect: true })
2067
1976
  ], RelProgress.prototype, "mode", 2);
2068
1977
  __decorateClass([
2069
1978
  property14({ type: Number })
@@ -2081,25 +1990,24 @@ var RelRadio = class extends LitElement16 {
2081
1990
  this.options = [];
2082
1991
  this.name = "radio-group";
2083
1992
  this.selectedValue = null;
1993
+ this.disabled = false;
2084
1994
  }
2085
1995
  onChange(value) {
1996
+ if (this.disabled) return;
2086
1997
  this.selectedValue = value;
2087
1998
  this.dispatchEvent(
2088
1999
  new CustomEvent("changed", {
2089
- detail: { value },
2090
2000
  bubbles: true,
2091
2001
  composed: true
2092
2002
  })
2093
2003
  );
2094
2004
  }
2095
- isChecked(value) {
2096
- return this.selectedValue === value;
2097
- }
2098
2005
  renderOption(option) {
2099
- const isChecked = this.isChecked(option.value);
2006
+ const isChecked = this.selectedValue === option.value;
2007
+ const isDisabled = this.disabled || option.disabled;
2100
2008
  const classes = [
2101
2009
  "rel-radio-option",
2102
- option.disabled ? "disabled" : "",
2010
+ isDisabled ? "disabled" : "",
2103
2011
  option.error ? "error" : ""
2104
2012
  ].filter(Boolean).join(" ");
2105
2013
  return html16`
@@ -2108,26 +2016,22 @@ var RelRadio = class extends LitElement16 {
2108
2016
  <input
2109
2017
  type="radio"
2110
2018
  name="${this.name}"
2111
- .value="${option.value}"
2112
2019
  .checked="${isChecked}"
2113
- ?disabled="${option.disabled}"
2114
- @change="${() => !option.disabled && this.onChange(option.value)}" />
2020
+ ?disabled="${isDisabled}"
2021
+ @change="${() => this.onChange(option.value)}"
2022
+ />
2115
2023
  <span class="radio-custom"></span>
2116
2024
  <span class="radio-label">${option.label}</span>
2117
2025
  </div>
2118
2026
 
2119
- ${option.supportingText ? html16`
2120
- <div class="radio-supporting ${option.error ? "error-text" : ""}">
2121
- ${option.supportingText}
2122
- </div>
2123
- ` : ""}
2027
+ ${option.supportingText ? html16`<div class="radio-supporting">${option.supportingText}</div>` : ""}
2124
2028
  </label>
2125
2029
  `;
2126
2030
  }
2127
2031
  render() {
2128
2032
  return html16`
2129
2033
  <div class="rel-radio-group">
2130
- ${this.options.map((option) => this.renderOption(option))}
2034
+ ${this.options.map((o) => this.renderOption(o))}
2131
2035
  </div>
2132
2036
  `;
2133
2037
  }
@@ -2147,10 +2051,13 @@ RelRadio.styles = css16`
2147
2051
  .rel-radio-option {
2148
2052
  display: flex;
2149
2053
  flex-direction: column;
2150
- align-items: flex-start;
2151
2054
  gap: var(--rel-spacing-space-3xs);
2152
2055
  cursor: pointer;
2153
- position: relative;
2056
+ }
2057
+
2058
+ .rel-radio-option.disabled {
2059
+ opacity: 0.6;
2060
+ cursor: not-allowed !important;
2154
2061
  }
2155
2062
 
2156
2063
  .radio-main {
@@ -2159,7 +2066,7 @@ RelRadio.styles = css16`
2159
2066
  gap: var(--rel-spacing-space-2xs);
2160
2067
  }
2161
2068
 
2162
- .rel-radio-option input {
2069
+ input {
2163
2070
  position: absolute;
2164
2071
  opacity: 0;
2165
2072
  pointer-events: none;
@@ -2170,75 +2077,33 @@ RelRadio.styles = css16`
2170
2077
  height: 20px;
2171
2078
  border: 2px solid var(--rel-colors-black);
2172
2079
  border-radius: 50%;
2173
- display: inline-block;
2174
2080
  position: relative;
2175
- flex-shrink: 0;
2176
- transition: all 0.2s ease-in-out;
2177
- }
2178
-
2179
- .rel-radio-option input:focus + .radio-custom {
2180
- outline: var(--rel-borders-width-stroke-200) solid var(--rel-colors-black);
2181
- outline-offset: var(--rel-spacing-space-3xs);
2182
2081
  }
2183
2082
 
2184
- .rel-radio-option input:checked + .radio-custom::after {
2083
+ input:checked + .radio-custom::after {
2185
2084
  content: "";
2186
2085
  position: absolute;
2187
- top: 50%;
2188
- left: 50%;
2189
- width: 10px;
2190
- height: 10px;
2191
- background-color: var(--rel-colors-black);
2086
+ inset: 4px;
2087
+ background: var(--rel-colors-black);
2192
2088
  border-radius: 50%;
2193
- transform: translate(-50%, -50%);
2194
- }
2195
-
2196
- /* Error state */
2197
- .rel-radio-option.error .radio-custom {
2198
- border-color: var(--rel-colors-red-secondary);
2199
- }
2200
-
2201
- .rel-radio-option.error input:checked + .radio-custom::after {
2202
- background-color: var(--rel-colors-red-secondary);
2203
- }
2204
-
2205
- .rel-radio-option.error .radio-label,
2206
- .rel-radio-option.error .radio-supporting {
2207
- color: var(--rel-colors-red-secondary);
2208
- }
2209
-
2210
- .rel-radio-option.error input:focus + .radio-custom {
2211
- outline: var(--rel-borders-width-stroke-200) solid var(--rel-colors-red-secondary);
2212
2089
  }
2213
2090
 
2214
- /* Disabled state */
2215
- .rel-radio-option.disabled {
2216
- opacity: 0.6;
2217
- cursor: not-allowed !important;
2218
- }
2219
-
2220
- .rel-radio-option.disabled .radio-label,
2221
- .rel-radio-option.disabled .radio-supporting {
2222
- cursor: not-allowed !important;
2223
- }
2224
-
2225
- /* Text styles */
2226
2091
  .radio-label {
2227
2092
  font-size: var(--rel-fontSizes-sm);
2228
2093
  font-weight: var(--rel-fontWeights-medium);
2229
- color: var(--rel-colors-gray-heading);
2230
- line-height: var(--rel-lineHeights-sm);
2231
2094
  }
2232
2095
 
2233
2096
  .radio-supporting {
2234
2097
  font-size: var(--rel-fontSizes-xs);
2235
- color: var(--rel-colors-gray-placeholder);
2236
2098
  margin-left: 28px;
2237
- line-height: var(--rel-lineHeights-xs);
2238
2099
  }
2239
2100
 
2240
- .radio-supporting.error-text {
2241
- color: var(--rel-colors-red-secondary);
2101
+ .error .radio-custom {
2102
+ border-color: var(--rel-colors-red-secondary);
2103
+ }
2104
+
2105
+ .error input:checked + .radio-custom::after {
2106
+ background: var(--rel-colors-red-secondary);
2242
2107
  }
2243
2108
  `;
2244
2109
  __decorateClass([
@@ -2248,8 +2113,11 @@ __decorateClass([
2248
2113
  property15({ type: String })
2249
2114
  ], RelRadio.prototype, "name", 2);
2250
2115
  __decorateClass([
2251
- property15({ type: String })
2116
+ property15({ type: String, reflect: true })
2252
2117
  ], RelRadio.prototype, "selectedValue", 2);
2118
+ __decorateClass([
2119
+ property15({ type: Boolean })
2120
+ ], RelRadio.prototype, "disabled", 2);
2253
2121
  RelRadio = __decorateClass([
2254
2122
  customElement16("rel-radio")
2255
2123
  ], RelRadio);
@@ -2665,7 +2533,7 @@ RelSelect = __decorateClass([
2665
2533
 
2666
2534
  // src/components/rel-slider/rel-slider.ts
2667
2535
  import { LitElement as LitElement19, html as html19, css as css19 } from "lit";
2668
- import { customElement as customElement19, property as property18, state as state4 } from "lit/decorators.js";
2536
+ import { customElement as customElement19, property as property18, state as state2 } from "lit/decorators.js";
2669
2537
  var RelSlider = class extends LitElement19 {
2670
2538
  constructor() {
2671
2539
  super(...arguments);
@@ -3091,7 +2959,7 @@ __decorateClass([
3091
2959
  property18({ type: Number })
3092
2960
  ], RelSlider.prototype, "value", 2);
3093
2961
  __decorateClass([
3094
- state4()
2962
+ state2()
3095
2963
  ], RelSlider.prototype, "ticks", 2);
3096
2964
  RelSlider = __decorateClass([
3097
2965
  customElement19("rel-slider")
@@ -3099,7 +2967,7 @@ RelSlider = __decorateClass([
3099
2967
 
3100
2968
  // src/components/rel-snackbar/rel-snackbar.ts
3101
2969
  import { LitElement as LitElement20, html as html20, css as css20 } from "lit";
3102
- import { customElement as customElement20, property as property19, state as state5 } from "lit/decorators.js";
2970
+ import { customElement as customElement20, property as property19, state as state3 } from "lit/decorators.js";
3103
2971
  var RelSnackbar = class extends LitElement20 {
3104
2972
  constructor() {
3105
2973
  super(...arguments);
@@ -3115,6 +2983,11 @@ var RelSnackbar = class extends LitElement20 {
3115
2983
  super.connectedCallback();
3116
2984
  this.setAutoDismiss();
3117
2985
  }
2986
+ updated(changed) {
2987
+ if (changed.has("duration") || changed.has("longerAction")) {
2988
+ this.setAutoDismiss();
2989
+ }
2990
+ }
3118
2991
  disconnectedCallback() {
3119
2992
  super.disconnectedCallback();
3120
2993
  this.clearTimeout();
@@ -3305,7 +3178,7 @@ __decorateClass([
3305
3178
  property19({ type: Number })
3306
3179
  ], RelSnackbar.prototype, "duration", 2);
3307
3180
  __decorateClass([
3308
- state5()
3181
+ state3()
3309
3182
  ], RelSnackbar.prototype, "visible", 2);
3310
3183
  RelSnackbar = __decorateClass([
3311
3184
  customElement20("rel-snackbar")
@@ -3338,6 +3211,19 @@ var RelStepper = class extends LitElement21 {
3338
3211
  if (this.isDisabled(step)) classes.push("disabled");
3339
3212
  return classes.join(" ");
3340
3213
  }
3214
+ onStepClick(step, index) {
3215
+ if (step.status === "disabled") return;
3216
+ this.dispatchEvent(
3217
+ new CustomEvent("step-change", {
3218
+ detail: {
3219
+ index,
3220
+ step
3221
+ },
3222
+ bubbles: true,
3223
+ composed: true
3224
+ })
3225
+ );
3226
+ }
3341
3227
  renderIndicator(step, index) {
3342
3228
  if (step.status === "done") {
3343
3229
  return html21`
@@ -3371,7 +3257,10 @@ var RelStepper = class extends LitElement21 {
3371
3257
  <div class="${stepperClasses}">
3372
3258
  ${this.steps.map(
3373
3259
  (step, idx) => html21`
3374
- <div class="${this.getStepClasses(step)}">
3260
+ <div
3261
+ class="${this.getStepClasses(step)}"
3262
+ @click="${() => this.onStepClick(step, idx)}"
3263
+ >
3375
3264
  ${isVertical && isTextRight ? html21`
3376
3265
  <!-- Indicator with connector below -->
3377
3266
  <div class="indicator-wrapper">
@@ -3620,7 +3509,10 @@ RelStepper.styles = css21`
3620
3509
  display: none;
3621
3510
  }
3622
3511
 
3623
- .rel-stepper.vertical.text-right .rel-step:last-child .indicator-wrapper .connector {
3512
+ .rel-stepper.vertical.text-right
3513
+ .rel-step:last-child
3514
+ .indicator-wrapper
3515
+ .connector {
3624
3516
  display: none;
3625
3517
  }
3626
3518
 
@@ -3722,7 +3614,7 @@ RelStepper = __decorateClass([
3722
3614
 
3723
3615
  // src/components/rel-switch/rel-switch.ts
3724
3616
  import { LitElement as LitElement22, html as html22, css as css22 } from "lit";
3725
- import { customElement as customElement22, property as property21, state as state6 } from "lit/decorators.js";
3617
+ import { customElement as customElement22, property as property21, state as state4 } from "lit/decorators.js";
3726
3618
  var RelSwitch = class extends LitElement22 {
3727
3619
  constructor() {
3728
3620
  super(...arguments);
@@ -3731,10 +3623,10 @@ var RelSwitch = class extends LitElement22 {
3731
3623
  this.isFocused = false;
3732
3624
  this.isPressed = false;
3733
3625
  }
3734
- toggle() {
3626
+ toggle(ev) {
3735
3627
  if (this.disabled) return;
3736
- this.checked = !this.checked;
3737
- this.requestUpdate();
3628
+ const input = ev.target;
3629
+ this.checked = input.checked;
3738
3630
  this.dispatchEvent(
3739
3631
  new CustomEvent("changed", {
3740
3632
  detail: this.checked,
@@ -3769,7 +3661,7 @@ var RelSwitch = class extends LitElement22 {
3769
3661
  type="checkbox"
3770
3662
  ?disabled=${this.disabled}
3771
3663
  .checked=${this.checked}
3772
- @change=${this.toggle}
3664
+ @change=${(e) => this.toggle(e)}
3773
3665
  @focus=${this.handleFocus}
3774
3666
  @blur=${this.handleBlur}
3775
3667
  @mousedown=${this.handleMouseDown}
@@ -3879,10 +3771,10 @@ __decorateClass([
3879
3771
  property21({ type: Boolean })
3880
3772
  ], RelSwitch.prototype, "disabled", 2);
3881
3773
  __decorateClass([
3882
- state6()
3774
+ state4()
3883
3775
  ], RelSwitch.prototype, "isFocused", 2);
3884
3776
  __decorateClass([
3885
- state6()
3777
+ state4()
3886
3778
  ], RelSwitch.prototype, "isPressed", 2);
3887
3779
  RelSwitch = __decorateClass([
3888
3780
  customElement22("rel-switch")
@@ -3902,7 +3794,7 @@ var RelTab = class extends LitElement23 {
3902
3794
  this.activeIndex = index;
3903
3795
  this.dispatchEvent(
3904
3796
  new CustomEvent("tab-change", {
3905
- detail: { index },
3797
+ detail: index,
3906
3798
  bubbles: true,
3907
3799
  composed: true
3908
3800
  })
@@ -3917,13 +3809,15 @@ var RelTab = class extends LitElement23 {
3917
3809
  }
3918
3810
  render() {
3919
3811
  return html23`
3920
- <div class="tabs-wrapper">
3812
+ <div class="tabs-wrapper" role="tablist">
3921
3813
  ${this.tabs.map(
3922
3814
  (tab, i) => html23`
3923
3815
  <div
3924
3816
  class="tab ${i === this.activeIndex ? "active" : ""} ${tab.disabled ? "disabled" : ""}"
3925
3817
  role="tab"
3926
- tabindex="${tab.disabled ? -1 : 0}"
3818
+ aria-selected="${i === this.activeIndex}"
3819
+ aria-disabled="${tab.disabled ?? false}"
3820
+ tabindex="${tab.disabled ? -1 : i === this.activeIndex ? 0 : -1}"
3927
3821
  @click="${() => this.selectTab(i)}"
3928
3822
  @keydown="${(e) => this.onKeyDown(e, i)}"
3929
3823
  >
@@ -4025,7 +3919,7 @@ __decorateClass([
4025
3919
  property22({ type: Array })
4026
3920
  ], RelTab.prototype, "tabs", 2);
4027
3921
  __decorateClass([
4028
- property22({ type: Number })
3922
+ property22({ type: Number, reflect: true })
4029
3923
  ], RelTab.prototype, "activeIndex", 2);
4030
3924
  RelTab = __decorateClass([
4031
3925
  customElement23("rel-tab")
@@ -4033,7 +3927,7 @@ RelTab = __decorateClass([
4033
3927
 
4034
3928
  // src/components/rel-textfield/rel-textfield.ts
4035
3929
  import { LitElement as LitElement24, html as html24, css as css24 } from "lit";
4036
- import { customElement as customElement24, property as property23, state as state7 } from "lit/decorators.js";
3930
+ import { customElement as customElement24, property as property23, state as state5 } from "lit/decorators.js";
4037
3931
  var RelTextfield = class extends LitElement24 {
4038
3932
  constructor() {
4039
3933
  super(...arguments);
@@ -4062,7 +3956,7 @@ var RelTextfield = class extends LitElement24 {
4062
3956
  this.value = input.value;
4063
3957
  this.dispatchEvent(
4064
3958
  new CustomEvent("input-change", {
4065
- detail: { value: this.value },
3959
+ detail: this.value,
4066
3960
  bubbles: true,
4067
3961
  composed: true
4068
3962
  })
@@ -4255,7 +4149,7 @@ __decorateClass([
4255
4149
  property23({ type: String })
4256
4150
  ], RelTextfield.prototype, "size", 2);
4257
4151
  __decorateClass([
4258
- state7()
4152
+ state5()
4259
4153
  ], RelTextfield.prototype, "internalState", 2);
4260
4154
  RelTextfield = __decorateClass([
4261
4155
  customElement24("rel-textfield")
@@ -4263,7 +4157,7 @@ RelTextfield = __decorateClass([
4263
4157
 
4264
4158
  // src/components/rel-toast/rel-toast.ts
4265
4159
  import { LitElement as LitElement25, html as html25, css as css25 } from "lit";
4266
- import { customElement as customElement25, property as property24, state as state8 } from "lit/decorators.js";
4160
+ import { customElement as customElement25, property as property24, state as state6 } from "lit/decorators.js";
4267
4161
  var RelToast = class extends LitElement25 {
4268
4162
  constructor() {
4269
4163
  super(...arguments);
@@ -4417,7 +4311,7 @@ __decorateClass([
4417
4311
  property24({ type: Number })
4418
4312
  ], RelToast.prototype, "duration", 2);
4419
4313
  __decorateClass([
4420
- state8()
4314
+ state6()
4421
4315
  ], RelToast.prototype, "visible", 2);
4422
4316
  RelToast = __decorateClass([
4423
4317
  customElement25("rel-toast")