@code0-tech/pictor 0.0.0-mvp.6 → 0.0.0-mvp.8
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/assets/components/button/Button.style.css +1 -1
- package/dist/assets/components/d-layout/DLayout.style.css +1 -1
- package/dist/assets/components/text/Text.style.css +1 -1
- package/dist/components/d-fullscreen/DFullScreen.js +21 -16
- package/dist/components/d-user/DUserMenu.js +14 -14
- package/dist/components/spacing/Spacing.d.ts +6 -0
- package/dist/components/spacing/Spacing.js +22 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +21 -19
- package/dist/utils/types.d.ts +2 -2
- package/package.json +12 -12
|
@@ -1 +1 @@
|
|
|
1
|
-
.button{padding:.
|
|
1
|
+
.button{padding:.7rem 1rem;gap:.5rem;cursor:pointer;height:fit-content;display:flex;align-items:center;width:fit-content;justify-content:center;font-size:.8rem}.button:disabled,.button[data-disabled],.button[aria-disabled=true],.button--disabled{cursor:not-allowed;opacity:25%;pointer-events:unset}.button{border-radius:1rem}.button--primary{border:none;background:#030014;color:#ffffffbf;position:relative;box-sizing:border-box;box-shadow:inset 0 0 0 1px #ffffff1a}.button--primary:hover{box-shadow:inset 0 0 0 1px #ffffff40}.button--primary:active,.button--primary:focus{box-shadow:inset 0 0 0 1px #ffffff0d,inset 0 0 3rem #ffffff1a;outline:none}.button--primary.button--outlined{background:transparent}.button--primary.button--none{background:transparent;box-shadow:none}.button--secondary{border:none;background:#1c1a2c;color:#ffffffbf;position:relative;box-sizing:border-box;box-shadow:inset 0 0 0 1px #ffffff1a}.button--secondary:hover{box-shadow:inset 0 0 0 1px #ffffff40}.button--secondary:active,.button--secondary:focus{box-shadow:inset 0 0 0 1px #ffffff0d,inset 0 0 3rem #ffffff1a;outline:none}.button--secondary.button--outlined{background:transparent}.button--secondary.button--none{background:transparent;box-shadow:none}.button--success{border:none;background:#071314;color:#ffffffbf;position:relative;box-sizing:border-box;box-shadow:inset 0 0 0 1px #ffffff1a}.button--success:hover{box-shadow:inset 0 0 0 1px #ffffff40}.button--success:active,.button--success:focus{box-shadow:inset 0 0 0 1px #ffffff0d,inset 0 0 3rem #ffffff1a;outline:none}.button--success.button--outlined{background:transparent}.button--success.button--none{background:transparent;box-shadow:none}.button--warning{border:none;background:#1c1313;color:#ffffffbf;position:relative;box-sizing:border-box;box-shadow:inset 0 0 0 1px #ffffff1a}.button--warning:hover{box-shadow:inset 0 0 0 1px #ffffff40}.button--warning:active,.button--warning:focus{box-shadow:inset 0 0 0 1px #ffffff0d,inset 0 0 3rem #ffffff1a;outline:none}.button--warning.button--outlined{background:transparent}.button--warning.button--none{background:transparent;box-shadow:none}.button--error{border:none;background:#180016;color:#ffffffbf;position:relative;box-sizing:border-box;box-shadow:inset 0 0 0 1px #ffffff1a}.button--error:hover{box-shadow:inset 0 0 0 1px #ffffff40}.button--error:active,.button--error:focus{box-shadow:inset 0 0 0 1px #ffffff0d,inset 0 0 3rem #ffffff1a;outline:none}.button--error.button--outlined{background:transparent}.button--error.button--none{background:transparent;box-shadow:none}.button--info{border:none;background:#0e1a24;color:#ffffffbf;position:relative;box-sizing:border-box;box-shadow:inset 0 0 0 1px #ffffff1a}.button--info:hover{box-shadow:inset 0 0 0 1px #ffffff40}.button--info:active,.button--info:focus{box-shadow:inset 0 0 0 1px #ffffff0d,inset 0 0 3rem #ffffff1a;outline:none}.button--info.button--outlined{background:transparent}.button--info.button--none{background:transparent;box-shadow:none}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
.d-layout{position:relative;width:100%;height:100%;overflow:hidden}.d-layout
|
|
1
|
+
.d-layout{position:relative;width:100%;height:100%;overflow:hidden}.d-layout>.flex,.d-layout>.flex>.flex{width:100%;height:100%;gap:.7rem}.d-layout__content{width:100%}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
.text{font-family:Inter,sans-serif}.text--xs{font-size:.7rem}.text--sm{font-size:.8rem}.text--md{font-size:1rem}.text--lg{font-size:1.2rem}.text--xl{font-size:1.3rem}.text--primary{font-family:Inter,sans-serif;line-height:1.1;letter-spacing:-.75px;color:#fff}.text--secondary{line-height:1.1;letter-spacing:-.75px;color:#ffffffbf}.text--tertiary{line-height:1.1;letter-spacing:-.75px;color:#ffffff80}
|
|
1
|
+
.text{font-family:Inter,sans-serif}.text--xxs{font-size:.35rem}.text--xs{font-size:.7rem}.text--sm{font-size:.8rem}.text--md{font-size:1rem}.text--lg{font-size:1.2rem}.text--xl{font-size:1.3rem}.text--primary{font-family:Inter,sans-serif;line-height:1.1;letter-spacing:-.75px;color:#fff}.text--secondary{line-height:1.1;letter-spacing:-.75px;color:#ffffffbf}.text--tertiary{line-height:1.1;letter-spacing:-.75px;color:#ffffff80}
|
|
@@ -1,21 +1,26 @@
|
|
|
1
|
-
import { jsx as
|
|
1
|
+
import { jsx as u } from "react/jsx-runtime";
|
|
2
2
|
import { c as f } from "../../_virtual/compiler-runtime.js";
|
|
3
|
-
import
|
|
4
|
-
import { mergeCode0Props as
|
|
3
|
+
import l from "react";
|
|
4
|
+
import { mergeCode0Props as m } from "../../utils/utils.js";
|
|
5
5
|
import '../../assets/components/d-fullscreen/DFullScreen.style.css';/* empty css */
|
|
6
|
-
const
|
|
7
|
-
const e = f.c(7), t =
|
|
8
|
-
let
|
|
9
|
-
e[0] === Symbol.for("react.memo_cache_sentinel") ? (
|
|
10
|
-
t.current
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
6
|
+
const y = (i) => {
|
|
7
|
+
const e = f.c(7), t = l.useRef(null);
|
|
8
|
+
let r, o;
|
|
9
|
+
e[0] === Symbol.for("react.memo_cache_sentinel") ? (r = () => {
|
|
10
|
+
if (!t.current)
|
|
11
|
+
return;
|
|
12
|
+
window.addEventListener("resize", () => {
|
|
13
|
+
const c = Math.round(window.visualViewport?.width ?? window.innerWidth), s = Math.round(window.visualViewport?.height ?? window.innerHeight);
|
|
14
|
+
t.current.style.height = s + "px", t.current.style.width = c + "px";
|
|
15
|
+
});
|
|
16
|
+
const w = Math.round(window.visualViewport?.width ?? window.innerWidth), h = Math.round(window.visualViewport?.height ?? window.innerHeight);
|
|
17
|
+
t.current.style.height = h + "px", t.current.style.width = w + "px";
|
|
18
|
+
}, o = [t], e[0] = r, e[1] = o) : (r = e[0], o = e[1]), l.useEffect(r, o);
|
|
19
|
+
let n;
|
|
20
|
+
e[2] !== i ? (n = m("d-full-screen", i), e[2] = i, e[3] = n) : n = e[3];
|
|
21
|
+
let d;
|
|
22
|
+
return e[4] !== i.children || e[5] !== n ? (d = /* @__PURE__ */ u("div", { ...n, ref: t, children: i.children }), e[4] = i.children, e[5] = n, e[6] = d) : d = e[6], d;
|
|
18
23
|
};
|
|
19
24
|
export {
|
|
20
|
-
|
|
25
|
+
y as DFullScreen
|
|
21
26
|
};
|
|
@@ -1,26 +1,26 @@
|
|
|
1
|
-
import { jsxs as
|
|
1
|
+
import { jsxs as i, jsx as e } from "react/jsx-runtime";
|
|
2
2
|
import l from "react";
|
|
3
|
-
import { Menu as
|
|
3
|
+
import { Menu as d, MenuTrigger as u, MenuPortal as h, MenuContent as f } from "../menu/Menu.js";
|
|
4
4
|
import { DUserReactiveService as n } from "./DUser.service.js";
|
|
5
|
-
import { useService as
|
|
6
|
-
import { Avatar as
|
|
7
|
-
import { Text as
|
|
5
|
+
import { useService as o } from "../../utils/contextStore.js";
|
|
6
|
+
import { Avatar as x } from "../avatar/Avatar.js";
|
|
7
|
+
import { Text as s } from "../text/Text.js";
|
|
8
8
|
import { Flex as c } from "../flex/Flex.js";
|
|
9
|
-
const j = (
|
|
10
|
-
const m =
|
|
11
|
-
return l.useMemo(() => /* @__PURE__ */
|
|
12
|
-
/* @__PURE__ */ e(
|
|
9
|
+
const j = (t) => {
|
|
10
|
+
const m = o(n), a = o(n), r = m.getById(t.userId);
|
|
11
|
+
return l.useMemo(() => /* @__PURE__ */ i(d, { ...t, children: [
|
|
12
|
+
/* @__PURE__ */ e(u, { asChild: !0, children: /* @__PURE__ */ i(c, { align: "center", style: {
|
|
13
13
|
gap: ".5rem"
|
|
14
14
|
}, children: [
|
|
15
|
-
/* @__PURE__ */ e(
|
|
16
|
-
/* @__PURE__ */
|
|
15
|
+
/* @__PURE__ */ e(x, { src: r?.avatarPath ?? "", identifier: r?.username ?? "" }),
|
|
16
|
+
/* @__PURE__ */ i(c, { style: {
|
|
17
17
|
flexDirection: "column"
|
|
18
18
|
}, children: [
|
|
19
|
-
/* @__PURE__ */ e(
|
|
20
|
-
/* @__PURE__ */ e(
|
|
19
|
+
/* @__PURE__ */ e(s, { size: "md", hierarchy: "secondary", children: r?.username }),
|
|
20
|
+
/* @__PURE__ */ e(s, { size: "xs", hierarchy: "tertiary", children: r?.email })
|
|
21
21
|
] })
|
|
22
22
|
] }) }),
|
|
23
|
-
/* @__PURE__ */ e(h, { children: /* @__PURE__ */ e(f, { side: "bottom", align: "start", sideOffset: 8, children:
|
|
23
|
+
/* @__PURE__ */ e(h, { children: /* @__PURE__ */ e(f, { side: "bottom", align: "start", sideOffset: 8, children: t.children }) })
|
|
24
24
|
] }), [a]);
|
|
25
25
|
};
|
|
26
26
|
export {
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { jsx as s } from "react/jsx-runtime";
|
|
2
|
+
import { c } from "../../_virtual/compiler-runtime.js";
|
|
3
|
+
import "../../utils/contextStore.js";
|
|
4
|
+
import "react";
|
|
5
|
+
import { mergeCode0Props as n } from "../../utils/utils.js";
|
|
6
|
+
const x = (o) => {
|
|
7
|
+
const t = c.c(4);
|
|
8
|
+
let e;
|
|
9
|
+
if (t[0] !== o) {
|
|
10
|
+
const {
|
|
11
|
+
spacing: r,
|
|
12
|
+
...m
|
|
13
|
+
} = o;
|
|
14
|
+
e = n(`spacing spacing--${r}`, m), t[0] = o, t[1] = e;
|
|
15
|
+
} else
|
|
16
|
+
e = t[1];
|
|
17
|
+
let i;
|
|
18
|
+
return t[2] !== e ? (i = /* @__PURE__ */ s("div", { ...e }), t[2] = e, t[3] = i) : i = t[3], i;
|
|
19
|
+
};
|
|
20
|
+
export {
|
|
21
|
+
x as Spacing
|
|
22
|
+
};
|
package/dist/index.d.ts
CHANGED
|
@@ -23,6 +23,7 @@ export * from './components/quote/Quote';
|
|
|
23
23
|
export * from './components/row/Row';
|
|
24
24
|
export * from './components/scroll-area/ScrollArea';
|
|
25
25
|
export * from './components/segmented-control/SegmentedControl';
|
|
26
|
+
export * from './components/spacing/Spacing';
|
|
26
27
|
export * from './components/text/Text';
|
|
27
28
|
export * from './components/tooltip/Tooltip';
|
|
28
29
|
export * from './utils/index';
|
package/dist/index.js
CHANGED
|
@@ -73,12 +73,13 @@ import { Quote as yr } from "./components/quote/Quote.js";
|
|
|
73
73
|
import { Row as Gr } from "./components/row/Row.js";
|
|
74
74
|
import { ScrollArea as Or, ScrollAreaCorner as Er, ScrollAreaScrollbar as hr, ScrollAreaThumb as zr, ScrollAreaViewport as Br } from "./components/scroll-area/ScrollArea.js";
|
|
75
75
|
import { SegmentedControl as Hr, SegmentedControlItem as Ur } from "./components/segmented-control/SegmentedControl.js";
|
|
76
|
-
import {
|
|
77
|
-
import {
|
|
78
|
-
import {
|
|
79
|
-
import {
|
|
80
|
-
import {
|
|
81
|
-
import {
|
|
76
|
+
import { Spacing as _r } from "./components/spacing/Spacing.js";
|
|
77
|
+
import { Tooltip as Kr, TooltipArrow as Qr, TooltipContent as qr, TooltipPortal as Jr, TooltipTrigger as Xr } from "./components/tooltip/Tooltip.js";
|
|
78
|
+
import { InspectionSeverity as Zr } from "./utils/inspection.js";
|
|
79
|
+
import { NonReactiveArrayService as et, createNonReactiveArrayService as ot } from "./utils/nonReactiveArrayService.js";
|
|
80
|
+
import { ObjectService as tt, createObjectService as it } from "./utils/objectStore.js";
|
|
81
|
+
import { ReactiveArrayService as mt, useReactiveArrayService as at } from "./utils/reactiveArrayService.js";
|
|
82
|
+
import { Colors as lt } from "./utils/types.js";
|
|
82
83
|
export {
|
|
83
84
|
m as Avatar,
|
|
84
85
|
n as Badge,
|
|
@@ -88,7 +89,7 @@ export {
|
|
|
88
89
|
g as Card,
|
|
89
90
|
Xo as CheckboxInput,
|
|
90
91
|
w as Col,
|
|
91
|
-
|
|
92
|
+
lt as Colors,
|
|
92
93
|
d as Command,
|
|
93
94
|
F as CommandDialog,
|
|
94
95
|
C as CommandEmpty,
|
|
@@ -160,7 +161,7 @@ export {
|
|
|
160
161
|
nr as InputMessage,
|
|
161
162
|
xr as InputSuggestionMenuContent,
|
|
162
163
|
fr as InputSuggestionMenuContentItems,
|
|
163
|
-
|
|
164
|
+
Zr as InspectionSeverity,
|
|
164
165
|
po as Menu,
|
|
165
166
|
mo as MenuArrow,
|
|
166
167
|
ao as MenuContent,
|
|
@@ -175,9 +176,9 @@ export {
|
|
|
175
176
|
go as MenuTrigger,
|
|
176
177
|
L as NodeFunctionView,
|
|
177
178
|
O as NodeParameterView,
|
|
178
|
-
|
|
179
|
+
et as NonReactiveArrayService,
|
|
179
180
|
ur as NumberInput,
|
|
180
|
-
|
|
181
|
+
tt as ObjectService,
|
|
181
182
|
pe as ParameterDefinitionView,
|
|
182
183
|
sr as PasswordInput,
|
|
183
184
|
Sr as PinInput,
|
|
@@ -186,7 +187,7 @@ export {
|
|
|
186
187
|
yr as Quote,
|
|
187
188
|
Fr as RadioGroup,
|
|
188
189
|
Rr as RadioInput,
|
|
189
|
-
|
|
190
|
+
mt as ReactiveArrayService,
|
|
190
191
|
Gr as Row,
|
|
191
192
|
Or as ScrollArea,
|
|
192
193
|
Er as ScrollAreaCorner,
|
|
@@ -195,16 +196,17 @@ export {
|
|
|
195
196
|
Br as ScrollAreaViewport,
|
|
196
197
|
Hr as SegmentedControl,
|
|
197
198
|
Ur as SegmentedControlItem,
|
|
199
|
+
_r as Spacing,
|
|
198
200
|
Vr as SwitchInput,
|
|
199
201
|
ze as Text,
|
|
200
202
|
Tr as TextInput,
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
203
|
+
Kr as Tooltip,
|
|
204
|
+
Qr as TooltipArrow,
|
|
205
|
+
qr as TooltipContent,
|
|
206
|
+
Jr as TooltipPortal,
|
|
207
|
+
Xr as TooltipTrigger,
|
|
208
|
+
ot as createNonReactiveArrayService,
|
|
209
|
+
it as createObjectService,
|
|
208
210
|
$o as emailValidation,
|
|
209
211
|
Qe as getChild,
|
|
210
212
|
qe as getContent,
|
|
@@ -218,7 +220,7 @@ export {
|
|
|
218
220
|
j as useFlowEdges,
|
|
219
221
|
U as useFlowNodes,
|
|
220
222
|
br as useForm,
|
|
221
|
-
|
|
223
|
+
at as useReactiveArrayService,
|
|
222
224
|
Ue as useService,
|
|
223
225
|
We as useStore
|
|
224
226
|
};
|
package/dist/utils/types.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { default as React, HTMLProps } from 'react';
|
|
2
2
|
export type Color = "primary" | "secondary" | "info" | "success" | "warning" | "error";
|
|
3
3
|
export declare const Colors: Color[];
|
|
4
|
-
export type Code0Sizes = "xs" | "sm" | "md" | "lg" | "xl";
|
|
5
|
-
export type Code0FontSizes = "0.
|
|
4
|
+
export type Code0Sizes = "xxs" | "xs" | "sm" | "md" | "lg" | "xl";
|
|
5
|
+
export type Code0FontSizes = "0.35" | "0.7" | "0.8" | "1" | "1.2" | "1.3";
|
|
6
6
|
export type StyleProp<Value> = Value;
|
|
7
7
|
export interface Code0ComponentProps {
|
|
8
8
|
m?: StyleProp<number | `${number}`>;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@code0-tech/pictor",
|
|
3
|
-
"version": "0.0.0-mvp.
|
|
3
|
+
"version": "0.0.0-mvp.8",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "A simple template for a custom React component library",
|
|
6
6
|
"scripts": {
|
|
@@ -22,7 +22,7 @@
|
|
|
22
22
|
"@babel/plugin-proposal-decorators": "^7.28.0",
|
|
23
23
|
"@babel/plugin-transform-class-properties": "^7.27.1",
|
|
24
24
|
"@code0-tech/sagittarius-graphql-types": "^0.0.0-65144a9920c6a8de3bcf24acdcb8eec4158cef73",
|
|
25
|
-
"@dagrejs/dagre": "^1.1.
|
|
25
|
+
"@dagrejs/dagre": "^1.1.8",
|
|
26
26
|
"@mdx-js/react": "^3.1.1",
|
|
27
27
|
"@radix-ui/react-checkbox": "^1.3.3",
|
|
28
28
|
"@radix-ui/react-dialog": "^1.1.15",
|
|
@@ -33,17 +33,17 @@
|
|
|
33
33
|
"@radix-ui/react-tabs": "^1.1.13",
|
|
34
34
|
"@radix-ui/react-toggle-group": "^1.1.11",
|
|
35
35
|
"@radix-ui/react-tooltip": "^1.2.8",
|
|
36
|
-
"@rollup/plugin-commonjs": "^
|
|
36
|
+
"@rollup/plugin-commonjs": "^29.0.0",
|
|
37
37
|
"@rollup/plugin-node-resolve": "^16.0.3",
|
|
38
38
|
"@rollup/plugin-terser": "^0.4.4",
|
|
39
39
|
"@rollup/plugin-typescript": "^12.3.0",
|
|
40
|
-
"@storybook/addon-a11y": "^10.0.
|
|
41
|
-
"@storybook/addon-links": "^10.0.
|
|
42
|
-
"@storybook/addon-onboarding": "^10.0.
|
|
43
|
-
"@storybook/builder-vite": "^10.0.
|
|
44
|
-
"@storybook/cli": "^10.0.
|
|
45
|
-
"@storybook/react": "^10.0.
|
|
46
|
-
"@storybook/react-vite": "^10.0.
|
|
40
|
+
"@storybook/addon-a11y": "^10.0.6",
|
|
41
|
+
"@storybook/addon-links": "^10.0.6",
|
|
42
|
+
"@storybook/addon-onboarding": "^10.0.6",
|
|
43
|
+
"@storybook/builder-vite": "^10.0.6",
|
|
44
|
+
"@storybook/cli": "^10.0.6",
|
|
45
|
+
"@storybook/react": "^10.0.6",
|
|
46
|
+
"@storybook/react-vite": "^10.0.6",
|
|
47
47
|
"@storybook/test-runner": "^0.24.1",
|
|
48
48
|
"@storybook/testing-library": "^0.2.2",
|
|
49
49
|
"@tabler/icons-react": "3.35.0",
|
|
@@ -71,12 +71,12 @@
|
|
|
71
71
|
"rimraf": "^6.1.0",
|
|
72
72
|
"sass": "^1.93.3",
|
|
73
73
|
"sass-loader": "^16.0.6",
|
|
74
|
-
"storybook": "^10.0.
|
|
74
|
+
"storybook": "^10.0.6",
|
|
75
75
|
"style-loader": "^4.0.0",
|
|
76
76
|
"ts-jest": "^29.4.5",
|
|
77
77
|
"ts-node": "^10.9.2",
|
|
78
78
|
"typescript": "^5.9.3",
|
|
79
|
-
"vite": "^7.2.
|
|
79
|
+
"vite": "^7.2.2",
|
|
80
80
|
"vite-plugin-dts": "^4.5.4",
|
|
81
81
|
"vite-plugin-lib-inject-css": "^2.2.2",
|
|
82
82
|
"@code0-tech/definition-reader": "^0.0.16"
|