@noya-app/noya-designsystem 0.1.37 → 0.1.38
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/.turbo/turbo-build.log +10 -10
- package/CHANGELOG.md +6 -0
- package/dist/index.css +1 -1
- package/dist/index.d.mts +343 -23
- package/dist/index.d.ts +343 -23
- package/dist/index.js +396 -128
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +400 -129
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
- package/src/components/Button.tsx +1 -1
- package/src/components/Checkbox.tsx +2 -0
- package/src/components/Chip.tsx +15 -8
- package/src/components/DraggableMenuButton.tsx +3 -2
- package/src/components/FillPreviewBackground.tsx +10 -9
- package/src/components/FloatingWindow.tsx +5 -6
- package/src/components/IconButton.tsx +5 -1
- package/src/components/InputField.tsx +95 -68
- package/src/components/InspectorContainer.tsx +2 -2
- package/src/components/InspectorPrimitives.tsx +19 -9
- package/src/components/Label.tsx +1 -1
- package/src/components/ListView.tsx +19 -32
- package/src/components/RadioGroup.tsx +1 -1
- package/src/components/SelectMenu.tsx +3 -3
- package/src/components/Switch.tsx +1 -1
- package/src/components/Text.tsx +20 -7
- package/src/components/TextArea.tsx +1 -1
- package/src/components/Tooltip.tsx +1 -1
- package/src/components/WorkspaceLayout.tsx +4 -3
- package/src/components/internal/TextInput.tsx +1 -0
- package/src/index.css +12 -2
- package/src/index.tsx +0 -1
- package/src/theme/index.ts +6 -3
- package/src/theme/themeUtils.ts +72 -0
- package/src/utils/tailwind.ts +4 -12
- package/tailwind.config.ts +16 -3
package/dist/index.js
CHANGED
|
@@ -1458,6 +1458,7 @@ __export(src_exports, {
|
|
|
1458
1458
|
WorkspaceLayout: () => WorkspaceLayout,
|
|
1459
1459
|
cn: () => cn,
|
|
1460
1460
|
createSectionedMenu: () => createSectionedMenu,
|
|
1461
|
+
cssVars: () => cssVars,
|
|
1461
1462
|
fuzzyFilter: () => fuzzyFilter,
|
|
1462
1463
|
fuzzyScore: () => fuzzyScore,
|
|
1463
1464
|
fuzzyTokenize: () => fuzzyTokenize,
|
|
@@ -1496,12 +1497,12 @@ var import_react = __toESM(require("react"));
|
|
|
1496
1497
|
|
|
1497
1498
|
// ../../node_modules/tailwind-merge/dist/bundle-mjs.mjs
|
|
1498
1499
|
var CLASS_PART_SEPARATOR = "-";
|
|
1499
|
-
var createClassGroupUtils = (
|
|
1500
|
-
const classMap = createClassMap(
|
|
1500
|
+
var createClassGroupUtils = (config2) => {
|
|
1501
|
+
const classMap = createClassMap(config2);
|
|
1501
1502
|
const {
|
|
1502
1503
|
conflictingClassGroups,
|
|
1503
1504
|
conflictingClassGroupModifiers
|
|
1504
|
-
} =
|
|
1505
|
+
} = config2;
|
|
1505
1506
|
const getClassGroupId = (className) => {
|
|
1506
1507
|
const classParts = className.split(CLASS_PART_SEPARATOR);
|
|
1507
1508
|
if (classParts[0] === "" && classParts.length !== 1) {
|
|
@@ -1549,22 +1550,22 @@ var getGroupIdForArbitraryProperty = (className) => {
|
|
|
1549
1550
|
}
|
|
1550
1551
|
}
|
|
1551
1552
|
};
|
|
1552
|
-
var createClassMap = (
|
|
1553
|
+
var createClassMap = (config2) => {
|
|
1553
1554
|
const {
|
|
1554
|
-
theme
|
|
1555
|
+
theme,
|
|
1555
1556
|
prefix
|
|
1556
|
-
} =
|
|
1557
|
+
} = config2;
|
|
1557
1558
|
const classMap = {
|
|
1558
1559
|
nextPart: /* @__PURE__ */ new Map(),
|
|
1559
1560
|
validators: []
|
|
1560
1561
|
};
|
|
1561
|
-
const prefixedClassGroupEntries = getPrefixedClassGroupEntries(Object.entries(
|
|
1562
|
+
const prefixedClassGroupEntries = getPrefixedClassGroupEntries(Object.entries(config2.classGroups), prefix);
|
|
1562
1563
|
prefixedClassGroupEntries.forEach(([classGroupId, classGroup]) => {
|
|
1563
|
-
processClassesRecursively(classGroup, classMap, classGroupId,
|
|
1564
|
+
processClassesRecursively(classGroup, classMap, classGroupId, theme);
|
|
1564
1565
|
});
|
|
1565
1566
|
return classMap;
|
|
1566
1567
|
};
|
|
1567
|
-
var processClassesRecursively = (classGroup, classPartObject, classGroupId,
|
|
1568
|
+
var processClassesRecursively = (classGroup, classPartObject, classGroupId, theme) => {
|
|
1568
1569
|
classGroup.forEach((classDefinition) => {
|
|
1569
1570
|
if (typeof classDefinition === "string") {
|
|
1570
1571
|
const classPartObjectToEdit = classDefinition === "" ? classPartObject : getPart(classPartObject, classDefinition);
|
|
@@ -1573,7 +1574,7 @@ var processClassesRecursively = (classGroup, classPartObject, classGroupId, them
|
|
|
1573
1574
|
}
|
|
1574
1575
|
if (typeof classDefinition === "function") {
|
|
1575
1576
|
if (isThemeGetter(classDefinition)) {
|
|
1576
|
-
processClassesRecursively(classDefinition(
|
|
1577
|
+
processClassesRecursively(classDefinition(theme), classPartObject, classGroupId, theme);
|
|
1577
1578
|
return;
|
|
1578
1579
|
}
|
|
1579
1580
|
classPartObject.validators.push({
|
|
@@ -1583,7 +1584,7 @@ var processClassesRecursively = (classGroup, classPartObject, classGroupId, them
|
|
|
1583
1584
|
return;
|
|
1584
1585
|
}
|
|
1585
1586
|
Object.entries(classDefinition).forEach(([key, classGroup2]) => {
|
|
1586
|
-
processClassesRecursively(classGroup2, getPart(classPartObject, key), classGroupId,
|
|
1587
|
+
processClassesRecursively(classGroup2, getPart(classPartObject, key), classGroupId, theme);
|
|
1587
1588
|
});
|
|
1588
1589
|
});
|
|
1589
1590
|
};
|
|
@@ -1659,11 +1660,11 @@ var createLruCache = (maxCacheSize) => {
|
|
|
1659
1660
|
};
|
|
1660
1661
|
};
|
|
1661
1662
|
var IMPORTANT_MODIFIER = "!";
|
|
1662
|
-
var createParseClassName = (
|
|
1663
|
+
var createParseClassName = (config2) => {
|
|
1663
1664
|
const {
|
|
1664
1665
|
separator,
|
|
1665
1666
|
experimentalParseClassName
|
|
1666
|
-
} =
|
|
1667
|
+
} = config2;
|
|
1667
1668
|
const isSeparatorSingleCharacter = separator.length === 1;
|
|
1668
1669
|
const firstSeparatorCharacter = separator[0];
|
|
1669
1670
|
const separatorLength = separator.length;
|
|
@@ -1728,10 +1729,10 @@ var sortModifiers = (modifiers) => {
|
|
|
1728
1729
|
sortedModifiers.push(...unsortedModifiers.sort());
|
|
1729
1730
|
return sortedModifiers;
|
|
1730
1731
|
};
|
|
1731
|
-
var createConfigUtils = (
|
|
1732
|
-
cache: createLruCache(
|
|
1733
|
-
parseClassName: createParseClassName(
|
|
1734
|
-
...createClassGroupUtils(
|
|
1732
|
+
var createConfigUtils = (config2) => ({
|
|
1733
|
+
cache: createLruCache(config2.cacheSize),
|
|
1734
|
+
parseClassName: createParseClassName(config2),
|
|
1735
|
+
...createClassGroupUtils(config2)
|
|
1735
1736
|
});
|
|
1736
1737
|
var SPLIT_CLASSES_REGEX = /\s+/;
|
|
1737
1738
|
var mergeClassList = (classList, configUtils) => {
|
|
@@ -1818,8 +1819,8 @@ function createTailwindMerge(createConfigFirst, ...createConfigRest) {
|
|
|
1818
1819
|
let cacheSet;
|
|
1819
1820
|
let functionToCall = initTailwindMerge;
|
|
1820
1821
|
function initTailwindMerge(classList) {
|
|
1821
|
-
const
|
|
1822
|
-
configUtils = createConfigUtils(
|
|
1822
|
+
const config2 = createConfigRest.reduce((previousConfig, createConfigCurrent) => createConfigCurrent(previousConfig), createConfigFirst());
|
|
1823
|
+
configUtils = createConfigUtils(config2);
|
|
1823
1824
|
cacheGet = configUtils.cache.get;
|
|
1824
1825
|
cacheSet = configUtils.cache.set;
|
|
1825
1826
|
functionToCall = tailwindMerge;
|
|
@@ -1839,7 +1840,7 @@ function createTailwindMerge(createConfigFirst, ...createConfigRest) {
|
|
|
1839
1840
|
};
|
|
1840
1841
|
}
|
|
1841
1842
|
var fromTheme = (key) => {
|
|
1842
|
-
const themeGetter = (
|
|
1843
|
+
const themeGetter = (theme) => theme[key] || [];
|
|
1843
1844
|
themeGetter.isThemeGetter = true;
|
|
1844
1845
|
return themeGetter;
|
|
1845
1846
|
};
|
|
@@ -3956,9 +3957,6 @@ var twMerge = /* @__PURE__ */ createTailwindMerge(getDefaultConfig);
|
|
|
3956
3957
|
|
|
3957
3958
|
// src/utils/tailwind.ts
|
|
3958
3959
|
var cn = (...classes) => twMerge(classes.filter(Boolean));
|
|
3959
|
-
function camelCaseToKebabCase(string) {
|
|
3960
|
-
return string.replace(/([a-z])([A-Z])/g, "$1-$2").toLowerCase();
|
|
3961
|
-
}
|
|
3962
3960
|
|
|
3963
3961
|
// src/components/ActivityIndicator.tsx
|
|
3964
3962
|
var ActivityIndicator = (0, import_react.memo)(function ActivityIndicator2({
|
|
@@ -4056,6 +4054,30 @@ var import_react4 = __toESM(require("react"));
|
|
|
4056
4054
|
|
|
4057
4055
|
// src/components/Text.tsx
|
|
4058
4056
|
var import_react3 = __toESM(require("react"));
|
|
4057
|
+
|
|
4058
|
+
// src/theme/themeUtils.ts
|
|
4059
|
+
function camelToKebabCase(str) {
|
|
4060
|
+
return str.replace(/([A-Z])/g, "-$1").toLowerCase();
|
|
4061
|
+
}
|
|
4062
|
+
function kebabToCamelCase(str) {
|
|
4063
|
+
return str.replace(
|
|
4064
|
+
/-([a-z])/g,
|
|
4065
|
+
(_, letter) => letter.toUpperCase()
|
|
4066
|
+
);
|
|
4067
|
+
}
|
|
4068
|
+
function convertKebabToCamelCase(obj) {
|
|
4069
|
+
if (Array.isArray(obj) || obj instanceof Set || obj instanceof Map) {
|
|
4070
|
+
return obj;
|
|
4071
|
+
}
|
|
4072
|
+
const result = {};
|
|
4073
|
+
for (const [key, value] of Object.entries(obj)) {
|
|
4074
|
+
const camelKey = kebabToCamelCase(key);
|
|
4075
|
+
result[camelKey] = value && typeof value === "object" && !Array.isArray(value) && !(value instanceof Set) && !(value instanceof Map) ? convertKebabToCamelCase(value) : value;
|
|
4076
|
+
}
|
|
4077
|
+
return result;
|
|
4078
|
+
}
|
|
4079
|
+
|
|
4080
|
+
// src/components/Text.tsx
|
|
4059
4081
|
var elements = {
|
|
4060
4082
|
title: "h1",
|
|
4061
4083
|
subtitle: "h1",
|
|
@@ -4102,7 +4124,7 @@ var Text = (0, import_react3.forwardRef)(function Text2({
|
|
|
4102
4124
|
Component3,
|
|
4103
4125
|
{
|
|
4104
4126
|
ref: forwardedRef,
|
|
4105
|
-
className: `${textStyles[variant]} text-${
|
|
4127
|
+
className: `${textStyles[variant]} text-${camelToKebabCase(String(color)) ?? "text"} ${className ?? ""}`,
|
|
4106
4128
|
style: style5,
|
|
4107
4129
|
tabIndex,
|
|
4108
4130
|
onClick,
|
|
@@ -4153,7 +4175,7 @@ var Tooltip = (0, import_react4.memo)(function Tooltip2({ children: children2, c
|
|
|
4153
4175
|
align: "center",
|
|
4154
4176
|
sideOffset: 2,
|
|
4155
4177
|
collisionPadding: 8,
|
|
4156
|
-
className: `${textStyles.small} text-text rounded-[3px] py-small px-medium bg-popover-background shadow-[
|
|
4178
|
+
className: `${textStyles.small} text-text rounded-[3px] py-small px-medium bg-popover-background shadow-[0_2px_4px_rgba(0,0,0,0.2)_0_0_12px_rgba(0,0,0,0.1)] border border-solid border-divider-strong`
|
|
4157
4179
|
},
|
|
4158
4180
|
content
|
|
4159
4181
|
))));
|
|
@@ -4198,7 +4220,7 @@ var Button = (0, import_react5.forwardRef)(function Button2({
|
|
|
4198
4220
|
{
|
|
4199
4221
|
ref: forwardedRef,
|
|
4200
4222
|
id,
|
|
4201
|
-
className: `no-underline leading-[1] relative border-0 outline-none select-none text-left rounded flex items-center justify-center [&>*]:pointer-events-none [-webkit-app-region:no-drag] focus:ring-2 focus:ring-primary focus:
|
|
4223
|
+
className: `no-underline leading-[1] relative border-0 outline-none select-none text-left rounded flex items-center justify-center [&>*]:pointer-events-none [-webkit-app-region:no-drag] focus:ring-2 focus:ring-primary focus:shadow-[0_0_0_1px_var(--popover-background)_inset] ${disabled ? "opacity-25" : ""} ${!className?.includes("flex") ? "flex-none" : ""} ${active ? "bg-primary text-white hover:bg-primary-light active:bg-primary" : variantStyles[variant]} ${sizeStyles[variant === "thin" ? "thin" : variant === "floating" && size3 !== "small" ? "floating" : variant === "none" ? "none" : size3]} ${className ?? ""}`,
|
|
4202
4224
|
style: style5,
|
|
4203
4225
|
tabIndex,
|
|
4204
4226
|
disabled,
|
|
@@ -4254,6 +4276,7 @@ var Checkbox = (0, import_react6.memo)(
|
|
|
4254
4276
|
focus:ring-2
|
|
4255
4277
|
focus:ring-primary
|
|
4256
4278
|
focus:ring-offset-1
|
|
4279
|
+
focus:z-interactable
|
|
4257
4280
|
`,
|
|
4258
4281
|
style: {
|
|
4259
4282
|
width: "27px",
|
|
@@ -4274,6 +4297,7 @@ var Checkbox = (0, import_react6.memo)(
|
|
|
4274
4297
|
stroke-white
|
|
4275
4298
|
opacity-0
|
|
4276
4299
|
peer-checked:opacity-100
|
|
4300
|
+
z-label
|
|
4277
4301
|
`,
|
|
4278
4302
|
style: {
|
|
4279
4303
|
strokeWidth: "1.3"
|
|
@@ -4396,6 +4420,244 @@ function useHover(props = {}) {
|
|
|
4396
4420
|
};
|
|
4397
4421
|
}
|
|
4398
4422
|
|
|
4423
|
+
// tailwind.config.ts
|
|
4424
|
+
var config = {
|
|
4425
|
+
content: ["./src/**/*.{ts,tsx}"],
|
|
4426
|
+
corePlugins: {
|
|
4427
|
+
// disables @tailwind base global styles
|
|
4428
|
+
preflight: false
|
|
4429
|
+
},
|
|
4430
|
+
theme: {
|
|
4431
|
+
extend: {
|
|
4432
|
+
colors: {
|
|
4433
|
+
"logo-fill": "var(--logo-fill)",
|
|
4434
|
+
"logo-highlight": "var(--logo-highlight)",
|
|
4435
|
+
background: "var(--background)",
|
|
4436
|
+
text: "var(--text)",
|
|
4437
|
+
"text-muted": "var(--text-muted)",
|
|
4438
|
+
"text-subtle": "var(--text-subtle)",
|
|
4439
|
+
"text-disabled": "var(--text-disabled)",
|
|
4440
|
+
"text-decorative-light": "var(--text-decorative-light)",
|
|
4441
|
+
"divider-subtle": "var(--divider-subtle)",
|
|
4442
|
+
divider: "var(--divider)",
|
|
4443
|
+
"divider-strong": "var(--divider-strong)",
|
|
4444
|
+
primary: "var(--primary)",
|
|
4445
|
+
"primary-light": "var(--primary-light)",
|
|
4446
|
+
"primary-pastel": "var(--primary-pastel)",
|
|
4447
|
+
secondary: "var(--secondary)",
|
|
4448
|
+
"secondary-light": "var(--secondary-light)",
|
|
4449
|
+
"secondary-pastel": "var(--secondary-pastel)",
|
|
4450
|
+
"secondary-bright": "var(--secondary-bright)",
|
|
4451
|
+
"input-background": "var(--input-background)",
|
|
4452
|
+
"input-background-light": "var(--input-background-light)",
|
|
4453
|
+
"code-background": "var(--code-background)",
|
|
4454
|
+
"code-background-dark": "var(--code-background-dark)",
|
|
4455
|
+
"selected-background": "var(--selected-background)",
|
|
4456
|
+
"breadcrumb-text": "var(--breadcrumb-text)",
|
|
4457
|
+
"breadcrumb-text-hover": "var(--breadcrumb-text-hover)",
|
|
4458
|
+
"breadcrumb-icon": "var(--breadcrumb-icon)",
|
|
4459
|
+
"canvas-background": "var(--canvas-background)",
|
|
4460
|
+
"canvas-grid": "var(--canvas-grid)",
|
|
4461
|
+
"sidebar-background": "var(--sidebar-background)",
|
|
4462
|
+
"sidebar-background-transparent": "var(--sidebar-background-transparent)",
|
|
4463
|
+
"popover-background": "var(--popover-background)",
|
|
4464
|
+
"popover-divider": "var(--popover-divider)",
|
|
4465
|
+
"listview-raised-background": "var(--listview-raised-background)",
|
|
4466
|
+
"listview-editing-background": "var(--listview-editing-background)",
|
|
4467
|
+
"slider-background": "var(--slider-background)",
|
|
4468
|
+
"slider-border": "var(--slider-border)",
|
|
4469
|
+
"radio-group-background": "var(--radio-group-background)",
|
|
4470
|
+
mask: "var(--mask)",
|
|
4471
|
+
"transparent-checker": "var(--transparent-checker)",
|
|
4472
|
+
scrollbar: "var(--scrollbar)",
|
|
4473
|
+
"placeholder-dots": "var(--placeholder-dots)",
|
|
4474
|
+
"drag-outline": "var(--drag-outline)",
|
|
4475
|
+
"active-background": "var(--active-background)",
|
|
4476
|
+
"thumbnail-background": "var(--thumbnail-background)",
|
|
4477
|
+
"thumbnail-shadow": "var(--thumbnail-shadow)",
|
|
4478
|
+
"inline-code-text": "var(--inline-code-text)",
|
|
4479
|
+
"inline-code-background": "var(--inline-code-background)",
|
|
4480
|
+
"text-link": "var(--text-link)",
|
|
4481
|
+
"text-link-focused": "var(--text-link-focused)",
|
|
4482
|
+
icon: "var(--icon)",
|
|
4483
|
+
"icon-selected": "var(--icon-selected)",
|
|
4484
|
+
warning: "var(--warning)",
|
|
4485
|
+
"radio-group-item": "var(--radio-group-item)",
|
|
4486
|
+
dot: "var(--dot)",
|
|
4487
|
+
"row-highlight": "var(--row-highlight)",
|
|
4488
|
+
"table-row-background": "var(--table-row-background)",
|
|
4489
|
+
"chip-primary-bg": "var(--chip-primary-bg)",
|
|
4490
|
+
"chip-secondary-bg": "var(--chip-secondary-bg)",
|
|
4491
|
+
"chip-error-bg": "var(--chip-error-bg)",
|
|
4492
|
+
"chip-default-bg": "var(--chip-default-bg)",
|
|
4493
|
+
"chip-primary-shadow": "var(--chip-primary-shadow)",
|
|
4494
|
+
"chip-secondary-shadow": "var(--chip-secondary-shadow)",
|
|
4495
|
+
"chip-error-shadow": "var(--chip-error-shadow)",
|
|
4496
|
+
"chip-default-shadow": "var(--chip-default-shadow)"
|
|
4497
|
+
},
|
|
4498
|
+
fontFamily: {
|
|
4499
|
+
sans: [
|
|
4500
|
+
"__Inter_6b0edc",
|
|
4501
|
+
"__Inter_Fallback_6b0edc",
|
|
4502
|
+
"-apple-system",
|
|
4503
|
+
"BlinkMacSystemFont",
|
|
4504
|
+
"Helvetica Neue",
|
|
4505
|
+
"Segoe UI",
|
|
4506
|
+
"Roboto",
|
|
4507
|
+
"Helvetica",
|
|
4508
|
+
"Arial",
|
|
4509
|
+
"sans-serif"
|
|
4510
|
+
],
|
|
4511
|
+
mono: ["Menlo", "Monaco", "Consolas", "Courier New", "monospace"]
|
|
4512
|
+
},
|
|
4513
|
+
// Type scale
|
|
4514
|
+
// The last one, 0.85, I just eyeballed
|
|
4515
|
+
// old: typeScale = [3.052, 2.441, 1.953, 1.563, 1.25, 1, 0.85]; // Major third
|
|
4516
|
+
fontSize: {
|
|
4517
|
+
title: [
|
|
4518
|
+
"3.052rem",
|
|
4519
|
+
{
|
|
4520
|
+
lineHeight: "1.4",
|
|
4521
|
+
letterSpacing: "-0.05em"
|
|
4522
|
+
}
|
|
4523
|
+
],
|
|
4524
|
+
subtitle: [
|
|
4525
|
+
"1.563rem",
|
|
4526
|
+
{
|
|
4527
|
+
lineHeight: "1.75",
|
|
4528
|
+
letterSpacing: "-0.05em"
|
|
4529
|
+
}
|
|
4530
|
+
],
|
|
4531
|
+
heading1: [
|
|
4532
|
+
"1.953rem",
|
|
4533
|
+
{
|
|
4534
|
+
lineHeight: "1.6",
|
|
4535
|
+
letterSpacing: "-0.025em"
|
|
4536
|
+
}
|
|
4537
|
+
],
|
|
4538
|
+
heading2: [
|
|
4539
|
+
"1.563rem",
|
|
4540
|
+
{
|
|
4541
|
+
lineHeight: "1.5",
|
|
4542
|
+
letterSpacing: "-0.025em"
|
|
4543
|
+
}
|
|
4544
|
+
],
|
|
4545
|
+
heading3: [
|
|
4546
|
+
"1.25rem",
|
|
4547
|
+
{
|
|
4548
|
+
lineHeight: "1.4",
|
|
4549
|
+
letterSpacing: "-0.025em"
|
|
4550
|
+
}
|
|
4551
|
+
],
|
|
4552
|
+
heading4: [
|
|
4553
|
+
"1rem",
|
|
4554
|
+
{
|
|
4555
|
+
lineHeight: "1.4"
|
|
4556
|
+
}
|
|
4557
|
+
],
|
|
4558
|
+
heading5: [
|
|
4559
|
+
"0.85rem",
|
|
4560
|
+
{
|
|
4561
|
+
lineHeight: "1.4"
|
|
4562
|
+
}
|
|
4563
|
+
],
|
|
4564
|
+
body: [
|
|
4565
|
+
"1",
|
|
4566
|
+
{
|
|
4567
|
+
lineHeight: "1.4"
|
|
4568
|
+
}
|
|
4569
|
+
],
|
|
4570
|
+
small: [
|
|
4571
|
+
"1",
|
|
4572
|
+
{
|
|
4573
|
+
lineHeight: "19px"
|
|
4574
|
+
}
|
|
4575
|
+
],
|
|
4576
|
+
code: [
|
|
4577
|
+
"90%",
|
|
4578
|
+
{
|
|
4579
|
+
lineHeight: "1.5"
|
|
4580
|
+
}
|
|
4581
|
+
],
|
|
4582
|
+
button: [
|
|
4583
|
+
"0.8rem",
|
|
4584
|
+
{
|
|
4585
|
+
lineHeight: "1.4",
|
|
4586
|
+
letterSpacing: "-0.2px"
|
|
4587
|
+
}
|
|
4588
|
+
],
|
|
4589
|
+
label: [
|
|
4590
|
+
"0.62rem",
|
|
4591
|
+
{
|
|
4592
|
+
lineHeight: "19px",
|
|
4593
|
+
letterSpacing: "-0.3px"
|
|
4594
|
+
}
|
|
4595
|
+
]
|
|
4596
|
+
},
|
|
4597
|
+
spacing: {
|
|
4598
|
+
nano: "2px",
|
|
4599
|
+
micro: "4px",
|
|
4600
|
+
small: "8px",
|
|
4601
|
+
medium: "16px",
|
|
4602
|
+
large: "32px",
|
|
4603
|
+
xlarge: "64px",
|
|
4604
|
+
xxlarge: "128px",
|
|
4605
|
+
"inset-top": "var(--inset-top)",
|
|
4606
|
+
"sidebar-width": "var(--sidebar-width)",
|
|
4607
|
+
"toolbar-height": "var(--toolbar-height)",
|
|
4608
|
+
"toolbar-separator": "var(--toolbar-separator)",
|
|
4609
|
+
"inspector-h-separator": "var(--inspector-h-separator)",
|
|
4610
|
+
"inspector-v-separator": "var(--inspector-v-separator)",
|
|
4611
|
+
"dialog-padding": "var(--dialog-padding)"
|
|
4612
|
+
},
|
|
4613
|
+
keyframes: {
|
|
4614
|
+
spin: {
|
|
4615
|
+
"0%": { transform: "rotate(0deg)" },
|
|
4616
|
+
"100%": { transform: "rotate(360deg)" }
|
|
4617
|
+
},
|
|
4618
|
+
shimmer: {
|
|
4619
|
+
"0%": {
|
|
4620
|
+
backgroundPosition: "-200% 0"
|
|
4621
|
+
},
|
|
4622
|
+
"100%": {
|
|
4623
|
+
backgroundPosition: "200% 0"
|
|
4624
|
+
}
|
|
4625
|
+
}
|
|
4626
|
+
},
|
|
4627
|
+
animation: {
|
|
4628
|
+
spin: "spin 1s linear infinite",
|
|
4629
|
+
shimmer: "shimmer 6s infinite linear"
|
|
4630
|
+
},
|
|
4631
|
+
zIndex: {
|
|
4632
|
+
interactable: "var(--interactable-z-index)",
|
|
4633
|
+
label: "var(--label-z-index)"
|
|
4634
|
+
}
|
|
4635
|
+
}
|
|
4636
|
+
},
|
|
4637
|
+
safelist: [
|
|
4638
|
+
"group",
|
|
4639
|
+
"group-hover:flex",
|
|
4640
|
+
"bg-row-highlight",
|
|
4641
|
+
"left-5",
|
|
4642
|
+
"right-6",
|
|
4643
|
+
"m-[0_-24px_0_-20px]",
|
|
4644
|
+
"p-[0_24px_0_20px]",
|
|
4645
|
+
"left-0",
|
|
4646
|
+
"border-divider-strong",
|
|
4647
|
+
"decoration-text-decorative-light",
|
|
4648
|
+
"underline",
|
|
4649
|
+
"-left-2.5",
|
|
4650
|
+
"-mr-2",
|
|
4651
|
+
"border-gray-200",
|
|
4652
|
+
"gap-1.5",
|
|
4653
|
+
"gap-toolbar-separator"
|
|
4654
|
+
]
|
|
4655
|
+
};
|
|
4656
|
+
var tailwind_config_default = config;
|
|
4657
|
+
|
|
4658
|
+
// src/theme/index.ts
|
|
4659
|
+
var cssVars = convertKebabToCamelCase(tailwind_config_default.theme.extend);
|
|
4660
|
+
|
|
4399
4661
|
// src/components/Chip.tsx
|
|
4400
4662
|
function getChipStyles({
|
|
4401
4663
|
$colorScheme,
|
|
@@ -4416,27 +4678,33 @@ function getChipStyles({
|
|
|
4416
4678
|
small: "text-[9px] p-[0px_4px]"
|
|
4417
4679
|
}[$size];
|
|
4418
4680
|
const fontStyles = $monospace ? "font-mono" : "";
|
|
4681
|
+
const shadowStyles = {
|
|
4682
|
+
primary: "shadow-[0_0_0_1px_var(--chip-primary-shadow)_inset]",
|
|
4683
|
+
secondary: "shadow-[0_0_0_1px_var(--chip-secondary-shadow)_inset]",
|
|
4684
|
+
error: "shadow-[0_0_0_1px_var(--chip-error-shadow)_inset]",
|
|
4685
|
+
default: "shadow-[0_0_0_1px_var(--chip-default-shadow)_inset]"
|
|
4686
|
+
};
|
|
4419
4687
|
const variantStyles2 = (() => {
|
|
4420
4688
|
const colors = {
|
|
4421
4689
|
primary: {
|
|
4422
4690
|
text: "text-primary",
|
|
4423
4691
|
bg: "bg-primary-pastel",
|
|
4424
|
-
subtle: "bg-[
|
|
4692
|
+
subtle: "bg-[var(--chip-primary-bg)]"
|
|
4425
4693
|
},
|
|
4426
4694
|
secondary: {
|
|
4427
4695
|
text: "text-secondary",
|
|
4428
4696
|
bg: "bg-secondary-pastel",
|
|
4429
|
-
subtle: "bg-[
|
|
4697
|
+
subtle: "bg-[var(--chip-secondary-bg)]"
|
|
4430
4698
|
},
|
|
4431
4699
|
error: {
|
|
4432
4700
|
text: "text-text",
|
|
4433
4701
|
bg: "bg-[rgb(255,219,219)]",
|
|
4434
|
-
subtle: "bg-[
|
|
4702
|
+
subtle: "bg-[var(--chip-error-bg)]"
|
|
4435
4703
|
},
|
|
4436
4704
|
default: {
|
|
4437
4705
|
text: "text-text",
|
|
4438
4706
|
bg: "bg-input-background",
|
|
4439
|
-
subtle: "bg-[
|
|
4707
|
+
subtle: "bg-[var(--chip-default-bg)]"
|
|
4440
4708
|
}
|
|
4441
4709
|
}[$colorScheme ?? "default"];
|
|
4442
4710
|
if ($variant === "solid") {
|
|
@@ -4445,7 +4713,7 @@ function getChipStyles({
|
|
|
4445
4713
|
if ($variant === "outlined") {
|
|
4446
4714
|
return `
|
|
4447
4715
|
${colors.text} bg-transparent
|
|
4448
|
-
|
|
4716
|
+
${shadowStyles[$colorScheme ?? "default"]}
|
|
4449
4717
|
hover:${colors.subtle} hover:shadow-none
|
|
4450
4718
|
`;
|
|
4451
4719
|
}
|
|
@@ -4498,7 +4766,7 @@ var Chip = (0, import_react7.memo)(
|
|
|
4498
4766
|
onHoverChange: onHoverDeleteChange
|
|
4499
4767
|
});
|
|
4500
4768
|
const handleClick = !children2 && !deletable && addable ? onAdd : onClick;
|
|
4501
|
-
const color = colorScheme === "primary" ?
|
|
4769
|
+
const color = colorScheme === "primary" ? cssVars.colors.primary : colorScheme === "secondary" ? cssVars.colors.secondary : cssVars.colors.text;
|
|
4502
4770
|
return /* @__PURE__ */ import_react7.default.createElement(
|
|
4503
4771
|
"span",
|
|
4504
4772
|
{
|
|
@@ -4612,7 +4880,7 @@ var IconButton = (0, import_react10.memo)(
|
|
|
4612
4880
|
return /* @__PURE__ */ import_react10.default.createElement(Button, { ref: forwardedRef, ...props, variant: "none", contentStyle: style5 }, /* @__PURE__ */ import_react10.default.createElement(
|
|
4613
4881
|
Icon,
|
|
4614
4882
|
{
|
|
4615
|
-
color: color ?? (selected ?
|
|
4883
|
+
color: color ?? (selected ? cssVars.colors.iconSelected : cssVars.colors.icon),
|
|
4616
4884
|
...size3 && { width: size3, height: size3 }
|
|
4617
4885
|
}
|
|
4618
4886
|
));
|
|
@@ -5266,7 +5534,8 @@ var ReadOnlyTextInput = (0, import_react31.forwardRef)(function ReadOnlyTextInpu
|
|
|
5266
5534
|
...rest,
|
|
5267
5535
|
value,
|
|
5268
5536
|
onKeyDown,
|
|
5269
|
-
readOnly: true
|
|
5537
|
+
readOnly: true,
|
|
5538
|
+
className: "focus:z-interactable"
|
|
5270
5539
|
}
|
|
5271
5540
|
);
|
|
5272
5541
|
});
|
|
@@ -5504,31 +5773,35 @@ var InputFieldContext = (0, import_react33.createContext)({
|
|
|
5504
5773
|
onFocusChange: () => {
|
|
5505
5774
|
}
|
|
5506
5775
|
});
|
|
5507
|
-
var LabelContainer = (0, import_react33.forwardRef)(
|
|
5508
|
-
|
|
5509
|
-
|
|
5776
|
+
var LabelContainer = (0, import_react33.forwardRef)(function LabelContainer2({
|
|
5777
|
+
labelPosition: $labelPosition,
|
|
5778
|
+
hasDropdown: $hasDropdown,
|
|
5779
|
+
size: $size,
|
|
5780
|
+
className,
|
|
5781
|
+
style: style5,
|
|
5782
|
+
...props
|
|
5783
|
+
}, ref) {
|
|
5784
|
+
const memoizedStyles = (0, import_react33.useMemo)(
|
|
5785
|
+
() => ({
|
|
5510
5786
|
left: $labelPosition === "start" ? $size === "large" ? "6px" : $size === "medium" ? "2px" : "0px" : "",
|
|
5511
|
-
right: $labelPosition === "end" ? $size === "large" ? "6px" : $size === "medium" ? "2px" : "0px" : ""
|
|
5512
|
-
|
|
5513
|
-
|
|
5514
|
-
|
|
5515
|
-
|
|
5516
|
-
|
|
5517
|
-
|
|
5518
|
-
|
|
5519
|
-
|
|
5520
|
-
}
|
|
5521
|
-
|
|
5522
|
-
|
|
5523
|
-
|
|
5787
|
+
right: $labelPosition === "end" ? $size === "large" ? "6px" : $size === "medium" ? "2px" : "0px" : "",
|
|
5788
|
+
...style5
|
|
5789
|
+
}),
|
|
5790
|
+
[$labelPosition, $size, style5]
|
|
5791
|
+
);
|
|
5792
|
+
return /* @__PURE__ */ import_react33.default.createElement(
|
|
5793
|
+
"label",
|
|
5794
|
+
{
|
|
5795
|
+
ref,
|
|
5796
|
+
className: `absolute top-0 bottom-0 flex items-center font-sans text-label font-bold uppercase text-text-disabled select-none z-label pointer-events-none ${$labelPosition === "start" ? `justify-start pl-[6px]` : $labelPosition === "end" ? `justify-end ${$hasDropdown ? "pr-[16px]" : "pr-[6px]"}` : ""} ${className ?? ""}`,
|
|
5797
|
+
style: memoizedStyles,
|
|
5798
|
+
...props
|
|
5799
|
+
}
|
|
5800
|
+
);
|
|
5801
|
+
});
|
|
5524
5802
|
var InputFieldLabel = (0, import_react33.memo)(
|
|
5525
|
-
(0, import_react33.forwardRef)(function InputFieldLabel2({
|
|
5526
|
-
|
|
5527
|
-
pointerEvents = "none",
|
|
5528
|
-
style: style5,
|
|
5529
|
-
className
|
|
5530
|
-
}, forwardedRef) {
|
|
5531
|
-
const { labelPosition, hasDropdown, setLabelWidth, size: size3 } = (0, import_react33.useContext)(InputFieldContext);
|
|
5803
|
+
(0, import_react33.forwardRef)(function InputFieldLabel2(props, forwardedRef) {
|
|
5804
|
+
const { labelPosition, hasDropdown, setLabelWidth, size: size3, id } = (0, import_react33.useContext)(InputFieldContext);
|
|
5532
5805
|
const ref = (0, import_react33.useRef)(null);
|
|
5533
5806
|
(0, import_react33.useLayoutEffect)(() => {
|
|
5534
5807
|
if (!setLabelWidth) return;
|
|
@@ -5539,18 +5812,16 @@ var InputFieldLabel = (0, import_react33.memo)(
|
|
|
5539
5812
|
return /* @__PURE__ */ import_react33.default.createElement(
|
|
5540
5813
|
LabelContainer,
|
|
5541
5814
|
{
|
|
5542
|
-
$size: size3,
|
|
5543
5815
|
ref: (element) => {
|
|
5544
5816
|
ref.current = element;
|
|
5545
5817
|
assignRef(forwardedRef, element);
|
|
5546
5818
|
},
|
|
5547
|
-
|
|
5548
|
-
|
|
5549
|
-
|
|
5550
|
-
|
|
5551
|
-
|
|
5552
|
-
}
|
|
5553
|
-
children2
|
|
5819
|
+
size: size3,
|
|
5820
|
+
labelPosition,
|
|
5821
|
+
hasDropdown,
|
|
5822
|
+
htmlFor: id,
|
|
5823
|
+
...props
|
|
5824
|
+
}
|
|
5554
5825
|
);
|
|
5555
5826
|
})
|
|
5556
5827
|
);
|
|
@@ -5655,10 +5926,13 @@ var InputElement = (0, import_react33.forwardRef)(
|
|
|
5655
5926
|
}, ref) => {
|
|
5656
5927
|
const paddingLeft = ($size === "large" ? 10 : $size === "medium" ? 6 : 4) + ($labelSize && $labelPosition === "start" ? 6 + $labelSize : 0);
|
|
5657
5928
|
const paddingRight = ($size === "large" ? 10 : $size === "medium" ? 6 : 1) + ($labelSize && $labelPosition === "end" ? 6 + $labelSize : 0) + ($hasDropdown ? 11 : 0);
|
|
5658
|
-
const memoizedStyles = (0, import_react33.useMemo)(
|
|
5659
|
-
|
|
5660
|
-
|
|
5661
|
-
|
|
5929
|
+
const memoizedStyles = (0, import_react33.useMemo)(
|
|
5930
|
+
() => ({
|
|
5931
|
+
paddingLeft: `${paddingLeft}px`,
|
|
5932
|
+
paddingRight: `${paddingRight}px`
|
|
5933
|
+
}),
|
|
5934
|
+
[paddingLeft, paddingRight]
|
|
5935
|
+
);
|
|
5662
5936
|
return /* @__PURE__ */ import_react33.default.createElement(
|
|
5663
5937
|
TextInput_default,
|
|
5664
5938
|
{
|
|
@@ -5666,7 +5940,7 @@ var InputElement = (0, import_react33.forwardRef)(
|
|
|
5666
5940
|
onSubmit: onSubmit ?? (() => {
|
|
5667
5941
|
}),
|
|
5668
5942
|
ref,
|
|
5669
|
-
className: `flex w-0 flex-[1_1_0px] relative border-0 outline-none min-w-0 self-stretch rounded bg-input-background focus:ring-2 focus:ring-primary
|
|
5943
|
+
className: `flex w-0 flex-[1_1_0px] relative border-0 outline-none min-w-0 self-stretch rounded bg-input-background focus:ring-2 focus:ring-primary placeholder:text-text-disabled ${readOnly ? "text-text-muted" : disabled ? "text-text-disabled" : "text-text"} font-sans font-normal ${$textAlign && `text-${$textAlign}`} ${$size === "small" ? "text-[11px] leading-[19px] py-[1px]" : $size === "large" ? "py-[10px] text-heading5" : $size === "medium" ? "py-1 text-heading5" : $variant === "bare" && "p-1 -m-1"} ${className ?? ""}`,
|
|
5670
5944
|
style: memoizedStyles,
|
|
5671
5945
|
...props
|
|
5672
5946
|
}
|
|
@@ -5681,7 +5955,8 @@ var InputFieldInput = (0, import_react33.forwardRef)(function InputFieldInput2({
|
|
|
5681
5955
|
buttonSize,
|
|
5682
5956
|
size: size3,
|
|
5683
5957
|
onFocusChange,
|
|
5684
|
-
setInputRef
|
|
5958
|
+
setInputRef,
|
|
5959
|
+
id
|
|
5685
5960
|
} = (0, import_react33.useContext)(InputFieldContext);
|
|
5686
5961
|
const handleFocusChange = (0, import_react33.useCallback)(
|
|
5687
5962
|
(isFocused) => {
|
|
@@ -5703,6 +5978,7 @@ var InputFieldInput = (0, import_react33.forwardRef)(function InputFieldInput2({
|
|
|
5703
5978
|
$variant: variant,
|
|
5704
5979
|
$textAlign: textAlign,
|
|
5705
5980
|
onFocusChange: handleFocusChange,
|
|
5981
|
+
id,
|
|
5706
5982
|
...rest
|
|
5707
5983
|
}
|
|
5708
5984
|
);
|
|
@@ -5817,6 +6093,7 @@ function InputFieldRoot({
|
|
|
5817
6093
|
className
|
|
5818
6094
|
}) {
|
|
5819
6095
|
const childrenArray = import_react33.Children.toArray(children2);
|
|
6096
|
+
const randomId = (0, import_react33.useId)();
|
|
5820
6097
|
const hasDropdown = childrenArray.some(
|
|
5821
6098
|
(child) => (0, import_react33.isValidElement)(child) && child.type === InputFieldDropdownMenu
|
|
5822
6099
|
);
|
|
@@ -5851,7 +6128,8 @@ function InputFieldRoot({
|
|
|
5851
6128
|
inputRef,
|
|
5852
6129
|
setInputRef,
|
|
5853
6130
|
setLabelWidth: setMeasuredLabelSize,
|
|
5854
|
-
setButtonWidth: setMeasuredButtonSize
|
|
6131
|
+
setButtonWidth: setMeasuredButtonSize,
|
|
6132
|
+
id: id ?? randomId
|
|
5855
6133
|
}),
|
|
5856
6134
|
[
|
|
5857
6135
|
labelPosition,
|
|
@@ -5862,13 +6140,14 @@ function InputFieldRoot({
|
|
|
5862
6140
|
size3,
|
|
5863
6141
|
isFocused,
|
|
5864
6142
|
handleFocusChange,
|
|
5865
|
-
inputRef
|
|
6143
|
+
inputRef,
|
|
6144
|
+
id,
|
|
6145
|
+
randomId
|
|
5866
6146
|
]
|
|
5867
6147
|
);
|
|
5868
6148
|
const rootElement = /* @__PURE__ */ import_react33.default.createElement(
|
|
5869
6149
|
RootContainer,
|
|
5870
6150
|
{
|
|
5871
|
-
id,
|
|
5872
6151
|
$width: width,
|
|
5873
6152
|
$flex: flex,
|
|
5874
6153
|
style: style5,
|
|
@@ -5903,7 +6182,7 @@ var PrimitiveInputField = ({
|
|
|
5903
6182
|
}) => /* @__PURE__ */ import_react33.default.createElement(
|
|
5904
6183
|
"input",
|
|
5905
6184
|
{
|
|
5906
|
-
className: `flex w-0 flex-1 relative border-none outline-none min-w-0 self-stretch rounded py-1 px-1.5 bg-input-background select-all pointer-events-[all] focus:ring-2 focus:ring-primary
|
|
6185
|
+
className: `flex w-0 flex-1 relative border-none outline-none min-w-0 self-stretch rounded py-1 px-1.5 bg-input-background select-all pointer-events-[all] focus:ring-2 focus:ring-primary font-sans font-normal text-heading5 placeholder:text-text-disabled focus:z-interactable ${readOnly ? "text-text-muted" : disabled ? "text-text-disabled" : "text-text"} ${className ?? ""}`,
|
|
5907
6186
|
...props
|
|
5908
6187
|
}
|
|
5909
6188
|
);
|
|
@@ -6435,13 +6714,13 @@ var DraggableMenuButton = (0, import_react41.memo)(function DraggableMenuButton2
|
|
|
6435
6714
|
/* @__PURE__ */ import_react41.default.createElement(Trigger5, null, /* @__PURE__ */ import_react41.default.createElement(
|
|
6436
6715
|
import_noya_icons5.DragHandleDots2Icon,
|
|
6437
6716
|
{
|
|
6438
|
-
color: isVisible || open ?
|
|
6717
|
+
color: isVisible || open ? cssVars.colors.icon : "transparent"
|
|
6439
6718
|
}
|
|
6440
6719
|
))
|
|
6441
6720
|
) : /* @__PURE__ */ import_react41.default.createElement(
|
|
6442
6721
|
import_noya_icons5.DragHandleDots2Icon,
|
|
6443
6722
|
{
|
|
6444
|
-
color: isVisible || open ?
|
|
6723
|
+
color: isVisible || open ? cssVars.colors.icon : "transparent"
|
|
6445
6724
|
}
|
|
6446
6725
|
)
|
|
6447
6726
|
);
|
|
@@ -6857,7 +7136,9 @@ var dotsHorizontalSvg = (fillColor) => `
|
|
|
6857
7136
|
<path d='M3.625 7.5C3.625 8.12132 3.12132 8.625 2.5 8.625C1.87868 8.625 1.375 8.12132 1.375 7.5C1.375 6.87868 1.87868 6.375 2.5 6.375C3.12132 6.375 3.625 6.87868 3.625 7.5ZM8.625 7.5C8.625 8.12132 8.12132 8.625 7.5 8.625C6.87868 8.625 6.375 8.12132 6.375 7.5C6.375 6.87868 6.87868 6.375 7.5 6.375C8.12132 6.375 8.625 6.87868 8.625 7.5ZM12.5 8.625C13.1213 8.625 13.625 8.12132 13.625 7.5C13.625 6.87868 13.1213 6.375 12.5 6.375C11.8787 6.375 11.375 6.87868 11.375 7.5C11.375 8.12132 11.8787 8.625 12.5 8.625Z'></path>
|
|
6858
7137
|
</svg>
|
|
6859
7138
|
`;
|
|
6860
|
-
var Background = (0, import_react44.memo)(function Background2({
|
|
7139
|
+
var Background = (0, import_react44.memo)(function Background2({
|
|
7140
|
+
background: background2
|
|
7141
|
+
}) {
|
|
6861
7142
|
return /* @__PURE__ */ import_react44.default.createElement(
|
|
6862
7143
|
"span",
|
|
6863
7144
|
{
|
|
@@ -6914,17 +7195,12 @@ var GradientPreviewBackground = (0, import_react44.memo)(function GradientPrevie
|
|
|
6914
7195
|
return /* @__PURE__ */ import_react44.default.createElement(Background, { background: background2 });
|
|
6915
7196
|
});
|
|
6916
7197
|
var background = `center url("data:image/svg+xml;utf8,${dotsHorizontalSvg(
|
|
6917
|
-
|
|
7198
|
+
cssVars.colors.placeholderDots
|
|
6918
7199
|
)}") no-repeat`;
|
|
6919
7200
|
var FillPreviewBackground = (0, import_react44.memo)(function FillPreviewBackground2({
|
|
6920
7201
|
value
|
|
6921
7202
|
}) {
|
|
6922
|
-
if (!value) return /* @__PURE__ */ import_react44.default.createElement(
|
|
6923
|
-
Background,
|
|
6924
|
-
{
|
|
6925
|
-
background
|
|
6926
|
-
}
|
|
6927
|
-
);
|
|
7203
|
+
if (!value) return /* @__PURE__ */ import_react44.default.createElement(Background, { background });
|
|
6928
7204
|
switch (value._class) {
|
|
6929
7205
|
case "color":
|
|
6930
7206
|
return /* @__PURE__ */ import_react44.default.createElement(ColorPreviewBackground, { color: value });
|
|
@@ -7196,8 +7472,8 @@ var FloatingWindow = ({
|
|
|
7196
7472
|
left: position.x,
|
|
7197
7473
|
width: size3.width,
|
|
7198
7474
|
height: size3.height,
|
|
7199
|
-
outline: `1px solid
|
|
7200
|
-
backgroundColor:
|
|
7475
|
+
outline: `1px solid ${cssVars.colors.divider}`,
|
|
7476
|
+
backgroundColor: cssVars.colors.canvasBackground
|
|
7201
7477
|
}
|
|
7202
7478
|
},
|
|
7203
7479
|
/* @__PURE__ */ import_react46.default.createElement(
|
|
@@ -7205,7 +7481,7 @@ var FloatingWindow = ({
|
|
|
7205
7481
|
{
|
|
7206
7482
|
style: {
|
|
7207
7483
|
...styles2.toolbar,
|
|
7208
|
-
backgroundColor:
|
|
7484
|
+
backgroundColor: cssVars.colors.sidebarBackground
|
|
7209
7485
|
},
|
|
7210
7486
|
onMouseDown: handleMouseDown
|
|
7211
7487
|
},
|
|
@@ -15004,21 +15280,6 @@ function getPositionMargin(marginType) {
|
|
|
15004
15280
|
bottom: marginType === "bottom" || marginType === "vertical" ? 8 : 0
|
|
15005
15281
|
};
|
|
15006
15282
|
}
|
|
15007
|
-
var theme = {
|
|
15008
|
-
colors: {
|
|
15009
|
-
textMuted: "var(--text-muted)",
|
|
15010
|
-
listView: {
|
|
15011
|
-
raisedBackground: "var(--listview-raised-background)"
|
|
15012
|
-
},
|
|
15013
|
-
secondary: "var(--secondary)",
|
|
15014
|
-
primary: "var(--primary)",
|
|
15015
|
-
textDisabled: "var(--text-disabled)",
|
|
15016
|
-
primaryLight: "var(--primary-light)",
|
|
15017
|
-
secondaryLight: "var(--secondary-light)",
|
|
15018
|
-
activeBackground: "var(--active-background)",
|
|
15019
|
-
dividerSubtle: "var(--divider-subtle)"
|
|
15020
|
-
}
|
|
15021
|
-
};
|
|
15022
15283
|
var RowContainer = (0, import_react51.forwardRef)(
|
|
15023
15284
|
({
|
|
15024
15285
|
className,
|
|
@@ -15036,6 +15297,8 @@ var RowContainer = (0, import_react51.forwardRef)(
|
|
|
15036
15297
|
$gap,
|
|
15037
15298
|
$backgroundColor,
|
|
15038
15299
|
style: style5,
|
|
15300
|
+
"aria-describedby": _,
|
|
15301
|
+
// Causes hydration warning
|
|
15039
15302
|
...props
|
|
15040
15303
|
}, ref) => {
|
|
15041
15304
|
const margin = getPositionMargin($marginType);
|
|
@@ -15063,19 +15326,19 @@ var RowContainer = (0, import_react51.forwardRef)(
|
|
|
15063
15326
|
marginBottom: `${margin.bottom}px`
|
|
15064
15327
|
}
|
|
15065
15328
|
},
|
|
15066
|
-
color:
|
|
15329
|
+
color: cssVars.colors.textMuted,
|
|
15067
15330
|
...$isSectionHeader && {
|
|
15068
|
-
backgroundColor:
|
|
15331
|
+
backgroundColor: cssVars.colors.listviewRaisedBackground,
|
|
15069
15332
|
...$sectionHeaderVariant === "label" && {
|
|
15070
|
-
color:
|
|
15333
|
+
color: cssVars.colors.textDisabled
|
|
15071
15334
|
}
|
|
15072
15335
|
},
|
|
15073
15336
|
...$disabled && {
|
|
15074
|
-
color:
|
|
15337
|
+
color: cssVars.colors.textDisabled
|
|
15075
15338
|
},
|
|
15076
15339
|
...$selected && {
|
|
15077
15340
|
color: "white",
|
|
15078
|
-
backgroundColor:
|
|
15341
|
+
backgroundColor: cssVars.colors[$colorScheme]
|
|
15079
15342
|
},
|
|
15080
15343
|
display: "flex",
|
|
15081
15344
|
alignItems: "center",
|
|
@@ -15089,15 +15352,15 @@ var RowContainer = (0, import_react51.forwardRef)(
|
|
|
15089
15352
|
},
|
|
15090
15353
|
position: "relative",
|
|
15091
15354
|
...$hovered && {
|
|
15092
|
-
boxShadow: `0 0 0 1px ${
|
|
15355
|
+
boxShadow: `0 0 0 1px ${cssVars.colors[$colorScheme]} inset`
|
|
15093
15356
|
},
|
|
15094
15357
|
...$showsActiveState && {
|
|
15095
15358
|
"&:active": {
|
|
15096
|
-
backgroundColor: $selected ? $colorScheme === "secondary" ?
|
|
15359
|
+
backgroundColor: $selected ? $colorScheme === "secondary" ? cssVars.colors.secondaryLight : cssVars.colors.primaryLight : cssVars.colors.activeBackground
|
|
15097
15360
|
}
|
|
15098
15361
|
},
|
|
15099
15362
|
...$divider && {
|
|
15100
|
-
borderBottom: `1px solid ${
|
|
15363
|
+
borderBottom: `1px solid ${cssVars.colors.dividerSubtle}`
|
|
15101
15364
|
},
|
|
15102
15365
|
...$backgroundColor && {
|
|
15103
15366
|
backgroundColor: $backgroundColor,
|
|
@@ -15137,14 +15400,14 @@ var ListViewDragIndicatorElement = (0, import_react51.forwardRef)(
|
|
|
15137
15400
|
borderRadius: "3px",
|
|
15138
15401
|
...$relativeDropPosition === "inside" ? {
|
|
15139
15402
|
inset: 2,
|
|
15140
|
-
boxShadow: `0 0 0 1px
|
|
15403
|
+
boxShadow: `0 0 0 1px ${cssVars.colors.sidebarBackground}, 0 0 0 3px ${$colorScheme === "secondary" ? cssVars.colors.secondary : cssVars.colors.dragOutline}`
|
|
15141
15404
|
} : {
|
|
15142
15405
|
top: $relativeDropPosition === "above" ? -(3 + $gap / 2) : void 0,
|
|
15143
15406
|
bottom: $relativeDropPosition === "below" ? -(3 + $gap / 2) : void 0,
|
|
15144
15407
|
left: $offsetLeft,
|
|
15145
15408
|
right: 0,
|
|
15146
15409
|
height: 6,
|
|
15147
|
-
backgroundColor: $colorScheme === "secondary" ?
|
|
15410
|
+
backgroundColor: $colorScheme === "secondary" ? cssVars.colors.secondary : cssVars.colors.primary,
|
|
15148
15411
|
border: `2px solid white`,
|
|
15149
15412
|
boxShadow: "0 0 2px rgba(0,0,0,0.5)"
|
|
15150
15413
|
},
|
|
@@ -15978,7 +16241,7 @@ var InspectorContainer = (0, import_react53.memo)(
|
|
|
15978
16241
|
display: "flex",
|
|
15979
16242
|
flexDirection: "column",
|
|
15980
16243
|
position: "relative",
|
|
15981
|
-
background:
|
|
16244
|
+
background: cssVars.colors.sidebarBackground,
|
|
15982
16245
|
...style5
|
|
15983
16246
|
}
|
|
15984
16247
|
},
|
|
@@ -15996,7 +16259,7 @@ var Label = (0, import_react54.memo)(
|
|
|
15996
16259
|
"label",
|
|
15997
16260
|
{
|
|
15998
16261
|
ref,
|
|
15999
|
-
className: `font-sans text-label uppercase flex items-center leading-[19px] select-none font-bold text-text-muted ${className ?? ""}`,
|
|
16262
|
+
className: `font-sans text-label uppercase flex items-center leading-[19px] select-none font-bold text-text-muted z-label ${className ?? ""}`,
|
|
16000
16263
|
...props
|
|
16001
16264
|
}
|
|
16002
16265
|
);
|
|
@@ -16142,7 +16405,7 @@ var ToggleGroupItem = (0, import_react57.forwardRef)(function ToggleGroupItem2({
|
|
|
16142
16405
|
ref: forwardedRef,
|
|
16143
16406
|
value,
|
|
16144
16407
|
disabled,
|
|
16145
|
-
className: `font-sans text-heading5 font-normal relative flex-1 appearance-none border-none bg-none text-radio-group-item p-0 m-0 rounded inline-flex items-center justify-center align-middle focus:outline-none focus:shadow-[0_0_0_1px_var(--sidebar-background),0_0_0_3px_${colorScheme === "secondary" ? "var(--secondary)" : "var(--primary)"}] aria-checked:bg-${colorScheme ? colorScheme : "radio-group-background"} aria-checked:text-${colorScheme ? "radio-group-background" : "text"} aria-checked:shadow-${colorScheme ? "none" : "0_1px_1px_rgba(0,0,0,0.1)"}`
|
|
16408
|
+
className: `font-sans text-heading5 font-normal relative flex-1 appearance-none border-none bg-none text-radio-group-item p-0 m-0 rounded inline-flex items-center justify-center align-middle focus:outline-none focus:shadow-[0_0_0_1px_var(--sidebar-background),0_0_0_3px_${colorScheme === "secondary" ? "var(--secondary)" : "var(--primary)"}] aria-checked:bg-${colorScheme ? colorScheme : "radio-group-background"} aria-checked:text-${colorScheme ? "radio-group-background" : "text"} aria-checked:shadow-${colorScheme ? "none" : "0_1px_1px_rgba(0,0,0,0.1)"} focus:z-interactable`
|
|
16146
16409
|
},
|
|
16147
16410
|
children2
|
|
16148
16411
|
);
|
|
@@ -16193,7 +16456,7 @@ var readOnlyStyle = {
|
|
|
16193
16456
|
justifyContent: "flex-start",
|
|
16194
16457
|
textAlign: "left"
|
|
16195
16458
|
};
|
|
16196
|
-
var labelStyles = `font-sans text-label uppercase text-text-disabled leading-[19px] font-bold text-[60%] pointer-events-none flex items-center mr-1.5`;
|
|
16459
|
+
var labelStyles = `font-sans text-label uppercase text-text-disabled leading-[19px] font-bold text-[60%] pointer-events-none flex items-center mr-1.5 z-label`;
|
|
16197
16460
|
var scrollButtonStyles = `
|
|
16198
16461
|
flex
|
|
16199
16462
|
items-center
|
|
@@ -16227,7 +16490,7 @@ var SelectMenu = (0, import_react58.memo)(function SelectMenu2({
|
|
|
16227
16490
|
id,
|
|
16228
16491
|
style: style5,
|
|
16229
16492
|
contentStyle: readOnlyStyle,
|
|
16230
|
-
className: `${className ?? ""} flex-1`,
|
|
16493
|
+
className: `${className ?? ""} flex-1 focus:z-interactable`,
|
|
16231
16494
|
disabled
|
|
16232
16495
|
},
|
|
16233
16496
|
icon && /* @__PURE__ */ import_react58.default.createElement(import_react58.default.Fragment, null, renderIcon(icon), /* @__PURE__ */ import_react58.default.createElement(Spacer.Horizontal, { inline: true, size: 6 })),
|
|
@@ -16241,7 +16504,7 @@ var SelectMenu = (0, import_react58.memo)(function SelectMenu2({
|
|
|
16241
16504
|
{
|
|
16242
16505
|
id,
|
|
16243
16506
|
style: style5,
|
|
16244
|
-
className: `${className ?? "w-full"} flex-1`,
|
|
16507
|
+
className: `${className ?? "w-full"} flex-1 focus:z-interactable`,
|
|
16245
16508
|
disabled
|
|
16246
16509
|
},
|
|
16247
16510
|
icon && /* @__PURE__ */ import_react58.default.createElement(import_react58.default.Fragment, null, renderIcon(icon), /* @__PURE__ */ import_react58.default.createElement(Spacer.Horizontal, { inline: true, size: 6 })),
|
|
@@ -16337,7 +16600,7 @@ var Switch = function Switch2({
|
|
|
16337
16600
|
onCheckedChange: (newValue) => {
|
|
16338
16601
|
onChange(newValue);
|
|
16339
16602
|
},
|
|
16340
|
-
className: `all-unset w-8 h-[19px] bg-active-background rounded-full relative cursor-pointer [webkit-tap-highlight-color:rgba(0,0,0,0)] focus:ring-2 focus:ring-primary focus:ring-offset-[1px] outline-none data-[state=checked]:bg-primary ${colorScheme === "secondary" && "data-[state=checked]:bg-secondary"}`
|
|
16603
|
+
className: `all-unset w-8 h-[19px] bg-active-background rounded-full relative cursor-pointer [webkit-tap-highlight-color:rgba(0,0,0,0)] focus:ring-2 focus:ring-primary focus:ring-offset-[1px] outline-none data-[state=checked]:bg-primary ${colorScheme === "secondary" && "data-[state=checked]:bg-secondary"} focus:z-interactable`
|
|
16341
16604
|
},
|
|
16342
16605
|
/* @__PURE__ */ import_react60.default.createElement(SwitchPrimitive.Thumb, { className: "block w-[15px] h-[15px] bg-white rounded-full transition-transform translate-x-[2px] data-[state=checked]:translate-x-[15px]" })
|
|
16343
16606
|
);
|
|
@@ -16376,7 +16639,7 @@ var AutoResizingTextArea = (0, import_react61.memo)(
|
|
|
16376
16639
|
return /* @__PURE__ */ import_react61.default.createElement(
|
|
16377
16640
|
"textarea",
|
|
16378
16641
|
{
|
|
16379
|
-
className: `font-sans text-heading5 font-normal text-text bg-input-background w-0 flex-1 py-1 px-1.5 border-none outline-none h-[100px] rounded-4 resize-none placeholder:text-text-disabled focus:ring-2 focus:ring-primary
|
|
16642
|
+
className: `font-sans text-heading5 font-normal text-text bg-input-background w-0 flex-1 py-1 px-1.5 border-none outline-none h-[100px] rounded-4 resize-none placeholder:text-text-disabled focus:ring-2 focus:ring-primary read-only:text-text-disabled focus:z-interactable ${className ?? ""}`,
|
|
16380
16643
|
ref: handleRef,
|
|
16381
16644
|
...rest,
|
|
16382
16645
|
onChange: handleChange,
|
|
@@ -16658,7 +16921,7 @@ var WorkspaceLayoutWithTheme = (0, import_react65.forwardRef)(function Workspace
|
|
|
16658
16921
|
id,
|
|
16659
16922
|
className,
|
|
16660
16923
|
style: {
|
|
16661
|
-
backgroundColor:
|
|
16924
|
+
backgroundColor: cssVars.colors.canvasBackground,
|
|
16662
16925
|
display: "flex",
|
|
16663
16926
|
flexDirection: "row",
|
|
16664
16927
|
...style5
|
|
@@ -16697,7 +16960,7 @@ var WorkspaceLayoutWithTheme = (0, import_react65.forwardRef)(function Workspace
|
|
|
16697
16960
|
cursor: "col-resize",
|
|
16698
16961
|
width: "1px",
|
|
16699
16962
|
height: "100%",
|
|
16700
|
-
backgroundColor:
|
|
16963
|
+
backgroundColor: cssVars.colors.divider
|
|
16701
16964
|
}
|
|
16702
16965
|
}
|
|
16703
16966
|
)),
|
|
@@ -16723,7 +16986,7 @@ var WorkspaceLayoutWithTheme = (0, import_react65.forwardRef)(function Workspace
|
|
|
16723
16986
|
cursor: "col-resize",
|
|
16724
16987
|
width: "1px",
|
|
16725
16988
|
height: "100%",
|
|
16726
|
-
backgroundColor:
|
|
16989
|
+
backgroundColor: cssVars.colors.divider
|
|
16727
16990
|
}
|
|
16728
16991
|
}
|
|
16729
16992
|
), /* @__PURE__ */ import_react65.default.createElement(
|
|
@@ -16906,7 +17169,7 @@ var Checkbox3 = (0, import_react68.forwardRef)(({ className, ...props }, ref) =>
|
|
|
16906
17169
|
{
|
|
16907
17170
|
ref,
|
|
16908
17171
|
type: "checkbox",
|
|
16909
|
-
className: cn("m-0", className),
|
|
17172
|
+
className: cn("m-0 focus:z-interactable", className),
|
|
16910
17173
|
...props
|
|
16911
17174
|
}
|
|
16912
17175
|
));
|
|
@@ -16920,12 +17183,16 @@ var Text3 = (0, import_react68.forwardRef)(({ className, ...props }, ref) => /*
|
|
|
16920
17183
|
));
|
|
16921
17184
|
var VerticalSeparator = () => /* @__PURE__ */ import_react68.default.createElement(Spacer.Vertical, { size: "inspector-v-separator" });
|
|
16922
17185
|
var HorizontalSeparator = () => /* @__PURE__ */ import_react68.default.createElement(Spacer.Horizontal, { size: "inspector-h-separator" });
|
|
16923
|
-
var RowLabel = (0, import_react68.forwardRef)(function RowLabel2({
|
|
17186
|
+
var RowLabel = (0, import_react68.forwardRef)(function RowLabel2({
|
|
17187
|
+
className,
|
|
17188
|
+
$textStyle,
|
|
17189
|
+
...props
|
|
17190
|
+
}, ref) {
|
|
16924
17191
|
return /* @__PURE__ */ import_react68.default.createElement(
|
|
16925
|
-
"
|
|
17192
|
+
"label",
|
|
16926
17193
|
{
|
|
16927
17194
|
ref,
|
|
16928
|
-
className: `font-sans text-label uppercase flex items-center leading-[19px] font-bold text-text-subtle ${$textStyle
|
|
17195
|
+
className: `font-sans text-label uppercase flex items-center leading-[19px] font-bold text-text-subtle z-label ${$textStyle ? textStyles[$textStyle] : ""} ${className ?? ""}`,
|
|
16929
17196
|
...props
|
|
16930
17197
|
}
|
|
16931
17198
|
);
|
|
@@ -17011,6 +17278,7 @@ var LabeledRow = (0, import_react68.memo)(function LabeledRow2({
|
|
|
17011
17278
|
WorkspaceLayout,
|
|
17012
17279
|
cn,
|
|
17013
17280
|
createSectionedMenu,
|
|
17281
|
+
cssVars,
|
|
17014
17282
|
fuzzyFilter,
|
|
17015
17283
|
fuzzyScore,
|
|
17016
17284
|
fuzzyTokenize,
|