@tensor_1/react 2.31.0 → 2.33.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 +367 -0
- package/dist/SchedulingCalendar-C4XVbqZr.d.ts +339 -0
- package/dist/attachment-labels.d.ts +16 -0
- package/dist/attachment-labels.js +9 -0
- package/dist/calendar-model.d.ts +141 -1
- package/dist/calendar-model.js +200 -11
- package/dist/chart-preset.cjs +127 -7
- package/dist/chart-preset.d.cts +2 -2
- package/dist/chart-preset.d.ts +1 -0
- package/dist/chart-preset.js +6 -1
- package/dist/chart-theme-Cl0IrkKQ.d.cts +112 -0
- package/dist/chart-theme.d.ts +51 -0
- package/dist/chart-theme.js +99 -0
- package/dist/chart.cjs +127 -7
- package/dist/chart.d.cts +2 -2
- package/dist/chart.d.ts +1 -0
- package/dist/chart.js +6 -2
- package/dist/components/Alert.d.ts +17 -1
- package/dist/components/Alert.js +9 -4
- package/dist/components/AlertDismiss.d.ts +14 -0
- package/dist/components/AlertDismiss.js +11 -0
- package/dist/components/Attachment.d.ts +15 -12
- package/dist/components/Attachment.js +17 -17
- package/dist/components/AttachmentParts.d.ts +24 -0
- package/dist/components/AttachmentParts.js +20 -0
- package/dist/components/Chart.d.ts +1 -0
- package/dist/components/Chart.js +6 -1
- package/dist/components/ChartCore.d.ts +6 -1
- package/dist/components/ChartCore.js +23 -5
- package/dist/components/Chip.d.ts +17 -2
- package/dist/components/Chip.js +35 -11
- package/dist/components/ChipRemove.d.ts +17 -0
- package/dist/components/ChipRemove.js +13 -0
- package/dist/components/CollapsibleParts.d.ts +29 -0
- package/dist/components/CollapsibleParts.js +20 -0
- package/dist/components/CollapsibleSection.d.ts +30 -3
- package/dist/components/CollapsibleSection.js +7 -11
- package/dist/components/CollapsibleSectionState.d.ts +1 -1
- package/dist/components/CollapsibleSectionState.js +54 -27
- package/dist/components/DashboardGrid.d.ts +60 -0
- package/dist/components/DashboardGrid.js +40 -0
- package/dist/components/DateRangePicker.d.ts +7 -1
- package/dist/components/DateRangePicker.js +5 -1
- package/dist/components/DescriptionList.d.ts +12 -1
- package/dist/components/DescriptionList.js +5 -5
- package/dist/components/Dialogs.d.ts +24 -3
- package/dist/components/Dialogs.js +74 -16
- package/dist/components/FileUpload.d.ts +10 -2
- package/dist/components/FileUpload.js +10 -4
- package/dist/components/FilterEditor.d.ts +4 -0
- package/dist/components/FilterEditor.js +13 -2
- package/dist/components/Heartbeat.d.ts +31 -0
- package/dist/components/Heartbeat.js +28 -0
- package/dist/components/Menu.d.ts +53 -5
- package/dist/components/Menu.js +104 -4
- package/dist/components/Meter.d.ts +7 -3
- package/dist/components/Meter.js +2 -1
- package/dist/components/Popover.d.ts +21 -2
- package/dist/components/Popover.js +94 -17
- package/dist/components/Prose.d.ts +6 -2
- package/dist/components/Prose.js +1 -1
- package/dist/components/RuleBuilder.d.ts +52 -4
- package/dist/components/RuleBuilder.js +109 -24
- package/dist/components/SchedulingCalendar.d.ts +4 -110
- package/dist/components/SchedulingCalendar.js +299 -63
- package/dist/components/SchedulingTimeGrid.d.ts +4 -0
- package/dist/components/SchedulingTimeGrid.js +521 -0
- package/dist/components/SchedulingTimeline.d.ts +2 -1
- package/dist/components/Segmented.d.ts +17 -3
- package/dist/components/Segmented.js +59 -5
- package/dist/components/Select.d.ts +66 -2
- package/dist/components/Select.js +800 -10
- package/dist/components/Spinner.d.ts +2 -1
- package/dist/components/Spinner.js +1 -1
- package/dist/components/StatusPill.d.ts +8 -2
- package/dist/components/StatusPill.js +2 -2
- package/dist/components/Steps.d.ts +28 -4
- package/dist/components/Steps.js +46 -16
- package/dist/components/TableControls.js +4 -3
- package/dist/components/Tabs.d.ts +7 -2
- package/dist/components/Tabs.js +14 -1
- package/dist/components/TextDiff.d.ts +49 -0
- package/dist/components/TextDiff.js +124 -0
- package/dist/{emoji-image-6mPZ15Zy.d.cts → emoji-image-DjCKpdwE.d.cts} +1 -1
- package/dist/emoji.cjs +169 -27
- package/dist/emoji.d.cts +3 -3
- package/dist/file-model.d.ts +22 -3
- package/dist/file-model.js +6 -4
- package/dist/filter-model.d.ts +26 -2
- package/dist/filter-model.js +13 -1
- package/dist/hooks/useAnchoredPosition.d.ts +24 -1
- package/dist/hooks/useAnchoredPosition.js +58 -8
- package/dist/hooks/useVirtualRows.d.ts +17 -2
- package/dist/hooks/useVirtualRows.js +6 -5
- package/dist/icons/Icon.d.ts +14 -14
- package/dist/index.cjs +4888 -1714
- package/dist/index.d.cts +1871 -658
- package/dist/index.d.ts +16 -9
- package/dist/index.js +67 -4
- package/dist/labels-context.d.ts +29 -1
- package/dist/{overlay-position-Cjv5E7mn.d.cts → overlay-position-2Afke51l.d.cts} +20 -0
- package/dist/overlay-position.d.ts +20 -0
- package/dist/overlay-position.js +17 -2
- package/dist/rich-text.cjs +169 -27
- package/dist/rich-text.d.cts +3 -3
- package/dist/rule-builder-model.d.ts +34 -2
- package/dist/rule-builder-model.js +48 -12
- package/dist/scheduling-calendar-model.d.ts +169 -0
- package/dist/scheduling-calendar-model.js +176 -0
- package/dist/select-model.d.ts +80 -0
- package/dist/select-model.js +109 -0
- package/dist/table-engine.d.ts +7 -0
- package/dist/table-engine.js +2 -1
- package/dist/text-diff-model.d.ts +71 -0
- package/dist/text-diff-model.js +261 -0
- package/package.json +1 -1
- package/dist/ChartCore-DzWe10bN.d.cts +0 -59
|
@@ -0,0 +1,261 @@
|
|
|
1
|
+
const WORD_TOKENS = /\s+|[\p{L}\p{M}\p{N}_]+|[^\s\p{L}\p{M}\p{N}_]/gu;
|
|
2
|
+
function tokenizeText(text, granularity) {
|
|
3
|
+
if (granularity === "line") return text === "" ? [] : text.split("\n").map((line) => line.endsWith("\r") ? line.slice(0, -1) : line);
|
|
4
|
+
return text.match(WORD_TOKENS) ?? [];
|
|
5
|
+
}
|
|
6
|
+
function myers(a, b, maxEdits) {
|
|
7
|
+
const n = a.length;
|
|
8
|
+
const m = b.length;
|
|
9
|
+
const limit = Math.min(n + m, maxEdits);
|
|
10
|
+
const offset = limit + 1;
|
|
11
|
+
const v = new Int32Array(2 * limit + 3);
|
|
12
|
+
const trace = [];
|
|
13
|
+
let found = -1;
|
|
14
|
+
for (let d = 0; d <= limit && found < 0; d += 1) {
|
|
15
|
+
for (let k = -d; k <= d; k += 2) {
|
|
16
|
+
let x2 = k === -d || k !== d && v[offset + k - 1] < v[offset + k + 1] ? v[offset + k + 1] : v[offset + k - 1] + 1;
|
|
17
|
+
let y2 = x2 - k;
|
|
18
|
+
while (x2 < n && y2 < m && a[x2] === b[y2]) {
|
|
19
|
+
x2 += 1;
|
|
20
|
+
y2 += 1;
|
|
21
|
+
}
|
|
22
|
+
v[offset + k] = x2;
|
|
23
|
+
if (x2 >= n && y2 >= m) {
|
|
24
|
+
found = d;
|
|
25
|
+
break;
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
trace.push(v.slice(offset - d, offset + d + 1));
|
|
29
|
+
}
|
|
30
|
+
if (found < 0) return null;
|
|
31
|
+
const steps = [];
|
|
32
|
+
let x = n;
|
|
33
|
+
let y = m;
|
|
34
|
+
for (let d = found; d > 0; d -= 1) {
|
|
35
|
+
const prev = trace[d - 1];
|
|
36
|
+
const at = (k2) => prev[k2 + d - 1];
|
|
37
|
+
const k = x - y;
|
|
38
|
+
const prevK = k === -d || k !== d && at(k - 1) < at(k + 1) ? k + 1 : k - 1;
|
|
39
|
+
const prevX = at(prevK);
|
|
40
|
+
const prevY = prevX - prevK;
|
|
41
|
+
while (x > prevX && y > prevY) {
|
|
42
|
+
steps.push("equal");
|
|
43
|
+
x -= 1;
|
|
44
|
+
y -= 1;
|
|
45
|
+
}
|
|
46
|
+
if (x === prevX) {
|
|
47
|
+
steps.push("insert");
|
|
48
|
+
y -= 1;
|
|
49
|
+
} else {
|
|
50
|
+
steps.push("delete");
|
|
51
|
+
x -= 1;
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
while (x > 0 && y > 0) {
|
|
55
|
+
steps.push("equal");
|
|
56
|
+
x -= 1;
|
|
57
|
+
y -= 1;
|
|
58
|
+
}
|
|
59
|
+
return steps.reverse();
|
|
60
|
+
}
|
|
61
|
+
function push(ops, type, token) {
|
|
62
|
+
const last = ops[ops.length - 1];
|
|
63
|
+
if (last?.type === type) last.tokens.push(token);
|
|
64
|
+
else ops.push({ type, tokens: [token] });
|
|
65
|
+
}
|
|
66
|
+
function normalize(ops) {
|
|
67
|
+
const out = [];
|
|
68
|
+
let del = [];
|
|
69
|
+
let ins = [];
|
|
70
|
+
const flush = () => {
|
|
71
|
+
if (del.length) out.push({ type: "delete", tokens: del });
|
|
72
|
+
if (ins.length) out.push({ type: "insert", tokens: ins });
|
|
73
|
+
del = [];
|
|
74
|
+
ins = [];
|
|
75
|
+
};
|
|
76
|
+
for (const op of ops) {
|
|
77
|
+
if (op.type === "delete") del = del.concat(op.tokens);
|
|
78
|
+
else if (op.type === "insert") ins = ins.concat(op.tokens);
|
|
79
|
+
else {
|
|
80
|
+
flush();
|
|
81
|
+
const last = out[out.length - 1];
|
|
82
|
+
if (last?.type === "equal") last.tokens.push(...op.tokens);
|
|
83
|
+
else out.push({ type: "equal", tokens: [...op.tokens] });
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
flush();
|
|
87
|
+
return out;
|
|
88
|
+
}
|
|
89
|
+
function absorbSpaces(ops) {
|
|
90
|
+
const out = ops.map((op) => ({ ...op, tokens: [...op.tokens] }));
|
|
91
|
+
for (let i = 1; i < out.length - 1; i += 1) {
|
|
92
|
+
const op = out[i];
|
|
93
|
+
if (op.type === "equal" && out[i - 1].type !== "equal" && out[i + 1].type !== "equal" && op.tokens.every((t) => /^\s+$/.test(t))) {
|
|
94
|
+
out.splice(i, 1, { type: "delete", tokens: op.tokens }, { type: "insert", tokens: [...op.tokens] });
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
return normalize(out);
|
|
98
|
+
}
|
|
99
|
+
function diffTokens(a, b, maxEdits = 2e3) {
|
|
100
|
+
let start = 0;
|
|
101
|
+
while (start < a.length && start < b.length && a[start] === b[start]) start += 1;
|
|
102
|
+
let endA = a.length;
|
|
103
|
+
let endB = b.length;
|
|
104
|
+
while (endA > start && endB > start && a[endA - 1] === b[endB - 1]) {
|
|
105
|
+
endA -= 1;
|
|
106
|
+
endB -= 1;
|
|
107
|
+
}
|
|
108
|
+
const ids = /* @__PURE__ */ new Map();
|
|
109
|
+
const id = (t) => {
|
|
110
|
+
let v = ids.get(t);
|
|
111
|
+
if (v === void 0) {
|
|
112
|
+
v = ids.size;
|
|
113
|
+
ids.set(t, v);
|
|
114
|
+
}
|
|
115
|
+
return v;
|
|
116
|
+
};
|
|
117
|
+
const midA = a.slice(start, endA);
|
|
118
|
+
const midB = b.slice(start, endB);
|
|
119
|
+
const steps = myers(midA.map(id), midB.map(id), maxEdits);
|
|
120
|
+
const ops = [];
|
|
121
|
+
for (const t of a.slice(0, start)) push(ops, "equal", t);
|
|
122
|
+
if (steps) {
|
|
123
|
+
let i = 0;
|
|
124
|
+
let j = 0;
|
|
125
|
+
for (const step of steps) {
|
|
126
|
+
if (step === "equal") {
|
|
127
|
+
push(ops, "equal", midA[i]);
|
|
128
|
+
i += 1;
|
|
129
|
+
j += 1;
|
|
130
|
+
} else if (step === "delete") {
|
|
131
|
+
push(ops, "delete", midA[i]);
|
|
132
|
+
i += 1;
|
|
133
|
+
} else {
|
|
134
|
+
push(ops, "insert", midB[j]);
|
|
135
|
+
j += 1;
|
|
136
|
+
}
|
|
137
|
+
}
|
|
138
|
+
} else {
|
|
139
|
+
for (const t of midA) push(ops, "delete", t);
|
|
140
|
+
for (const t of midB) push(ops, "insert", t);
|
|
141
|
+
}
|
|
142
|
+
for (const t of a.slice(endA)) push(ops, "equal", t);
|
|
143
|
+
return normalize(ops);
|
|
144
|
+
}
|
|
145
|
+
const counts = (tokens, granularity) => granularity === "line" ? tokens.length : tokens.filter((t) => /[\p{L}\p{N}]/u.test(t)).length;
|
|
146
|
+
function diffText(before, after, { granularity = "line", maxTokens = 2e4, maxEdits = 2e3 } = {}) {
|
|
147
|
+
const a = tokenizeText(before, granularity);
|
|
148
|
+
const b = tokenizeText(after, granularity);
|
|
149
|
+
if (a.length > maxTokens || b.length > maxTokens) return { status: "too-large", granularity, ops: [], added: 0, removed: 0 };
|
|
150
|
+
let ops = diffTokens(a, b, maxEdits);
|
|
151
|
+
if (granularity === "word") ops = absorbSpaces(ops);
|
|
152
|
+
let added = 0;
|
|
153
|
+
let removed = 0;
|
|
154
|
+
for (const op of ops) {
|
|
155
|
+
if (op.type === "insert") added += counts(op.tokens, granularity);
|
|
156
|
+
if (op.type === "delete") removed += counts(op.tokens, granularity);
|
|
157
|
+
}
|
|
158
|
+
return { status: "ok", granularity, ops, added, removed };
|
|
159
|
+
}
|
|
160
|
+
const SIMILAR = 0.4;
|
|
161
|
+
function compareLines(before, after) {
|
|
162
|
+
const longest = Math.max(before.length, after.length);
|
|
163
|
+
if (longest === 0) return { similarity: 1, left: [{ text: "", changed: false }], right: [{ text: "", changed: false }] };
|
|
164
|
+
if (before.length + after.length > 4e3) return { similarity: 0, left: [{ text: before, changed: true }], right: [{ text: after, changed: true }] };
|
|
165
|
+
const { ops } = diffText(before, after, { granularity: "word", maxEdits: 400 });
|
|
166
|
+
const left = [];
|
|
167
|
+
const right = [];
|
|
168
|
+
let same = 0;
|
|
169
|
+
for (const op of ops) {
|
|
170
|
+
const text = op.tokens.join("");
|
|
171
|
+
if (op.type === "equal") {
|
|
172
|
+
same += text.replace(/\s/g, "").length;
|
|
173
|
+
left.push({ text, changed: false });
|
|
174
|
+
right.push({ text, changed: false });
|
|
175
|
+
} else (op.type === "delete" ? left : right).push({ text, changed: true });
|
|
176
|
+
}
|
|
177
|
+
const visible = Math.max(before.replace(/\s/g, "").length, after.replace(/\s/g, "").length) || 1;
|
|
178
|
+
return { similarity: same / visible, left, right };
|
|
179
|
+
}
|
|
180
|
+
function alignBlock(deleted, inserted) {
|
|
181
|
+
const n = deleted.length;
|
|
182
|
+
const m = inserted.length;
|
|
183
|
+
const out = [];
|
|
184
|
+
if (n * m > 2500) {
|
|
185
|
+
deleted.forEach((_, i2) => out.push([i2, null, null]));
|
|
186
|
+
inserted.forEach((_, j2) => out.push([null, j2, null]));
|
|
187
|
+
return out;
|
|
188
|
+
}
|
|
189
|
+
const cmp = deleted.map((d) => inserted.map((i2) => compareLines(d, i2)));
|
|
190
|
+
const score = Array.from({ length: n + 1 }, () => new Float64Array(m + 1));
|
|
191
|
+
for (let i2 = n - 1; i2 >= 0; i2 -= 1) {
|
|
192
|
+
for (let j2 = m - 1; j2 >= 0; j2 -= 1) {
|
|
193
|
+
const sim = cmp[i2][j2].similarity;
|
|
194
|
+
score[i2][j2] = Math.max(score[i2 + 1][j2], score[i2][j2 + 1], sim >= SIMILAR ? sim + score[i2 + 1][j2 + 1] : 0);
|
|
195
|
+
}
|
|
196
|
+
}
|
|
197
|
+
let i = 0;
|
|
198
|
+
let j = 0;
|
|
199
|
+
while (i < n || j < m) {
|
|
200
|
+
if (i < n && j < m && cmp[i][j].similarity >= SIMILAR && score[i][j] === cmp[i][j].similarity + score[i + 1][j + 1]) {
|
|
201
|
+
out.push([i, j, cmp[i][j]]);
|
|
202
|
+
i += 1;
|
|
203
|
+
j += 1;
|
|
204
|
+
} else if (i < n && (j >= m || score[i][j] === score[i + 1][j])) {
|
|
205
|
+
out.push([i, null, null]);
|
|
206
|
+
i += 1;
|
|
207
|
+
} else {
|
|
208
|
+
out.push([null, j, null]);
|
|
209
|
+
j += 1;
|
|
210
|
+
}
|
|
211
|
+
}
|
|
212
|
+
return out;
|
|
213
|
+
}
|
|
214
|
+
function textDiffRows(result, { context } = {}) {
|
|
215
|
+
const rows = [];
|
|
216
|
+
let left = 1;
|
|
217
|
+
let right = 1;
|
|
218
|
+
const ops = result.ops;
|
|
219
|
+
for (let i = 0; i < ops.length; i += 1) {
|
|
220
|
+
const op = ops[i];
|
|
221
|
+
if (op.type === "equal") {
|
|
222
|
+
for (const text of op.tokens) rows.push({ kind: "equal", before: { number: left++, segments: [{ text, changed: false }] }, after: { number: right++, segments: [{ text, changed: false }] } });
|
|
223
|
+
continue;
|
|
224
|
+
}
|
|
225
|
+
const deleted = op.type === "delete" ? op.tokens : [];
|
|
226
|
+
const inserted = op.type === "insert" ? op.tokens : ops[i + 1]?.type === "insert" ? ops[i + 1].tokens : [];
|
|
227
|
+
if (op.type === "delete" && ops[i + 1]?.type === "insert") i += 1;
|
|
228
|
+
for (const [d, n, pair] of alignBlock(deleted, inserted)) {
|
|
229
|
+
if (pair && d !== null && n !== null) rows.push({ kind: "change", before: { number: left++, segments: pair.left }, after: { number: right++, segments: pair.right } });
|
|
230
|
+
else if (d !== null) rows.push({ kind: "delete", before: { number: left++, segments: [{ text: deleted[d], changed: true }] } });
|
|
231
|
+
else if (n !== null) rows.push({ kind: "insert", after: { number: right++, segments: [{ text: inserted[n], changed: true }] } });
|
|
232
|
+
}
|
|
233
|
+
}
|
|
234
|
+
if (context === void 0 || context < 0) return rows;
|
|
235
|
+
const out = [];
|
|
236
|
+
for (let i = 0; i < rows.length; ) {
|
|
237
|
+
if (rows[i].kind !== "equal") {
|
|
238
|
+
out.push(rows[i]);
|
|
239
|
+
i += 1;
|
|
240
|
+
continue;
|
|
241
|
+
}
|
|
242
|
+
let j = i;
|
|
243
|
+
while (j < rows.length && rows[j].kind === "equal") j += 1;
|
|
244
|
+
const keepHead = i === 0 ? 0 : context;
|
|
245
|
+
const keepTail = j === rows.length ? 0 : context;
|
|
246
|
+
const hidden = j - i - keepHead - keepTail;
|
|
247
|
+
if (hidden > 1) {
|
|
248
|
+
out.push(...rows.slice(i, i + keepHead));
|
|
249
|
+
out.push({ kind: "fold", count: hidden, rows: rows.slice(i + keepHead, j - keepTail) });
|
|
250
|
+
out.push(...rows.slice(j - keepTail, j));
|
|
251
|
+
} else out.push(...rows.slice(i, j));
|
|
252
|
+
i = j;
|
|
253
|
+
}
|
|
254
|
+
return out;
|
|
255
|
+
}
|
|
256
|
+
export {
|
|
257
|
+
diffText,
|
|
258
|
+
diffTokens,
|
|
259
|
+
textDiffRows,
|
|
260
|
+
tokenizeText
|
|
261
|
+
};
|
package/package.json
CHANGED
|
@@ -1,59 +0,0 @@
|
|
|
1
|
-
import * as react from 'react';
|
|
2
|
-
import { CSSProperties, ReactNode, HTMLAttributes } from 'react';
|
|
3
|
-
import { EChartsOption, ECharts } from 'echarts';
|
|
4
|
-
|
|
5
|
-
declare function uixChartPalette(): string[];
|
|
6
|
-
interface ChartTableRow {
|
|
7
|
-
[key: string]: string | number;
|
|
8
|
-
}
|
|
9
|
-
/**
|
|
10
|
-
* Every word the chart renders itself (TENSOR RX-125, UIX-04 / UIX-05). The
|
|
11
|
-
* loading text used to live in CSS `content:`, where nothing could translate it.
|
|
12
|
-
*/
|
|
13
|
-
interface ChartLabels {
|
|
14
|
-
/** Shown (and announced inside the busy region) while `loading`. */
|
|
15
|
-
loading: ReactNode;
|
|
16
|
-
/** Accessible name when neither `ariaLabel` nor `title` is given. */
|
|
17
|
-
chart: string;
|
|
18
|
-
/** Appended to the chart's name for its data-table alternative. */
|
|
19
|
-
dataTableSuffix: string;
|
|
20
|
-
}
|
|
21
|
-
declare const DEFAULT_CHART_LABELS: ChartLabels;
|
|
22
|
-
interface ChartProps {
|
|
23
|
-
option: EChartsOption;
|
|
24
|
-
title?: string;
|
|
25
|
-
subtitle?: string;
|
|
26
|
-
height?: string | number;
|
|
27
|
-
className?: string;
|
|
28
|
-
style?: CSSProperties;
|
|
29
|
-
ariaLabel?: string;
|
|
30
|
-
tableData?: ChartTableRow[];
|
|
31
|
-
tableHeaders?: string[];
|
|
32
|
-
onReady?: (chart: ECharts) => void;
|
|
33
|
-
header?: ReactNode;
|
|
34
|
-
headerAction?: ReactNode;
|
|
35
|
-
footer?: ReactNode;
|
|
36
|
-
loading?: boolean;
|
|
37
|
-
empty?: ReactNode;
|
|
38
|
-
/** Translatable words; English defaults in {@link DEFAULT_CHART_LABELS}. */
|
|
39
|
-
labels?: Partial<ChartLabels>;
|
|
40
|
-
}
|
|
41
|
-
interface ChartMetricProps extends HTMLAttributes<HTMLDivElement> {
|
|
42
|
-
value: ReactNode;
|
|
43
|
-
label?: ReactNode;
|
|
44
|
-
delta?: ReactNode;
|
|
45
|
-
deltaTone?: 'neutral' | 'positive' | 'negative' | 'warning';
|
|
46
|
-
}
|
|
47
|
-
declare function ChartMetric({ value, label, delta, deltaTone, className, ...props }: ChartMetricProps): react.JSX.Element;
|
|
48
|
-
interface ChartLegendProps extends HTMLAttributes<HTMLUListElement> {
|
|
49
|
-
children?: ReactNode;
|
|
50
|
-
}
|
|
51
|
-
declare function ChartLegend({ children, className, ...props }: ChartLegendProps): react.JSX.Element;
|
|
52
|
-
interface ChartLegendItemProps extends HTMLAttributes<HTMLLIElement> {
|
|
53
|
-
label: ReactNode;
|
|
54
|
-
color?: string;
|
|
55
|
-
swatch?: 'block' | 'line' | 'dash';
|
|
56
|
-
}
|
|
57
|
-
declare function ChartLegendItem({ label, color, swatch, className, style, ...props }: ChartLegendItemProps): react.JSX.Element;
|
|
58
|
-
|
|
59
|
-
export { type ChartProps as C, DEFAULT_CHART_LABELS as D, type ChartLabels as a, ChartLegend as b, ChartLegendItem as c, type ChartLegendItemProps as d, type ChartLegendProps as e, ChartMetric as f, type ChartMetricProps as g, type ChartTableRow as h, uixChartPalette as u };
|