singularity-components 0.1.138 → 0.1.139

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 (76) hide show
  1. package/dist/components/index.d.ts +7 -7
  2. package/dist/components/primitives/accordion/accordion.d.ts +5 -6
  3. package/dist/components/primitives/accordion/accordion.js +44 -18
  4. package/dist/components/primitives/accordion/accordion.js.map +1 -1
  5. package/dist/components/primitives/accordion/accordion.stories.d.ts +1 -2
  6. package/dist/components/primitives/accordion/accordion.stories.js +4 -5
  7. package/dist/components/primitives/accordion/accordion.stories.js.map +1 -1
  8. package/dist/components/primitives/alert/alert.d.ts +2 -1
  9. package/dist/components/primitives/alert/alert.js +16 -5
  10. package/dist/components/primitives/alert/alert.js.map +1 -1
  11. package/dist/components/primitives/alert/alert.stories.js +1 -1
  12. package/dist/components/primitives/alert/alert.stories.js.map +1 -1
  13. package/dist/components/primitives/badge/badge.d.ts +4 -6
  14. package/dist/components/primitives/badge/badge.js +25 -19
  15. package/dist/components/primitives/badge/badge.js.map +1 -1
  16. package/dist/components/primitives/badge/badges.js.map +1 -1
  17. package/dist/components/primitives/button/button.d.ts +8 -12
  18. package/dist/components/primitives/button/button.js +24 -66
  19. package/dist/components/primitives/button/button.js.map +1 -1
  20. package/dist/components/primitives/button/button.stories.d.ts +2 -5
  21. package/dist/components/primitives/button/button.stories.js +1 -14
  22. package/dist/components/primitives/button/button.stories.js.map +1 -1
  23. package/dist/components/primitives/button/button_with_icon_variant.d.ts +2 -0
  24. package/dist/components/primitives/button/button_with_icon_variant.js +1 -0
  25. package/dist/components/primitives/button/button_with_icon_variant.js.map +1 -0
  26. package/dist/components/primitives/icon/icon.d.ts +4 -4
  27. package/dist/components/primitives/icon/icon.js +4 -4
  28. package/dist/components/primitives/icon/icon.js.map +1 -1
  29. package/dist/components/primitives/icon/icon.stories.d.ts +3 -0
  30. package/dist/components/primitives/icon/icon.stories.js +3 -0
  31. package/dist/components/primitives/icon/icon.stories.js.map +1 -1
  32. package/dist/components/primitives/index.d.ts +7 -7
  33. package/dist/components/primitives/index.js +0 -2
  34. package/dist/components/primitives/index.js.map +1 -1
  35. package/dist/components/primitives/layout/layout.d.ts +7 -6
  36. package/dist/components/primitives/layout/layout.js +9 -7
  37. package/dist/components/primitives/layout/layout.js.map +1 -1
  38. package/dist/components/primitives/layout/layout.stories.js +1 -1
  39. package/dist/components/primitives/layout/layout.stories.js.map +1 -1
  40. package/dist/components/primitives/separator/separator.d.ts +2 -3
  41. package/dist/components/primitives/separator/separator.js +4 -7
  42. package/dist/components/primitives/separator/separator.js.map +1 -1
  43. package/dist/components/primitives/separator/separator.stories.d.ts +1 -2
  44. package/dist/components/primitives/separator/separator.stories.js +1 -1
  45. package/dist/components/primitives/separator/separator.stories.js.map +1 -1
  46. package/dist/components/primitives/spinner/spinner.d.ts +2 -7
  47. package/dist/components/primitives/spinner/spinner.js +8 -70
  48. package/dist/components/primitives/spinner/spinner.js.map +1 -1
  49. package/dist/components/primitives/spinner/spinner.stories.js +4 -5
  50. package/dist/components/primitives/spinner/spinner.stories.js.map +1 -1
  51. package/dist/components/primitives/stack/stack.js.map +1 -1
  52. package/dist/components/primitives/stack/stack.stories.d.ts +1 -1
  53. package/dist/components/primitives/text/internal/text-element.d.ts +12 -18
  54. package/dist/components/primitives/text/internal/text-element.js +6 -9
  55. package/dist/components/primitives/text/internal/text-element.js.map +1 -1
  56. package/dist/components/primitives/text/text-div.stories.js +2 -2
  57. package/dist/components/primitives/text/text-div.stories.js.map +1 -1
  58. package/dist/components/primitives/text/text-span.stories.js +2 -2
  59. package/dist/components/primitives/text/text-span.stories.js.map +1 -1
  60. package/dist/components/units/cards/blog-card.js +6 -7
  61. package/dist/components/units/cards/blog-card.js.map +1 -1
  62. package/dist/components/units/cards/card.js +2 -2
  63. package/dist/components/units/cards/card.js.map +1 -1
  64. package/dist/css/variables.css +78 -0
  65. package/dist/css/variables.css.map +1 -0
  66. package/dist/css/variables.d.ts +2 -0
  67. package/dist/index.d.ts +7 -7
  68. package/dist/main.css +584 -577
  69. package/dist/main.css.map +1 -1
  70. package/package.json +88 -186
  71. package/dist/components/primitives/input/input.d.ts +0 -6
  72. package/dist/components/primitives/input/input.js +0 -23
  73. package/dist/components/primitives/input/input.js.map +0 -1
  74. package/dist/components/primitives/table/table.d.ts +0 -13
  75. package/dist/components/primitives/table/table.js +0 -117
  76. package/dist/components/primitives/table/table.js.map +0 -1
package/package.json CHANGED
@@ -1,186 +1,88 @@
1
- {
2
- "name": "singularity-components",
3
- "version": "0.1.138",
4
- "type": "module",
5
- "files": [
6
- "dist"
7
- ],
8
- "main": "./dist/index.js",
9
- "module": "./dist/index.js",
10
- "exports": {
11
- ".": {
12
- "types": "./dist/index.d.ts",
13
- "import": "./dist/index.js"
14
- },
15
- "./package.json": "./package.json",
16
- "./*": {
17
- "types": "./dist/*.d.ts",
18
- "import": "./dist/*.js"
19
- },
20
- "./components/primitives/accordion/accordion": {
21
- "types": "./dist/components/primitives/accordion/accordion.d.ts",
22
- "import": "./dist/components/primitives/accordion/accordion.js"
23
- },
24
- "./components/primitives/alert/alert": {
25
- "types": "./dist/components/primitives/alert/alert.d.ts",
26
- "import": "./dist/components/primitives/alert/alert.js"
27
- },
28
- "./components/primitives/badge/badge": {
29
- "types": "./dist/components/primitives/badge/badge.d.ts",
30
- "import": "./dist/components/primitives/badge/badge.js"
31
- },
32
- "./components/primitives/badge/badges": {
33
- "types": "./dist/components/primitives/badge/badges.d.ts",
34
- "import": "./dist/components/primitives/badge/badges.js"
35
- },
36
- "./components/primitives/button/button": {
37
- "types": "./dist/components/primitives/button/button.d.ts",
38
- "import": "./dist/components/primitives/button/button.js"
39
- },
40
- "./components/primitives/icon/icon": {
41
- "types": "./dist/components/primitives/icon/icon.d.ts",
42
- "import": "./dist/components/primitives/icon/icon.js"
43
- },
44
- "./components/primitives/input/input": {
45
- "types": "./dist/components/primitives/input/input.d.ts",
46
- "import": "./dist/components/primitives/input/input.js"
47
- },
48
- "./components/primitives/layout/layout": {
49
- "types": "./dist/components/primitives/layout/layout.d.ts",
50
- "import": "./dist/components/primitives/layout/layout.js"
51
- },
52
- "./components/primitives/separator/separator": {
53
- "types": "./dist/components/primitives/separator/separator.d.ts",
54
- "import": "./dist/components/primitives/separator/separator.js"
55
- },
56
- "./components/primitives/skeleton/skeleton": {
57
- "types": "./dist/components/primitives/skeleton/skeleton.d.ts",
58
- "import": "./dist/components/primitives/skeleton/skeleton.js"
59
- },
60
- "./components/primitives/spinner/spinner": {
61
- "types": "./dist/components/primitives/spinner/spinner.d.ts",
62
- "import": "./dist/components/primitives/spinner/spinner.js"
63
- },
64
- "./components/primitives/stack/stack": {
65
- "types": "./dist/components/primitives/stack/stack.d.ts",
66
- "import": "./dist/components/primitives/stack/stack.js"
67
- },
68
- "./components/primitives/table/table": {
69
- "types": "./dist/components/primitives/table/table.d.ts",
70
- "import": "./dist/components/primitives/table/table.js"
71
- },
72
- "./components/primitives/text/text-div": {
73
- "types": "./dist/components/primitives/text/text-div.d.ts",
74
- "import": "./dist/components/primitives/text/text-div.js"
75
- },
76
- "./components/primitives/text/text-heading": {
77
- "types": "./dist/components/primitives/text/text-heading.d.ts",
78
- "import": "./dist/components/primitives/text/text-heading.js"
79
- },
80
- "./components/primitives/text/text-paragraph": {
81
- "types": "./dist/components/primitives/text/text-paragraph.d.ts",
82
- "import": "./dist/components/primitives/text/text-paragraph.js"
83
- },
84
- "./components/primitives/text/text-span": {
85
- "types": "./dist/components/primitives/text/text-span.d.ts",
86
- "import": "./dist/components/primitives/text/text-span.js"
87
- },
88
- "./components/primitives/text/text-time": {
89
- "types": "./dist/components/primitives/text/text-time.d.ts",
90
- "import": "./dist/components/primitives/text/text-time.js"
91
- },
92
- "./components/primitives/ui-image": {
93
- "types": "./dist/components/primitives/ui-image.d.ts",
94
- "import": "./dist/components/primitives/ui-image.js"
95
- },
96
- "./components/primitives/ui-link": {
97
- "types": "./dist/components/primitives/ui-link.d.ts",
98
- "import": "./dist/components/primitives/ui-link.js"
99
- },
100
- "./components/units/cards/blog-card": {
101
- "types": "./dist/components/units/cards/blog-card.d.ts",
102
- "import": "./dist/components/units/cards/blog-card.js"
103
- },
104
- "./components/units/cards/card": {
105
- "types": "./dist/components/units/cards/card.d.ts",
106
- "import": "./dist/components/units/cards/card.js"
107
- },
108
- "./components/units/cards/cards": {
109
- "types": "./dist/components/units/cards/cards.d.ts",
110
- "import": "./dist/components/units/cards/cards.js"
111
- },
112
- "./components/providers/ImageContext": {
113
- "types": "./dist/components/providers/ImageContext.d.ts",
114
- "import": "./dist/components/providers/ImageContext.js"
115
- },
116
- "./components/providers/LinkContext": {
117
- "types": "./dist/components/providers/LinkContext.d.ts",
118
- "import": "./dist/components/providers/LinkContext.js"
119
- },
120
- "./components/providers/SingularityContext": {
121
- "types": "./dist/components/providers/SingularityContext.d.ts",
122
- "import": "./dist/components/providers/SingularityContext.js"
123
- },
124
- "./utils": {
125
- "types": "./dist/utils.d.ts",
126
- "import": "./dist/utils.js"
127
- }
128
- },
129
- "scripts": {
130
- "build": "tsup",
131
- "storybook": "storybook dev -p 6006 --no-open",
132
- "storybook:build": "storybook build",
133
- "droplet-down": "docker-compose --context remote -f .\\docker-compose-droplet.yml down",
134
- "droplet-up": "powershell -ExecutionPolicy Bypass -File droplet-update-containers.ps1"
135
- },
136
- "keywords": [
137
- "test"
138
- ],
139
- "author": "Filip",
140
- "license": "MIT",
141
- "description": "",
142
- "dependencies": {
143
- "@radix-ui/react-accordion": "^1.2.12",
144
- "@radix-ui/react-separator": "^1.1.8",
145
- "@radix-ui/react-slot": "^1.2.4",
146
- "@tailwindcss/postcss": "^4.1.18",
147
- "class-variance-authority": "^0.7.1",
148
- "clsx": "^2.1.1",
149
- "lucide-react": "^0.562.0",
150
- "postcss": "^8.5.6",
151
- "react": "^19.2.3",
152
- "react-dom": "^19.2.3",
153
- "react-spinners": "^0.17.0",
154
- "tailwind-merge": "^3.4.0",
155
- "tailwindcss": "^4.1.18",
156
- "tailwindcss-animate": "^1.0.7"
157
- },
158
- "devDependencies": {
159
- "@chromatic-com/storybook": "^4.1.3",
160
- "@storybook/addon-docs": "^10.1.11",
161
- "@storybook/addon-links": "^10.1.11",
162
- "@storybook/addon-themes": "^10.1.11",
163
- "@storybook/react-vite": "^10.1.11",
164
- "@types/node": "^25.0.3",
165
- "@types/react": "^19.2.7",
166
- "@types/react-dom": "^19.2.3",
167
- "@typescript-eslint/eslint-plugin": "^8.52.0",
168
- "@typescript-eslint/parser": "^8.52.0",
169
- "@vitejs/plugin-react": "^5.1.2",
170
- "eslint": "^9.39.2",
171
- "eslint-plugin-react-hooks": "^7.0.1",
172
- "eslint-plugin-react-refresh": "^0.4.26",
173
- "eslint-plugin-storybook": "10.1.11",
174
- "storybook": "^10.1.11",
175
- "tsup": "^8.5.1",
176
- "typescript": "^5.9.3",
177
- "vite": "^7.3.1",
178
- "vite-plugin-dts": "^4.5.4",
179
- "vite-tsconfig-paths": "^6.0.3"
180
- },
181
- "peerDependencies": {
182
- "lucide-react": "^0.562.0",
183
- "react": "^19.2.3",
184
- "react-dom": "^19.2.3"
185
- }
186
- }
1
+ {
2
+ "name": "singularity-components",
3
+ "version": "0.1.139",
4
+ "type": "module",
5
+ "files": [
6
+ "dist"
7
+ ],
8
+ "main": "./dist/index.js",
9
+ "module": "./dist/index.js",
10
+ "exports": {
11
+ ".": {
12
+ "types": "./dist/index.d.ts",
13
+ "import": "./dist/index.js"
14
+ },
15
+ "./*": {
16
+ "types": "./dist/*.d.ts",
17
+ "import": "./dist/*.js"
18
+ },
19
+ "./components/*": {
20
+ "types": "./dist/components/*.d.ts",
21
+ "import": "./dist/components/*.js"
22
+ },
23
+ "./providers/*": {
24
+ "types": "./dist/components/providers/*.d.ts",
25
+ "import": "./dist/components/providers/*.js"
26
+ },
27
+ "./utils": {
28
+ "types": "./dist/utils.d.ts",
29
+ "import": "./dist/utils.js"
30
+ }
31
+ },
32
+ "scripts": {
33
+ "build": "tsup",
34
+ "storybook": "storybook dev -p 6006 --no-open",
35
+ "storybook:build": "storybook build",
36
+ "droplet-down": "docker-compose --context remote -f .\\docker-compose-droplet.yml down",
37
+ "droplet-up": "powershell -ExecutionPolicy Bypass -File droplet-update-containers.ps1"
38
+ },
39
+ "keywords": [
40
+ "test"
41
+ ],
42
+ "author": "Filip",
43
+ "license": "MIT",
44
+ "description": "",
45
+ "dependencies": {
46
+ "@base-ui/react": "^1.1.0",
47
+ "@radix-ui/react-slot": "^1.2.4",
48
+ "@tailwindcss/postcss": "^4.1.18",
49
+ "class-variance-authority": "^0.7.1",
50
+ "clsx": "^2.1.1",
51
+ "lucide-react": "^0.563.0",
52
+ "postcss": "^8.5.6",
53
+ "react": "^19.2.4",
54
+ "react-dom": "^19.2.4",
55
+ "react-spinners": "^0.17.0",
56
+ "tailwind-merge": "^3.4.0",
57
+ "tailwindcss": "^4.1.18",
58
+ "tailwindcss-animate": "^1.0.7"
59
+ },
60
+ "devDependencies": {
61
+ "@chromatic-com/storybook": "^5.0.0",
62
+ "@storybook/addon-docs": "^10.2.6",
63
+ "@storybook/addon-links": "^10.2.6",
64
+ "@storybook/addon-themes": "^10.2.6",
65
+ "@storybook/react-vite": "^10.2.6",
66
+ "@types/node": "^25.2.0",
67
+ "@types/react": "^19.2.11",
68
+ "@types/react-dom": "^19.2.3",
69
+ "@typescript-eslint/eslint-plugin": "^8.54.0",
70
+ "@typescript-eslint/parser": "^8.54.0",
71
+ "@vitejs/plugin-react": "^5.1.3",
72
+ "eslint": "^9.39.2",
73
+ "eslint-plugin-react-hooks": "^7.0.1",
74
+ "eslint-plugin-react-refresh": "^0.5.0",
75
+ "eslint-plugin-storybook": "10.2.6",
76
+ "storybook": "^10.2.6",
77
+ "tsup": "^8.5.1",
78
+ "typescript": "^5.9.3",
79
+ "vite": "^7.3.1",
80
+ "vite-plugin-dts": "^4.5.4",
81
+ "vite-tsconfig-paths": "^6.0.5"
82
+ },
83
+ "peerDependencies": {
84
+ "lucide-react": "^0.563.0",
85
+ "react": "^19.2.4",
86
+ "react-dom": "^19.2.4"
87
+ }
88
+ }
@@ -1,6 +0,0 @@
1
- import * as react_jsx_runtime from 'react/jsx-runtime';
2
- import * as React from 'react';
3
-
4
- declare function Input({ className, type, ...props }: React.ComponentProps<"input">): react_jsx_runtime.JSX.Element;
5
-
6
- export { Input };
@@ -1,23 +0,0 @@
1
- import { jsx } from "react/jsx-runtime";
2
- import * as React from "react";
3
- import { cn } from "../../../utils";
4
- function Input({ className, type, ...props }) {
5
- return /* @__PURE__ */ jsx(
6
- "input",
7
- {
8
- type,
9
- "data-slot": "input",
10
- className: cn(
11
- "sg:file:text-foreground sg:placeholder:text-muted-foreground sg:selection:bg-primary sg:selection:text-primary-foreground sg:dark:bg-input/30 sg:border-input sg:flex sg:h-9 sg:w-full sg:min-w-0 sg:rounded-md sg:border sg:bg-transparent sg:px-3 sg:py-1 sg:text-base sg:shadow-xs sg:transition-[color,box-shadow] sg:outline-none sg:file:inline-flex sg:file:h-7 sg:file:border-0 sg:file:bg-transparent sg:file:text-sm sg:file:font-medium sg:disabled:pointer-events-none sg:disabled:cursor-not-allowed sg:disabled:opacity-50 sg:md:text-sm",
12
- "sg:focus-visible:border-ring sg:focus-visible:ring-ring/50 sg:focus-visible:ring-[3px]",
13
- "sg:aria-invalid:ring-destructive/20 sg:dark:aria-invalid:ring-destructive/40 sg:aria-invalid:border-destructive",
14
- className
15
- ),
16
- ...props
17
- }
18
- );
19
- }
20
- export {
21
- Input
22
- };
23
- //# sourceMappingURL=input.js.map
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../../../../src/components/primitives/input/input.tsx"],"sourcesContent":["import * as React from \"react\";\nimport { cn } from \"../../../utils\";\n\nfunction Input({ className, type, ...props }: React.ComponentProps<\"input\">) {\n return (\n <input\n type={type}\n data-slot=\"input\"\n className={cn(\n \"sg:file:text-foreground sg:placeholder:text-muted-foreground sg:selection:bg-primary sg:selection:text-primary-foreground sg:dark:bg-input/30 sg:border-input sg:flex sg:h-9 sg:w-full sg:min-w-0 sg:rounded-md sg:border sg:bg-transparent sg:px-3 sg:py-1 sg:text-base sg:shadow-xs sg:transition-[color,box-shadow] sg:outline-none sg:file:inline-flex sg:file:h-7 sg:file:border-0 sg:file:bg-transparent sg:file:text-sm sg:file:font-medium sg:disabled:pointer-events-none sg:disabled:cursor-not-allowed sg:disabled:opacity-50 sg:md:text-sm\",\n \"sg:focus-visible:border-ring sg:focus-visible:ring-ring/50 sg:focus-visible:ring-[3px]\",\n \"sg:aria-invalid:ring-destructive/20 sg:dark:aria-invalid:ring-destructive/40 sg:aria-invalid:border-destructive\",\n className\n )}\n {...props}\n />\n );\n}\n\nexport { Input };\n"],"mappings":"AAKI;AALJ,YAAY,WAAW;AACvB,SAAS,UAAU;AAEnB,SAAS,MAAM,EAAE,WAAW,MAAM,GAAG,MAAM,GAAkC;AAC3E,SACE;AAAA,IAAC;AAAA;AAAA,MACC;AAAA,MACA,aAAU;AAAA,MACV,WAAW;AAAA,QACT;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,MACF;AAAA,MACC,GAAG;AAAA;AAAA,EACN;AAEJ;","names":[]}
@@ -1,13 +0,0 @@
1
- import * as react_jsx_runtime from 'react/jsx-runtime';
2
- import * as React from 'react';
3
-
4
- declare function Table({ className, ...props }: React.ComponentProps<"table">): react_jsx_runtime.JSX.Element;
5
- declare function TableHeader({ className, ...props }: React.ComponentProps<"thead">): react_jsx_runtime.JSX.Element;
6
- declare function TableBody({ className, ...props }: React.ComponentProps<"tbody">): react_jsx_runtime.JSX.Element;
7
- declare function TableFooter({ className, ...props }: React.ComponentProps<"tfoot">): react_jsx_runtime.JSX.Element;
8
- declare function TableRow({ className, ...props }: React.ComponentProps<"tr">): react_jsx_runtime.JSX.Element;
9
- declare function TableHead({ className, ...props }: React.ComponentProps<"th">): react_jsx_runtime.JSX.Element;
10
- declare function TableCell({ className, ...props }: React.ComponentProps<"td">): react_jsx_runtime.JSX.Element;
11
- declare function TableCaption({ className, ...props }: React.ComponentProps<"caption">): react_jsx_runtime.JSX.Element;
12
-
13
- export { Table, TableBody, TableCaption, TableCell, TableFooter, TableHead, TableHeader, TableRow };
@@ -1,117 +0,0 @@
1
- "use client";
2
- import { jsx } from "react/jsx-runtime";
3
- import * as React from "react";
4
- import { cn } from "../../../utils";
5
- function Table({ className, ...props }) {
6
- return /* @__PURE__ */ jsx(
7
- "div",
8
- {
9
- "data-slot": "table-container",
10
- className: "sg:relative sg:w-full sg:overflow-x-auto",
11
- children: /* @__PURE__ */ jsx(
12
- "table",
13
- {
14
- "data-slot": "table",
15
- className: cn("sg:w-full sg:caption-bottom sg:text-sm", className),
16
- ...props
17
- }
18
- )
19
- }
20
- );
21
- }
22
- function TableHeader({ className, ...props }) {
23
- return /* @__PURE__ */ jsx(
24
- "thead",
25
- {
26
- "data-slot": "table-header",
27
- className: cn("sg:[&_tr]:border-b", className),
28
- ...props
29
- }
30
- );
31
- }
32
- function TableBody({ className, ...props }) {
33
- return /* @__PURE__ */ jsx(
34
- "tbody",
35
- {
36
- "data-slot": "table-body",
37
- className: cn("sg:[&_tr:last-child]:border-0", className),
38
- ...props
39
- }
40
- );
41
- }
42
- function TableFooter({ className, ...props }) {
43
- return /* @__PURE__ */ jsx(
44
- "tfoot",
45
- {
46
- "data-slot": "table-footer",
47
- className: cn(
48
- "sg:bg-muted/50 sg:border-t sg:font-medium sg:[&>tr]:last:border-b-0",
49
- className
50
- ),
51
- ...props
52
- }
53
- );
54
- }
55
- function TableRow({ className, ...props }) {
56
- return /* @__PURE__ */ jsx(
57
- "tr",
58
- {
59
- "data-slot": "table-row",
60
- className: cn(
61
- "sg:hover:bg-muted/50 sg:data-[state=selected]:bg-muted sg:border-b sg:transition-colors",
62
- className
63
- ),
64
- ...props
65
- }
66
- );
67
- }
68
- function TableHead({ className, ...props }) {
69
- return /* @__PURE__ */ jsx(
70
- "th",
71
- {
72
- "data-slot": "table-head",
73
- className: cn(
74
- "sg:text-foreground sg:h-10 sg:px-2 sg:text-left sg:align-middle sg:font-medium sg:whitespace-nowrap sg:[&:has([role=checkbox])]:pr-0 sg:[&>[role=checkbox]]:translate-y-[2px]",
75
- className
76
- ),
77
- ...props
78
- }
79
- );
80
- }
81
- function TableCell({ className, ...props }) {
82
- return /* @__PURE__ */ jsx(
83
- "td",
84
- {
85
- "data-slot": "table-cell",
86
- className: cn(
87
- "sg:p-2 sg:align-middle sg:whitespace-nowrap sg:[&:has([role=checkbox])]:pr-0 sg:[&>[role=checkbox]]:translate-y-[2px]",
88
- className
89
- ),
90
- ...props
91
- }
92
- );
93
- }
94
- function TableCaption({
95
- className,
96
- ...props
97
- }) {
98
- return /* @__PURE__ */ jsx(
99
- "caption",
100
- {
101
- "data-slot": "table-caption",
102
- className: cn("sg:text-muted-foreground sg:mt-4 sg:text-sm", className),
103
- ...props
104
- }
105
- );
106
- }
107
- export {
108
- Table,
109
- TableBody,
110
- TableCaption,
111
- TableCell,
112
- TableFooter,
113
- TableHead,
114
- TableHeader,
115
- TableRow
116
- };
117
- //# sourceMappingURL=table.js.map
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../../../../src/components/primitives/table/table.tsx"],"sourcesContent":["\"use client\";\n\nimport * as React from \"react\";\nimport { cn } from \"../../../utils\";\n\nfunction Table({ className, ...props }: React.ComponentProps<\"table\">) {\n return (\n <div\n data-slot=\"table-container\"\n className=\"sg:relative sg:w-full sg:overflow-x-auto\"\n >\n <table\n data-slot=\"table\"\n className={cn(\"sg:w-full sg:caption-bottom sg:text-sm\", className)}\n {...props}\n />\n </div>\n );\n}\n\nfunction TableHeader({ className, ...props }: React.ComponentProps<\"thead\">) {\n return (\n <thead\n data-slot=\"table-header\"\n className={cn(\"sg:[&_tr]:border-b\", className)}\n {...props}\n />\n );\n}\n\nfunction TableBody({ className, ...props }: React.ComponentProps<\"tbody\">) {\n return (\n <tbody\n data-slot=\"table-body\"\n className={cn(\"sg:[&_tr:last-child]:border-0\", className)}\n {...props}\n />\n );\n}\n\nfunction TableFooter({ className, ...props }: React.ComponentProps<\"tfoot\">) {\n return (\n <tfoot\n data-slot=\"table-footer\"\n className={cn(\n \"sg:bg-muted/50 sg:border-t sg:font-medium sg:[&>tr]:last:border-b-0\",\n className\n )}\n {...props}\n />\n );\n}\n\nfunction TableRow({ className, ...props }: React.ComponentProps<\"tr\">) {\n return (\n <tr\n data-slot=\"table-row\"\n className={cn(\n \"sg:hover:bg-muted/50 sg:data-[state=selected]:bg-muted sg:border-b sg:transition-colors\",\n className\n )}\n {...props}\n />\n );\n}\n\nfunction TableHead({ className, ...props }: React.ComponentProps<\"th\">) {\n return (\n <th\n data-slot=\"table-head\"\n className={cn(\n \"sg:text-foreground sg:h-10 sg:px-2 sg:text-left sg:align-middle sg:font-medium sg:whitespace-nowrap sg:[&:has([role=checkbox])]:pr-0 sg:[&>[role=checkbox]]:translate-y-[2px]\",\n className\n )}\n {...props}\n />\n );\n}\n\nfunction TableCell({ className, ...props }: React.ComponentProps<\"td\">) {\n return (\n <td\n data-slot=\"table-cell\"\n className={cn(\n \"sg:p-2 sg:align-middle sg:whitespace-nowrap sg:[&:has([role=checkbox])]:pr-0 sg:[&>[role=checkbox]]:translate-y-[2px]\",\n className\n )}\n {...props}\n />\n );\n}\n\nfunction TableCaption({\n className,\n ...props\n}: React.ComponentProps<\"caption\">) {\n return (\n <caption\n data-slot=\"table-caption\"\n className={cn(\"sg:text-muted-foreground sg:mt-4 sg:text-sm\", className)}\n {...props}\n />\n );\n}\n\nexport {\n Table,\n TableHeader,\n TableBody,\n TableFooter,\n TableHead,\n TableRow,\n TableCell,\n TableCaption,\n};\n"],"mappings":";AAWM;AATN,YAAY,WAAW;AACvB,SAAS,UAAU;AAEnB,SAAS,MAAM,EAAE,WAAW,GAAG,MAAM,GAAkC;AACrE,SACE;AAAA,IAAC;AAAA;AAAA,MACC,aAAU;AAAA,MACV,WAAU;AAAA,MAEV;AAAA,QAAC;AAAA;AAAA,UACC,aAAU;AAAA,UACV,WAAW,GAAG,0CAA0C,SAAS;AAAA,UAChE,GAAG;AAAA;AAAA,MACN;AAAA;AAAA,EACF;AAEJ;AAEA,SAAS,YAAY,EAAE,WAAW,GAAG,MAAM,GAAkC;AAC3E,SACE;AAAA,IAAC;AAAA;AAAA,MACC,aAAU;AAAA,MACV,WAAW,GAAG,sBAAsB,SAAS;AAAA,MAC5C,GAAG;AAAA;AAAA,EACN;AAEJ;AAEA,SAAS,UAAU,EAAE,WAAW,GAAG,MAAM,GAAkC;AACzE,SACE;AAAA,IAAC;AAAA;AAAA,MACC,aAAU;AAAA,MACV,WAAW,GAAG,iCAAiC,SAAS;AAAA,MACvD,GAAG;AAAA;AAAA,EACN;AAEJ;AAEA,SAAS,YAAY,EAAE,WAAW,GAAG,MAAM,GAAkC;AAC3E,SACE;AAAA,IAAC;AAAA;AAAA,MACC,aAAU;AAAA,MACV,WAAW;AAAA,QACT;AAAA,QACA;AAAA,MACF;AAAA,MACC,GAAG;AAAA;AAAA,EACN;AAEJ;AAEA,SAAS,SAAS,EAAE,WAAW,GAAG,MAAM,GAA+B;AACrE,SACE;AAAA,IAAC;AAAA;AAAA,MACC,aAAU;AAAA,MACV,WAAW;AAAA,QACT;AAAA,QACA;AAAA,MACF;AAAA,MACC,GAAG;AAAA;AAAA,EACN;AAEJ;AAEA,SAAS,UAAU,EAAE,WAAW,GAAG,MAAM,GAA+B;AACtE,SACE;AAAA,IAAC;AAAA;AAAA,MACC,aAAU;AAAA,MACV,WAAW;AAAA,QACT;AAAA,QACA;AAAA,MACF;AAAA,MACC,GAAG;AAAA;AAAA,EACN;AAEJ;AAEA,SAAS,UAAU,EAAE,WAAW,GAAG,MAAM,GAA+B;AACtE,SACE;AAAA,IAAC;AAAA;AAAA,MACC,aAAU;AAAA,MACV,WAAW;AAAA,QACT;AAAA,QACA;AAAA,MACF;AAAA,MACC,GAAG;AAAA;AAAA,EACN;AAEJ;AAEA,SAAS,aAAa;AAAA,EACpB;AAAA,EACA,GAAG;AACL,GAAoC;AAClC,SACE;AAAA,IAAC;AAAA;AAAA,MACC,aAAU;AAAA,MACV,WAAW,GAAG,+CAA+C,SAAS;AAAA,MACrE,GAAG;AAAA;AAAA,EACN;AAEJ;","names":[]}