@stackone/malachite 2.27.2 → 2.29.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/COMPONENTS.md +2 -0
- package/dist/components/CommandPalette.js +150 -0
- package/dist/components/CommandPalette.js.map +1 -0
- package/dist/components/Keycap.js +38 -0
- package/dist/components/Keycap.js.map +1 -0
- package/dist/components/SidePanelNavFooter.js +21 -37
- package/dist/components/SidePanelNavFooter.js.map +1 -1
- package/dist/components/Surface.js +130 -133
- package/dist/components/Surface.js.map +1 -1
- package/dist/components/asChild.js +13 -0
- package/dist/components/asChild.js.map +1 -0
- package/dist/components/overlayBehaviour.js +82 -73
- package/dist/components/overlayBehaviour.js.map +1 -1
- package/dist/components/portalOverlay.js +12 -11
- package/dist/components/portalOverlay.js.map +1 -1
- package/dist/index.d.ts +132 -18
- package/dist/index.js +333 -329
- package/dist/index.js.map +1 -1
- package/dist/tailwind.css.js +1 -1
- package/package.json +1 -1
package/COMPONENTS.md
CHANGED
|
@@ -60,6 +60,8 @@ The catalog of components exported from `@stackone/malachite`. **Reach for one o
|
|
|
60
60
|
- **`FooterNav`** — Footer navigation bar of links. _Key props:_ `FooterNavLink[]`.
|
|
61
61
|
- **`FooterLinks`** — Inline list of footer links (e.g. terms, privacy, support).
|
|
62
62
|
- **`StepTabs`** — Header for a short, ordered flow — a two-step drawer or wizard panel. Each step is a button carrying `aria-current="step"`, not a tab: the body beneath is the step’s form, so it keeps the normal tab order instead of adopting a `tablist`’s arrow-key contract. States are current / complete (a check, still reachable so the user can go back) / upcoming. For a read-only progress readout use `Stepper`. _Key props:_ `items` (`key`, `label`, `hint`, `disabled`), `activeKey`, `completedKeys`, `onChange`, `aria-label`, `aria-labelledby`, `className`.
|
|
63
|
+
- **`CommandPalette`** — Chrome for a command palette, over a headless library that keeps its own elements. `FieldRow`/`Field` take the query input, `List` the scrolling viewport (with a bottom fade for `hasMoreBelow`), `Group` + `Heading` a titled section, and `Row` one result — composing leading/label/tags/crumb/meta/status/hint so names start and statuses end on the same x down the list. `Message` covers empty and loading, `Legend` documents the scope sigils, `Footer` the key hints. Everything the library owns is taken through `asChild`, so its role, id, state and handlers are untouched.
|
|
64
|
+
- **`Keycap`** — One key on a keyboard, drawn as a cap — `esc`, `⌘`, a caret, or a sigil a user types to scope a search. Renders a `<kbd>`, or a button as soon as either `onClick` or `disabled` is passed — `disabled={false}` included, since naming the prop at all is the statement that the cap is a control. `SidePanelNavFooter` is built on it.
|
|
63
65
|
- **`CollapsibleSection`** — Collapsible sunken-card section (title - subtitle header, disclosure arrow right) for stacked detail sections in side panels and detail pages. A preset over `Accordion`’s `sunken` variant.
|
|
64
66
|
- **`KeyValueList`** — Bordered card of label/value rows (`KeyValueList.Row`) for entity details: fixed-width secondary labels, free-form values, row dividers.
|
|
65
67
|
|
|
@@ -0,0 +1,150 @@
|
|
|
1
|
+
import { jsx as t, jsxs as n, Fragment as g } from "react/jsx-runtime";
|
|
2
|
+
import y, { useState as w, useEffect as N, useRef as k, useCallback as $ } from "react";
|
|
3
|
+
import { createPortal as R } from "react-dom";
|
|
4
|
+
import { ShadowRootWrapper as _ } from "../ShadowRootWrapper.js";
|
|
5
|
+
import { Keycap as z } from "./Keycap.js";
|
|
6
|
+
import { paintOnChild as i } from "./asChild.js";
|
|
7
|
+
import { useOverlayBehaviour as F } from "./overlayBehaviour.js";
|
|
8
|
+
import { OVERLAY_ELEVATED_ATTR as L, overlayIdentity as b } from "./portalOverlay.js";
|
|
9
|
+
const C = "w-full max-w-[640px] overflow-hidden font-body antialiased rounded-[var(--malachite-radius-xxl,14px)] border border-solid border-[var(--malachite-card-border)] bg-[var(--malachite-card-background)] outline-none [box-shadow:0_16px_48px_0_rgba(0,0,0,0.18)]", E = ({
|
|
10
|
+
children: a,
|
|
11
|
+
onDismiss: e,
|
|
12
|
+
"aria-label": r,
|
|
13
|
+
className: l = "",
|
|
14
|
+
style: s
|
|
15
|
+
}) => {
|
|
16
|
+
const [c, d] = w(!1);
|
|
17
|
+
N(() => d(!0), []);
|
|
18
|
+
const p = k(null), m = $(() => e == null ? void 0 : e(), [e]), { ref: x, isTopmost: u, zIndex: f, elevated: v } = F({
|
|
19
|
+
open: !0,
|
|
20
|
+
onClose: m,
|
|
21
|
+
hostRef: p,
|
|
22
|
+
initialFocus: "content"
|
|
23
|
+
});
|
|
24
|
+
return c ? R(
|
|
25
|
+
/* @__PURE__ */ t(
|
|
26
|
+
_,
|
|
27
|
+
{
|
|
28
|
+
hostRef: p,
|
|
29
|
+
hostStyle: { position: "relative", zIndex: f },
|
|
30
|
+
hostProps: v ? { ...b("commandpalette"), [L]: "" } : b("commandpalette"),
|
|
31
|
+
children: /* @__PURE__ */ t(
|
|
32
|
+
"div",
|
|
33
|
+
{
|
|
34
|
+
className: "fixed inset-0 z-[1000] flex items-start justify-center pt-[10vh] bg-[var(--malachite-overlay-scrim,rgba(0,0,0,0.5))]",
|
|
35
|
+
onClick: e ? (h) => h.target === h.currentTarget && e() : void 0,
|
|
36
|
+
role: "presentation",
|
|
37
|
+
children: /* @__PURE__ */ t(
|
|
38
|
+
"div",
|
|
39
|
+
{
|
|
40
|
+
ref: x,
|
|
41
|
+
role: "dialog",
|
|
42
|
+
"aria-modal": u ? "true" : void 0,
|
|
43
|
+
"aria-label": r,
|
|
44
|
+
tabIndex: -1,
|
|
45
|
+
className: `${C} ${l}`.trim(),
|
|
46
|
+
style: s,
|
|
47
|
+
children: a
|
|
48
|
+
}
|
|
49
|
+
)
|
|
50
|
+
}
|
|
51
|
+
)
|
|
52
|
+
}
|
|
53
|
+
),
|
|
54
|
+
document.body
|
|
55
|
+
) : null;
|
|
56
|
+
}, I = "w-full border-none bg-transparent px-0 py-[18px] text-[length:var(--malachite-font-size-xlarge,18px)] text-[var(--malachite-text-primary)] outline-none placeholder:text-[var(--malachite-text-placeholder)]", S = ({ children: a, className: e = "", style: r }) => i(a, `${I} ${e}`.trim(), r), T = ({ children: a, scope: e, className: r = "" }) => /* @__PURE__ */ n(
|
|
57
|
+
"div",
|
|
58
|
+
{
|
|
59
|
+
className: `flex items-center gap-2 border-0 border-b border-solid border-[var(--malachite-card-border)] px-[18px] ${r}`.trim(),
|
|
60
|
+
children: [
|
|
61
|
+
e,
|
|
62
|
+
a
|
|
63
|
+
]
|
|
64
|
+
}
|
|
65
|
+
), j = ({ children: a }) => /* @__PURE__ */ t("span", { className: "flex-none whitespace-nowrap rounded-lg border border-solid border-[var(--malachite-card-border)] bg-[var(--malachite-card-sunken-background)] px-2 py-[3px] text-[length:var(--malachite-font-size-small,13px)] text-[var(--malachite-text-primary)]", children: a }), P = "max-h-[420px] overflow-auto py-1 bg-[var(--malachite-card-background)]", A = ({ children: a, hasMoreBelow: e = !1, className: r = "", style: l }) => /* @__PURE__ */ n("div", { className: "relative", children: [
|
|
66
|
+
i(a, `${P} ${r}`.trim(), l),
|
|
67
|
+
e ? /* @__PURE__ */ t(
|
|
68
|
+
"div",
|
|
69
|
+
{
|
|
70
|
+
"aria-hidden": !0,
|
|
71
|
+
className: "pointer-events-none absolute inset-x-0 bottom-0 h-[28px] bg-[linear-gradient(to_bottom,transparent,var(--malachite-card-background))]"
|
|
72
|
+
}
|
|
73
|
+
) : null
|
|
74
|
+
] }), G = ({ children: a, divider: e = !1, className: r = "", style: l }) => i(
|
|
75
|
+
a,
|
|
76
|
+
`block pt-1 pb-2 ${e ? "border-0 border-b border-solid border-[var(--malachite-card-border)]" : ""} ${r}`.trim(),
|
|
77
|
+
l
|
|
78
|
+
), M = ({
|
|
79
|
+
children: a,
|
|
80
|
+
trailing: e
|
|
81
|
+
}) => /* @__PURE__ */ n("div", { className: "mb-1 flex items-center gap-2 px-4 text-[length:var(--malachite-font-size-xsmall,11px)] font-semibold uppercase tracking-[0.06em] text-[var(--malachite-text-secondary)]", children: [
|
|
82
|
+
a,
|
|
83
|
+
e
|
|
84
|
+
] }), O = "group mx-2 flex cursor-pointer items-center gap-2 rounded-[var(--malachite-radius-xl,12px)] px-3 py-[10px] text-[length:var(--malachite-font-size-medium,14px)] text-[var(--malachite-text-primary)] transition-colors hover:bg-[var(--malachite-card-sunken-background)] data-[selected=true]:bg-[var(--malachite-card-sunken-background)]", V = ({
|
|
85
|
+
children: a,
|
|
86
|
+
selected: e = !1,
|
|
87
|
+
leading: r,
|
|
88
|
+
label: l,
|
|
89
|
+
tags: s,
|
|
90
|
+
crumb: c,
|
|
91
|
+
meta: d,
|
|
92
|
+
status: p,
|
|
93
|
+
hint: m,
|
|
94
|
+
className: x = ""
|
|
95
|
+
}) => i(
|
|
96
|
+
a,
|
|
97
|
+
`${O} ${e ? "bg-[var(--malachite-card-sunken-background)]" : ""} ${x}`.trim(),
|
|
98
|
+
void 0,
|
|
99
|
+
/* @__PURE__ */ n(g, { children: [
|
|
100
|
+
r,
|
|
101
|
+
/* @__PURE__ */ n("span", { className: "flex min-w-0 flex-1 items-baseline gap-2", children: [
|
|
102
|
+
l ? /* @__PURE__ */ t("span", { className: "min-w-0 flex-[0_1_auto] overflow-hidden text-ellipsis whitespace-nowrap", children: l }) : null,
|
|
103
|
+
s ? /* @__PURE__ */ t("span", { className: "flex flex-none items-center gap-1 self-center", children: s }) : null,
|
|
104
|
+
c ? /* @__PURE__ */ t("span", { className: "flex-none whitespace-nowrap", children: c }) : null,
|
|
105
|
+
d ? /* @__PURE__ */ t("span", { className: "flex-none", children: d }) : null
|
|
106
|
+
] }),
|
|
107
|
+
/* @__PURE__ */ t("span", { className: "flex min-w-[84px] flex-none justify-end", children: p }),
|
|
108
|
+
/* @__PURE__ */ t(
|
|
109
|
+
"span",
|
|
110
|
+
{
|
|
111
|
+
className: `flex-none ${e ? "" : "invisible"} group-data-[selected=true]:visible`,
|
|
112
|
+
children: m
|
|
113
|
+
}
|
|
114
|
+
)
|
|
115
|
+
] })
|
|
116
|
+
), H = ({ children: a, className: e = "", style: r }) => {
|
|
117
|
+
const l = `block px-4 py-2 text-[length:var(--malachite-font-size-medium,14px)] text-[var(--malachite-text-secondary)] ${e}`.trim();
|
|
118
|
+
return y.isValidElement(a) ? i(a, l, r) : /* @__PURE__ */ t("div", { className: l, style: r, children: a });
|
|
119
|
+
}, W = ({ items: a }) => /* @__PURE__ */ t("div", { className: "flex flex-wrap gap-[14px] px-4 pt-[10px] pb-1 text-[length:var(--malachite-font-size-small,13px)] text-[var(--malachite-text-secondary)]", children: a.map((e) => /* @__PURE__ */ n("span", { className: "inline-flex items-center gap-[6px]", children: [
|
|
120
|
+
/* @__PURE__ */ t(z, { size: "small", children: e.key }),
|
|
121
|
+
e.label
|
|
122
|
+
] }, e.key)) }), B = ({ children: a, columns: e = 2, className: r = "" }) => /* @__PURE__ */ t(
|
|
123
|
+
"div",
|
|
124
|
+
{
|
|
125
|
+
className: `grid gap-1 px-2 ${e === 2 ? "grid-cols-2" : "grid-cols-1"} ${r}`.trim(),
|
|
126
|
+
children: a
|
|
127
|
+
}
|
|
128
|
+
), K = ({
|
|
129
|
+
children: a,
|
|
130
|
+
trailing: e
|
|
131
|
+
}) => /* @__PURE__ */ n("div", { className: "flex items-center justify-between gap-3 border-0 border-t border-solid border-[var(--malachite-card-border)] px-4 py-3 text-[length:var(--malachite-font-size-small,13px)] text-[var(--malachite-text-secondary)]", children: [
|
|
132
|
+
/* @__PURE__ */ t("span", { className: "flex items-center gap-[10px]", children: a }),
|
|
133
|
+
e ? /* @__PURE__ */ t("span", { className: "flex items-center gap-[10px]", children: e }) : null
|
|
134
|
+
] }), o = E;
|
|
135
|
+
o.FieldRow = T;
|
|
136
|
+
o.Field = S;
|
|
137
|
+
o.ScopeChip = j;
|
|
138
|
+
o.List = A;
|
|
139
|
+
o.Group = G;
|
|
140
|
+
o.Heading = M;
|
|
141
|
+
o.Row = V;
|
|
142
|
+
o.Grid = B;
|
|
143
|
+
o.Message = H;
|
|
144
|
+
o.Legend = W;
|
|
145
|
+
o.Footer = K;
|
|
146
|
+
export {
|
|
147
|
+
o as CommandPalette,
|
|
148
|
+
o as default
|
|
149
|
+
};
|
|
150
|
+
//# sourceMappingURL=CommandPalette.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"CommandPalette.js","sources":["../../src/components/CommandPalette.tsx"],"sourcesContent":["import React, { useCallback, useEffect, useRef, useState } from 'react';\nimport { createPortal } from 'react-dom';\nimport { ShadowRootWrapper } from '../ShadowRootWrapper';\nimport Keycap from './Keycap';\nimport { paintOnChild } from './asChild';\nimport { useOverlayBehaviour } from './overlayBehaviour';\nimport { OVERLAY_ELEVATED_ATTR, overlayIdentity } from './portalOverlay';\n\nconst PANEL =\n 'w-full max-w-[640px] overflow-hidden font-body antialiased rounded-[var(--malachite-radius-xxl,14px)] border border-solid border-[var(--malachite-card-border)] bg-[var(--malachite-card-background)] outline-none [box-shadow:0_16px_48px_0_rgba(0,0,0,0.18)]';\n\nexport interface CommandPaletteProps {\n children?: React.ReactNode;\n /** Scrim click, and Escape unless a consumer handler already called `preventDefault`. */\n onDismiss?: () => void;\n 'aria-label'?: string;\n className?: string;\n style?: React.CSSProperties;\n}\n\n/** Open while mounted. */\nconst CommandPaletteRoot: React.FC<CommandPaletteProps> = ({\n children,\n onDismiss,\n 'aria-label': ariaLabel,\n className = '',\n style,\n}) => {\n const [isMounted, setIsMounted] = useState(false);\n useEffect(() => setIsMounted(true), []);\n\n const hostRef = useRef<HTMLDivElement | null>(null);\n const dismiss = useCallback(() => onDismiss?.(), [onDismiss]);\n const { ref, isTopmost, zIndex, elevated } = useOverlayBehaviour({\n open: true,\n onClose: dismiss,\n hostRef,\n initialFocus: 'content',\n });\n\n if (!isMounted) {\n return null;\n }\n\n return createPortal(\n <ShadowRootWrapper\n hostRef={hostRef}\n hostStyle={{ position: 'relative', zIndex }}\n hostProps={\n elevated\n ? { ...overlayIdentity('commandpalette'), [OVERLAY_ELEVATED_ATTR]: '' }\n : overlayIdentity('commandpalette')\n }\n >\n <div\n className=\"fixed inset-0 z-[1000] flex items-start justify-center pt-[10vh] bg-[var(--malachite-overlay-scrim,rgba(0,0,0,0.5))]\"\n onClick={\n onDismiss\n ? (event) => event.target === event.currentTarget && onDismiss()\n : undefined\n }\n role=\"presentation\"\n >\n <div\n ref={ref}\n role=\"dialog\"\n aria-modal={isTopmost ? 'true' : undefined}\n aria-label={ariaLabel}\n tabIndex={-1}\n className={`${PANEL} ${className}`.trim()}\n style={style}\n >\n {children}\n </div>\n </div>\n </ShadowRootWrapper>,\n document.body,\n );\n};\n\ninterface AsChildProps {\n children: React.ReactElement;\n className?: string;\n style?: React.CSSProperties;\n}\n\nconst FIELD =\n 'w-full border-none bg-transparent px-0 py-[18px] text-[length:var(--malachite-font-size-xlarge,18px)] text-[var(--malachite-text-primary)] outline-none placeholder:text-[var(--malachite-text-placeholder)]';\n\nconst Field: React.FC<AsChildProps> = ({ children, className = '', style }) =>\n paintOnChild(children, `${FIELD} ${className}`.trim(), style);\n\nexport interface FieldRowProps {\n children?: React.ReactNode;\n scope?: React.ReactNode;\n className?: string;\n}\n\nconst FieldRow: React.FC<FieldRowProps> = ({ children, scope, className = '' }) => (\n <div\n className={`flex items-center gap-2 border-0 border-b border-solid border-[var(--malachite-card-border)] px-[18px] ${className}`.trim()}\n >\n {scope}\n {children}\n </div>\n);\n\nconst ScopeChip: React.FC<{ children?: React.ReactNode }> = ({ children }) => (\n <span className=\"flex-none whitespace-nowrap rounded-lg border border-solid border-[var(--malachite-card-border)] bg-[var(--malachite-card-sunken-background)] px-2 py-[3px] text-[length:var(--malachite-font-size-small,13px)] text-[var(--malachite-text-primary)]\">\n {children}\n </span>\n);\n\nexport interface ListProps extends AsChildProps {\n hasMoreBelow?: boolean;\n}\n\nconst LIST = 'max-h-[420px] overflow-auto py-1 bg-[var(--malachite-card-background)]';\n\nconst List: React.FC<ListProps> = ({ children, hasMoreBelow = false, className = '', style }) => (\n <div className=\"relative\">\n {paintOnChild(children, `${LIST} ${className}`.trim(), style)}\n {hasMoreBelow ? (\n <div\n aria-hidden\n className=\"pointer-events-none absolute inset-x-0 bottom-0 h-[28px] bg-[linear-gradient(to_bottom,transparent,var(--malachite-card-background))]\"\n />\n ) : null}\n </div>\n);\n\nexport interface GroupProps extends AsChildProps {\n divider?: boolean;\n}\n\nconst Group: React.FC<GroupProps> = ({ children, divider = false, className = '', style }) =>\n paintOnChild(\n children,\n `block pt-1 pb-2 ${\n divider ? 'border-0 border-b border-solid border-[var(--malachite-card-border)]' : ''\n } ${className}`.trim(),\n style,\n );\n\nconst Heading: React.FC<{ children?: React.ReactNode; trailing?: React.ReactNode }> = ({\n children,\n trailing,\n}) => (\n <div className=\"mb-1 flex items-center gap-2 px-4 text-[length:var(--malachite-font-size-xsmall,11px)] font-semibold uppercase tracking-[0.06em] text-[var(--malachite-text-secondary)]\">\n {children}\n {trailing}\n </div>\n);\n\nexport interface RowProps {\n /** Its children are replaced, so give the item an explicit `value`/`keywords`. */\n children: React.ReactElement;\n selected?: boolean;\n leading?: React.ReactNode;\n label?: React.ReactNode;\n /** Tags beside the label, kept visible while a long label truncates. */\n tags?: React.ReactNode;\n crumb?: React.ReactNode;\n meta?: React.ReactNode;\n status?: React.ReactNode;\n hint?: React.ReactNode;\n className?: string;\n}\n\n// `data-selected` too: a headless library marks its active item without re-rendering the row.\nconst ROW =\n 'group mx-2 flex cursor-pointer items-center gap-2 rounded-[var(--malachite-radius-xl,12px)] px-3 py-[10px] text-[length:var(--malachite-font-size-medium,14px)] text-[var(--malachite-text-primary)] transition-colors hover:bg-[var(--malachite-card-sunken-background)] data-[selected=true]:bg-[var(--malachite-card-sunken-background)]';\n\nconst Row: React.FC<RowProps> = ({\n children,\n selected = false,\n leading,\n label,\n tags,\n crumb,\n meta,\n status,\n hint,\n className = '',\n}) =>\n paintOnChild(\n children,\n `${ROW} ${selected ? 'bg-[var(--malachite-card-sunken-background)]' : ''} ${className}`.trim(),\n undefined,\n <>\n {leading}\n <span className=\"flex min-w-0 flex-1 items-baseline gap-2\">\n {label ? (\n <span className=\"min-w-0 flex-[0_1_auto] overflow-hidden text-ellipsis whitespace-nowrap\">\n {label}\n </span>\n ) : null}\n {tags ? (\n <span className=\"flex flex-none items-center gap-1 self-center\">{tags}</span>\n ) : null}\n {crumb ? <span className=\"flex-none whitespace-nowrap\">{crumb}</span> : null}\n {meta ? <span className=\"flex-none\">{meta}</span> : null}\n </span>\n <span className=\"flex min-w-[84px] flex-none justify-end\">{status}</span>\n <span\n className={`flex-none ${selected ? '' : 'invisible'} group-data-[selected=true]:visible`}\n >\n {hint}\n </span>\n </>,\n );\n\nexport interface MessageProps {\n children: React.ReactNode;\n className?: string;\n style?: React.CSSProperties;\n}\n\nconst Message: React.FC<MessageProps> = ({ children, className = '', style }) => {\n const classes =\n `block px-4 py-2 text-[length:var(--malachite-font-size-medium,14px)] text-[var(--malachite-text-secondary)] ${className}`.trim();\n return React.isValidElement(children) ? (\n paintOnChild(children, classes, style)\n ) : (\n <div className={classes} style={style}>\n {children}\n </div>\n );\n};\n\nexport interface LegendProps {\n items: { key: string; label: string }[];\n}\n\nconst Legend: React.FC<LegendProps> = ({ items }) => (\n <div className=\"flex flex-wrap gap-[14px] px-4 pt-[10px] pb-1 text-[length:var(--malachite-font-size-small,13px)] text-[var(--malachite-text-secondary)]\">\n {items.map((item) => (\n <span key={item.key} className=\"inline-flex items-center gap-[6px]\">\n <Keycap size=\"small\">{item.key}</Keycap>\n {item.label}\n </span>\n ))}\n </div>\n);\n\nexport interface GridProps {\n children?: React.ReactNode;\n columns?: 1 | 2;\n className?: string;\n}\n\nconst Grid: React.FC<GridProps> = ({ children, columns = 2, className = '' }) => (\n <div\n className={`grid gap-1 px-2 ${columns === 2 ? 'grid-cols-2' : 'grid-cols-1'} ${className}`.trim()}\n >\n {children}\n </div>\n);\n\nconst Footer: React.FC<{ children?: React.ReactNode; trailing?: React.ReactNode }> = ({\n children,\n trailing,\n}) => (\n <div className=\"flex items-center justify-between gap-3 border-0 border-t border-solid border-[var(--malachite-card-border)] px-4 py-3 text-[length:var(--malachite-font-size-small,13px)] text-[var(--malachite-text-secondary)]\">\n <span className=\"flex items-center gap-[10px]\">{children}</span>\n {trailing ? <span className=\"flex items-center gap-[10px]\">{trailing}</span> : null}\n </div>\n);\n\ninterface CommandPaletteComponent extends React.FC<CommandPaletteProps> {\n FieldRow: React.FC<FieldRowProps>;\n Field: React.FC<AsChildProps>;\n ScopeChip: React.FC<{ children?: React.ReactNode }>;\n List: React.FC<ListProps>;\n Group: React.FC<GroupProps>;\n Heading: React.FC<{ children?: React.ReactNode; trailing?: React.ReactNode }>;\n Row: React.FC<RowProps>;\n Grid: React.FC<GridProps>;\n Message: React.FC<MessageProps>;\n Legend: React.FC<LegendProps>;\n Footer: React.FC<{ children?: React.ReactNode; trailing?: React.ReactNode }>;\n}\n\nconst CommandPalette = CommandPaletteRoot as CommandPaletteComponent;\nCommandPalette.FieldRow = FieldRow;\nCommandPalette.Field = Field;\nCommandPalette.ScopeChip = ScopeChip;\nCommandPalette.List = List;\nCommandPalette.Group = Group;\nCommandPalette.Heading = Heading;\nCommandPalette.Row = Row;\nCommandPalette.Grid = Grid;\nCommandPalette.Message = Message;\nCommandPalette.Legend = Legend;\nCommandPalette.Footer = Footer;\n\nexport default CommandPalette;\nexport { CommandPalette };\n"],"names":["PANEL","CommandPaletteRoot","children","onDismiss","ariaLabel","className","style","isMounted","setIsMounted","useState","useEffect","hostRef","useRef","dismiss","useCallback","ref","isTopmost","zIndex","elevated","useOverlayBehaviour","createPortal","jsx","ShadowRootWrapper","overlayIdentity","OVERLAY_ELEVATED_ATTR","event","FIELD","Field","paintOnChild","FieldRow","scope","jsxs","ScopeChip","LIST","List","hasMoreBelow","Group","divider","Heading","trailing","ROW","Row","selected","leading","label","tags","crumb","meta","status","hint","Fragment","Message","classes","React","Legend","items","item","Keycap","Grid","columns","Footer","CommandPalette"],"mappings":";;;;;;;;AAQA,MAAMA,IACF,kQAYEC,IAAoD,CAAC;AAAA,EACvD,UAAAC;AAAA,EACA,WAAAC;AAAA,EACA,cAAcC;AAAA,EACd,WAAAC,IAAY;AAAA,EACZ,OAAAC;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EAAE,OAAAC,EAAA,wBACpC,OAAA,EAAI,WAAU,4IACV,UAAAA,EAAM,IAAI,CAACC,MACR,gBAAAzB,EAAC,QAAA,EAAoB,WAAU,sCAC3B,UAAA;AAAA,EAAA,gBAAAV,EAACoC,GAAA,EAAO,MAAK,SAAS,UAAAD,EAAK,KAAI;AAAA,EAC9BA,EAAK;AAAA,EAAA,GAFCA,EAAK,GAGhB,CACH,GACL,GASEE,IAA4B,CAAC,EAAE,UAAAxD,GAAU,SAAAyD,IAAU,GAAG,WAAAtD,IAAY,SACpE,gBAAAgB;AAAA,EAAC;AAAA,EAAA;AAAA,IACG,WAAW,mBAAmBsC,MAAY,IAAI,gBAAgB,aAAa,IAAItD,CAAS,GAAG,KAAA;AAAA,IAE1F,UAAAH;AAAA,EAAA;AACL,GAGE0D,IAA+E,CAAC;AAAA,EAClF,UAAA1D;AAAA,EACA,UAAAqC;AACJ,MACI,gBAAAR,EAAC,OAAA,EAAI,WAAU,qNACX,UAAA;AAAA,EAAA,gBAAAV,EAAC,QAAA,EAAK,WAAU,gCAAgC,UAAAnB,EAAA,CAAS;AAAA,EACxDqC,IAAW,gBAAAlB,EAAC,QAAA,EAAK,WAAU,gCAAgC,aAAS,IAAU;AAAA,GACnF,GAiBEwC,IAAiB5D;AACvB4D,EAAe,WAAWhC;AAC1BgC,EAAe,QAAQlC;AACvBkC,EAAe,YAAY7B;AAC3B6B,EAAe,OAAO3B;AACtB2B,EAAe,QAAQzB;AACvByB,EAAe,UAAUvB;AACzBuB,EAAe,MAAMpB;AACrBoB,EAAe,OAAOH;AACtBG,EAAe,UAAUV;AACzBU,EAAe,SAASP;AACxBO,EAAe,SAASD;"}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import { jsx as i } from "react/jsx-runtime";
|
|
2
|
+
import { FOCUS_RING as m } from "./focusRing.js";
|
|
3
|
+
const c = {
|
|
4
|
+
small: "h-[18px] min-w-[18px]",
|
|
5
|
+
medium: "h-[20px] min-w-[20px]"
|
|
6
|
+
}, b = "inline-flex items-center justify-center rounded-lg border border-solid border-[var(--malachite-card-border,rgb(232,232,232))] bg-[var(--malachite-card-background,rgb(255,255,255))] [box-shadow:var(--malachite-shadow-default,0px_1px_0px_0px_rgba(0,0,0,0.15))]", n = "px-[6px] text-[10px] font-medium uppercase tracking-[0.5px] text-[var(--malachite-text-placeholder,rgb(187,187,187))]", x = "px-[4px]", h = ({
|
|
7
|
+
children: a,
|
|
8
|
+
size: e = "medium",
|
|
9
|
+
onClick: t,
|
|
10
|
+
disabled: r,
|
|
11
|
+
"aria-label": o,
|
|
12
|
+
"aria-labelledby": l,
|
|
13
|
+
className: p = ""
|
|
14
|
+
}) => t !== void 0 || r !== void 0 ? /* @__PURE__ */ i(
|
|
15
|
+
"button",
|
|
16
|
+
{
|
|
17
|
+
type: "button",
|
|
18
|
+
"aria-label": o,
|
|
19
|
+
"aria-labelledby": l,
|
|
20
|
+
onClick: t,
|
|
21
|
+
disabled: r,
|
|
22
|
+
className: `${c[e]} ${b} ${x} transition-opacity ${m} ${r ? "cursor-not-allowed opacity-40" : "cursor-pointer hover:border-[var(--malachite-text-placeholder,rgb(187,187,187))]"} ${p}`.trim(),
|
|
23
|
+
children: a
|
|
24
|
+
}
|
|
25
|
+
) : /* @__PURE__ */ i(
|
|
26
|
+
"kbd",
|
|
27
|
+
{
|
|
28
|
+
className: `${c[e]} ${b} ${n} ${p}`.trim(),
|
|
29
|
+
"aria-label": o,
|
|
30
|
+
"aria-labelledby": l,
|
|
31
|
+
children: a
|
|
32
|
+
}
|
|
33
|
+
);
|
|
34
|
+
export {
|
|
35
|
+
h as Keycap,
|
|
36
|
+
h as default
|
|
37
|
+
};
|
|
38
|
+
//# sourceMappingURL=Keycap.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Keycap.js","sources":["../../src/components/Keycap.tsx"],"sourcesContent":["import React from 'react';\nimport { FOCUS_RING } from './focusRing';\n\nexport type KeycapSize = 'small' | 'medium';\n\nexport interface KeycapProps {\n children: React.ReactNode;\n size?: KeycapSize;\n onClick?: () => void;\n /** Renders a `<button>` even when `false`. */\n disabled?: boolean;\n 'aria-label'?: string;\n 'aria-labelledby'?: string;\n className?: string;\n}\n\nconst SIZE_CLASSES: Record<KeycapSize, string> = {\n small: 'h-[18px] min-w-[18px]',\n medium: 'h-[20px] min-w-[20px]',\n};\n\nconst CAP =\n 'inline-flex items-center justify-center rounded-lg border border-solid border-[var(--malachite-card-border,rgb(232,232,232))] bg-[var(--malachite-card-background,rgb(255,255,255))] [box-shadow:var(--malachite-shadow-default,0px_1px_0px_0px_rgba(0,0,0,0.15))]';\n\nconst LABEL_CAP =\n 'px-[6px] text-[10px] font-medium uppercase tracking-[0.5px] text-[var(--malachite-text-placeholder,rgb(187,187,187))]';\nconst GLYPH_CAP = 'px-[4px]';\n\nexport const Keycap: React.FC<KeycapProps> = ({\n children,\n size = 'medium',\n onClick,\n disabled,\n 'aria-label': ariaLabel,\n 'aria-labelledby': ariaLabelledBy,\n className = '',\n}) => {\n const pressable = onClick !== undefined || disabled !== undefined;\n\n if (!pressable) {\n return (\n <kbd\n className={`${SIZE_CLASSES[size]} ${CAP} ${LABEL_CAP} ${className}`.trim()}\n aria-label={ariaLabel}\n aria-labelledby={ariaLabelledBy}\n >\n {children}\n </kbd>\n );\n }\n\n return (\n <button\n type=\"button\"\n aria-label={ariaLabel}\n aria-labelledby={ariaLabelledBy}\n onClick={onClick}\n disabled={disabled}\n className={`${SIZE_CLASSES[size]} ${CAP} ${GLYPH_CAP} transition-opacity ${FOCUS_RING} ${\n disabled\n ? 'cursor-not-allowed opacity-40'\n : 'cursor-pointer hover:border-[var(--malachite-text-placeholder,rgb(187,187,187))]'\n } ${className}`.trim()}\n >\n {children}\n </button>\n );\n};\n\nexport default Keycap;\n"],"names":["SIZE_CLASSES","CAP","LABEL_CAP","GLYPH_CAP","Keycap","children","size","onClick","disabled","ariaLabel","ariaLabelledBy","className","jsx","FOCUS_RING"],"mappings":";;AAgBA,MAAMA,IAA2C;AAAA,EAC7C,OAAO;AAAA,EACP,QAAQ;AACZ,GAEMC,IACF,sQAEEC,IACF,yHACEC,IAAY,YAELC,IAAgC,CAAC;AAAA,EAC1C,UAAAC;AAAA,EACA,MAAAC,IAAO;AAAA,EACP,SAAAC;AAAA,EACA,UAAAC;AAAA,EACA,cAAcC;AAAA,EACd,mBAAmBC;AAAA,EACnB,WAAAC,IAAY;AAChB,MACsBJ,MAAY,UAAaC,MAAa,SAepD,gBAAAI;AAAA,EAAC;AAAA,EAAA;AAAA,IACG,MAAK;AAAA,IACL,cAAYH;AAAA,IACZ,mBAAiBC;AAAA,IACjB,SAAAH;AAAA,IACA,UAAAC;AAAA,IACA,WAAW,GAAGR,EAAaM,CAAI,CAAC,IAAIL,CAAG,IAAIE,CAAS,uBAAuBU,CAAU,IACjFL,IACM,kCACA,kFACV,IAAIG,CAAS,GAAG,KAAA;AAAA,IAEf,UAAAN;AAAA,EAAA;AAAA,IAvBD,gBAAAO;AAAA,EAAC;AAAA,EAAA;AAAA,IACG,WAAW,GAAGZ,EAAaM,CAAI,CAAC,IAAIL,CAAG,IAAIC,CAAS,IAAIS,CAAS,GAAG,KAAA;AAAA,IACpE,cAAYF;AAAA,IACZ,mBAAiBC;AAAA,IAEhB,UAAAL;AAAA,EAAA;AAAA;"}
|
|
@@ -1,46 +1,30 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import {
|
|
5
|
-
const
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
onNavigateDown: a,
|
|
18
|
-
canNavigateUp: l = !1,
|
|
19
|
-
canNavigateDown: i = !1,
|
|
20
|
-
actions: c,
|
|
21
|
-
className: d = ""
|
|
22
|
-
}) => /* @__PURE__ */ r("div", { className: `flex w-full items-center justify-between ${d}`, children: [
|
|
23
|
-
/* @__PURE__ */ r("div", { className: "flex items-center gap-[8px]", children: [
|
|
24
|
-
/* @__PURE__ */ r("div", { className: "flex items-center gap-[4px]", children: [
|
|
25
|
-
/* @__PURE__ */ e(o, { ariaLabel: "Previous", onClick: t, disabled: !l, children: /* @__PURE__ */ e(m, { size: 11 }) }),
|
|
26
|
-
/* @__PURE__ */ e(o, { ariaLabel: "Next", onClick: a, disabled: !i, children: /* @__PURE__ */ e(p, { size: 11 }) })
|
|
1
|
+
import { jsxs as a, jsx as e } from "react/jsx-runtime";
|
|
2
|
+
import d from "./CustomIcons/CaretDownIcon.js";
|
|
3
|
+
import o from "./CustomIcons/CaretUpIcon.js";
|
|
4
|
+
import { Keycap as l } from "./Keycap.js";
|
|
5
|
+
const s = "text-[13px] font-medium tracking-[0.14px] text-[var(--malachite-text-secondary)]", N = ({
|
|
6
|
+
onNavigateUp: r,
|
|
7
|
+
onNavigateDown: t,
|
|
8
|
+
canNavigateUp: c = !1,
|
|
9
|
+
canNavigateDown: n = !1,
|
|
10
|
+
actions: i,
|
|
11
|
+
className: m = ""
|
|
12
|
+
}) => /* @__PURE__ */ a("div", { className: `flex w-full items-center justify-between ${m}`, children: [
|
|
13
|
+
/* @__PURE__ */ a("div", { className: "flex items-center gap-[8px]", children: [
|
|
14
|
+
/* @__PURE__ */ a("div", { className: "flex items-center gap-[4px]", children: [
|
|
15
|
+
/* @__PURE__ */ e(l, { "aria-label": "Previous", onClick: r, disabled: !c, children: /* @__PURE__ */ e(o, { size: 11 }) }),
|
|
16
|
+
/* @__PURE__ */ e(l, { "aria-label": "Next", onClick: t, disabled: !n, children: /* @__PURE__ */ e(d, { size: 11 }) })
|
|
27
17
|
] }),
|
|
28
18
|
/* @__PURE__ */ e("span", { className: s, children: "Navigate" }),
|
|
29
|
-
/* @__PURE__ */
|
|
30
|
-
/* @__PURE__ */ e(
|
|
31
|
-
"span",
|
|
32
|
-
{
|
|
33
|
-
className: `${n} px-[6px] text-[10px] font-medium uppercase tracking-[0.5px] text-[var(--malachite-text-placeholder)]`,
|
|
34
|
-
children: "esc"
|
|
35
|
-
}
|
|
36
|
-
),
|
|
19
|
+
/* @__PURE__ */ a("div", { className: "ml-[20px] flex items-center gap-[8px]", children: [
|
|
20
|
+
/* @__PURE__ */ e(l, { children: "esc" }),
|
|
37
21
|
/* @__PURE__ */ e("span", { className: s, children: "Close" })
|
|
38
22
|
] })
|
|
39
23
|
] }),
|
|
40
|
-
|
|
24
|
+
i ? /* @__PURE__ */ e("div", { className: "flex items-center", children: i }) : null
|
|
41
25
|
] });
|
|
42
26
|
export {
|
|
43
|
-
|
|
44
|
-
|
|
27
|
+
N as SidePanelNavFooter,
|
|
28
|
+
N as default
|
|
45
29
|
};
|
|
46
30
|
//# sourceMappingURL=SidePanelNavFooter.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SidePanelNavFooter.js","sources":["../../src/components/SidePanelNavFooter.tsx"],"sourcesContent":["import React from 'react';\nimport CaretDownIcon from './CustomIcons/CaretDownIcon';\nimport CaretUpIcon from './CustomIcons/CaretUpIcon';\nimport
|
|
1
|
+
{"version":3,"file":"SidePanelNavFooter.js","sources":["../../src/components/SidePanelNavFooter.tsx"],"sourcesContent":["import React from 'react';\nimport CaretDownIcon from './CustomIcons/CaretDownIcon';\nimport CaretUpIcon from './CustomIcons/CaretUpIcon';\nimport Keycap from './Keycap';\n\nexport interface SidePanelNavFooterProps {\n onNavigateUp?: () => void;\n onNavigateDown?: () => void;\n canNavigateUp?: boolean;\n canNavigateDown?: boolean;\n actions?: React.ReactNode;\n className?: string;\n}\n\nconst LABEL = 'text-[13px] font-medium tracking-[0.14px] text-[var(--malachite-text-secondary)]';\n\nconst SidePanelNavFooter: React.FC<SidePanelNavFooterProps> = ({\n onNavigateUp,\n onNavigateDown,\n canNavigateUp = false,\n canNavigateDown = false,\n actions,\n className = '',\n}) => (\n <div className={`flex w-full items-center justify-between ${className}`}>\n <div className=\"flex items-center gap-[8px]\">\n <div className=\"flex items-center gap-[4px]\">\n <Keycap aria-label=\"Previous\" onClick={onNavigateUp} disabled={!canNavigateUp}>\n <CaretUpIcon size={11} />\n </Keycap>\n <Keycap aria-label=\"Next\" onClick={onNavigateDown} disabled={!canNavigateDown}>\n <CaretDownIcon size={11} />\n </Keycap>\n </div>\n <span className={LABEL}>Navigate</span>\n <div className=\"ml-[20px] flex items-center gap-[8px]\">\n <Keycap>esc</Keycap>\n <span className={LABEL}>Close</span>\n </div>\n </div>\n {actions ? <div className=\"flex items-center\">{actions}</div> : null}\n </div>\n);\n\nexport default SidePanelNavFooter;\nexport { SidePanelNavFooter };\n"],"names":["LABEL","SidePanelNavFooter","onNavigateUp","onNavigateDown","canNavigateUp","canNavigateDown","actions","className","jsxs","jsx","Keycap","CaretUpIcon","CaretDownIcon"],"mappings":";;;;AAcA,MAAMA,IAAQ,oFAERC,IAAwD,CAAC;AAAA,EAC3D,cAAAC;AAAA,EACA,gBAAAC;AAAA,EACA,eAAAC,IAAgB;AAAA,EAChB,iBAAAC,IAAkB;AAAA,EAClB,SAAAC;AAAA,EACA,WAAAC,IAAY;AAChB,MACI,gBAAAC,EAAC,OAAA,EAAI,WAAW,4CAA4CD,CAAS,IACjE,UAAA;AAAA,EAAA,gBAAAC,EAAC,OAAA,EAAI,WAAU,+BACX,UAAA;AAAA,IAAA,gBAAAA,EAAC,OAAA,EAAI,WAAU,+BACX,UAAA;AAAA,MAAA,gBAAAC,EAACC,GAAA,EAAO,cAAW,YAAW,SAASR,GAAc,UAAU,CAACE,GAC5D,UAAA,gBAAAK,EAACE,GAAA,EAAY,MAAM,GAAA,CAAI,GAC3B;AAAA,MACA,gBAAAF,EAACC,GAAA,EAAO,cAAW,QAAO,SAASP,GAAgB,UAAU,CAACE,GAC1D,UAAA,gBAAAI,EAACG,GAAA,EAAc,MAAM,IAAI,EAAA,CAC7B;AAAA,IAAA,GACJ;AAAA,IACA,gBAAAH,EAAC,QAAA,EAAK,WAAWT,GAAO,UAAA,YAAQ;AAAA,IAChC,gBAAAQ,EAAC,OAAA,EAAI,WAAU,yCACX,UAAA;AAAA,MAAA,gBAAAC,EAACC,KAAO,UAAA,MAAA,CAAG;AAAA,MACX,gBAAAD,EAAC,QAAA,EAAK,WAAWT,GAAO,UAAA,QAAA,CAAK;AAAA,IAAA,EAAA,CACjC;AAAA,EAAA,GACJ;AAAA,EACCM,IAAU,gBAAAG,EAAC,OAAA,EAAI,WAAU,qBAAqB,aAAQ,IAAS;AAAA,EAAA,CACpE;"}
|