@elcrm/components 0.2.9 → 0.2.13

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.
@@ -0,0 +1,178 @@
1
+ import e from "react";
2
+ import { B as K } from "./Badge-jp-9iNNL.js";
3
+ import { D as R } from "./Dropdown-DosvDR13.js";
4
+ import { I as F } from "./Item-D4okhsfW.js";
5
+ import { b as I } from "./badgeText-CRzlIzi3.js";
6
+ import { c as f } from "./cx-CcykAxZN.js";
7
+ import { c as L, b as M } from "./navTree-BRyaILN9.js";
8
+ import { u as O } from "./useControllableValue-CWqH1kpM.js";
9
+ import './Sidebar.css';const T = "c2r", V = "c2b", j = "c2x", z = "c2g", A = "c2s", W = "c2p", $ = "c2h", G = "c2n", H = "c2i", J = "c2a", P = "c2o", Q = "c2l", U = "c2d", X = "c2c", Y = "c2m", Z = "c2f", _ = "c2q", S = "c2w", ee = "c2u", ne = "c2k", ce = "c2v", n = {
10
+ r: T,
11
+ b: V,
12
+ x: j,
13
+ g: z,
14
+ s: A,
15
+ p: W,
16
+ h: $,
17
+ n: G,
18
+ i: H,
19
+ a: J,
20
+ o: P,
21
+ l: Q,
22
+ d: U,
23
+ c: X,
24
+ m: Y,
25
+ f: Z,
26
+ q: _,
27
+ w: S,
28
+ u: ee,
29
+ k: ne,
30
+ v: ce
31
+ };
32
+ function te({ className: l }) {
33
+ return /* @__PURE__ */ e.createElement("svg", { className: l, viewBox: "0 0 16 16", "aria-hidden": !0 }, /* @__PURE__ */ e.createElement("circle", { cx: "8", cy: "3", r: "1.3", fill: "currentColor" }), /* @__PURE__ */ e.createElement("circle", { cx: "8", cy: "8", r: "1.3", fill: "currentColor" }), /* @__PURE__ */ e.createElement("circle", { cx: "8", cy: "13", r: "1.3", fill: "currentColor" }));
34
+ }
35
+ function le({
36
+ footer: l,
37
+ className: u,
38
+ ...c
39
+ }) {
40
+ const o = /* @__PURE__ */ e.createElement(te, { className: n.k });
41
+ if (e.isValidElement(l) && typeof l.type != "string") {
42
+ const s = l.props;
43
+ return e.cloneElement(l, {
44
+ as: "button",
45
+ extra: s.extra ?? o,
46
+ className: f(s.className, u),
47
+ ...c,
48
+ onClick: (t) => {
49
+ var i, a;
50
+ (i = s.onClick) == null || i.call(s, t), (a = c.onClick) == null || a.call(c, t);
51
+ }
52
+ });
53
+ }
54
+ return /* @__PURE__ */ e.createElement("button", { type: "button", className: f(n.u, u), ...c }, /* @__PURE__ */ e.createElement("span", { className: n.w }, l), o);
55
+ }
56
+ function ae({ className: l }) {
57
+ return /* @__PURE__ */ e.createElement("svg", { className: l, viewBox: "0 0 12 12", "aria-hidden": !0 }, /* @__PURE__ */ e.createElement(
58
+ "path",
59
+ {
60
+ d: "M2.5 4.5 6 8l3.5-3.5",
61
+ fill: "none",
62
+ stroke: "currentColor",
63
+ strokeWidth: "1.5",
64
+ strokeLinecap: "round",
65
+ strokeLinejoin: "round"
66
+ }
67
+ ));
68
+ }
69
+ function x({
70
+ items: l,
71
+ value: u,
72
+ open: c,
73
+ onSelect: o,
74
+ onToggle: s
75
+ }) {
76
+ return /* @__PURE__ */ e.createElement(e.Fragment, null, l.map((t) => {
77
+ const i = t.items, a = i != null && i.length > 0, E = a && c.includes(t.value), p = I(t.badge), m = !a && u === t.value;
78
+ return /* @__PURE__ */ e.createElement("li", { key: t.value }, /* @__PURE__ */ e.createElement(
79
+ F,
80
+ {
81
+ as: "button",
82
+ active: m,
83
+ className: f(n.i, m && n.a),
84
+ "aria-current": m ? "page" : void 0,
85
+ "aria-expanded": a ? E : void 0,
86
+ "data-open": E ? "true" : void 0,
87
+ onClick: () => {
88
+ a ? s(t.value) : o == null || o(t.value);
89
+ }
90
+ },
91
+ t.icon != null ? /* @__PURE__ */ e.createElement("span", { className: n.o, "aria-hidden": !0 }, t.icon) : null,
92
+ /* @__PURE__ */ e.createElement("span", { className: n.l }, t.label),
93
+ p != null ? /* @__PURE__ */ e.createElement(K, { className: n.d, tone: "accent", size: "s" }, p) : null,
94
+ a ? /* @__PURE__ */ e.createElement(ae, { className: n.c }) : null
95
+ ), a && E ? /* @__PURE__ */ e.createElement("ul", { className: n.m }, /* @__PURE__ */ e.createElement(
96
+ x,
97
+ {
98
+ items: i,
99
+ value: u,
100
+ open: c,
101
+ onSelect: o,
102
+ onToggle: s
103
+ }
104
+ )) : null);
105
+ }));
106
+ }
107
+ function pe({
108
+ groups: l,
109
+ items: u,
110
+ value: c,
111
+ onSelect: o,
112
+ open: s,
113
+ defaultOpen: t,
114
+ onOpenChange: i,
115
+ variant: a = "cards",
116
+ brand: E,
117
+ extra: p,
118
+ footer: m,
119
+ footerItems: g,
120
+ onFooterSelect: y,
121
+ footerMenuLabel: C = "Меню аккаунта",
122
+ version: v,
123
+ className: w,
124
+ "aria-label": q = "Основное меню"
125
+ }) {
126
+ const N = l ?? u ?? [], [d = [], k] = O(
127
+ s,
128
+ L(N, t, c),
129
+ i
130
+ ), h = e.useRef(c);
131
+ e.useEffect(() => {
132
+ if (c == null || c === h.current) {
133
+ h.current = c;
134
+ return;
135
+ }
136
+ h.current = c;
137
+ const b = M(N, c).filter((D) => !d.includes(D));
138
+ b.length && k([...d, ...b]);
139
+ }, [c, N, d, k]);
140
+ const B = (r) => {
141
+ k(
142
+ d.includes(r) ? d.filter((b) => b !== r) : [...d, r]
143
+ );
144
+ };
145
+ return /* @__PURE__ */ e.createElement(
146
+ "aside",
147
+ {
148
+ className: f(n.r, a === "plain" && n.p, w),
149
+ "aria-label": q
150
+ },
151
+ E != null || p != null ? /* @__PURE__ */ e.createElement("div", { className: n.b }, E, p != null ? /* @__PURE__ */ e.createElement("div", { className: n.x }, p) : null) : null,
152
+ /* @__PURE__ */ e.createElement("div", { className: n.g }, N.map((r) => /* @__PURE__ */ e.createElement("nav", { key: r.value, className: n.s, "aria-label": r.title ?? "Навигация" }, r.title ? /* @__PURE__ */ e.createElement("div", { className: n.h }, r.title) : null, /* @__PURE__ */ e.createElement("ul", { className: n.n }, /* @__PURE__ */ e.createElement(
153
+ x,
154
+ {
155
+ items: r.items ?? [],
156
+ value: c,
157
+ open: d,
158
+ onSelect: o,
159
+ onToggle: B
160
+ }
161
+ ))))),
162
+ m != null || v != null ? /* @__PURE__ */ e.createElement("div", { className: f(n.s, n.f) }, m != null && g != null && g.length > 0 ? /* @__PURE__ */ e.createElement(
163
+ R,
164
+ {
165
+ className: n.q,
166
+ align: "start",
167
+ placement: "top",
168
+ label: C,
169
+ trigger: /* @__PURE__ */ e.createElement(le, { footer: m, className: n.w }),
170
+ items: g,
171
+ onSelect: y
172
+ }
173
+ ) : m, v != null ? /* @__PURE__ */ e.createElement("div", { className: n.v }, v) : null) : null
174
+ );
175
+ }
176
+ export {
177
+ pe as S
178
+ };
package/dist/Sidebar.css CHANGED
@@ -1 +1 @@
1
- @layer elcrm-components{.c2r{box-sizing:border-box;display:flex;flex-direction:column;flex:1 1 auto;width:var(--sidebar-width, 248px);min-width:0;min-height:0;height:100%;max-height:100%;padding:var(--sidebar-pad-y, 16px) var(--sidebar-pad-x, 12px);gap:var(--shell-gap-sm, 8px);color:var(--shell-color);align-self:stretch}.c2b{display:flex;flex-direction:row;align-items:center;gap:var(--shell-gap);padding:4px 8px;min-width:0}.c2x{flex-shrink:0;margin-left:auto}.c2g{flex:1;min-height:0;display:flex;flex-direction:column;gap:var(--shell-gap-sm);overflow-y:auto;overflow-x:hidden;scrollbar-width:thin}.c2s{box-sizing:border-box;flex-shrink:0;padding:8px}.c2p{--sidebar-plain: 1}.c2r:not(.c2p) .c2s{background:var(--sidebar-block-bg);border:1px solid var(--sidebar-block-border);border-radius:var(--sidebar-block-radius);box-shadow:var(--sidebar-block-shadow)}.c2h{margin:2px 10px 6px;font-size:var(--sidebar-group-font-size);font-weight:600;letter-spacing:.08em;text-transform:uppercase;color:var(--shell-color-muted)}.c2n{margin:0;padding:0;list-style:none}.c2n>li{list-style:none}.c2n .c2i:is(button){position:relative;display:flex;width:100%;box-sizing:border-box;flex-direction:row;align-items:center;gap:8px;margin:0 0 1px;padding:var(--sidebar-item-padding);border:0;border-radius:8px;background:transparent;color:var(--shell-color-muted);font-family:inherit;font-size:var(--sidebar-item-font-size);font-weight:500;line-height:1.25;letter-spacing:0;text-align:left;cursor:pointer}.c2n .c2i:is(button):hover{color:var(--shell-color);background:var(--shell-background-hover)}.c2n .c2i:is(button).c2a,.c2n .c2i:is(button)[aria-current=page],.c2n .c2i:is(button)[data-active=true],.c2n .c2i:is(button).c2a:hover{color:var(--sidebar-item-active);background:var(--sidebar-item-active-bg)}.c2o{display:inline-flex;flex-shrink:0;align-items:center;justify-content:center;width:var(--sidebar-icon-size);height:var(--sidebar-icon-size);color:inherit}.c2o :is(svg){display:block;width:var(--sidebar-icon-size);height:var(--sidebar-icon-size)}.c2a .c2o{color:var(--sidebar-icon-active)}.c2l{flex:1;min-width:0}.c2d{flex-shrink:0;min-width:16px;height:16px;padding:0 4px;font-size:10px}.c2f{margin-top:auto}.c2q{display:flex;width:100%;min-width:0;flex:0 0 auto;height:auto;align-items:center}.c2q>*{display:flex;width:100%;min-width:0;height:auto;align-items:center}.c2w{display:flex;width:100%;min-width:0;align-items:center}.c2u{display:flex;align-items:center;width:100%;min-width:0;gap:var(--shell-gap-sm);margin:0;padding:0;border:none;background:transparent;font:inherit;color:inherit;cursor:pointer;text-align:left}.c2k{flex-shrink:0;width:var(--sidebar-icon-size);height:var(--sidebar-icon-size);color:var(--shell-color-muted)}.c2v{margin-top:var(--shell-gap-sm);font-size:11px;color:var(--shell-color-muted);text-align:center}@media (max-width: 900px){.c2r{width:72px;padding:12px 8px}.c2l,.c2h,.c2v{display:none}.c2b{flex-direction:column;justify-content:center;align-items:center;gap:8px;padding:4px 0}.c2x{margin-left:0}.c2s{padding:6px}.c2n .c2i{justify-content:center;align-items:center;gap:0;width:100%;min-height:40px;padding:10px 0}.c2n .c2d{position:absolute;top:4px;right:4px;min-width:14px;height:14px;padding:0 4px;font-size:.625rem;line-height:14px;pointer-events:none}}}
1
+ @layer elcrm-components{.c2r{box-sizing:border-box;display:flex;flex-direction:column;flex:1 1 auto;width:var(--sidebar-width, 248px);min-width:0;min-height:0;height:100%;max-height:100%;padding:var(--sidebar-pad-y, 16px) var(--sidebar-pad-x, 12px);gap:var(--shell-gap-sm, 8px);color:var(--shell-color);align-self:stretch}.c2b{display:flex;flex-direction:row;align-items:center;gap:var(--shell-gap);padding:4px 8px;min-width:0}.c2x{flex-shrink:0;margin-left:auto}.c2g{flex:1;min-height:0;display:flex;flex-direction:column;gap:var(--shell-gap-sm);overflow-y:auto;overflow-x:hidden;scrollbar-width:thin}.c2s{box-sizing:border-box;flex-shrink:0;padding:8px}.c2p{--sidebar-plain: 1}.c2r:not(.c2p) .c2s{background:var(--sidebar-block-bg);border:1px solid var(--sidebar-block-border);border-radius:var(--sidebar-block-radius);box-shadow:var(--sidebar-block-shadow)}.c2h{margin:2px 10px 6px;font-size:var(--sidebar-group-font-size);font-weight:600;letter-spacing:.08em;text-transform:uppercase;color:var(--shell-color-muted)}.c2n{margin:0;padding:0;list-style:none}.c2n>li{list-style:none}.c2n .c2i:is(button){position:relative;display:flex;width:100%;box-sizing:border-box;flex-direction:row;align-items:center;gap:8px;margin:0 0 1px;padding:var(--sidebar-item-padding);border:0;border-radius:8px;background:transparent;color:var(--shell-color-muted);font-family:inherit;font-size:var(--sidebar-item-font-size);font-weight:500;line-height:1.25;letter-spacing:0;text-align:left;cursor:pointer}.c2n .c2i:is(button):hover{color:var(--shell-color);background:var(--shell-background-hover)}.c2n .c2i:is(button).c2a,.c2n .c2i:is(button)[aria-current=page],.c2n .c2i:is(button)[data-active=true],.c2n .c2i:is(button).c2a:hover{color:var(--sidebar-item-active);background:var(--sidebar-item-active-bg)}.c2o{display:inline-flex;flex-shrink:0;align-items:center;justify-content:center;width:var(--sidebar-icon-size);height:var(--sidebar-icon-size);color:inherit}.c2o :is(svg){display:block;width:var(--sidebar-icon-size);height:var(--sidebar-icon-size)}.c2a .c2o{color:var(--sidebar-icon-active)}.c2l{flex:1;min-width:0}.c2d{flex-shrink:0;min-width:16px;height:16px;padding:0 4px;font-size:10px}.c2c{flex-shrink:0;width:12px;height:12px;margin-left:auto;color:var(--shell-color-muted);transition:transform .15s ease}.c2n .c2i:is(button)[data-open=true] .c2c{transform:rotate(180deg);color:inherit}.c2m{margin:0;padding:0 0 0 var(--sidebar-indent);list-style:none}.c2m>li{list-style:none}.c2f{margin-top:auto}.c2q{display:flex;width:100%;min-width:0;flex:0 0 auto;height:auto;align-items:center}.c2q>*{display:flex;width:100%;min-width:0;height:auto;align-items:center}.c2w{display:flex;width:100%;min-width:0;align-items:center}.c2u{display:flex;align-items:center;width:100%;min-width:0;gap:var(--shell-gap-sm);margin:0;padding:0;border:none;background:transparent;font:inherit;color:inherit;cursor:pointer;text-align:left}.c2k{flex-shrink:0;width:var(--sidebar-icon-size);height:var(--sidebar-icon-size);color:var(--shell-color-muted)}.c2v{margin-top:var(--shell-gap-sm);font-size:11px;color:var(--shell-color-muted);text-align:center}@media (max-width: 900px){.c2r{width:72px;padding:12px 8px}.c2l,.c2h,.c2v,.c2c,.c2m{display:none}.c2b{flex-direction:column;justify-content:center;align-items:center;gap:8px;padding:4px 0}.c2x{margin-left:0}.c2s{padding:6px}.c2n .c2i{justify-content:center;align-items:center;gap:0;width:100%;min-height:40px;padding:10px 0}.c2n .c2d{position:absolute;top:4px;right:4px;min-width:14px;height:14px;padding:0 4px;font-size:.625rem;line-height:14px;pointer-events:none}}}
package/dist/Sidebar.d.ts CHANGED
@@ -11,6 +11,17 @@ export type SidebarItem = {
11
11
  icon?: React.ReactNode;
12
12
  /** Счётчик справа */
13
13
  badge?: number | string | null;
14
+ /**
15
+ * Вложенные пункты — есть → шеврон и раскрытие.
16
+ * Клик по родителю только открывает/закрывает, `onSelect` не зовём.
17
+ */
18
+ items?: SidebarItem[];
19
+ /**
20
+ * Подменю открыто при первом рендере.
21
+ * Если выбран потомок — ветка откроется сама.
22
+ * @default false
23
+ */
24
+ defaultOpen?: boolean;
14
25
  };
15
26
  /** Группа пунктов. `title` — «Аккаунт» / «Админ». */
16
27
  export type SidebarGroup = {
@@ -39,8 +50,23 @@ export type SidebarGroup = {
39
50
  * brand={<Brand as="strong">App</Brand>}
40
51
  * extra={<Notifications.Bell />}
41
52
  * groups={[
42
- * { value: "main", items: [{ value: "home", label: "Обзор", icon: <Icon /> }] },
43
- * { value: "admin", title: "Админ", items: [{ value: "users", label: "Люди" }] },
53
+ * {
54
+ * value: "docs",
55
+ * items: [
56
+ * { value: "games", label: "VK Games" },
57
+ * {
58
+ * value: "bridge",
59
+ * label: "VK Bridge",
60
+ * defaultOpen: true,
61
+ * items: [
62
+ * { value: "intro", label: "Введение" },
63
+ * { value: "events", label: "События", items: [
64
+ * { value: "evt-init", label: "VKWebAppInit" },
65
+ * ] },
66
+ * ],
67
+ * },
68
+ * ],
69
+ * },
44
70
  * ]}
45
71
  * footer={<AvatarName title="Паша" description="mail@…" />}
46
72
  * footerItems={[
@@ -62,8 +88,19 @@ export type SidebarProps = {
62
88
  items?: SidebarGroup[];
63
89
  /** Текущий пункт */
64
90
  value?: string;
65
- /** Выбор пункта */
91
+ /** Выбор пункта (только листья, без `items`) */
66
92
  onSelect?: (value: string) => void;
93
+ /**
94
+ * Раскрытые родители (их `value`). Контролируемый режим.
95
+ * Вместе с `onOpenChange`.
96
+ */
97
+ open?: string[];
98
+ /**
99
+ * Начально раскрытые (плюс `item.defaultOpen` и предки выбранного).
100
+ */
101
+ defaultOpen?: string[];
102
+ /** Смена набора раскрытых родителей */
103
+ onOpenChange?: (open: string[]) => void;
67
104
  /**
68
105
  * `cards` — блоки-карточки.
69
106
  * `plain` — плоский список.
@@ -96,4 +133,4 @@ export type SidebarProps = {
96
133
  *
97
134
  * @see Layout, Brand, Item, Badge, NavSections
98
135
  */
99
- export declare function Sidebar({ groups, items, value, onSelect, variant, brand, extra, footer, footerItems, onFooterSelect, footerMenuLabel, version, className, "aria-label": ariaLabel, }: SidebarProps): React.JSX.Element;
136
+ export declare function Sidebar({ groups, items, value, onSelect, open: openProp, defaultOpen, onOpenChange, variant, brand, extra, footer, footerItems, onFooterSelect, footerMenuLabel, version, className, "aria-label": ariaLabel, }: SidebarProps): React.JSX.Element;
package/dist/Sidebar.js CHANGED
@@ -1,4 +1,4 @@
1
- import { S as e } from "./Sidebar-BgZiGEDH.js";
1
+ import { S as e } from "./Sidebar-CYFaPqdC.js";
2
2
  export {
3
3
  e as Sidebar
4
4
  };
@@ -0,0 +1,74 @@
1
+ import o from "react";
2
+ import { c as P } from "./cx-CcykAxZN.js";
3
+ import './SplitPane.css';function $(t, e, l, i) {
4
+ if (e <= 0) return t;
5
+ const r = l / e, c = 1 - i / e;
6
+ return c < r ? 0.5 : Math.max(r, Math.min(c, t));
7
+ }
8
+ const B = "cFr", C = "cFx", D = "cFy", H = "cFp", X = "cFh", n = {
9
+ r: B,
10
+ x: C,
11
+ y: D,
12
+ p: H,
13
+ h: X
14
+ }, z = 6;
15
+ function E() {
16
+ if (typeof document > "u") return z;
17
+ const t = getComputedStyle(document.documentElement).getPropertyValue("--split-handle-size").trim(), e = Number.parseFloat(t);
18
+ return Number.isFinite(e) && e > 0 ? e : z;
19
+ }
20
+ function V({
21
+ direction: t,
22
+ ratio: e,
23
+ onRatioChange: l,
24
+ minFirst: i = 140,
25
+ minSecond: r = 140,
26
+ first: c,
27
+ second: S,
28
+ className: b,
29
+ ...F
30
+ }) {
31
+ const m = o.useRef(null), R = t === "horizontal" ? "x" : "y", N = (u) => {
32
+ u.preventDefault();
33
+ const p = m.current;
34
+ if (!p) return;
35
+ const f = E(), s = p.getBoundingClientRect(), h = t === "horizontal" ? s.width - f : s.height - f, y = (a, L) => {
36
+ const M = t === "horizontal" ? a - s.left : L - s.top;
37
+ l($(M / h, h, i, r));
38
+ };
39
+ y(u.clientX, u.clientY);
40
+ const x = (a) => {
41
+ y(a.clientX, a.clientY);
42
+ }, v = () => {
43
+ document.removeEventListener("pointermove", x), document.removeEventListener("pointerup", v), document.body.style.cursor = "", document.body.style.userSelect = "";
44
+ };
45
+ document.body.style.cursor = t === "horizontal" ? "col-resize" : "row-resize", document.body.style.userSelect = "none", document.addEventListener("pointermove", x), document.addEventListener("pointerup", v);
46
+ }, d = E(), g = `calc((100% - ${d}px) * ${e})`, w = `calc((100% - ${d}px) * ${1 - e})`;
47
+ return /* @__PURE__ */ o.createElement(
48
+ "div",
49
+ {
50
+ ref: m,
51
+ className: P(n.r, R === "x" ? n.x : n.y, b),
52
+ ...F
53
+ },
54
+ /* @__PURE__ */ o.createElement("div", { className: n.p, style: { flexBasis: g } }, c),
55
+ /* @__PURE__ */ o.createElement(
56
+ "button",
57
+ {
58
+ type: "button",
59
+ className: n.h,
60
+ role: "separator",
61
+ "aria-orientation": t === "horizontal" ? "vertical" : "horizontal",
62
+ "aria-valuenow": Math.round(e * 100),
63
+ "aria-valuemin": 0,
64
+ "aria-valuemax": 100,
65
+ onPointerDown: N
66
+ }
67
+ ),
68
+ /* @__PURE__ */ o.createElement("div", { className: n.p, style: { flexBasis: w } }, S)
69
+ );
70
+ }
71
+ export {
72
+ V as S,
73
+ $ as c
74
+ };
@@ -0,0 +1 @@
1
+ @layer elcrm-components{.cFr{display:flex;min-height:0;min-width:0}.cFx{flex-direction:row}.cFy{flex-direction:column}.cFp{min-width:0;min-height:0;overflow:auto}.cFh{flex:0 0 var(--split-handle-size);margin:0;padding:0;border:0;background:var(--split-handle-bg);cursor:col-resize;touch-action:none}.cFy .cFh{cursor:row-resize}.cFh:hover,.cFh:focus-visible{background:var(--split-handle-bg-hover)}}
@@ -0,0 +1,29 @@
1
+ import { default as React } from 'react';
2
+ export type SplitPaneDirection = "horizontal" | "vertical";
3
+ export type SplitPaneProps = React.HTMLAttributes<HTMLDivElement> & {
4
+ direction: SplitPaneDirection;
5
+ /** Доля первой панели 0…1 */
6
+ ratio: number;
7
+ onRatioChange: (ratio: number) => void;
8
+ minFirst?: number;
9
+ minSecond?: number;
10
+ first: React.ReactNode;
11
+ second: React.ReactNode;
12
+ };
13
+ /**
14
+ * Две панели с перетаскиваемым разделителем.
15
+ *
16
+ * @example
17
+ * ```tsx
18
+ * <SplitPane
19
+ * direction="horizontal"
20
+ * ratio={0.58}
21
+ * onRatioChange={setRatio}
22
+ * first={<Preview />}
23
+ * second={<Editor />}
24
+ * />
25
+ * ```
26
+ *
27
+ * Токены: `--split-handle-size`, `--split-handle-bg`.
28
+ */
29
+ export declare function SplitPane({ direction, ratio, onRatioChange, minFirst, minSecond, first, second, className, ...rest }: SplitPaneProps): React.JSX.Element;
@@ -0,0 +1,5 @@
1
+ import { S as t, c as i } from "./SplitPane-DR7PCZ8f.js";
2
+ export {
3
+ t as SplitPane,
4
+ i as clampSplitRatio
5
+ };
@@ -0,0 +1,25 @@
1
+ import e from "react";
2
+ import { c as n } from "./cx-CcykAxZN.js";
3
+ import './Table.css';const r = "cDw", f = "cDt", m = "cDf", t = {
4
+ w: r,
5
+ t: f,
6
+ f: m
7
+ };
8
+ function w({
9
+ layout: c = "auto",
10
+ className: a,
11
+ children: o,
12
+ ...s
13
+ }) {
14
+ return /* @__PURE__ */ e.createElement("div", { className: t.w }, /* @__PURE__ */ e.createElement(
15
+ "table",
16
+ {
17
+ className: n(t.t, c === "fixed" && t.f, a),
18
+ ...s
19
+ },
20
+ o
21
+ ));
22
+ }
23
+ export {
24
+ w as T
25
+ };
package/dist/Table.css ADDED
@@ -0,0 +1 @@
1
+ @layer elcrm-components{.cDw{overflow:auto}.cDt{width:100%;border-collapse:collapse;font-size:var(--table-font-size);color:var(--shell-color)}.cDf{table-layout:fixed}.cDt th,.cDt td{padding:var(--table-cell-padding);border-bottom:1px solid var(--shell-border);text-align:left;vertical-align:top}.cDt th{color:var(--shell-color-muted);font-weight:var(--shell-font-weight);font-size:var(--table-head-font-size);text-transform:uppercase;letter-spacing:.04em}.cDt code{font-size:var(--table-code-font-size)}}
@@ -0,0 +1,29 @@
1
+ import { default as React } from 'react';
2
+ export type TableProps = React.TableHTMLAttributes<HTMLTableElement> & {
3
+ /** `fixed` — равномерные колонки, ширины через col/colgroup в children. */
4
+ layout?: "auto" | "fixed";
5
+ };
6
+ /**
7
+ * Таблица данных: обёртка со скроллом + стили shell.
8
+ *
9
+ * @example
10
+ * ```tsx
11
+ * <Table>
12
+ * <thead>
13
+ * <tr>
14
+ * <th>Имя</th>
15
+ * <th>Тип</th>
16
+ * </tr>
17
+ * </thead>
18
+ * <tbody>
19
+ * <tr>
20
+ * <td><code>label</code></td>
21
+ * <td>string</td>
22
+ * </tr>
23
+ * </tbody>
24
+ * </Table>
25
+ * ```
26
+ *
27
+ * Токены: `--table-*`, `--shell-border`, `--shell-color`.
28
+ */
29
+ export declare function Table({ layout, className, children, ...rest }: TableProps): React.JSX.Element;
package/dist/Table.js ADDED
@@ -0,0 +1,4 @@
1
+ import { T as o } from "./Table-BoDr3X2d.js";
2
+ export {
3
+ o as Table
4
+ };
package/dist/index.css CHANGED
@@ -8,6 +8,8 @@
8
8
 
9
9
  @layer elcrm-components{.cjr{display:inline-flex;align-items:center;justify-content:center;gap:.25rem;padding:.2rem .5rem;border-radius:999px;border:0;font-size:var(--shell-font-size-sm);font-weight:600;line-height:1;white-space:nowrap}.cjs{padding:2px var(--shell-gap-sm);font-size:var(--shell-font-size-sm);letter-spacing:.04em}.cjm{padding:.2rem .5rem;font-size:var(--shell-font-size-sm)}.cjl{padding:.3rem .65rem;font-size:var(--shell-font-size)}.cjn{background:var(--shell-background-hover);color:var(--shell-color)}.cja{background:color-mix(in srgb,var(--shell-color-accent) 16%,transparent);color:var(--shell-color-accent)}.cju{background:color-mix(in srgb,var(--shell-color-success) 16%,transparent);color:var(--shell-color-success)}.cjw{background:color-mix(in srgb,var(--shell-color-warning) 16%,transparent);color:var(--shell-color-warning)}.cjd{background:color-mix(in srgb,var(--shell-color-danger) 16%,transparent);color:var(--shell-color-danger)}.cjo{flex-shrink:0;width:.45em;height:.45em;border-radius:50%;background:currentColor}}
10
10
 
11
+ @layer elcrm-components{.cLr{margin:0;padding:var(--banner-padding);border:1px solid var(--banner-border);border-radius:var(--shell-radius);background:var(--banner-bg);font-size:var(--shell-font-size-sm);color:var(--shell-color);line-height:1.45}.cLi{--banner-bg: color-mix(in srgb, var(--shell-color-accent) 8%, var(--shell-bg));--banner-border: color-mix(in srgb, var(--shell-color-accent) 35%, var(--shell-border))}.cLw{--banner-bg: color-mix(in srgb, var(--shell-color-warning) 10%, var(--shell-bg));--banner-border: color-mix(in srgb, var(--shell-color-warning) 40%, var(--shell-border))}.cLd{--banner-bg: color-mix(in srgb, var(--shell-color-danger) 10%, var(--shell-bg));--banner-border: color-mix(in srgb, var(--shell-color-danger) 40%, var(--shell-border))}.cLs{--banner-bg: color-mix(in srgb, var(--shell-color-success) 10%, var(--shell-bg));--banner-border: color-mix(in srgb, var(--shell-color-success) 40%, var(--shell-border))}.cLr code{font-size:.92em}}
12
+
11
13
  @layer elcrm-components{.cnr{-webkit-appearance:none;-moz-appearance:none;appearance:none;margin:0;padding:0;border:0;background:transparent;font:inherit;font-weight:700;letter-spacing:.02em;color:var(--shell-color);white-space:nowrap;cursor:pointer;text-decoration:none}.cnr:hover{color:var(--shell-color-accent)}}
12
14
 
13
15
  @layer elcrm-components{.c0r{display:flex;flex-wrap:wrap;align-items:center;gap:var(--shell-gap-sm);list-style:none;margin:0;padding:0;font-size:var(--shell-font-size-sm);font-weight:var(--shell-font-weight);color:var(--shell-color-muted);line-height:1.3}.c0i{display:inline-flex;align-items:center;gap:var(--shell-gap-sm);min-width:0;color:inherit}.c0i:is(a,button){-webkit-appearance:none;-moz-appearance:none;appearance:none;margin:0;padding:0;border:none;background:transparent;font:inherit;font-weight:inherit;color:inherit;cursor:pointer;text-decoration:none}.c0i:is(a,button):hover{color:var(--shell-color)}.c0c,.c0i[aria-current=page]{color:var(--shell-color-accent);cursor:default}.c0n{display:inline-flex;flex-shrink:0;align-items:center;justify-content:center;width:var(--shell-icon-size);height:var(--shell-icon-size);overflow:hidden;border-radius:calc(var(--shell-radius) * .5);color:inherit}.c0n img{width:100%;height:100%;object-fit:cover;display:block}.c0l{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.c0d{display:inline-flex;flex-shrink:0;width:.75rem;height:.75rem;color:var(--shell-color-muted)}.c0s{display:inline-flex;flex-shrink:0;align-items:center;justify-content:center;color:var(--shell-color-muted);-webkit-user-select:none;user-select:none}.c0v{width:.75rem;height:.75rem;display:block}.c0e{display:inline-flex;align-items:center;justify-content:center;min-width:1em;color:var(--shell-color-muted);letter-spacing:.05em}.c0e:is(button){-webkit-appearance:none;-moz-appearance:none;appearance:none;margin:0;padding:.15rem .35rem;border:none;border-radius:calc(var(--shell-radius) * .4);background:transparent;font:inherit;color:inherit;cursor:pointer}.c0e:is(button):hover{background:var(--shell-background-hover);color:var(--shell-color)}}
@@ -16,6 +18,8 @@
16
18
 
17
19
  @layer elcrm-components{.c8r{display:flex;flex-direction:column;box-sizing:border-box;min-width:0;min-height:0;height:100%;overflow:hidden;background:var(--chat-background);border:var(--chat-border);border-radius:var(--chat-radius)}.c8l{width:var(--chat-list-width);max-width:100%}.c8g{width:100%}.c8h{flex:0 0 auto;padding:var(--chat-header-padding);border-bottom:var(--chat-border)}.c8b{flex:1 1 auto;min-height:0;overflow:auto;padding:var(--chat-body-padding)}.c8g .c8h{padding:var(--chat-messages-header-padding)}.c8g .c8b{display:flex;flex-direction:column;padding:var(--chat-messages-body-padding)}.c8f{flex:0 0 auto;padding:var(--chat-footer-padding);border-top:var(--chat-border)}.c8g .c8f{padding:var(--chat-messages-footer-padding)}.c8p{display:flex;align-items:stretch;gap:var(--chat-split-gap);min-height:0;height:100%}.c8p>*{min-height:0}}
18
20
 
21
+ @layer elcrm-components{.cEr{border:1px solid var(--shell-border);border-radius:var(--shell-radius);background:var(--code-block-bg);overflow:hidden}.cEb{display:flex;justify-content:space-between;align-items:center;gap:var(--shell-gap-sm);padding:var(--code-block-bar-padding);border-bottom:1px solid var(--shell-border);font-size:var(--shell-font-size-sm);color:var(--shell-color-muted)}.cEp{margin:0;padding:var(--code-block-padding);overflow:auto;font-family:var(--code-block-font-family);font-size:var(--code-block-font-size);line-height:var(--code-block-line-height);color:var(--shell-color);white-space:pre}.cEa{display:inline-flex;align-items:center;gap:.35rem;flex-shrink:0}.cEc{border:0;background:transparent;color:var(--shell-color-accent);cursor:pointer;font:inherit;padding:0}.cEc:hover,.cEc:focus-visible{text-decoration:underline}}
22
+
19
23
  @layer elcrm-components{.crr{position:relative;display:inline-flex;vertical-align:middle}.crt{display:inline-flex;align-items:center;gap:var(--shell-gap-sm);margin:0;padding:var(--shell-padding);box-sizing:border-box;font:inherit;font-size:var(--shell-font-size);font-weight:var(--shell-font-weight);color:var(--shell-color);background:var(--shell-background);border:1px solid var(--shell-border);border-radius:var(--shell-radius);cursor:pointer;-webkit-appearance:none;-moz-appearance:none;appearance:none;line-height:1.2}.crt[data-size]{height:var(--control-height);min-height:var(--control-height);padding-block:0;box-sizing:border-box}.crt:hover{background:var(--shell-background-hover)}.crt[data-open=true]{border-color:var(--shell-color-accent);color:var(--shell-color-accent)}.crc{display:inline-flex;width:var(--shell-icon-size);height:var(--shell-icon-size);flex-shrink:0;color:var(--shell-color-muted)}.crt[data-open=true] .crc{color:var(--shell-color-accent)}.crp{min-width:0}.crh{margin:0;padding:var(--shell-padding);font-size:var(--shell-font-size-sm);font-weight:var(--shell-font-weight);color:var(--shell-color-muted);line-height:1.3}.crg{display:flex;flex-direction:column;gap:2px}.crd{height:0;margin:var(--shell-gap-sm) 0;border:0;border-top:1px solid var(--shell-border)}.cri{display:flex;align-items:center;gap:var(--shell-gap-sm);width:100%;margin:0;padding:var(--shell-padding);box-sizing:border-box;text-align:left;font:inherit;font-size:var(--shell-font-size);font-weight:500;color:var(--shell-color);background:transparent;border:none;border-radius:calc(var(--shell-radius) * .7);cursor:pointer;-webkit-appearance:none;-moz-appearance:none;appearance:none;line-height:1.35}.cri:hover:not(:disabled),.cri:focus-visible:not(:disabled){background:var(--shell-background-hover);outline:none}.cri[data-checked=true]{background:var(--shell-background-selected)}.cri[data-danger=true]{color:var(--shell-color-danger)}.cri[data-danger=true] .crn,.cri[data-danger=true] .crm{color:inherit}.cri:disabled,.cri[aria-disabled=true]{opacity:var(--shell-disabled-opacity);cursor:not-allowed}.crn,.crk{display:inline-flex;flex-shrink:0;align-items:center;justify-content:center;width:var(--shell-icon-size);height:var(--shell-icon-size);color:var(--shell-color-muted)}.crk{color:var(--shell-color-accent)}.crl{flex:1;min-width:0}.cru{flex-shrink:0;margin-left:auto;font-size:var(--shell-font-size-sm);color:var(--shell-color-muted)}.crm{display:inline-flex;flex-shrink:0;margin-left:auto;width:var(--shell-icon-size);height:var(--shell-icon-size);color:var(--shell-color-muted)}.crb{display:inline-flex;flex-shrink:0;width:var(--shell-status-size);height:var(--shell-status-size);border-radius:50%}.cro{background:var(--shell-color-success)}.crf{background:var(--shell-color-muted)}.crx{display:inline-flex;flex-shrink:0;align-items:center;justify-content:center;box-sizing:border-box;width:var(--shell-check-size);height:var(--shell-check-size);border:1px solid var(--shell-border);border-radius:calc(var(--shell-radius) * .4);background:var(--shell-background);color:var(--avatar-color)}.cry{border-color:var(--shell-color-accent);background:var(--shell-color-accent)}.crv{width:70%;height:70%;display:block}}
20
24
 
21
25
  @layer elcrm-components{.cpr{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:var(--shell-gap);padding:var(--shell-padding);text-align:center;color:var(--shell-color-muted)}.cpi{display:flex;margin-bottom:var(--shell-gap-sm);color:var(--shell-color-muted)}.cpt{margin:0;font-size:var(--shell-font-size-lg);font-weight:var(--shell-font-weight);color:var(--shell-color);line-height:1.3}.cpd{margin:0;max-width:22rem;font-size:var(--shell-font-size);color:var(--shell-color-muted);line-height:1.45}.cpa{display:flex;flex-wrap:wrap;gap:var(--shell-gap-sm);justify-content:center;margin-top:var(--shell-gap)}}
@@ -38,7 +42,7 @@
38
42
 
39
43
  @layer elcrm-components{.cmr{display:flex;align-items:center;gap:var(--shell-gap-sm);margin:0;padding:0;list-style:none}.cmv{flex-direction:column;align-items:stretch}.cmi{-webkit-appearance:none;-moz-appearance:none;appearance:none;display:inline-flex;align-items:center;justify-content:center;border:0;background:transparent;color:var(--button-color-muted);padding:var(--button-padding);border-radius:var(--button-radius);font:inherit;line-height:1;cursor:pointer;text-align:left;gap:var(--shell-gap-sm)}.cmd{flex-shrink:0;min-width:16px;height:16px;padding:0 4px;font-size:10px}.cmi>svg{display:block;flex-shrink:0}.cmi:hover{background:var(--button-background-hover);color:var(--button-color)}.cma,.cmi[aria-current=page],.cmi[data-active=true]{background:var(--button-background-selected);color:var(--button-color)}.cmu{width:100%;align-items:stretch;gap:1.25rem;padding:0;border-bottom:1px solid var(--shell-border)}.cmu .cmi{border-radius:0;background:transparent;padding:.45rem .1rem .55rem;border-bottom:2px solid transparent;margin-bottom:-1px}.cmu .cmi:hover{background:transparent;color:var(--shell-color)}.cmu .cma,.cmu .cmi[aria-current=page],.cmu .cmi[data-active=true]{background:transparent;color:var(--shell-color);border-bottom-color:var(--shell-color-accent)}}
40
44
 
41
- @layer elcrm-components{.cvr{display:flex;align-items:stretch;gap:var(--shell-gap-lg);width:100%;flex:1 1 auto;min-height:0;box-sizing:border-box;padding:var(--nav-sections-padding)}.cvn{display:flex;flex-direction:column;gap:var(--shell-gap);flex:0 0 var(--nav-sections-nav-width);width:var(--nav-sections-nav-width);min-width:var(--nav-sections-nav-width);box-sizing:border-box}.cvg{display:flex;flex-direction:column;gap:2px;padding-bottom:var(--shell-gap);border-bottom:1px solid var(--shell-border)}.cvg:last-of-type{border-bottom:none;padding-bottom:0}.cvl{font-size:var(--sidebar-group-font-size);font-weight:var(--shell-font-weight);letter-spacing:.04em;text-transform:uppercase;color:var(--shell-color-muted);padding:0 var(--shell-padding-inline) var(--shell-gap-sm)}.cvi:is(button){position:relative;font-size:var(--shell-font-size-sm)}.cva:before{content:"";position:absolute;left:0;top:6px;bottom:6px;width:3px;border-radius:0 2px 2px 0;background:var(--shell-color-accent)}.cvi:disabled{opacity:var(--shell-disabled-opacity);cursor:not-allowed}.cvc{display:inline-flex;flex:0 0 auto;color:var(--shell-color-muted);line-height:0}.cva .cvc{color:var(--shell-color)}.cvt{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.cvf{margin-top:auto;padding-top:var(--shell-gap);border-top:1px solid var(--shell-border)}.cvm{flex:1 1 auto;min-width:0;max-width:var(--nav-sections-main-max-width);width:100%;min-height:0;overflow:auto}@media (max-width: 720px){.cvr{flex-direction:column}.cvn{flex:none;width:100%;min-width:0;max-width:none}}}
45
+ @layer elcrm-components{.cvr{display:flex;align-items:stretch;gap:var(--shell-gap-lg);width:100%;flex:1 1 auto;min-height:0;box-sizing:border-box;padding:var(--nav-sections-padding)}.cvn{display:flex;flex-direction:column;gap:var(--shell-gap);flex:0 0 var(--nav-sections-nav-width);width:var(--nav-sections-nav-width);min-width:var(--nav-sections-nav-width);box-sizing:border-box}.cvg{display:flex;flex-direction:column;gap:2px;padding-bottom:var(--shell-gap);border-bottom:1px solid var(--shell-border)}.cvg:last-of-type{border-bottom:none;padding-bottom:0}.cvl{font-size:var(--sidebar-group-font-size);font-weight:var(--shell-font-weight);letter-spacing:.04em;text-transform:uppercase;color:var(--shell-color-muted);padding:0 var(--shell-padding-inline) var(--shell-gap-sm)}.cvi:is(button){position:relative;display:flex;width:100%;align-items:center;font-size:var(--shell-font-size-sm)}.cva:before{content:"";position:absolute;left:0;top:6px;bottom:6px;width:3px;border-radius:0 2px 2px 0;background:var(--shell-color-accent)}.cvi:disabled{opacity:var(--shell-disabled-opacity);cursor:not-allowed}.cvc{display:inline-flex;flex:0 0 auto;color:var(--shell-color-muted);line-height:0}.cva .cvc{color:var(--shell-color)}.cvt{flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.cve{flex-shrink:0;width:12px;height:12px;margin-left:auto;color:var(--shell-color-muted);transition:transform .15s ease}.cvi:is(button)[data-open=true] .cve{transform:rotate(180deg);color:inherit}.cvs{display:flex;flex-direction:column;gap:2px;padding-inline-start:var(--sidebar-indent)}.cvf{margin-top:auto;padding-top:var(--shell-gap);border-top:1px solid var(--shell-border)}.cvm{flex:1 1 auto;min-width:0;max-width:var(--nav-sections-main-max-width);width:100%;min-height:0;overflow:auto}@media (max-width: 720px){.cvr{flex-direction:column}.cvn{flex:none;width:100%;min-width:0;max-width:none}}}
42
46
 
43
47
  @layer elcrm-components{.ccr{display:flex;flex-direction:column;gap:var(--shell-gap);margin:0 0 var(--shell-gap)}.cck{position:sticky;top:0;z-index:var(--shell-z);background:var(--shell-bg)}.ccw{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:var(--shell-gap-sm)}.cct{min-width:0;max-width:36rem}.cch{margin:0;display:flex;align-items:flex-start;gap:.4em;font-size:var(--section-title-size);font-weight:var(--shell-font-weight);color:var(--shell-color);line-height:1.15}.ccn{min-width:0}.ccu{display:inline-flex;align-items:center;margin-top:.12em;font-size:.7rem;font-weight:600;line-height:1;color:var(--shell-color-muted)}.ccs{margin:var(--shell-gap-sm) 0 0;font-size:var(--shell-font-size);color:var(--shell-color-muted);line-height:1.45}.cca{display:flex;flex-wrap:wrap;align-items:center;gap:var(--shell-gap-sm)}.ccc{display:flex;flex-direction:column;gap:var(--shell-gap);min-width:0}}
44
48
 
@@ -56,7 +60,9 @@
56
60
 
57
61
  @layer elcrm-components{.cep{display:flex;flex-direction:column;gap:var(--shell-gap);padding:var(--section-padding);flex:1;min-width:0}.ceu{box-sizing:border-box;min-height:100svh;display:flex;align-items:center;justify-content:center;padding:var(--section-padding)}.cek{box-sizing:border-box;width:100%;max-width:var(--section-auth-card-max-width);padding:var(--shell-gap-lg);background:var(--shell-background);border:1px solid var(--shell-border);border-radius:var(--shell-radius);box-shadow:var(--shell-shadow);display:flex;flex-direction:column;gap:var(--shell-gap)}.ceh{display:flex;flex-direction:column;gap:var(--shell-gap-sm)}.cec{text-align:center;align-items:center}.cei{display:flex;margin-bottom:var(--shell-gap-sm)}.cec .cei{justify-content:center}.cet{margin:0;font-size:var(--section-title-size);font-weight:var(--shell-font-weight);letter-spacing:-.02em;color:var(--shell-color);line-height:1.25}.ced{font-size:var(--section-title-size-md)}.cee{margin:0;font-size:var(--shell-font-size);color:var(--shell-color-muted);line-height:1.45}.ceb{display:flex;flex-direction:column;gap:var(--shell-gap);width:100%;text-align:left}.ces{display:flex;flex-direction:column;gap:var(--shell-gap-sm);width:100%}.cel{display:flex;flex-direction:column;gap:var(--shell-gap);margin-bottom:var(--shell-gap-lg);padding-bottom:var(--shell-gap-lg);border-bottom:1px solid var(--shell-border)}.cel:last-of-type{margin-bottom:0;padding-bottom:0;border-bottom:none}.cel .cet{font-size:var(--shell-font-size);font-weight:var(--shell-font-weight)}}
58
62
 
59
- @layer elcrm-components{.c2r{box-sizing:border-box;display:flex;flex-direction:column;flex:1 1 auto;width:var(--sidebar-width, 248px);min-width:0;min-height:0;height:100%;max-height:100%;padding:var(--sidebar-pad-y, 16px) var(--sidebar-pad-x, 12px);gap:var(--shell-gap-sm, 8px);color:var(--shell-color);align-self:stretch}.c2b{display:flex;flex-direction:row;align-items:center;gap:var(--shell-gap);padding:4px 8px;min-width:0}.c2x{flex-shrink:0;margin-left:auto}.c2g{flex:1;min-height:0;display:flex;flex-direction:column;gap:var(--shell-gap-sm);overflow-y:auto;overflow-x:hidden;scrollbar-width:thin}.c2s{box-sizing:border-box;flex-shrink:0;padding:8px}.c2p{--sidebar-plain: 1}.c2r:not(.c2p) .c2s{background:var(--sidebar-block-bg);border:1px solid var(--sidebar-block-border);border-radius:var(--sidebar-block-radius);box-shadow:var(--sidebar-block-shadow)}.c2h{margin:2px 10px 6px;font-size:var(--sidebar-group-font-size);font-weight:600;letter-spacing:.08em;text-transform:uppercase;color:var(--shell-color-muted)}.c2n{margin:0;padding:0;list-style:none}.c2n>li{list-style:none}.c2n .c2i:is(button){position:relative;display:flex;width:100%;box-sizing:border-box;flex-direction:row;align-items:center;gap:8px;margin:0 0 1px;padding:var(--sidebar-item-padding);border:0;border-radius:8px;background:transparent;color:var(--shell-color-muted);font-family:inherit;font-size:var(--sidebar-item-font-size);font-weight:500;line-height:1.25;letter-spacing:0;text-align:left;cursor:pointer}.c2n .c2i:is(button):hover{color:var(--shell-color);background:var(--shell-background-hover)}.c2n .c2i:is(button).c2a,.c2n .c2i:is(button)[aria-current=page],.c2n .c2i:is(button)[data-active=true],.c2n .c2i:is(button).c2a:hover{color:var(--sidebar-item-active);background:var(--sidebar-item-active-bg)}.c2o{display:inline-flex;flex-shrink:0;align-items:center;justify-content:center;width:var(--sidebar-icon-size);height:var(--sidebar-icon-size);color:inherit}.c2o :is(svg){display:block;width:var(--sidebar-icon-size);height:var(--sidebar-icon-size)}.c2a .c2o{color:var(--sidebar-icon-active)}.c2l{flex:1;min-width:0}.c2d{flex-shrink:0;min-width:16px;height:16px;padding:0 4px;font-size:10px}.c2f{margin-top:auto}.c2q{display:flex;width:100%;min-width:0;flex:0 0 auto;height:auto;align-items:center}.c2q>*{display:flex;width:100%;min-width:0;height:auto;align-items:center}.c2w{display:flex;width:100%;min-width:0;align-items:center}.c2u{display:flex;align-items:center;width:100%;min-width:0;gap:var(--shell-gap-sm);margin:0;padding:0;border:none;background:transparent;font:inherit;color:inherit;cursor:pointer;text-align:left}.c2k{flex-shrink:0;width:var(--sidebar-icon-size);height:var(--sidebar-icon-size);color:var(--shell-color-muted)}.c2v{margin-top:var(--shell-gap-sm);font-size:11px;color:var(--shell-color-muted);text-align:center}@media (max-width: 900px){.c2r{width:72px;padding:12px 8px}.c2l,.c2h,.c2v{display:none}.c2b{flex-direction:column;justify-content:center;align-items:center;gap:8px;padding:4px 0}.c2x{margin-left:0}.c2s{padding:6px}.c2n .c2i{justify-content:center;align-items:center;gap:0;width:100%;min-height:40px;padding:10px 0}.c2n .c2d{position:absolute;top:4px;right:4px;min-width:14px;height:14px;padding:0 4px;font-size:.625rem;line-height:14px;pointer-events:none}}}
63
+ @layer elcrm-components{.c2r{box-sizing:border-box;display:flex;flex-direction:column;flex:1 1 auto;width:var(--sidebar-width, 248px);min-width:0;min-height:0;height:100%;max-height:100%;padding:var(--sidebar-pad-y, 16px) var(--sidebar-pad-x, 12px);gap:var(--shell-gap-sm, 8px);color:var(--shell-color);align-self:stretch}.c2b{display:flex;flex-direction:row;align-items:center;gap:var(--shell-gap);padding:4px 8px;min-width:0}.c2x{flex-shrink:0;margin-left:auto}.c2g{flex:1;min-height:0;display:flex;flex-direction:column;gap:var(--shell-gap-sm);overflow-y:auto;overflow-x:hidden;scrollbar-width:thin}.c2s{box-sizing:border-box;flex-shrink:0;padding:8px}.c2p{--sidebar-plain: 1}.c2r:not(.c2p) .c2s{background:var(--sidebar-block-bg);border:1px solid var(--sidebar-block-border);border-radius:var(--sidebar-block-radius);box-shadow:var(--sidebar-block-shadow)}.c2h{margin:2px 10px 6px;font-size:var(--sidebar-group-font-size);font-weight:600;letter-spacing:.08em;text-transform:uppercase;color:var(--shell-color-muted)}.c2n{margin:0;padding:0;list-style:none}.c2n>li{list-style:none}.c2n .c2i:is(button){position:relative;display:flex;width:100%;box-sizing:border-box;flex-direction:row;align-items:center;gap:8px;margin:0 0 1px;padding:var(--sidebar-item-padding);border:0;border-radius:8px;background:transparent;color:var(--shell-color-muted);font-family:inherit;font-size:var(--sidebar-item-font-size);font-weight:500;line-height:1.25;letter-spacing:0;text-align:left;cursor:pointer}.c2n .c2i:is(button):hover{color:var(--shell-color);background:var(--shell-background-hover)}.c2n .c2i:is(button).c2a,.c2n .c2i:is(button)[aria-current=page],.c2n .c2i:is(button)[data-active=true],.c2n .c2i:is(button).c2a:hover{color:var(--sidebar-item-active);background:var(--sidebar-item-active-bg)}.c2o{display:inline-flex;flex-shrink:0;align-items:center;justify-content:center;width:var(--sidebar-icon-size);height:var(--sidebar-icon-size);color:inherit}.c2o :is(svg){display:block;width:var(--sidebar-icon-size);height:var(--sidebar-icon-size)}.c2a .c2o{color:var(--sidebar-icon-active)}.c2l{flex:1;min-width:0}.c2d{flex-shrink:0;min-width:16px;height:16px;padding:0 4px;font-size:10px}.c2c{flex-shrink:0;width:12px;height:12px;margin-left:auto;color:var(--shell-color-muted);transition:transform .15s ease}.c2n .c2i:is(button)[data-open=true] .c2c{transform:rotate(180deg);color:inherit}.c2m{margin:0;padding:0 0 0 var(--sidebar-indent);list-style:none}.c2m>li{list-style:none}.c2f{margin-top:auto}.c2q{display:flex;width:100%;min-width:0;flex:0 0 auto;height:auto;align-items:center}.c2q>*{display:flex;width:100%;min-width:0;height:auto;align-items:center}.c2w{display:flex;width:100%;min-width:0;align-items:center}.c2u{display:flex;align-items:center;width:100%;min-width:0;gap:var(--shell-gap-sm);margin:0;padding:0;border:none;background:transparent;font:inherit;color:inherit;cursor:pointer;text-align:left}.c2k{flex-shrink:0;width:var(--sidebar-icon-size);height:var(--sidebar-icon-size);color:var(--shell-color-muted)}.c2v{margin-top:var(--shell-gap-sm);font-size:11px;color:var(--shell-color-muted);text-align:center}@media (max-width: 900px){.c2r{width:72px;padding:12px 8px}.c2l,.c2h,.c2v,.c2c,.c2m{display:none}.c2b{flex-direction:column;justify-content:center;align-items:center;gap:8px;padding:4px 0}.c2x{margin-left:0}.c2s{padding:6px}.c2n .c2i{justify-content:center;align-items:center;gap:0;width:100%;min-height:40px;padding:10px 0}.c2n .c2d{position:absolute;top:4px;right:4px;min-width:14px;height:14px;padding:0 4px;font-size:.625rem;line-height:14px;pointer-events:none}}}
64
+
65
+ @layer elcrm-components{.cFr{display:flex;min-height:0;min-width:0}.cFx{flex-direction:row}.cFy{flex-direction:column}.cFp{min-width:0;min-height:0;overflow:auto}.cFh{flex:0 0 var(--split-handle-size);margin:0;padding:0;border:0;background:var(--split-handle-bg);cursor:col-resize;touch-action:none}.cFy .cFh{cursor:row-resize}.cFh:hover,.cFh:focus-visible{background:var(--split-handle-bg-hover)}}
60
66
 
61
67
  @layer elcrm-components{.c1r{box-sizing:border-box;min-width:0;gap:var(--shell-gap)}.c1c,.c1g{width:100%}.c1c{display:flex;flex-direction:column}.c1h{display:flex;flex-direction:row;flex-wrap:wrap;align-items:center;width:auto;max-width:100%}.c1g{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,var(--stack-grid-min)),1fr))}.c1n{display:grid;width:100%;align-items:stretch;grid-template-columns:var(--stack-columns-template)}}
62
68
 
@@ -64,6 +70,8 @@
64
70
 
65
71
  @layer elcrm-components{.ctr{display:flex;flex-direction:column;gap:var(--shell-gap);width:100%;min-width:0}.ctb{display:flex;align-items:flex-end;gap:var(--shell-gap);border-bottom:1px solid var(--shell-border);min-width:0}.ctn{display:flex;align-items:stretch;gap:var(--shell-gap-lg);flex:1 1 auto;min-width:0;overflow-x:auto;scrollbar-width:thin}.ctt{-webkit-appearance:none;-moz-appearance:none;appearance:none;display:inline-flex;align-items:center;gap:var(--shell-gap-sm);flex:0 0 auto;margin:0 0 -1px;padding:var(--shell-padding-block) .15rem;border:none;border-bottom:2px solid transparent;background:transparent;color:var(--shell-color-muted);font:inherit;font-size:var(--shell-font-size);font-weight:500;white-space:nowrap;cursor:pointer}.ctt:hover:not(:disabled){color:var(--shell-color)}.cta{color:var(--shell-color);border-bottom-color:var(--shell-color-accent)}.ctt:disabled{opacity:var(--shell-disabled-opacity);cursor:not-allowed}.cte{display:inline-flex;align-items:center;justify-content:center;min-width:1.15em;height:1.15em;padding:0 .35em;border-radius:999px;background:var(--shell-color-danger);color:var(--avatar-color);font-size:var(--sidebar-group-font-size);font-style:normal;font-weight:700;line-height:1}.cts{flex:0 0 auto;display:flex;align-items:center;padding-bottom:var(--shell-gap-sm)}.ctm{min-width:0;width:100%}}
66
72
 
73
+ @layer elcrm-components{.cDw{overflow:auto}.cDt{width:100%;border-collapse:collapse;font-size:var(--table-font-size);color:var(--shell-color)}.cDf{table-layout:fixed}.cDt th,.cDt td{padding:var(--table-cell-padding);border-bottom:1px solid var(--shell-border);text-align:left;vertical-align:top}.cDt th{color:var(--shell-color-muted);font-weight:var(--shell-font-weight);font-size:var(--table-head-font-size);text-transform:uppercase;letter-spacing:.04em}.cDt code{font-size:var(--table-code-font-size)}}
74
+
67
75
  @layer elcrm-components{.c6r{display:flex;flex-direction:column;gap:2px;min-width:0;text-align:left}.c6t{margin:0;font-size:var(--shell-font-size);font-weight:var(--shell-font-weight);color:var(--shell-color);line-height:1.3;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.c6d{margin:0;font-size:var(--shell-font-size-sm);font-weight:400;color:var(--shell-color-muted);line-height:1.35;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.c6s .c6t{font-size:var(--shell-font-size-sm)}.c6l .c6t{font-size:var(--shell-font-size-lg)}.c6l .c6d{font-size:var(--shell-font-size)}}
68
76
 
69
77
  @layer elcrm-components{.cCr{display:flex;flex-wrap:wrap;align-items:center;gap:var(--toolbar-gap);width:100%;min-width:0;box-sizing:border-box;--field-width: auto}.cCr>[data-field]{flex:0 1 auto;width:auto;min-width:0;max-width:100%}.cCr>[data-field=search]{flex:1 1 var(--field-search-min-width, 10rem);width:auto!important;max-width:none}.cCr[data-width=s]{display:inline-flex;width:auto;max-width:100%}.cCr[data-align=center]{justify-content:center}.cCr[data-align=end]{justify-content:flex-end}.cCr[data-align=between]{justify-content:space-between}.cCr[data-size=s]{--control-height: var(--control-height-s);--field-height: var(--control-height-s);--control-font-size: 13px;--button-height: var(--button-height-s);--button-height-m: var(--button-height-s);--button-padding: var(--button-padding-s);--button-size-m: var(--button-size-s)}.cCr[data-size=l]{--control-height: var(--control-height-l);--field-height: var(--control-height-l);--button-height: var(--button-height-l);--button-height-m: var(--button-height-l);--button-size-m: var(--button-size-l)}}
package/dist/index.d.ts CHANGED
@@ -81,6 +81,16 @@ export { Healthmap } from './Healthmap';
81
81
  export type { HealthmapProps, HealthmapData, HealthmapDay, HealthmapUnit, } from './Healthmap';
82
82
  export { PanelInfo } from './PanelInfo';
83
83
  export type { PanelInfoProps } from './PanelInfo';
84
+ export { Table } from './Table';
85
+ export type { TableProps } from './Table';
86
+ export { CodeBlock } from './CodeBlock';
87
+ export type { CodeBlockProps } from './CodeBlock';
88
+ export { SplitPane, clampSplitRatio } from './SplitPane';
89
+ export type { SplitPaneProps, SplitPaneDirection } from './SplitPane';
90
+ export { Banner } from './Banner';
91
+ export type { BannerProps, BannerTone } from './Banner';
92
+ export { IconButton } from './IconButton';
93
+ export type { IconButtonProps } from './IconButton';
84
94
  export { acquireOverlayZIndex, releaseOverlayZIndex, peekOverlayZIndex, } from './overlayZ';
85
95
  export { createLazyResolver } from './lazyRoute';
86
96
  export type { LazyRouteChunk } from './lazyRoute';
@@ -81,6 +81,16 @@ export { Healthmap } from './Healthmap';
81
81
  export type { HealthmapProps, HealthmapData, HealthmapDay, HealthmapUnit, } from './Healthmap';
82
82
  export { PanelInfo } from './PanelInfo';
83
83
  export type { PanelInfoProps } from './PanelInfo';
84
+ export { Table } from './Table';
85
+ export type { TableProps } from './Table';
86
+ export { CodeBlock } from './CodeBlock';
87
+ export type { CodeBlockProps } from './CodeBlock';
88
+ export { SplitPane, clampSplitRatio } from './SplitPane';
89
+ export type { SplitPaneProps, SplitPaneDirection } from './SplitPane';
90
+ export { Banner } from './Banner';
91
+ export type { BannerProps, BannerTone } from './Banner';
92
+ export { IconButton } from './IconButton';
93
+ export type { IconButtonProps } from './IconButton';
84
94
  export { acquireOverlayZIndex, releaseOverlayZIndex, peekOverlayZIndex, } from './overlayZ';
85
95
  export { createLazyResolver } from './lazyRoute';
86
96
  export type { LazyRouteChunk } from './lazyRoute';