@likec4/styles 1.55.1 → 1.56.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/package.json +6 -6
- package/preset/_chunks/libs/@radix-ui/colors.mjs +2 -0
- package/preset/_chunks/libs/pandacss-preset-radix-colors.mjs +2 -0
- package/preset/_chunks/libs/remeda.mjs +22 -0
- package/preset/_chunks/rolldown-runtime.mjs +2 -0
- package/preset/preset.mjs +100 -18
- package/vars/vars.mjs +3 -0
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@likec4/styles",
|
|
3
3
|
"description": "Shared PandaCSS preset and generated styles, used in LikeC4",
|
|
4
4
|
"license": "MIT",
|
|
5
|
-
"version": "1.
|
|
5
|
+
"version": "1.56.0",
|
|
6
6
|
"bugs": "https://github.com/likec4/likec4/issues",
|
|
7
7
|
"homepage": "https://likec4.dev",
|
|
8
8
|
"author": "Denis Davydkov <denis@davydkov.com>",
|
|
@@ -92,21 +92,21 @@
|
|
|
92
92
|
}
|
|
93
93
|
},
|
|
94
94
|
"devDependencies": {
|
|
95
|
-
"@types/node": "~22.19.
|
|
95
|
+
"@types/node": "~22.19.17",
|
|
96
96
|
"@pandabox/panda-plugins": "^0.0.8",
|
|
97
97
|
"@pandabox/utils": "^0.0.5",
|
|
98
98
|
"@pandabox/unplugin": "^0.2.2",
|
|
99
99
|
"@pandacss/dev": "^1.9.1",
|
|
100
100
|
"@types/picomatch": "^4.0.3",
|
|
101
101
|
"@types/react": "19.2.14",
|
|
102
|
-
"postcss": "8.5.
|
|
102
|
+
"postcss": "8.5.10",
|
|
103
103
|
"remeda": "^2.33.7",
|
|
104
104
|
"nano-spawn": "^2.0.0",
|
|
105
105
|
"obuild": "0.4.31",
|
|
106
106
|
"typescript": "5.9.3",
|
|
107
|
-
"@likec4/style-preset": "1.
|
|
108
|
-
"@likec4/
|
|
109
|
-
"@likec4/
|
|
107
|
+
"@likec4/style-preset": "1.56.0",
|
|
108
|
+
"@likec4/tsconfig": "1.56.0",
|
|
109
|
+
"@likec4/devops": "1.42.0"
|
|
110
110
|
},
|
|
111
111
|
"scripts": {
|
|
112
112
|
"typecheck": "tsc --noEmit",
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { t as __exportAll } from "../../rolldown-runtime.mjs";
|
|
2
|
+
//#region ../../node_modules/.pnpm/@radix-ui+colors@3.0.0/node_modules/@radix-ui/colors/index.mjs
|
|
2
3
|
var colors_exports = /* @__PURE__ */ __exportAll({
|
|
3
4
|
amber: () => amber,
|
|
4
5
|
amberA: () => amberA,
|
|
@@ -3781,4 +3782,5 @@ const whiteP3A = {
|
|
|
3781
3782
|
whiteA11: "color(display-p3 1 1 1 / 0.9)",
|
|
3782
3783
|
whiteA12: "color(display-p3 1 1 1 / 0.95)"
|
|
3783
3784
|
};
|
|
3785
|
+
//#endregion
|
|
3784
3786
|
export { grass as a, orange as c, red as d, ruby as f, yellow as g, violet as h, crimson as i, pink as l, tomato as m, blue as n, indigo as o, teal as p, colors_exports as r, lime as s, amber as t, purple as u };
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { r as colors_exports } from "./@radix-ui/colors.mjs";
|
|
2
2
|
import { definePreset } from "@pandacss/dev";
|
|
3
|
+
//#region ../../node_modules/.pnpm/pandacss-preset-radix-colors@0.2.1_@pandacss+dev@1.9.1_typescript@5.9.3__@radix-ui+colors@3.0.0/node_modules/pandacss-preset-radix-colors/index.mjs
|
|
3
4
|
var SCALE_TAGS_REGEX = new RegExp(`(${["P3"].join("|")})|(?=[A-Z0-9])`, "g");
|
|
4
5
|
function getScaleTags(fullName) {
|
|
5
6
|
return fullName.split(SCALE_TAGS_REGEX).filter(Boolean).map((x) => x.toLowerCase());
|
|
@@ -144,4 +145,5 @@ function transformScaleName(scale) {
|
|
|
144
145
|
return scale.split(/(Dark|P3|A)/).map((x) => x.toLowerCase()).filter(Boolean).join(".");
|
|
145
146
|
}
|
|
146
147
|
Object.keys(colors_exports).filter((scale) => !scale.includes("default")).map(transformScaleName);
|
|
148
|
+
//#endregion
|
|
147
149
|
export { createPreset as t };
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
//#region ../../node_modules/.pnpm/remeda@2.33.7/node_modules/remeda/dist/lazyDataLastImpl-DtF3cihj.js
|
|
1
2
|
function e$4(e, t, n) {
|
|
2
3
|
let r = (n) => e(n, ...t);
|
|
3
4
|
return n === void 0 ? r : Object.assign(r, {
|
|
@@ -5,12 +6,16 @@ function e$4(e, t, n) {
|
|
|
5
6
|
lazyArgs: t
|
|
6
7
|
});
|
|
7
8
|
}
|
|
9
|
+
//#endregion
|
|
10
|
+
//#region ../../node_modules/.pnpm/remeda@2.33.7/node_modules/remeda/dist/purry.js
|
|
8
11
|
function t$10(t, n, r) {
|
|
9
12
|
let i = t.length - n.length;
|
|
10
13
|
if (i === 0) return t(...n);
|
|
11
14
|
if (i === 1) return e$4(t, n, r);
|
|
12
15
|
throw Error(`Wrong number of arguments`);
|
|
13
16
|
}
|
|
17
|
+
//#endregion
|
|
18
|
+
//#region ../../node_modules/.pnpm/remeda@2.33.7/node_modules/remeda/dist/capitalize.js
|
|
14
19
|
function t$9(...t) {
|
|
15
20
|
return t$10(n$6, t);
|
|
16
21
|
}
|
|
@@ -18,6 +23,8 @@ const n$6 = (e) => `${e[0]?.toUpperCase() ?? ``}${e.slice(1)}`, t$8 = {
|
|
|
18
23
|
done: !1,
|
|
19
24
|
hasNext: !1
|
|
20
25
|
};
|
|
26
|
+
//#endregion
|
|
27
|
+
//#region ../../node_modules/.pnpm/remeda@2.33.7/node_modules/remeda/dist/pipe.js
|
|
21
28
|
function t$7(e, ...t) {
|
|
22
29
|
let a = e, o = t.map((e) => `lazy` in e ? r(e) : void 0), s = 0;
|
|
23
30
|
for (; s < t.length;) {
|
|
@@ -66,16 +73,24 @@ function r(e) {
|
|
|
66
73
|
function i(e) {
|
|
67
74
|
return typeof e == `string` || typeof e == `object` && !!e && Symbol.iterator in e;
|
|
68
75
|
}
|
|
76
|
+
//#endregion
|
|
77
|
+
//#region ../../node_modules/.pnpm/remeda@2.33.7/node_modules/remeda/dist/hasAtLeast.js
|
|
69
78
|
function t$6(...t) {
|
|
70
79
|
return t$10(n$3, t);
|
|
71
80
|
}
|
|
72
81
|
const n$3 = (e, t) => e.length >= t;
|
|
82
|
+
//#endregion
|
|
83
|
+
//#region ../../node_modules/.pnpm/remeda@2.33.7/node_modules/remeda/dist/isString.js
|
|
73
84
|
function e$2(e) {
|
|
74
85
|
return typeof e == `string`;
|
|
75
86
|
}
|
|
87
|
+
//#endregion
|
|
88
|
+
//#region ../../node_modules/.pnpm/remeda@2.33.7/node_modules/remeda/dist/keys.js
|
|
76
89
|
function t$5(...t) {
|
|
77
90
|
return t$10(Object.keys, t);
|
|
78
91
|
}
|
|
92
|
+
//#endregion
|
|
93
|
+
//#region ../../node_modules/.pnpm/remeda@2.33.7/node_modules/remeda/dist/mapKeys.js
|
|
79
94
|
function t$4(...t) {
|
|
80
95
|
return t$10(n$2, t);
|
|
81
96
|
}
|
|
@@ -87,6 +102,8 @@ function n$2(e, t) {
|
|
|
87
102
|
}
|
|
88
103
|
return n;
|
|
89
104
|
}
|
|
105
|
+
//#endregion
|
|
106
|
+
//#region ../../node_modules/.pnpm/remeda@2.33.7/node_modules/remeda/dist/mapToObj.js
|
|
90
107
|
function t$3(...t) {
|
|
91
108
|
return t$10(n$1, t);
|
|
92
109
|
}
|
|
@@ -98,6 +115,8 @@ function n$1(e, t) {
|
|
|
98
115
|
}
|
|
99
116
|
return n;
|
|
100
117
|
}
|
|
118
|
+
//#endregion
|
|
119
|
+
//#region ../../node_modules/.pnpm/remeda@2.33.7/node_modules/remeda/dist/mapValues.js
|
|
101
120
|
function t$2(...t) {
|
|
102
121
|
return t$10(n, t);
|
|
103
122
|
}
|
|
@@ -106,6 +125,8 @@ function n(e, t) {
|
|
|
106
125
|
for (let [r, i] of Object.entries(e)) n[r] = t(i, r, e);
|
|
107
126
|
return n;
|
|
108
127
|
}
|
|
128
|
+
//#endregion
|
|
129
|
+
//#region ../../node_modules/.pnpm/remeda@2.33.7/node_modules/remeda/dist/prop.js
|
|
109
130
|
function e$1(e, ...n) {
|
|
110
131
|
return typeof e == `string` || typeof e == `number` || typeof e == `symbol` ? (r) => t$1(r, e, ...n) : t$1(e, ...n);
|
|
111
132
|
}
|
|
@@ -123,4 +144,5 @@ new Set([
|
|
|
123
144
|
...` .
|
|
124
145
|
.\v.\f.\r. .
.\xA0. . . . . . . . . . . . .\u2028.\u2029. . . .`.split(`.`)
|
|
125
146
|
]);
|
|
147
|
+
//#endregion
|
|
126
148
|
export { t$5 as a, t$7 as c, t$4 as i, t$9 as l, t$2 as n, e$2 as o, t$3 as r, t$6 as s, e$1 as t };
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
//#region \0rolldown/runtime.js
|
|
1
2
|
var __defProp = Object.defineProperty;
|
|
2
3
|
var __exportAll = (all, no_symbols) => {
|
|
3
4
|
let target = {};
|
|
@@ -8,4 +9,5 @@ var __exportAll = (all, no_symbols) => {
|
|
|
8
9
|
if (!no_symbols) __defProp(target, Symbol.toStringTag, { value: "Module" });
|
|
9
10
|
return target;
|
|
10
11
|
};
|
|
12
|
+
//#endregion
|
|
11
13
|
export { __exportAll as t };
|
package/preset/preset.mjs
CHANGED
|
@@ -3,6 +3,7 @@ import { a as t$6, c as t$2, i as t$4, l as t$1, n as t$3, o as e$1, r as t$5, s
|
|
|
3
3
|
import { a as grass, c as orange, d as red, f as ruby, g as yellow, h as violet, i as crimson, l as pink, m as tomato, n as blue$2, o as indigo, p as teal, s as lime, t as amber, u as purple } from "./_chunks/libs/@radix-ui/colors.mjs";
|
|
4
4
|
import { t as createPreset } from "./_chunks/libs/pandacss-preset-radix-colors.mjs";
|
|
5
5
|
import { defineAnimationStyles, defineKeyframes, defineLayerStyles, defineParts, definePattern, definePreset, defineRecipe, defineSemanticTokens, defineSlotRecipe, defineTextStyles, defineTokens, defineUtility } from "@pandacss/dev";
|
|
6
|
+
//#region ../preset/src/animations.ts
|
|
6
7
|
const keyframes = defineKeyframes({
|
|
7
8
|
"indicatorOpacity": {
|
|
8
9
|
"0%": { opacity: .8 },
|
|
@@ -29,6 +30,8 @@ const animationStyles = defineAnimationStyles({
|
|
|
29
30
|
animationName: "xyedgeAnimated"
|
|
30
31
|
} }
|
|
31
32
|
});
|
|
33
|
+
//#endregion
|
|
34
|
+
//#region ../preset/src/defaults/vars.ts
|
|
32
35
|
const vars = {
|
|
33
36
|
font: "--likec4-app-font",
|
|
34
37
|
spacing: "--likec4-spacing",
|
|
@@ -73,8 +76,12 @@ function __v(key, defaultTo) {
|
|
|
73
76
|
if (defaultValue) return `var(${name}, var(${defaultValue}))`;
|
|
74
77
|
return `var(${name}, ${defaultTo})`;
|
|
75
78
|
}
|
|
79
|
+
//#endregion
|
|
80
|
+
//#region ../preset/src/const.ts
|
|
76
81
|
const root = ".likec4-root";
|
|
77
82
|
`${root}`;
|
|
83
|
+
//#endregion
|
|
84
|
+
//#region ../preset/src/defaults/element-colors.ts
|
|
78
85
|
const blue$1 = {
|
|
79
86
|
fill: "#3b82f6",
|
|
80
87
|
stroke: "#2563eb",
|
|
@@ -131,6 +138,8 @@ const ElementColors = {
|
|
|
131
138
|
loContrast: "#c7d2fe"
|
|
132
139
|
}
|
|
133
140
|
};
|
|
141
|
+
//#endregion
|
|
142
|
+
//#region ../preset/src/defaults/relationship-colors.ts
|
|
134
143
|
const gray = {
|
|
135
144
|
line: "#8D8D8D",
|
|
136
145
|
labelBg: "#18191B",
|
|
@@ -144,12 +153,12 @@ const slate = {
|
|
|
144
153
|
const blue = {
|
|
145
154
|
line: "#3b82f6",
|
|
146
155
|
labelBg: "#172554",
|
|
147
|
-
label: "#
|
|
156
|
+
label: "#eff5fd"
|
|
148
157
|
};
|
|
149
158
|
const sky = {
|
|
150
159
|
line: "#0ea5e9",
|
|
151
160
|
labelBg: "#082f49",
|
|
152
|
-
label: "#
|
|
161
|
+
label: "#d4f2ff"
|
|
153
162
|
};
|
|
154
163
|
const RelationshipColors = {
|
|
155
164
|
amber: {
|
|
@@ -162,24 +171,26 @@ const RelationshipColors = {
|
|
|
162
171
|
green: {
|
|
163
172
|
line: "#15803d",
|
|
164
173
|
labelBg: "#052e16",
|
|
165
|
-
label: "#
|
|
174
|
+
label: "#bbfcd3"
|
|
166
175
|
},
|
|
167
176
|
indigo: {
|
|
168
177
|
line: "#6366f1",
|
|
169
178
|
labelBg: "#1e1b4b",
|
|
170
|
-
label: "#
|
|
179
|
+
label: "#cbd0fd"
|
|
171
180
|
},
|
|
172
181
|
muted: slate,
|
|
173
182
|
primary: blue,
|
|
174
183
|
red: {
|
|
175
184
|
line: "#AC4D39",
|
|
176
185
|
labelBg: "#b91c1c",
|
|
177
|
-
label: "#
|
|
186
|
+
label: "#fcd9d2"
|
|
178
187
|
},
|
|
179
188
|
secondary: sky,
|
|
180
189
|
sky,
|
|
181
190
|
slate
|
|
182
191
|
};
|
|
192
|
+
//#endregion
|
|
193
|
+
//#region ../preset/src/defaults/sizes.ts
|
|
183
194
|
const defaultSizes = {
|
|
184
195
|
sizes: {
|
|
185
196
|
xs: {
|
|
@@ -210,6 +221,13 @@ const defaultSizes = {
|
|
|
210
221
|
lg: 24,
|
|
211
222
|
xl: 32
|
|
212
223
|
},
|
|
224
|
+
/**
|
|
225
|
+
* Text sizes for titles
|
|
226
|
+
* https://typescale.com/
|
|
227
|
+
*
|
|
228
|
+
* Scale: 1.2
|
|
229
|
+
* Base: 16px
|
|
230
|
+
*/
|
|
213
231
|
textSizes: {
|
|
214
232
|
xs: 13.33,
|
|
215
233
|
sm: 16,
|
|
@@ -225,6 +243,8 @@ const defaultSizes = {
|
|
|
225
243
|
xl: 90
|
|
226
244
|
}
|
|
227
245
|
};
|
|
246
|
+
//#endregion
|
|
247
|
+
//#region ../preset/src/defaults/types.ts
|
|
228
248
|
const ElementShapes = [
|
|
229
249
|
"rectangle",
|
|
230
250
|
"person",
|
|
@@ -268,6 +288,8 @@ const DefaultTagColors = [
|
|
|
268
288
|
"violet"
|
|
269
289
|
];
|
|
270
290
|
tomato.tomato9, grass.grass9, blue$2.blue9, ruby.ruby9, orange.orange9, indigo.indigo9, pink.pink9, teal.teal9, purple.purple9, amber.amber9, crimson.crimson9, red.red9, lime.lime9, yellow.yellow9, violet.violet9;
|
|
291
|
+
//#endregion
|
|
292
|
+
//#region ../preset/src/defaults/index.ts
|
|
271
293
|
const defaultTheme = {
|
|
272
294
|
colors: ThemeColors.reduce((acc, key) => {
|
|
273
295
|
acc[key] = {
|
|
@@ -278,6 +300,8 @@ const defaultTheme = {
|
|
|
278
300
|
}, {}),
|
|
279
301
|
...defaultSizes
|
|
280
302
|
};
|
|
303
|
+
//#endregion
|
|
304
|
+
//#region ../preset/src/conditions.ts
|
|
281
305
|
const shapeSizeCondition = (key) => `shapeSize${t$1(key)}`;
|
|
282
306
|
const conditions = { extend: {
|
|
283
307
|
...t$2(defaultTheme.sizes, t$3((_, key) => `:where([data-likec4-shape-size='${key}']) &`), t$4(shapeSizeCondition)),
|
|
@@ -307,6 +331,8 @@ const conditions = { extend: {
|
|
|
307
331
|
whenDimmed: ":where(.react-flow__node, .react-flow__edge):has([data-likec4-dimmed]) &",
|
|
308
332
|
whenFocused: ":where(.react-flow__node, .react-flow__edge):is(:focus-visible, :focus, :focus-within) &"
|
|
309
333
|
} };
|
|
334
|
+
//#endregion
|
|
335
|
+
//#region ../preset/src/generated.ts
|
|
310
336
|
const breakpoints = {
|
|
311
337
|
xs: "36em",
|
|
312
338
|
sm: "48em",
|
|
@@ -1310,6 +1336,8 @@ const mantine = {
|
|
|
1310
1336
|
darkSelector: "[data-mantine-color-scheme=\"dark\"] &",
|
|
1311
1337
|
lightSelector: "[data-mantine-color-scheme=\"light\"] &"
|
|
1312
1338
|
};
|
|
1339
|
+
//#endregion
|
|
1340
|
+
//#region ../preset/src/helpers.ts
|
|
1313
1341
|
/**
|
|
1314
1342
|
* Changes the alpha channel of a color
|
|
1315
1343
|
* @param color color value or CSS variable
|
|
@@ -1327,6 +1355,8 @@ function alpha(color, percentage = 50) {
|
|
|
1327
1355
|
function rem(pixels) {
|
|
1328
1356
|
return `${pixels}px`;
|
|
1329
1357
|
}
|
|
1358
|
+
//#endregion
|
|
1359
|
+
//#region ../preset/src/globalCss.ts
|
|
1330
1360
|
const sizeConditions = {
|
|
1331
1361
|
...t$5(t$6(defaultTheme.textSizes), (size) => [`:where([data-likec4-text-size='${size}'])`, { [vars.textsize]: `{fontSizes.likec4.${size}}` }]),
|
|
1332
1362
|
...t$5(t$6(defaultTheme.spacing), (size) => [`:where([data-likec4-spacing='${size}'])`, { [vars.spacing]: `{spacing.likec4.${size}}` }])
|
|
@@ -1337,12 +1367,7 @@ const globalCss = { extend: {
|
|
|
1337
1367
|
".likec4-shadow-root": {
|
|
1338
1368
|
display: "contents",
|
|
1339
1369
|
color: "var(--colors-text)",
|
|
1340
|
-
"
|
|
1341
|
-
"--mantine-font-family-headings": "var(--likec4-app-font, var(--likec4-app-font-default))",
|
|
1342
|
-
"& dialog": {
|
|
1343
|
-
"--mantine-font-family": "var(--likec4-app-font, var(--likec4-app-font-default))",
|
|
1344
|
-
color: "var(--colors-text)"
|
|
1345
|
-
}
|
|
1370
|
+
"& dialog": { color: "var(--colors-text)" }
|
|
1346
1371
|
},
|
|
1347
1372
|
".likec4-edge-label-container": {
|
|
1348
1373
|
top: 0,
|
|
@@ -1420,11 +1445,11 @@ const globalCss = { extend: {
|
|
|
1420
1445
|
"--xy-edge-stroke-selected": __v("palette.relationStrokeSelected"),
|
|
1421
1446
|
"--xy-edge-label-color": {
|
|
1422
1447
|
base: __v("palette.relationLabel"),
|
|
1423
|
-
_light: `oklch(from ${__v("palette.relationLabel")} calc(l + 0.
|
|
1448
|
+
_light: `oklch(from ${__v("palette.relationLabel")} calc(l + 0.1) c h)`
|
|
1424
1449
|
},
|
|
1425
1450
|
"--xy-edge-label-background-color": {
|
|
1426
|
-
|
|
1427
|
-
_light: alpha(__v("palette.relationLabelBg"),
|
|
1451
|
+
base: alpha(__v("palette.relationLabelBg"), 85),
|
|
1452
|
+
_light: alpha(__v("palette.relationLabelBg"), 65)
|
|
1428
1453
|
},
|
|
1429
1454
|
"&:is([data-likec4-hovered=\"true\"], [data-edge-active=\"true\"])": {
|
|
1430
1455
|
"--xy-edge-stroke-width": 4,
|
|
@@ -1446,8 +1471,8 @@ const globalCss = { extend: {
|
|
|
1446
1471
|
transitionDuration: "400ms"
|
|
1447
1472
|
},
|
|
1448
1473
|
"& :where(.react-flow__edgelabel-renderer) > *": { mixBlendMode: {
|
|
1449
|
-
base: "
|
|
1450
|
-
|
|
1474
|
+
base: "luminosity",
|
|
1475
|
+
_light: "hard-light",
|
|
1451
1476
|
_print: "normal!"
|
|
1452
1477
|
} },
|
|
1453
1478
|
"& :where(.react-flow__edges) > svg": { mixBlendMode: {
|
|
@@ -1465,8 +1490,10 @@ const globalCss = { extend: {
|
|
|
1465
1490
|
},
|
|
1466
1491
|
":where(.likec4-static-view, .relationships-browser, .likec4-relationship-details) .react-flow .react-flow__attribution": { display: "none" }
|
|
1467
1492
|
} };
|
|
1493
|
+
//#endregion
|
|
1494
|
+
//#region ../preset/src/globalVars.ts
|
|
1468
1495
|
const globalVars = { extend: {
|
|
1469
|
-
[vars.font]: "
|
|
1496
|
+
[vars.font]: "var(--likec4-app-font-default)",
|
|
1470
1497
|
[vars.spacing]: "/*-*/ /*-*/",
|
|
1471
1498
|
[vars.textsize]: rem(defaultTheme.textSizes.md),
|
|
1472
1499
|
[vars.palette.fill]: defaultTheme.colors.primary.elements.fill,
|
|
@@ -1483,6 +1510,8 @@ const globalVars = { extend: {
|
|
|
1483
1510
|
[vars.icon.color]: "/*-*/ /*-*/",
|
|
1484
1511
|
[vars.icon.size]: "/*-*/ /*-*/"
|
|
1485
1512
|
} };
|
|
1513
|
+
//#endregion
|
|
1514
|
+
//#region ../preset/src/layer-styles.ts
|
|
1486
1515
|
const layerStyles = /* @__PURE__ */ defineLayerStyles({ likec4: {
|
|
1487
1516
|
tag: {
|
|
1488
1517
|
description: "LikeC4 tag layer",
|
|
@@ -1620,6 +1649,8 @@ const patterns = { extend: {
|
|
|
1620
1649
|
jsx: ["Txt"]
|
|
1621
1650
|
})
|
|
1622
1651
|
} };
|
|
1652
|
+
//#endregion
|
|
1653
|
+
//#region ../preset/src/radixColors.ts
|
|
1623
1654
|
const radixColorsPreset = /* @__PURE__ */ createPreset({
|
|
1624
1655
|
autoP3: false,
|
|
1625
1656
|
darkMode: { condition: "[data-mantine-color-scheme=\"dark\"] &" },
|
|
@@ -1719,6 +1750,8 @@ const actionBtn = defineRecipe({
|
|
|
1719
1750
|
conditions: ["*"]
|
|
1720
1751
|
}]
|
|
1721
1752
|
});
|
|
1753
|
+
//#endregion
|
|
1754
|
+
//#region ../preset/src/recipes/compoundNode.ts
|
|
1722
1755
|
const borderWidth = {
|
|
1723
1756
|
var: "--_border-width",
|
|
1724
1757
|
ref: "var(--_border-width)"
|
|
@@ -1948,6 +1981,8 @@ const compoundNode = defineRecipe({
|
|
|
1948
1981
|
borderStyle: ["*"]
|
|
1949
1982
|
}]
|
|
1950
1983
|
});
|
|
1984
|
+
//#endregion
|
|
1985
|
+
//#region ../preset/src/recipes/edgeActionBtn.ts
|
|
1951
1986
|
const edgeActionBtn = defineRecipe({
|
|
1952
1987
|
className: "likec4-edge-action-btn",
|
|
1953
1988
|
description: "Action Button within Diagram Edge Label",
|
|
@@ -1985,6 +2020,8 @@ const edgeActionBtn = defineRecipe({
|
|
|
1985
2020
|
defaultVariants: {},
|
|
1986
2021
|
staticCss: [{ conditions: ["*"] }]
|
|
1987
2022
|
});
|
|
2023
|
+
//#endregion
|
|
2024
|
+
//#region ../preset/src/recipes/edgeLabel.ts
|
|
1988
2025
|
const parts$4 = defineParts({
|
|
1989
2026
|
root: { selector: "&" },
|
|
1990
2027
|
stepNumber: { selector: "& .likec4-edge-label__step-number" },
|
|
@@ -2027,7 +2064,7 @@ const edgeLabel = defineRecipe({
|
|
|
2027
2064
|
},
|
|
2028
2065
|
background: `color-mix(in oklab, var(--xy-edge-label-background-color), {colors.likec4.mixColor} 12%)`,
|
|
2029
2066
|
fontVariantNumeric: "tabular-nums",
|
|
2030
|
-
[":where([data-likec4-color=\"gray\"]) &"]: { _dark: { background: `
|
|
2067
|
+
[":where([data-likec4-color=\"gray\"]) &"]: { _dark: { background: `color-mix(in oklab, var(--xy-edge-label-background-color), {colors.likec4.mixColor} 15%)` } }
|
|
2031
2068
|
},
|
|
2032
2069
|
contents: {
|
|
2033
2070
|
display: "contents",
|
|
@@ -2094,6 +2131,8 @@ const edgeLabel = defineRecipe({
|
|
|
2094
2131
|
pointerEvents: ["*"]
|
|
2095
2132
|
}]
|
|
2096
2133
|
});
|
|
2134
|
+
//#endregion
|
|
2135
|
+
//#region ../preset/src/recipes/edgePath.ts
|
|
2097
2136
|
const edgePath = defineSlotRecipe({
|
|
2098
2137
|
description: "Recipe for Edge Path",
|
|
2099
2138
|
slots: [
|
|
@@ -2177,6 +2216,8 @@ const edgePath = defineSlotRecipe({
|
|
|
2177
2216
|
},
|
|
2178
2217
|
staticCss: [{ conditions: ["*"] }]
|
|
2179
2218
|
});
|
|
2219
|
+
//#endregion
|
|
2220
|
+
//#region ../preset/src/recipes/elementNode.ts
|
|
2180
2221
|
const elementNode = defineRecipe({
|
|
2181
2222
|
className: "likec4-element-node",
|
|
2182
2223
|
jsx: ["ElementNodeContainer", "ElementNode"],
|
|
@@ -2210,6 +2251,8 @@ const elementNode = defineRecipe({
|
|
|
2210
2251
|
},
|
|
2211
2252
|
staticCss: [{ conditions: ["*"] }]
|
|
2212
2253
|
});
|
|
2254
|
+
//#endregion
|
|
2255
|
+
//#region ../preset/src/recipes/elementNodeData.ts
|
|
2213
2256
|
const parts$3 = defineParts({
|
|
2214
2257
|
root: { selector: "&" },
|
|
2215
2258
|
icon: { selector: "& [data-likec4-icon]" },
|
|
@@ -2442,6 +2485,8 @@ const elementNodeData = defineRecipe({
|
|
|
2442
2485
|
conditions: ["*"]
|
|
2443
2486
|
}]
|
|
2444
2487
|
});
|
|
2488
|
+
//#endregion
|
|
2489
|
+
//#region ../preset/src/recipes/elementShape.ts
|
|
2445
2490
|
const parts$2 = defineParts({
|
|
2446
2491
|
root: { selector: "&" },
|
|
2447
2492
|
outline: { selector: "& .likec4-shape-outline" },
|
|
@@ -2662,6 +2707,8 @@ const elementShapeRecipe = defineRecipe({
|
|
|
2662
2707
|
withBorder: ["*"]
|
|
2663
2708
|
}]
|
|
2664
2709
|
});
|
|
2710
|
+
//#endregion
|
|
2711
|
+
//#region ../preset/src/recipes/likec4tag.ts
|
|
2665
2712
|
const likec4tag = defineRecipe({
|
|
2666
2713
|
className: "likec4-tag",
|
|
2667
2714
|
base: {
|
|
@@ -2704,6 +2751,8 @@ const likec4tag = defineRecipe({
|
|
|
2704
2751
|
conditions: ["hover"]
|
|
2705
2752
|
}]
|
|
2706
2753
|
});
|
|
2754
|
+
//#endregion
|
|
2755
|
+
//#region ../preset/src/recipes/markdownBlock.ts
|
|
2707
2756
|
const markdownBlock = defineRecipe({
|
|
2708
2757
|
className: "likec4-markdown-block",
|
|
2709
2758
|
jsx: ["MarkdownBlock", "Markdown"],
|
|
@@ -2932,6 +2981,9 @@ const markdownBlock = defineRecipe({
|
|
|
2932
2981
|
}
|
|
2933
2982
|
},
|
|
2934
2983
|
variants: {
|
|
2984
|
+
/**
|
|
2985
|
+
* When markdown block is used inside a diagram node, this variant should be used to apply the likec4 palette.
|
|
2986
|
+
*/
|
|
2935
2987
|
uselikec4palette: {
|
|
2936
2988
|
true: {
|
|
2937
2989
|
"--code-background": "color-mix(in oklab , var(--likec4-palette-stroke) 70%, transparent)",
|
|
@@ -2953,6 +3005,9 @@ const markdownBlock = defineRecipe({
|
|
|
2953
3005
|
},
|
|
2954
3006
|
false: {}
|
|
2955
3007
|
},
|
|
3008
|
+
/**
|
|
3009
|
+
* Markdown block can receive either markdown or plain text.
|
|
3010
|
+
*/
|
|
2956
3011
|
value: {
|
|
2957
3012
|
markdown: {},
|
|
2958
3013
|
plaintext: { "& :where(p)": { whiteSpace: "preserve-breaks" } }
|
|
@@ -2968,6 +3023,8 @@ const markdownBlock = defineRecipe({
|
|
|
2968
3023
|
conditions: ["*"]
|
|
2969
3024
|
}]
|
|
2970
3025
|
});
|
|
3026
|
+
//#endregion
|
|
3027
|
+
//#region ../preset/src/recipes/navigationPanelActionIcon.ts
|
|
2971
3028
|
const navigationPanelActionIcon = defineRecipe({
|
|
2972
3029
|
className: "likec4-navigation-panel-icon",
|
|
2973
3030
|
jsx: ["PanelActionIcon"],
|
|
@@ -3016,6 +3073,8 @@ const navigationPanelActionIcon = defineRecipe({
|
|
|
3016
3073
|
conditions: ["*"]
|
|
3017
3074
|
}]
|
|
3018
3075
|
});
|
|
3076
|
+
//#endregion
|
|
3077
|
+
//#region ../preset/src/recipes/nodeNotes.ts
|
|
3019
3078
|
const parts$1 = defineParts({
|
|
3020
3079
|
root: { selector: "&" },
|
|
3021
3080
|
paper: { selector: "& .__paper" },
|
|
@@ -3090,6 +3149,8 @@ const nodeNotes = defineRecipe({
|
|
|
3090
3149
|
defaultVariants: { opened: false },
|
|
3091
3150
|
staticCss: [{ opened: ["*"] }]
|
|
3092
3151
|
});
|
|
3152
|
+
//#endregion
|
|
3153
|
+
//#region ../preset/src/recipes/overlay.ts
|
|
3093
3154
|
const backdropBlur = "--_blur";
|
|
3094
3155
|
const backdropOpacity = "--_opacity";
|
|
3095
3156
|
const level = "--_level";
|
|
@@ -3177,6 +3238,8 @@ const overlay = defineRecipe({
|
|
|
3177
3238
|
withBackdrop: ["*"]
|
|
3178
3239
|
}]
|
|
3179
3240
|
});
|
|
3241
|
+
//#endregion
|
|
3242
|
+
//#region ../preset/src/recipes/index.ts
|
|
3180
3243
|
var recipes_exports = /* @__PURE__ */ __exportAll({
|
|
3181
3244
|
actionBtn: () => actionBtn,
|
|
3182
3245
|
actionButtons: () => actionButtons,
|
|
@@ -3193,6 +3256,8 @@ var recipes_exports = /* @__PURE__ */ __exportAll({
|
|
|
3193
3256
|
nodeNotes: () => nodeNotes,
|
|
3194
3257
|
overlay: () => overlay
|
|
3195
3258
|
});
|
|
3259
|
+
//#endregion
|
|
3260
|
+
//#region ../preset/src/stot-recipes/navigationLink.ts
|
|
3196
3261
|
const navigationLink = defineSlotRecipe({
|
|
3197
3262
|
className: "likec4-navlink",
|
|
3198
3263
|
description: "Navigation Link (classes for Mantine NavLink)",
|
|
@@ -3251,6 +3316,8 @@ const navigationLink = defineSlotRecipe({
|
|
|
3251
3316
|
conditions: ["*"]
|
|
3252
3317
|
}]
|
|
3253
3318
|
});
|
|
3319
|
+
//#endregion
|
|
3320
|
+
//#region ../preset/src/stot-recipes/navigationPanel.ts
|
|
3254
3321
|
const navigationPanel = defineSlotRecipe({
|
|
3255
3322
|
className: "likec4-navigation-panel",
|
|
3256
3323
|
jsx: ["NavigationPanel", /NavigationPanel/],
|
|
@@ -3376,10 +3443,14 @@ const navigationPanel = defineSlotRecipe({
|
|
|
3376
3443
|
panelPosition: ["*"]
|
|
3377
3444
|
}]
|
|
3378
3445
|
});
|
|
3446
|
+
//#endregion
|
|
3447
|
+
//#region ../preset/src/stot-recipes/index.ts
|
|
3379
3448
|
var stot_recipes_exports = /* @__PURE__ */ __exportAll({
|
|
3380
3449
|
navigationLink: () => navigationLink,
|
|
3381
3450
|
navigationPanel: () => navigationPanel
|
|
3382
3451
|
});
|
|
3452
|
+
//#endregion
|
|
3453
|
+
//#region ../preset/src/text-styles.ts
|
|
3383
3454
|
function defineTextStyles$1(definition) {
|
|
3384
3455
|
return defineTextStyles(definition);
|
|
3385
3456
|
}
|
|
@@ -3473,6 +3544,8 @@ const textStyles = defineTextStyles$1({
|
|
|
3473
3544
|
}
|
|
3474
3545
|
}
|
|
3475
3546
|
});
|
|
3547
|
+
//#endregion
|
|
3548
|
+
//#region ../preset/src/tokens-semantic.ts
|
|
3476
3549
|
const semanticTokens = defineSemanticTokens({ colors: defineSemanticTokens.colors({
|
|
3477
3550
|
white: { value: "#fff" },
|
|
3478
3551
|
black: { value: "#000" },
|
|
@@ -3708,12 +3781,16 @@ const semanticTokens = defineSemanticTokens({ colors: defineSemanticTokens.color
|
|
|
3708
3781
|
}
|
|
3709
3782
|
}
|
|
3710
3783
|
}) });
|
|
3784
|
+
//#endregion
|
|
3785
|
+
//#region ../preset/src/tokens.colors.ts
|
|
3711
3786
|
const colors = defineTokens.colors({
|
|
3712
3787
|
mantine: tokens$1.colors.mantine,
|
|
3713
3788
|
transparent: { value: "transparent" },
|
|
3714
3789
|
none: { value: "none" },
|
|
3715
3790
|
inherit: { value: "inherit" }
|
|
3716
3791
|
});
|
|
3792
|
+
//#endregion
|
|
3793
|
+
//#region ../preset/src/tokens.ts
|
|
3717
3794
|
const tokens = defineTokens({
|
|
3718
3795
|
fontSizes: {
|
|
3719
3796
|
"xxs": { value: "10px" },
|
|
@@ -3926,6 +4003,8 @@ const tokens = defineTokens({
|
|
|
3926
4003
|
}
|
|
3927
4004
|
}
|
|
3928
4005
|
});
|
|
4006
|
+
//#endregion
|
|
4007
|
+
//#region ../preset/src/utilities.ts
|
|
3929
4008
|
const durationValues = [
|
|
3930
4009
|
"fastest",
|
|
3931
4010
|
"faster",
|
|
@@ -3948,6 +4027,8 @@ const utilities = { extend: { transition: defineUtility({
|
|
|
3948
4027
|
};
|
|
3949
4028
|
}
|
|
3950
4029
|
}) } };
|
|
4030
|
+
//#endregion
|
|
4031
|
+
//#region ../preset/src/index.ts
|
|
3951
4032
|
const theme = {
|
|
3952
4033
|
breakpoints,
|
|
3953
4034
|
textStyles,
|
|
@@ -3977,4 +4058,5 @@ var src_default = /* @__PURE__ */ definePreset({
|
|
|
3977
4058
|
utilities,
|
|
3978
4059
|
theme: { extend: theme }
|
|
3979
4060
|
});
|
|
4061
|
+
//#endregion
|
|
3980
4062
|
export { src_default as default, theme };
|
package/vars/vars.mjs
CHANGED
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
//#endregion
|
|
2
|
+
//#region ../preset/src/index.ts
|
|
1
3
|
const vars = {
|
|
2
4
|
likec4: {
|
|
3
5
|
font: "--likec4-app-font",
|
|
@@ -412,4 +414,5 @@ const vars = {
|
|
|
412
414
|
lightSelector: "[data-mantine-color-scheme=\"light\"] &"
|
|
413
415
|
}
|
|
414
416
|
};
|
|
417
|
+
//#endregion
|
|
415
418
|
export { vars as default };
|