@nextui-org/theme 0.0.0-dev-v2-20230421004240 → 0.0.0-dev-v2-20230423211529

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 (43) hide show
  1. package/dist/chunk-3B4SYPW2.mjs +18 -0
  2. package/dist/{chunk-5GRQZPPR.mjs → chunk-BLEVU2FW.mjs} +1 -1
  3. package/dist/{chunk-7WADY6QI.mjs → chunk-FDBBFTXB.mjs} +4 -4
  4. package/dist/{chunk-U45XCA4S.mjs → chunk-FJNSTLAL.mjs} +1 -1
  5. package/dist/{chunk-2QIDY5NZ.mjs → chunk-MW7UVOSP.mjs} +2 -2
  6. package/dist/{chunk-YYN3SHJ5.mjs → chunk-NQJBJXX3.mjs} +3 -3
  7. package/dist/{chunk-W2RCO7SN.mjs → chunk-R47OQZR5.mjs} +1 -0
  8. package/dist/chunk-TILCNEZM.mjs +212 -0
  9. package/dist/{chunk-CJ7TG72B.mjs → chunk-TYA6TT57.mjs} +1 -1
  10. package/dist/{chunk-CO6ANWRA.mjs → chunk-XUL76UJD.mjs} +1 -1
  11. package/dist/colors/index.js +1 -1
  12. package/dist/colors/index.mjs +2 -2
  13. package/dist/colors/semantic.js +1 -1
  14. package/dist/colors/semantic.mjs +1 -1
  15. package/dist/colors.js +1 -1
  16. package/dist/colors.mjs +2 -2
  17. package/dist/components/button.js +1 -0
  18. package/dist/components/button.mjs +1 -1
  19. package/dist/components/chip.js +3 -3
  20. package/dist/components/chip.mjs +1 -1
  21. package/dist/components/index.d.ts +2 -0
  22. package/dist/components/index.js +236 -7
  23. package/dist/components/index.mjs +27 -19
  24. package/dist/components/modal.d.ts +1 -1
  25. package/dist/components/pagination.js +1 -1
  26. package/dist/components/pagination.mjs +1 -1
  27. package/dist/components/spacer.d.ts +27 -0
  28. package/dist/components/spacer.js +42 -0
  29. package/dist/components/spacer.mjs +6 -0
  30. package/dist/components/spinner.js +1 -1
  31. package/dist/components/spinner.mjs +1 -1
  32. package/dist/components/table.d.ts +277 -0
  33. package/dist/components/table.js +236 -0
  34. package/dist/components/table.mjs +6 -0
  35. package/dist/components/user.js +2 -2
  36. package/dist/components/user.mjs +1 -1
  37. package/dist/index.d.ts +5 -2
  38. package/dist/index.js +241 -12
  39. package/dist/index.mjs +31 -23
  40. package/dist/plugin.js +1 -1
  41. package/dist/plugin.mjs +4 -4
  42. package/package.json +2 -2
  43. /package/dist/{chunk-NP4SOC4S.mjs → chunk-RH7YHIQY.mjs} +0 -0
@@ -0,0 +1,18 @@
1
+ // src/components/spacer.ts
2
+ import { tv } from "tailwind-variants";
3
+ var spacer = tv({
4
+ base: "w-px h-px inline-block",
5
+ variants: {
6
+ isInline: {
7
+ true: "inline-block",
8
+ false: "block"
9
+ }
10
+ },
11
+ defaultVariants: {
12
+ isInline: false
13
+ }
14
+ });
15
+
16
+ export {
17
+ spacer
18
+ };
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  semanticColors
3
- } from "./chunk-U45XCA4S.mjs";
3
+ } from "./chunk-FJNSTLAL.mjs";
4
4
  import {
5
5
  commonColors
6
6
  } from "./chunk-CRCBVLUP.mjs";
@@ -1,12 +1,12 @@
1
- import {
2
- utilities
3
- } from "./chunk-XLATS5QU.mjs";
4
1
  import {
5
2
  baseStyles
6
3
  } from "./chunk-INZK6TTL.mjs";
4
+ import {
5
+ utilities
6
+ } from "./chunk-XLATS5QU.mjs";
7
7
  import {
8
8
  semanticColors
9
- } from "./chunk-U45XCA4S.mjs";
9
+ } from "./chunk-FJNSTLAL.mjs";
10
10
  import {
11
11
  removeDefaultKeys
12
12
  } from "./chunk-37PIXVP4.mjs";
@@ -38,7 +38,7 @@ var base = {
38
38
  },
39
39
  dark: {
40
40
  background: {
41
- DEFAULT: "#0B0B0C"
41
+ DEFAULT: "#000000"
42
42
  },
43
43
  foreground: {
44
44
  DEFAULT: "#ECEDEE"
@@ -12,8 +12,8 @@ var user = tv({
12
12
  "data-[focus-visible=true]:dark:ring-offset-background-dark"
13
13
  ],
14
14
  wrapper: "inline-flex flex-col items-start",
15
- name: "text-sm text-foreground dark:text-foreground-dark",
16
- description: "text-xs text-neutral-500"
15
+ name: "text-sm text-inherit",
16
+ description: "text-xs text-neutral-400"
17
17
  }
18
18
  });
19
19
 
@@ -29,10 +29,10 @@ var chip = tv({
29
29
  variant: {
30
30
  solid: {},
31
31
  bordered: {
32
- base: "border-1.5 !bg-transparent"
32
+ base: "border-1.5 bg-transparent"
33
33
  },
34
34
  light: {
35
- base: "!bg-transparent"
35
+ base: "bg-transparent"
36
36
  },
37
37
  flat: {},
38
38
  faded: {
@@ -40,7 +40,7 @@ var chip = tv({
40
40
  },
41
41
  shadow: {},
42
42
  dot: {
43
- base: "border-1.5 border-neutral text-foreground !bg-transparent"
43
+ base: "border-1.5 border-neutral text-foreground bg-transparent"
44
44
  }
45
45
  },
46
46
  color: {
@@ -11,6 +11,7 @@ var button = tv({
11
11
  "inline-flex",
12
12
  "items-center",
13
13
  "justify-center",
14
+ "max-w-fit",
14
15
  "box-border",
15
16
  "appearance-none",
16
17
  "outline-none",
@@ -0,0 +1,212 @@
1
+ // src/components/table.ts
2
+ import { tv } from "tailwind-variants";
3
+ var focusRing = [
4
+ "data-[focus-visible=true]:outline-none",
5
+ "data-[focus-visible=true]:ring-2",
6
+ "data-[focus-visible=true]:ring-primary",
7
+ "data-[focus-visible=true]:ring-offset-2",
8
+ "data-[focus-visible=true]:ring-offset-background",
9
+ "data-[focus-visible=true]:dark:ring-offset-background-dark"
10
+ ];
11
+ var table = tv({
12
+ slots: {
13
+ base: [
14
+ "p-4",
15
+ "flex",
16
+ "flex-col",
17
+ "relative",
18
+ "justify-between",
19
+ "gap-4",
20
+ "border",
21
+ "border-neutral-100",
22
+ "overflow-auto"
23
+ ],
24
+ table: "min-w-full h-auto",
25
+ thead: "[&>tr]:first:rounded-lg",
26
+ tbody: "",
27
+ tr: ["group", "outline-none", ...focusRing],
28
+ th: [
29
+ "group",
30
+ "px-3",
31
+ "h-10",
32
+ "text-left",
33
+ "align-middle",
34
+ "bg-neutral-100",
35
+ "text-neutral-500",
36
+ "text-xs",
37
+ "font-semibold",
38
+ "first:rounded-l-lg",
39
+ "last:rounded-r-lg",
40
+ "outline-none",
41
+ "data-[sortable=true]:transition-colors",
42
+ "data-[sortable=true]:cursor-pointer",
43
+ "data-[hover=true]:text-neutral-400",
44
+ ...focusRing
45
+ ],
46
+ td: [
47
+ "py-2",
48
+ "px-3",
49
+ "relative",
50
+ "align-middle",
51
+ "whitespace-normal",
52
+ "text-base",
53
+ "font-normal",
54
+ "outline-none",
55
+ ...focusRing,
56
+ "before:content-['']",
57
+ "before:absolute",
58
+ "before:-z-[1]",
59
+ "before:inset-0",
60
+ "before:opacity-0",
61
+ "data-[selected=true]:before:opacity-100",
62
+ "group-data-[disabled=true]:text-neutral-300"
63
+ ],
64
+ tfoot: "",
65
+ sortIcon: [
66
+ "ml-2",
67
+ "mb-px",
68
+ "opacity-0",
69
+ "text-inherit",
70
+ "inline-block",
71
+ "transition-transform-opacity",
72
+ "data-[visible=true]:opacity-100",
73
+ "group-data-[hover=true]:opacity-100",
74
+ "data-[direction=ascending]:rotate-180"
75
+ ],
76
+ emptyWrapper: "text-neutral-400 align-middle text-center h-40",
77
+ loadingWrapper: "absolute inset-0 flex items-center justify-center"
78
+ },
79
+ variants: {
80
+ color: {
81
+ neutral: {
82
+ td: "before:bg-neutral-200 dark:before:bg-neutral-100 data-[selected=true]:text-neutral-foreground"
83
+ },
84
+ primary: {
85
+ td: "before:bg-primary-50 data-[selected=true]:text-primary"
86
+ },
87
+ secondary: {
88
+ td: "before:bg-secondary-100 data-[selected=true]:text-secondary"
89
+ },
90
+ success: {
91
+ td: "before:bg-success-50 data-[selected=true]:text-success"
92
+ },
93
+ warning: {
94
+ td: "before:bg-warning-50 data-[selected=true]:text-warning"
95
+ },
96
+ danger: {
97
+ td: "before:bg-danger-50 data-[selected=true]:text-danger"
98
+ }
99
+ },
100
+ layout: {
101
+ auto: {
102
+ table: "table-auto"
103
+ },
104
+ fixed: {
105
+ table: "table-fixed"
106
+ }
107
+ },
108
+ radius: {
109
+ none: {
110
+ base: "rounded-none"
111
+ },
112
+ base: {
113
+ base: "rounded"
114
+ },
115
+ sm: {
116
+ base: "rounded-sm"
117
+ },
118
+ md: {
119
+ base: "rounded-md"
120
+ },
121
+ lg: {
122
+ base: "rounded-lg"
123
+ },
124
+ xl: {
125
+ base: "rounded-xl"
126
+ },
127
+ "2xl": {
128
+ base: "rounded-2xl"
129
+ }
130
+ },
131
+ shadow: {
132
+ none: {
133
+ base: "shadow-none"
134
+ },
135
+ sm: {
136
+ base: "shadow-sm"
137
+ },
138
+ md: {
139
+ base: "shadow-md"
140
+ },
141
+ lg: {
142
+ base: "shadow-lg"
143
+ },
144
+ xl: {
145
+ base: "shadow-xl"
146
+ },
147
+ "2xl": {
148
+ base: "shadow-2xl"
149
+ },
150
+ inner: {
151
+ base: "shadow-inner"
152
+ }
153
+ },
154
+ hideHeader: {
155
+ true: {
156
+ thead: "hidden"
157
+ }
158
+ },
159
+ isStriped: {
160
+ true: {
161
+ td: [
162
+ "group-data-[odd=true]:before:bg-neutral-100",
163
+ "group-data-[odd=true]:before:opacity-100"
164
+ ]
165
+ }
166
+ },
167
+ isHeaderSticky: {
168
+ true: {
169
+ thead: "sticky top-0 z-10 [&>tr]:first:shadow"
170
+ }
171
+ },
172
+ isSelectable: {
173
+ true: {
174
+ tr: "cursor-default",
175
+ td: ["group-data-[hover=true]:before:opacity-70"]
176
+ }
177
+ },
178
+ isMultiSelectable: {
179
+ true: {
180
+ td: [
181
+ "group-data-[first=true]:first:before:rounded-tl-lg",
182
+ "group-data-[first=true]:last:before:rounded-tr-lg",
183
+ "group-data-[middle=true]:before:rounded-none",
184
+ "group-data-[last=true]:first:before:rounded-bl-lg",
185
+ "group-data-[last=true]:last:before:rounded-br-lg"
186
+ ]
187
+ },
188
+ false: {
189
+ td: ["first:before:rounded-l-lg", "last:before:rounded-r-lg"]
190
+ }
191
+ },
192
+ fullWidth: {
193
+ true: {
194
+ base: "w-full",
195
+ table: "w-full"
196
+ }
197
+ }
198
+ },
199
+ defaultVariants: {
200
+ layout: "auto",
201
+ shadow: "lg",
202
+ radius: "xl",
203
+ color: "neutral",
204
+ hideHeader: false,
205
+ isStriped: false,
206
+ fullWidth: true
207
+ }
208
+ });
209
+
210
+ export {
211
+ table
212
+ };
@@ -304,7 +304,7 @@ var pagination = tv({
304
304
  "data-[focus-visible=true]:ring-offset-2",
305
305
  "data-[focus-visible=true]:ring-offset-background",
306
306
  "data-[focus-visible=true]:dark:ring-offset-background-dark",
307
- "data-[disabled=true]:opacity-50",
307
+ "data-[disabled=true]:text-neutral-300",
308
308
  "data-[disabled=true]:pointer-events-none"
309
309
  ]
310
310
  },
@@ -2,7 +2,7 @@
2
2
  import { tv } from "tailwind-variants";
3
3
  var spinner = tv({
4
4
  slots: {
5
- base: "flex flex-col items-center justify-center relative",
5
+ base: "inline-flex flex-col items-center justify-center relative",
6
6
  circle1: [
7
7
  "absolute",
8
8
  "w-full",
@@ -196,7 +196,7 @@ var base = {
196
196
  },
197
197
  dark: {
198
198
  background: {
199
- DEFAULT: "#0B0B0C"
199
+ DEFAULT: "#000000"
200
200
  },
201
201
  foreground: {
202
202
  DEFAULT: "#ECEDEE"
@@ -1,9 +1,9 @@
1
1
  import {
2
2
  colors
3
- } from "../chunk-5GRQZPPR.mjs";
3
+ } from "../chunk-BLEVU2FW.mjs";
4
4
  import {
5
5
  semanticColors
6
- } from "../chunk-U45XCA4S.mjs";
6
+ } from "../chunk-FJNSTLAL.mjs";
7
7
  import "../chunk-37PIXVP4.mjs";
8
8
  import "../chunk-M63AFAHO.mjs";
9
9
  import {
@@ -194,7 +194,7 @@ var base = {
194
194
  },
195
195
  dark: {
196
196
  background: {
197
- DEFAULT: "#0B0B0C"
197
+ DEFAULT: "#000000"
198
198
  },
199
199
  foreground: {
200
200
  DEFAULT: "#ECEDEE"
@@ -2,7 +2,7 @@ import {
2
2
  semanticColors,
3
3
  semanticColorsDark,
4
4
  semanticColorsLight
5
- } from "../chunk-U45XCA4S.mjs";
5
+ } from "../chunk-FJNSTLAL.mjs";
6
6
  import "../chunk-37PIXVP4.mjs";
7
7
  import "../chunk-CRCBVLUP.mjs";
8
8
  import "../chunk-DCEG5LGX.mjs";
package/dist/colors.js CHANGED
@@ -196,7 +196,7 @@ var base = {
196
196
  },
197
197
  dark: {
198
198
  background: {
199
- DEFAULT: "#0B0B0C"
199
+ DEFAULT: "#000000"
200
200
  },
201
201
  foreground: {
202
202
  DEFAULT: "#ECEDEE"
package/dist/colors.mjs CHANGED
@@ -1,10 +1,10 @@
1
1
  import "./chunk-WQEDQHKX.mjs";
2
2
  import {
3
3
  colors
4
- } from "./chunk-5GRQZPPR.mjs";
4
+ } from "./chunk-BLEVU2FW.mjs";
5
5
  import {
6
6
  semanticColors
7
- } from "./chunk-U45XCA4S.mjs";
7
+ } from "./chunk-FJNSTLAL.mjs";
8
8
  import "./chunk-37PIXVP4.mjs";
9
9
  import "./chunk-M63AFAHO.mjs";
10
10
  import {
@@ -107,6 +107,7 @@ var button = (0, import_tailwind_variants.tv)({
107
107
  "inline-flex",
108
108
  "items-center",
109
109
  "justify-center",
110
+ "max-w-fit",
110
111
  "box-border",
111
112
  "appearance-none",
112
113
  "outline-none",
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  button
3
- } from "../chunk-W2RCO7SN.mjs";
3
+ } from "../chunk-R47OQZR5.mjs";
4
4
  import "../chunk-CMYR6AOY.mjs";
5
5
  import "../chunk-K7LK7NCE.mjs";
6
6
  import "../chunk-RO3WUCFF.mjs";
@@ -132,10 +132,10 @@ var chip = (0, import_tailwind_variants.tv)({
132
132
  variant: {
133
133
  solid: {},
134
134
  bordered: {
135
- base: "border-1.5 !bg-transparent"
135
+ base: "border-1.5 bg-transparent"
136
136
  },
137
137
  light: {
138
- base: "!bg-transparent"
138
+ base: "bg-transparent"
139
139
  },
140
140
  flat: {},
141
141
  faded: {
@@ -143,7 +143,7 @@ var chip = (0, import_tailwind_variants.tv)({
143
143
  },
144
144
  shadow: {},
145
145
  dot: {
146
- base: "border-1.5 border-neutral text-foreground !bg-transparent"
146
+ base: "border-1.5 border-neutral text-foreground bg-transparent"
147
147
  }
148
148
  },
149
149
  color: {
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  chip
3
- } from "../chunk-YYN3SHJ5.mjs";
3
+ } from "../chunk-NQJBJXX3.mjs";
4
4
  import "../chunk-CMYR6AOY.mjs";
5
5
  import "../chunk-K7LK7NCE.mjs";
6
6
  import "../chunk-RO3WUCFF.mjs";
@@ -30,5 +30,7 @@ export { dropdownMenu } from './dropdown-menu.js';
30
30
  export { ImageSlots, ImageVariantProps, image } from './image.js';
31
31
  export { ModalSlots, ModalVariantProps, modal } from './modal.js';
32
32
  export { NavbarSlots, NavbarVariantProps, navbar } from './navbar.js';
33
+ export { TableReturnType, TableSlots, TableVariantProps, table } from './table.js';
34
+ export { SpacerVariantProps, spacer } from './spacer.js';
33
35
  import 'tailwind-variants';
34
36
  import 'tailwind-variants/dist/config';