@momoi-labs/kiso-react 0.13.0 → 0.15.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/README.md +3 -0
- package/dist/app-shell.js +3 -2
- package/dist/chart-legend.js +1 -1
- package/dist/chart-style.d.ts +19 -0
- package/dist/chart-style.js +68 -0
- package/dist/chart.d.ts +3 -1
- package/dist/chart.js +21 -9
- package/dist/chip-input.js +3 -8
- package/dist/command-palette.js +2 -1
- package/dist/detail-select.d.ts +24 -0
- package/dist/detail-select.js +56 -0
- package/dist/diagram.d.ts +104 -0
- package/dist/diagram.js +208 -0
- package/dist/index.d.ts +5 -0
- package/dist/index.js +4 -0
- package/dist/pane-grid.d.ts +28 -0
- package/dist/pane-grid.js +488 -0
- package/dist/password-input.d.ts +15 -0
- package/dist/password-input.js +31 -0
- package/dist/search.js +2 -1
- package/dist/select.js +2 -1
- package/dist/sparkline.d.ts +3 -1
- package/dist/sparkline.js +16 -2
- package/dist/steps.js +2 -1
- package/dist/styles.css +51 -0
- package/dist/theme-selector.js +5 -4
- package/dist/time-range-control.js +2 -1
- package/package.json +6 -4
package/dist/diagram.js
ADDED
|
@@ -0,0 +1,208 @@
|
|
|
1
|
+
import { Fragment as _Fragment, jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
import * as React from "react";
|
|
3
|
+
import { clsx as cn } from "clsx";
|
|
4
|
+
import { ChevronDown, ChevronUp, Container, Database, GitBranch, Route, Server } from "lucide-react";
|
|
5
|
+
import { Badge } from "./badge.js";
|
|
6
|
+
import { Card } from "./card.js";
|
|
7
|
+
import { StatusBadge } from "./status-badge.js";
|
|
8
|
+
import { useIsomorphicLayoutEffect } from "./use-isomorphic-layout-effect.js";
|
|
9
|
+
const DiagramContext = React.createContext(null);
|
|
10
|
+
function useRegistry(part) {
|
|
11
|
+
const registry = React.useContext(DiagramContext);
|
|
12
|
+
if (!registry)
|
|
13
|
+
throw new Error(`${part} must be inside <Diagram>`);
|
|
14
|
+
return registry;
|
|
15
|
+
}
|
|
16
|
+
/* Each kind carries its default label, icon and tone. The tone colours the
|
|
17
|
+
rail and the icon; the frame stays neutral so the kind reads at a glance
|
|
18
|
+
without turning the node into a status. */
|
|
19
|
+
const kinds = {
|
|
20
|
+
route: { label: "Route", tone: "neutral", icon: Route },
|
|
21
|
+
service: { label: "Service", tone: "primary", icon: Server },
|
|
22
|
+
repository: { label: "Git repository", tone: "primary", icon: GitBranch },
|
|
23
|
+
image: { label: "Container image", tone: "primary", icon: Container },
|
|
24
|
+
database: { label: "Database", tone: "info", icon: Database },
|
|
25
|
+
};
|
|
26
|
+
const statuses = {
|
|
27
|
+
stopped: { label: "Stopped", tone: "neutral" },
|
|
28
|
+
failed: { label: "Failed", tone: "danger" },
|
|
29
|
+
};
|
|
30
|
+
const RADIUS = 8;
|
|
31
|
+
/* An edge is two paths. The trunk is the horizontal run out of the source,
|
|
32
|
+
shared by every edge that leaves it, so it is always drawn solid and
|
|
33
|
+
neutral: two styles on one line would paint over each other. The branch
|
|
34
|
+
is the rest, the turn onto the merge column, the vertical run and the
|
|
35
|
+
straight run into the target, and it carries the edge's line and tone. */
|
|
36
|
+
function elbow(sx, sy, tx, ty, mid) {
|
|
37
|
+
const dy = ty - sy;
|
|
38
|
+
if (Math.abs(dy) < 1)
|
|
39
|
+
return { trunk: `M ${sx} ${sy} H ${mid}`, branch: `M ${mid} ${sy} H ${tx}` };
|
|
40
|
+
const r = Math.max(0, Math.min(RADIUS, Math.abs(dy) / 2, mid - sx, tx - mid));
|
|
41
|
+
const d = Math.sign(dy);
|
|
42
|
+
return {
|
|
43
|
+
trunk: `M ${sx} ${sy} H ${mid - r}`,
|
|
44
|
+
branch: [
|
|
45
|
+
`M ${mid - r} ${sy}`,
|
|
46
|
+
`Q ${mid} ${sy} ${mid} ${sy + d * r}`,
|
|
47
|
+
`V ${ty - d * r}`,
|
|
48
|
+
`Q ${mid} ${ty} ${mid + r} ${ty}`,
|
|
49
|
+
`H ${tx}`,
|
|
50
|
+
].join(" "),
|
|
51
|
+
};
|
|
52
|
+
}
|
|
53
|
+
function Diagram({ label, background, strength, borderStyle, cornerStyle, cornerSize, cornerMarks, className, children, ...props }) {
|
|
54
|
+
const frame = React.useRef(null);
|
|
55
|
+
const scroll = React.useRef(null);
|
|
56
|
+
const nodes = React.useRef(new Map()).current;
|
|
57
|
+
const [edges, setEdges] = React.useState([]);
|
|
58
|
+
const [version, setVersion] = React.useState(0);
|
|
59
|
+
const [drawn, setDrawn] = React.useState({ paths: [], labels: [] });
|
|
60
|
+
const marker = `${React.useId()}arrow`;
|
|
61
|
+
const register = React.useCallback((id, element) => {
|
|
62
|
+
if (element)
|
|
63
|
+
nodes.set(id, element);
|
|
64
|
+
else
|
|
65
|
+
nodes.delete(id);
|
|
66
|
+
setVersion((value) => value + 1);
|
|
67
|
+
}, [nodes]);
|
|
68
|
+
const addEdge = React.useCallback((edge) => {
|
|
69
|
+
setEdges((list) => [...list, edge]);
|
|
70
|
+
return () => setEdges((list) => list.filter((item) => item !== edge));
|
|
71
|
+
}, []);
|
|
72
|
+
const context = React.useMemo(() => ({ nodes, register, addEdge }), [nodes, register, addEdge]);
|
|
73
|
+
useIsomorphicLayoutEffect(() => {
|
|
74
|
+
const root = frame.current;
|
|
75
|
+
const region = scroll.current;
|
|
76
|
+
if (!root || !region)
|
|
77
|
+
return;
|
|
78
|
+
// Lay the drawing out wrapped to the panel first. If it still overflows,
|
|
79
|
+
// wrapping only cramps it, so it takes its natural width and scrolls.
|
|
80
|
+
const fit = () => {
|
|
81
|
+
root.removeAttribute("data-overflow");
|
|
82
|
+
if (root.offsetWidth > region.clientWidth)
|
|
83
|
+
root.setAttribute("data-overflow", "");
|
|
84
|
+
};
|
|
85
|
+
const measure = () => {
|
|
86
|
+
fit();
|
|
87
|
+
const origin = root.getBoundingClientRect();
|
|
88
|
+
const box = (id) => {
|
|
89
|
+
const rect = nodes.get(id)?.getBoundingClientRect();
|
|
90
|
+
if (!rect)
|
|
91
|
+
return null;
|
|
92
|
+
return {
|
|
93
|
+
left: rect.left - origin.left,
|
|
94
|
+
right: rect.right - origin.left,
|
|
95
|
+
top: rect.top - origin.top,
|
|
96
|
+
height: rect.height,
|
|
97
|
+
y: rect.top - origin.top + rect.height / 2,
|
|
98
|
+
};
|
|
99
|
+
};
|
|
100
|
+
// Each edge into a target gets its own entry point, spread down the
|
|
101
|
+
// target's side in the order of their sources, so their arrows and
|
|
102
|
+
// labels never land on the same spot. One edge enters at the middle.
|
|
103
|
+
const measured = edges.flatMap((edge) => {
|
|
104
|
+
const target = box(edge.to);
|
|
105
|
+
const sources = edge.from.map(box).filter((b) => b !== null);
|
|
106
|
+
return target && sources.length ? [{ edge, target, sources }] : [];
|
|
107
|
+
});
|
|
108
|
+
const entries = new Map();
|
|
109
|
+
const top = (item) => Math.min(...item.sources.map((s) => s.y));
|
|
110
|
+
for (const id of new Set(measured.map((item) => item.edge.to))) {
|
|
111
|
+
const group = measured.filter((item) => item.edge.to === id).sort((a, b) => top(a) - top(b));
|
|
112
|
+
group.forEach((item, index) => {
|
|
113
|
+
entries.set(item.edge, item.target.top + (item.target.height * (index + 1)) / (group.length + 1));
|
|
114
|
+
});
|
|
115
|
+
}
|
|
116
|
+
const next = { paths: [], labels: [] };
|
|
117
|
+
for (const { edge, target, sources } of measured) {
|
|
118
|
+
const ty = entries.get(edge) ?? target.y;
|
|
119
|
+
const start = Math.max(...sources.map((s) => s.right));
|
|
120
|
+
const mid = (start + target.left) / 2;
|
|
121
|
+
sources.forEach((source, index) => {
|
|
122
|
+
const { trunk, branch } = elbow(source.right, source.y, target.left, ty, mid);
|
|
123
|
+
next.paths.push({ key: `${edge.key}:${index}:trunk`, d: trunk, arrow: false });
|
|
124
|
+
next.paths.push({ key: `${edge.key}:${index}`, d: branch, line: edge.line, tone: edge.tone, arrow: true });
|
|
125
|
+
});
|
|
126
|
+
// The label sits on the edge's own run into the target, above the line.
|
|
127
|
+
if (edge.label)
|
|
128
|
+
next.labels.push({ key: edge.key, x: mid, y: ty - RADIUS, text: edge.label });
|
|
129
|
+
}
|
|
130
|
+
setDrawn(next);
|
|
131
|
+
};
|
|
132
|
+
measure();
|
|
133
|
+
const observer = new ResizeObserver(measure);
|
|
134
|
+
observer.observe(root);
|
|
135
|
+
observer.observe(region);
|
|
136
|
+
nodes.forEach((element) => observer.observe(element));
|
|
137
|
+
return () => observer.disconnect();
|
|
138
|
+
}, [edges, nodes, version]);
|
|
139
|
+
return (_jsx(DiagramContext.Provider, { value: context, children: _jsx("div", { ...props, "data-slot": "diagram", className: cn("card diagram", className), "data-background-style": background, "data-background-strength": strength, children: _jsx("div", { ref: scroll, "data-slot": "diagram-scroll", className: "diagram-scroll", role: "group", "aria-label": label, tabIndex: 0, children: _jsxs("div", { ref: frame, "data-slot": "diagram-canvas", className: "diagram-canvas", children: [_jsx("div", { "data-slot": "diagram-lanes", className: "diagram-lanes", "data-border-style": borderStyle, "data-corner-style": cornerStyle, "data-corner-size": cornerSize, "data-corner-marks": cornerMarks, "data-edge-labels": edges.some((edge) => edge.label) || undefined, children: children }), _jsxs("svg", { className: "diagram-edges", "aria-hidden": "true", children: [_jsx("defs", { children: ["neutral", "success", "danger"].map((tone) => (_jsx("marker", { id: `${marker}-${tone}`, className: "diagram-arrow", "data-tone": tone, viewBox: "0 0 10 10", refX: "9", refY: "5", markerWidth: "7", markerHeight: "7", orient: "auto-start-reverse", children: _jsx("path", { d: "M 0 0 L 10 5 L 0 10 z" }) }, tone))) }), drawn.paths.map((path) => (_jsx("path", { d: path.d, "data-line": path.line, "data-tone": path.tone, markerEnd: path.arrow ? `url(#${marker}-${path.tone ?? "neutral"})` : undefined }, path.key))), drawn.labels.map((item) => (_jsx("text", { x: item.x, y: item.y, className: "diagram-edge-label", children: item.text }, item.key)))] })] }) }) }) }));
|
|
140
|
+
}
|
|
141
|
+
function DiagramColumn({ className, ...props }) {
|
|
142
|
+
return _jsx("div", { ...props, "data-slot": "diagram-column", className: cn("diagram-column", className) });
|
|
143
|
+
}
|
|
144
|
+
/* A group draws several nodes as one card, split by a rule, such as the
|
|
145
|
+
container that receives requests with the other containers under it.
|
|
146
|
+
Edges still reach each node on its own. The group carries the frame, so
|
|
147
|
+
its frame props replace the nodes' own. */
|
|
148
|
+
function DiagramNodeGroup({ borderStyle, cornerStyle, cornerSize, cornerMarks, className, ...props }) {
|
|
149
|
+
return (_jsx(Card, { ...props, "data-slot": "diagram-node-group", className: cn("diagram-node-group", className), "data-border-style": borderStyle, "data-corner-style": cornerStyle, "data-corner-size": cornerSize, "data-corner-marks": cornerMarks }));
|
|
150
|
+
}
|
|
151
|
+
function DiagramNode({ id, title, kind, icon, label, accent, status, borderStyle, cornerStyle, cornerSize, cornerMarks, className, children, ...props }) {
|
|
152
|
+
const { register } = useRegistry("DiagramNode");
|
|
153
|
+
const ref = React.useCallback((element) => register(id, element), [id, register]);
|
|
154
|
+
const spec = kind ? kinds[kind] : undefined;
|
|
155
|
+
const Icon = icon ?? spec?.icon;
|
|
156
|
+
const caption = label ?? spec?.label;
|
|
157
|
+
const glyph = Icon && _jsx(Icon, { className: "icon icon-sm", strokeWidth: 1.75, "aria-hidden": "true", focusable: "false" });
|
|
158
|
+
const items = React.Children.toArray(children);
|
|
159
|
+
const text = items.filter((item) => typeof item === "string" || typeof item === "number");
|
|
160
|
+
const parts = items.filter((item) => typeof item !== "string" && typeof item !== "number");
|
|
161
|
+
return (_jsxs(Card, { ...props, ref: ref, "data-slot": "diagram-node", className: cn("diagram-node", className), "data-kind": kind, "data-tone": spec?.tone ?? "neutral", "data-accent": accent || undefined, "data-status": status, "data-border-style": borderStyle, "data-corner-style": cornerStyle, "data-corner-size": cornerSize, "data-corner-marks": cornerMarks, children: [caption && (_jsxs("span", { className: "diagram-node-kind", children: [glyph, _jsx("span", { className: "t-caps", children: caption })] })), title != null && (_jsxs("span", { className: "diagram-node-title", "data-lead": (!caption && !!glyph) || undefined, children: [!caption && glyph, title] })), text.length > 0 && _jsx("span", { className: "diagram-node-text mono", children: text }), status && (_jsx(StatusBadge, { tone: statuses[status].tone, className: "diagram-node-status", children: statuses[status].label })), parts] }));
|
|
162
|
+
}
|
|
163
|
+
/* One fact about a node as a line: its icon and name, the value on the
|
|
164
|
+
right. Long values wrap under the name before they widen the node. */
|
|
165
|
+
function DiagramFact({ icon: Icon, label, empty, className, children, ...props }) {
|
|
166
|
+
const value = children ?? null;
|
|
167
|
+
return (_jsxs("div", { ...props, "data-slot": "diagram-fact", className: cn("diagram-fact", className), children: [_jsxs("span", { className: "diagram-fact-label", children: [Icon && _jsx(Icon, { className: "icon icon-sm", strokeWidth: 1.75, "aria-hidden": "true", focusable: "false" }), label] }), value != null && value !== false
|
|
168
|
+
? _jsx("span", { className: "diagram-fact-value mono", children: value })
|
|
169
|
+
: _jsx("span", { className: "diagram-fact-value muted", children: empty })] }));
|
|
170
|
+
}
|
|
171
|
+
/* A part of a node that folds under a header. Folded, its body stays in the
|
|
172
|
+
layout with no height, so the node keeps its width and the edges do not
|
|
173
|
+
move sideways. */
|
|
174
|
+
function DiagramFold({ title, count, defaultOpen = true, className, children, ...props }) {
|
|
175
|
+
const [open, setOpen] = React.useState(defaultOpen);
|
|
176
|
+
const body = React.useId();
|
|
177
|
+
const Chevron = open ? ChevronUp : ChevronDown;
|
|
178
|
+
return (_jsxs("div", { ...props, "data-slot": "diagram-fold", className: cn("diagram-fold", className), "data-open": open, children: [_jsxs("button", { type: "button", className: "diagram-fold-head", "aria-expanded": open, "aria-controls": body, onClick: () => setOpen(!open), children: [_jsxs("span", { className: "diagram-fold-title", children: [title, count != null && _jsx(Badge, { className: "badge-count", children: count })] }), _jsx(Chevron, { className: "icon icon-sm", strokeWidth: 1.75, "aria-hidden": "true", focusable: "false" })] }), _jsx("div", { id: body, className: "diagram-fold-body", children: children })] }));
|
|
179
|
+
}
|
|
180
|
+
/* Chips that show one kind of line at a time. The first chip shows all of
|
|
181
|
+
them with their total. Render it only when there is more than one kind. */
|
|
182
|
+
function DiagramFilter({ options, value, onValueChange, className, ...props }) {
|
|
183
|
+
const total = options.reduce((sum, option) => sum + option.count, 0);
|
|
184
|
+
return (_jsxs("div", { role: "group", "aria-label": "Show", ...props, "data-slot": "diagram-filter", className: cn("diagram-filter", className), children: [_jsxs("button", { type: "button", "aria-pressed": value === null, onClick: () => onValueChange(null), children: ["All ", total] }), options.map((option) => (_jsxs("button", { type: "button", "aria-pressed": value === option.value, onClick: () => onValueChange(option.value), children: [option.label, " ", option.count] }, option.value)))] }));
|
|
185
|
+
}
|
|
186
|
+
/* One kind of thing a node lists: a heading with its count and action, and
|
|
187
|
+
its lines hanging from the heading as a tree. */
|
|
188
|
+
function DiagramSection({ title, icon: Icon, count, action, className, children, ...props }) {
|
|
189
|
+
return (_jsxs("div", { ...props, "data-slot": "diagram-section", className: cn("diagram-section", className), "data-flat": title == null || undefined, children: [title != null && (_jsxs("div", { className: "diagram-section-head", children: [_jsxs("span", { className: "diagram-section-title", children: [Icon && _jsx(Icon, { className: "icon icon-sm", strokeWidth: 1.75, "aria-hidden": "true", focusable: "false" }), title, count != null && _jsx(Badge, { className: "badge-count", children: count })] }), action] })), children] }));
|
|
190
|
+
}
|
|
191
|
+
/* One line of a section: a name in mono and, on the right, where it goes. */
|
|
192
|
+
function DiagramLine({ end, onClick, className, children, ...props }) {
|
|
193
|
+
const content = _jsxs(_Fragment, { children: [_jsx("span", { className: "diagram-line-name mono", children: children }), end != null && _jsx("span", { className: "diagram-line-end", children: end })] });
|
|
194
|
+
if (onClick) {
|
|
195
|
+
return (_jsx("button", { ...props, type: "button", "data-slot": "diagram-line", className: cn("diagram-line", className), onClick: onClick, children: content }));
|
|
196
|
+
}
|
|
197
|
+
return _jsx("div", { ...props, "data-slot": "diagram-line", className: cn("diagram-line", className), children: content });
|
|
198
|
+
}
|
|
199
|
+
/* An edge renders nothing itself: it registers with the Diagram, which draws
|
|
200
|
+
it once the nodes are measured. */
|
|
201
|
+
function DiagramEdge({ from, to, label, line, tone }) {
|
|
202
|
+
const { addEdge } = useRegistry("DiagramEdge");
|
|
203
|
+
// Ids never contain a newline, so the join is a stable dependency.
|
|
204
|
+
const sources = (Array.isArray(from) ? from : [from]).join("\n");
|
|
205
|
+
React.useEffect(() => addEdge({ key: `${sources}->${to}`, from: sources.split("\n"), to, label, line, tone }), [addEdge, sources, to, label, line, tone]);
|
|
206
|
+
return null;
|
|
207
|
+
}
|
|
208
|
+
export { Diagram, DiagramColumn, DiagramNodeGroup, DiagramNode, DiagramFact, DiagramFold, DiagramFilter, DiagramSection, DiagramLine, DiagramEdge };
|
package/dist/index.d.ts
CHANGED
|
@@ -20,6 +20,7 @@ export * from "./form-field.js";
|
|
|
20
20
|
export * from "./form.js";
|
|
21
21
|
export * from "./header.js";
|
|
22
22
|
export * from "./input.js";
|
|
23
|
+
export * from "./password-input.js";
|
|
23
24
|
export * from "./kv.js";
|
|
24
25
|
export * from "./label.js";
|
|
25
26
|
export * from "./link.js";
|
|
@@ -30,12 +31,15 @@ export * from "./pagination.js";
|
|
|
30
31
|
export * from "./popover.js";
|
|
31
32
|
export * from "./search.js";
|
|
32
33
|
export * from "./select.js";
|
|
34
|
+
export * from "./detail-select.js";
|
|
35
|
+
export type { ChartStyle } from "./chart-style.js";
|
|
33
36
|
export * from "./separator.js";
|
|
34
37
|
export * from "./sidebar.js";
|
|
35
38
|
export * from "./skeleton.js";
|
|
36
39
|
export * from "./sparkline.js";
|
|
37
40
|
export * from "./spinner.js";
|
|
38
41
|
export * from "./split.js";
|
|
42
|
+
export * from "./pane-grid.js";
|
|
39
43
|
export * from "./stat.js";
|
|
40
44
|
export * from "./switch.js";
|
|
41
45
|
export * from "./table.js";
|
|
@@ -60,3 +64,4 @@ export * from "./status-badge.js";
|
|
|
60
64
|
export * from "./steps.js";
|
|
61
65
|
export * from "./radio-group.js";
|
|
62
66
|
export * from "./file-dropzone.js";
|
|
67
|
+
export * from "./diagram.js";
|
package/dist/index.js
CHANGED
|
@@ -21,6 +21,7 @@ export * from "./form-field.js";
|
|
|
21
21
|
export * from "./form.js";
|
|
22
22
|
export * from "./header.js";
|
|
23
23
|
export * from "./input.js";
|
|
24
|
+
export * from "./password-input.js";
|
|
24
25
|
export * from "./kv.js";
|
|
25
26
|
export * from "./label.js";
|
|
26
27
|
export * from "./link.js";
|
|
@@ -31,12 +32,14 @@ export * from "./pagination.js";
|
|
|
31
32
|
export * from "./popover.js";
|
|
32
33
|
export * from "./search.js";
|
|
33
34
|
export * from "./select.js";
|
|
35
|
+
export * from "./detail-select.js";
|
|
34
36
|
export * from "./separator.js";
|
|
35
37
|
export * from "./sidebar.js";
|
|
36
38
|
export * from "./skeleton.js";
|
|
37
39
|
export * from "./sparkline.js";
|
|
38
40
|
export * from "./spinner.js";
|
|
39
41
|
export * from "./split.js";
|
|
42
|
+
export * from "./pane-grid.js";
|
|
40
43
|
export * from "./stat.js";
|
|
41
44
|
export * from "./switch.js";
|
|
42
45
|
export * from "./table.js";
|
|
@@ -61,3 +64,4 @@ export * from "./status-badge.js";
|
|
|
61
64
|
export * from "./steps.js";
|
|
62
65
|
export * from "./radio-group.js";
|
|
63
66
|
export * from "./file-dropzone.js";
|
|
67
|
+
export * from "./diagram.js";
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
export type PaneGridLayout = {
|
|
3
|
+
rows: string[][];
|
|
4
|
+
sizes: Record<string, number>;
|
|
5
|
+
};
|
|
6
|
+
export type PaneGridOverflow = "wrap" | "scroll";
|
|
7
|
+
export type PaneGridProps = Omit<React.ComponentProps<"section">, "title"> & {
|
|
8
|
+
title?: React.ReactNode;
|
|
9
|
+
layout?: PaneGridLayout;
|
|
10
|
+
defaultLayout?: PaneGridLayout;
|
|
11
|
+
onLayoutChange?: (layout: PaneGridLayout) => void;
|
|
12
|
+
flow?: "rows" | "masonry";
|
|
13
|
+
overflow?: PaneGridOverflow;
|
|
14
|
+
fill?: boolean;
|
|
15
|
+
pack?: boolean;
|
|
16
|
+
scrollPages?: number;
|
|
17
|
+
debug?: boolean;
|
|
18
|
+
};
|
|
19
|
+
export declare function PaneGrid({ title, layout: controlled, defaultLayout, onLayoutChange, overflow, flow, fill, pack, scrollPages, debug, className, children, ...props }: PaneGridProps): React.JSX.Element;
|
|
20
|
+
export type GridPaneProps = Omit<React.ComponentProps<"article">, "title" | "id"> & {
|
|
21
|
+
id: string;
|
|
22
|
+
title: string;
|
|
23
|
+
min?: number;
|
|
24
|
+
size?: number;
|
|
25
|
+
newRow?: boolean;
|
|
26
|
+
actions?: React.ReactNode;
|
|
27
|
+
};
|
|
28
|
+
export declare function GridPane({ id, title, min: _min, size: _size, newRow: _newRow, actions, className, style, children, ...props }: GridPaneProps): React.JSX.Element;
|