svelte-multistyle-ui 0.0.6-alpha → 0.0.8-alpha

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 (113) hide show
  1. package/cli/bin.js +3 -0
  2. package/cli/emit.js +3 -5
  3. package/cli/fixtures/sample.expected.svelte +229 -56
  4. package/cli/fixtures/sample.yaml +254 -128
  5. package/cli/generate.js +438 -7
  6. package/dist/components/Accordion.svelte +3 -1
  7. package/dist/components/Accordion.svelte.d.ts +2 -0
  8. package/dist/components/Alert.svelte +5 -3
  9. package/dist/components/Alert.svelte.d.ts +4 -2
  10. package/dist/components/Avatar.svelte +3 -1
  11. package/dist/components/Avatar.svelte.d.ts +2 -0
  12. package/dist/components/Breadcrumb.svelte +3 -2
  13. package/dist/components/Breadcrumb.svelte.d.ts +2 -0
  14. package/dist/components/Button.svelte +3 -1
  15. package/dist/components/Button.svelte.d.ts +2 -0
  16. package/dist/components/ButtonGroup.svelte +3 -1
  17. package/dist/components/ButtonGroup.svelte.d.ts +2 -0
  18. package/dist/components/Card.svelte +2 -1
  19. package/dist/components/Carousel.svelte +3 -1
  20. package/dist/components/Carousel.svelte.d.ts +2 -0
  21. package/dist/components/Checkbox.svelte +3 -1
  22. package/dist/components/Checkbox.svelte.d.ts +2 -0
  23. package/dist/components/Chip.svelte +3 -1
  24. package/dist/components/Chip.svelte.d.ts +2 -0
  25. package/dist/components/Column.svelte +2 -1
  26. package/dist/components/CommandPalette.svelte +3 -1
  27. package/dist/components/CommandPalette.svelte.d.ts +2 -0
  28. package/dist/components/DatePicker.svelte +3 -1
  29. package/dist/components/DatePicker.svelte.d.ts +2 -0
  30. package/dist/components/Divider.svelte +3 -1
  31. package/dist/components/Divider.svelte.d.ts +2 -0
  32. package/dist/components/Drawer.svelte +3 -1
  33. package/dist/components/Drawer.svelte.d.ts +2 -0
  34. package/dist/components/DropdownMenu.svelte +3 -1
  35. package/dist/components/DropdownMenu.svelte.d.ts +2 -0
  36. package/dist/components/FAB.svelte +3 -1
  37. package/dist/components/FAB.svelte.d.ts +2 -0
  38. package/dist/components/FileUpload.svelte +3 -1
  39. package/dist/components/FileUpload.svelte.d.ts +2 -0
  40. package/dist/components/Grid.svelte +2 -1
  41. package/dist/components/IconButton.svelte +3 -1
  42. package/dist/components/IconButton.svelte.d.ts +2 -0
  43. package/dist/components/Input.svelte +3 -1
  44. package/dist/components/Input.svelte.d.ts +2 -0
  45. package/dist/components/Modal.svelte +3 -1
  46. package/dist/components/Modal.svelte.d.ts +2 -0
  47. package/dist/components/MultiSelect.svelte +3 -1
  48. package/dist/components/MultiSelect.svelte.d.ts +2 -0
  49. package/dist/components/Pagination.svelte +3 -1
  50. package/dist/components/Pagination.svelte.d.ts +2 -0
  51. package/dist/components/Popover.svelte +3 -1
  52. package/dist/components/Popover.svelte.d.ts +2 -0
  53. package/dist/components/ProgressBar.svelte +3 -1
  54. package/dist/components/ProgressBar.svelte.d.ts +2 -0
  55. package/dist/components/Radio.svelte +3 -1
  56. package/dist/components/Radio.svelte.d.ts +2 -0
  57. package/dist/components/Rating.svelte +3 -1
  58. package/dist/components/Rating.svelte.d.ts +2 -0
  59. package/dist/components/Row.svelte +2 -1
  60. package/dist/components/Select.svelte +3 -1
  61. package/dist/components/Select.svelte.d.ts +2 -0
  62. package/dist/components/Skeleton.svelte +3 -1
  63. package/dist/components/Skeleton.svelte.d.ts +2 -0
  64. package/dist/components/Slider.svelte +3 -1
  65. package/dist/components/Slider.svelte.d.ts +2 -0
  66. package/dist/components/SortableList.svelte +3 -1
  67. package/dist/components/SortableList.svelte.d.ts +2 -0
  68. package/dist/components/Spinner.svelte +3 -1
  69. package/dist/components/Spinner.svelte.d.ts +2 -0
  70. package/dist/components/Stepper.svelte +3 -1
  71. package/dist/components/Stepper.svelte.d.ts +2 -0
  72. package/dist/components/Table.svelte +3 -1
  73. package/dist/components/Table.svelte.d.ts +2 -0
  74. package/dist/components/Tabs.svelte +3 -1
  75. package/dist/components/Tabs.svelte.d.ts +2 -0
  76. package/dist/components/Textarea.svelte +3 -1
  77. package/dist/components/Textarea.svelte.d.ts +2 -0
  78. package/dist/components/Toast.svelte +7 -5
  79. package/dist/components/Toast.svelte.d.ts +2 -0
  80. package/dist/components/Toggle.svelte +3 -1
  81. package/dist/components/Toggle.svelte.d.ts +2 -0
  82. package/dist/components/Tooltip.svelte +3 -1
  83. package/dist/components/Tooltip.svelte.d.ts +2 -0
  84. package/dist/components/charts/BarChart.svelte +2 -2
  85. package/dist/components/charts/BarChart.svelte.d.ts +2 -0
  86. package/dist/components/charts/BubbleChart.svelte +2 -2
  87. package/dist/components/charts/BubbleChart.svelte.d.ts +2 -0
  88. package/dist/components/charts/Chart.svelte +3 -1
  89. package/dist/components/charts/Chart.svelte.d.ts +2 -0
  90. package/dist/components/charts/ComboChart.svelte +2 -2
  91. package/dist/components/charts/ComboChart.svelte.d.ts +2 -0
  92. package/dist/components/charts/DoughnutChart.svelte +2 -2
  93. package/dist/components/charts/DoughnutChart.svelte.d.ts +2 -0
  94. package/dist/components/charts/LineChart.svelte +2 -2
  95. package/dist/components/charts/LineChart.svelte.d.ts +2 -0
  96. package/dist/components/charts/PieChart.svelte +2 -2
  97. package/dist/components/charts/PieChart.svelte.d.ts +2 -0
  98. package/dist/components/charts/PolarAreaChart.svelte +2 -2
  99. package/dist/components/charts/PolarAreaChart.svelte.d.ts +2 -0
  100. package/dist/components/charts/RadarChart.svelte +2 -2
  101. package/dist/components/charts/RadarChart.svelte.d.ts +2 -0
  102. package/dist/components/charts/ScatterChart.svelte +2 -2
  103. package/dist/components/charts/ScatterChart.svelte.d.ts +2 -0
  104. package/dist/components/charts/StackedBarChart.svelte +2 -2
  105. package/dist/components/charts/StackedBarChart.svelte.d.ts +2 -0
  106. package/dist/components/charts/StackedLineChart.svelte +2 -2
  107. package/dist/components/charts/StackedLineChart.svelte.d.ts +2 -0
  108. package/dist/components/select-styles.css +6 -1
  109. package/dist/index.d.ts +1 -0
  110. package/dist/index.js +3 -0
  111. package/dist/utils/cn.d.ts +1 -0
  112. package/dist/utils/cn.js +9 -0
  113. package/package.json +4 -3
@@ -11,6 +11,7 @@ declare const ButtonGroup: import("svelte").Component<{
11
11
  items?: any[];
12
12
  value?: string;
13
13
  orientation?: string;
14
+ class?: string;
14
15
  } & Record<string, any>, {}, "value">;
15
16
  type $$ComponentProps = {
16
17
  style: any;
@@ -20,4 +21,5 @@ type $$ComponentProps = {
20
21
  items?: any[];
21
22
  value?: string;
22
23
  orientation?: string;
24
+ class?: string;
23
25
  } & Record<string, any>;
@@ -1,6 +1,7 @@
1
1
  <script>
2
2
  import "./card-styles.css";
3
3
  import { defaults } from "../config.js";
4
+ import { cn } from "../utils/cn.js";
4
5
 
5
6
  let {
6
7
  style: styleProp,
@@ -21,7 +22,7 @@
21
22
  </script>
22
23
 
23
24
  <div
24
- class="s-card {styleClass} {themeClass} {padClass} {className}"
25
+ class={cn("s-card", styleClass, themeClass, padClass, className)}
25
26
  class:elevated
26
27
  {...rest}
27
28
  >
@@ -1,6 +1,7 @@
1
1
  <script>
2
2
  import "./carousel-styles.css";
3
3
  import { defaults } from "../config.js";
4
+ import { cn } from "../utils/cn.js";
4
5
 
5
6
  let {
6
7
  style: styleProp,
@@ -10,6 +11,7 @@
10
11
  interval = 4000,
11
12
  showArrows = true,
12
13
  showIndicators = true,
14
+ class: className = "",
13
15
  ...rest
14
16
  } = $props();
15
17
 
@@ -48,7 +50,7 @@
48
50
  </script>
49
51
 
50
52
  <div
51
- class="s-carousel {styleClass} {themeClass}"
53
+ class={cn("s-carousel", styleClass, themeClass, className)}
52
54
  onmouseenter={() => { isHovering = true; }}
53
55
  onmouseleave={() => { isHovering = false; }}
54
56
  role="region"
@@ -11,6 +11,7 @@ declare const Carousel: import("svelte").Component<{
11
11
  interval?: number;
12
12
  showArrows?: boolean;
13
13
  showIndicators?: boolean;
14
+ class?: string;
14
15
  } & Record<string, any>, {}, "">;
15
16
  type $$ComponentProps = {
16
17
  style: any;
@@ -20,4 +21,5 @@ type $$ComponentProps = {
20
21
  interval?: number;
21
22
  showArrows?: boolean;
22
23
  showIndicators?: boolean;
24
+ class?: string;
23
25
  } & Record<string, any>;
@@ -1,6 +1,7 @@
1
1
  <script>
2
2
  import "./checkbox-styles.css";
3
3
  import { defaults } from "../config.js";
4
+ import { cn } from "../utils/cn.js";
4
5
 
5
6
  let {
6
7
  style: styleProp,
@@ -9,6 +10,7 @@
9
10
  label = "",
10
11
  disabled = false,
11
12
  indeterminate = false,
13
+ class: className = "",
12
14
  ...rest
13
15
  } = $props();
14
16
 
@@ -22,7 +24,7 @@
22
24
  </script>
23
25
 
24
26
  <label
25
- class="s-checkbox {styleClass} {themeClass}"
27
+ class={cn("s-checkbox", styleClass, themeClass, className)}
26
28
  class:disabled
27
29
  class:checked
28
30
  class:indeterminate
@@ -10,6 +10,7 @@ declare const Checkbox: import("svelte").Component<{
10
10
  label?: string;
11
11
  disabled?: boolean;
12
12
  indeterminate?: boolean;
13
+ class?: string;
13
14
  } & Record<string, any>, {}, "checked">;
14
15
  type $$ComponentProps = {
15
16
  style: any;
@@ -18,4 +19,5 @@ type $$ComponentProps = {
18
19
  label?: string;
19
20
  disabled?: boolean;
20
21
  indeterminate?: boolean;
22
+ class?: string;
21
23
  } & Record<string, any>;
@@ -1,6 +1,7 @@
1
1
  <script>
2
2
  import "./chip-styles.css";
3
3
  import { defaults } from "../config.js";
4
+ import { cn } from "../utils/cn.js";
4
5
 
5
6
  let {
6
7
  style: styleProp,
@@ -12,6 +13,7 @@
12
13
  dismissible = false,
13
14
  icon = "",
14
15
  ondismiss,
16
+ class: className = "",
15
17
  ...rest
16
18
  } = $props();
17
19
 
@@ -25,7 +27,7 @@
25
27
 
26
28
  {#if visible}
27
29
  <span
28
- class="s-chip {styleClass} {themeClass} chip-{variant} chip-{color} chip-{size}"
30
+ class={cn("s-chip", styleClass, themeClass, `chip-${variant}`, `chip-${color}`, `chip-${size}`, className)}
29
31
  {...rest}
30
32
  >
31
33
  {#if icon}
@@ -13,6 +13,7 @@ declare const Chip: import("svelte").Component<{
13
13
  dismissible?: boolean;
14
14
  icon?: string;
15
15
  ondismiss: any;
16
+ class?: string;
16
17
  } & Record<string, any>, {}, "">;
17
18
  type $$ComponentProps = {
18
19
  style: any;
@@ -24,4 +25,5 @@ type $$ComponentProps = {
24
25
  dismissible?: boolean;
25
26
  icon?: string;
26
27
  ondismiss: any;
28
+ class?: string;
27
29
  } & Record<string, any>;
@@ -1,5 +1,6 @@
1
1
  <script>
2
2
  import "./column-styles.css";
3
+ import { cn } from "../utils/cn.js";
3
4
 
4
5
  let {
5
6
  gap = "8px",
@@ -33,6 +34,6 @@
33
34
  );
34
35
  </script>
35
36
 
36
- <div class="s-column {className}" style={styleStr} {...rest}>
37
+ <div class={cn("s-column", className)} style={styleStr} {...rest}>
37
38
  {@render children?.()}
38
39
  </div>
@@ -3,6 +3,7 @@
3
3
  import { defaults } from "../config.js";
4
4
  import { fade } from "svelte/transition";
5
5
  import { portal } from "../actions/portal.js";
6
+ import { cn } from "../utils/cn.js";
6
7
 
7
8
  let {
8
9
  style: styleProp,
@@ -10,6 +11,7 @@
10
11
  open = $bindable(false),
11
12
  groups = [],
12
13
  placeholder = "Type a command...",
14
+ class: className = "",
13
15
  ...rest
14
16
  } = $props();
15
17
 
@@ -150,7 +152,7 @@
150
152
  {#if open}
151
153
  <div
152
154
  use:portal
153
- class="s-cmdk-overlay"
155
+ class={cn("s-cmdk-overlay", className)}
154
156
  transition:fade={{ duration: 150 }}
155
157
  onclick={(e) => { if (e.target === e.currentTarget) handleClose(); }}
156
158
  role="dialog"
@@ -9,6 +9,7 @@ declare const CommandPalette: import("svelte").Component<{
9
9
  open?: boolean;
10
10
  groups?: any[];
11
11
  placeholder?: string;
12
+ class?: string;
12
13
  } & Record<string, any>, {}, "open">;
13
14
  type $$ComponentProps = {
14
15
  style: any;
@@ -16,4 +17,5 @@ type $$ComponentProps = {
16
17
  open?: boolean;
17
18
  groups?: any[];
18
19
  placeholder?: string;
20
+ class?: string;
19
21
  } & Record<string, any>;
@@ -2,6 +2,7 @@
2
2
  import "./datepicker-styles.css";
3
3
  import { defaults, iconClass } from "../config.js";
4
4
  import { portal } from "../actions/portal.js";
5
+ import { cn } from "../utils/cn.js";
5
6
  import dayjs from "dayjs";
6
7
  import customParseFormat from "dayjs/plugin/customParseFormat";
7
8
  dayjs.extend(customParseFormat);
@@ -18,6 +19,7 @@
18
19
  min = undefined,
19
20
  max = undefined,
20
21
  locale = "en-US",
22
+ class: className = "",
21
23
  ...rest
22
24
  } = $props();
23
25
 
@@ -286,7 +288,7 @@
286
288
  </script>
287
289
 
288
290
  <div
289
- class="s-datepicker-wrapper {styleClass} {themeClass}"
291
+ class={cn("s-datepicker-wrapper", styleClass, themeClass, className)}
290
292
  class:s-datepicker-open={open}
291
293
  class:focused={open}
292
294
  class:floated
@@ -15,6 +15,7 @@ declare const DatePicker: import("svelte").Component<{
15
15
  min?: any;
16
16
  max?: any;
17
17
  locale?: string;
18
+ class?: string;
18
19
  } & Record<string, any>, {}, "value">;
19
20
  type $$ComponentProps = {
20
21
  style: any;
@@ -28,4 +29,5 @@ type $$ComponentProps = {
28
29
  min?: any;
29
30
  max?: any;
30
31
  locale?: string;
32
+ class?: string;
31
33
  } & Record<string, any>;
@@ -1,12 +1,14 @@
1
1
  <script>
2
2
  import "./divider-styles.css";
3
3
  import { defaults } from "../config.js";
4
+ import { cn } from "../utils/cn.js";
4
5
 
5
6
  let {
6
7
  style: styleProp,
7
8
  theme: themeProp,
8
9
  orientation = "horizontal",
9
10
  label = "",
11
+ class: className = "",
10
12
  ...rest
11
13
  } = $props();
12
14
 
@@ -18,7 +20,7 @@
18
20
  </script>
19
21
 
20
22
  <div
21
- class="s-divider {styleClass} {themeClass}"
23
+ class={cn("s-divider", styleClass, themeClass, className)}
22
24
  class:vertical={orientation === "vertical"}
23
25
  role="separator"
24
26
  aria-orientation={orientation}
@@ -8,10 +8,12 @@ declare const Divider: import("svelte").Component<{
8
8
  theme: any;
9
9
  orientation?: string;
10
10
  label?: string;
11
+ class?: string;
11
12
  } & Record<string, any>, {}, "">;
12
13
  type $$ComponentProps = {
13
14
  style: any;
14
15
  theme: any;
15
16
  orientation?: string;
16
17
  label?: string;
18
+ class?: string;
17
19
  } & Record<string, any>;
@@ -3,6 +3,7 @@
3
3
  import { defaults } from "../config.js";
4
4
  import { fade } from "svelte/transition";
5
5
  import { portal } from "../actions/portal.js";
6
+ import { cn } from "../utils/cn.js";
6
7
 
7
8
  let {
8
9
  style: styleProp,
@@ -11,6 +12,7 @@
11
12
  open = $bindable(false),
12
13
  children,
13
14
  onclose,
15
+ class: className = "",
14
16
  ...rest
15
17
  } = $props();
16
18
 
@@ -51,7 +53,7 @@
51
53
  {#if open}
52
54
  <div
53
55
  use:portal
54
- class="s-drawer-overlay"
56
+ class={cn("s-drawer-overlay", className)}
55
57
  transition:fade={{ duration: 200 }}
56
58
  onclick={handleBackdrop}
57
59
  role="presentation"
@@ -10,6 +10,7 @@ declare const Drawer: import("svelte").Component<{
10
10
  open?: boolean;
11
11
  children: any;
12
12
  onclose: any;
13
+ class?: string;
13
14
  } & Record<string, any>, {}, "open">;
14
15
  type $$ComponentProps = {
15
16
  style: any;
@@ -18,4 +19,5 @@ type $$ComponentProps = {
18
19
  open?: boolean;
19
20
  children: any;
20
21
  onclose: any;
22
+ class?: string;
21
23
  } & Record<string, any>;
@@ -2,6 +2,7 @@
2
2
  import "./dropdown-styles.css";
3
3
  import { defaults } from "../config.js";
4
4
  import { fly } from "svelte/transition";
5
+ import { cn } from "../utils/cn.js";
5
6
 
6
7
  let {
7
8
  style: styleProp,
@@ -12,6 +13,7 @@
12
13
  items = [],
13
14
  position = "bottom",
14
15
  align = "left",
16
+ class: className = "",
15
17
  ...rest
16
18
  } = $props();
17
19
 
@@ -60,7 +62,7 @@
60
62
  </script>
61
63
 
62
64
  <div
63
- class="s-dropdown {styleClass} {themeClass} dropdown-{align}"
65
+ class={cn("s-dropdown", styleClass, themeClass, `dropdown-${align}`, className)}
64
66
  class:open
65
67
  {...rest}
66
68
  >
@@ -12,6 +12,7 @@ declare const DropdownMenu: import("svelte").Component<{
12
12
  items?: any[];
13
13
  position?: string;
14
14
  align?: string;
15
+ class?: string;
15
16
  } & Record<string, any>, {}, "">;
16
17
  type $$ComponentProps = {
17
18
  style: any;
@@ -22,4 +23,5 @@ type $$ComponentProps = {
22
23
  items?: any[];
23
24
  position?: string;
24
25
  align?: string;
26
+ class?: string;
25
27
  } & Record<string, any>;
@@ -1,6 +1,7 @@
1
1
  <script>
2
2
  import "./fab-styles.css";
3
3
  import { defaults } from "../config.js";
4
+ import { cn } from "../utils/cn.js";
4
5
 
5
6
  let {
6
7
  style: styleProp,
@@ -9,6 +10,7 @@
9
10
  children,
10
11
  position = "bottom-right",
11
12
  onclick,
13
+ class: className = "",
12
14
  ...rest
13
15
  } = $props();
14
16
 
@@ -21,7 +23,7 @@
21
23
  </script>
22
24
 
23
25
  <button
24
- class="s-fab {styleClass} {themeClass} {presetClass} fab-{position}"
26
+ class={cn("s-fab", styleClass, themeClass, presetClass, `fab-${position}`, className)}
25
27
  {onclick}
26
28
  {...rest}
27
29
  >
@@ -10,6 +10,7 @@ declare const FAB: import("svelte").Component<{
10
10
  children: any;
11
11
  position?: string;
12
12
  onclick: any;
13
+ class?: string;
13
14
  } & Record<string, any>, {}, "">;
14
15
  type $$ComponentProps = {
15
16
  style: any;
@@ -18,4 +19,5 @@ type $$ComponentProps = {
18
19
  children: any;
19
20
  position?: string;
20
21
  onclick: any;
22
+ class?: string;
21
23
  } & Record<string, any>;
@@ -1,6 +1,7 @@
1
1
  <script>
2
2
  import "./fileupload-styles.css";
3
3
  import { defaults } from "../config.js";
4
+ import { cn } from "../utils/cn.js";
4
5
 
5
6
  let {
6
7
  style: styleProp,
@@ -9,6 +10,7 @@
9
10
  multiple = false,
10
11
  disabled = false,
11
12
  label = "Drop files or click to upload",
13
+ class: className = "",
12
14
  ...rest
13
15
  } = $props();
14
16
 
@@ -33,7 +35,7 @@
33
35
  </script>
34
36
 
35
37
  <div
36
- class="s-fileupload {styleClass} {themeClass}"
38
+ class={cn("s-fileupload", styleClass, themeClass, className)}
37
39
  class:dragging
38
40
  class:disabled
39
41
  ondragover={(e) => {
@@ -10,6 +10,7 @@ declare const FileUpload: import("svelte").Component<{
10
10
  multiple?: boolean;
11
11
  disabled?: boolean;
12
12
  label?: string;
13
+ class?: string;
13
14
  } & Record<string, any>, {}, "">;
14
15
  type $$ComponentProps = {
15
16
  style: any;
@@ -18,4 +19,5 @@ type $$ComponentProps = {
18
19
  multiple?: boolean;
19
20
  disabled?: boolean;
20
21
  label?: string;
22
+ class?: string;
21
23
  } & Record<string, any>;
@@ -1,5 +1,6 @@
1
1
  <script>
2
2
  import "./grid-styles.css";
3
+ import { cn } from "../utils/cn.js";
3
4
 
4
5
  let {
5
6
  columns = 1,
@@ -46,6 +47,6 @@
46
47
  );
47
48
  </script>
48
49
 
49
- <div class="s-grid {className}" style={styleStr} {...rest}>
50
+ <div class={cn("s-grid", className)} style={styleStr} {...rest}>
50
51
  {@render children?.()}
51
52
  </div>
@@ -1,6 +1,7 @@
1
1
  <script>
2
2
  import "./iconbutton-styles.css";
3
3
  import { defaults, iconClass } from "../config.js";
4
+ import { cn } from "../utils/cn.js";
4
5
 
5
6
  let {
6
7
  style: styleProp,
@@ -13,6 +14,7 @@
13
14
  children,
14
15
  onclick,
15
16
  ariaLabel = "",
17
+ class: className = "",
16
18
  ...rest
17
19
  } = $props();
18
20
 
@@ -27,7 +29,7 @@
27
29
  </script>
28
30
 
29
31
  <button
30
- class="s-iconbtn {styleClass} {themeClass} {variantClass} {presetClass} {sizeClass}"
32
+ class={cn("s-iconbtn", styleClass, themeClass, variantClass, presetClass, sizeClass, className)}
31
33
  {disabled}
32
34
  {onclick}
33
35
  aria-label={ariaLabel}
@@ -14,6 +14,7 @@ declare const IconButton: import("svelte").Component<{
14
14
  children: any;
15
15
  onclick: any;
16
16
  ariaLabel?: string;
17
+ class?: string;
17
18
  } & Record<string, any>, {}, "">;
18
19
  type $$ComponentProps = {
19
20
  style: any;
@@ -26,4 +27,5 @@ type $$ComponentProps = {
26
27
  children: any;
27
28
  onclick: any;
28
29
  ariaLabel?: string;
30
+ class?: string;
29
31
  } & Record<string, any>;
@@ -1,6 +1,7 @@
1
1
  <script>
2
2
  import "./input-styles.css";
3
3
  import { defaults, iconClass } from "../config.js";
4
+ import { cn } from "../utils/cn.js";
4
5
 
5
6
  let {
6
7
  style: styleProp,
@@ -33,6 +34,7 @@
33
34
  form = undefined,
34
35
  inputmode = undefined,
35
36
  spellcheck = undefined,
37
+ class: className = "",
36
38
  ...rest
37
39
  } = $props();
38
40
 
@@ -67,7 +69,7 @@
67
69
  </script>
68
70
 
69
71
  <div
70
- class="s-input-wrapper {styleClass} {themeClass}"
72
+ class={cn("s-input-wrapper", styleClass, themeClass, className)}
71
73
  class:disabled
72
74
  class:focused
73
75
  class:has-value={hasValue}
@@ -34,6 +34,7 @@ declare const Input: import("svelte").Component<{
34
34
  form?: any;
35
35
  inputmode?: any;
36
36
  spellcheck?: any;
37
+ class?: string;
37
38
  } & Record<string, any>, {}, "value">;
38
39
  type $$ComponentProps = {
39
40
  style: any;
@@ -66,4 +67,5 @@ type $$ComponentProps = {
66
67
  form?: any;
67
68
  inputmode?: any;
68
69
  spellcheck?: any;
70
+ class?: string;
69
71
  } & Record<string, any>;
@@ -3,6 +3,7 @@
3
3
  import { defaults } from "../config.js";
4
4
  import { fade, scale } from "svelte/transition";
5
5
  import { portal } from "../actions/portal.js";
6
+ import { cn } from "../utils/cn.js";
6
7
 
7
8
  let {
8
9
  style: styleProp,
@@ -12,6 +13,7 @@
12
13
  size = "medium",
13
14
  children,
14
15
  onclose,
16
+ class: className = "",
15
17
  ...rest
16
18
  } = $props();
17
19
 
@@ -35,7 +37,7 @@
35
37
  {#if open}
36
38
  <div
37
39
  use:portal
38
- class="s-modal-overlay {styleClass} {themeClass}"
40
+ class={cn("s-modal-overlay", styleClass, themeClass, className)}
39
41
  transition:fade={{ duration: 200 }}
40
42
  onclick={handleBackdrop}
41
43
  role="dialog"
@@ -11,6 +11,7 @@ declare const Modal: import("svelte").Component<{
11
11
  size?: string;
12
12
  children: any;
13
13
  onclose: any;
14
+ class?: string;
14
15
  } & Record<string, any>, {}, "open">;
15
16
  type $$ComponentProps = {
16
17
  style: any;
@@ -20,4 +21,5 @@ type $$ComponentProps = {
20
21
  size?: string;
21
22
  children: any;
22
23
  onclose: any;
24
+ class?: string;
23
25
  } & Record<string, any>;
@@ -1,6 +1,7 @@
1
1
  <script>
2
2
  import "./multiselect-styles.css";
3
3
  import { defaults } from "../config.js";
4
+ import { cn } from "../utils/cn.js";
4
5
 
5
6
  let {
6
7
  style: styleProp,
@@ -10,6 +11,7 @@
10
11
  placeholder = "Select...",
11
12
  label = "",
12
13
  disabled = false,
14
+ class: className = "",
13
15
  ...rest
14
16
  } = $props();
15
17
 
@@ -62,7 +64,7 @@
62
64
  </script>
63
65
 
64
66
  <div
65
- class="s-mselect-wrapper {styleClass} {themeClass}"
67
+ class={cn("s-mselect-wrapper", styleClass, themeClass, className)}
66
68
  class:disabled
67
69
  class:focused
68
70
  class:open
@@ -11,6 +11,7 @@ declare const MultiSelect: import("svelte").Component<{
11
11
  placeholder?: string;
12
12
  label?: string;
13
13
  disabled?: boolean;
14
+ class?: string;
14
15
  } & Record<string, any>, {}, "selected">;
15
16
  type $$ComponentProps = {
16
17
  style: any;
@@ -20,4 +21,5 @@ type $$ComponentProps = {
20
21
  placeholder?: string;
21
22
  label?: string;
22
23
  disabled?: boolean;
24
+ class?: string;
23
25
  } & Record<string, any>;
@@ -1,6 +1,7 @@
1
1
  <script>
2
2
  import "./pagination-styles.css";
3
3
  import { defaults } from "../config.js";
4
+ import { cn } from "../utils/cn.js";
4
5
 
5
6
  let {
6
7
  style: styleProp,
@@ -8,6 +9,7 @@
8
9
  total = 0,
9
10
  perPage = 10,
10
11
  current = $bindable(1),
12
+ class: className = "",
11
13
  ...rest
12
14
  } = $props();
13
15
 
@@ -26,7 +28,7 @@
26
28
  </script>
27
29
 
28
30
  <nav
29
- class="s-pagination {styleClass} {themeClass}"
31
+ class={cn("s-pagination", styleClass, themeClass, className)}
30
32
  aria-label="Pagination"
31
33
  {...rest}
32
34
  >
@@ -9,6 +9,7 @@ declare const Pagination: import("svelte").Component<{
9
9
  total?: number;
10
10
  perPage?: number;
11
11
  current?: number;
12
+ class?: string;
12
13
  } & Record<string, any>, {}, "current">;
13
14
  type $$ComponentProps = {
14
15
  style: any;
@@ -16,4 +17,5 @@ type $$ComponentProps = {
16
17
  total?: number;
17
18
  perPage?: number;
18
19
  current?: number;
20
+ class?: string;
19
21
  } & Record<string, any>;