@crisp-ui-kit/crisp 0.33.4 → 0.34.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/checkbox.css +1 -1
- package/dist/checkbox.layered.css +1 -1
- package/dist/cjs/components/avatargroup/avatargroup.recipe.js +21 -8
- package/dist/cjs/components/barchart/barchart.js +6 -1
- package/dist/cjs/components/checkbox/checkbox.recipe.js +50 -17
- package/dist/cjs/components/datepicker/datepicker.js +7 -1
- package/dist/cjs/components/kbd/kbd.recipe.js +22 -9
- package/dist/cjs/components/linechart/linechart.js +6 -1
- package/dist/cjs/components/skeleton/skeleton.recipe.js +14 -8
- package/dist/cjs/components/table/table.js +6 -2
- package/dist/cjs/components/textarea/textarea.js +9 -2
- package/dist/cjs/components/textarea/textarea.recipe.js +14 -5
- package/dist/cjs/components/tooltip/tooltip.recipe.js +27 -6
- package/dist/cjs/product/recordpage/recordpage.js +1 -1
- package/dist/command.css +1 -1
- package/dist/command.layered.css +1 -1
- package/dist/esm/components/avatargroup/avatargroup.recipe.js +21 -8
- package/dist/esm/components/barchart/barchart.js +6 -1
- package/dist/esm/components/checkbox/checkbox.recipe.js +50 -17
- package/dist/esm/components/datepicker/datepicker.js +7 -1
- package/dist/esm/components/kbd/kbd.recipe.js +22 -9
- package/dist/esm/components/linechart/linechart.js +6 -1
- package/dist/esm/components/skeleton/skeleton.recipe.js +14 -8
- package/dist/esm/components/table/table.js +6 -2
- package/dist/esm/components/textarea/textarea.js +9 -2
- package/dist/esm/components/textarea/textarea.recipe.js +14 -5
- package/dist/esm/components/tooltip/tooltip.recipe.js +27 -6
- package/dist/esm/product/recordpage/recordpage.js +1 -1
- package/dist/navitem.css +1 -1
- package/dist/navitem.layered.css +1 -1
- package/dist/sidebar.css +1 -1
- package/dist/sidebar.layered.css +1 -1
- package/dist/styles.css +6 -90
- package/dist/styles.layered.css +6 -90
- package/dist/textarea.css +2 -2
- package/dist/textarea.layered.css +2 -2
- package/dist/tokens.css +0 -84
- package/dist/types/components/avatargroup/avatargroup.recipe.d.ts +25 -2
- package/dist/types/components/checkbox/checkbox.recipe.d.ts +51 -3
- package/dist/types/components/kbd/kbd.recipe.d.ts +24 -3
- package/dist/types/components/skeleton/skeleton.recipe.d.ts +19 -2
- package/dist/types/components/tooltip/tooltip.recipe.d.ts +30 -2
- package/package.json +2 -1
|
@@ -1,13 +1,26 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { defineSpec, resolveRecipe, specToRecipe } from "../../core/index.js";
|
|
2
2
|
import { contract as c } from "../../tokens/index.js";
|
|
3
|
-
const
|
|
3
|
+
const spec = defineSpec({
|
|
4
4
|
name: "kbd",
|
|
5
|
-
base:
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
5
|
+
base: {
|
|
6
|
+
boxSizing: "border-box",
|
|
7
|
+
display: "inline-flex",
|
|
8
|
+
alignItems: "center",
|
|
9
|
+
justifyContent: "center",
|
|
10
|
+
gap: c.space["0.5"],
|
|
11
|
+
minWidth: "20px",
|
|
12
|
+
height: "20px",
|
|
13
|
+
paddingInline: c.space["1"],
|
|
14
|
+
borderRadius: c.radius.sm,
|
|
15
|
+
fontFamily: c.font.sans,
|
|
16
|
+
fontSize: c.text.xs,
|
|
17
|
+
fontWeight: c.weight.regular,
|
|
18
|
+
color: `color-mix(in srgb, ${c.fgPrimary} 50%, transparent)`,
|
|
19
|
+
background: "transparent",
|
|
20
|
+
boxShadow: `inset 0 0 0 1px color-mix(in srgb, ${c.fgPrimary} 6%, transparent)`,
|
|
21
|
+
},
|
|
12
22
|
});
|
|
23
|
+
const config = specToRecipe(spec);
|
|
24
|
+
export const kbdRecipe = Object.assign(resolveRecipe(config), { config });
|
|
25
|
+
export { spec };
|
|
13
26
|
export default config;
|
|
@@ -41,9 +41,14 @@ export function LineChart({ data, height = 240, max, ticks = 5, color, area = tr
|
|
|
41
41
|
: "";
|
|
42
42
|
const summary = ariaLabel ??
|
|
43
43
|
`Line chart: ${data.map((d) => `${d.label} ${format(d.value)}`).join(", ")}`;
|
|
44
|
-
return (_jsxs("div", { className: linechartRecipe({ className }), ...rest,
|
|
44
|
+
return (_jsxs("div", { className: linechartRecipe({ className }), ...rest,
|
|
45
|
+
// merged, not assigned: written plainly this sits AFTER `{...rest}` and
|
|
46
|
+
// overwrites whatever style the consumer passed, so `style={{ maxWidth }}`
|
|
47
|
+
// on the chart did nothing at all. The consumer's wins on collision.
|
|
48
|
+
style: {
|
|
45
49
|
height,
|
|
46
50
|
"--crisp-linechart-yaxis-width": yAxisWidthValue,
|
|
51
|
+
...rest.style,
|
|
47
52
|
}, role: "img", "aria-label": summary, children: [_jsxs("div", { className: "crisp-linechart-body", children: [_jsx("div", { className: "crisp-linechart-yaxis", children: tickValues.map((t) => (_jsx("span", { className: "crisp-linechart-ytick", style: { bottom: `${(t / top) * 100}%` }, children: format(t) }, t))) }), _jsxs("div", { className: "crisp-linechart-plot", children: [tickValues.map((t) => (_jsx("div", { className: "crisp-linechart-grid", style: { bottom: `${(t / top) * 100}%` } }, t))), pts.length > 1 && (_jsxs("svg", { className: "crisp-linechart-svg", viewBox: "0 0 100 100", preserveAspectRatio: "none", "aria-hidden": "true", children: [area && _jsx("path", { className: "crisp-linechart-area", d: areaPath }), _jsx("polyline", { className: "crisp-linechart-line", points: line, style: { stroke: color } })] })), dots &&
|
|
48
53
|
pts.map((p, i) => (_jsx("span", { className: "crisp-linechart-dot-html", style: {
|
|
49
54
|
left: `${p.x}%`,
|
|
@@ -1,14 +1,20 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { defineSpec, resolveRecipe, specToRecipe } from "../../core/index.js";
|
|
2
2
|
import { contract as c } from "../../tokens/index.js";
|
|
3
3
|
// A pulsing placeholder block for loading states.
|
|
4
|
-
const
|
|
4
|
+
const spec = defineSpec({
|
|
5
5
|
name: "skeleton",
|
|
6
|
-
globalCss:
|
|
7
|
-
base:
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
6
|
+
globalCss: "@keyframes crisp-skeleton { 0%, 100% { opacity: 1; } 50% { opacity: 0.5; } }",
|
|
7
|
+
base: {
|
|
8
|
+
display: "block",
|
|
9
|
+
background: `color-mix(in srgb, ${c.fgPrimary} 8%, transparent)`,
|
|
10
|
+
borderRadius: c.radius.md,
|
|
11
|
+
animation: "crisp-skeleton 1.4s ease-in-out infinite",
|
|
12
|
+
},
|
|
13
|
+
parts: [
|
|
14
|
+
{ selector: "&[data-circle]", decls: { borderRadius: c.radius.full } },
|
|
15
|
+
],
|
|
12
16
|
});
|
|
17
|
+
const config = specToRecipe(spec);
|
|
13
18
|
export const skeletonRecipe = resolveRecipe(config);
|
|
19
|
+
export { spec };
|
|
14
20
|
export default config;
|
|
@@ -8,11 +8,15 @@ import { tableRecipe } from "./table.recipe.js";
|
|
|
8
8
|
* `TableHeader`, `TableBody`, `TableFooter`, `TableRow`, `TableHead`,
|
|
9
9
|
* `TableCell`, and `TableCaption`.
|
|
10
10
|
*/
|
|
11
|
-
export const Table = React.forwardRef(({ interactive, surface, className, wrapperClassName, scrollProps, children,
|
|
11
|
+
export const Table = React.forwardRef(({ interactive, surface, className, wrapperClassName, scrollProps, children,
|
|
12
|
+
// on the root for the same reason as Textarea: the wrapper is the box a
|
|
13
|
+
// consumer sees and the scroll container they want to size. Native
|
|
14
|
+
// table attributes still reach the <table> below.
|
|
15
|
+
style, ...props }, ref) => (_jsx("div", { className: tableRecipe({
|
|
12
16
|
interactive,
|
|
13
17
|
surface,
|
|
14
18
|
className: wrapperClassName,
|
|
15
|
-
}), children: _jsx("div", { ...scrollProps, className: `crisp-table-scroll${scrollProps?.className ? ` ${scrollProps.className}` : ""}`, children: _jsx("table", { ref: ref, className: className, ...props, children: children }) }) })));
|
|
19
|
+
}), style: style, children: _jsx("div", { ...scrollProps, className: `crisp-table-scroll${scrollProps?.className ? ` ${scrollProps.className}` : ""}`, children: _jsx("table", { ref: ref, className: className, ...props, children: children }) }) })));
|
|
16
20
|
Table.displayName = "Table";
|
|
17
21
|
export const TableHeader = React.forwardRef((props, ref) => _jsx("thead", { ref: ref, ...props }));
|
|
18
22
|
TableHeader.displayName = "TableHeader";
|
|
@@ -6,12 +6,19 @@ import { textareaRecipe } from "./textarea.recipe.js";
|
|
|
6
6
|
* `<textarea>` prop; pass `showCount` with `maxLength` to render a live
|
|
7
7
|
* character counter (which turns red if the value exceeds the limit).
|
|
8
8
|
*/
|
|
9
|
-
export const Textarea = React.forwardRef(({ showCount, maxLength, className, wrapperClassName, value, defaultValue, onChange,
|
|
9
|
+
export const Textarea = React.forwardRef(({ showCount, maxLength, className, wrapperClassName, value, defaultValue, onChange,
|
|
10
|
+
// `style` is pulled out and put on the ROOT, the way Input does it.
|
|
11
|
+
// Everything else belongs on the <textarea> -- id, name, form
|
|
12
|
+
// association, aria -- but `style` sizes the visual box, and the box is
|
|
13
|
+
// the root: it carries the focus ring (an ::after on the wrap) and the
|
|
14
|
+
// character counter. Left on the field, `style={{ maxWidth: 480 }}` gave
|
|
15
|
+
// a 480px control inside a full-width ring with the counter stranded.
|
|
16
|
+
style, ...props }, ref) => {
|
|
10
17
|
const initial = String(value ?? defaultValue ?? "").length;
|
|
11
18
|
const [count, setCount] = React.useState(initial);
|
|
12
19
|
const len = value !== undefined ? String(value).length : count;
|
|
13
20
|
const counted = showCount && maxLength != null;
|
|
14
|
-
return (_jsxs("div", { className: textareaRecipe({ className: wrapperClassName }), "data-counted": counted ? "" : undefined, children: [_jsx("span", { className: "crisp-textarea-wrap", children: _jsx("textarea", { ref: ref, className: `crisp-textarea-field${className ? ` ${className}` : ""}`, maxLength: maxLength, value: value, defaultValue: defaultValue, onChange: (e) => {
|
|
21
|
+
return (_jsxs("div", { className: textareaRecipe({ className: wrapperClassName }), style: style, "data-counted": counted ? "" : undefined, children: [_jsx("span", { className: "crisp-textarea-wrap", children: _jsx("textarea", { ref: ref, className: `crisp-textarea-field${className ? ` ${className}` : ""}`, maxLength: maxLength, value: value, defaultValue: defaultValue, onChange: (e) => {
|
|
15
22
|
if (value === undefined)
|
|
16
23
|
setCount(e.target.value.length);
|
|
17
24
|
onChange?.(e);
|
|
@@ -1,8 +1,17 @@
|
|
|
1
1
|
import { defineRecipe, resolveRecipe } from "../../core/index.js";
|
|
2
2
|
import { contract as c, elevation as e } from "../../tokens/index.js";
|
|
3
|
-
// A multiline text field
|
|
4
|
-
//
|
|
5
|
-
//
|
|
3
|
+
// A multiline text field: an inset 1px ring (radius 8), 14px text, and an
|
|
4
|
+
// optional character counter pinned bottom-right (12px, muted). Focus rings
|
|
5
|
+
// the field brand.
|
|
6
|
+
//
|
|
7
|
+
// The inset is seed-design's, not Attio's -- the second deliberate divergence
|
|
8
|
+
// after the focus treatment. seed's text-input sets its inline inset to
|
|
9
|
+
// `$dimension.x3_5`, which rootage/dimension.yaml gives as **14px**, against
|
|
10
|
+
// the 10px this had. seed ships no textarea, so only the horizontal inset is
|
|
11
|
+
// theirs to copy; the vertical is derived from it: 10px above and below a
|
|
12
|
+
// 20px line makes a single-line box 40px tall, which is exactly seed's
|
|
13
|
+
// `$dimension.x10` medium field height. The counter's own inset moves to 14px
|
|
14
|
+
// with it, so it lines up with the text rather than sitting 4px inside it.
|
|
6
15
|
const config = defineRecipe({
|
|
7
16
|
name: "textarea",
|
|
8
17
|
base: `
|
|
@@ -10,7 +19,7 @@ const config = defineRecipe({
|
|
|
10
19
|
|
|
11
20
|
& .crisp-textarea-field {
|
|
12
21
|
box-sizing: border-box; display: block; width: 100%; min-height: 80px; resize: vertical;
|
|
13
|
-
margin: 0; padding: ${c.space["
|
|
22
|
+
margin: 0; padding: ${c.space["2.5"]} 14px; border: none; border-radius: ${c.radius.md};
|
|
14
23
|
background: ${c.bgSurface}; box-shadow: ${e.field};
|
|
15
24
|
font-family: inherit; font-size: ${c.text.lg}; line-height: 20px; color: ${c.fgPrimary};
|
|
16
25
|
outline: none; transition: box-shadow .15s ease;
|
|
@@ -32,7 +41,7 @@ const config = defineRecipe({
|
|
|
32
41
|
&[data-invalid] .crisp-textarea-wrap::after { border-color: ${c.bgDanger}; }
|
|
33
42
|
&[data-invalid] .crisp-textarea-wrap:focus-within::after { border-color: ${c.bgDanger}; }
|
|
34
43
|
&[data-counted] .crisp-textarea-field { padding-bottom: ${c.space["5"]}; }
|
|
35
|
-
& .crisp-textarea-count { position: absolute; inset-inline-end:
|
|
44
|
+
& .crisp-textarea-count { position: absolute; inset-inline-end: 14px; bottom: ${c.space["2.5"]}; font-size: ${c.text.sm}; color: ${c.fgMuted}; pointer-events: none; }
|
|
36
45
|
& .crisp-textarea-count[data-over] { color: ${c.bgDanger}; }
|
|
37
46
|
`,
|
|
38
47
|
variants: {},
|
|
@@ -1,13 +1,34 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { defineSpec, resolveRecipe, specToRecipe } from "../../core/index.js";
|
|
2
2
|
import { contract as c } from "../../tokens/index.js";
|
|
3
3
|
// The floating bubble for a Tooltip — a dark hint chip. Applied to the
|
|
4
4
|
// portaled bubble itself (not a wrapper), so its styles survive the portal.
|
|
5
|
-
const
|
|
5
|
+
const spec = defineSpec({
|
|
6
6
|
name: "tooltip",
|
|
7
|
-
base:
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
7
|
+
base: {
|
|
8
|
+
position: "fixed",
|
|
9
|
+
zIndex: 70,
|
|
10
|
+
boxSizing: "border-box",
|
|
11
|
+
pointerEvents: "none",
|
|
12
|
+
maxWidth: "260px",
|
|
13
|
+
padding: `${c.space["1"]} ${c.space["2"]}`,
|
|
14
|
+
borderRadius: c.radius.sm,
|
|
15
|
+
background: "#20242c",
|
|
16
|
+
color: "#fff",
|
|
17
|
+
fontFamily: c.font.sans,
|
|
18
|
+
fontSize: c.text.sm,
|
|
19
|
+
fontWeight: c.weight.medium,
|
|
20
|
+
lineHeight: "1.45",
|
|
21
|
+
boxShadow: "0 4px 14px -2px rgba(28,40,64,0.28), 0 0 0 1px rgba(255,255,255,0.04)",
|
|
22
|
+
opacity: 1,
|
|
23
|
+
transition: "opacity 0.12s ease",
|
|
24
|
+
},
|
|
25
|
+
parts: [
|
|
26
|
+
// An at-rule whose body is declarations rather than rules, so a part
|
|
27
|
+
// expresses it directly: the entry state the overlay animates from.
|
|
28
|
+
{ selector: "@starting-style", decls: { opacity: 0 } },
|
|
29
|
+
],
|
|
11
30
|
});
|
|
31
|
+
const config = specToRecipe(spec);
|
|
12
32
|
export const tooltipRecipe = resolveRecipe(config);
|
|
33
|
+
export { spec };
|
|
13
34
|
export default config;
|
|
@@ -355,7 +355,7 @@ export function RecordPage({ record, columns, collection = "Records", labels, on
|
|
|
355
355
|
return (_jsx("div", { className: "crisp-recordpage-panel", children: _jsx(EmptyCard, { icon: _jsx(Folder, { size: 22, strokeWidth: 1.5 }), children: t.nothingHereYet }) }));
|
|
356
356
|
}
|
|
357
357
|
};
|
|
358
|
-
return (_jsxs("div", { className: recordpageRecipe({ className }), ...rest, children: [_jsxs("div", { className: "crisp-recordpage-topbar", children: [_jsxs("nav", { className: "crisp-recordpage-crumbs", "aria-label": t.breadcrumb, children: [_jsx("button", { type: "button", className: "crisp-recordpage-crumb", onClick: onBack, "aria-label": `Back to ${collection}`, children: collection }), _jsx("span", { className: "crisp-recordpage-crumb-sep", children: "/" }), _jsx("span", { className: "crisp-recordpage-crumb-name", children: name })] }), _jsxs("div", { className: "crisp-recordpage-actions", children: [_jsxs("button", { type: "button", className: "crisp-recordpage-action crisp-recordpage-action--ghost", children: [_jsx(Sparkles, { size: 14, strokeWidth: 1.75, color: "var(--bg-brand-solid)" }), t.askAttio] }), onToggleFull && (_jsx("button", { type: "button", className: "crisp-recordpage-action crisp-recordpage-action--icon", onClick: onToggleFull, "aria-label": full ? t.exitFullScreen : t.fullScreen, children: full ? (_jsx(Minimize2, { size: 15, strokeWidth: 1.75 })) : (_jsx(Maximize2, { size: 15, strokeWidth: 1.75 })) })), _jsxs(Menu, { align: "end", "aria-label": t.recordActions, trigger: _jsx("button", { type: "button", className: "crisp-recordpage-action crisp-recordpage-action--icon", "aria-label": t.recordActions, children: _jsx(MoreHorizontal, { size: 16, strokeWidth: 1.75 }) }), children: [_jsx(MenuItem, { icon: _jsx(Copy, { size: 15, strokeWidth: 1.75 }), shortcut: "\u2318C", children: t.copyRecordLink }), _jsx(MenuItem, { icon: _jsx(Plus, { size: 15, strokeWidth: 1.75 }), children: t.addToList }), _jsx(MenuItem, { icon: _jsx(Star, { size: 15, strokeWidth: 1.75 }), onSelect: () => setFavorite((f) => !f), children: favorite ? t.removeFromFavourites : t.addToFavourites }), _jsx(MenuSeparator, {}), _jsx(MenuItem, { icon: _jsx(Trash2, { size: 15, strokeWidth: 1.75 }), danger: true, shortcut: "\u232B", children: t.deleteRecord })] })] })] }), _jsxs("div", { className: "crisp-recordpage-body", children: [_jsxs("aside", { className: "crisp-recordpage-details", style: { width: detailsW }, children: [_jsxs("div", { className: "crisp-recordpage-entity", children: [entity?.avatar ? (_jsx("img", { className: "crisp-recordpage-entity-logo", src: entity.avatar, alt: "" })) : (_jsx(Avatar, { size: "lg", shape: "rounded", tone: "brand", children: name.charAt(0) })), _jsx("span", { className: "crisp-recordpage-entity-name", children: name }), _jsx("button", { type: "button", className: "crisp-recordpage-entity-iconbtn", "aria-label": t.editRecord, children: _jsx(Pencil, { size: 15, strokeWidth: 1.75 }) }), _jsx("button", { type: "button", className: "crisp-recordpage-entity-iconbtn", "data-active": favorite ? "" : undefined, "aria-pressed": favorite, onClick: () => setFavorite((f) => !f), "aria-label": favorite ? t.removeFromFavourites : t.addToFavourites, children: _jsx(Star, { size: 15, strokeWidth: 1.75 }) })] }), _jsxs("div", { className: "crisp-recordpage-quickactions", children: [_jsxs("button", { type: "button", className: "crisp-recordpage-compose", children: [_jsx(Mail, { size: 16, strokeWidth: 1.75 }), t.composeEmail] }), _jsx("button", { type: "button", className: "crisp-recordpage-quickbtn", "aria-label": t.copyRecordLink, children: _jsx(Copy, { size: 15, strokeWidth: 1.75 }) }), _jsx("button", { type: "button", className: "crisp-recordpage-quickbtn", "aria-label": t.logANote, children: _jsx(FileText, { size: 15, strokeWidth: 1.75 }) }), _jsx("button", { type: "button", className: "crisp-recordpage-quickbtn", "aria-label": t.linkRecords, children: _jsx(Share2, { size: 15, strokeWidth: 1.75 }) }), _jsx("button", { type: "button", className: "crisp-recordpage-quickbtn", "aria-label": t.createATask, children: _jsx(SquareCheck, { size: 15, strokeWidth: 1.75 }) })] }), _jsxs("div", { className: "crisp-recordpage-section", children: [_jsxs("div", { className: "crisp-recordpage-detailhead", children: [searchOpen ? (_jsx("input", {
|
|
358
|
+
return (_jsxs("div", { className: recordpageRecipe({ className }), ...rest, children: [_jsxs("div", { className: "crisp-recordpage-topbar", children: [_jsxs("nav", { className: "crisp-recordpage-crumbs", "aria-label": t.breadcrumb, children: [_jsx("button", { type: "button", className: "crisp-recordpage-crumb", onClick: onBack, "aria-label": `Back to ${collection}`, children: collection }), _jsx("span", { className: "crisp-recordpage-crumb-sep", children: "/" }), _jsx("span", { className: "crisp-recordpage-crumb-name", children: name })] }), _jsxs("div", { className: "crisp-recordpage-actions", children: [_jsxs("button", { type: "button", className: "crisp-recordpage-action crisp-recordpage-action--ghost", children: [_jsx(Sparkles, { size: 14, strokeWidth: 1.75, color: "var(--crisp-bg-brand-solid)" }), t.askAttio] }), onToggleFull && (_jsx("button", { type: "button", className: "crisp-recordpage-action crisp-recordpage-action--icon", onClick: onToggleFull, "aria-label": full ? t.exitFullScreen : t.fullScreen, children: full ? (_jsx(Minimize2, { size: 15, strokeWidth: 1.75 })) : (_jsx(Maximize2, { size: 15, strokeWidth: 1.75 })) })), _jsxs(Menu, { align: "end", "aria-label": t.recordActions, trigger: _jsx("button", { type: "button", className: "crisp-recordpage-action crisp-recordpage-action--icon", "aria-label": t.recordActions, children: _jsx(MoreHorizontal, { size: 16, strokeWidth: 1.75 }) }), children: [_jsx(MenuItem, { icon: _jsx(Copy, { size: 15, strokeWidth: 1.75 }), shortcut: "\u2318C", children: t.copyRecordLink }), _jsx(MenuItem, { icon: _jsx(Plus, { size: 15, strokeWidth: 1.75 }), children: t.addToList }), _jsx(MenuItem, { icon: _jsx(Star, { size: 15, strokeWidth: 1.75 }), onSelect: () => setFavorite((f) => !f), children: favorite ? t.removeFromFavourites : t.addToFavourites }), _jsx(MenuSeparator, {}), _jsx(MenuItem, { icon: _jsx(Trash2, { size: 15, strokeWidth: 1.75 }), danger: true, shortcut: "\u232B", children: t.deleteRecord })] })] })] }), _jsxs("div", { className: "crisp-recordpage-body", children: [_jsxs("aside", { className: "crisp-recordpage-details", style: { width: detailsW }, children: [_jsxs("div", { className: "crisp-recordpage-entity", children: [entity?.avatar ? (_jsx("img", { className: "crisp-recordpage-entity-logo", src: entity.avatar, alt: "" })) : (_jsx(Avatar, { size: "lg", shape: "rounded", tone: "brand", children: name.charAt(0) })), _jsx("span", { className: "crisp-recordpage-entity-name", children: name }), _jsx("button", { type: "button", className: "crisp-recordpage-entity-iconbtn", "aria-label": t.editRecord, children: _jsx(Pencil, { size: 15, strokeWidth: 1.75 }) }), _jsx("button", { type: "button", className: "crisp-recordpage-entity-iconbtn", "data-active": favorite ? "" : undefined, "aria-pressed": favorite, onClick: () => setFavorite((f) => !f), "aria-label": favorite ? t.removeFromFavourites : t.addToFavourites, children: _jsx(Star, { size: 15, strokeWidth: 1.75 }) })] }), _jsxs("div", { className: "crisp-recordpage-quickactions", children: [_jsxs("button", { type: "button", className: "crisp-recordpage-compose", children: [_jsx(Mail, { size: 16, strokeWidth: 1.75 }), t.composeEmail] }), _jsx("button", { type: "button", className: "crisp-recordpage-quickbtn", "aria-label": t.copyRecordLink, children: _jsx(Copy, { size: 15, strokeWidth: 1.75 }) }), _jsx("button", { type: "button", className: "crisp-recordpage-quickbtn", "aria-label": t.logANote, children: _jsx(FileText, { size: 15, strokeWidth: 1.75 }) }), _jsx("button", { type: "button", className: "crisp-recordpage-quickbtn", "aria-label": t.linkRecords, children: _jsx(Share2, { size: 15, strokeWidth: 1.75 }) }), _jsx("button", { type: "button", className: "crisp-recordpage-quickbtn", "aria-label": t.createATask, children: _jsx(SquareCheck, { size: 15, strokeWidth: 1.75 }) })] }), _jsxs("div", { className: "crisp-recordpage-section", children: [_jsxs("div", { className: "crisp-recordpage-detailhead", children: [searchOpen ? (_jsx("input", {
|
|
359
359
|
// biome-ignore lint/a11y/noAutofocus: focusing the just-opened field search is expected
|
|
360
360
|
autoFocus: true, type: "text", className: "crisp-recordpage-fieldsearch", placeholder: t.searchPlaceholder, "aria-label": t.searchFields, value: fieldQuery, onChange: (e) => setFieldQuery(e.target.value), onKeyDown: (e) => {
|
|
361
361
|
if (e.key === "Escape") {
|
package/dist/navitem.css
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
.crisp-navitem {
|
|
2
|
-
box-sizing: border-box; display: flex; align-items: center; gap: var(--crisp-space-1-5)
|
|
2
|
+
box-sizing: border-box; display: flex; align-items: center; gap: var(--crisp-space-1-5); height: 28px; padding-inline: var(--crisp-space-2); padding-inline-end: var(--crisp-space-1); border-radius: var(--crisp-radius-lg); font-family: var(--crisp-font-sans); font-size: var(--crisp-text-lg); font-weight: var(--crisp-weight-medium); letter-spacing: -0.14px; line-height: 20px; color: var(--crisp-fg-primary); text-decoration: none; cursor: pointer; user-select: none; width: 100%; transition: background-color 0.16s;
|
|
3
3
|
& .crisp-navitem-label { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
|
|
4
4
|
& .crisp-navitem-trailing { margin-inline-start: auto; display: inline-flex; align-items: center; flex-shrink: 0; }
|
|
5
5
|
&:hover { background: color-mix(in srgb, var(--crisp-fg-primary) 2%, transparent); }
|
package/dist/navitem.layered.css
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
@layer crisp-components {
|
|
2
2
|
.crisp-navitem {
|
|
3
|
-
box-sizing: border-box; display: flex; align-items: center; gap: var(--crisp-space-1-5)
|
|
3
|
+
box-sizing: border-box; display: flex; align-items: center; gap: var(--crisp-space-1-5); height: 28px; padding-inline: var(--crisp-space-2); padding-inline-end: var(--crisp-space-1); border-radius: var(--crisp-radius-lg); font-family: var(--crisp-font-sans); font-size: var(--crisp-text-lg); font-weight: var(--crisp-weight-medium); letter-spacing: -0.14px; line-height: 20px; color: var(--crisp-fg-primary); text-decoration: none; cursor: pointer; user-select: none; width: 100%; transition: background-color 0.16s;
|
|
4
4
|
& .crisp-navitem-label { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
|
|
5
5
|
& .crisp-navitem-trailing { margin-inline-start: auto; display: inline-flex; align-items: center; flex-shrink: 0; }
|
|
6
6
|
&:hover { background: color-mix(in srgb, var(--crisp-fg-primary) 2%, transparent); }
|
package/dist/sidebar.css
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
.crisp-sidebar {
|
|
2
|
-
box-sizing: border-box; display: flex; flex-direction: column; width: 275px; height: 100%; background: var(--crisp-bg-sidebar)
|
|
2
|
+
box-sizing: border-box; display: flex; flex-direction: column; width: 275px; height: 100%; background: var(--crisp-bg-sidebar); border-inline-end: 1px solid var(--crisp-border-subtle); padding: var(--crisp-space-2); font-family: var(--crisp-font-sans); -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; overflow-y: auto;
|
|
3
3
|
& .crisp-sidebar-section { display: flex; flex-direction: column; gap: var(--crisp-space-px); margin-top: var(--crisp-space-2); }
|
|
4
4
|
& .crisp-sidebar-section[data-collapsed] { display: none; }
|
|
5
5
|
& .crisp-sidebar-label { font-size: var(--crisp-text-sm); font-weight: var(--crisp-weight-medium); color: var(--crisp-fg-muted); padding: var(--crisp-space-1-5) var(--crisp-space-2) var(--crisp-space-0-5); }
|
package/dist/sidebar.layered.css
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
@layer crisp-components {
|
|
2
2
|
.crisp-sidebar {
|
|
3
|
-
box-sizing: border-box; display: flex; flex-direction: column; width: 275px; height: 100%; background: var(--crisp-bg-sidebar)
|
|
3
|
+
box-sizing: border-box; display: flex; flex-direction: column; width: 275px; height: 100%; background: var(--crisp-bg-sidebar); border-inline-end: 1px solid var(--crisp-border-subtle); padding: var(--crisp-space-2); font-family: var(--crisp-font-sans); -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; overflow-y: auto;
|
|
4
4
|
& .crisp-sidebar-section { display: flex; flex-direction: column; gap: var(--crisp-space-px); margin-top: var(--crisp-space-2); }
|
|
5
5
|
& .crisp-sidebar-section[data-collapsed] { display: none; }
|
|
6
6
|
& .crisp-sidebar-label { font-size: var(--crisp-text-sm); font-weight: var(--crisp-weight-medium); color: var(--crisp-fg-muted); padding: var(--crisp-space-1-5) var(--crisp-space-2) var(--crisp-space-0-5); }
|
package/dist/styles.css
CHANGED
|
@@ -122,90 +122,6 @@
|
|
|
122
122
|
--crisp-font-sans: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
|
|
123
123
|
}
|
|
124
124
|
|
|
125
|
-
/* -----------------------------------------------------------------
|
|
126
|
-
* Deprecated unprefixed aliases (issue #276) — SCHEDULED FOR REMOVAL in
|
|
127
|
-
* the next major version. Prefer the --crisp-* custom property
|
|
128
|
-
* above; these only forward to it so an existing override keeps working.
|
|
129
|
-
* ----------------------------------------------------------------- */
|
|
130
|
-
:root {
|
|
131
|
-
--bg-brand-solid: var(--crisp-bg-brand-solid);
|
|
132
|
-
--bg-brand-solid-pressed: var(--crisp-bg-brand-solid-pressed);
|
|
133
|
-
--fg-on-brand: var(--crisp-fg-on-brand);
|
|
134
|
-
--fg-on-tone: var(--crisp-fg-on-tone);
|
|
135
|
-
--bg-surface: var(--crisp-bg-surface);
|
|
136
|
-
--bg-raised: var(--crisp-bg-raised);
|
|
137
|
-
--border-default: var(--crisp-border-default);
|
|
138
|
-
--border-subtle: var(--crisp-border-subtle);
|
|
139
|
-
--ring-neutral: var(--crisp-ring-neutral);
|
|
140
|
-
--bg-tile-active: var(--crisp-bg-tile-active);
|
|
141
|
-
--shadow-tile-active: var(--crisp-shadow-tile-active);
|
|
142
|
-
--bg-overlay-frost: var(--crisp-bg-overlay-frost);
|
|
143
|
-
--shadow-overlay1: var(--crisp-shadow-overlay1);
|
|
144
|
-
--shadow-overlay2: var(--crisp-shadow-overlay2);
|
|
145
|
-
--shadow-overlay3: var(--crisp-shadow-overlay3);
|
|
146
|
-
--bg-popover: var(--crisp-bg-popover);
|
|
147
|
-
--ring-popover: var(--crisp-ring-popover);
|
|
148
|
-
--shadow-popover1: var(--crisp-shadow-popover1);
|
|
149
|
-
--shadow-popover2: var(--crisp-shadow-popover2);
|
|
150
|
-
--shadow-popover3: var(--crisp-shadow-popover3);
|
|
151
|
-
--fg-primary: var(--crisp-fg-primary);
|
|
152
|
-
--fg-muted: var(--crisp-fg-muted);
|
|
153
|
-
--bg-danger: var(--crisp-bg-danger);
|
|
154
|
-
--bg-danger-solid: var(--crisp-bg-danger-solid);
|
|
155
|
-
--stroke-field-focus: var(--crisp-stroke-field-focus);
|
|
156
|
-
--fg-disabled: var(--crisp-fg-disabled);
|
|
157
|
-
--bg-neutral-weak: var(--crisp-bg-neutral-weak);
|
|
158
|
-
--bg-neutral-inverted: var(--crisp-bg-neutral-inverted);
|
|
159
|
-
--fg-on-neutral-inverted: var(--crisp-fg-on-neutral-inverted);
|
|
160
|
-
--fg-neutral-subtle: var(--crisp-fg-neutral-subtle);
|
|
161
|
-
--fg-neutral-muted: var(--crisp-fg-neutral-muted);
|
|
162
|
-
--stroke-focus-ring: var(--crisp-stroke-focus-ring);
|
|
163
|
-
--bg-success: var(--crisp-bg-success);
|
|
164
|
-
--bg-warning: var(--crisp-bg-warning);
|
|
165
|
-
--bg-orange: var(--crisp-bg-orange);
|
|
166
|
-
--bg-cyan: var(--crisp-bg-cyan);
|
|
167
|
-
--bg-purple: var(--crisp-bg-purple);
|
|
168
|
-
--bg-sidebar: var(--crisp-bg-sidebar);
|
|
169
|
-
--bg-subtle: var(--crisp-bg-subtle);
|
|
170
|
-
--space-1: var(--crisp-space-1);
|
|
171
|
-
--space-2: var(--crisp-space-2);
|
|
172
|
-
--space-3: var(--crisp-space-3);
|
|
173
|
-
--space-4: var(--crisp-space-4);
|
|
174
|
-
--space-5: var(--crisp-space-5);
|
|
175
|
-
--space-6: var(--crisp-space-6);
|
|
176
|
-
--space-8: var(--crisp-space-8);
|
|
177
|
-
--space-px: var(--crisp-space-px);
|
|
178
|
-
--space-0-5: var(--crisp-space-0-5);
|
|
179
|
-
--space-1-5: var(--crisp-space-1-5);
|
|
180
|
-
--space-2-5: var(--crisp-space-2-5);
|
|
181
|
-
--radius-chip: var(--crisp-radius-chip);
|
|
182
|
-
--radius-sm: var(--crisp-radius-sm);
|
|
183
|
-
--radius-md: var(--crisp-radius-md);
|
|
184
|
-
--radius-lg: var(--crisp-radius-lg);
|
|
185
|
-
--radius-xl: var(--crisp-radius-xl);
|
|
186
|
-
--radius-2xl: var(--crisp-radius-2xl);
|
|
187
|
-
--radius-full: var(--crisp-radius-full);
|
|
188
|
-
--size-icon: var(--crisp-size-icon);
|
|
189
|
-
--size-chip: var(--crisp-size-chip);
|
|
190
|
-
--size-row: var(--crisp-size-row);
|
|
191
|
-
--size-menuRow: var(--crisp-size-menuRow);
|
|
192
|
-
--size-tableRow: var(--crisp-size-tableRow);
|
|
193
|
-
--size-tableHeader: var(--crisp-size-tableHeader);
|
|
194
|
-
--size-header: var(--crisp-size-header);
|
|
195
|
-
--size-calendarCell: var(--crisp-size-calendarCell);
|
|
196
|
-
--size-calendarPill: var(--crisp-size-calendarPill);
|
|
197
|
-
--text-xs: var(--crisp-text-xs);
|
|
198
|
-
--text-sm: var(--crisp-text-sm);
|
|
199
|
-
--text-md: var(--crisp-text-md);
|
|
200
|
-
--text-lg: var(--crisp-text-lg);
|
|
201
|
-
--text-xl: var(--crisp-text-xl);
|
|
202
|
-
--weight-regular: var(--crisp-weight-regular);
|
|
203
|
-
--weight-medium: var(--crisp-weight-medium);
|
|
204
|
-
--weight-semibold: var(--crisp-weight-semibold);
|
|
205
|
-
--weight-bold: var(--crisp-weight-bold);
|
|
206
|
-
--font-sans: var(--crisp-font-sans);
|
|
207
|
-
}
|
|
208
|
-
|
|
209
125
|
.crisp-accordion {
|
|
210
126
|
display: flex; flex-direction: column; font-family: var(--crisp-font-sans);
|
|
211
127
|
& .crisp-accordion-item { border-bottom: 1px solid var(--crisp-border-subtle); }
|
|
@@ -483,7 +399,7 @@
|
|
|
483
399
|
}
|
|
484
400
|
|
|
485
401
|
.crisp-checkbox {
|
|
486
|
-
appearance: none; -webkit-appearance: none; box-sizing: border-box; flex-shrink: 0; margin: 0; width: 16px; height: 16px; border: none; border-radius: var(--crisp-radius-sm)
|
|
402
|
+
appearance: none; -webkit-appearance: none; box-sizing: border-box; flex-shrink: 0; margin: 0; width: 16px; height: 16px; border: none; border-radius: var(--crisp-radius-sm); background: var(--crisp-bg-surface); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--crisp-fg-primary) 9%, transparent); cursor: pointer; transition: background-color .12s, box-shadow .12s;
|
|
487
403
|
&:hover { box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--crisp-fg-primary) 30%, transparent); }
|
|
488
404
|
&:checked, &:indeterminate { background: var(--crisp-bg-brand-solid) center / 10px no-repeat; box-shadow: none; }
|
|
489
405
|
&:checked { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 12 12' fill='none' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M2.5 6.5 5 9l4.5-5'/%3E%3C/svg%3E"); }
|
|
@@ -1531,7 +1447,7 @@
|
|
|
1531
1447
|
|
|
1532
1448
|
.crisp-textarea {
|
|
1533
1449
|
position: relative; display: block; width: 100%; font-family: var(--crisp-font-sans);
|
|
1534
|
-
& .crisp-textarea-field { box-sizing: border-box; display: block; width: 100%; min-height: 80px; resize: vertical; margin: 0; padding: var(--crisp-space-
|
|
1450
|
+
& .crisp-textarea-field { box-sizing: border-box; display: block; width: 100%; min-height: 80px; resize: vertical; margin: 0; padding: var(--crisp-space-2-5) 14px; border: none; border-radius: var(--crisp-radius-md); background: var(--crisp-bg-surface); box-shadow: inset 0 0 0 1px var(--crisp-ring-neutral), 0 0 2px rgba(28,40,64,0.18), 0 1px 3px rgba(0,0,0,0.04); font-family: inherit; font-size: var(--crisp-text-lg); line-height: 20px; color: var(--crisp-fg-primary); outline: none; transition: box-shadow .15s ease; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }
|
|
1535
1451
|
& .crisp-textarea-field::placeholder { color: var(--crisp-fg-muted); }
|
|
1536
1452
|
& .crisp-textarea-field:disabled { opacity: 0.5; cursor: not-allowed; }
|
|
1537
1453
|
/* seed-design's focus treatment, same as Input: a 2px ring on an ::after
|
|
@@ -1547,7 +1463,7 @@
|
|
|
1547
1463
|
&[data-invalid] .crisp-textarea-wrap::after { border-color: var(--crisp-bg-danger); }
|
|
1548
1464
|
&[data-invalid] .crisp-textarea-wrap:focus-within::after { border-color: var(--crisp-bg-danger); }
|
|
1549
1465
|
&[data-counted] .crisp-textarea-field { padding-bottom: var(--crisp-space-5); }
|
|
1550
|
-
& .crisp-textarea-count { position: absolute; inset-inline-end:
|
|
1466
|
+
& .crisp-textarea-count { position: absolute; inset-inline-end: 14px; bottom: var(--crisp-space-2-5); font-size: var(--crisp-text-sm); color: var(--crisp-fg-muted); pointer-events: none; }
|
|
1551
1467
|
& .crisp-textarea-count[data-over] { color: var(--crisp-bg-danger); }
|
|
1552
1468
|
}
|
|
1553
1469
|
|
|
@@ -1717,7 +1633,7 @@
|
|
|
1717
1633
|
}
|
|
1718
1634
|
|
|
1719
1635
|
.crisp-command {
|
|
1720
|
-
display: contents; font-family: var(--crisp-font-sans)
|
|
1636
|
+
display: contents; font-family: var(--crisp-font-sans);
|
|
1721
1637
|
& .crisp-command-content, & .crisp-command-card { -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }
|
|
1722
1638
|
& .crisp-command-backdrop { position: fixed; inset: 0; z-index: 50; background: transparent; }
|
|
1723
1639
|
& .crisp-command-positioner { position: fixed; inset: 0; z-index: 51; display: flex; align-items: flex-start; justify-content: center; padding: 15vh var(--crisp-space-4) var(--crisp-space-4); }
|
|
@@ -1859,7 +1775,7 @@
|
|
|
1859
1775
|
}
|
|
1860
1776
|
|
|
1861
1777
|
.crisp-navitem {
|
|
1862
|
-
box-sizing: border-box; display: flex; align-items: center; gap: var(--crisp-space-1-5)
|
|
1778
|
+
box-sizing: border-box; display: flex; align-items: center; gap: var(--crisp-space-1-5); height: 28px; padding-inline: var(--crisp-space-2); padding-inline-end: var(--crisp-space-1); border-radius: var(--crisp-radius-lg); font-family: var(--crisp-font-sans); font-size: var(--crisp-text-lg); font-weight: var(--crisp-weight-medium); letter-spacing: -0.14px; line-height: 20px; color: var(--crisp-fg-primary); text-decoration: none; cursor: pointer; user-select: none; width: 100%; transition: background-color 0.16s;
|
|
1863
1779
|
& .crisp-navitem-label { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
|
|
1864
1780
|
& .crisp-navitem-trailing { margin-inline-start: auto; display: inline-flex; align-items: center; flex-shrink: 0; }
|
|
1865
1781
|
&:hover { background: color-mix(in srgb, var(--crisp-fg-primary) 2%, transparent); }
|
|
@@ -2380,7 +2296,7 @@
|
|
|
2380
2296
|
}
|
|
2381
2297
|
|
|
2382
2298
|
.crisp-sidebar {
|
|
2383
|
-
box-sizing: border-box; display: flex; flex-direction: column; width: 275px; height: 100%; background: var(--crisp-bg-sidebar)
|
|
2299
|
+
box-sizing: border-box; display: flex; flex-direction: column; width: 275px; height: 100%; background: var(--crisp-bg-sidebar); border-inline-end: 1px solid var(--crisp-border-subtle); padding: var(--crisp-space-2); font-family: var(--crisp-font-sans); -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; overflow-y: auto;
|
|
2384
2300
|
& .crisp-sidebar-section { display: flex; flex-direction: column; gap: var(--crisp-space-px); margin-top: var(--crisp-space-2); }
|
|
2385
2301
|
& .crisp-sidebar-section[data-collapsed] { display: none; }
|
|
2386
2302
|
& .crisp-sidebar-label { font-size: var(--crisp-text-sm); font-weight: var(--crisp-weight-medium); color: var(--crisp-fg-muted); padding: var(--crisp-space-1-5) var(--crisp-space-2) var(--crisp-space-0-5); }
|
package/dist/styles.layered.css
CHANGED
|
@@ -122,90 +122,6 @@
|
|
|
122
122
|
--crisp-font-sans: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
|
|
123
123
|
}
|
|
124
124
|
|
|
125
|
-
/* -----------------------------------------------------------------
|
|
126
|
-
* Deprecated unprefixed aliases (issue #276) — SCHEDULED FOR REMOVAL in
|
|
127
|
-
* the next major version. Prefer the --crisp-* custom property
|
|
128
|
-
* above; these only forward to it so an existing override keeps working.
|
|
129
|
-
* ----------------------------------------------------------------- */
|
|
130
|
-
:root {
|
|
131
|
-
--bg-brand-solid: var(--crisp-bg-brand-solid);
|
|
132
|
-
--bg-brand-solid-pressed: var(--crisp-bg-brand-solid-pressed);
|
|
133
|
-
--fg-on-brand: var(--crisp-fg-on-brand);
|
|
134
|
-
--fg-on-tone: var(--crisp-fg-on-tone);
|
|
135
|
-
--bg-surface: var(--crisp-bg-surface);
|
|
136
|
-
--bg-raised: var(--crisp-bg-raised);
|
|
137
|
-
--border-default: var(--crisp-border-default);
|
|
138
|
-
--border-subtle: var(--crisp-border-subtle);
|
|
139
|
-
--ring-neutral: var(--crisp-ring-neutral);
|
|
140
|
-
--bg-tile-active: var(--crisp-bg-tile-active);
|
|
141
|
-
--shadow-tile-active: var(--crisp-shadow-tile-active);
|
|
142
|
-
--bg-overlay-frost: var(--crisp-bg-overlay-frost);
|
|
143
|
-
--shadow-overlay1: var(--crisp-shadow-overlay1);
|
|
144
|
-
--shadow-overlay2: var(--crisp-shadow-overlay2);
|
|
145
|
-
--shadow-overlay3: var(--crisp-shadow-overlay3);
|
|
146
|
-
--bg-popover: var(--crisp-bg-popover);
|
|
147
|
-
--ring-popover: var(--crisp-ring-popover);
|
|
148
|
-
--shadow-popover1: var(--crisp-shadow-popover1);
|
|
149
|
-
--shadow-popover2: var(--crisp-shadow-popover2);
|
|
150
|
-
--shadow-popover3: var(--crisp-shadow-popover3);
|
|
151
|
-
--fg-primary: var(--crisp-fg-primary);
|
|
152
|
-
--fg-muted: var(--crisp-fg-muted);
|
|
153
|
-
--bg-danger: var(--crisp-bg-danger);
|
|
154
|
-
--bg-danger-solid: var(--crisp-bg-danger-solid);
|
|
155
|
-
--stroke-field-focus: var(--crisp-stroke-field-focus);
|
|
156
|
-
--fg-disabled: var(--crisp-fg-disabled);
|
|
157
|
-
--bg-neutral-weak: var(--crisp-bg-neutral-weak);
|
|
158
|
-
--bg-neutral-inverted: var(--crisp-bg-neutral-inverted);
|
|
159
|
-
--fg-on-neutral-inverted: var(--crisp-fg-on-neutral-inverted);
|
|
160
|
-
--fg-neutral-subtle: var(--crisp-fg-neutral-subtle);
|
|
161
|
-
--fg-neutral-muted: var(--crisp-fg-neutral-muted);
|
|
162
|
-
--stroke-focus-ring: var(--crisp-stroke-focus-ring);
|
|
163
|
-
--bg-success: var(--crisp-bg-success);
|
|
164
|
-
--bg-warning: var(--crisp-bg-warning);
|
|
165
|
-
--bg-orange: var(--crisp-bg-orange);
|
|
166
|
-
--bg-cyan: var(--crisp-bg-cyan);
|
|
167
|
-
--bg-purple: var(--crisp-bg-purple);
|
|
168
|
-
--bg-sidebar: var(--crisp-bg-sidebar);
|
|
169
|
-
--bg-subtle: var(--crisp-bg-subtle);
|
|
170
|
-
--space-1: var(--crisp-space-1);
|
|
171
|
-
--space-2: var(--crisp-space-2);
|
|
172
|
-
--space-3: var(--crisp-space-3);
|
|
173
|
-
--space-4: var(--crisp-space-4);
|
|
174
|
-
--space-5: var(--crisp-space-5);
|
|
175
|
-
--space-6: var(--crisp-space-6);
|
|
176
|
-
--space-8: var(--crisp-space-8);
|
|
177
|
-
--space-px: var(--crisp-space-px);
|
|
178
|
-
--space-0-5: var(--crisp-space-0-5);
|
|
179
|
-
--space-1-5: var(--crisp-space-1-5);
|
|
180
|
-
--space-2-5: var(--crisp-space-2-5);
|
|
181
|
-
--radius-chip: var(--crisp-radius-chip);
|
|
182
|
-
--radius-sm: var(--crisp-radius-sm);
|
|
183
|
-
--radius-md: var(--crisp-radius-md);
|
|
184
|
-
--radius-lg: var(--crisp-radius-lg);
|
|
185
|
-
--radius-xl: var(--crisp-radius-xl);
|
|
186
|
-
--radius-2xl: var(--crisp-radius-2xl);
|
|
187
|
-
--radius-full: var(--crisp-radius-full);
|
|
188
|
-
--size-icon: var(--crisp-size-icon);
|
|
189
|
-
--size-chip: var(--crisp-size-chip);
|
|
190
|
-
--size-row: var(--crisp-size-row);
|
|
191
|
-
--size-menuRow: var(--crisp-size-menuRow);
|
|
192
|
-
--size-tableRow: var(--crisp-size-tableRow);
|
|
193
|
-
--size-tableHeader: var(--crisp-size-tableHeader);
|
|
194
|
-
--size-header: var(--crisp-size-header);
|
|
195
|
-
--size-calendarCell: var(--crisp-size-calendarCell);
|
|
196
|
-
--size-calendarPill: var(--crisp-size-calendarPill);
|
|
197
|
-
--text-xs: var(--crisp-text-xs);
|
|
198
|
-
--text-sm: var(--crisp-text-sm);
|
|
199
|
-
--text-md: var(--crisp-text-md);
|
|
200
|
-
--text-lg: var(--crisp-text-lg);
|
|
201
|
-
--text-xl: var(--crisp-text-xl);
|
|
202
|
-
--weight-regular: var(--crisp-weight-regular);
|
|
203
|
-
--weight-medium: var(--crisp-weight-medium);
|
|
204
|
-
--weight-semibold: var(--crisp-weight-semibold);
|
|
205
|
-
--weight-bold: var(--crisp-weight-bold);
|
|
206
|
-
--font-sans: var(--crisp-font-sans);
|
|
207
|
-
}
|
|
208
|
-
|
|
209
125
|
@layer crisp-components {
|
|
210
126
|
.crisp-accordion {
|
|
211
127
|
display: flex; flex-direction: column; font-family: var(--crisp-font-sans);
|
|
@@ -484,7 +400,7 @@
|
|
|
484
400
|
}
|
|
485
401
|
|
|
486
402
|
.crisp-checkbox {
|
|
487
|
-
appearance: none; -webkit-appearance: none; box-sizing: border-box; flex-shrink: 0; margin: 0; width: 16px; height: 16px; border: none; border-radius: var(--crisp-radius-sm)
|
|
403
|
+
appearance: none; -webkit-appearance: none; box-sizing: border-box; flex-shrink: 0; margin: 0; width: 16px; height: 16px; border: none; border-radius: var(--crisp-radius-sm); background: var(--crisp-bg-surface); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--crisp-fg-primary) 9%, transparent); cursor: pointer; transition: background-color .12s, box-shadow .12s;
|
|
488
404
|
&:hover { box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--crisp-fg-primary) 30%, transparent); }
|
|
489
405
|
&:checked, &:indeterminate { background: var(--crisp-bg-brand-solid) center / 10px no-repeat; box-shadow: none; }
|
|
490
406
|
&:checked { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 12 12' fill='none' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M2.5 6.5 5 9l4.5-5'/%3E%3C/svg%3E"); }
|
|
@@ -1532,7 +1448,7 @@
|
|
|
1532
1448
|
|
|
1533
1449
|
.crisp-textarea {
|
|
1534
1450
|
position: relative; display: block; width: 100%; font-family: var(--crisp-font-sans);
|
|
1535
|
-
& .crisp-textarea-field { box-sizing: border-box; display: block; width: 100%; min-height: 80px; resize: vertical; margin: 0; padding: var(--crisp-space-
|
|
1451
|
+
& .crisp-textarea-field { box-sizing: border-box; display: block; width: 100%; min-height: 80px; resize: vertical; margin: 0; padding: var(--crisp-space-2-5) 14px; border: none; border-radius: var(--crisp-radius-md); background: var(--crisp-bg-surface); box-shadow: inset 0 0 0 1px var(--crisp-ring-neutral), 0 0 2px rgba(28,40,64,0.18), 0 1px 3px rgba(0,0,0,0.04); font-family: inherit; font-size: var(--crisp-text-lg); line-height: 20px; color: var(--crisp-fg-primary); outline: none; transition: box-shadow .15s ease; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }
|
|
1536
1452
|
& .crisp-textarea-field::placeholder { color: var(--crisp-fg-muted); }
|
|
1537
1453
|
& .crisp-textarea-field:disabled { opacity: 0.5; cursor: not-allowed; }
|
|
1538
1454
|
/* seed-design's focus treatment, same as Input: a 2px ring on an ::after
|
|
@@ -1548,7 +1464,7 @@
|
|
|
1548
1464
|
&[data-invalid] .crisp-textarea-wrap::after { border-color: var(--crisp-bg-danger); }
|
|
1549
1465
|
&[data-invalid] .crisp-textarea-wrap:focus-within::after { border-color: var(--crisp-bg-danger); }
|
|
1550
1466
|
&[data-counted] .crisp-textarea-field { padding-bottom: var(--crisp-space-5); }
|
|
1551
|
-
& .crisp-textarea-count { position: absolute; inset-inline-end:
|
|
1467
|
+
& .crisp-textarea-count { position: absolute; inset-inline-end: 14px; bottom: var(--crisp-space-2-5); font-size: var(--crisp-text-sm); color: var(--crisp-fg-muted); pointer-events: none; }
|
|
1552
1468
|
& .crisp-textarea-count[data-over] { color: var(--crisp-bg-danger); }
|
|
1553
1469
|
}
|
|
1554
1470
|
|
|
@@ -1718,7 +1634,7 @@
|
|
|
1718
1634
|
}
|
|
1719
1635
|
|
|
1720
1636
|
.crisp-command {
|
|
1721
|
-
display: contents; font-family: var(--crisp-font-sans)
|
|
1637
|
+
display: contents; font-family: var(--crisp-font-sans);
|
|
1722
1638
|
& .crisp-command-content, & .crisp-command-card { -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }
|
|
1723
1639
|
& .crisp-command-backdrop { position: fixed; inset: 0; z-index: 50; background: transparent; }
|
|
1724
1640
|
& .crisp-command-positioner { position: fixed; inset: 0; z-index: 51; display: flex; align-items: flex-start; justify-content: center; padding: 15vh var(--crisp-space-4) var(--crisp-space-4); }
|
|
@@ -1860,7 +1776,7 @@
|
|
|
1860
1776
|
}
|
|
1861
1777
|
|
|
1862
1778
|
.crisp-navitem {
|
|
1863
|
-
box-sizing: border-box; display: flex; align-items: center; gap: var(--crisp-space-1-5)
|
|
1779
|
+
box-sizing: border-box; display: flex; align-items: center; gap: var(--crisp-space-1-5); height: 28px; padding-inline: var(--crisp-space-2); padding-inline-end: var(--crisp-space-1); border-radius: var(--crisp-radius-lg); font-family: var(--crisp-font-sans); font-size: var(--crisp-text-lg); font-weight: var(--crisp-weight-medium); letter-spacing: -0.14px; line-height: 20px; color: var(--crisp-fg-primary); text-decoration: none; cursor: pointer; user-select: none; width: 100%; transition: background-color 0.16s;
|
|
1864
1780
|
& .crisp-navitem-label { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
|
|
1865
1781
|
& .crisp-navitem-trailing { margin-inline-start: auto; display: inline-flex; align-items: center; flex-shrink: 0; }
|
|
1866
1782
|
&:hover { background: color-mix(in srgb, var(--crisp-fg-primary) 2%, transparent); }
|
|
@@ -2381,7 +2297,7 @@
|
|
|
2381
2297
|
}
|
|
2382
2298
|
|
|
2383
2299
|
.crisp-sidebar {
|
|
2384
|
-
box-sizing: border-box; display: flex; flex-direction: column; width: 275px; height: 100%; background: var(--crisp-bg-sidebar)
|
|
2300
|
+
box-sizing: border-box; display: flex; flex-direction: column; width: 275px; height: 100%; background: var(--crisp-bg-sidebar); border-inline-end: 1px solid var(--crisp-border-subtle); padding: var(--crisp-space-2); font-family: var(--crisp-font-sans); -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; overflow-y: auto;
|
|
2385
2301
|
& .crisp-sidebar-section { display: flex; flex-direction: column; gap: var(--crisp-space-px); margin-top: var(--crisp-space-2); }
|
|
2386
2302
|
& .crisp-sidebar-section[data-collapsed] { display: none; }
|
|
2387
2303
|
& .crisp-sidebar-label { font-size: var(--crisp-text-sm); font-weight: var(--crisp-weight-medium); color: var(--crisp-fg-muted); padding: var(--crisp-space-1-5) var(--crisp-space-2) var(--crisp-space-0-5); }
|
package/dist/textarea.css
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
.crisp-textarea {
|
|
2
2
|
position: relative; display: block; width: 100%; font-family: var(--crisp-font-sans);
|
|
3
|
-
& .crisp-textarea-field { box-sizing: border-box; display: block; width: 100%; min-height: 80px; resize: vertical; margin: 0; padding: var(--crisp-space-
|
|
3
|
+
& .crisp-textarea-field { box-sizing: border-box; display: block; width: 100%; min-height: 80px; resize: vertical; margin: 0; padding: var(--crisp-space-2-5) 14px; border: none; border-radius: var(--crisp-radius-md); background: var(--crisp-bg-surface); box-shadow: inset 0 0 0 1px var(--crisp-ring-neutral), 0 0 2px rgba(28,40,64,0.18), 0 1px 3px rgba(0,0,0,0.04); font-family: inherit; font-size: var(--crisp-text-lg); line-height: 20px; color: var(--crisp-fg-primary); outline: none; transition: box-shadow .15s ease; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }
|
|
4
4
|
& .crisp-textarea-field::placeholder { color: var(--crisp-fg-muted); }
|
|
5
5
|
& .crisp-textarea-field:disabled { opacity: 0.5; cursor: not-allowed; }
|
|
6
6
|
/* seed-design's focus treatment, same as Input: a 2px ring on an ::after
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
&[data-invalid] .crisp-textarea-wrap::after { border-color: var(--crisp-bg-danger); }
|
|
17
17
|
&[data-invalid] .crisp-textarea-wrap:focus-within::after { border-color: var(--crisp-bg-danger); }
|
|
18
18
|
&[data-counted] .crisp-textarea-field { padding-bottom: var(--crisp-space-5); }
|
|
19
|
-
& .crisp-textarea-count { position: absolute; inset-inline-end:
|
|
19
|
+
& .crisp-textarea-count { position: absolute; inset-inline-end: 14px; bottom: var(--crisp-space-2-5); font-size: var(--crisp-text-sm); color: var(--crisp-fg-muted); pointer-events: none; }
|
|
20
20
|
& .crisp-textarea-count[data-over] { color: var(--crisp-bg-danger); }
|
|
21
21
|
}
|
|
22
22
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
@layer crisp-components {
|
|
2
2
|
.crisp-textarea {
|
|
3
3
|
position: relative; display: block; width: 100%; font-family: var(--crisp-font-sans);
|
|
4
|
-
& .crisp-textarea-field { box-sizing: border-box; display: block; width: 100%; min-height: 80px; resize: vertical; margin: 0; padding: var(--crisp-space-
|
|
4
|
+
& .crisp-textarea-field { box-sizing: border-box; display: block; width: 100%; min-height: 80px; resize: vertical; margin: 0; padding: var(--crisp-space-2-5) 14px; border: none; border-radius: var(--crisp-radius-md); background: var(--crisp-bg-surface); box-shadow: inset 0 0 0 1px var(--crisp-ring-neutral), 0 0 2px rgba(28,40,64,0.18), 0 1px 3px rgba(0,0,0,0.04); font-family: inherit; font-size: var(--crisp-text-lg); line-height: 20px; color: var(--crisp-fg-primary); outline: none; transition: box-shadow .15s ease; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }
|
|
5
5
|
& .crisp-textarea-field::placeholder { color: var(--crisp-fg-muted); }
|
|
6
6
|
& .crisp-textarea-field:disabled { opacity: 0.5; cursor: not-allowed; }
|
|
7
7
|
/* seed-design's focus treatment, same as Input: a 2px ring on an ::after
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
&[data-invalid] .crisp-textarea-wrap::after { border-color: var(--crisp-bg-danger); }
|
|
18
18
|
&[data-invalid] .crisp-textarea-wrap:focus-within::after { border-color: var(--crisp-bg-danger); }
|
|
19
19
|
&[data-counted] .crisp-textarea-field { padding-bottom: var(--crisp-space-5); }
|
|
20
|
-
& .crisp-textarea-count { position: absolute; inset-inline-end:
|
|
20
|
+
& .crisp-textarea-count { position: absolute; inset-inline-end: 14px; bottom: var(--crisp-space-2-5); font-size: var(--crisp-text-sm); color: var(--crisp-fg-muted); pointer-events: none; }
|
|
21
21
|
& .crisp-textarea-count[data-over] { color: var(--crisp-bg-danger); }
|
|
22
22
|
}
|
|
23
23
|
|