@pixerate/editor 0.156.0 → 0.158.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/agent/index.cjs +34 -34
- package/dist/agent/index.js +5 -5
- package/dist/canvas/index.cjs +6 -6
- package/dist/canvas/index.js +2 -2
- package/dist/chart/index.cjs +90 -88
- package/dist/chart/index.js +9 -7
- package/dist/chart/spec.d.cts +2 -1
- package/dist/chart/spec.d.ts +2 -1
- package/dist/chart/types.d.cts +5 -0
- package/dist/chart/types.d.ts +5 -0
- package/dist/{chunk-CD7PLU77.cjs → chunk-3YDQLQH2.cjs} +3 -1
- package/dist/{chunk-2WDZI6QD.cjs → chunk-4T44CJ5K.cjs} +15 -15
- package/dist/{chunk-XTU6QO2W.cjs → chunk-4YWAEV4W.cjs} +36 -27
- package/dist/{chunk-4YQKRHMI.cjs → chunk-57JLBGJ5.cjs} +8 -8
- package/dist/{chunk-SVINJIGK.js → chunk-5QBRAIVK.js} +3 -3
- package/dist/{chunk-R3PECGTQ.cjs → chunk-6LUYFHHN.cjs} +51 -51
- package/dist/{chunk-ZQWLWDZI.js → chunk-72BGL3I2.js} +2 -0
- package/dist/{chunk-ML2II3Y3.cjs → chunk-AKDWAWSY.cjs} +58 -46
- package/dist/{chunk-EQ4SF4X4.js → chunk-DBIVICAO.js} +1 -1
- package/dist/{chunk-SUVZJ2CP.js → chunk-H5XX4KHB.js} +11 -1
- package/dist/{chunk-37RLSNQ3.js → chunk-Q6PA362P.js} +2 -2
- package/dist/{chunk-DSZCDNTM.js → chunk-R3QY7PPL.js} +11 -2
- package/dist/{chunk-4RF2H3N3.js → chunk-SSCL7QQ4.js} +15 -3
- package/dist/{chunk-TLMRGLQQ.cjs → chunk-TVO6W2Q6.cjs} +20 -17
- package/dist/{chunk-EIUTJPEL.js → chunk-UM3RPYC5.js} +5 -2
- package/dist/{chunk-I4AHLP7F.cjs → chunk-WPPJH6X4.cjs} +12 -2
- package/dist/{chunk-RZJCYJWO.cjs → chunk-XNQ5EFB4.cjs} +16 -16
- package/dist/{chunk-R6HNWN7B.js → chunk-YABNLNY7.js} +3 -3
- package/dist/export/index.cjs +4 -4
- package/dist/export/index.js +3 -3
- package/dist/extensions/index.cjs +7 -7
- package/dist/extensions/index.js +6 -6
- package/dist/image-editor/controller.d.cts +24 -1
- package/dist/image-editor/controller.d.ts +24 -1
- package/dist/image-editor/controls.d.cts +9 -0
- package/dist/image-editor/controls.d.ts +9 -0
- package/dist/image-editor/index.cjs +7699 -7446
- package/dist/image-editor/index.js +11053 -10800
- package/dist/image-editor/layers/panel.d.cts +24 -0
- package/dist/image-editor/layers/panel.d.ts +24 -0
- package/dist/image-editor/layers/smart.d.cts +2 -0
- package/dist/image-editor/layers/smart.d.ts +2 -0
- package/dist/image-editor/transform.d.cts +1 -0
- package/dist/image-editor/transform.d.ts +1 -0
- package/dist/index.cjs +13 -13
- package/dist/index.js +7 -7
- package/dist/paint-editor/index.cjs +6 -6
- package/dist/paint-editor/index.js +1 -1
- package/package.json +1 -1
- package/skills/pixerate-chart/SKILL.md +4 -1
package/dist/chart/index.cjs
CHANGED
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
|
|
8
8
|
|
|
9
9
|
|
|
10
|
-
var
|
|
10
|
+
var _chunkTVO6W2Q6cjs = require('../chunk-TVO6W2Q6.cjs');
|
|
11
11
|
|
|
12
12
|
|
|
13
13
|
|
|
@@ -15,7 +15,7 @@ var _chunkTLMRGLQQcjs = require('../chunk-TLMRGLQQ.cjs');
|
|
|
15
15
|
|
|
16
16
|
|
|
17
17
|
|
|
18
|
-
var
|
|
18
|
+
var _chunk4T44CJ5Kcjs = require('../chunk-4T44CJ5K.cjs');
|
|
19
19
|
|
|
20
20
|
|
|
21
21
|
|
|
@@ -37,7 +37,7 @@ var _chunk2WDZI6QDcjs = require('../chunk-2WDZI6QD.cjs');
|
|
|
37
37
|
|
|
38
38
|
|
|
39
39
|
|
|
40
|
-
var
|
|
40
|
+
var _chunkAKDWAWSYcjs = require('../chunk-AKDWAWSY.cjs');
|
|
41
41
|
|
|
42
42
|
|
|
43
43
|
|
|
@@ -76,7 +76,7 @@ var _chunkML2II3Y3cjs = require('../chunk-ML2II3Y3.cjs');
|
|
|
76
76
|
|
|
77
77
|
|
|
78
78
|
|
|
79
|
-
var
|
|
79
|
+
var _chunk4YWAEV4Wcjs = require('../chunk-4YWAEV4W.cjs');
|
|
80
80
|
|
|
81
81
|
|
|
82
82
|
|
|
@@ -137,7 +137,8 @@ var _chunkXTU6QO2Wcjs = require('../chunk-XTU6QO2W.cjs');
|
|
|
137
137
|
|
|
138
138
|
|
|
139
139
|
|
|
140
|
-
|
|
140
|
+
|
|
141
|
+
var _chunkWPPJH6X4cjs = require('../chunk-WPPJH6X4.cjs');
|
|
141
142
|
require('../chunk-55AKPTLM.cjs');
|
|
142
143
|
|
|
143
144
|
|
|
@@ -269,7 +270,7 @@ function chartFileName(spec, extension) {
|
|
|
269
270
|
}
|
|
270
271
|
async function downloadChartPng(spec, options = {}) {
|
|
271
272
|
const { width = 800, height = 450, filename = chartFileName(spec, "png"), theme, ...raster } = options;
|
|
272
|
-
const svg =
|
|
273
|
+
const svg = _chunkAKDWAWSYcjs.chartToSvg.call(void 0, spec, { width, height, theme });
|
|
273
274
|
const { url, width: w, height: h } = await svgToPngDataUrl(svg, { ...raster, width, height });
|
|
274
275
|
const doc = _nullishCoalesce(raster.document, () => ( globalThis.document));
|
|
275
276
|
const link = doc.createElement("a");
|
|
@@ -284,7 +285,7 @@ async function downloadChartPng(spec, options = {}) {
|
|
|
284
285
|
|
|
285
286
|
// src/chart/recommend.ts
|
|
286
287
|
var blank = (c) => c === null || c === void 0 || String(c).trim() === "";
|
|
287
|
-
var isText = (c) => blank(c) ||
|
|
288
|
+
var isText = (c) => blank(c) || _chunkWPPJH6X4cjs.parseChartValue.call(void 0, c) === void 0;
|
|
288
289
|
function analyzeChartTable(rows) {
|
|
289
290
|
const grid = rows.filter((r) => r.some((c) => !blank(c)));
|
|
290
291
|
const height = grid.length;
|
|
@@ -302,7 +303,7 @@ function analyzeChartTable(rows) {
|
|
|
302
303
|
let anyPositive = false;
|
|
303
304
|
for (let r = headerRow ? 1 : 0; r < height; r++)
|
|
304
305
|
for (let c = labelColumn ? 1 : 0; c < width; c++) {
|
|
305
|
-
const v =
|
|
306
|
+
const v = _chunkWPPJH6X4cjs.parseChartValue.call(void 0, cell(r, c));
|
|
306
307
|
if (typeof v !== "number") continue;
|
|
307
308
|
anyNumber = true;
|
|
308
309
|
if (v < 0) {
|
|
@@ -311,7 +312,7 @@ function analyzeChartTable(rows) {
|
|
|
311
312
|
} else if (v > 0) anyPositive = true;
|
|
312
313
|
}
|
|
313
314
|
const labels = byRows ? _nullishCoalesce(_optionalChain([grid, 'access', _20 => _20[0], 'optionalAccess', _21 => _21.slice, 'call', _22 => _22(labelColumn ? 1 : 0)]), () => ( [])) : grid.slice(headerRow ? 1 : 0).map((r) => r[0]);
|
|
314
|
-
const dates = (byRows ? headerRow : labelColumn) && labels.length > 1 && labels.filter((l) => !blank(l) &&
|
|
315
|
+
const dates = (byRows ? headerRow : labelColumn) && labels.length > 1 && labels.filter((l) => !blank(l) && _chunk4YWAEV4Wcjs.parseChartDate.call(void 0, String(l)) !== null).length >= labels.length * 0.8;
|
|
315
316
|
return {
|
|
316
317
|
headerRow,
|
|
317
318
|
labelColumn,
|
|
@@ -398,7 +399,7 @@ function chartFromTable(rows, options = {}) {
|
|
|
398
399
|
if (xFromFirst) {
|
|
399
400
|
table = table.map((r) => [r[1], ...r.slice(2)]);
|
|
400
401
|
}
|
|
401
|
-
const data =
|
|
402
|
+
const data = _chunkWPPJH6X4cjs.chartDataFromTable.call(void 0, table, { seriesIn: shape.byRows ? "rows" : "columns", header: true, xFromFirstColumn: xFromFirst });
|
|
402
403
|
return { type, stacking, categories: data.categories, series: data.series, issues: data.issues, shape };
|
|
403
404
|
}
|
|
404
405
|
|
|
@@ -434,10 +435,10 @@ function createChartCommands(controller, options = {}) {
|
|
|
434
435
|
readOnly: true,
|
|
435
436
|
keywords: ["chart", "data", "spec", "get", "summary"],
|
|
436
437
|
description: "Returns the chart spec, its data as a table (series names in the header row) and a summary: per-series min / max / mean / trend, axes as drawn, layout warnings and a colour check.",
|
|
437
|
-
params: object({ width:
|
|
438
|
+
params: object({ width: _chunkTVO6W2Q6cjs.WIDTH, height: _chunkTVO6W2Q6cjs.HEIGHT }),
|
|
438
439
|
run: (_ctx, params = {}) => {
|
|
439
440
|
const spec = controller.getSpec();
|
|
440
|
-
return { spec: controller.toJSON(), table:
|
|
441
|
+
return { spec: controller.toJSON(), table: _chunkWPPJH6X4cjs.chartDataToTable.call(void 0, spec), summary: _chunkAKDWAWSYcjs.summarizeChart.call(void 0, controller.toJSON(), { width: _nullishCoalesce(_optionalChain([params, 'optionalAccess', _25 => _25.width]), () => ( 640)), height: _nullishCoalesce(_optionalChain([params, 'optionalAccess', _26 => _26.height]), () => ( 400)) }), issues: controller.getState().issues };
|
|
441
442
|
}
|
|
442
443
|
},
|
|
443
444
|
{
|
|
@@ -445,8 +446,8 @@ function createChartCommands(controller, options = {}) {
|
|
|
445
446
|
id: `${prefix}update`,
|
|
446
447
|
label: "Change Chart\u2026",
|
|
447
448
|
keywords: ["chart", "title", "axis", "legend", "stack", "style", "format", "type"],
|
|
448
|
-
description: 'Changes chart presentation as one undo step: type, titles, axes (xAxis = categories, yAxis = values, yAxis2 = secondary values; reverse, and scale "log" on value axes), legend, stacking, orientation, curve, points, data labels, palette, donut hole, bar spacing, histogram bins or
|
|
449
|
-
params: object(
|
|
449
|
+
description: 'Changes chart presentation as one undo step: type, titles, axes (xAxis = categories, yAxis = values, yAxis2 = secondary values; reverse, and scale "log" on value axes), legend, stacking, orientation, curve, points, data labels, palette, donut hole, bar spacing, histogram bins, waterfall total, or radar rings and grid shape. Invalid values change nothing and return why.',
|
|
450
|
+
params: object(_chunkTVO6W2Q6cjs.CHART_UPDATE_PROPERTIES),
|
|
450
451
|
run: (_ctx, params) => {
|
|
451
452
|
check(controller.update(params));
|
|
452
453
|
return { spec: controller.toJSON() };
|
|
@@ -460,11 +461,11 @@ function createChartCommands(controller, options = {}) {
|
|
|
460
461
|
description: "Replaces the categories and series as one undo step. Each series has one value per category (padded with gaps).",
|
|
461
462
|
params: object({
|
|
462
463
|
categories: { type: "array", items: { type: "string" }, description: "Category labels in order." },
|
|
463
|
-
series: { type: "array", description: "The new series.", items: object({ id: { type: "string", description: "Stable id (optional)." }, ...
|
|
464
|
+
series: { type: "array", description: "The new series.", items: object({ id: { type: "string", description: "Stable id (optional)." }, ..._chunkTVO6W2Q6cjs.SERIES_PROPS }, ["name", "values"]) }
|
|
464
465
|
}),
|
|
465
466
|
run: (_ctx, params) => {
|
|
466
467
|
check(controller.setData(params));
|
|
467
|
-
return { table:
|
|
468
|
+
return { table: _chunkWPPJH6X4cjs.chartDataToTable.call(void 0, controller.getSpec()) };
|
|
468
469
|
}
|
|
469
470
|
},
|
|
470
471
|
{
|
|
@@ -473,10 +474,10 @@ function createChartCommands(controller, options = {}) {
|
|
|
473
474
|
label: "Set Chart Values\u2026",
|
|
474
475
|
keywords: ["chart", "value", "cell", "edit"],
|
|
475
476
|
description: "Sets individual values as one undo step. Series by id or name; category by index or label.",
|
|
476
|
-
params: object({ cells: { type: "array", minItems: 1, description: "Values to set.", items: object({ series:
|
|
477
|
+
params: object({ cells: { type: "array", minItems: 1, description: "Values to set.", items: object({ series: _chunkTVO6W2Q6cjs.SERIES_REF, category: _chunkTVO6W2Q6cjs.CATEGORY_REF, value: _chunkTVO6W2Q6cjs.VALUE }, ["series", "category", "value"]) } }, ["cells"]),
|
|
477
478
|
run: (_ctx, params) => {
|
|
478
479
|
check(controller.setValues(params.cells.map((c) => ({ seriesId: resolveSeries(c.series).id, index: resolveCategory(c.category), value: c.value }))));
|
|
479
|
-
return { table:
|
|
480
|
+
return { table: _chunkWPPJH6X4cjs.chartDataToTable.call(void 0, controller.getSpec()) };
|
|
480
481
|
}
|
|
481
482
|
},
|
|
482
483
|
{
|
|
@@ -485,7 +486,7 @@ function createChartCommands(controller, options = {}) {
|
|
|
485
486
|
label: "Add Series",
|
|
486
487
|
keywords: ["chart", "series", "new"],
|
|
487
488
|
description: "Adds a series (default: an empty one at the end). Returns its id.",
|
|
488
|
-
params: object({ ...
|
|
489
|
+
params: object({ ..._chunkTVO6W2Q6cjs.SERIES_PROPS, id: { type: "string", description: "Id to use (default series-N)." }, at: { type: "integer", minimum: 0, description: "Position (default: last)." } }),
|
|
489
490
|
run: (_ctx, params = {}) => {
|
|
490
491
|
const { at, ...input } = _nullishCoalesce(params, () => ( {}));
|
|
491
492
|
const clean = Object.fromEntries(Object.entries(input).filter(([, v]) => v !== null));
|
|
@@ -500,7 +501,7 @@ function createChartCommands(controller, options = {}) {
|
|
|
500
501
|
label: "Change Series\u2026",
|
|
501
502
|
keywords: ["chart", "series", "rename", "colour", "color", "hide", "axis", "marker"],
|
|
502
503
|
description: "Renames, recolours, hides, moves to the secondary axis or changes how a series is drawn, including error bars (null resets a field).",
|
|
503
|
-
params: object({ series:
|
|
504
|
+
params: object({ series: _chunkTVO6W2Q6cjs.SERIES_REF, ...Object.fromEntries(Object.entries(_chunkTVO6W2Q6cjs.SERIES_PROPS).filter(([k]) => k !== "values")) }, ["series"]),
|
|
504
505
|
run: (_ctx, params) => {
|
|
505
506
|
const { series, ...patch } = params;
|
|
506
507
|
const id = resolveSeries(series).id;
|
|
@@ -514,7 +515,7 @@ function createChartCommands(controller, options = {}) {
|
|
|
514
515
|
label: "Delete Series",
|
|
515
516
|
keywords: ["chart", "series", "remove"],
|
|
516
517
|
description: "Deletes a series by id or name.",
|
|
517
|
-
params: object({ series:
|
|
518
|
+
params: object({ series: _chunkTVO6W2Q6cjs.SERIES_REF }, ["series"]),
|
|
518
519
|
run: (_ctx, params) => {
|
|
519
520
|
check(controller.removeSeries(resolveSeries(params.series).id));
|
|
520
521
|
return { series: seriesIds() };
|
|
@@ -535,7 +536,7 @@ function createChartCommands(controller, options = {}) {
|
|
|
535
536
|
label: "Delete Category",
|
|
536
537
|
keywords: ["chart", "category", "row", "remove"],
|
|
537
538
|
description: "Deletes a category (and its values) by index or label.",
|
|
538
|
-
params: object({ category:
|
|
539
|
+
params: object({ category: _chunkTVO6W2Q6cjs.CATEGORY_REF }, ["category"]),
|
|
539
540
|
run: (_ctx, params) => {
|
|
540
541
|
check(controller.removeCategory(resolveCategory(params.category)));
|
|
541
542
|
return { categories: controller.getSpec().categories };
|
|
@@ -547,7 +548,7 @@ function createChartCommands(controller, options = {}) {
|
|
|
547
548
|
label: "Add Trendline\u2026",
|
|
548
549
|
keywords: ["chart", "trend", "regression", "fit", "forecast", "moving average"],
|
|
549
550
|
description: "Fits a trendline to a series (linear, exponential, logarithmic, power, polynomial or moving average). Returns its index and the fit.",
|
|
550
|
-
params: object({ series:
|
|
551
|
+
params: object({ series: _chunkTVO6W2Q6cjs.SERIES_REF, ..._chunkTVO6W2Q6cjs.TRENDLINE_PROPS }, ["series", "type"]),
|
|
551
552
|
run: (_ctx, params) => {
|
|
552
553
|
const { series, ...line } = params;
|
|
553
554
|
const result = controller.addTrendline(resolveSeries(series).id, line);
|
|
@@ -562,7 +563,7 @@ function createChartCommands(controller, options = {}) {
|
|
|
562
563
|
label: "Delete Trendline",
|
|
563
564
|
keywords: ["chart", "trend", "remove"],
|
|
564
565
|
description: "Deletes a trendline from a series.",
|
|
565
|
-
params: object({ series:
|
|
566
|
+
params: object({ series: _chunkTVO6W2Q6cjs.SERIES_REF, index: { type: "integer", minimum: 0, description: "Trendline index (0 = first)." } }, ["series", "index"]),
|
|
566
567
|
run: (_ctx, params) => {
|
|
567
568
|
check(controller.removeTrendline(resolveSeries(params.series).id, params.index));
|
|
568
569
|
return { trendlines: _nullishCoalesce(_optionalChain([controller, 'access', _29 => _29.getSeries, 'call', _30 => _30(resolveSeries(params.series).id), 'optionalAccess', _31 => _31.trendlines]), () => ( [])) };
|
|
@@ -575,8 +576,8 @@ function createChartCommands(controller, options = {}) {
|
|
|
575
576
|
keywords: ["chart", "quick layout", "style", "colours", "colors", "monochrome", "theme"],
|
|
576
577
|
description: "Applies a quick layout and / or colour scheme as one undo step.",
|
|
577
578
|
params: object({
|
|
578
|
-
layout: { type: "string", enum:
|
|
579
|
-
colors: { type: "string", enum:
|
|
579
|
+
layout: { type: "string", enum: _chunkAKDWAWSYcjs.CHART_LAYOUT_PRESETS.map((p) => p.id), description: "Quick layout id." },
|
|
580
|
+
colors: { type: "string", enum: _chunkAKDWAWSYcjs.CHART_COLOR_SCHEMES.map((p) => p.id), description: "Colour scheme id." }
|
|
580
581
|
}),
|
|
581
582
|
run: (_ctx, params = {}) => {
|
|
582
583
|
check(controller.applyPreset(_nullishCoalesce(params, () => ( {}))));
|
|
@@ -591,7 +592,7 @@ function createChartCommands(controller, options = {}) {
|
|
|
591
592
|
description: "Swaps series and categories as one undo step.",
|
|
592
593
|
run: () => {
|
|
593
594
|
check(controller.transpose());
|
|
594
|
-
return { table:
|
|
595
|
+
return { table: _chunkWPPJH6X4cjs.chartDataToTable.call(void 0, controller.getSpec()) };
|
|
595
596
|
}
|
|
596
597
|
},
|
|
597
598
|
{
|
|
@@ -611,7 +612,7 @@ function createChartCommands(controller, options = {}) {
|
|
|
611
612
|
run: (_ctx, params) => {
|
|
612
613
|
const result = controller.importCsv(params.csv, { seriesIn: params.seriesIn, header: params.header });
|
|
613
614
|
check(result);
|
|
614
|
-
return { table:
|
|
615
|
+
return { table: _chunkWPPJH6X4cjs.chartDataToTable.call(void 0, controller.getSpec()), issues: _nullishCoalesce(result.issues, () => ( [])) };
|
|
615
616
|
}
|
|
616
617
|
},
|
|
617
618
|
{
|
|
@@ -622,7 +623,7 @@ function createChartCommands(controller, options = {}) {
|
|
|
622
623
|
description: "Replaces the chart with Mermaid xychart-beta, pie or radar-beta text (one undo step). Unreadable lines are listed with line numbers.",
|
|
623
624
|
params: object({ mermaid: { type: "string", description: "Mermaid text." } }, ["mermaid"]),
|
|
624
625
|
run: (_ctx, params) => {
|
|
625
|
-
const read =
|
|
626
|
+
const read = _chunkAKDWAWSYcjs.chartFromMermaid.call(void 0, params.mermaid);
|
|
626
627
|
if (!read.family) fail(read.issues.map((i) => i.message).join(" ") || "Expected Mermaid starting with xychart-beta, pie or radar-beta.");
|
|
627
628
|
check(controller.update({ ...read.spec }, { label: "Import Mermaid chart" }));
|
|
628
629
|
return { spec: controller.toJSON(), issues: read.issues };
|
|
@@ -636,7 +637,7 @@ function createChartCommands(controller, options = {}) {
|
|
|
636
637
|
keywords: ["chart", "mermaid", "markdown", "export"],
|
|
637
638
|
description: "Returns the chart as Mermaid text (with a round-trip comment unless meta is false).",
|
|
638
639
|
params: object({ meta: { type: "boolean", description: "Include the %% @pixerate round-trip comment (default true)." } }),
|
|
639
|
-
run: (_ctx, params = {}) => ({ mermaid:
|
|
640
|
+
run: (_ctx, params = {}) => ({ mermaid: _chunkAKDWAWSYcjs.chartToMermaid.call(void 0, controller.toJSON(), { meta: _optionalChain([params, 'optionalAccess', _32 => _32.meta]) }) })
|
|
640
641
|
},
|
|
641
642
|
{
|
|
642
643
|
...base,
|
|
@@ -645,7 +646,7 @@ function createChartCommands(controller, options = {}) {
|
|
|
645
646
|
readOnly: true,
|
|
646
647
|
keywords: ["chart", "office", "word", "powerpoint", "docx", "pptx", "xml", "export"],
|
|
647
648
|
description: "Returns the chart as a DrawingML chart part (c:chartSpace) and what could not be written.",
|
|
648
|
-
run: () =>
|
|
649
|
+
run: () => _chunk4T44CJ5Kcjs.chartToOoxml.call(void 0, controller.toJSON())
|
|
649
650
|
},
|
|
650
651
|
{
|
|
651
652
|
...base,
|
|
@@ -654,9 +655,9 @@ function createChartCommands(controller, options = {}) {
|
|
|
654
655
|
readOnly: true,
|
|
655
656
|
keywords: ["chart", "svg", "export", "image"],
|
|
656
657
|
description: "Returns the chart drawn as a standalone, accessible SVG string (with <title> and <desc>).",
|
|
657
|
-
params: object({ width:
|
|
658
|
+
params: object({ width: _chunkTVO6W2Q6cjs.WIDTH, height: _chunkTVO6W2Q6cjs.HEIGHT }),
|
|
658
659
|
run: (_ctx, params = {}) => ({
|
|
659
|
-
svg:
|
|
660
|
+
svg: _chunkAKDWAWSYcjs.chartToSvg.call(void 0, controller.toJSON(), { width: _nullishCoalesce(_optionalChain([params, 'optionalAccess', _33 => _33.width]), () => ( 640)), height: _nullishCoalesce(_optionalChain([params, 'optionalAccess', _34 => _34.height]), () => ( 400)) })
|
|
660
661
|
})
|
|
661
662
|
},
|
|
662
663
|
{
|
|
@@ -668,7 +669,7 @@ function createChartCommands(controller, options = {}) {
|
|
|
668
669
|
description: "Suggests chart types for the current data (or CSV), best first, each with a reason.",
|
|
669
670
|
params: object({ csv: { type: "string", description: "CSV text to analyse instead of the current data." } }),
|
|
670
671
|
run: (_ctx, params = {}) => ({
|
|
671
|
-
recommendations: recommendChartTypes(_optionalChain([params, 'optionalAccess', _35 => _35.csv]) !== void 0 ? _chunkN3KJFGXTcjs.parseCsv.call(void 0, params.csv) :
|
|
672
|
+
recommendations: recommendChartTypes(_optionalChain([params, 'optionalAccess', _35 => _35.csv]) !== void 0 ? _chunkN3KJFGXTcjs.parseCsv.call(void 0, params.csv) : _chunkWPPJH6X4cjs.chartDataToTable.call(void 0, controller.getSpec()))
|
|
672
673
|
})
|
|
673
674
|
},
|
|
674
675
|
{
|
|
@@ -681,8 +682,8 @@ function createChartCommands(controller, options = {}) {
|
|
|
681
682
|
run: () => {
|
|
682
683
|
const s = controller.getSpec();
|
|
683
684
|
const visible = s.series.filter((x) => !x.hidden);
|
|
684
|
-
const colors =
|
|
685
|
-
return { colors, ...
|
|
685
|
+
const colors = _chunkWPPJH6X4cjs.chartColorsByCategory.call(void 0, s.type) ? s.categories.map((_, i) => _optionalChain([visible, 'access', _36 => _36[0], 'optionalAccess', _37 => _37.pointColors, 'optionalAccess', _38 => _38[i]]) || _chunkWPPJH6X4cjs.chartSliceColor.call(void 0, s, i)) : visible.map((x) => _chunkWPPJH6X4cjs.chartSeriesColor.call(void 0, s, s.series.indexOf(x)));
|
|
686
|
+
return { colors, ..._chunkWPPJH6X4cjs.checkChartColors.call(void 0, colors) };
|
|
686
687
|
}
|
|
687
688
|
},
|
|
688
689
|
{
|
|
@@ -713,7 +714,7 @@ function chartClientToScene(scene, box, clientX, clientY) {
|
|
|
713
714
|
function canDragChartPoint(controller, scene, target) {
|
|
714
715
|
if (_optionalChain([target, 'optionalAccess', _39 => _39.kind]) !== "point" || !scene.valueScale || scene.percent) return false;
|
|
715
716
|
const spec = controller.getSpec();
|
|
716
|
-
const family =
|
|
717
|
+
const family = _chunkWPPJH6X4cjs.chartFamily.call(void 0, spec);
|
|
717
718
|
if (family !== "cartesian" && family !== "xy" && family !== "waterfall") return false;
|
|
718
719
|
const series = controller.getSeries(target.seriesId);
|
|
719
720
|
return !!series && !series.hidden && series.values[target.index] !== null;
|
|
@@ -722,7 +723,7 @@ function snapChartDragValue(scene, value, options = {}) {
|
|
|
722
723
|
const scale = _nullishCoalesce(options.scale, () => ( scene.valueScale));
|
|
723
724
|
const tolerance = _nullishCoalesce(options.tolerancePx, () => ( 6));
|
|
724
725
|
if (scale) {
|
|
725
|
-
const px = (v) =>
|
|
726
|
+
const px = (v) => _chunk4YWAEV4Wcjs.chartScaleToPixel.call(void 0, v, scale);
|
|
726
727
|
const at = px(value);
|
|
727
728
|
let best = null;
|
|
728
729
|
let bestDist = tolerance;
|
|
@@ -737,7 +738,7 @@ function snapChartDragValue(scene, value, options = {}) {
|
|
|
737
738
|
}
|
|
738
739
|
if (best !== null) return best;
|
|
739
740
|
}
|
|
740
|
-
return
|
|
741
|
+
return _chunk4YWAEV4Wcjs.snapChartValue.call(void 0, scene, value, options.step, _optionalChain([scale, 'optionalAccess', _40 => _40.ticks]), _optionalChain([scale, 'optionalAccess', _41 => _41.logBase]));
|
|
741
742
|
}
|
|
742
743
|
function startChartPointDrag(controller, scene, target, start, options = {}) {
|
|
743
744
|
if (!canDragChartPoint(controller, scene, target)) return null;
|
|
@@ -746,11 +747,11 @@ function startChartPointDrag(controller, scene, target, start, options = {}) {
|
|
|
746
747
|
const series = controller.getSeries(seriesId);
|
|
747
748
|
const secondary = series.axis === "secondary" && !!scene.valueScale2;
|
|
748
749
|
const scale = secondary ? scene.valueScale2 : scene.valueScale;
|
|
749
|
-
const xy =
|
|
750
|
+
const xy = _chunkWPPJH6X4cjs.chartFamily.call(void 0, spec) === "xy" && !!scene.xScale;
|
|
750
751
|
const startValue = _nullishCoalesce(series.values[index], () => ( 0));
|
|
751
752
|
const startX = _nullishCoalesce(_optionalChain([series, 'access', _42 => _42.x, 'optionalAccess', _43 => _43[index]]), () => ( null));
|
|
752
|
-
const startAt =
|
|
753
|
-
const startAtX = xy ?
|
|
753
|
+
const startAt = _chunk4YWAEV4Wcjs.chartValueAtPoint.call(void 0, scene, start, secondary);
|
|
754
|
+
const startAtX = xy ? _chunk4YWAEV4Wcjs.chartXAtPoint.call(void 0, scene, start) : void 0;
|
|
754
755
|
if (startAt === void 0) return null;
|
|
755
756
|
const candidates = [0, startValue];
|
|
756
757
|
if (!xy) {
|
|
@@ -768,7 +769,7 @@ function startChartPointDrag(controller, scene, target, start, options = {}) {
|
|
|
768
769
|
target: { seriesId, index },
|
|
769
770
|
move(point, moveOptions = {}) {
|
|
770
771
|
if (ended) return;
|
|
771
|
-
const at =
|
|
772
|
+
const at = _chunk4YWAEV4Wcjs.chartValueAtPoint.call(void 0, scene, point, secondary);
|
|
772
773
|
if (at === void 0) return;
|
|
773
774
|
const factor = moveOptions.fine ? 0.1 : 1;
|
|
774
775
|
const moved = (from, to, s, value) => s.logBase && value > 0 && from > 0 && to > 0 ? value * Math.pow(to / from, factor) : value + (to - from) * factor;
|
|
@@ -776,7 +777,7 @@ function startChartPointDrag(controller, scene, target, start, options = {}) {
|
|
|
776
777
|
let moveX = false;
|
|
777
778
|
let atX;
|
|
778
779
|
if (xy && startX !== null && startAtX !== void 0) {
|
|
779
|
-
atX =
|
|
780
|
+
atX = _chunk4YWAEV4Wcjs.chartXAtPoint.call(void 0, scene, point);
|
|
780
781
|
moveX = atX !== void 0;
|
|
781
782
|
if (moveOptions.lockAxis) {
|
|
782
783
|
if (Math.abs(point.x - start.x) >= Math.abs(point.y - start.y)) moveY = false;
|
|
@@ -788,7 +789,7 @@ function startChartPointDrag(controller, scene, target, start, options = {}) {
|
|
|
788
789
|
if (moveOptions.fine) {
|
|
789
790
|
if (s.logBase && !options.step) return v > 0 ? Number(v.toPrecision(3)) : v;
|
|
790
791
|
const unit = options.step ? options.step / 10 : s.ticks.length > 1 ? (s.ticks[1] - s.ticks[0]) / 100 : void 0;
|
|
791
|
-
return
|
|
792
|
+
return _chunk4YWAEV4Wcjs.snapChartValue.call(void 0, scene, v, unit, s.ticks);
|
|
792
793
|
}
|
|
793
794
|
return snapChartDragValue(scene, v, { candidates: c, tolerancePx: options.tolerancePx, step: options.step, scale: s });
|
|
794
795
|
};
|
|
@@ -876,7 +877,7 @@ function describeChartSelection(controller, selection = controller.getState().se
|
|
|
876
877
|
case "legend":
|
|
877
878
|
return "Legend";
|
|
878
879
|
case "axis":
|
|
879
|
-
return selection.axis === "x" ?
|
|
880
|
+
return selection.axis === "x" ? _chunkWPPJH6X4cjs.chartFamily.call(void 0, spec) === "xy" ? "X axis" : "Category axis" : selection.axis === "y" ? "Value axis" : "Secondary value axis";
|
|
880
881
|
case "series":
|
|
881
882
|
return `Series "${_nullishCoalesce(_optionalChain([controller, 'access', _59 => _59.getSeries, 'call', _60 => _60(selection.seriesId), 'optionalAccess', _61 => _61.name]), () => ( selection.seriesId))}"`;
|
|
882
883
|
case "category":
|
|
@@ -890,7 +891,7 @@ function describeChartSelection(controller, selection = controller.getState().se
|
|
|
890
891
|
const series = controller.getSeries(selection.seriesId);
|
|
891
892
|
const value = _optionalChain([series, 'optionalAccess', _65 => _65.values, 'access', _66 => _66[selection.index]]);
|
|
892
893
|
const x = _optionalChain([series, 'optionalAccess', _67 => _67.x, 'optionalAccess', _68 => _68[selection.index]]);
|
|
893
|
-
if (x !== void 0 && x !== null &&
|
|
894
|
+
if (x !== void 0 && x !== null && _chunkWPPJH6X4cjs.chartFamily.call(void 0, spec) === "xy") return `${_nullishCoalesce(_optionalChain([series, 'optionalAccess', _69 => _69.name]), () => ( selection.seriesId))}: (${x}, ${_nullishCoalesce(value, () => ( "blank"))})`;
|
|
894
895
|
return `${_nullishCoalesce(_optionalChain([series, 'optionalAccess', _70 => _70.name]), () => ( selection.seriesId))} \xB7 ${_nullishCoalesce(spec.categories[selection.index], () => ( selection.index))}: ${_nullishCoalesce(value, () => ( "blank"))}`;
|
|
895
896
|
}
|
|
896
897
|
}
|
|
@@ -967,7 +968,7 @@ function planChartCommand(spec, scene, command, speed = 1) {
|
|
|
967
968
|
const from = _nullishCoalesce(_optionalChain([series, 'optionalAccess', _73 => _73.values, 'access', _74 => _74[command.index]]), () => ( 0));
|
|
968
969
|
const scale = _optionalChain([series, 'optionalAccess', _75 => _75.axis]) === "secondary" ? _nullishCoalesce(scene.valueScale2, () => ( scene.valueScale)) : scene.valueScale;
|
|
969
970
|
if (at && scale) {
|
|
970
|
-
const px =
|
|
971
|
+
const px = _chunk4YWAEV4Wcjs.linearMap.call(void 0, command.value, scale.domain, scale.range);
|
|
971
972
|
const to = scale.axis === "y" ? { x: at.x, y: px } : { x: px, y: at.y };
|
|
972
973
|
steps.push({ type: "move", to: at, ms: ms(380) }, { type: "press" }, { type: "drag", to, ms: ms(520), from, value: command.value }, { type: "release" });
|
|
973
974
|
} else steps.push({ type: "drag", to: { x: scene.plot.x + scene.plot.width / 2, y: scene.plot.y + scene.plot.height / 2 }, ms: ms(200), from, value: command.value });
|
|
@@ -1200,13 +1201,13 @@ function createChartToolProvider(controller, options = {}) {
|
|
|
1200
1201
|
fail2(`There is no category ${JSON.stringify(ref)}; expected an index from 0 to ${categories.length - 1} or one of ${categories.slice(0, 20).map((c) => JSON.stringify(c)).join(", ")}.`);
|
|
1201
1202
|
return index;
|
|
1202
1203
|
};
|
|
1203
|
-
const table = () =>
|
|
1204
|
+
const table = () => _chunkWPPJH6X4cjs.chartDataToTable.call(void 0, spec());
|
|
1204
1205
|
const Parser = () => _nullishCoalesce(options.DOMParser, () => ( globalThis.DOMParser));
|
|
1205
1206
|
const getChart = {
|
|
1206
1207
|
name: "get_chart",
|
|
1207
1208
|
title: "Read the chart",
|
|
1208
1209
|
description: "Returns the chart spec (type, titles, axes, legend, series with ids and settings), its data as a table (header row of series names, then one row per category), the current selection, and a summary at the given size: per-series min / max / mean / trend, the axes as drawn, layout warnings (hidden labels, thinned lines), a colour check and a plain-language description. Use the series ids and category indexes it returns with the write tools.",
|
|
1209
|
-
inputSchema: { type: "object", properties: { width:
|
|
1210
|
+
inputSchema: { type: "object", properties: { width: _chunkTVO6W2Q6cjs.WIDTH, height: _chunkTVO6W2Q6cjs.HEIGHT }, additionalProperties: false },
|
|
1210
1211
|
annotations: { title: "Read the chart", ...READ },
|
|
1211
1212
|
handler: ({ width = size.width, height = size.height }) => {
|
|
1212
1213
|
const reason = readOnlyReason();
|
|
@@ -1214,7 +1215,7 @@ function createChartToolProvider(controller, options = {}) {
|
|
|
1214
1215
|
spec: controller.toJSON(),
|
|
1215
1216
|
table: table(),
|
|
1216
1217
|
selection: controller.getState().selection,
|
|
1217
|
-
summary:
|
|
1218
|
+
summary: _chunkAKDWAWSYcjs.summarizeChart.call(void 0, controller.toJSON(), { width, height }),
|
|
1218
1219
|
issues: controller.getState().issues,
|
|
1219
1220
|
...reason ? { readOnly: reason } : {}
|
|
1220
1221
|
};
|
|
@@ -1227,8 +1228,8 @@ function createChartToolProvider(controller, options = {}) {
|
|
|
1227
1228
|
inputSchema: {
|
|
1228
1229
|
type: "object",
|
|
1229
1230
|
properties: {
|
|
1230
|
-
width:
|
|
1231
|
-
height:
|
|
1231
|
+
width: _chunkTVO6W2Q6cjs.WIDTH,
|
|
1232
|
+
height: _chunkTVO6W2Q6cjs.HEIGHT,
|
|
1232
1233
|
format: { type: "string", enum: ["svg", "png"], description: "svg (default): the SVG document as text. png: an image to look at (only when the host can rasterize; costs image tokens)." }
|
|
1233
1234
|
},
|
|
1234
1235
|
additionalProperties: false
|
|
@@ -1236,8 +1237,8 @@ function createChartToolProvider(controller, options = {}) {
|
|
|
1236
1237
|
annotations: { title: "Render the chart", ...READ },
|
|
1237
1238
|
handler: async ({ width = size.width, height = size.height, format = "svg" }) => {
|
|
1238
1239
|
const json = controller.toJSON();
|
|
1239
|
-
const scene =
|
|
1240
|
-
const svg =
|
|
1240
|
+
const scene = _chunk4YWAEV4Wcjs.layoutChart.call(void 0, json, { width, height, selection: null });
|
|
1241
|
+
const svg = _chunkAKDWAWSYcjs.chartSceneToSvg.call(void 0, scene, { ariaLabel: json.title || void 0, description: _chunkAKDWAWSYcjs.describeChart.call(void 0, json) });
|
|
1241
1242
|
const warnings = scene.warnings;
|
|
1242
1243
|
if (format === "png") {
|
|
1243
1244
|
if (!options.rasterize) fail2('This host cannot rasterize charts; call render_chart with format "svg", or get_chart for the layout warnings.');
|
|
@@ -1271,8 +1272,8 @@ function createChartToolProvider(controller, options = {}) {
|
|
|
1271
1272
|
handler: ({ colors, surface }) => {
|
|
1272
1273
|
const s = spec();
|
|
1273
1274
|
const visible = s.series.filter((x) => !x.hidden);
|
|
1274
|
-
const own =
|
|
1275
|
-
return { colors: _nullishCoalesce(colors, () => ( own)), ...
|
|
1275
|
+
const own = _chunkWPPJH6X4cjs.chartColorsByCategory.call(void 0, s.type) ? s.categories.map((_, i) => _optionalChain([visible, 'access', _87 => _87[0], 'optionalAccess', _88 => _88.pointColors, 'optionalAccess', _89 => _89[i]]) || _chunkWPPJH6X4cjs.chartSliceColor.call(void 0, s, i)) : visible.map((x) => _chunkWPPJH6X4cjs.chartSeriesColor.call(void 0, s, s.series.indexOf(x)));
|
|
1276
|
+
return { colors: _nullishCoalesce(colors, () => ( own)), ..._chunkWPPJH6X4cjs.checkChartColors.call(void 0, _nullishCoalesce(colors, () => ( own)), { surface }) };
|
|
1276
1277
|
}
|
|
1277
1278
|
};
|
|
1278
1279
|
const recommend = {
|
|
@@ -1294,7 +1295,7 @@ function createChartToolProvider(controller, options = {}) {
|
|
|
1294
1295
|
description: "Returns a trendline's fitted coefficients (in x for category charts, x = 1, 2, 3, \u2026), R\xB2, equation and the number of points, or the moving-average points.",
|
|
1295
1296
|
inputSchema: {
|
|
1296
1297
|
type: "object",
|
|
1297
|
-
properties: { series:
|
|
1298
|
+
properties: { series: _chunkTVO6W2Q6cjs.SERIES_REF, index: { type: "integer", minimum: 0, description: "Trendline index on the series (0 = first)." } },
|
|
1298
1299
|
required: ["series", "index"],
|
|
1299
1300
|
additionalProperties: false
|
|
1300
1301
|
},
|
|
@@ -1316,8 +1317,8 @@ function createChartToolProvider(controller, options = {}) {
|
|
|
1316
1317
|
inputSchema: { type: "object", properties: {}, additionalProperties: false },
|
|
1317
1318
|
annotations: { title: "List chart presets", ...READ },
|
|
1318
1319
|
handler: () => ({
|
|
1319
|
-
layouts:
|
|
1320
|
-
colorSchemes:
|
|
1320
|
+
layouts: _chunkAKDWAWSYcjs.CHART_LAYOUT_PRESETS.map(({ id, label, description }) => ({ id, label, description })),
|
|
1321
|
+
colorSchemes: _chunkAKDWAWSYcjs.CHART_COLOR_SCHEMES.map(({ id, label, description, palette }) => ({ id, label, description, palette }))
|
|
1321
1322
|
})
|
|
1322
1323
|
};
|
|
1323
1324
|
const exportMermaid = {
|
|
@@ -1326,7 +1327,7 @@ function createChartToolProvider(controller, options = {}) {
|
|
|
1326
1327
|
description: 'Returns the chart as Mermaid text (xychart-beta, pie or radar-beta) for Markdown or chat. With meta (default true) one "%% @pixerate {\u2026}" comment keeps what Mermaid cannot express, so import_chart_mermaid gets the chart back exactly.',
|
|
1327
1328
|
inputSchema: { type: "object", properties: { meta: { type: "boolean", description: "Include the round-trip comment (default true)." } }, additionalProperties: false },
|
|
1328
1329
|
annotations: { title: "Export chart as Mermaid", ...READ },
|
|
1329
|
-
handler: ({ meta = true }) => ({ mermaid:
|
|
1330
|
+
handler: ({ meta = true }) => ({ mermaid: _chunkAKDWAWSYcjs.chartToMermaid.call(void 0, controller.toJSON(), { meta }) })
|
|
1330
1331
|
};
|
|
1331
1332
|
const exportOoxml = {
|
|
1332
1333
|
name: "export_chart_ooxml",
|
|
@@ -1334,15 +1335,15 @@ function createChartToolProvider(controller, options = {}) {
|
|
|
1334
1335
|
description: "Returns the chart as a DrawingML chart part (c:chartSpace) for Word or PowerPoint files, with what could not be written as sentences.",
|
|
1335
1336
|
inputSchema: { type: "object", properties: {}, additionalProperties: false },
|
|
1336
1337
|
annotations: { title: "Export chart as Office XML", ...READ },
|
|
1337
|
-
handler: () =>
|
|
1338
|
+
handler: () => _chunk4T44CJ5Kcjs.chartToOoxml.call(void 0, controller.toJSON())
|
|
1338
1339
|
};
|
|
1339
1340
|
const updateChart = {
|
|
1340
1341
|
name: "update_chart",
|
|
1341
1342
|
title: "Change chart presentation",
|
|
1342
|
-
description: 'Changes how the chart looks, as one undo step: type, titles, axes (xAxis = categories or numeric x, yAxis = values, yAxis2 = secondary values; each can be reversed, and value axes can be logarithmic with scale "log"), legend, stacking, orientation, curve, points, data labels and their position, palette, donut hole, bar spacing, histogram bins, waterfall total. All-or-nothing: invalid values change nothing and come back as sentences. Returns the new spec.',
|
|
1343
|
+
description: 'Changes how the chart looks, as one undo step: type, titles, axes (xAxis = categories or numeric x, yAxis = values, yAxis2 = secondary values; each can be reversed, and value axes can be logarithmic with scale "log"), legend, stacking, orientation, curve, points, data labels and their position, palette, donut hole, bar spacing, histogram bins, waterfall total, radar rings (radarTicks) and grid shape (radarGraticule). All-or-nothing: invalid values change nothing and come back as sentences. Returns the new spec.',
|
|
1343
1344
|
inputSchema: {
|
|
1344
1345
|
type: "object",
|
|
1345
|
-
properties:
|
|
1346
|
+
properties: _chunkTVO6W2Q6cjs.CHART_UPDATE_PROPERTIES,
|
|
1346
1347
|
additionalProperties: false
|
|
1347
1348
|
},
|
|
1348
1349
|
annotations: { title: "Change chart presentation", ...WRITE_IDEMPOTENT },
|
|
@@ -1363,7 +1364,7 @@ function createChartToolProvider(controller, options = {}) {
|
|
|
1363
1364
|
series: {
|
|
1364
1365
|
type: "array",
|
|
1365
1366
|
description: "The new series (replaces all).",
|
|
1366
|
-
items: { type: "object", properties: { id: { type: "string", description: "Stable id (optional)." }, ...
|
|
1367
|
+
items: { type: "object", properties: { id: { type: "string", description: "Stable id (optional)." }, ..._chunkTVO6W2Q6cjs.SERIES_PROPS }, required: ["name", "values"], additionalProperties: false }
|
|
1367
1368
|
}
|
|
1368
1369
|
},
|
|
1369
1370
|
additionalProperties: false
|
|
@@ -1386,7 +1387,7 @@ function createChartToolProvider(controller, options = {}) {
|
|
|
1386
1387
|
type: "array",
|
|
1387
1388
|
minItems: 1,
|
|
1388
1389
|
description: "Values to set.",
|
|
1389
|
-
items: { type: "object", properties: { series:
|
|
1390
|
+
items: { type: "object", properties: { series: _chunkTVO6W2Q6cjs.SERIES_REF, category: _chunkTVO6W2Q6cjs.CATEGORY_REF, value: _chunkTVO6W2Q6cjs.VALUE }, required: ["series", "category", "value"], additionalProperties: false }
|
|
1390
1391
|
}
|
|
1391
1392
|
},
|
|
1392
1393
|
required: ["cells"],
|
|
@@ -1395,7 +1396,7 @@ function createChartToolProvider(controller, options = {}) {
|
|
|
1395
1396
|
annotations: { title: "Set chart values", ...WRITE_IDEMPOTENT },
|
|
1396
1397
|
handler: async ({ cells }) => {
|
|
1397
1398
|
const resolved = cells.map((c) => ({ seriesId: seriesById(c.series).id, index: categoryIndex(c.category), value: c.value }));
|
|
1398
|
-
const parsed = resolved.map((c) =>
|
|
1399
|
+
const parsed = resolved.map((c) => _chunkWPPJH6X4cjs.parseChartValue.call(void 0, c.value));
|
|
1399
1400
|
const bad = resolved.find((_, i) => parsed[i] === void 0);
|
|
1400
1401
|
if (bad) fail2(`"${String(bad.value)}" is not a number; pass a number, numeric text or null for a gap. Nothing was changed.`);
|
|
1401
1402
|
if (options.director && parsed.every((v) => typeof v === "number")) {
|
|
@@ -1412,7 +1413,7 @@ function createChartToolProvider(controller, options = {}) {
|
|
|
1412
1413
|
description: "Adds a series (values padded to the categories) and selects it. Returns its id and stored values.",
|
|
1413
1414
|
inputSchema: {
|
|
1414
1415
|
type: "object",
|
|
1415
|
-
properties: { ...
|
|
1416
|
+
properties: { ..._chunkTVO6W2Q6cjs.SERIES_PROPS, id: { type: "string", description: "Id to use (default: series-N)." }, at: { type: "integer", minimum: 0, description: "Position (default: last)." } },
|
|
1416
1417
|
required: ["name"],
|
|
1417
1418
|
additionalProperties: false
|
|
1418
1419
|
},
|
|
@@ -1430,7 +1431,7 @@ function createChartToolProvider(controller, options = {}) {
|
|
|
1430
1431
|
description: "Renames, recolours, hides, moves to the secondary axis or changes how a series is drawn (marker, curve, labels, format, x values, bubble sizes, point colours, error bars). null resets a field. Values change with set_chart_values. Returns the series.",
|
|
1431
1432
|
inputSchema: {
|
|
1432
1433
|
type: "object",
|
|
1433
|
-
properties: { series:
|
|
1434
|
+
properties: { series: _chunkTVO6W2Q6cjs.SERIES_REF, ...Object.fromEntries(Object.entries(_chunkTVO6W2Q6cjs.SERIES_PROPS).filter(([k]) => k !== "values")) },
|
|
1434
1435
|
required: ["series"],
|
|
1435
1436
|
additionalProperties: false
|
|
1436
1437
|
},
|
|
@@ -1446,7 +1447,7 @@ function createChartToolProvider(controller, options = {}) {
|
|
|
1446
1447
|
name: "remove_chart_series",
|
|
1447
1448
|
title: "Delete a series",
|
|
1448
1449
|
description: "Deletes a series and its values. Returns the remaining series ids.",
|
|
1449
|
-
inputSchema: { type: "object", properties: { series:
|
|
1450
|
+
inputSchema: { type: "object", properties: { series: _chunkTVO6W2Q6cjs.SERIES_REF }, required: ["series"], additionalProperties: false },
|
|
1450
1451
|
annotations: { title: "Delete a series", ...DESTRUCTIVE },
|
|
1451
1452
|
handler: ({ series }) => {
|
|
1452
1453
|
resolve(controller.removeSeries(seriesById(series).id));
|
|
@@ -1472,7 +1473,7 @@ function createChartToolProvider(controller, options = {}) {
|
|
|
1472
1473
|
name: "remove_chart_category",
|
|
1473
1474
|
title: "Delete a category",
|
|
1474
1475
|
description: "Deletes a category and its value in every series. Returns the remaining categories.",
|
|
1475
|
-
inputSchema: { type: "object", properties: { category:
|
|
1476
|
+
inputSchema: { type: "object", properties: { category: _chunkTVO6W2Q6cjs.CATEGORY_REF }, required: ["category"], additionalProperties: false },
|
|
1476
1477
|
annotations: { title: "Delete a category", ...DESTRUCTIVE },
|
|
1477
1478
|
handler: ({ category }) => {
|
|
1478
1479
|
resolve(controller.removeCategory(categoryIndex(category)));
|
|
@@ -1515,7 +1516,7 @@ function createChartToolProvider(controller, options = {}) {
|
|
|
1515
1516
|
annotations: { title: "Import a Mermaid chart", ...DESTRUCTIVE },
|
|
1516
1517
|
handler: ({ mermaid }) => {
|
|
1517
1518
|
const fenced = /```(?:mermaid)?\s*\n([\s\S]*?)```/.exec(mermaid);
|
|
1518
|
-
const read =
|
|
1519
|
+
const read = _chunkAKDWAWSYcjs.chartFromMermaid.call(void 0, fenced ? fenced[1] : mermaid);
|
|
1519
1520
|
if (!read.family) fail2(read.issues.map((i) => i.message).join(" ") || "Expected Mermaid starting with xychart-beta, pie or radar-beta.");
|
|
1520
1521
|
resolve(controller.update({ ...read.spec }, { label: "Import Mermaid chart" }));
|
|
1521
1522
|
return { spec: controller.toJSON(), issues: read.issues };
|
|
@@ -1528,7 +1529,7 @@ function createChartToolProvider(controller, options = {}) {
|
|
|
1528
1529
|
inputSchema: { type: "object", properties: { xml: { type: "string", description: "The chart part XML, e.g. word/charts/chart1.xml." } }, required: ["xml"], additionalProperties: false },
|
|
1529
1530
|
annotations: { title: "Import an Office chart", ...DESTRUCTIVE },
|
|
1530
1531
|
handler: ({ xml }) => {
|
|
1531
|
-
const read =
|
|
1532
|
+
const read = _chunk4T44CJ5Kcjs.chartFromOoxml.call(void 0, xml, { DOMParser: Parser() });
|
|
1532
1533
|
if (read.issues.some((i) => i.path === "" || i.path === "plotArea")) fail2(read.issues.map((i) => i.message).join(" "));
|
|
1533
1534
|
resolve(controller.update({ ...read.spec }, { label: "Import Office chart" }));
|
|
1534
1535
|
return { spec: controller.toJSON(), issues: read.issues.map((i) => i.message), unsupported: read.unsupported, lossless: read.lossless };
|
|
@@ -1538,7 +1539,7 @@ function createChartToolProvider(controller, options = {}) {
|
|
|
1538
1539
|
name: "add_chart_trendline",
|
|
1539
1540
|
title: "Add a trendline",
|
|
1540
1541
|
description: "Fits a trendline to a series and draws it (unstacked bar, line, area, scatter and bubble charts). Returns its index and the fit: coefficients, R\xB2 and equation.",
|
|
1541
|
-
inputSchema: { type: "object", properties: { series:
|
|
1542
|
+
inputSchema: { type: "object", properties: { series: _chunkTVO6W2Q6cjs.SERIES_REF, ..._chunkTVO6W2Q6cjs.TRENDLINE_PROPS }, required: ["series", "type"], additionalProperties: false },
|
|
1542
1543
|
annotations: { title: "Add a trendline", ...WRITE },
|
|
1543
1544
|
handler: ({ series, ...line }) => {
|
|
1544
1545
|
const s = seriesById(series);
|
|
@@ -1552,7 +1553,7 @@ function createChartToolProvider(controller, options = {}) {
|
|
|
1552
1553
|
description: "Deletes a trendline from a series. Returns the series' remaining trendlines.",
|
|
1553
1554
|
inputSchema: {
|
|
1554
1555
|
type: "object",
|
|
1555
|
-
properties: { series:
|
|
1556
|
+
properties: { series: _chunkTVO6W2Q6cjs.SERIES_REF, index: { type: "integer", minimum: 0, description: "Trendline index on the series (0 = first)." } },
|
|
1556
1557
|
required: ["series", "index"],
|
|
1557
1558
|
additionalProperties: false
|
|
1558
1559
|
},
|
|
@@ -1570,8 +1571,8 @@ function createChartToolProvider(controller, options = {}) {
|
|
|
1570
1571
|
inputSchema: {
|
|
1571
1572
|
type: "object",
|
|
1572
1573
|
properties: {
|
|
1573
|
-
layout: { type: "string", enum:
|
|
1574
|
-
colors: { type: "string", enum:
|
|
1574
|
+
layout: { type: "string", enum: _chunkAKDWAWSYcjs.CHART_LAYOUT_PRESETS.map((p) => p.id), description: "Quick layout id." },
|
|
1575
|
+
colors: { type: "string", enum: _chunkAKDWAWSYcjs.CHART_COLOR_SCHEMES.map((p) => p.id), description: "Colour scheme id." }
|
|
1575
1576
|
},
|
|
1576
1577
|
additionalProperties: false
|
|
1577
1578
|
},
|
|
@@ -1600,8 +1601,8 @@ function createChartToolProvider(controller, options = {}) {
|
|
|
1600
1601
|
type: "object",
|
|
1601
1602
|
properties: {
|
|
1602
1603
|
kind: { type: "string", enum: ["none", "chart", "title", "subtitle", "legend", "axis", "series", "point", "category", "trendline"], description: "What to select." },
|
|
1603
|
-
series: { ...
|
|
1604
|
-
category: { ...
|
|
1604
|
+
series: { ..._chunkTVO6W2Q6cjs.SERIES_REF, description: "Series id or name (series, point, trendline)." },
|
|
1605
|
+
category: { ..._chunkTVO6W2Q6cjs.CATEGORY_REF, description: "Category index or label (point, category)." },
|
|
1605
1606
|
axis: { type: "string", enum: ["x", "y", "y2"], description: "Axis (axis)." },
|
|
1606
1607
|
index: { type: "integer", minimum: 0, description: "Trendline index (trendline)." }
|
|
1607
1608
|
},
|
|
@@ -1659,15 +1660,15 @@ function createChartToolProvider(controller, options = {}) {
|
|
|
1659
1660
|
to: { type: "object", description: "End, as fractions of the chart.", properties: { x: { type: "number", minimum: 0, maximum: 1, description: "Fraction of the width." }, y: { type: "number", minimum: 0, maximum: 1, description: "Fraction of the height." } }, required: ["x", "y"], additionalProperties: false },
|
|
1660
1661
|
fine: { type: "boolean", description: "Move a tenth as far (Alt)." },
|
|
1661
1662
|
lockAxis: { type: "boolean", description: "Scatter charts: change only the axis moved along most (Shift)." },
|
|
1662
|
-
width:
|
|
1663
|
-
height:
|
|
1663
|
+
width: _chunkTVO6W2Q6cjs.WIDTH,
|
|
1664
|
+
height: _chunkTVO6W2Q6cjs.HEIGHT
|
|
1664
1665
|
},
|
|
1665
1666
|
required: ["from", "to"],
|
|
1666
1667
|
additionalProperties: false
|
|
1667
1668
|
},
|
|
1668
1669
|
annotations: { title: "Drag a chart point", ...WRITE },
|
|
1669
1670
|
handler: ({ from, to, fine, lockAxis, width = size.width, height = size.height }) => {
|
|
1670
|
-
const scene =
|
|
1671
|
+
const scene = _chunk4YWAEV4Wcjs.layoutChart.call(void 0, controller.toJSON(), { width, height });
|
|
1671
1672
|
const start = { x: from.x * width, y: from.y * height };
|
|
1672
1673
|
const target = chartHitTest(scene, start);
|
|
1673
1674
|
if (_optionalChain([target, 'optionalAccess', _97 => _97.kind]) !== "point") fail2(`There is no bar or point at (${from.x}, ${from.y}); ${target ? `that is the ${target.kind}` : "that is outside the chart"}. Use render_chart to find marks.`);
|
|
@@ -1697,7 +1698,7 @@ function createChartToolProvider(controller, options = {}) {
|
|
|
1697
1698
|
},
|
|
1698
1699
|
annotations: { title: "Press a key on the chart", ...DESTRUCTIVE },
|
|
1699
1700
|
handler: ({ key: k, shift, alt }) => {
|
|
1700
|
-
const scene =
|
|
1701
|
+
const scene = _chunk4YWAEV4Wcjs.layoutChart.call(void 0, controller.toJSON(), size);
|
|
1701
1702
|
const used = handleChartKey(controller, scene, { key: k, shiftKey: shift, altKey: alt });
|
|
1702
1703
|
const sel = controller.getState().selection;
|
|
1703
1704
|
const value = _optionalChain([sel, 'optionalAccess', _102 => _102.kind]) === "point" ? _nullishCoalesce(_optionalChain([controller, 'access', _103 => _103.getSeries, 'call', _104 => _104(sel.seriesId), 'optionalAccess', _105 => _105.values, 'access', _106 => _106[sel.index]]), () => ( null)) : void 0;
|
|
@@ -1808,12 +1809,12 @@ var ChartStream = (_class = class {
|
|
|
1808
1809
|
if (format === "json") {
|
|
1809
1810
|
const value = complete ? safeParse(text) : parsePartialChartJson(text);
|
|
1810
1811
|
if (value !== void 0) {
|
|
1811
|
-
const read =
|
|
1812
|
+
const read = _chunkWPPJH6X4cjs.normalizeChartSpec.call(void 0, value);
|
|
1812
1813
|
spec = read.spec;
|
|
1813
1814
|
issues = complete ? read.issues : [];
|
|
1814
1815
|
}
|
|
1815
1816
|
} else {
|
|
1816
|
-
const read =
|
|
1817
|
+
const read = _chunkAKDWAWSYcjs.chartFromMermaid.call(void 0, text, { partial: !complete });
|
|
1817
1818
|
if (read.family) {
|
|
1818
1819
|
spec = read.spec;
|
|
1819
1820
|
issues = complete ? read.issues : [];
|
|
@@ -1934,7 +1935,7 @@ async function readRels(r, partPath) {
|
|
|
1934
1935
|
}
|
|
1935
1936
|
return rels;
|
|
1936
1937
|
}
|
|
1937
|
-
var isChartRef = (el) => el.localName === "chart" && (el.namespaceURI ===
|
|
1938
|
+
var isChartRef = (el) => el.localName === "chart" && (el.namespaceURI === _chunk4T44CJ5Kcjs.CHART_OOXML_NS || el.namespaceURI === STRICT_CHART_NS || el.namespaceURI === CHARTEX_NS);
|
|
1938
1939
|
function frameName(ref) {
|
|
1939
1940
|
for (let el = ref.parentElement; el; el = el.parentElement) {
|
|
1940
1941
|
if (el.localName === "graphicFrame") {
|
|
@@ -1953,7 +1954,7 @@ async function chartsInPart(r, root, rels, place) {
|
|
|
1953
1954
|
const entry = r.zip.get(rel.target);
|
|
1954
1955
|
if (!entry) continue;
|
|
1955
1956
|
r.seen.add(rel.target);
|
|
1956
|
-
const read =
|
|
1957
|
+
const read = _chunk4T44CJ5Kcjs.chartFromOoxml.call(void 0, await r.zip.readText(entry), { DOMParser: r.Parser });
|
|
1957
1958
|
const name = frameName(ref);
|
|
1958
1959
|
r.charts.push({
|
|
1959
1960
|
id: `chart-${r.charts.length + 1}`,
|
|
@@ -2384,4 +2385,5 @@ function createChartEditorDocument(controller) {
|
|
|
2384
2385
|
|
|
2385
2386
|
|
|
2386
2387
|
|
|
2387
|
-
exports.CHART_AXIS_KINDS = _chunkI4AHLP7Fcjs.CHART_AXIS_KINDS; exports.CHART_AXIS_SCALES = _chunkI4AHLP7Fcjs.CHART_AXIS_SCALES; exports.CHART_COLOR_SCHEMES = _chunkML2II3Y3cjs.CHART_COLOR_SCHEMES; exports.CHART_CURVES = _chunkI4AHLP7Fcjs.CHART_CURVES; exports.CHART_DATE_STEPS = _chunkXTU6QO2Wcjs.CHART_DATE_STEPS; exports.CHART_ERROR_BAR_DIRECTIONS = _chunkI4AHLP7Fcjs.CHART_ERROR_BAR_DIRECTIONS; exports.CHART_ERROR_BAR_LABELS = _chunkI4AHLP7Fcjs.CHART_ERROR_BAR_LABELS; exports.CHART_ERROR_BAR_TYPES = _chunkI4AHLP7Fcjs.CHART_ERROR_BAR_TYPES; exports.CHART_LABEL_POSITIONS = _chunkI4AHLP7Fcjs.CHART_LABEL_POSITIONS; exports.CHART_LAYOUT_PRESETS = _chunkML2II3Y3cjs.CHART_LAYOUT_PRESETS; exports.CHART_LEGEND_POSITIONS = _chunkI4AHLP7Fcjs.CHART_LEGEND_POSITIONS; exports.CHART_MARKERS = _chunkI4AHLP7Fcjs.CHART_MARKERS; exports.CHART_MERMAID_META_PREFIX = _chunkML2II3Y3cjs.CHART_MERMAID_META_PREFIX; exports.CHART_NUMBER_STYLES = _chunkI4AHLP7Fcjs.CHART_NUMBER_STYLES; exports.CHART_OOXML_CONTENT_TYPE = _chunk2WDZI6QDcjs.CHART_OOXML_CONTENT_TYPE; exports.CHART_OOXML_NS = _chunk2WDZI6QDcjs.CHART_OOXML_NS; exports.CHART_OOXML_RELATIONSHIP = _chunk2WDZI6QDcjs.CHART_OOXML_RELATIONSHIP; exports.CHART_ORIENTATIONS = _chunkI4AHLP7Fcjs.CHART_ORIENTATIONS; exports.CHART_PALETTE_SHADES = _chunkI4AHLP7Fcjs.CHART_PALETTE_SHADES; exports.CHART_PRESENCE_COLORS = CHART_PRESENCE_COLORS; exports.CHART_RASTER_MAX_SIZE = CHART_RASTER_MAX_SIZE; exports.CHART_SERIES_TYPES = _chunkI4AHLP7Fcjs.CHART_SERIES_TYPES; exports.CHART_STACKINGS = _chunkI4AHLP7Fcjs.CHART_STACKINGS; exports.CHART_TRENDLINE_TYPES = _chunkI4AHLP7Fcjs.CHART_TRENDLINE_TYPES; exports.CHART_TYPES = _chunkI4AHLP7Fcjs.CHART_TYPES; exports.CHART_TYPE_LABELS = _chunkI4AHLP7Fcjs.CHART_TYPE_LABELS; exports.CSS_VARIABLE_CHART_THEME = _chunkI4AHLP7Fcjs.CSS_VARIABLE_CHART_THEME; exports.ChartController = _chunkML2II3Y3cjs.ChartController; exports.ChartDirector = ChartDirector; exports.ChartPresence = ChartPresence; exports.ChartStream = ChartStream; exports.DEFAULT_CHART_PALETTE = _chunkI4AHLP7Fcjs.DEFAULT_CHART_PALETTE; exports.DEFAULT_CHART_THEME = _chunkI4AHLP7Fcjs.DEFAULT_CHART_THEME; exports.MAX_CHART_DATA_LABELS = _chunkXTU6QO2Wcjs.MAX_CHART_DATA_LABELS; exports.MAX_CHART_LINE_POINTS = _chunkXTU6QO2Wcjs.MAX_CHART_LINE_POINTS; exports.MAX_CHART_MARKERS = _chunkXTU6QO2Wcjs.MAX_CHART_MARKERS; exports.OfficeChartsError = OfficeChartsError; exports.RENDER_CHART_INSTRUCTIONS = RENDER_CHART_INSTRUCTIONS; exports.analyzeChartTable = analyzeChartTable; exports.blendChartScenes = blendChartScenes; exports.canDragChartPoint = canDragChartPoint; exports.chartBoxStats = _chunkXTU6QO2Wcjs.chartBoxStats; exports.chartClientToScene = chartClientToScene; exports.chartColorDistance = _chunkI4AHLP7Fcjs.chartColorDistance; exports.chartColorInputValue = _chunkI4AHLP7Fcjs.chartColorInputValue; exports.chartColorsByCategory = _chunkI4AHLP7Fcjs.chartColorsByCategory; exports.chartContrastRatio = _chunkI4AHLP7Fcjs.chartContrastRatio; exports.chartDataFromTable = _chunkI4AHLP7Fcjs.chartDataFromTable; exports.chartDataToTable = _chunkI4AHLP7Fcjs.chartDataToTable; exports.chartDateLabels = _chunkXTU6QO2Wcjs.chartDateLabels; exports.chartDateToSerial = _chunkXTU6QO2Wcjs.chartDateToSerial; exports.chartErrorAmounts = _chunkI4AHLP7Fcjs.chartErrorAmounts; exports.chartErrorBarsOfType = _chunkI4AHLP7Fcjs.chartErrorBarsOfType; exports.chartFamily = _chunkI4AHLP7Fcjs.chartFamily; exports.chartFileName = chartFileName; exports.chartFormatToCode = _chunk2WDZI6QDcjs.chartFormatToCode; exports.chartFromMermaid = _chunkML2II3Y3cjs.chartFromMermaid; exports.chartFromOoxml = _chunk2WDZI6QDcjs.chartFromOoxml; exports.chartFromTable = chartFromTable; exports.chartHistogram = _chunkXTU6QO2Wcjs.chartHistogram; exports.chartHitTest = chartHitTest; exports.chartLuminance = _chunkI4AHLP7Fcjs.chartLuminance; exports.chartMermaidFamily = _chunkML2II3Y3cjs.chartMermaidFamily; exports.chartMovingAverage = _chunkXTU6QO2Wcjs.chartMovingAverage; exports.chartPointAnchor = chartPointAnchor; exports.chartPointColor = _chunkI4AHLP7Fcjs.chartPointColor; exports.chartPointRef = chartPointRef; exports.chartPresetPatch = _chunkML2II3Y3cjs.chartPresetPatch; exports.chartQuantile = _chunkXTU6QO2Wcjs.chartQuantile; exports.chartRasterSize = chartRasterSize; exports.chartRgbToHex = _chunkI4AHLP7Fcjs.chartRgbToHex; exports.chartRgbToOklab = _chunkI4AHLP7Fcjs.chartRgbToOklab; exports.chartScaleFromPixel = _chunkXTU6QO2Wcjs.chartScaleFromPixel; exports.chartScaleToPixel = _chunkXTU6QO2Wcjs.chartScaleToPixel; exports.chartSceneToDomSpec = _chunkML2II3Y3cjs.chartSceneToDomSpec; exports.chartSceneToSvg = _chunkML2II3Y3cjs.chartSceneToSvg; exports.chartSerialToDate = _chunkXTU6QO2Wcjs.chartSerialToDate; exports.chartSeriesColor = _chunkI4AHLP7Fcjs.chartSeriesColor; exports.chartSeriesType = _chunkI4AHLP7Fcjs.chartSeriesType; exports.chartSliceColor = _chunkI4AHLP7Fcjs.chartSliceColor; exports.chartSquarify = _chunkXTU6QO2Wcjs.chartSquarify; exports.chartSupportsTrendlines = _chunkXTU6QO2Wcjs.chartSupportsTrendlines; exports.chartTextBaseline = _chunkML2II3Y3cjs.chartTextBaseline; exports.chartTextOn = _chunkI4AHLP7Fcjs.chartTextOn; exports.chartTextTransform = _chunkML2II3Y3cjs.chartTextTransform; exports.chartToMermaid = _chunkML2II3Y3cjs.chartToMermaid; exports.chartToOoxml = _chunk2WDZI6QDcjs.chartToOoxml; exports.chartToSvg = _chunkML2II3Y3cjs.chartToSvg; exports.chartTrendlineName = _chunkXTU6QO2Wcjs.chartTrendlineName; exports.chartValueAtPoint = _chunkXTU6QO2Wcjs.chartValueAtPoint; exports.chartXAtPoint = _chunkXTU6QO2Wcjs.chartXAtPoint; exports.checkChartColors = _chunkI4AHLP7Fcjs.checkChartColors; exports.cloneChartSeries = _chunkI4AHLP7Fcjs.cloneChartSeries; exports.cloneChartSpec = _chunkI4AHLP7Fcjs.cloneChartSpec; exports.compileChartFormatCode = _chunkXTU6QO2Wcjs.compileChartFormatCode; exports.contrastingTextColor = _chunkXTU6QO2Wcjs.contrastingTextColor; exports.createChartCommands = createChartCommands; exports.createChartController = _chunkML2II3Y3cjs.createChartController; exports.createChartEditorDocument = createChartEditorDocument; exports.createChartRasterizer = createChartRasterizer; exports.createChartSpec = _chunkI4AHLP7Fcjs.createChartSpec; exports.createChartToolProvider = createChartToolProvider; exports.createInstantChartClock = createInstantChartClock; exports.createOfficeChartToolProvider = createOfficeChartToolProvider; exports.cyclePaletteColor = _chunkI4AHLP7Fcjs.cyclePaletteColor; exports.decimateChartPoints = _chunkXTU6QO2Wcjs.decimateChartPoints; exports.defaultChartAxis = _chunkI4AHLP7Fcjs.defaultChartAxis; exports.defaultChartErrorBarValue = _chunkI4AHLP7Fcjs.defaultChartErrorBarValue; exports.describeChart = _chunkML2II3Y3cjs.describeChart; exports.describeChartErrorBars = _chunkI4AHLP7Fcjs.describeChartErrorBars; exports.describeChartSelection = describeChartSelection; exports.describeOfficeChartPlace = describeOfficeChartPlace; exports.downloadChartPng = downloadChartPng; exports.easeChartTween = easeChartTween; exports.estimateChartTextWidth = _chunkXTU6QO2Wcjs.estimateChartTextWidth; exports.extractDocxCharts = extractDocxCharts; exports.extractOfficeCharts = extractOfficeCharts; exports.extractPptxCharts = extractPptxCharts; exports.extractXlsxCharts = extractXlsxCharts; exports.findMermaidCharts = _chunkML2II3Y3cjs.findMermaidCharts; exports.fitChartTrendline = _chunkXTU6QO2Wcjs.fitChartTrendline; exports.formatChartAmountList = _chunkI4AHLP7Fcjs.formatChartAmountList; exports.formatChartDate = _chunkXTU6QO2Wcjs.formatChartDate; exports.formatChartNumber = _chunkXTU6QO2Wcjs.formatChartNumber; exports.formatChartValueWithCode = _chunkXTU6QO2Wcjs.formatChartValueWithCode; exports.handleChartKey = handleChartKey; exports.isCartesianChart = _chunkI4AHLP7Fcjs.isCartesianChart; exports.isXyChart = _chunkI4AHLP7Fcjs.isXyChart; exports.layoutChart = _chunkXTU6QO2Wcjs.layoutChart; exports.layoutSparkline = _chunkML2II3Y3cjs.layoutSparkline; exports.linearMap = _chunkXTU6QO2Wcjs.linearMap; exports.locateChartPoint = locateChartPoint; exports.monochromeChartPalette = _chunkML2II3Y3cjs.monochromeChartPalette; exports.niceLogScale = _chunkXTU6QO2Wcjs.niceLogScale; exports.niceScale = _chunkXTU6QO2Wcjs.niceScale; exports.niceStep = _chunkXTU6QO2Wcjs.niceStep; exports.normalizeChartAxis = _chunkI4AHLP7Fcjs.normalizeChartAxis; exports.normalizeChartErrorBars = _chunkI4AHLP7Fcjs.normalizeChartErrorBars; exports.normalizeChartSpec = _chunkI4AHLP7Fcjs.normalizeChartSpec; exports.normalizeChartTrendline = _chunkI4AHLP7Fcjs.normalizeChartTrendline; exports.normalizeChartValues = _chunkI4AHLP7Fcjs.normalizeChartValues; exports.parseChartAmountList = _chunkI4AHLP7Fcjs.parseChartAmountList; exports.parseChartColor = _chunkI4AHLP7Fcjs.parseChartColor; exports.parseChartDate = _chunkXTU6QO2Wcjs.parseChartDate; exports.parseChartValue = _chunkI4AHLP7Fcjs.parseChartValue; exports.parsePartialChartJson = parsePartialChartJson; exports.planChartCommand = planChartCommand; exports.planChartToolPlayback = planChartToolPlayback; exports.rasterizeChartSvg = rasterizeChartSvg; exports.realChartClock = realChartClock; exports.recommendChartTypes = recommendChartTypes; exports.recommendForShape = recommendForShape; exports.resolveChartSvgPaints = resolveChartSvgPaints; exports.sameChartSelection = _chunkXTU6QO2Wcjs.sameChartSelection; exports.shadeChartColor = _chunkI4AHLP7Fcjs.shadeChartColor; exports.simulateChartVision = _chunkI4AHLP7Fcjs.simulateChartVision; exports.snapChartDragValue = snapChartDragValue; exports.snapChartValue = _chunkXTU6QO2Wcjs.snapChartValue; exports.sparklineToSvg = _chunkML2II3Y3cjs.sparklineToSvg; exports.startChartPointDrag = startChartPointDrag; exports.stepDecimals = _chunkXTU6QO2Wcjs.stepDecimals; exports.summarizeChart = _chunkML2II3Y3cjs.summarizeChart; exports.summarizeChartSeries = _chunkXTU6QO2Wcjs.summarizeChartSeries; exports.trendNumberText = _chunkXTU6QO2Wcjs.trendNumberText; exports.uniqueChartSeriesId = _chunkI4AHLP7Fcjs.uniqueChartSeriesId; exports.withChartPlayback = withChartPlayback;
|
|
2388
|
+
|
|
2389
|
+
exports.CHART_AXIS_KINDS = _chunkWPPJH6X4cjs.CHART_AXIS_KINDS; exports.CHART_AXIS_SCALES = _chunkWPPJH6X4cjs.CHART_AXIS_SCALES; exports.CHART_COLOR_SCHEMES = _chunkAKDWAWSYcjs.CHART_COLOR_SCHEMES; exports.CHART_CURVES = _chunkWPPJH6X4cjs.CHART_CURVES; exports.CHART_DATE_STEPS = _chunk4YWAEV4Wcjs.CHART_DATE_STEPS; exports.CHART_ERROR_BAR_DIRECTIONS = _chunkWPPJH6X4cjs.CHART_ERROR_BAR_DIRECTIONS; exports.CHART_ERROR_BAR_LABELS = _chunkWPPJH6X4cjs.CHART_ERROR_BAR_LABELS; exports.CHART_ERROR_BAR_TYPES = _chunkWPPJH6X4cjs.CHART_ERROR_BAR_TYPES; exports.CHART_LABEL_POSITIONS = _chunkWPPJH6X4cjs.CHART_LABEL_POSITIONS; exports.CHART_LAYOUT_PRESETS = _chunkAKDWAWSYcjs.CHART_LAYOUT_PRESETS; exports.CHART_LEGEND_POSITIONS = _chunkWPPJH6X4cjs.CHART_LEGEND_POSITIONS; exports.CHART_MARKERS = _chunkWPPJH6X4cjs.CHART_MARKERS; exports.CHART_MERMAID_META_PREFIX = _chunkAKDWAWSYcjs.CHART_MERMAID_META_PREFIX; exports.CHART_NUMBER_STYLES = _chunkWPPJH6X4cjs.CHART_NUMBER_STYLES; exports.CHART_OOXML_CONTENT_TYPE = _chunk4T44CJ5Kcjs.CHART_OOXML_CONTENT_TYPE; exports.CHART_OOXML_NS = _chunk4T44CJ5Kcjs.CHART_OOXML_NS; exports.CHART_OOXML_RELATIONSHIP = _chunk4T44CJ5Kcjs.CHART_OOXML_RELATIONSHIP; exports.CHART_ORIENTATIONS = _chunkWPPJH6X4cjs.CHART_ORIENTATIONS; exports.CHART_PALETTE_SHADES = _chunkWPPJH6X4cjs.CHART_PALETTE_SHADES; exports.CHART_PRESENCE_COLORS = CHART_PRESENCE_COLORS; exports.CHART_RADAR_GRATICULES = _chunkWPPJH6X4cjs.CHART_RADAR_GRATICULES; exports.CHART_RASTER_MAX_SIZE = CHART_RASTER_MAX_SIZE; exports.CHART_SERIES_TYPES = _chunkWPPJH6X4cjs.CHART_SERIES_TYPES; exports.CHART_STACKINGS = _chunkWPPJH6X4cjs.CHART_STACKINGS; exports.CHART_TRENDLINE_TYPES = _chunkWPPJH6X4cjs.CHART_TRENDLINE_TYPES; exports.CHART_TYPES = _chunkWPPJH6X4cjs.CHART_TYPES; exports.CHART_TYPE_LABELS = _chunkWPPJH6X4cjs.CHART_TYPE_LABELS; exports.CSS_VARIABLE_CHART_THEME = _chunkWPPJH6X4cjs.CSS_VARIABLE_CHART_THEME; exports.ChartController = _chunkAKDWAWSYcjs.ChartController; exports.ChartDirector = ChartDirector; exports.ChartPresence = ChartPresence; exports.ChartStream = ChartStream; exports.DEFAULT_CHART_PALETTE = _chunkWPPJH6X4cjs.DEFAULT_CHART_PALETTE; exports.DEFAULT_CHART_THEME = _chunkWPPJH6X4cjs.DEFAULT_CHART_THEME; exports.MAX_CHART_DATA_LABELS = _chunk4YWAEV4Wcjs.MAX_CHART_DATA_LABELS; exports.MAX_CHART_LINE_POINTS = _chunk4YWAEV4Wcjs.MAX_CHART_LINE_POINTS; exports.MAX_CHART_MARKERS = _chunk4YWAEV4Wcjs.MAX_CHART_MARKERS; exports.OfficeChartsError = OfficeChartsError; exports.RENDER_CHART_INSTRUCTIONS = RENDER_CHART_INSTRUCTIONS; exports.analyzeChartTable = analyzeChartTable; exports.blendChartScenes = blendChartScenes; exports.canDragChartPoint = canDragChartPoint; exports.chartBoxStats = _chunk4YWAEV4Wcjs.chartBoxStats; exports.chartClientToScene = chartClientToScene; exports.chartColorDistance = _chunkWPPJH6X4cjs.chartColorDistance; exports.chartColorInputValue = _chunkWPPJH6X4cjs.chartColorInputValue; exports.chartColorsByCategory = _chunkWPPJH6X4cjs.chartColorsByCategory; exports.chartContrastRatio = _chunkWPPJH6X4cjs.chartContrastRatio; exports.chartDataFromTable = _chunkWPPJH6X4cjs.chartDataFromTable; exports.chartDataToTable = _chunkWPPJH6X4cjs.chartDataToTable; exports.chartDateLabels = _chunk4YWAEV4Wcjs.chartDateLabels; exports.chartDateToSerial = _chunk4YWAEV4Wcjs.chartDateToSerial; exports.chartErrorAmounts = _chunkWPPJH6X4cjs.chartErrorAmounts; exports.chartErrorBarsOfType = _chunkWPPJH6X4cjs.chartErrorBarsOfType; exports.chartFamily = _chunkWPPJH6X4cjs.chartFamily; exports.chartFileName = chartFileName; exports.chartFormatToCode = _chunk4T44CJ5Kcjs.chartFormatToCode; exports.chartFromMermaid = _chunkAKDWAWSYcjs.chartFromMermaid; exports.chartFromOoxml = _chunk4T44CJ5Kcjs.chartFromOoxml; exports.chartFromTable = chartFromTable; exports.chartHistogram = _chunk4YWAEV4Wcjs.chartHistogram; exports.chartHitTest = chartHitTest; exports.chartLuminance = _chunkWPPJH6X4cjs.chartLuminance; exports.chartMermaidFamily = _chunkAKDWAWSYcjs.chartMermaidFamily; exports.chartMovingAverage = _chunk4YWAEV4Wcjs.chartMovingAverage; exports.chartPointAnchor = chartPointAnchor; exports.chartPointColor = _chunkWPPJH6X4cjs.chartPointColor; exports.chartPointRef = chartPointRef; exports.chartPresetPatch = _chunkAKDWAWSYcjs.chartPresetPatch; exports.chartQuantile = _chunk4YWAEV4Wcjs.chartQuantile; exports.chartRasterSize = chartRasterSize; exports.chartRgbToHex = _chunkWPPJH6X4cjs.chartRgbToHex; exports.chartRgbToOklab = _chunkWPPJH6X4cjs.chartRgbToOklab; exports.chartScaleFromPixel = _chunk4YWAEV4Wcjs.chartScaleFromPixel; exports.chartScaleToPixel = _chunk4YWAEV4Wcjs.chartScaleToPixel; exports.chartSceneToDomSpec = _chunkAKDWAWSYcjs.chartSceneToDomSpec; exports.chartSceneToSvg = _chunkAKDWAWSYcjs.chartSceneToSvg; exports.chartSerialToDate = _chunk4YWAEV4Wcjs.chartSerialToDate; exports.chartSeriesColor = _chunkWPPJH6X4cjs.chartSeriesColor; exports.chartSeriesType = _chunkWPPJH6X4cjs.chartSeriesType; exports.chartSliceColor = _chunkWPPJH6X4cjs.chartSliceColor; exports.chartSquarify = _chunk4YWAEV4Wcjs.chartSquarify; exports.chartSupportsTrendlines = _chunk4YWAEV4Wcjs.chartSupportsTrendlines; exports.chartTextBaseline = _chunkAKDWAWSYcjs.chartTextBaseline; exports.chartTextOn = _chunkWPPJH6X4cjs.chartTextOn; exports.chartTextTransform = _chunkAKDWAWSYcjs.chartTextTransform; exports.chartToMermaid = _chunkAKDWAWSYcjs.chartToMermaid; exports.chartToOoxml = _chunk4T44CJ5Kcjs.chartToOoxml; exports.chartToSvg = _chunkAKDWAWSYcjs.chartToSvg; exports.chartTrendlineName = _chunk4YWAEV4Wcjs.chartTrendlineName; exports.chartValueAtPoint = _chunk4YWAEV4Wcjs.chartValueAtPoint; exports.chartXAtPoint = _chunk4YWAEV4Wcjs.chartXAtPoint; exports.checkChartColors = _chunkWPPJH6X4cjs.checkChartColors; exports.cloneChartSeries = _chunkWPPJH6X4cjs.cloneChartSeries; exports.cloneChartSpec = _chunkWPPJH6X4cjs.cloneChartSpec; exports.compileChartFormatCode = _chunk4YWAEV4Wcjs.compileChartFormatCode; exports.contrastingTextColor = _chunk4YWAEV4Wcjs.contrastingTextColor; exports.createChartCommands = createChartCommands; exports.createChartController = _chunkAKDWAWSYcjs.createChartController; exports.createChartEditorDocument = createChartEditorDocument; exports.createChartRasterizer = createChartRasterizer; exports.createChartSpec = _chunkWPPJH6X4cjs.createChartSpec; exports.createChartToolProvider = createChartToolProvider; exports.createInstantChartClock = createInstantChartClock; exports.createOfficeChartToolProvider = createOfficeChartToolProvider; exports.cyclePaletteColor = _chunkWPPJH6X4cjs.cyclePaletteColor; exports.decimateChartPoints = _chunk4YWAEV4Wcjs.decimateChartPoints; exports.defaultChartAxis = _chunkWPPJH6X4cjs.defaultChartAxis; exports.defaultChartErrorBarValue = _chunkWPPJH6X4cjs.defaultChartErrorBarValue; exports.describeChart = _chunkAKDWAWSYcjs.describeChart; exports.describeChartErrorBars = _chunkWPPJH6X4cjs.describeChartErrorBars; exports.describeChartSelection = describeChartSelection; exports.describeOfficeChartPlace = describeOfficeChartPlace; exports.downloadChartPng = downloadChartPng; exports.easeChartTween = easeChartTween; exports.estimateChartTextWidth = _chunk4YWAEV4Wcjs.estimateChartTextWidth; exports.extractDocxCharts = extractDocxCharts; exports.extractOfficeCharts = extractOfficeCharts; exports.extractPptxCharts = extractPptxCharts; exports.extractXlsxCharts = extractXlsxCharts; exports.findMermaidCharts = _chunkAKDWAWSYcjs.findMermaidCharts; exports.fitChartTrendline = _chunk4YWAEV4Wcjs.fitChartTrendline; exports.formatChartAmountList = _chunkWPPJH6X4cjs.formatChartAmountList; exports.formatChartDate = _chunk4YWAEV4Wcjs.formatChartDate; exports.formatChartNumber = _chunk4YWAEV4Wcjs.formatChartNumber; exports.formatChartValueWithCode = _chunk4YWAEV4Wcjs.formatChartValueWithCode; exports.handleChartKey = handleChartKey; exports.isCartesianChart = _chunkWPPJH6X4cjs.isCartesianChart; exports.isXyChart = _chunkWPPJH6X4cjs.isXyChart; exports.layoutChart = _chunk4YWAEV4Wcjs.layoutChart; exports.layoutSparkline = _chunkAKDWAWSYcjs.layoutSparkline; exports.linearMap = _chunk4YWAEV4Wcjs.linearMap; exports.locateChartPoint = locateChartPoint; exports.monochromeChartPalette = _chunkAKDWAWSYcjs.monochromeChartPalette; exports.niceLogScale = _chunk4YWAEV4Wcjs.niceLogScale; exports.niceScale = _chunk4YWAEV4Wcjs.niceScale; exports.niceStep = _chunk4YWAEV4Wcjs.niceStep; exports.normalizeChartAxis = _chunkWPPJH6X4cjs.normalizeChartAxis; exports.normalizeChartErrorBars = _chunkWPPJH6X4cjs.normalizeChartErrorBars; exports.normalizeChartSpec = _chunkWPPJH6X4cjs.normalizeChartSpec; exports.normalizeChartTrendline = _chunkWPPJH6X4cjs.normalizeChartTrendline; exports.normalizeChartValues = _chunkWPPJH6X4cjs.normalizeChartValues; exports.parseChartAmountList = _chunkWPPJH6X4cjs.parseChartAmountList; exports.parseChartColor = _chunkWPPJH6X4cjs.parseChartColor; exports.parseChartDate = _chunk4YWAEV4Wcjs.parseChartDate; exports.parseChartValue = _chunkWPPJH6X4cjs.parseChartValue; exports.parsePartialChartJson = parsePartialChartJson; exports.planChartCommand = planChartCommand; exports.planChartToolPlayback = planChartToolPlayback; exports.rasterizeChartSvg = rasterizeChartSvg; exports.realChartClock = realChartClock; exports.recommendChartTypes = recommendChartTypes; exports.recommendForShape = recommendForShape; exports.resolveChartSvgPaints = resolveChartSvgPaints; exports.sameChartSelection = _chunk4YWAEV4Wcjs.sameChartSelection; exports.shadeChartColor = _chunkWPPJH6X4cjs.shadeChartColor; exports.simulateChartVision = _chunkWPPJH6X4cjs.simulateChartVision; exports.snapChartDragValue = snapChartDragValue; exports.snapChartValue = _chunk4YWAEV4Wcjs.snapChartValue; exports.sparklineToSvg = _chunkAKDWAWSYcjs.sparklineToSvg; exports.startChartPointDrag = startChartPointDrag; exports.stepDecimals = _chunk4YWAEV4Wcjs.stepDecimals; exports.summarizeChart = _chunkAKDWAWSYcjs.summarizeChart; exports.summarizeChartSeries = _chunk4YWAEV4Wcjs.summarizeChartSeries; exports.trendNumberText = _chunk4YWAEV4Wcjs.trendNumberText; exports.uniqueChartSeriesId = _chunkWPPJH6X4cjs.uniqueChartSeriesId; exports.withChartPlayback = withChartPlayback;
|