@code0-tech/pictor 0.2.3 → 0.4.0
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/dist/_virtual/compiler-runtime.js +5 -0
- package/dist/_virtual/compiler-runtime2.js +4 -0
- package/dist/_virtual/react-compiler-runtime.development.js +4 -0
- package/dist/_virtual/react-compiler-runtime.production.js +4 -0
- package/dist/assets/components/alert/Alert.style.css +1 -0
- package/dist/assets/components/aurora/Aurora.style.css +1 -0
- package/dist/assets/components/avatar/Avatar.style.css +1 -0
- package/dist/assets/components/badge/Badge.style.css +1 -0
- package/dist/assets/components/breadcrumb/Breadcrumb.style.css +1 -0
- package/dist/assets/components/button/Button.style.css +1 -0
- package/dist/assets/components/button-group/ButtonGroup.style.css +1 -0
- package/dist/assets/components/card/Card.style.css +1 -0
- package/dist/assets/components/col/Col.style.css +1 -0
- package/dist/assets/components/command/Command.style.css +1 -0
- package/dist/assets/components/container/Container.style.css +1 -0
- package/dist/assets/components/context-menu/ContextMenu.style.css +1 -0
- package/dist/assets/components/data-table/DataTable.style.css +1 -0
- package/dist/assets/components/dialog/Dialog.style.css +1 -0
- package/dist/assets/components/editor/Editor.styles.css +1 -0
- package/dist/assets/components/file-tabs/FileTabs.style.css +1 -0
- package/dist/assets/components/flex/Flex.style.css +1 -0
- package/dist/assets/components/form/Input.style.css +1 -0
- package/dist/assets/components/fullscreen/FullScreen.style.css +1 -0
- package/dist/assets/components/layout/Layout.style.css +1 -0
- package/dist/assets/components/menu/Menu.style.css +1 -0
- package/dist/assets/components/quote/Quote.style.css +1 -0
- package/dist/assets/components/resizable/Resizable.style.css +1 -0
- package/dist/assets/components/row/Row.style.css +1 -0
- package/dist/assets/components/scroll-area/ScrollArea.style.css +1 -0
- package/dist/assets/components/segmented-control/SegmentedControl.style.css +1 -0
- package/dist/assets/components/spacing/Spacing.style.css +1 -0
- package/dist/assets/components/tab/Tab.style.css +1 -0
- package/dist/assets/components/text/Text.style.css +1 -0
- package/dist/assets/components/toast/Toast.style.css +1 -0
- package/dist/assets/components/tooltip/Tooltip.style.css +1 -0
- package/dist/components/alert/Alert.d.ts +7 -0
- package/dist/components/alert/Alert.js +39 -0
- package/dist/components/aurora/Aurora.d.ts +5 -0
- package/dist/components/aurora/Aurora.js +23 -0
- package/dist/components/avatar/Avatar.d.ts +10 -0
- package/dist/components/avatar/Avatar.js +53 -0
- package/dist/components/badge/Badge.d.ts +8 -0
- package/dist/components/badge/Badge.js +63 -0
- package/dist/components/breadcrumb/Breadcrumb.d.ts +7 -0
- package/dist/components/breadcrumb/Breadcrumb.js +19 -0
- package/dist/components/button/Button.d.ts +11 -0
- package/dist/components/button/Button.js +31 -0
- package/dist/components/button-group/ButtonGroup.d.ts +8 -0
- package/dist/components/button-group/ButtonGroup.js +28 -0
- package/dist/components/card/Card.d.ts +15 -0
- package/dist/components/card/Card.js +42 -0
- package/dist/components/card/CardSection.d.ts +10 -0
- package/dist/components/card/CardSection.js +28 -0
- package/dist/{esm/components → components}/col/Col.d.ts +3 -5
- package/dist/components/col/Col.js +27 -0
- package/dist/components/command/Command.d.ts +30 -0
- package/dist/components/command/Command.js +103 -0
- package/dist/components/container/Container.d.ts +6 -0
- package/dist/components/container/Container.js +21 -0
- package/dist/components/context-menu/ContextMenu.d.ts +31 -0
- package/dist/components/context-menu/ContextMenu.js +106 -0
- package/dist/components/data-table/DataTable.d.ts +23 -0
- package/dist/components/data-table/DataTable.js +41 -0
- package/dist/components/data-table/DataTableColumn.d.ts +6 -0
- package/dist/components/data-table/DataTableColumn.js +22 -0
- package/dist/components/data-table/DataTableFilterInput.d.ts +18 -0
- package/dist/components/data-table/DataTableFilterInput.js +212 -0
- package/dist/components/data-table/DataTableFilterSuggestionMenu.d.ts +7 -0
- package/dist/components/data-table/DataTableFilterSuggestionMenu.js +53 -0
- package/dist/components/data-table/index.d.ts +4 -0
- package/dist/components/data-table/index.js +11 -0
- package/dist/components/dialog/Dialog.d.ts +29 -0
- package/dist/components/dialog/Dialog.js +102 -0
- package/dist/components/editor/Editor.d.ts +29 -0
- package/dist/components/editor/Editor.js +337 -0
- package/dist/components/file-tabs/FileTabs.d.ts +17 -0
- package/dist/components/file-tabs/FileTabs.js +71 -0
- package/dist/components/file-tabs/FileTabs.service.d.ts +17 -0
- package/dist/components/file-tabs/FileTabs.service.js +88 -0
- package/dist/components/file-tabs/FileTabs.view.d.ts +10 -0
- package/dist/components/file-tabs/FileTabs.view.js +1 -0
- package/dist/components/file-tabs/index.d.ts +3 -0
- package/dist/components/file-tabs/index.js +9 -0
- package/dist/components/flex/Flex.d.ts +7 -0
- package/dist/components/flex/Flex.js +21 -0
- package/dist/components/form/CheckboxInput.d.ts +5 -0
- package/dist/components/form/CheckboxInput.js +76 -0
- package/dist/components/form/EmailInput.d.ts +8 -0
- package/dist/components/form/EmailInput.js +21 -0
- package/dist/components/form/Input.d.ts +35 -0
- package/dist/components/form/Input.js +434 -0
- package/dist/components/form/Input.syntax.hook.d.ts +10 -0
- package/dist/components/form/Input.syntax.hook.js +14 -0
- package/dist/components/form/Input.utils.d.ts +10 -0
- package/dist/components/form/Input.utils.js +38 -0
- package/dist/components/form/InputContentEditable.hook.d.ts +52 -0
- package/dist/components/form/InputContentEditable.hook.js +449 -0
- package/dist/components/form/InputDescription.d.ts +5 -0
- package/dist/components/form/InputDescription.js +12 -0
- package/dist/components/form/InputLabel.d.ts +5 -0
- package/dist/components/form/InputLabel.js +12 -0
- package/dist/components/form/InputMessage.d.ts +5 -0
- package/dist/components/form/InputMessage.js +18 -0
- package/dist/components/form/InputSuggestion.d.ts +27 -0
- package/dist/components/form/InputSuggestion.js +218 -0
- package/dist/components/form/NumberInput.d.ts +6 -0
- package/dist/components/form/NumberInput.js +20 -0
- package/dist/components/form/PasswordInput.d.ts +8 -0
- package/dist/components/form/PasswordInput.js +19 -0
- package/dist/components/form/PinInput.d.ts +11 -0
- package/dist/components/form/PinInput.js +66 -0
- package/dist/components/form/RadioGroup.d.ts +5 -0
- package/dist/components/form/RadioGroup.js +48 -0
- package/dist/components/form/RadioInput.d.ts +7 -0
- package/dist/components/form/RadioInput.js +27 -0
- package/dist/components/form/SwitchInput.d.ts +6 -0
- package/dist/components/form/SwitchInput.js +19 -0
- package/dist/components/form/TextAreaInput.d.ts +7 -0
- package/dist/components/form/TextAreaInput.js +20 -0
- package/dist/components/form/TextInput.d.ts +7 -0
- package/dist/components/form/TextInput.js +20 -0
- package/dist/components/form/index.d.ts +17 -0
- package/dist/components/form/index.js +40 -0
- package/dist/components/form/useForm.d.ts +30 -0
- package/dist/components/form/useForm.js +78 -0
- package/dist/components/fullscreen/FullScreen.d.ts +6 -0
- package/dist/components/fullscreen/FullScreen.js +26 -0
- package/dist/components/layout/Layout.d.ts +12 -0
- package/dist/components/layout/Layout.js +75 -0
- package/dist/components/menu/Menu.d.ts +35 -0
- package/dist/components/menu/Menu.js +120 -0
- package/dist/components/quote/Quote.d.ts +10 -0
- package/dist/components/quote/Quote.js +44 -0
- package/dist/components/resizable/Resizable.d.ts +12 -0
- package/dist/components/resizable/Resizable.js +34 -0
- package/dist/components/row/Row.d.ts +6 -0
- package/dist/components/row/Row.js +21 -0
- package/dist/components/scroll-area/ScrollArea.d.ts +13 -0
- package/dist/components/scroll-area/ScrollArea.js +43 -0
- package/dist/components/segmented-control/SegmentedControl.d.ts +10 -0
- package/dist/components/segmented-control/SegmentedControl.js +26 -0
- package/dist/components/spacing/Spacing.d.ts +6 -0
- package/dist/components/spacing/Spacing.js +23 -0
- package/dist/components/tab/Tab.d.ts +11 -0
- package/dist/components/tab/Tab.js +40 -0
- package/dist/components/text/Text.d.ts +8 -0
- package/dist/components/text/Text.js +23 -0
- package/dist/components/toast/Toast.d.ts +13 -0
- package/dist/components/toast/Toast.js +66 -0
- package/dist/components/tooltip/Tooltip.d.ts +17 -0
- package/dist/components/tooltip/Tooltip.js +48 -0
- package/dist/index.d.ts +33 -300
- package/dist/index.js +191 -0
- package/dist/node_modules/@lezer/common/dist/index.js +146 -0
- package/dist/node_modules/@lezer/highlight/dist/index.js +543 -0
- package/dist/node_modules/prettier/plugins/babel.js +7157 -0
- package/dist/node_modules/prettier/plugins/estree.js +4453 -0
- package/dist/node_modules/prettier/standalone.js +2429 -0
- package/dist/node_modules/react/cjs/react-compiler-runtime.development.js +21 -0
- package/dist/node_modules/react/cjs/react-compiler-runtime.production.js +14 -0
- package/dist/node_modules/react/compiler-runtime.js +10 -0
- package/dist/utils/arrayService.d.ts +10 -0
- package/dist/utils/arrayService.js +1 -0
- package/dist/utils/contextStore.d.ts +62 -0
- package/dist/utils/contextStore.js +60 -0
- package/dist/utils/index.d.ts +8 -0
- package/dist/utils/index.js +25 -0
- package/dist/utils/inspection.d.ts +15 -0
- package/dist/utils/inspection.js +29 -0
- package/dist/utils/nonReactiveArrayService.d.ts +19 -0
- package/dist/utils/nonReactiveArrayService.js +54 -0
- package/dist/utils/objectStore.d.ts +12 -0
- package/dist/utils/objectStore.js +34 -0
- package/dist/utils/reactiveArrayService.d.ts +23 -0
- package/dist/utils/reactiveArrayService.js +90 -0
- package/dist/{cjs/utils → utils}/types.d.ts +4 -4
- package/dist/utils/types.js +4 -0
- package/dist/utils/utils.d.ts +55 -0
- package/dist/utils/utils.js +159 -0
- package/dist/utils/view.d.ts +8 -0
- package/dist/utils/view.js +28 -0
- package/package.json +130 -54
- package/dist/cjs/components/Text/Text.d.ts +0 -10
- package/dist/cjs/components/alert/Alert.d.ts +0 -16
- package/dist/cjs/components/badge/Badge.d.ts +0 -9
- package/dist/cjs/components/button/Button.d.ts +0 -17
- package/dist/cjs/components/button-group/ButtonGroup.d.ts +0 -9
- package/dist/cjs/components/card/Card.d.ts +0 -20
- package/dist/cjs/components/col/Col.d.ts +0 -15
- package/dist/cjs/components/container/Container.d.ts +0 -8
- package/dist/cjs/components/dropdown/Dropdown.d.ts +0 -24
- package/dist/cjs/components/dropdown/DropdownFooter.d.ts +0 -13
- package/dist/cjs/components/dropdown/DropdownHeader.d.ts +0 -13
- package/dist/cjs/components/dropdown/DropdownItem.d.ts +0 -12
- package/dist/cjs/components/dropdown/DropdownItemGroup.d.ts +0 -12
- package/dist/cjs/components/input/Input.d.ts +0 -37
- package/dist/cjs/components/list-group/ListGroup.d.ts +0 -12
- package/dist/cjs/components/menu/InternalMenu.d.ts +0 -4
- package/dist/cjs/components/menu/Menu.d.ts +0 -41
- package/dist/cjs/components/popover/InternalPopover.d.ts +0 -10
- package/dist/cjs/components/popover/Popover.d.ts +0 -16
- package/dist/cjs/components/quote/Quote.d.ts +0 -12
- package/dist/cjs/components/row/Row.d.ts +0 -8
- package/dist/cjs/components/tooltip/Tooltip.d.ts +0 -18
- package/dist/cjs/index.d.ts +0 -16
- package/dist/cjs/index.js +0 -9275
- package/dist/cjs/utils/utils.d.ts +0 -18
- package/dist/esm/components/Text/Text.d.ts +0 -10
- package/dist/esm/components/alert/Alert.d.ts +0 -16
- package/dist/esm/components/badge/Badge.d.ts +0 -9
- package/dist/esm/components/button/Button.d.ts +0 -17
- package/dist/esm/components/button-group/ButtonGroup.d.ts +0 -9
- package/dist/esm/components/card/Card.d.ts +0 -20
- package/dist/esm/components/container/Container.d.ts +0 -8
- package/dist/esm/components/dropdown/Dropdown.d.ts +0 -24
- package/dist/esm/components/dropdown/DropdownFooter.d.ts +0 -13
- package/dist/esm/components/dropdown/DropdownHeader.d.ts +0 -13
- package/dist/esm/components/dropdown/DropdownItem.d.ts +0 -12
- package/dist/esm/components/dropdown/DropdownItemGroup.d.ts +0 -12
- package/dist/esm/components/input/Input.d.ts +0 -37
- package/dist/esm/components/list-group/ListGroup.d.ts +0 -12
- package/dist/esm/components/menu/InternalMenu.d.ts +0 -4
- package/dist/esm/components/menu/Menu.d.ts +0 -41
- package/dist/esm/components/popover/InternalPopover.d.ts +0 -10
- package/dist/esm/components/popover/Popover.d.ts +0 -16
- package/dist/esm/components/quote/Quote.d.ts +0 -12
- package/dist/esm/components/row/Row.d.ts +0 -8
- package/dist/esm/components/tooltip/Tooltip.d.ts +0 -18
- package/dist/esm/index.d.ts +0 -16
- package/dist/esm/index.js +0 -9251
- package/dist/esm/utils/types.d.ts +0 -57
- package/dist/esm/utils/utils.d.ts +0 -18
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import { jsx as o } from "react/jsx-runtime";
|
|
2
|
+
import { c as n } from "../../_virtual/compiler-runtime.js";
|
|
3
|
+
import "../../utils/contextStore.js";
|
|
4
|
+
import "react";
|
|
5
|
+
import { mergeCode0Props as r } from "../../utils/utils.js";
|
|
6
|
+
import { Tabs as c, Content as m, List as b, Trigger as f } from "@radix-ui/react-tabs";
|
|
7
|
+
import '../../assets/components/tab/Tab.style.css';/* empty css */
|
|
8
|
+
const x = (a) => {
|
|
9
|
+
const t = n.c(4);
|
|
10
|
+
let e;
|
|
11
|
+
t[0] !== a ? (e = r("tab", a), t[0] = a, t[1] = e) : e = t[1];
|
|
12
|
+
let l;
|
|
13
|
+
return t[2] !== e ? (l = /* @__PURE__ */ o(c, { "data-slot": "tabs", ...e }), t[2] = e, t[3] = l) : l = t[3], l;
|
|
14
|
+
}, C = (a) => {
|
|
15
|
+
const t = n.c(4);
|
|
16
|
+
let e;
|
|
17
|
+
t[0] !== a ? (e = r("tab__list", a), t[0] = a, t[1] = e) : e = t[1];
|
|
18
|
+
let l;
|
|
19
|
+
return t[2] !== e ? (l = /* @__PURE__ */ o(b, { "data-slot": "tabs", ...e }), t[2] = e, t[3] = l) : l = t[3], l;
|
|
20
|
+
}, L = (a) => {
|
|
21
|
+
const t = n.c(5), e = a.value;
|
|
22
|
+
let l;
|
|
23
|
+
t[0] !== a ? (l = r("tab__trigger", a), t[0] = a, t[1] = l) : l = t[1];
|
|
24
|
+
const s = l;
|
|
25
|
+
let i;
|
|
26
|
+
return t[2] !== a.value || t[3] !== s ? (i = /* @__PURE__ */ o(f, { "data-slot": "tabs", "data-value": e, ...s }), t[2] = a.value, t[3] = s, t[4] = i) : i = t[4], i;
|
|
27
|
+
}, j = (a) => {
|
|
28
|
+
const t = n.c(4);
|
|
29
|
+
let e;
|
|
30
|
+
t[0] !== a ? (e = r("tab__content", a), t[0] = a, t[1] = e) : e = t[1];
|
|
31
|
+
const l = e;
|
|
32
|
+
let s;
|
|
33
|
+
return t[2] !== l ? (s = /* @__PURE__ */ o(m, { "data-slot": "tabs", ...l }), t[2] = l, t[3] = s) : s = t[3], s;
|
|
34
|
+
};
|
|
35
|
+
export {
|
|
36
|
+
x as Tab,
|
|
37
|
+
j as TabContent,
|
|
38
|
+
C as TabList,
|
|
39
|
+
L as TabTrigger
|
|
40
|
+
};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { Code0Component, Code0Sizes } from '../../utils/types';
|
|
3
|
+
export interface FontType extends Omit<Omit<Code0Component<HTMLSpanElement>, "children">, "size"> {
|
|
4
|
+
children: React.ReactNode;
|
|
5
|
+
size?: Code0Sizes;
|
|
6
|
+
hierarchy?: "primary" | "secondary" | "tertiary";
|
|
7
|
+
}
|
|
8
|
+
export declare const Text: React.FC<FontType>;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { jsx as p } from "react/jsx-runtime";
|
|
2
|
+
import { c as h } from "../../_virtual/compiler-runtime.js";
|
|
3
|
+
import '../../assets/components/text/Text.style.css';/* empty css */
|
|
4
|
+
import { mergeCode0Props as l } from "../../utils/utils.js";
|
|
5
|
+
const $ = (i) => {
|
|
6
|
+
const e = h.c(6);
|
|
7
|
+
let t, r;
|
|
8
|
+
if (e[0] !== i) {
|
|
9
|
+
const {
|
|
10
|
+
size: s,
|
|
11
|
+
children: m,
|
|
12
|
+
hierarchy: c,
|
|
13
|
+
...n
|
|
14
|
+
} = i;
|
|
15
|
+
t = m, r = l(`text text--${c === void 0 ? "secondary" : c} text--${s === void 0 ? "sm" : s}`, n), e[0] = i, e[1] = t, e[2] = r;
|
|
16
|
+
} else
|
|
17
|
+
t = e[1], r = e[2];
|
|
18
|
+
let o;
|
|
19
|
+
return e[3] !== t || e[4] !== r ? (o = /* @__PURE__ */ p("span", { ...r, children: t }), e[3] = t, e[4] = r, e[5] = o) : o = e[5], o;
|
|
20
|
+
};
|
|
21
|
+
export {
|
|
22
|
+
$ as Text
|
|
23
|
+
};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { Code0Component, Color } from '../../utils';
|
|
3
|
+
export interface ToastProps extends Omit<Code0Component<HTMLDivElement>, "title" | "id"> {
|
|
4
|
+
children?: React.ReactNode | React.ReactNode[];
|
|
5
|
+
id: string | number;
|
|
6
|
+
title: React.ReactNode;
|
|
7
|
+
color?: Color;
|
|
8
|
+
dismissible?: boolean;
|
|
9
|
+
onClose?: (event: React.MouseEvent<HTMLSpanElement, MouseEvent>) => void;
|
|
10
|
+
duration?: number;
|
|
11
|
+
}
|
|
12
|
+
export declare function toast(toast: Omit<ToastProps, 'id'>): string | number;
|
|
13
|
+
export declare function Toast(props: ToastProps): React.JSX.Element;
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
import { jsxs as r, jsx as s } from "react/jsx-runtime";
|
|
2
|
+
import { c as p } from "../../_virtual/compiler-runtime.js";
|
|
3
|
+
import { toast as d } from "sonner";
|
|
4
|
+
import '../../assets/components/toast/Toast.style.css';/* empty css */
|
|
5
|
+
import "../../utils/contextStore.js";
|
|
6
|
+
import "react";
|
|
7
|
+
import { mergeCode0Props as f } from "../../utils/utils.js";
|
|
8
|
+
import { IconX as u, IconCircleX as N, IconAlertCircle as y, IconCircleCheck as z, IconInfoCircle as C, IconCircleDot as a } from "@tabler/icons-react";
|
|
9
|
+
import { Text as c } from "../text/Text.js";
|
|
10
|
+
import { Flex as n } from "../flex/Flex.js";
|
|
11
|
+
import { Button as x } from "../button/Button.js";
|
|
12
|
+
function D(o) {
|
|
13
|
+
return d.custom((e) => /* @__PURE__ */ s(I, { id: e, ...o, children: o.children }), {
|
|
14
|
+
duration: o.duration ?? 4e3
|
|
15
|
+
});
|
|
16
|
+
}
|
|
17
|
+
function I(o) {
|
|
18
|
+
const {
|
|
19
|
+
dismissible: e = !1,
|
|
20
|
+
color: i = "secondary",
|
|
21
|
+
title: t,
|
|
22
|
+
onClose: _ = () => {
|
|
23
|
+
},
|
|
24
|
+
children: l,
|
|
25
|
+
duration: m = 4e3,
|
|
26
|
+
...h
|
|
27
|
+
} = o;
|
|
28
|
+
return /* @__PURE__ */ r("div", { ...f(`toast toast--${i}`, h), children: [
|
|
29
|
+
/* @__PURE__ */ r(n, { className: "toast__header", children: [
|
|
30
|
+
/* @__PURE__ */ r(n, { className: "toast__header-wrapper", children: [
|
|
31
|
+
i && /* @__PURE__ */ s(g, { color: i }),
|
|
32
|
+
/* @__PURE__ */ s(c, { size: "md", children: t })
|
|
33
|
+
] }),
|
|
34
|
+
e && /* @__PURE__ */ s(x, { variant: "none", paddingSize: "xxs", color: i, className: "toast__dismissible", onClick: () => d.dismiss(o.id), children: /* @__PURE__ */ s(u, { size: 16 }) })
|
|
35
|
+
] }),
|
|
36
|
+
l && /* @__PURE__ */ s("div", { className: "toast__content", children: l }),
|
|
37
|
+
/* @__PURE__ */ r(n, { className: "toast__duration", style: {
|
|
38
|
+
"--toast-duration": `${m}ms`
|
|
39
|
+
}, children: [
|
|
40
|
+
/* @__PURE__ */ s(c, { hierarchy: "tertiary", children: "This message will close in" }),
|
|
41
|
+
" ",
|
|
42
|
+
/* @__PURE__ */ s(c, { hierarchy: "primary", children: m / 1e3 }),
|
|
43
|
+
" ",
|
|
44
|
+
/* @__PURE__ */ s(c, { children: "seconds" })
|
|
45
|
+
] })
|
|
46
|
+
] });
|
|
47
|
+
}
|
|
48
|
+
const g = (o) => {
|
|
49
|
+
const e = p.c(1), {
|
|
50
|
+
color: i
|
|
51
|
+
} = o;
|
|
52
|
+
let t;
|
|
53
|
+
return e[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t = {
|
|
54
|
+
primary: /* @__PURE__ */ s(a, { className: "toast__icon", size: 16 }),
|
|
55
|
+
secondary: /* @__PURE__ */ s(a, { className: "toast__icon", size: 16 }),
|
|
56
|
+
tertiary: /* @__PURE__ */ s(a, { className: "toast__icon", size: 16 }),
|
|
57
|
+
info: /* @__PURE__ */ s(C, { className: "toast__icon", size: 16 }),
|
|
58
|
+
success: /* @__PURE__ */ s(z, { className: "toast__icon", size: 16 }),
|
|
59
|
+
warning: /* @__PURE__ */ s(y, { className: "toast__icon", size: 16 }),
|
|
60
|
+
error: /* @__PURE__ */ s(N, { className: "toast__icon", size: 16 })
|
|
61
|
+
}, e[0] = t) : t = e[0], t[i] ?? null;
|
|
62
|
+
};
|
|
63
|
+
export {
|
|
64
|
+
I as Toast,
|
|
65
|
+
D as toast
|
|
66
|
+
};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { Code0ComponentProps, Color } from '../../utils/types';
|
|
3
|
+
import * as RadixTooltip from "@radix-ui/react-tooltip";
|
|
4
|
+
export type TooltipProps = Code0ComponentProps & RadixTooltip.TooltipProps;
|
|
5
|
+
export type TooltipTriggerProps = Code0ComponentProps & RadixTooltip.TooltipTriggerProps;
|
|
6
|
+
export type TooltipPortalProps = Code0ComponentProps & RadixTooltip.TooltipPortalProps;
|
|
7
|
+
export type TooltipContentProps = Code0ComponentProps & RadixTooltip.TooltipContentProps & {
|
|
8
|
+
color?: Color;
|
|
9
|
+
};
|
|
10
|
+
export type TooltipArrowProps = Code0ComponentProps & RadixTooltip.TooltipArrowProps & {
|
|
11
|
+
color?: Color;
|
|
12
|
+
};
|
|
13
|
+
export declare const Tooltip: React.FC<TooltipProps>;
|
|
14
|
+
export declare const TooltipTrigger: React.FC<TooltipTriggerProps>;
|
|
15
|
+
export declare const TooltipPortal: React.FC<TooltipPortalProps>;
|
|
16
|
+
export declare const TooltipContent: React.FC<TooltipContentProps>;
|
|
17
|
+
export declare const TooltipArrow: React.FC<TooltipArrowProps>;
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import { jsx as r } from "react/jsx-runtime";
|
|
2
|
+
import { c as s } from "../../_virtual/compiler-runtime.js";
|
|
3
|
+
import * as c from "@radix-ui/react-tooltip";
|
|
4
|
+
import { mergeCode0Props as a } from "../../utils/utils.js";
|
|
5
|
+
import '../../assets/components/tooltip/Tooltip.style.css';/* empty css */
|
|
6
|
+
const u = (o) => {
|
|
7
|
+
const t = s.c(4);
|
|
8
|
+
let l;
|
|
9
|
+
t[0] !== o ? (l = a("tooltip", o), t[0] = o, t[1] = l) : l = t[1];
|
|
10
|
+
const i = l;
|
|
11
|
+
let e;
|
|
12
|
+
return t[2] !== i ? (e = /* @__PURE__ */ r(c.TooltipProvider, { delayDuration: 0, children: /* @__PURE__ */ r(c.Tooltip, { ...i }) }), t[2] = i, t[3] = e) : e = t[3], e;
|
|
13
|
+
}, $ = (o) => {
|
|
14
|
+
const t = s.c(4);
|
|
15
|
+
let l;
|
|
16
|
+
t[0] !== o ? (l = a("tooltip__trigger", o), t[0] = o, t[1] = l) : l = t[1];
|
|
17
|
+
const i = l;
|
|
18
|
+
let e;
|
|
19
|
+
return t[2] !== i ? (e = /* @__PURE__ */ r(c.TooltipTrigger, { ...i }), t[2] = i, t[3] = e) : e = t[3], e;
|
|
20
|
+
}, d = (o) => {
|
|
21
|
+
const t = s.c(4);
|
|
22
|
+
let l;
|
|
23
|
+
t[0] !== o ? (l = a("tooltip__portal", o), t[0] = o, t[1] = l) : l = t[1];
|
|
24
|
+
const i = l;
|
|
25
|
+
let e;
|
|
26
|
+
return t[2] !== i ? (e = /* @__PURE__ */ r(c.TooltipPortal, { ...i }), t[2] = i, t[3] = e) : e = t[3], e;
|
|
27
|
+
}, w = (o) => {
|
|
28
|
+
const t = s.c(6), l = o.align, i = `tooltip__content tooltip__content--${o.color ?? "tertiary"}`;
|
|
29
|
+
let e;
|
|
30
|
+
t[0] !== o || t[1] !== i ? (e = a(i, o), t[0] = o, t[1] = i, t[2] = e) : e = t[2];
|
|
31
|
+
const n = e;
|
|
32
|
+
let f;
|
|
33
|
+
return t[3] !== o.align || t[4] !== n ? (f = /* @__PURE__ */ r(c.TooltipContent, { align: l, ...n }), t[3] = o.align, t[4] = n, t[5] = f) : f = t[5], f;
|
|
34
|
+
}, x = (o) => {
|
|
35
|
+
const t = s.c(5), l = `tooltip__arrow tooltip__arrow--${o.color ?? "tertiary"}}`;
|
|
36
|
+
let i;
|
|
37
|
+
t[0] !== o || t[1] !== l ? (i = a(l, o), t[0] = o, t[1] = l, t[2] = i) : i = t[2];
|
|
38
|
+
const e = i;
|
|
39
|
+
let n;
|
|
40
|
+
return t[3] !== e ? (n = /* @__PURE__ */ r(c.TooltipArrow, { ...e }), t[3] = e, t[4] = n) : n = t[4], n;
|
|
41
|
+
};
|
|
42
|
+
export {
|
|
43
|
+
u as Tooltip,
|
|
44
|
+
x as TooltipArrow,
|
|
45
|
+
w as TooltipContent,
|
|
46
|
+
d as TooltipPortal,
|
|
47
|
+
$ as TooltipTrigger
|
|
48
|
+
};
|
package/dist/index.d.ts
CHANGED
|
@@ -1,300 +1,33 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
fs?: StyleProp<React.CSSProperties['fontStyle']>;
|
|
35
|
-
tt?: StyleProp<React.CSSProperties['textTransform']>;
|
|
36
|
-
td?: StyleProp<React.CSSProperties['textDecoration']>;
|
|
37
|
-
w?: StyleProp<React.CSSProperties['width']>;
|
|
38
|
-
miw?: StyleProp<React.CSSProperties['minWidth']>;
|
|
39
|
-
maw?: StyleProp<React.CSSProperties['maxWidth']>;
|
|
40
|
-
h?: StyleProp<React.CSSProperties['height']>;
|
|
41
|
-
mih?: StyleProp<React.CSSProperties['minHeight']>;
|
|
42
|
-
mah?: StyleProp<React.CSSProperties['maxHeight']>;
|
|
43
|
-
bgsz?: StyleProp<React.CSSProperties['backgroundSize']>;
|
|
44
|
-
bgp?: StyleProp<React.CSSProperties['backgroundPosition']>;
|
|
45
|
-
bgr?: StyleProp<React.CSSProperties['backgroundRepeat']>;
|
|
46
|
-
bga?: StyleProp<React.CSSProperties['backgroundAttachment']>;
|
|
47
|
-
pos?: StyleProp<React.CSSProperties['position']>;
|
|
48
|
-
top?: StyleProp<React.CSSProperties['top']>;
|
|
49
|
-
left?: StyleProp<React.CSSProperties['left']>;
|
|
50
|
-
bottom?: StyleProp<React.CSSProperties['bottom']>;
|
|
51
|
-
right?: StyleProp<React.CSSProperties['right']>;
|
|
52
|
-
inset?: StyleProp<React.CSSProperties['inset']>;
|
|
53
|
-
display?: StyleProp<React.CSSProperties['display']>;
|
|
54
|
-
flex?: StyleProp<React.CSSProperties['flex']>;
|
|
55
|
-
align?: StyleProp<React.CSSProperties['alignItems']>;
|
|
56
|
-
justify?: StyleProp<React.CSSProperties['justifyContent']>;
|
|
57
|
-
tf?: StyleProp<React.CSSProperties['transform']>;
|
|
58
|
-
}
|
|
59
|
-
interface Code0Component<T> extends Code0ComponentProps, HTMLProps<T> {
|
|
60
|
-
}
|
|
61
|
-
|
|
62
|
-
interface AlertType extends Omit<Code0Component<HTMLDivElement>, "title"> {
|
|
63
|
-
children?: ReactNode | ReactNode[];
|
|
64
|
-
title: ReactNode;
|
|
65
|
-
color?: Color;
|
|
66
|
-
icon?: boolean;
|
|
67
|
-
dismissible?: boolean;
|
|
68
|
-
onClose?: (event: React.MouseEvent<HTMLSpanElement, MouseEvent>) => void;
|
|
69
|
-
}
|
|
70
|
-
declare const Alert: React.FC<AlertType>;
|
|
71
|
-
|
|
72
|
-
interface BadgeType extends Code0Component<HTMLSpanElement> {
|
|
73
|
-
children: string;
|
|
74
|
-
color?: Color;
|
|
75
|
-
}
|
|
76
|
-
declare const Badge: React.FC<BadgeType>;
|
|
77
|
-
|
|
78
|
-
interface ButtonType extends Code0Component<HTMLAnchorElement> {
|
|
79
|
-
children: ReactNode | ReactNode[];
|
|
80
|
-
color?: Color;
|
|
81
|
-
variant?: "none" | "normal" | "outlined" | "filled";
|
|
82
|
-
active?: boolean;
|
|
83
|
-
disabled?: boolean;
|
|
84
|
-
}
|
|
85
|
-
interface ButtonIconType extends Code0Component<HTMLSpanElement> {
|
|
86
|
-
children: ReactNode;
|
|
87
|
-
}
|
|
88
|
-
declare const _default$7: React.FC<ButtonType> & {
|
|
89
|
-
Icon: React.FC<ButtonIconType>;
|
|
90
|
-
};
|
|
91
|
-
|
|
92
|
-
interface ButtonGroupType extends Code0Component<HTMLDivElement> {
|
|
93
|
-
children: ReactElement<ButtonType>[];
|
|
94
|
-
}
|
|
95
|
-
declare const ButtonGroup: React.FC<ButtonGroupType>;
|
|
96
|
-
|
|
97
|
-
interface CardType extends Code0Component<HTMLDivElement> {
|
|
98
|
-
children: ReactNode | ReactNode[];
|
|
99
|
-
color?: Color;
|
|
100
|
-
variant?: "none" | "normal" | "outlined" | "filled";
|
|
101
|
-
gradient?: boolean;
|
|
102
|
-
gradientPosition?: "top-left" | "top-right" | "bottom-right" | "bottom-left";
|
|
103
|
-
outline?: boolean;
|
|
104
|
-
}
|
|
105
|
-
interface SectionType extends Code0Component<HTMLDivElement> {
|
|
106
|
-
children: ReactNode | ReactNode[];
|
|
107
|
-
image?: boolean;
|
|
108
|
-
border?: boolean;
|
|
109
|
-
}
|
|
110
|
-
declare const _default$6: React.FC<CardType> & {
|
|
111
|
-
Section: React.FC<SectionType>;
|
|
112
|
-
};
|
|
113
|
-
|
|
114
|
-
type ColBreakPointRange = 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12;
|
|
115
|
-
interface ColType extends Code0Component<HTMLDivElement> {
|
|
116
|
-
children: ReactNode | ReactNode[];
|
|
117
|
-
xs?: ColBreakPointRange;
|
|
118
|
-
sm?: ColBreakPointRange;
|
|
119
|
-
md?: ColBreakPointRange;
|
|
120
|
-
lg?: ColBreakPointRange;
|
|
121
|
-
xl?: ColBreakPointRange;
|
|
122
|
-
xxl?: ColBreakPointRange;
|
|
123
|
-
}
|
|
124
|
-
declare const Col: React.FC<ColType>;
|
|
125
|
-
|
|
126
|
-
interface ContainerType extends Code0Component<HTMLDivElement> {
|
|
127
|
-
children: ReactNode | ReactNode[];
|
|
128
|
-
}
|
|
129
|
-
declare const Container: React.FC<ContainerType>;
|
|
130
|
-
|
|
131
|
-
interface DropdownItemType {
|
|
132
|
-
children: ReactNode;
|
|
133
|
-
}
|
|
134
|
-
|
|
135
|
-
interface DropdownItemGroupType {
|
|
136
|
-
children: ReactNode;
|
|
137
|
-
}
|
|
138
|
-
|
|
139
|
-
interface DropdownFooterType {
|
|
140
|
-
children: ReactNode;
|
|
141
|
-
}
|
|
142
|
-
|
|
143
|
-
interface DropdownHeaderType {
|
|
144
|
-
children: ReactNode;
|
|
145
|
-
}
|
|
146
|
-
|
|
147
|
-
interface DropdownType$1 {
|
|
148
|
-
children: ReactElement<DropdownTriggerType & DropdownMenuType>[];
|
|
149
|
-
position?: 'top' | 'bottom' | 'left' | 'right';
|
|
150
|
-
align?: 'start' | 'center' | 'end';
|
|
151
|
-
maxWidthFactor?: number;
|
|
152
|
-
}
|
|
153
|
-
interface DropdownTriggerType {
|
|
154
|
-
children: ReactNode;
|
|
155
|
-
}
|
|
156
|
-
interface DropdownMenuType {
|
|
157
|
-
children: ReactNode;
|
|
158
|
-
}
|
|
159
|
-
declare const _default$5: React.FC<DropdownType$1> & {
|
|
160
|
-
Trigger: React.FC<DropdownTriggerType>;
|
|
161
|
-
Menu: React.FC<DropdownMenuType>;
|
|
162
|
-
Header: React.FC<DropdownHeaderType>;
|
|
163
|
-
Footer: React.FC<DropdownFooterType>;
|
|
164
|
-
Group: React.FC<DropdownItemGroupType> & {
|
|
165
|
-
Item: React.FC<DropdownItemType>;
|
|
166
|
-
};
|
|
167
|
-
};
|
|
168
|
-
|
|
169
|
-
interface FontType extends Omit<Omit<Code0Component<HTMLSpanElement>, "children">, "size"> {
|
|
170
|
-
children: React.ReactNode;
|
|
171
|
-
size: Code0Sizes;
|
|
172
|
-
hierarchy?: "primary" | "secondary" | "tertiary";
|
|
173
|
-
}
|
|
174
|
-
declare const Text: React.FC<FontType>;
|
|
175
|
-
|
|
176
|
-
type InputChildType = InputControlType | InputDescType | InputLabelType;
|
|
177
|
-
interface InputType {
|
|
178
|
-
children: ReactElement<InputControlType> | ReactElement<InputChildType>[];
|
|
179
|
-
disabled?: boolean;
|
|
180
|
-
valid?: boolean | undefined;
|
|
181
|
-
}
|
|
182
|
-
type InputControlTypesType = "email" | "date" | "datetime-local" | "hidden" | "number" | "password" | "search" | "tel" | "text" | "time" | "url" | "week";
|
|
183
|
-
interface InputControlType extends DetailedHTMLProps<InputHTMLAttributes<HTMLInputElement>, HTMLInputElement> {
|
|
184
|
-
placeholder: string;
|
|
185
|
-
children?: ReactElement<InputControlMessageType | InputControlIconType>[] | ReactElement<InputControlMessageType | InputControlIconType>;
|
|
186
|
-
disabled?: boolean;
|
|
187
|
-
type?: InputControlTypesType;
|
|
188
|
-
}
|
|
189
|
-
type InputControlMessageType = {
|
|
190
|
-
children: string;
|
|
191
|
-
};
|
|
192
|
-
type InputControlIconType = {
|
|
193
|
-
children: ReactElement<TablerIconsProps>;
|
|
194
|
-
};
|
|
195
|
-
type InputLabelType = {
|
|
196
|
-
children: string;
|
|
197
|
-
};
|
|
198
|
-
type InputDescType = {
|
|
199
|
-
children: string;
|
|
200
|
-
};
|
|
201
|
-
declare const _default$4: React.FC<InputType> & {
|
|
202
|
-
Desc: React.FC<InputDescType>;
|
|
203
|
-
Label: React.FC<InputLabelType>;
|
|
204
|
-
Control: React.ForwardRefExoticComponent<Omit<InputControlType, "ref"> & React.RefAttributes<HTMLInputElement>> & {
|
|
205
|
-
Message: React.FC<InputControlMessageType>;
|
|
206
|
-
Icon: React.FC<InputControlIconType>;
|
|
207
|
-
};
|
|
208
|
-
};
|
|
209
|
-
|
|
210
|
-
interface ListGroupType {
|
|
211
|
-
children: ReactElement<ListGroupItemType> | ReactElement<ListGroupItemType>[];
|
|
212
|
-
}
|
|
213
|
-
interface ListGroupItemType {
|
|
214
|
-
children: ReactNode;
|
|
215
|
-
}
|
|
216
|
-
declare const _default$3: React.FC<ListGroupType> & {
|
|
217
|
-
Item: React.FC<ListGroupItemType>;
|
|
218
|
-
};
|
|
219
|
-
|
|
220
|
-
interface PopoverProps extends PositionProps, OverlayTriggerProps {
|
|
221
|
-
children: React.ReactElement<PopoverTriggerType & PopoverContentType>[];
|
|
222
|
-
}
|
|
223
|
-
interface PopoverTriggerType {
|
|
224
|
-
children: React.ReactElement;
|
|
225
|
-
}
|
|
226
|
-
interface PopoverContentType {
|
|
227
|
-
children: React.ReactNode;
|
|
228
|
-
}
|
|
229
|
-
declare const _default$2: React.FC<PopoverProps> & {
|
|
230
|
-
Trigger: React.FC<PopoverTriggerType>;
|
|
231
|
-
Content: React.FC<PopoverContentType>;
|
|
232
|
-
};
|
|
233
|
-
|
|
234
|
-
interface MenuType<T> extends AriaMenuProps<T>, PopoverProps {
|
|
235
|
-
children: React.ReactElement<MenuTriggerType & MenuContentType>[];
|
|
236
|
-
}
|
|
237
|
-
interface MenuTriggerType {
|
|
238
|
-
children: React.ReactElement;
|
|
239
|
-
}
|
|
240
|
-
interface MenuContentType {
|
|
241
|
-
children: React.ReactNode;
|
|
242
|
-
}
|
|
243
|
-
interface MenuItemType {
|
|
244
|
-
children: React.ReactNode;
|
|
245
|
-
key: Key;
|
|
246
|
-
color?: Color;
|
|
247
|
-
disabled?: boolean;
|
|
248
|
-
unselectable?: boolean;
|
|
249
|
-
textValue?: string;
|
|
250
|
-
}
|
|
251
|
-
interface MenuShortcutType {
|
|
252
|
-
children: string;
|
|
253
|
-
}
|
|
254
|
-
interface MenuIconType {
|
|
255
|
-
children: React.ReactNode;
|
|
256
|
-
}
|
|
257
|
-
interface MenuSectionType {
|
|
258
|
-
children: React.ReactElement<MenuItemType> | React.ReactElement<MenuItemType>[];
|
|
259
|
-
title?: string;
|
|
260
|
-
}
|
|
261
|
-
declare const _default$1: React.FC<MenuType<any>> & {
|
|
262
|
-
Trigger: React.FC<MenuTriggerType>;
|
|
263
|
-
Content: React.FC<MenuContentType>;
|
|
264
|
-
Item: React.FC<MenuItemType>;
|
|
265
|
-
Shortcut: React.FC<MenuShortcutType>;
|
|
266
|
-
Section: React.FC<MenuSectionType>;
|
|
267
|
-
Icon: React.FC<MenuIconType>;
|
|
268
|
-
};
|
|
269
|
-
|
|
270
|
-
interface QuoteType extends Omit<CardType, "children"> {
|
|
271
|
-
children: string;
|
|
272
|
-
logo: string;
|
|
273
|
-
name: string;
|
|
274
|
-
position: string;
|
|
275
|
-
inlineBorder?: boolean;
|
|
276
|
-
}
|
|
277
|
-
declare const Quote: React.FC<QuoteType>;
|
|
278
|
-
|
|
279
|
-
interface RowType extends Code0Component<HTMLDivElement> {
|
|
280
|
-
children: ReactNode | ReactNode[];
|
|
281
|
-
}
|
|
282
|
-
declare const Row: React.FC<RowType>;
|
|
283
|
-
|
|
284
|
-
interface DropdownType {
|
|
285
|
-
children: ReactElement<TooltipTriggerType & TooltipMenuType>[];
|
|
286
|
-
position?: 'top' | 'bottom' | 'left' | 'right';
|
|
287
|
-
align?: 'start' | 'center' | 'end';
|
|
288
|
-
}
|
|
289
|
-
interface TooltipTriggerType {
|
|
290
|
-
children: ReactNode;
|
|
291
|
-
}
|
|
292
|
-
interface TooltipMenuType {
|
|
293
|
-
children: ReactNode;
|
|
294
|
-
}
|
|
295
|
-
declare const _default: React.FC<DropdownType> & {
|
|
296
|
-
Trigger: React.FC<TooltipTriggerType>;
|
|
297
|
-
Menu: React.FC<TooltipMenuType>;
|
|
298
|
-
};
|
|
299
|
-
|
|
300
|
-
export { Alert, Badge, _default$7 as Button, ButtonGroup, _default$6 as Card, Col, Container, _default$5 as Dropdown, _default$4 as Input, _default$3 as ListGroup, _default$1 as Menu, _default$2 as Popover, Quote, Row, Text, _default as Tooltip };
|
|
1
|
+
export * from './components/alert/Alert';
|
|
2
|
+
export * from './components/aurora/Aurora';
|
|
3
|
+
export * from './components/avatar/Avatar';
|
|
4
|
+
export * from './components/badge/Badge';
|
|
5
|
+
export * from './components/breadcrumb/Breadcrumb';
|
|
6
|
+
export * from './components/button/Button';
|
|
7
|
+
export * from './components/button-group/ButtonGroup';
|
|
8
|
+
export * from './components/card/Card';
|
|
9
|
+
export * from './components/col/Col';
|
|
10
|
+
export * from './components/command/Command';
|
|
11
|
+
export * from './components/container/Container';
|
|
12
|
+
export * from './components/context-menu/ContextMenu';
|
|
13
|
+
export * from './components/data-table/index';
|
|
14
|
+
export * from './components/dialog/Dialog';
|
|
15
|
+
export * from './components/editor/Editor';
|
|
16
|
+
export * from './components/file-tabs/index';
|
|
17
|
+
export * from './components/flex/Flex';
|
|
18
|
+
export * from './components/flex/Flex';
|
|
19
|
+
export * from './components/form/index';
|
|
20
|
+
export * from './components/fullscreen/FullScreen';
|
|
21
|
+
export * from './components/layout/Layout';
|
|
22
|
+
export * from './components/menu/Menu';
|
|
23
|
+
export * from './components/quote/Quote';
|
|
24
|
+
export * from './components/resizable/Resizable';
|
|
25
|
+
export * from './components/row/Row';
|
|
26
|
+
export * from './components/scroll-area/ScrollArea';
|
|
27
|
+
export * from './components/segmented-control/SegmentedControl';
|
|
28
|
+
export * from './components/spacing/Spacing';
|
|
29
|
+
export * from './components/tab/Tab';
|
|
30
|
+
export * from './components/text/Text';
|
|
31
|
+
export * from './components/toast/Toast';
|
|
32
|
+
export * from './components/tooltip/Tooltip';
|
|
33
|
+
export * from './utils/index';
|