@c-rex/ui 0.0.11 → 0.0.13
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.
- package/package.json +34 -54
- package/src/alert.tsx +58 -0
- package/src/breadcrumb.tsx +115 -0
- package/src/button.tsx +66 -0
- package/src/command.tsx +151 -0
- package/src/dialog.tsx +122 -0
- package/src/hooks/use-mobile.tsx +19 -0
- package/src/input.tsx +22 -0
- package/src/popover.tsx +31 -0
- package/src/select.tsx +157 -0
- package/src/separator.tsx +29 -0
- package/src/sheet.tsx +140 -0
- package/src/sidebar.tsx +785 -0
- package/src/skeleton.tsx +15 -0
- package/src/table.tsx +120 -0
- package/src/tooltip.tsx +30 -0
- package/dist/alert.cjs.js +0 -197
- package/dist/alert.cjs.js.map +0 -1
- package/dist/alert.d.cts +0 -11
- package/dist/alert.d.ts +0 -11
- package/dist/alert.esm.js +0 -116
- package/dist/alert.esm.js.map +0 -1
- package/dist/breadcrumb.cjs.js +0 -299
- package/dist/breadcrumb.cjs.js.map +0 -1
- package/dist/breadcrumb.d.cts +0 -22
- package/dist/breadcrumb.d.ts +0 -22
- package/dist/breadcrumb.esm.js +0 -202
- package/dist/breadcrumb.esm.js.map +0 -1
- package/dist/button.cjs.js +0 -200
- package/dist/button.cjs.js.map +0 -1
- package/dist/button.d.cts +0 -15
- package/dist/button.d.ts +0 -15
- package/dist/button.esm.js +0 -123
- package/dist/button.esm.js.map +0 -1
- package/dist/command.cjs.js +0 -387
- package/dist/command.cjs.js.map +0 -1
- package/dist/command.d.cts +0 -83
- package/dist/command.d.ts +0 -83
- package/dist/command.esm.js +0 -282
- package/dist/command.esm.js.map +0 -1
- package/dist/dialog.cjs.js +0 -290
- package/dist/dialog.cjs.js.map +0 -1
- package/dist/dialog.d.cts +0 -22
- package/dist/dialog.d.ts +0 -22
- package/dist/dialog.esm.js +0 -181
- package/dist/dialog.esm.js.map +0 -1
- package/dist/hooks/use-mobile.cjs.js +0 -127
- package/dist/hooks/use-mobile.cjs.js.map +0 -1
- package/dist/hooks/use-mobile.d.cts +0 -3
- package/dist/hooks/use-mobile.d.ts +0 -3
- package/dist/hooks/use-mobile.esm.js +0 -66
- package/dist/hooks/use-mobile.esm.js.map +0 -1
- package/dist/input.cjs.js +0 -155
- package/dist/input.cjs.js.map +0 -1
- package/dist/input.d.cts +0 -5
- package/dist/input.d.ts +0 -5
- package/dist/input.esm.js +0 -82
- package/dist/input.esm.js.map +0 -1
- package/dist/popover.cjs.js +0 -175
- package/dist/popover.cjs.js.map +0 -1
- package/dist/popover.d.cts +0 -9
- package/dist/popover.d.ts +0 -9
- package/dist/popover.esm.js +0 -90
- package/dist/popover.esm.js.map +0 -1
- package/dist/select.cjs.js +0 -326
- package/dist/select.cjs.js.map +0 -1
- package/dist/select.d.cts +0 -15
- package/dist/select.d.ts +0 -15
- package/dist/select.esm.js +0 -217
- package/dist/select.esm.js.map +0 -1
- package/dist/separator.cjs.js +0 -158
- package/dist/separator.cjs.js.map +0 -1
- package/dist/separator.d.cts +0 -6
- package/dist/separator.d.ts +0 -6
- package/dist/separator.esm.js +0 -85
- package/dist/separator.esm.js.map +0 -1
- package/dist/sheet.cjs.js +0 -308
- package/dist/sheet.cjs.js.map +0 -1
- package/dist/sheet.d.cts +0 -29
- package/dist/sheet.d.ts +0 -29
- package/dist/sheet.esm.js +0 -199
- package/dist/sheet.esm.js.map +0 -1
- package/dist/sidebar.cjs.js +0 -1077
- package/dist/sidebar.cjs.js.map +0 -1
- package/dist/sidebar.d.cts +0 -72
- package/dist/sidebar.d.ts +0 -72
- package/dist/sidebar.esm.js +0 -912
- package/dist/sidebar.esm.js.map +0 -1
- package/dist/skeleton.cjs.js +0 -138
- package/dist/skeleton.cjs.js.map +0 -1
- package/dist/skeleton.d.cts +0 -5
- package/dist/skeleton.d.ts +0 -5
- package/dist/skeleton.esm.js +0 -76
- package/dist/skeleton.esm.js.map +0 -1
- package/dist/table.cjs.js +0 -254
- package/dist/table.cjs.js.map +0 -1
- package/dist/table.d.cts +0 -12
- package/dist/table.d.ts +0 -12
- package/dist/table.esm.js +0 -153
- package/dist/table.esm.js.map +0 -1
- package/dist/tooltip.cjs.js +0 -173
- package/dist/tooltip.cjs.js.map +0 -1
- package/dist/tooltip.d.cts +0 -9
- package/dist/tooltip.d.ts +0 -9
- package/dist/tooltip.esm.js +0 -88
- package/dist/tooltip.esm.js.map +0 -1
package/src/skeleton.tsx
ADDED
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { cn } from "@c-rex/utils";
|
|
2
|
+
|
|
3
|
+
function Skeleton({
|
|
4
|
+
className,
|
|
5
|
+
...props
|
|
6
|
+
}: React.HTMLAttributes<HTMLDivElement>) {
|
|
7
|
+
return (
|
|
8
|
+
<div
|
|
9
|
+
className={cn("animate-pulse rounded-md bg-primary/10", className)}
|
|
10
|
+
{...props}
|
|
11
|
+
/>
|
|
12
|
+
);
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
export { Skeleton };
|
package/src/table.tsx
ADDED
|
@@ -0,0 +1,120 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
|
|
3
|
+
import { cn } from "@c-rex/utils";
|
|
4
|
+
|
|
5
|
+
const Table = React.forwardRef<
|
|
6
|
+
HTMLTableElement,
|
|
7
|
+
React.HTMLAttributes<HTMLTableElement>
|
|
8
|
+
>(({ className, ...props }, ref) => (
|
|
9
|
+
<div className="relative w-full overflow-auto">
|
|
10
|
+
<table
|
|
11
|
+
ref={ref}
|
|
12
|
+
className={cn("w-full caption-bottom text-sm", className)}
|
|
13
|
+
{...props}
|
|
14
|
+
/>
|
|
15
|
+
</div>
|
|
16
|
+
));
|
|
17
|
+
Table.displayName = "Table";
|
|
18
|
+
|
|
19
|
+
const TableHeader = React.forwardRef<
|
|
20
|
+
HTMLTableSectionElement,
|
|
21
|
+
React.HTMLAttributes<HTMLTableSectionElement>
|
|
22
|
+
>(({ className, ...props }, ref) => (
|
|
23
|
+
<thead ref={ref} className={cn("[&_tr]:border-b", className)} {...props} />
|
|
24
|
+
));
|
|
25
|
+
TableHeader.displayName = "TableHeader";
|
|
26
|
+
|
|
27
|
+
const TableBody = React.forwardRef<
|
|
28
|
+
HTMLTableSectionElement,
|
|
29
|
+
React.HTMLAttributes<HTMLTableSectionElement>
|
|
30
|
+
>(({ className, ...props }, ref) => (
|
|
31
|
+
<tbody
|
|
32
|
+
ref={ref}
|
|
33
|
+
className={cn("[&_tr:last-child]:border-0", className)}
|
|
34
|
+
{...props}
|
|
35
|
+
/>
|
|
36
|
+
));
|
|
37
|
+
TableBody.displayName = "TableBody";
|
|
38
|
+
|
|
39
|
+
const TableFooter = React.forwardRef<
|
|
40
|
+
HTMLTableSectionElement,
|
|
41
|
+
React.HTMLAttributes<HTMLTableSectionElement>
|
|
42
|
+
>(({ className, ...props }, ref) => (
|
|
43
|
+
<tfoot
|
|
44
|
+
ref={ref}
|
|
45
|
+
className={cn(
|
|
46
|
+
"border-t bg-muted/50 font-medium [&>tr]:last:border-b-0",
|
|
47
|
+
className,
|
|
48
|
+
)}
|
|
49
|
+
{...props}
|
|
50
|
+
/>
|
|
51
|
+
));
|
|
52
|
+
TableFooter.displayName = "TableFooter";
|
|
53
|
+
|
|
54
|
+
const TableRow = React.forwardRef<
|
|
55
|
+
HTMLTableRowElement,
|
|
56
|
+
React.HTMLAttributes<HTMLTableRowElement>
|
|
57
|
+
>(({ className, ...props }, ref) => (
|
|
58
|
+
<tr
|
|
59
|
+
ref={ref}
|
|
60
|
+
className={cn(
|
|
61
|
+
"border-b transition-colors hover:bg-muted/50 data-[state=selected]:bg-muted",
|
|
62
|
+
className,
|
|
63
|
+
)}
|
|
64
|
+
{...props}
|
|
65
|
+
/>
|
|
66
|
+
));
|
|
67
|
+
TableRow.displayName = "TableRow";
|
|
68
|
+
|
|
69
|
+
const TableHead = React.forwardRef<
|
|
70
|
+
HTMLTableCellElement,
|
|
71
|
+
React.ThHTMLAttributes<HTMLTableCellElement>
|
|
72
|
+
>(({ className, ...props }, ref) => (
|
|
73
|
+
<th
|
|
74
|
+
ref={ref}
|
|
75
|
+
className={cn(
|
|
76
|
+
"h-10 px-2 text-left align-middle font-medium text-muted-foreground [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]",
|
|
77
|
+
className,
|
|
78
|
+
)}
|
|
79
|
+
{...props}
|
|
80
|
+
/>
|
|
81
|
+
));
|
|
82
|
+
TableHead.displayName = "TableHead";
|
|
83
|
+
|
|
84
|
+
const TableCell = React.forwardRef<
|
|
85
|
+
HTMLTableCellElement,
|
|
86
|
+
React.TdHTMLAttributes<HTMLTableCellElement>
|
|
87
|
+
>(({ className, ...props }, ref) => (
|
|
88
|
+
<td
|
|
89
|
+
ref={ref}
|
|
90
|
+
className={cn(
|
|
91
|
+
"p-2 align-middle [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]",
|
|
92
|
+
className,
|
|
93
|
+
)}
|
|
94
|
+
{...props}
|
|
95
|
+
/>
|
|
96
|
+
));
|
|
97
|
+
TableCell.displayName = "TableCell";
|
|
98
|
+
|
|
99
|
+
const TableCaption = React.forwardRef<
|
|
100
|
+
HTMLTableCaptionElement,
|
|
101
|
+
React.HTMLAttributes<HTMLTableCaptionElement>
|
|
102
|
+
>(({ className, ...props }, ref) => (
|
|
103
|
+
<caption
|
|
104
|
+
ref={ref}
|
|
105
|
+
className={cn("mt-4 text-sm text-muted-foreground", className)}
|
|
106
|
+
{...props}
|
|
107
|
+
/>
|
|
108
|
+
));
|
|
109
|
+
TableCaption.displayName = "TableCaption";
|
|
110
|
+
|
|
111
|
+
export {
|
|
112
|
+
Table,
|
|
113
|
+
TableHeader,
|
|
114
|
+
TableBody,
|
|
115
|
+
TableFooter,
|
|
116
|
+
TableHead,
|
|
117
|
+
TableRow,
|
|
118
|
+
TableCell,
|
|
119
|
+
TableCaption,
|
|
120
|
+
};
|
package/src/tooltip.tsx
ADDED
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import * as TooltipPrimitive from "@radix-ui/react-tooltip";
|
|
3
|
+
|
|
4
|
+
import { cn } from "@c-rex/utils";
|
|
5
|
+
|
|
6
|
+
const TooltipProvider = TooltipPrimitive.Provider;
|
|
7
|
+
|
|
8
|
+
const Tooltip = TooltipPrimitive.Root;
|
|
9
|
+
|
|
10
|
+
const TooltipTrigger = TooltipPrimitive.Trigger;
|
|
11
|
+
|
|
12
|
+
const TooltipContent = React.forwardRef<
|
|
13
|
+
React.ElementRef<typeof TooltipPrimitive.Content>,
|
|
14
|
+
React.ComponentPropsWithoutRef<typeof TooltipPrimitive.Content>
|
|
15
|
+
>(({ className, sideOffset = 4, ...props }, ref) => (
|
|
16
|
+
<TooltipPrimitive.Portal>
|
|
17
|
+
<TooltipPrimitive.Content
|
|
18
|
+
ref={ref}
|
|
19
|
+
sideOffset={sideOffset}
|
|
20
|
+
className={cn(
|
|
21
|
+
"z-50 overflow-hidden rounded-md bg-primary px-3 py-1.5 text-xs text-primary-foreground animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",
|
|
22
|
+
className,
|
|
23
|
+
)}
|
|
24
|
+
{...props}
|
|
25
|
+
/>
|
|
26
|
+
</TooltipPrimitive.Portal>
|
|
27
|
+
));
|
|
28
|
+
TooltipContent.displayName = TooltipPrimitive.Content.displayName;
|
|
29
|
+
|
|
30
|
+
export { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };
|
package/dist/alert.cjs.js
DELETED
|
@@ -1,197 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
function _define_property(obj, key, value) {
|
|
3
|
-
if (key in obj) {
|
|
4
|
-
Object.defineProperty(obj, key, {
|
|
5
|
-
value: value,
|
|
6
|
-
enumerable: true,
|
|
7
|
-
configurable: true,
|
|
8
|
-
writable: true
|
|
9
|
-
});
|
|
10
|
-
} else {
|
|
11
|
-
obj[key] = value;
|
|
12
|
-
}
|
|
13
|
-
return obj;
|
|
14
|
-
}
|
|
15
|
-
function _object_spread(target) {
|
|
16
|
-
for(var i = 1; i < arguments.length; i++){
|
|
17
|
-
var source = arguments[i] != null ? arguments[i] : {};
|
|
18
|
-
var ownKeys = Object.keys(source);
|
|
19
|
-
if (typeof Object.getOwnPropertySymbols === "function") {
|
|
20
|
-
ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function(sym) {
|
|
21
|
-
return Object.getOwnPropertyDescriptor(source, sym).enumerable;
|
|
22
|
-
}));
|
|
23
|
-
}
|
|
24
|
-
ownKeys.forEach(function(key) {
|
|
25
|
-
_define_property(target, key, source[key]);
|
|
26
|
-
});
|
|
27
|
-
}
|
|
28
|
-
return target;
|
|
29
|
-
}
|
|
30
|
-
function _object_without_properties(source, excluded) {
|
|
31
|
-
if (source == null) return {};
|
|
32
|
-
var target = _object_without_properties_loose(source, excluded);
|
|
33
|
-
var key, i;
|
|
34
|
-
if (Object.getOwnPropertySymbols) {
|
|
35
|
-
var sourceSymbolKeys = Object.getOwnPropertySymbols(source);
|
|
36
|
-
for(i = 0; i < sourceSymbolKeys.length; i++){
|
|
37
|
-
key = sourceSymbolKeys[i];
|
|
38
|
-
if (excluded.indexOf(key) >= 0) continue;
|
|
39
|
-
if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
|
|
40
|
-
target[key] = source[key];
|
|
41
|
-
}
|
|
42
|
-
}
|
|
43
|
-
return target;
|
|
44
|
-
}
|
|
45
|
-
function _object_without_properties_loose(source, excluded) {
|
|
46
|
-
if (source == null) return {};
|
|
47
|
-
var target = {};
|
|
48
|
-
var sourceKeys = Object.keys(source);
|
|
49
|
-
var key, i;
|
|
50
|
-
for(i = 0; i < sourceKeys.length; i++){
|
|
51
|
-
key = sourceKeys[i];
|
|
52
|
-
if (excluded.indexOf(key) >= 0) continue;
|
|
53
|
-
target[key] = source[key];
|
|
54
|
-
}
|
|
55
|
-
return target;
|
|
56
|
-
}
|
|
57
|
-
function _type_of(obj) {
|
|
58
|
-
"@swc/helpers - typeof";
|
|
59
|
-
return obj && typeof Symbol !== "undefined" && obj.constructor === Symbol ? "symbol" : typeof obj;
|
|
60
|
-
}
|
|
61
|
-
var __create = Object.create;
|
|
62
|
-
var __defProp = Object.defineProperty;
|
|
63
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
64
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
65
|
-
var __getProtoOf = Object.getPrototypeOf;
|
|
66
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
67
|
-
var __export = function(target, all) {
|
|
68
|
-
for(var name in all)__defProp(target, name, {
|
|
69
|
-
get: all[name],
|
|
70
|
-
enumerable: true
|
|
71
|
-
});
|
|
72
|
-
};
|
|
73
|
-
var __copyProps = function(to, from, except, desc) {
|
|
74
|
-
if (from && (typeof from === "undefined" ? "undefined" : _type_of(from)) === "object" || typeof from === "function") {
|
|
75
|
-
var _iteratorNormalCompletion = true, _didIteratorError = false, _iteratorError = undefined;
|
|
76
|
-
try {
|
|
77
|
-
var _loop = function() {
|
|
78
|
-
var key = _step.value;
|
|
79
|
-
if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
|
|
80
|
-
get: function() {
|
|
81
|
-
return from[key];
|
|
82
|
-
},
|
|
83
|
-
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
84
|
-
});
|
|
85
|
-
};
|
|
86
|
-
for(var _iterator = __getOwnPropNames(from)[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true)_loop();
|
|
87
|
-
} catch (err) {
|
|
88
|
-
_didIteratorError = true;
|
|
89
|
-
_iteratorError = err;
|
|
90
|
-
} finally{
|
|
91
|
-
try {
|
|
92
|
-
if (!_iteratorNormalCompletion && _iterator.return != null) {
|
|
93
|
-
_iterator.return();
|
|
94
|
-
}
|
|
95
|
-
} finally{
|
|
96
|
-
if (_didIteratorError) {
|
|
97
|
-
throw _iteratorError;
|
|
98
|
-
}
|
|
99
|
-
}
|
|
100
|
-
}
|
|
101
|
-
}
|
|
102
|
-
return to;
|
|
103
|
-
};
|
|
104
|
-
var __toESM = function(mod, isNodeMode, target) {
|
|
105
|
-
return target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(// If the importer is in node compatibility mode or this is not an ESM
|
|
106
|
-
// file that has been converted to a CommonJS file using a Babel-
|
|
107
|
-
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
108
|
-
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
109
|
-
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
|
|
110
|
-
value: mod,
|
|
111
|
-
enumerable: true
|
|
112
|
-
}) : target, mod);
|
|
113
|
-
};
|
|
114
|
-
var __toCommonJS = function(mod) {
|
|
115
|
-
return __copyProps(__defProp({}, "__esModule", {
|
|
116
|
-
value: true
|
|
117
|
-
}), mod);
|
|
118
|
-
};
|
|
119
|
-
// src/alert.tsx
|
|
120
|
-
var alert_exports = {};
|
|
121
|
-
__export(alert_exports, {
|
|
122
|
-
Alert: function() {
|
|
123
|
-
return Alert;
|
|
124
|
-
},
|
|
125
|
-
AlertDescription: function() {
|
|
126
|
-
return AlertDescription;
|
|
127
|
-
},
|
|
128
|
-
AlertTitle: function() {
|
|
129
|
-
return AlertTitle;
|
|
130
|
-
}
|
|
131
|
-
});
|
|
132
|
-
module.exports = __toCommonJS(alert_exports);
|
|
133
|
-
var React = __toESM(require("react"), 1);
|
|
134
|
-
var import_class_variance_authority = require("class-variance-authority");
|
|
135
|
-
// ../utils/src/classMerge.ts
|
|
136
|
-
var import_clsx = require("clsx");
|
|
137
|
-
var import_tailwind_merge = require("tailwind-merge");
|
|
138
|
-
function cn() {
|
|
139
|
-
for(var _len = arguments.length, inputs = new Array(_len), _key = 0; _key < _len; _key++){
|
|
140
|
-
inputs[_key] = arguments[_key];
|
|
141
|
-
}
|
|
142
|
-
return (0, import_tailwind_merge.twMerge)((0, import_clsx.clsx)(inputs));
|
|
143
|
-
}
|
|
144
|
-
// src/alert.tsx
|
|
145
|
-
var import_jsx_runtime = require("react/jsx-runtime");
|
|
146
|
-
var alertVariants = (0, import_class_variance_authority.cva)("relative w-full rounded-lg border px-4 py-3 text-sm [&>svg+div]:translate-y-[-3px] [&>svg]:absolute [&>svg]:left-4 [&>svg]:top-4 [&>svg]:text-foreground [&>svg~*]:pl-7", {
|
|
147
|
-
variants: {
|
|
148
|
-
variant: {
|
|
149
|
-
default: "bg-background text-foreground",
|
|
150
|
-
destructive: "border-destructive/50 text-destructive dark:border-destructive [&>svg]:text-destructive"
|
|
151
|
-
}
|
|
152
|
-
},
|
|
153
|
-
defaultVariants: {
|
|
154
|
-
variant: "default"
|
|
155
|
-
}
|
|
156
|
-
});
|
|
157
|
-
var Alert = React.forwardRef(function(_param, ref) {
|
|
158
|
-
var className = _param.className, variant = _param.variant, props = _object_without_properties(_param, [
|
|
159
|
-
"className",
|
|
160
|
-
"variant"
|
|
161
|
-
]);
|
|
162
|
-
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", _object_spread({
|
|
163
|
-
ref: ref,
|
|
164
|
-
role: "alert",
|
|
165
|
-
className: cn(alertVariants({
|
|
166
|
-
variant: variant
|
|
167
|
-
}), className)
|
|
168
|
-
}, props));
|
|
169
|
-
});
|
|
170
|
-
Alert.displayName = "Alert";
|
|
171
|
-
var AlertTitle = React.forwardRef(function(_param, ref) {
|
|
172
|
-
var className = _param.className, props = _object_without_properties(_param, [
|
|
173
|
-
"className"
|
|
174
|
-
]);
|
|
175
|
-
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("h5", _object_spread({
|
|
176
|
-
ref: ref,
|
|
177
|
-
className: cn("mb-1 font-medium leading-none tracking-tight", className)
|
|
178
|
-
}, props));
|
|
179
|
-
});
|
|
180
|
-
AlertTitle.displayName = "AlertTitle";
|
|
181
|
-
var AlertDescription = React.forwardRef(function(_param, ref) {
|
|
182
|
-
var className = _param.className, props = _object_without_properties(_param, [
|
|
183
|
-
"className"
|
|
184
|
-
]);
|
|
185
|
-
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", _object_spread({
|
|
186
|
-
ref: ref,
|
|
187
|
-
className: cn("text-sm [&_p]:leading-relaxed", className)
|
|
188
|
-
}, props));
|
|
189
|
-
});
|
|
190
|
-
AlertDescription.displayName = "AlertDescription";
|
|
191
|
-
// Annotate the CommonJS export names for ESM import in node:
|
|
192
|
-
0 && (module.exports = {
|
|
193
|
-
Alert: Alert,
|
|
194
|
-
AlertDescription: AlertDescription,
|
|
195
|
-
AlertTitle: AlertTitle
|
|
196
|
-
});
|
|
197
|
-
//# sourceMappingURL=alert.cjs.js.map
|
package/dist/alert.cjs.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["/Users/periotto/Desktop/workspace/c-rex.net-web-client-foundation/packages/ui/dist/alert.cjs.js","../src/alert.tsx","../../utils/src/classMerge.ts"],"names":["__create","Object","create","__defProp","defineProperty","__getOwnPropDesc","getOwnPropertyDescriptor","__getOwnPropNames","getOwnPropertyNames","__getProtoOf","getPrototypeOf","__hasOwnProp","prototype","hasOwnProperty","__export","target","all","name","get","enumerable","__copyProps","to","from","except","desc","key","call","__toESM","mod","isNodeMode","__esModule","value","__toCommonJS","alert_exports","Alert","AlertDescription","AlertTitle","module","exports","React","require","import_class_variance_authority","import_clsx","import_tailwind_merge","cn","inputs","twMerge","clsx","import_jsx_runtime","alertVariants","cva","variants","variant","default","destructive","defaultVariants","forwardRef","ref","className","props","jsx","role","displayName"],"mappings":"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","sourcesContent":["\"use strict\";\nvar __create = Object.create;\nvar __defProp = Object.defineProperty;\nvar __getOwnPropDesc = Object.getOwnPropertyDescriptor;\nvar __getOwnPropNames = Object.getOwnPropertyNames;\nvar __getProtoOf = Object.getPrototypeOf;\nvar __hasOwnProp = Object.prototype.hasOwnProperty;\nvar __export = (target, all) => {\n for (var name in all)\n __defProp(target, name, { get: all[name], enumerable: true });\n};\nvar __copyProps = (to, from, except, desc) => {\n if (from && typeof from === \"object\" || typeof from === \"function\") {\n for (let key of __getOwnPropNames(from))\n if (!__hasOwnProp.call(to, key) && key !== except)\n __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });\n }\n return to;\n};\nvar __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(\n // If the importer is in node compatibility mode or this is not an ESM\n // file that has been converted to a CommonJS file using a Babel-\n // compatible transform (i.e. \"__esModule\" has not been set), then set\n // \"default\" to the CommonJS \"module.exports\" for node compatibility.\n isNodeMode || !mod || !mod.__esModule ? __defProp(target, \"default\", { value: mod, enumerable: true }) : target,\n mod\n));\nvar __toCommonJS = (mod) => __copyProps(__defProp({}, \"__esModule\", { value: true }), mod);\n\n// src/alert.tsx\nvar alert_exports = {};\n__export(alert_exports, {\n Alert: () => Alert,\n AlertDescription: () => AlertDescription,\n AlertTitle: () => AlertTitle\n});\nmodule.exports = __toCommonJS(alert_exports);\nvar React = __toESM(require(\"react\"), 1);\nvar import_class_variance_authority = require(\"class-variance-authority\");\n\n// ../utils/src/classMerge.ts\nvar import_clsx = require(\"clsx\");\nvar import_tailwind_merge = require(\"tailwind-merge\");\nfunction cn(...inputs) {\n return (0, import_tailwind_merge.twMerge)((0, import_clsx.clsx)(inputs));\n}\n\n// src/alert.tsx\nvar import_jsx_runtime = require(\"react/jsx-runtime\");\nvar alertVariants = (0, import_class_variance_authority.cva)(\n \"relative w-full rounded-lg border px-4 py-3 text-sm [&>svg+div]:translate-y-[-3px] [&>svg]:absolute [&>svg]:left-4 [&>svg]:top-4 [&>svg]:text-foreground [&>svg~*]:pl-7\",\n {\n variants: {\n variant: {\n default: \"bg-background text-foreground\",\n destructive: \"border-destructive/50 text-destructive dark:border-destructive [&>svg]:text-destructive\"\n }\n },\n defaultVariants: {\n variant: \"default\"\n }\n }\n);\nvar Alert = React.forwardRef(({ className, variant, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)(\n \"div\",\n {\n ref,\n role: \"alert\",\n className: cn(alertVariants({ variant }), className),\n ...props\n }\n));\nAlert.displayName = \"Alert\";\nvar AlertTitle = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)(\n \"h5\",\n {\n ref,\n className: cn(\"mb-1 font-medium leading-none tracking-tight\", className),\n ...props\n }\n));\nAlertTitle.displayName = \"AlertTitle\";\nvar AlertDescription = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)(\n \"div\",\n {\n ref,\n className: cn(\"text-sm [&_p]:leading-relaxed\", className),\n ...props\n }\n));\nAlertDescription.displayName = \"AlertDescription\";\n// Annotate the CommonJS export names for ESM import in node:\n0 && (module.exports = {\n Alert,\n AlertDescription,\n AlertTitle\n});\n","import * as React from \"react\";\nimport { cva, type VariantProps } from \"class-variance-authority\";\nimport { cn } from \"@c-rex/utils\";\n\nconst alertVariants = cva(\n \"relative w-full rounded-lg border px-4 py-3 text-sm [&>svg+div]:translate-y-[-3px] [&>svg]:absolute [&>svg]:left-4 [&>svg]:top-4 [&>svg]:text-foreground [&>svg~*]:pl-7\",\n {\n variants: {\n variant: {\n default: \"bg-background text-foreground\",\n destructive:\n \"border-destructive/50 text-destructive dark:border-destructive [&>svg]:text-destructive\",\n },\n },\n defaultVariants: {\n variant: \"default\",\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes<HTMLDivElement> & VariantProps<typeof alertVariants>\n>(({ className, variant, ...props }, ref) => (\n <div\n ref={ref}\n role=\"alert\"\n className={cn(alertVariants({ variant }), className)}\n {...props}\n />\n));\nAlert.displayName = \"Alert\";\n\nconst AlertTitle = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes<HTMLHeadingElement>\n>(({ className, ...props }, ref) => (\n <h5\n ref={ref}\n className={cn(\"mb-1 font-medium leading-none tracking-tight\", className)}\n {...props}\n />\n));\nAlertTitle.displayName = \"AlertTitle\";\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes<HTMLParagraphElement>\n>(({ className, ...props }, ref) => (\n <div\n ref={ref}\n className={cn(\"text-sm [&_p]:leading-relaxed\", className)}\n {...props}\n />\n));\nAlertDescription.displayName = \"AlertDescription\";\n\nexport { Alert, AlertTitle, AlertDescription };\n","import { clsx, type ClassValue } from \"clsx\";\nimport { twMerge } from \"tailwind-merge\";\n\nexport function cn(...inputs: ClassValue[]) {\n return twMerge(clsx(inputs));\n}\n"]}
|
package/dist/alert.d.cts
DELETED
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import * as class_variance_authority_dist_types from 'class-variance-authority/dist/types';
|
|
2
|
-
import * as React from 'react';
|
|
3
|
-
import { VariantProps } from 'class-variance-authority';
|
|
4
|
-
|
|
5
|
-
declare const Alert: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & VariantProps<(props?: ({
|
|
6
|
-
variant?: "default" | "destructive" | null | undefined;
|
|
7
|
-
} & class_variance_authority_dist_types.ClassProp) | undefined) => string> & React.RefAttributes<HTMLDivElement>>;
|
|
8
|
-
declare const AlertTitle: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLHeadingElement> & React.RefAttributes<HTMLParagraphElement>>;
|
|
9
|
-
declare const AlertDescription: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLParagraphElement> & React.RefAttributes<HTMLParagraphElement>>;
|
|
10
|
-
|
|
11
|
-
export { Alert, AlertDescription, AlertTitle };
|
package/dist/alert.d.ts
DELETED
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import * as class_variance_authority_dist_types from 'class-variance-authority/dist/types';
|
|
2
|
-
import * as React from 'react';
|
|
3
|
-
import { VariantProps } from 'class-variance-authority';
|
|
4
|
-
|
|
5
|
-
declare const Alert: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & VariantProps<(props?: ({
|
|
6
|
-
variant?: "default" | "destructive" | null | undefined;
|
|
7
|
-
} & class_variance_authority_dist_types.ClassProp) | undefined) => string> & React.RefAttributes<HTMLDivElement>>;
|
|
8
|
-
declare const AlertTitle: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLHeadingElement> & React.RefAttributes<HTMLParagraphElement>>;
|
|
9
|
-
declare const AlertDescription: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLParagraphElement> & React.RefAttributes<HTMLParagraphElement>>;
|
|
10
|
-
|
|
11
|
-
export { Alert, AlertDescription, AlertTitle };
|
package/dist/alert.esm.js
DELETED
|
@@ -1,116 +0,0 @@
|
|
|
1
|
-
// src/alert.tsx
|
|
2
|
-
function _define_property(obj, key, value) {
|
|
3
|
-
if (key in obj) {
|
|
4
|
-
Object.defineProperty(obj, key, {
|
|
5
|
-
value: value,
|
|
6
|
-
enumerable: true,
|
|
7
|
-
configurable: true,
|
|
8
|
-
writable: true
|
|
9
|
-
});
|
|
10
|
-
} else {
|
|
11
|
-
obj[key] = value;
|
|
12
|
-
}
|
|
13
|
-
return obj;
|
|
14
|
-
}
|
|
15
|
-
function _object_spread(target) {
|
|
16
|
-
for(var i = 1; i < arguments.length; i++){
|
|
17
|
-
var source = arguments[i] != null ? arguments[i] : {};
|
|
18
|
-
var ownKeys = Object.keys(source);
|
|
19
|
-
if (typeof Object.getOwnPropertySymbols === "function") {
|
|
20
|
-
ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function(sym) {
|
|
21
|
-
return Object.getOwnPropertyDescriptor(source, sym).enumerable;
|
|
22
|
-
}));
|
|
23
|
-
}
|
|
24
|
-
ownKeys.forEach(function(key) {
|
|
25
|
-
_define_property(target, key, source[key]);
|
|
26
|
-
});
|
|
27
|
-
}
|
|
28
|
-
return target;
|
|
29
|
-
}
|
|
30
|
-
function _object_without_properties(source, excluded) {
|
|
31
|
-
if (source == null) return {};
|
|
32
|
-
var target = _object_without_properties_loose(source, excluded);
|
|
33
|
-
var key, i;
|
|
34
|
-
if (Object.getOwnPropertySymbols) {
|
|
35
|
-
var sourceSymbolKeys = Object.getOwnPropertySymbols(source);
|
|
36
|
-
for(i = 0; i < sourceSymbolKeys.length; i++){
|
|
37
|
-
key = sourceSymbolKeys[i];
|
|
38
|
-
if (excluded.indexOf(key) >= 0) continue;
|
|
39
|
-
if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
|
|
40
|
-
target[key] = source[key];
|
|
41
|
-
}
|
|
42
|
-
}
|
|
43
|
-
return target;
|
|
44
|
-
}
|
|
45
|
-
function _object_without_properties_loose(source, excluded) {
|
|
46
|
-
if (source == null) return {};
|
|
47
|
-
var target = {};
|
|
48
|
-
var sourceKeys = Object.keys(source);
|
|
49
|
-
var key, i;
|
|
50
|
-
for(i = 0; i < sourceKeys.length; i++){
|
|
51
|
-
key = sourceKeys[i];
|
|
52
|
-
if (excluded.indexOf(key) >= 0) continue;
|
|
53
|
-
target[key] = source[key];
|
|
54
|
-
}
|
|
55
|
-
return target;
|
|
56
|
-
}
|
|
57
|
-
import * as React from "react";
|
|
58
|
-
import { cva } from "class-variance-authority";
|
|
59
|
-
// ../utils/src/classMerge.ts
|
|
60
|
-
import { clsx } from "clsx";
|
|
61
|
-
import { twMerge } from "tailwind-merge";
|
|
62
|
-
function cn() {
|
|
63
|
-
for(var _len = arguments.length, inputs = new Array(_len), _key = 0; _key < _len; _key++){
|
|
64
|
-
inputs[_key] = arguments[_key];
|
|
65
|
-
}
|
|
66
|
-
return twMerge(clsx(inputs));
|
|
67
|
-
}
|
|
68
|
-
// src/alert.tsx
|
|
69
|
-
import { jsx } from "react/jsx-runtime";
|
|
70
|
-
var alertVariants = cva("relative w-full rounded-lg border px-4 py-3 text-sm [&>svg+div]:translate-y-[-3px] [&>svg]:absolute [&>svg]:left-4 [&>svg]:top-4 [&>svg]:text-foreground [&>svg~*]:pl-7", {
|
|
71
|
-
variants: {
|
|
72
|
-
variant: {
|
|
73
|
-
default: "bg-background text-foreground",
|
|
74
|
-
destructive: "border-destructive/50 text-destructive dark:border-destructive [&>svg]:text-destructive"
|
|
75
|
-
}
|
|
76
|
-
},
|
|
77
|
-
defaultVariants: {
|
|
78
|
-
variant: "default"
|
|
79
|
-
}
|
|
80
|
-
});
|
|
81
|
-
var Alert = React.forwardRef(function(_param, ref) {
|
|
82
|
-
var className = _param.className, variant = _param.variant, props = _object_without_properties(_param, [
|
|
83
|
-
"className",
|
|
84
|
-
"variant"
|
|
85
|
-
]);
|
|
86
|
-
return /* @__PURE__ */ jsx("div", _object_spread({
|
|
87
|
-
ref: ref,
|
|
88
|
-
role: "alert",
|
|
89
|
-
className: cn(alertVariants({
|
|
90
|
-
variant: variant
|
|
91
|
-
}), className)
|
|
92
|
-
}, props));
|
|
93
|
-
});
|
|
94
|
-
Alert.displayName = "Alert";
|
|
95
|
-
var AlertTitle = React.forwardRef(function(_param, ref) {
|
|
96
|
-
var className = _param.className, props = _object_without_properties(_param, [
|
|
97
|
-
"className"
|
|
98
|
-
]);
|
|
99
|
-
return /* @__PURE__ */ jsx("h5", _object_spread({
|
|
100
|
-
ref: ref,
|
|
101
|
-
className: cn("mb-1 font-medium leading-none tracking-tight", className)
|
|
102
|
-
}, props));
|
|
103
|
-
});
|
|
104
|
-
AlertTitle.displayName = "AlertTitle";
|
|
105
|
-
var AlertDescription = React.forwardRef(function(_param, ref) {
|
|
106
|
-
var className = _param.className, props = _object_without_properties(_param, [
|
|
107
|
-
"className"
|
|
108
|
-
]);
|
|
109
|
-
return /* @__PURE__ */ jsx("div", _object_spread({
|
|
110
|
-
ref: ref,
|
|
111
|
-
className: cn("text-sm [&_p]:leading-relaxed", className)
|
|
112
|
-
}, props));
|
|
113
|
-
});
|
|
114
|
-
AlertDescription.displayName = "AlertDescription";
|
|
115
|
-
export { Alert, AlertDescription, AlertTitle };
|
|
116
|
-
//# sourceMappingURL=alert.esm.js.map
|
package/dist/alert.esm.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["/Users/periotto/Desktop/workspace/c-rex.net-web-client-foundation/packages/ui/dist/alert.esm.js","../src/alert.tsx","../../utils/src/classMerge.ts"],"names":["React","cva","clsx","twMerge","cn","inputs","jsx","alertVariants","variants","variant","default","destructive","defaultVariants","Alert","forwardRef","ref","className","props","role","displayName","AlertTitle","AlertDescription"],"mappings":"AAAA,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;ACAhB,YAAYA,WAAW,QAAA;AACvB,SAASC,GAAA,QAA8B,2BAAA;ADGvC,6BAA6B;AEJ7B,SAASC,IAAA,QAA6B,OAAA;AACtC,SAASC,OAAA,QAAe,iBAAA;AAEjB,SAASC;IAAA,IAAA,IAAA,OAAA,UAAA,QAAA,AAAMC,SAAN,UAAA,OAAA,OAAA,GAAA,OAAA,MAAA;QAAMA,OAAN,QAAA,SAAA,CAAA,KAAM;;IAClB,OAAOF,QAAQD,KAAKG;AACxB;AFMA,gBAAgB;ACaZ,SAAAC,GAAA,QAAA,oBAAA;AApBJ,IAAMC,gBAAgBN,IAClB,2KACA;IACIO,UAAU;QACNC,SAAS;YACLC,SAAS;YACTC,aACI;QACR;IACJ;IACAC,iBAAiB;QACbH,SAAS;IACb;AACJ;AAGJ,IAAMI,QAAcb,MAAAc,UAAA,CAGlB,iBAAmCC;QAAhCC,mBAAAA,WAAWP,iBAAAA,SAAYQ;QAAvBD;QAAWP;;WACZ,aAAA,GAAAH,IAAC,OAAA;QACGS,KAAAA;QACAG,MAAK;QACLF,WAAWZ,GAAGG,cAAc;YAAEE,SAAAA;QAAQ,IAAIO;OACtCC;;AAGZJ,MAAMM,WAAA,GAAc;AAEpB,IAAMC,aAAmBpB,MAAAc,UAAA,CAGvB,iBAA0BC;QAAvBC,mBAAAA,WAAcC;QAAdD;;WACD,aAAA,GAAAV,IAAC,MAAA;QACGS,KAAAA;QACAC,WAAWZ,GAAG,gDAAgDY;OAC1DC;;AAGZG,WAAWD,WAAA,GAAc;AAEzB,IAAME,mBAAyBrB,MAAAc,UAAA,CAG7B,iBAA0BC;QAAvBC,mBAAAA,WAAcC;QAAdD;;WACD,aAAA,GAAAV,IAAC,OAAA;QACGS,KAAAA;QACAC,WAAWZ,GAAG,iCAAiCY;OAC3CC;;AAGZI,iBAAiBF,WAAA,GAAc;ADA/B,SACEN,KAAK,EACLQ,gBAAgB,EAChBD,UAAU,GACV","sourcesContent":["// src/alert.tsx\nimport * as React from \"react\";\nimport { cva } from \"class-variance-authority\";\n\n// ../utils/src/classMerge.ts\nimport { clsx } from \"clsx\";\nimport { twMerge } from \"tailwind-merge\";\nfunction cn(...inputs) {\n return twMerge(clsx(inputs));\n}\n\n// src/alert.tsx\nimport { jsx } from \"react/jsx-runtime\";\nvar alertVariants = cva(\n \"relative w-full rounded-lg border px-4 py-3 text-sm [&>svg+div]:translate-y-[-3px] [&>svg]:absolute [&>svg]:left-4 [&>svg]:top-4 [&>svg]:text-foreground [&>svg~*]:pl-7\",\n {\n variants: {\n variant: {\n default: \"bg-background text-foreground\",\n destructive: \"border-destructive/50 text-destructive dark:border-destructive [&>svg]:text-destructive\"\n }\n },\n defaultVariants: {\n variant: \"default\"\n }\n }\n);\nvar Alert = React.forwardRef(({ className, variant, ...props }, ref) => /* @__PURE__ */ jsx(\n \"div\",\n {\n ref,\n role: \"alert\",\n className: cn(alertVariants({ variant }), className),\n ...props\n }\n));\nAlert.displayName = \"Alert\";\nvar AlertTitle = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(\n \"h5\",\n {\n ref,\n className: cn(\"mb-1 font-medium leading-none tracking-tight\", className),\n ...props\n }\n));\nAlertTitle.displayName = \"AlertTitle\";\nvar AlertDescription = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(\n \"div\",\n {\n ref,\n className: cn(\"text-sm [&_p]:leading-relaxed\", className),\n ...props\n }\n));\nAlertDescription.displayName = \"AlertDescription\";\nexport {\n Alert,\n AlertDescription,\n AlertTitle\n};\n","import * as React from \"react\";\nimport { cva, type VariantProps } from \"class-variance-authority\";\nimport { cn } from \"@c-rex/utils\";\n\nconst alertVariants = cva(\n \"relative w-full rounded-lg border px-4 py-3 text-sm [&>svg+div]:translate-y-[-3px] [&>svg]:absolute [&>svg]:left-4 [&>svg]:top-4 [&>svg]:text-foreground [&>svg~*]:pl-7\",\n {\n variants: {\n variant: {\n default: \"bg-background text-foreground\",\n destructive:\n \"border-destructive/50 text-destructive dark:border-destructive [&>svg]:text-destructive\",\n },\n },\n defaultVariants: {\n variant: \"default\",\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes<HTMLDivElement> & VariantProps<typeof alertVariants>\n>(({ className, variant, ...props }, ref) => (\n <div\n ref={ref}\n role=\"alert\"\n className={cn(alertVariants({ variant }), className)}\n {...props}\n />\n));\nAlert.displayName = \"Alert\";\n\nconst AlertTitle = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes<HTMLHeadingElement>\n>(({ className, ...props }, ref) => (\n <h5\n ref={ref}\n className={cn(\"mb-1 font-medium leading-none tracking-tight\", className)}\n {...props}\n />\n));\nAlertTitle.displayName = \"AlertTitle\";\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes<HTMLParagraphElement>\n>(({ className, ...props }, ref) => (\n <div\n ref={ref}\n className={cn(\"text-sm [&_p]:leading-relaxed\", className)}\n {...props}\n />\n));\nAlertDescription.displayName = \"AlertDescription\";\n\nexport { Alert, AlertTitle, AlertDescription };\n","import { clsx, type ClassValue } from \"clsx\";\nimport { twMerge } from \"tailwind-merge\";\n\nexport function cn(...inputs: ClassValue[]) {\n return twMerge(clsx(inputs));\n}\n"]}
|