@reliability-design/web 1.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (60) hide show
  1. package/dist/components/rel-accordion/rel-accordion.stories.ts +313 -0
  2. package/dist/components/rel-accordion/rel-accordion.ts +114 -0
  3. package/dist/components/rel-alert/rel-alert.stories.ts +412 -0
  4. package/dist/components/rel-alert/rel-alert.ts +194 -0
  5. package/dist/components/rel-avatar/rel-avatar.stories.ts +327 -0
  6. package/dist/components/rel-avatar/rel-avatar.ts +100 -0
  7. package/dist/components/rel-badge/rel-badge.stories.ts +350 -0
  8. package/dist/components/rel-badge/rel-badge.ts +70 -0
  9. package/dist/components/rel-breadcrumb/rel-breadcrumb.stories.ts +306 -0
  10. package/dist/components/rel-breadcrumb/rel-breadcrumb.ts +97 -0
  11. package/dist/components/rel-button/rel-button.stories.ts +356 -0
  12. package/dist/components/rel-button/rel-button.ts +204 -0
  13. package/dist/components/rel-card/rel-card.stories.ts +299 -0
  14. package/dist/components/rel-card/rel-card.ts +33 -0
  15. package/dist/components/rel-cardmedia/rel-cardmedia.stories.ts +368 -0
  16. package/dist/components/rel-cardmedia/rel-cardmedia.ts +80 -0
  17. package/dist/components/rel-checkbox/rel-checkbox.stories.ts +414 -0
  18. package/dist/components/rel-checkbox/rel-checkbox.ts +164 -0
  19. package/dist/components/rel-chip/rel-chip.stories.ts +552 -0
  20. package/dist/components/rel-chip/rel-chip.ts +261 -0
  21. package/dist/components/rel-container/rel-container.stories.ts +239 -0
  22. package/dist/components/rel-container/rel-container.ts +74 -0
  23. package/dist/components/rel-divider/rel-divider.stories.ts +229 -0
  24. package/dist/components/rel-divider/rel-divider.ts +44 -0
  25. package/dist/components/rel-layout/rel-layout.stories.ts +713 -0
  26. package/dist/components/rel-layout/rel-layout.ts +60 -0
  27. package/dist/components/rel-menu/rel-menu.stories.ts +910 -0
  28. package/dist/components/rel-menu/rel-menu.ts +319 -0
  29. package/dist/components/rel-progress/rel-progress.stories.ts +817 -0
  30. package/dist/components/rel-progress/rel-progress.ts +182 -0
  31. package/dist/components/rel-radio/rel-radio.stories.ts +1048 -0
  32. package/dist/components/rel-radio/rel-radio.ts +187 -0
  33. package/dist/components/rel-segmented-button/rel-segmented-button.stories.ts +1079 -0
  34. package/dist/components/rel-segmented-button/rel-segmented-button.ts +150 -0
  35. package/dist/components/rel-select/rel-select.stories.ts +1201 -0
  36. package/dist/components/rel-select/rel-select.ts +261 -0
  37. package/dist/components/rel-slider/rel-slider.stories.ts +730 -0
  38. package/dist/components/rel-slider/rel-slider.ts +440 -0
  39. package/dist/components/rel-snackbar/rel-snackbar.stories.ts +808 -0
  40. package/dist/components/rel-snackbar/rel-snackbar.ts +212 -0
  41. package/dist/components/rel-stepper/rel-stepper.stories.ts +752 -0
  42. package/dist/components/rel-stepper/rel-stepper.ts +425 -0
  43. package/dist/components/rel-switch/rel-switch.stories.ts +441 -0
  44. package/dist/components/rel-switch/rel-switch.ts +161 -0
  45. package/dist/components/rel-tab/rel-tab.stories.ts +492 -0
  46. package/dist/components/rel-tab/rel-tab.ts +145 -0
  47. package/dist/components/rel-textfield/rel-textfield.stories.ts +710 -0
  48. package/dist/components/rel-textfield/rel-textfield.ts +224 -0
  49. package/dist/components/rel-toast/rel-toast.stories.ts +394 -0
  50. package/dist/components/rel-toast/rel-toast.ts +154 -0
  51. package/dist/components/rel-tooltip/rel-tooltip.stories.ts +364 -0
  52. package/dist/components/rel-tooltip/rel-tooltip.ts +80 -0
  53. package/dist/index.d.mts +372 -0
  54. package/dist/index.d.ts +372 -0
  55. package/dist/index.js +4593 -0
  56. package/dist/index.js.map +1 -0
  57. package/dist/index.mjs +4544 -0
  58. package/dist/index.mjs.map +1 -0
  59. package/dist/styles/vars.css +184 -0
  60. package/package.json +32 -0
@@ -0,0 +1,372 @@
1
+ import * as lit_html from 'lit-html';
2
+ import * as lit from 'lit';
3
+ import { LitElement } from 'lit';
4
+
5
+ declare class RelAccordion extends LitElement {
6
+ title: string;
7
+ open: boolean;
8
+ static styles: lit.CSSResult;
9
+ private toggle;
10
+ private chevron;
11
+ render(): lit_html.TemplateResult<1>;
12
+ }
13
+
14
+ declare class RelAlert extends LitElement {
15
+ type: "info" | "success" | "warning" | "error" | "neutral";
16
+ message1: string;
17
+ message2?: string;
18
+ urlText?: string;
19
+ urlHref?: string;
20
+ dismissible: boolean;
21
+ dismissed: boolean;
22
+ static styles: lit.CSSResult;
23
+ private get iconSvg();
24
+ private dismissAlert;
25
+ render(): lit_html.TemplateResult<1> | null;
26
+ }
27
+
28
+ declare class RelAvatar extends LitElement {
29
+ size: "lg" | "md" | "sm" | "xs";
30
+ type: "image" | "text" | "icon";
31
+ src: string;
32
+ text: string;
33
+ alt: string;
34
+ static styles: lit.CSSResult;
35
+ render(): lit_html.TemplateResult<1>;
36
+ }
37
+
38
+ declare class RelBadge extends LitElement {
39
+ number: string;
40
+ size: "sm" | "md" | "lg";
41
+ variant: "dot" | "number";
42
+ static styles: lit.CSSResult;
43
+ private get classes();
44
+ render(): lit_html.TemplateResult<1>;
45
+ }
46
+
47
+ interface BreadcrumbItem {
48
+ label: string;
49
+ url?: string;
50
+ }
51
+ declare class RelBreadcrumbs extends LitElement {
52
+ items: BreadcrumbItem[];
53
+ static styles: lit.CSSResult;
54
+ render(): lit_html.TemplateResult<1>;
55
+ }
56
+
57
+ declare class RelButton extends LitElement {
58
+ variant: "default" | "primary" | "secondary" | "text" | "link" | "icon";
59
+ tone: "default" | "critical" | "success";
60
+ size: "small" | "medium" | "large";
61
+ border: "corner-radius" | "small-corner-radius" | "no-corner-radius";
62
+ disabled: boolean;
63
+ static styles: lit.CSSResult;
64
+ private get classes();
65
+ render(): lit_html.TemplateResult<1>;
66
+ }
67
+
68
+ declare class RelCard extends LitElement {
69
+ static styles: lit.CSSResult;
70
+ render(): lit_html.TemplateResult<1>;
71
+ }
72
+
73
+ declare class RelCardMedia extends LitElement {
74
+ imageSrc: string;
75
+ imageAlt: string;
76
+ title: string;
77
+ subtitle: string;
78
+ static styles: lit.CSSResult;
79
+ render(): lit_html.TemplateResult<1>;
80
+ }
81
+
82
+ type CheckboxState = "default" | "error" | "disabled";
83
+ type CheckboxStatus = "unchecked" | "checked" | "indeterminate";
84
+ declare class RelCheckbox extends LitElement {
85
+ label: string;
86
+ supportingtext: string;
87
+ state: CheckboxState;
88
+ status: CheckboxStatus;
89
+ static styles: lit.CSSResult;
90
+ private toggle;
91
+ render(): lit_html.TemplateResult<1>;
92
+ }
93
+
94
+ declare class RelChip extends LitElement {
95
+ label: string;
96
+ tone: "default" | "blue" | "yellow" | "red" | "green";
97
+ leadingIcon?: string;
98
+ trailingIcon?: string;
99
+ avatar?: string;
100
+ removable: boolean;
101
+ outline: boolean;
102
+ private removed;
103
+ static styles: lit.CSSResult;
104
+ private get classes();
105
+ private handleRemove;
106
+ private handleKeyDown;
107
+ render(): lit_html.TemplateResult<1> | null;
108
+ private renderIcon;
109
+ }
110
+
111
+ declare class RelContainer extends LitElement {
112
+ padding: "sm" | "md" | "lg";
113
+ shadow: boolean;
114
+ background: "light" | "white" | "none";
115
+ static styles: lit.CSSResult;
116
+ private get classes();
117
+ render(): lit_html.TemplateResult<1>;
118
+ }
119
+
120
+ declare class RelDivider extends LitElement {
121
+ orientation: "horizontal" | "vertical";
122
+ static styles: lit.CSSResult;
123
+ render(): lit_html.TemplateResult<1>;
124
+ }
125
+
126
+ declare class RelLayout extends LitElement {
127
+ gap: string;
128
+ columns: number;
129
+ responsive: boolean;
130
+ static styles: lit.CSSResult;
131
+ render(): lit_html.TemplateResult<1>;
132
+ }
133
+
134
+ type MenuType = "default" | "checkbox" | "arrow";
135
+ interface MenuItem {
136
+ label: string;
137
+ active?: boolean;
138
+ checked?: boolean;
139
+ disabled?: boolean;
140
+ submenu?: MenuItem[];
141
+ open?: boolean;
142
+ }
143
+ declare class RelMenu extends LitElement {
144
+ type: MenuType;
145
+ items: MenuItem[];
146
+ private focusedIndex;
147
+ static styles: lit.CSSResult;
148
+ connectedCallback(): void;
149
+ disconnectedCallback(): void;
150
+ private handleDocumentClick;
151
+ private onItemEnter;
152
+ private onItemLeave;
153
+ private onItemClick;
154
+ private onSubClick;
155
+ private toggleCheckbox;
156
+ private onKeydown;
157
+ private renderMenuItem;
158
+ render(): lit_html.TemplateResult<1>;
159
+ }
160
+
161
+ type ProgressMode = "linear-determinate" | "linear-indeterminate" | "circular-determinate" | "circular-indeterminate";
162
+ declare class RelProgress extends LitElement {
163
+ mode: ProgressMode;
164
+ value: number;
165
+ private radius;
166
+ private circumference;
167
+ static styles: lit.CSSResult;
168
+ private renderLinearDeterminate;
169
+ private renderLinearIndeterminate;
170
+ private renderCircularDeterminate;
171
+ private renderCircularIndeterminate;
172
+ render(): lit_html.TemplateResult<1>;
173
+ }
174
+
175
+ interface RadioOption {
176
+ value: string;
177
+ label: string;
178
+ supportingText?: string;
179
+ disabled?: boolean;
180
+ error?: boolean;
181
+ }
182
+ declare class RelRadio extends LitElement {
183
+ options: RadioOption[];
184
+ name: string;
185
+ selectedValue: string | null;
186
+ static styles: lit.CSSResult;
187
+ private onChange;
188
+ private isChecked;
189
+ private renderOption;
190
+ render(): lit_html.TemplateResult<1>;
191
+ }
192
+
193
+ type SegmentSize = "small" | "medium";
194
+ type SegmentAlign = "left" | "middle" | "right";
195
+ interface SegmentOption {
196
+ label: string;
197
+ value: string;
198
+ disabled?: boolean;
199
+ }
200
+ declare class RelSegmentedButton extends LitElement {
201
+ options: SegmentOption[];
202
+ active: string;
203
+ size: SegmentSize;
204
+ align: SegmentAlign;
205
+ static styles: lit.CSSResult;
206
+ private setActive;
207
+ private renderSegment;
208
+ render(): lit_html.TemplateResult<1>;
209
+ }
210
+
211
+ type SelectState = "default" | "error" | "disabled";
212
+ type SelectSize = "small" | "medium" | "large";
213
+ type SelectBorder = "rounded" | "sharp";
214
+ declare class RelSelect extends LitElement {
215
+ label: string;
216
+ options: string[];
217
+ selected: string;
218
+ state: SelectState;
219
+ supportingText: string;
220
+ size: SelectSize;
221
+ border: SelectBorder;
222
+ leftIcon: string;
223
+ rightIcon: string;
224
+ static styles: lit.CSSResult;
225
+ private onChange;
226
+ render(): lit_html.TemplateResult<1>;
227
+ }
228
+
229
+ type SliderType = "continuous" | "discrete";
230
+ type TrackStyle = "solid" | "dotted";
231
+ declare class RelSlider extends LitElement {
232
+ type: SliderType;
233
+ min: number;
234
+ max: number;
235
+ step: number;
236
+ disabled: boolean;
237
+ track: TrackStyle;
238
+ showTickLabels: boolean;
239
+ showBubble: boolean;
240
+ value: number;
241
+ private ticks;
242
+ static styles: lit.CSSResult;
243
+ connectedCallback(): void;
244
+ updated(changedProperties: Map<string, any>): void;
245
+ private get percentage();
246
+ private setupTicks;
247
+ private getTickLeftPct;
248
+ private isTickActive;
249
+ private onInput;
250
+ private updateActiveWidth;
251
+ private renderThumbContainer;
252
+ private renderTicks;
253
+ private renderTickLabels;
254
+ render(): lit_html.TemplateResult<1>;
255
+ }
256
+
257
+ type SnackbarLines = "single" | "double";
258
+ declare class RelSnackbar extends LitElement {
259
+ message: string;
260
+ action?: string;
261
+ longerAction: boolean;
262
+ iconClose: boolean;
263
+ lines: SnackbarLines;
264
+ duration: number;
265
+ private visible;
266
+ private timeout;
267
+ static styles: lit.CSSResult;
268
+ connectedCallback(): void;
269
+ disconnectedCallback(): void;
270
+ private setAutoDismiss;
271
+ private clearTimeout;
272
+ private onActionClick;
273
+ private dismiss;
274
+ render(): lit_html.TemplateResult<1>;
275
+ }
276
+
277
+ type StepStatus = "done" | "progress" | "disabled";
278
+ type TextAlign = "right" | "below";
279
+ type Orientation = "horizontal" | "vertical";
280
+ type StepperSize = "small" | "large";
281
+ interface Step {
282
+ title: string;
283
+ status: StepStatus;
284
+ }
285
+ declare class RelStepper extends LitElement {
286
+ steps: Step[];
287
+ textAlign: TextAlign;
288
+ orientation: Orientation;
289
+ size: StepperSize;
290
+ static styles: lit.CSSResult;
291
+ private isDone;
292
+ private isProgress;
293
+ private isDisabled;
294
+ private getStepClasses;
295
+ private renderIndicator;
296
+ render(): lit_html.TemplateResult<1>;
297
+ }
298
+
299
+ declare class RelSwitch extends LitElement {
300
+ checked: boolean;
301
+ disabled: boolean;
302
+ private isFocused;
303
+ private isPressed;
304
+ static styles: lit.CSSResult;
305
+ private toggle;
306
+ private handleFocus;
307
+ private handleBlur;
308
+ private handleMouseDown;
309
+ private handleMouseUp;
310
+ render(): lit_html.TemplateResult<1>;
311
+ }
312
+
313
+ interface TabItem {
314
+ label: string;
315
+ badge?: number;
316
+ disabled?: boolean;
317
+ }
318
+ declare class RelTab extends LitElement {
319
+ tabs: TabItem[];
320
+ activeIndex: number;
321
+ static styles: lit.CSSResult;
322
+ private selectTab;
323
+ private onKeyDown;
324
+ render(): lit_html.TemplateResult<1>;
325
+ }
326
+
327
+ type TextFieldState = "default" | "focused" | "error" | "disabled";
328
+ type TextFieldSize = "small" | "medium" | "large";
329
+ declare class RelTextfield extends LitElement {
330
+ label?: string;
331
+ placeholder: string;
332
+ type: string;
333
+ value: string;
334
+ leftIcon?: string;
335
+ rightIcon?: string;
336
+ supportingText?: string;
337
+ state: TextFieldState;
338
+ size: TextFieldSize;
339
+ private internalState;
340
+ static styles: lit.CSSResult;
341
+ private get currentState();
342
+ private handleFocus;
343
+ private handleBlur;
344
+ private handleInput;
345
+ render(): lit_html.TemplateResult<1>;
346
+ }
347
+
348
+ type ToastType = "default" | "error";
349
+ declare class RelToast extends LitElement {
350
+ message: string;
351
+ type: ToastType;
352
+ actionLabel?: string;
353
+ duration: number;
354
+ private visible;
355
+ private timeoutId?;
356
+ static styles: lit.CSSResult;
357
+ show(): void;
358
+ close(): void;
359
+ private handleActionClick;
360
+ render(): lit_html.TemplateResult<1>;
361
+ }
362
+
363
+ type TooltipPosition = "above" | "below";
364
+ declare class RelTooltip extends LitElement {
365
+ text: string;
366
+ position: TooltipPosition;
367
+ showTail: boolean;
368
+ static styles: lit.CSSResult;
369
+ render(): lit_html.TemplateResult<1>;
370
+ }
371
+
372
+ export { type MenuItem, type MenuType, type Orientation, type ProgressMode, type RadioOption, RelAccordion, RelAlert, RelAvatar, RelBadge, RelBreadcrumbs, RelButton, RelCard, RelCardMedia, RelCheckbox, RelChip, RelContainer, RelDivider, RelLayout, RelMenu, RelProgress, RelRadio, RelSegmentedButton, RelSelect, RelSlider, RelSnackbar, RelStepper, RelSwitch, RelTab, RelTextfield, RelToast, RelTooltip, type SegmentAlign, type SegmentOption, type SegmentSize, type SelectBorder, type SelectSize, type SelectState, type SliderType, type SnackbarLines, type Step, type StepStatus, type StepperSize, type TabItem, type TextAlign, type TextFieldSize, type TextFieldState, type ToastType, type TooltipPosition, type TrackStyle };