@sheetxl/react 0.8.0-beta.1 → 0.8.0-beta.11
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/browser/esm/1-LEUre9ZLG0OYYB.mjs +197 -0
- package/browser/esm/94dxo1A-z8lgiiGw.mjs +128 -0
- package/browser/esm/B26QVfjer2oY2ewK.mjs +32 -0
- package/browser/esm/B93LSmhnvkxNXTq-.mjs +42 -0
- package/browser/esm/BQYS2Yf-EAV_tBLr.mjs +20 -0
- package/{node/esm/DAE_NG8D9uT50zUH.mjs → browser/esm/BegvsXeRs7e-9t8k.mjs} +3 -4
- package/browser/esm/Bl2BFCQ00fotauKB.mjs +36 -0
- package/browser/esm/Bos4Rkp8UTF7QXUB.mjs +31 -0
- package/browser/esm/C1pc9F4Rt2C5FKUo.mjs +45 -0
- package/browser/esm/CPnnESfZz2jjJd82.mjs +134 -0
- package/browser/esm/CRi6DQ3UXmPEv-w_.mjs +729 -0
- package/browser/esm/ClAtIfYbsUPA073B.mjs +2706 -0
- package/browser/esm/CzRIbc-Lk__VMLKM.mjs +60 -0
- package/browser/esm/D2u6THGErqw64KQI.mjs +63 -0
- package/browser/esm/DMdsMPT0fWBbTkNn.mjs +67 -0
- package/browser/esm/DS66lAIM-9M-YoZQ.mjs +315 -0
- package/browser/esm/DgL7Dy-Lqcr1TvW6.mjs +23528 -0
- package/browser/esm/Dnh1kpz3v1JKtRD_.mjs +79 -0
- package/browser/esm/cQ6xdPFkEcuDlNTN.mjs +75 -0
- package/browser/esm/chart.mjs +40 -0
- package/browser/esm/control.mjs +216 -0
- package/browser/esm/group.mjs +123 -0
- package/browser/esm/index.mjs +15460 -8762
- package/browser/esm/note.mjs +112 -0
- package/browser/esm/picture.mjs +86 -0
- package/browser/esm/shape.mjs +7 -0
- package/browser/esm/slicer.mjs +276 -0
- package/browser/esm/ugfE7YeZALQURDKF.mjs +241 -0
- package/licenses/dependencies.txt +319 -600
- package/node/esm/6zApGj9DozhFy-bx.mjs +35 -0
- package/node/esm/BMVK5plvmBOAIlxP.mjs +80 -0
- package/node/esm/BaRfst1euuhquupX.mjs +66 -0
- package/node/esm/Be9c1GwQkPo8Piuh.mjs +134 -0
- package/node/esm/BiaDWnN3tT7neoRL.mjs +68 -0
- package/node/esm/BlxXufqBBg1PtsXd.mjs +8 -0
- package/node/esm/C_SNx7TlFEcwbYjx.mjs +2706 -0
- package/node/esm/DJPgbB1X22YmhbaR.mjs +242 -0
- package/node/esm/DTMTIrYIK1eZswsM.mjs +37 -0
- package/node/esm/D_pCpfdQowV_4Aje.mjs +198 -0
- package/node/esm/DgGEHydEjD7nfsDB.mjs +76 -0
- package/node/esm/Dj5FM7_-YWhCtCCt.mjs +45 -0
- package/node/esm/DxQZmb-j4NLUO9Af.mjs +63 -0
- package/node/esm/JiQGhLkoL8CJpVvA.mjs +20 -0
- package/node/esm/b-XRVRI1fYQQMkTC.mjs +1664 -0
- package/node/esm/chart.mjs +40 -0
- package/node/esm/control.mjs +216 -0
- package/node/esm/gpD-9LDW92phhoma.mjs +32 -0
- package/node/esm/group.mjs +123 -0
- package/node/esm/index.mjs +15830 -8966
- package/node/esm/note.mjs +113 -0
- package/node/esm/picture.mjs +86 -0
- package/node/esm/shape.mjs +735 -0
- package/node/esm/sigD1UFqvPlWUw_9.mjs +128 -0
- package/node/esm/slicer.mjs +278 -0
- package/node/esm/umljAT66yb3_rURh.mjs +320 -0
- package/package.json +55 -14
- package/resources/contents.json +24 -0
- package/resources/locales/contents.json +56 -0
- package/resources/locales/de/chart.cmd.json +82 -0
- package/resources/locales/de/movable.cmd.json +154 -0
- package/resources/locales/de/picture.cmd.json +31 -0
- package/resources/locales/de/selection.cmd.json +8 -0
- package/resources/locales/de/shape.cmd.json +17 -0
- package/resources/locales/de/sheet.cmd.json +339 -21
- package/resources/locales/de/slicer.cmd.json +17 -0
- package/resources/locales/de/table.cmd.json +9 -1
- package/resources/locales/de/ui.msg.json +321 -3
- package/resources/locales/de/workbook.cmd.json +15 -6
- package/resources/locales/en/chart.cmd.json +82 -0
- package/resources/locales/en/movable.cmd.json +154 -0
- package/resources/locales/en/picture.cmd.json +31 -0
- package/resources/locales/en/selection.cmd.json +8 -0
- package/resources/locales/en/shape.cmd.json +17 -0
- package/resources/locales/en/sheet.cmd.json +353 -22
- package/resources/locales/en/slicer.cmd.json +17 -0
- package/resources/locales/en/table.cmd.json +9 -1
- package/resources/locales/en/ui.msg.json +321 -3
- package/resources/locales/en/workbook.cmd.json +16 -7
- package/types/chart.d.ts +2 -0
- package/types/control.d.ts +2 -0
- package/types/group.d.ts +2 -0
- package/types/note.d.ts +2 -0
- package/types/picture.d.ts +2 -0
- package/types/shape.d.ts +2 -0
- package/types/slicer.d.ts +2 -0
- package/types/src/annotation/RangeAnnotations.d.ts +119 -0
- package/types/src/annotation/index.d.ts +2 -0
- package/types/src/autoFill/AutoFillPresets.d.ts +14 -0
- package/types/src/autoFill/FillMenu.d.ts +36 -0
- package/types/src/autoFill/FillSeries.d.ts +38 -0
- package/types/src/autoFill/index.d.ts +4 -0
- package/types/src/border/StaticBorderRenderer.d.ts +19 -2
- package/types/src/border/useBorders.d.ts +81 -8
- package/types/src/cell/CornerTriangle.d.ts +6 -0
- package/types/src/cell/FormulaCellRenderer.d.ts +6 -3
- package/types/src/cell/OutlineButton.d.ts +123 -0
- package/types/src/cell/SheetCellRenderer.d.ts +2 -2
- package/types/src/cell/SheetHeaderRenderer.d.ts +5 -0
- package/types/src/cell/StaticCellRenderer.d.ts +57 -0
- package/types/src/cell/index.d.ts +2 -0
- package/types/src/cell/useFormulaViewAnchor.d.ts +3 -3
- package/types/src/chart/ChartCommands.d.ts +15 -0
- package/types/src/chart/ChartEditor.d.ts +10 -2
- package/types/src/chart/ChartElement.d.ts +111 -0
- package/types/src/chart/ChartKind.d.ts +7 -0
- package/types/src/chart/PresetChartTypeDescriptors.d.ts +3 -1
- package/types/src/chart/index.d.ts +2 -1
- package/types/src/chart/paint/_fills.d.ts +24 -0
- package/types/src/chart/paint/_graphics.d.ts +46 -0
- package/types/src/chart/paint/echarts.d.ts +30 -0
- package/types/src/chart/paint/index.d.ts +12 -0
- package/types/src/chart/paint/kinds/ChartPaintKind.d.ts +132 -0
- package/types/src/chart/paint/kinds/_Area.d.ts +3 -0
- package/types/src/chart/paint/kinds/_Bar.d.ts +3 -0
- package/types/src/chart/paint/kinds/_BoxWhisker.d.ts +3 -0
- package/types/src/chart/paint/kinds/_Bubble.d.ts +3 -0
- package/types/src/chart/paint/kinds/_Funnel.d.ts +3 -0
- package/types/src/chart/paint/kinds/_Histogram.d.ts +3 -0
- package/types/src/chart/paint/kinds/_Line.d.ts +10 -0
- package/types/src/chart/paint/kinds/_OfPie.d.ts +3 -0
- package/types/src/chart/paint/kinds/_Pie.d.ts +21 -0
- package/types/src/chart/paint/kinds/_Placeholder.d.ts +7 -0
- package/types/src/chart/paint/kinds/_Radar.d.ts +3 -0
- package/types/src/chart/paint/kinds/_Scatter.d.ts +3 -0
- package/types/src/chart/paint/kinds/_Sunburst.d.ts +3 -0
- package/types/src/chart/paint/kinds/_Surface.d.ts +3 -0
- package/types/src/chart/paint/kinds/_Treemap.d.ts +3 -0
- package/types/src/chart/paint/kinds/_Waterfall.d.ts +3 -0
- package/types/src/chart/paint/kinds/_builtIns.d.ts +12 -0
- package/types/src/chart/paint/toEChartsOption.d.ts +31 -0
- package/types/src/checklist/ValueChecklist.d.ts +112 -0
- package/types/src/checklist/index.d.ts +2 -0
- package/types/src/clipboard/ClipboardCommands.d.ts +3 -3
- package/types/src/clipboard/SheetClipboardLayer.d.ts +2 -2
- package/types/src/commands/ContextualToolbar.d.ts +19 -0
- package/types/src/commands/createTransactionalMiddleware.d.ts +4 -1
- package/types/src/commands/index.d.ts +1 -0
- package/types/src/comment/CommentCardRequest.d.ts +94 -0
- package/types/src/comment/CommentUtils.d.ts +43 -0
- package/types/src/comment/NoteEditor.d.ts +20 -0
- package/types/src/comment/index.d.ts +5 -0
- package/types/src/comment/useCommentThread.d.ts +37 -0
- package/types/src/comment/useSheetComments.d.ts +28 -0
- package/types/src/{sheet → conditionalFormat}/ConditionalFormatPresets.d.ts +6 -6
- package/types/src/conditionalFormat/index.d.ts +1 -0
- package/types/src/context/WorksheetContext.d.ts +18 -0
- package/types/src/context/index.d.ts +1 -1
- package/types/src/control/FormControlRenderers.d.ts +22 -0
- package/types/src/editor/EditorCommands.d.ts +3 -3
- package/types/src/editor/FunctionPreviewPanel.d.ts +15 -1
- package/types/src/editor/NamedItemLabel.d.ts +29 -0
- package/types/src/editor/NamedItemsPanel.d.ts +13 -2
- package/types/src/editor/SheetCellEditorLayer.d.ts +5 -9
- package/types/src/editor/SheetCellEditorStartLayer.d.ts +61 -0
- package/types/src/editor/SheetCellInput.d.ts +26 -2
- package/types/src/editor/SheetEditable.d.ts +14 -8
- package/types/src/editor/SheetReferenceLayer.d.ts +4 -4
- package/types/src/editor/VirtualKeyboardLayer.d.ts +49 -0
- package/types/src/editor/formulaAnchor.d.ts +12 -0
- package/types/src/editor/formulaCaret.d.ts +39 -10
- package/types/src/editor/formulaEval.d.ts +9 -5
- package/types/src/editor/formulaLint.d.ts +36 -0
- package/types/src/editor/formulaPresentation.d.ts +7 -0
- package/types/src/editor/formulaText.d.ts +17 -5
- package/types/src/editor/functionArgs.d.ts +20 -0
- package/types/src/editor/index.d.ts +5 -1
- package/types/src/editor/pickedReference.d.ts +76 -0
- package/types/src/editor/useEditRejectedNotice.d.ts +32 -0
- package/types/src/editor/useFormulaHints.d.ts +95 -5
- package/types/src/editor/useFormulaInput.d.ts +30 -4
- package/types/src/editor/useReferenceMode.d.ts +12 -0
- package/types/src/editor/validationAlert.d.ts +24 -0
- package/types/src/externalLink/ExternalLinksPaneArgs.d.ts +23 -0
- package/types/src/externalLink/index.d.ts +2 -0
- package/types/src/form/FormulaInput.d.ts +18 -2
- package/types/src/form/FormulaInputParts.d.ts +10 -1
- package/types/src/form/useEditCommit.d.ts +23 -3
- package/types/src/form/useInputField.d.ts +2 -3
- package/types/src/frame/CommandContext.d.ts +189 -7
- package/types/src/group/GroupEditor.d.ts +25 -0
- package/types/src/index.d.ts +14 -2
- package/types/src/io/WorkbookIO.d.ts +2 -0
- package/types/src/layer/BorderLayer.d.ts +2 -2
- package/types/src/layer/CellErrorLayer.d.ts +26 -9
- package/types/src/layer/CellFillLayer.d.ts +2 -2
- package/types/src/layer/CellInsertLayer.d.ts +71 -0
- package/types/src/layer/CircularIndicatorLayer.d.ts +2 -2
- package/types/src/layer/CommentCardLayer.d.ts +43 -0
- package/types/src/layer/CommentsLayer.d.ts +35 -0
- package/types/src/layer/ConditionalBarLayer.d.ts +2 -2
- package/types/src/layer/ConditionalIcons.d.ts +4 -4
- package/types/src/layer/ConditionalIconsLayer.d.ts +2 -2
- package/types/src/layer/ContextMenuLayer.d.ts +2 -2
- package/types/src/layer/FreezeDragLines.d.ts +17 -0
- package/types/src/layer/GridFreezeLayer.d.ts +11 -0
- package/types/src/layer/HeaderFreezeLayer.d.ts +12 -0
- package/types/src/layer/HeaderResizerLayer.d.ts +2 -1
- package/types/src/layer/HyperlinkLayer.d.ts +109 -0
- package/types/src/layer/MovableKindScope.d.ts +17 -0
- package/types/src/layer/ProtectionLayer.d.ts +52 -0
- package/types/src/layer/RangeAnnotationLayer.d.ts +71 -0
- package/types/src/layer/ResizeIndicator.d.ts +11 -10
- package/types/src/layer/ResizeTooltip.d.ts +13 -0
- package/types/src/layer/SheetBackgroundLayer.d.ts +3 -3
- package/types/src/layer/SheetCellLayer.d.ts +4 -4
- package/types/src/layer/SheetColumnButtonLayer.d.ts +2 -2
- package/types/src/layer/SheetGridLineLayer.d.ts +11 -13
- package/types/src/layer/SheetHeaderCellLayer.d.ts +10 -1
- package/types/src/layer/SheetLayers.d.ts +115 -0
- package/types/src/layer/SheetMovableLayer.d.ts +2 -2
- package/types/src/layer/SheetOutlineLayer.d.ts +40 -0
- package/types/src/layer/SheetTableCommandLayer.d.ts +2 -2
- package/types/src/layer/SpillLayer.d.ts +2 -2
- package/types/src/layer/TableLayer.d.ts +6 -5
- package/types/src/layer/TableToolbar.d.ts +42 -0
- package/types/src/layer/ValidationDropdownLayer.d.ts +17 -7
- package/types/src/layer/ValidationIndicatorLayer.d.ts +11 -5
- package/types/src/layer/ValidationPromptLayer.d.ts +65 -0
- package/types/src/layer/_tableColor.d.ts +4 -0
- package/types/src/layer/cellTip.d.ts +13 -0
- package/types/src/layer/freezeDragState.d.ts +21 -0
- package/types/src/layer/index.d.ts +14 -1
- package/types/src/layer/resizeIndicatorState.d.ts +3 -1
- package/types/src/layer/useFreezeDrag.d.ts +22 -0
- package/types/src/layer/useNormalBorderLines.d.ts +15 -0
- package/types/src/layer/useSheetFeatureRegions.d.ts +2 -2
- package/types/src/layer/useSheetVisibleCells.d.ts +2 -2
- package/types/src/layer/useSheetVisibleDecorations.d.ts +2 -2
- package/types/src/layer/useTableHeaderCells.d.ts +2 -2
- package/types/src/layer/useValidationPicker.d.ts +37 -37
- package/types/src/layer/useVisibleTables.d.ts +2 -2
- package/types/src/layer/validationMark.d.ts +63 -0
- package/types/src/listener/index.d.ts +5 -0
- package/types/src/listener/useCell.d.ts +29 -0
- package/types/src/listener/useCellRange.d.ts +23 -0
- package/types/src/listener/useCellValue.d.ts +26 -0
- package/types/src/listener/useModelListener.d.ts +8 -8
- package/types/src/listener/useRangeSnapshot.d.ts +35 -0
- package/types/src/listener/useTable.d.ts +26 -0
- package/types/src/movable/ConnectionSites.d.ts +18 -0
- package/types/src/movable/DefaultMovable.d.ts +8 -0
- package/types/src/movable/IMovableArea.d.ts +56 -0
- package/types/src/movable/MovableAdornment.d.ts +26 -0
- package/types/src/movable/MovableCommandGroups.d.ts +40 -0
- package/types/src/movable/MovableCommands.d.ts +8 -3
- package/types/src/movable/MovableControl.d.ts +78 -0
- package/types/src/movable/MovableEdit.d.ts +22 -0
- package/types/src/movable/MovableFrame.d.ts +16 -13
- package/types/src/movable/MovableLayer.d.ts +25 -7
- package/types/src/movable/MovableRenderers.d.ts +210 -0
- package/types/src/movable/PlaceholderFrames.d.ts +11 -0
- package/types/src/movable/RotateHandle.d.ts +37 -0
- package/types/src/movable/TextBox.d.ts +34 -0
- package/types/src/movable/connect.d.ts +16 -0
- package/types/src/movable/framePlacement.d.ts +72 -0
- package/types/src/movable/geometry.d.ts +61 -0
- package/types/src/movable/index.d.ts +11 -0
- package/types/src/movable/pressTarget.d.ts +20 -0
- package/types/src/picker/PickerPanel.d.ts +52 -0
- package/types/src/picker/cellPickerOpen.d.ts +6 -0
- package/types/src/picker/index.d.ts +4 -0
- package/types/src/picker/useCellPicker.d.ts +95 -0
- package/types/src/picture/PictureCommands.d.ts +12 -0
- package/types/src/picture/PictureKind.d.ts +7 -0
- package/types/src/picture/index.d.ts +0 -1
- package/types/src/protection/ProtectionPaneArgs.d.ts +31 -0
- package/types/src/protection/index.d.ts +3 -0
- package/types/src/protection/unlockProtectedRanges.d.ts +23 -0
- package/types/src/richText/RichTextEditor.d.ts +41 -0
- package/types/src/richText/index.d.ts +2 -0
- package/types/src/selection/SelectionCommands.d.ts +2 -2
- package/types/src/selection/SheetSelectionLayer.d.ts +16 -12
- package/types/src/shape/ConnectorControl.d.ts +46 -0
- package/types/src/shape/ShapeCommands.d.ts +11 -0
- package/types/src/shape/ShapeControl.d.ts +8 -0
- package/types/src/shape/ShapeEditor.d.ts +15 -2
- package/types/src/shape/ShapeGallery.d.ts +31 -0
- package/types/src/shape/ShapeHandles.d.ts +28 -0
- package/types/src/shape/ShapeKind.d.ts +7 -0
- package/types/src/shape/ShapeSVG.d.ts +22 -0
- package/types/src/shape/ShapeText.d.ts +17 -0
- package/types/src/shape/icons/ShapeIcons.d.ts +16 -0
- package/types/src/shape/icons/_ShapeIconPack.d.ts +4 -0
- package/types/src/shape/index.d.ts +3 -1
- package/types/src/shape/shapeFrame.d.ts +50 -0
- package/types/src/shape/shapeStyle.d.ts +82 -0
- package/types/src/sheet/ISheetHeaderElement.d.ts +1 -1
- package/types/src/sheet/{ISheetElement.d.ts → IWorksheetElement.d.ts} +107 -77
- package/types/src/sheet/OpaqueSheetElement.d.ts +21 -0
- package/types/src/sheet/SheetCommandProvider.d.ts +11 -6
- package/types/src/sheet/SheetCommands.d.ts +22 -7
- package/types/src/sheet/SheetKindIcon.d.ts +14 -0
- package/types/src/sheet/SheetOutlineElement.d.ts +70 -0
- package/types/src/sheet/SheetPanels.d.ts +11 -0
- package/types/src/sheet/SheetScrollbar.d.ts +4 -13
- package/types/src/sheet/TopLeftCorner.d.ts +2 -2
- package/types/src/sheet/WorksheetElement.d.ts +12 -0
- package/types/src/sheet/_freezeAt.d.ts +10 -0
- package/types/src/sheet/_useHeaderMetrics.d.ts +11 -0
- package/types/src/sheet/circularReferences.d.ts +12 -4
- package/types/src/sheet/index.d.ts +6 -3
- package/types/src/sheet/useCycleHighlight.d.ts +21 -0
- package/types/src/slicer/SlicerCommands.d.ts +10 -0
- package/types/src/slicer/SlicerEditor.d.ts +8 -2
- package/types/src/slicer/SlicerKind.d.ts +7 -0
- package/types/src/slicer/SlicerStylePreview.d.ts +18 -0
- package/types/src/slicer/index.d.ts +2 -1
- package/types/src/slicer/slicerStyles.d.ts +32 -0
- package/types/src/tabStrip/SheetTab.d.ts +1 -1
- package/types/src/tabStrip/TabStrip.d.ts +7 -0
- package/types/src/table/TableCommands.d.ts +2 -2
- package/types/src/taskPane/ITaskPane.d.ts +12 -1
- package/types/src/taskPane/MovablePane.d.ts +17 -0
- package/types/src/taskPane/TaskPaneArea.d.ts +7 -0
- package/types/src/taskPane/index.d.ts +1 -0
- package/types/src/theme/ThemeState.d.ts +14 -1
- package/types/src/theme/buildOOXMLThemeCSS.d.ts +2 -2
- package/types/src/theme/useGridColorScheme.d.ts +2 -2
- package/types/src/theme/useSystemColors.d.ts +2 -2
- package/types/src/workbook/DefaultMovableRenderers.d.ts +20 -0
- package/types/src/workbook/DefaultRenderers.d.ts +3 -2
- package/types/src/workbook/IWorkbookElement.d.ts +51 -5
- package/types/src/workbook/WorkbookCommands.d.ts +2 -4
- package/types/src/workbook/WorkbookStrip.d.ts +9 -0
- package/types/src/workbook/_followOrigin.d.ts +9 -0
- package/types/src/workbook/useWorkbookFormat.d.ts +3 -3
- package/browser/cjs/Bo9Kx3L_XQkGPBJ5.cjs +0 -1
- package/browser/cjs/Pl04-kDEQSO8_qFU.cjs +0 -156
- package/browser/cjs/index.cjs +0 -35
- package/browser/esm/SJMJzBwlXTJ9QIO5.mjs +0 -6286
- package/types/src/chart/templates/area-stacked-percent-template.json.d.ts +0 -10
- package/types/src/chart/templates/area-stacked-template.json.d.ts +0 -10
- package/types/src/chart/templates/area-template.json.d.ts +0 -9
- package/types/src/chart/templates/bar-stacked-percent-template.json.d.ts +0 -10
- package/types/src/chart/templates/bar-stacked-template.json.d.ts +0 -10
- package/types/src/chart/templates/bar-template.json.d.ts +0 -9
- package/types/src/chart/templates/column-stacked-percent-template.json.d.ts +0 -10
- package/types/src/chart/templates/column-stacked-template.json.d.ts +0 -10
- package/types/src/chart/templates/column-template.json.d.ts +0 -9
- package/types/src/chart/templates/line-markers-template.json.d.ts +0 -10
- package/types/src/chart/templates/line-stacked-markers-template.json.d.ts +0 -11
- package/types/src/chart/templates/line-stacked-percent-markers-template.json.d.ts +0 -11
- package/types/src/chart/templates/line-stacked-percent-template.json.d.ts +0 -10
- package/types/src/chart/templates/line-stacked-template.json.d.ts +0 -10
- package/types/src/chart/templates/line-template.json.d.ts +0 -9
- package/types/src/chart/templates/pie-doughnut-template.json.d.ts +0 -10
- package/types/src/chart/templates/pie-template.json.d.ts +0 -9
- package/types/src/chart/templates/scatter-lines-markers-smooth-template.json.d.ts +0 -10
- package/types/src/chart/templates/scatter-lines-markers-template.json.d.ts +0 -10
- package/types/src/chart/templates/scatter-lines-smooth-template.json.d.ts +0 -10
- package/types/src/chart/templates/scatter-lines-template.json.d.ts +0 -10
- package/types/src/chart/templates/scatter-markers-template.json.d.ts +0 -10
- package/types/src/context/SheetContext.d.ts +0 -18
- package/types/src/editor/useProtectedEditNotice.d.ts +0 -14
- package/types/src/layer/validationList.d.ts +0 -84
- package/types/src/list/SheetValueList.d.ts +0 -93
- package/types/src/list/index.d.ts +0 -2
- package/types/src/movable/MoveableBundle.d.ts +0 -4
- package/types/src/sheet/SheetElement.d.ts +0 -15
|
@@ -0,0 +1,111 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { IChart, IChartElementSelection } from '@sheetxl/sdk';
|
|
3
|
+
import { Point } from '@sheetxl/utils';
|
|
4
|
+
export interface ChartElementAttributes {
|
|
5
|
+
isChartElement: () => true;
|
|
6
|
+
/** The chart drawn; `null` until a `Promise` input resolves. */
|
|
7
|
+
getChart: () => IChart | null;
|
|
8
|
+
/**
|
|
9
|
+
* The chart as it is drawn now, as an SVG document of the element's unzoomed size; `null` while
|
|
10
|
+
* the chart has no layout or the element no size.
|
|
11
|
+
*/
|
|
12
|
+
toSVG: () => Promise<string | null>;
|
|
13
|
+
/**
|
|
14
|
+
* The chart element drawn under a point of the page (`clientX`, `clientY`), as the chart is
|
|
15
|
+
* painted now; `null` outside the chart, or before it is painted.
|
|
16
|
+
*/
|
|
17
|
+
getElementAt: (clientX: number, clientY: number) => IChart.IElement | null;
|
|
18
|
+
}
|
|
19
|
+
export interface IChartElement extends HTMLDivElement, ChartElementAttributes {
|
|
20
|
+
}
|
|
21
|
+
/** A press on the chart, as {@link ChartElementProps.onElementPress} reports it. */
|
|
22
|
+
export interface ChartElementPress {
|
|
23
|
+
/** The element under the pointer; `null` outside the chart. The chart area is the chart itself. */
|
|
24
|
+
element: IChart.IElement | null;
|
|
25
|
+
/** Where, in px from the chart's top-left, unzoomed. */
|
|
26
|
+
point: Point;
|
|
27
|
+
event: React.PointerEvent<HTMLDivElement>;
|
|
28
|
+
}
|
|
29
|
+
export interface ChartElementProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
30
|
+
/**
|
|
31
|
+
* The chart to draw: one in a workbook, or one made outside it with `createChart`, or a
|
|
32
|
+
* `Promise` for either. A promise draws nothing until it resolves and shows the error if it
|
|
33
|
+
* rejects; while a later promise resolves, the chart already drawn is kept.
|
|
34
|
+
*
|
|
35
|
+
* This can be accessed (once resolved) via the element ref.
|
|
36
|
+
*/
|
|
37
|
+
chart: IChart | Promise<IChart>;
|
|
38
|
+
/**
|
|
39
|
+
* Called with the chart once {@link ChartElementProps.chart} resolves, and again whenever a new
|
|
40
|
+
* input resolves to a different one. Until the first input resolves, or if an input fails, the
|
|
41
|
+
* chart is `null`.
|
|
42
|
+
*
|
|
43
|
+
* @remarks
|
|
44
|
+
* Lets an app pass a `Promise` here and hold the live chart in its own state, without awaiting
|
|
45
|
+
* or suspending.
|
|
46
|
+
*
|
|
47
|
+
* @example
|
|
48
|
+
* ```tsx
|
|
49
|
+
* const [pending] = useState(() => sheet.getCharts().add('A1:D5', { type: 'line' }));
|
|
50
|
+
* const [chart, setChart] = useState<IChart | null>(null);
|
|
51
|
+
* return <ChartElement chart={pending} onChartChange={setChart} />;
|
|
52
|
+
* ```
|
|
53
|
+
*/
|
|
54
|
+
onChartChange?: (chart: IChart | null) => void;
|
|
55
|
+
/**
|
|
56
|
+
* The scale the chart is drawn at, where `1` is unscaled: the element's box is measured at the
|
|
57
|
+
* scale and the chart laid out at the unscaled size.
|
|
58
|
+
* @defaultValue 1
|
|
59
|
+
*/
|
|
60
|
+
zoom?: number;
|
|
61
|
+
/**
|
|
62
|
+
* The element's width, as `style.width`; by default the element fills its parent. A number is
|
|
63
|
+
* taken as the box's width without waiting to measure it.
|
|
64
|
+
*/
|
|
65
|
+
width?: number | string;
|
|
66
|
+
/** The element's height, as `style.height`; a number as the box's height. */
|
|
67
|
+
height?: number | string;
|
|
68
|
+
/**
|
|
69
|
+
* The selection a press inside the chart changes, and whose selected elements are outlined: the
|
|
70
|
+
* sheet view's (`getChartElementSelection`) for a chart on a sheet, or one made for the chart
|
|
71
|
+
* (`new ChartElementSelection({ chart })`). Without one, a press selects nothing.
|
|
72
|
+
*
|
|
73
|
+
* @remarks
|
|
74
|
+
* As in Excel, the first press on a series selects the series and the next one its point; on
|
|
75
|
+
* the legend, the legend and then its entry; on a series' labels, all of them and then the one.
|
|
76
|
+
* A press on the chart area empties the selection: the chart is then what is selected.
|
|
77
|
+
*/
|
|
78
|
+
selection?: IChartElementSelection | null;
|
|
79
|
+
/**
|
|
80
|
+
* Called on a press inside the chart with what is under the pointer, before the selection (if
|
|
81
|
+
* any) changes.
|
|
82
|
+
*/
|
|
83
|
+
onElementPress?: (press: ChartElementPress) => void;
|
|
84
|
+
ref?: React.Ref<IChartElement>;
|
|
85
|
+
}
|
|
86
|
+
/**
|
|
87
|
+
* The element a press selects, given what is under the pointer and what is selected: Excel's two
|
|
88
|
+
* steps, the whole first and the part of it on the next press.
|
|
89
|
+
*/
|
|
90
|
+
export declare const nextSelected: (hit: IChart.IElement, active: IChart.IElement | null) => IChart.IElement;
|
|
91
|
+
/**
|
|
92
|
+
* Draws a chart, anywhere: a `div` the chart fills.
|
|
93
|
+
*
|
|
94
|
+
* @remarks
|
|
95
|
+
* The chart is laid out at the box's unzoomed px (`IChart.getLayout`) and painted as laid out,
|
|
96
|
+
* so the same chart in two elements is drawn twice, each at its own size. It is laid out again
|
|
97
|
+
* when the box is resized and whenever the chart says its layout may have changed
|
|
98
|
+
* (`onLayoutChange`: an edit, a cell it plots, a font arriving). The painter is loaded on the
|
|
99
|
+
* first mount through `ChartPaint`; a chart with no model (a `cx:` chart) draws nothing.
|
|
100
|
+
*
|
|
101
|
+
* Nothing of a sheet or a movable is needed: `ChartEditor` is this element inside a movable's
|
|
102
|
+
* frame, and a chart made with `createChart` draws from its own JSON. The chart may be given as a
|
|
103
|
+
* `Promise` (the one `getCharts().add` answers, say); `onChartChange` hands the app the chart
|
|
104
|
+
* once it is there.
|
|
105
|
+
*
|
|
106
|
+
* A press inside the chart is hit-tested against the layout painted (`IChart.getElementAt`), and
|
|
107
|
+
* with a {@link ChartElementProps.selection} selects what is pressed, Excel's way; the selected
|
|
108
|
+
* elements are outlined over the chart.
|
|
109
|
+
*/
|
|
110
|
+
export declare const ChartElement: React.NamedExoticComponent<Omit<ChartElementProps, "ref"> & React.RefAttributes<IChartElement>>;
|
|
111
|
+
//# sourceMappingURL=ChartElement.d.ts.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { MovableRendererModule } from '../movable/MovableRenderers';
|
|
2
|
+
/**
|
|
3
|
+
* The chart kind, as the renderer registry loads it: one module, so a failed fetch can be
|
|
4
|
+
* imported again whole.
|
|
5
|
+
*/
|
|
6
|
+
export declare const ChartKind: MovableRendererModule;
|
|
7
|
+
//# sourceMappingURL=ChartKind.d.ts.map
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { default as React } from 'react';
|
|
2
|
+
import { IChart } from '@sheetxl/sdk';
|
|
2
3
|
export declare const PresetChartType: {
|
|
3
4
|
readonly Column: "column";
|
|
4
5
|
readonly ColumnStacked: "columnStacked";
|
|
@@ -29,7 +30,8 @@ export type PresetChartType = typeof PresetChartType[keyof typeof PresetChartTyp
|
|
|
29
30
|
export interface ChartTypeDescriptor {
|
|
30
31
|
Icon: React.FC<React.SVGProps<SVGSVGElement>>;
|
|
31
32
|
description: string;
|
|
32
|
-
|
|
33
|
+
/** The chart type the gallery entry inserts. */
|
|
34
|
+
type: IChart.Type;
|
|
33
35
|
}
|
|
34
36
|
export declare const presetChartTypeDescriptor: (presetType: PresetChartType) => ChartTypeDescriptor;
|
|
35
37
|
//# sourceMappingURL=PresetChartTypeDescriptors.d.ts.map
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
-
export * from './ChartEditor';
|
|
2
1
|
export * from './PresetChartTypeDescriptors';
|
|
2
|
+
export { ChartPaintKinds, type ChartPaintKind } from './paint/kinds/ChartPaintKind';
|
|
3
|
+
export { ChartElement, nextSelected, type ChartElementProps, type ChartElementAttributes, type ChartElementPress, type IChartElement } from './ChartElement';
|
|
3
4
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { IFill, IStroke, IText } from '@sheetxl/sdk';
|
|
2
|
+
/** A pattern preset's tile, row by row; `null` for a name that is not one of Excel's. */
|
|
3
|
+
export declare const patternTile: (preset: string | undefined) => boolean[][] | null;
|
|
4
|
+
/**
|
|
5
|
+
* What ECharts colors a shape with for `fill`: a CSS color, a gradient, or a repeated tile.
|
|
6
|
+
*
|
|
7
|
+
* @param none What draws no fill: `'transparent'` for a series, `'none'` for a `graphic` element.
|
|
8
|
+
*/
|
|
9
|
+
export declare const paintOf: (fill: IFill.JSON | null | undefined, none?: string) => any;
|
|
10
|
+
/** One color for `fill`, where ECharts takes no more (a tooltip's swatch): a gradient's first stop, a pattern's foreground. */
|
|
11
|
+
export declare const colorOf: (fill: IFill.JSON | null | undefined) => string | null;
|
|
12
|
+
/** A line's width in px. */
|
|
13
|
+
export declare const widthOf: (stroke: IStroke.JSON | null | undefined) => number;
|
|
14
|
+
/** A line's dash in px; `undefined` for a solid line. */
|
|
15
|
+
export declare const dashOf: (stroke: IStroke.JSON) => number[] | undefined;
|
|
16
|
+
/** A run's typeface. */
|
|
17
|
+
export declare const familyOf: (run: IText.RunPropertiesJSON) => string;
|
|
18
|
+
export declare const isBold: (run: IText.RunPropertiesJSON) => boolean;
|
|
19
|
+
export declare const isItalic: (run: IText.RunPropertiesJSON) => boolean;
|
|
20
|
+
/** A run's size in px. */
|
|
21
|
+
export declare const sizeOf: (run: IText.RunPropertiesJSON) => number;
|
|
22
|
+
/** What a run's text is filled with, as ECharts colors text. */
|
|
23
|
+
export declare const textPaintOf: (run: IText.RunPropertiesJSON) => any;
|
|
24
|
+
//# sourceMappingURL=_fills.d.ts.map
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import { ChartLayout, IFill, IStroke, IText } from '@sheetxl/sdk';
|
|
2
|
+
type Font = IText.RunPropertiesJSON;
|
|
3
|
+
type MarkerLayout = ChartLayout.MarkerLayout;
|
|
4
|
+
type Stroke = IStroke.JSON;
|
|
5
|
+
/**
|
|
6
|
+
* What every painter of a layout shares: fonts, strokes and markers as ECharts states them, and
|
|
7
|
+
* the `graphic` elements for text boxes, lines and up/down bars. Echarts is never imported here:
|
|
8
|
+
* these are plain objects an option carries.
|
|
9
|
+
*/
|
|
10
|
+
export declare const fontStyle: (font: Font) => Record<string, unknown>;
|
|
11
|
+
/** A run as a canvas font: `italic bold 13.33px Calibri`. */
|
|
12
|
+
export declare const fontOf: (font: Font, size?: number) => string;
|
|
13
|
+
/** A stroke as a `graphic` element's style states it. */
|
|
14
|
+
export declare const strokeStyle: (stroke: Stroke | null | undefined) => Record<string, unknown>;
|
|
15
|
+
/** A stroke as a series' `lineStyle` states it. */
|
|
16
|
+
export declare const lineStyle: (stroke: Stroke | null | undefined) => Record<string, unknown>;
|
|
17
|
+
/** Lines across a unit square: Excel's x, star and plus, drawn in the marker's outline color. */
|
|
18
|
+
export declare const MARKER_LINES: Readonly<Record<string, readonly [number, number, number, number][]>>;
|
|
19
|
+
/**
|
|
20
|
+
* How ECharts draws a marker of the layout's: its symbol, box and offset from the point. A marker's
|
|
21
|
+
* size is its box (measured, `probe-chart-markers.ps1`): a dash is that wide and a fifth of it tall,
|
|
22
|
+
* a dot half as wide, from the point to the right. A circle, square, dash and dot keep their outline
|
|
23
|
+
* inside the box, along a dot's height but not its width; the other symbols center it on the box.
|
|
24
|
+
* An x, star or plus is its lines; its fill, a square of the size with no outline, is
|
|
25
|
+
* {@link markerFill}'s.
|
|
26
|
+
*/
|
|
27
|
+
export declare const markerSymbol: (marker: MarkerLayout) => {
|
|
28
|
+
symbol: string;
|
|
29
|
+
symbolSize: number | [number, number];
|
|
30
|
+
symbolOffset?: [number, number];
|
|
31
|
+
};
|
|
32
|
+
/** The square under a filled x, star or plus, as Excel draws it; `null` for any other marker. */
|
|
33
|
+
export declare const markerFill: (marker: MarkerLayout | null) => IFill.JSON | null;
|
|
34
|
+
/** A marker of the layout's centered on (`cx`, `cy`), as `graphic` elements (a legend key's). */
|
|
35
|
+
export declare const markerGraphic: (marker: MarkerLayout, cx: number, cy: number, z: number) => any[];
|
|
36
|
+
/**
|
|
37
|
+
* A text box of the layout (an axis title, a data label) as `graphic` elements: its box, where it
|
|
38
|
+
* has a fill or a line, and its text centered in it, turned about the box's center.
|
|
39
|
+
*/
|
|
40
|
+
export declare const textGraphic: (text: ChartLayout.TextLayout, fill: IFill.JSON | null, border: Stroke | null, lineHeight?: number) => any[];
|
|
41
|
+
/** A group's lines (high-low, drop, series lines) as `graphic` lines over its series (z 3). */
|
|
42
|
+
export declare const linesGraphic: (lines: ChartLayout.LinesLayout | undefined) => any[];
|
|
43
|
+
/** A group's up/down bars as `graphic` rects over its series (z 3), as Excel draws them. */
|
|
44
|
+
export declare const upDownBarsGraphic: (upDown: ChartLayout.UpDownBarsLayout | undefined) => any[];
|
|
45
|
+
export {};
|
|
46
|
+
//# sourceMappingURL=_graphics.d.ts.map
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { ChartLayout } from '@sheetxl/sdk';
|
|
2
|
+
import { TranslateOptions } from './toEChartsOption';
|
|
3
|
+
import * as echarts from 'echarts/core';
|
|
4
|
+
/** Registers the renderer and the components, once. The series types come with the kinds. */
|
|
5
|
+
export declare function ensureRegistered(): void;
|
|
6
|
+
export type EChartsInstance = echarts.ECharts;
|
|
7
|
+
/**
|
|
8
|
+
* An ECharts instance with no DOM, sized at the layout, with the layout set. The caller
|
|
9
|
+
* disposes it. For tests that read ECharts' geometry; `renderChartToSVG` is the product.
|
|
10
|
+
*/
|
|
11
|
+
export declare function createHeadlessChart(layout: ChartLayout, options?: TranslateOptions): EChartsInstance;
|
|
12
|
+
/**
|
|
13
|
+
* Paints the layout headless, as an SVG document string of the layout's size.
|
|
14
|
+
*/
|
|
15
|
+
export declare function renderChartToSVG(layout: ChartLayout, options?: TranslateOptions): string;
|
|
16
|
+
/**
|
|
17
|
+
* A chart painted into an element. What is drawn is the layout's alone: a host that wants to know
|
|
18
|
+
* what is under the pointer asks the chart (`IChart.getElementAt`) with the layout it painted.
|
|
19
|
+
*/
|
|
20
|
+
export interface MountedChart {
|
|
21
|
+
/** Paints a new layout; a new size resizes the instance first. */
|
|
22
|
+
update(layout: ChartLayout): void;
|
|
23
|
+
dispose(): void;
|
|
24
|
+
}
|
|
25
|
+
/**
|
|
26
|
+
* Paints the layout into `host`, sized at the layout's px. The host is not measured: the frame
|
|
27
|
+
* scales it (DESIGN-CHART §5 "Size and zoom").
|
|
28
|
+
*/
|
|
29
|
+
export declare function mountChart(host: HTMLElement, layout: ChartLayout, options?: TranslateOptions): MountedChart;
|
|
30
|
+
//# sourceMappingURL=echarts.d.ts.map
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
export { toEChartsOption, type TranslateOptions } from './toEChartsOption';
|
|
2
|
+
export { ChartPaintKinds, type ChartPaintKind } from './kinds/ChartPaintKind';
|
|
3
|
+
export type { MountedChart, EChartsInstance } from './echarts';
|
|
4
|
+
/** What the painter module exports. */
|
|
5
|
+
export type ChartPaintModule = typeof import('./echarts');
|
|
6
|
+
/**
|
|
7
|
+
* The painter. It carries ECharts, so nothing imports it statically: it loads the first time a
|
|
8
|
+
* chart is painted or rendered to SVG, or earlier when `LazyModules.prefetch` warms the lazy
|
|
9
|
+
* modules (DESIGN-CHART §7).
|
|
10
|
+
*/
|
|
11
|
+
export declare const ChartPaint: import('@sheetxl/utils').LazyModule<typeof import("./echarts")>;
|
|
12
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1,132 @@
|
|
|
1
|
+
import { ChartLayout, IFill, IStroke } from '@sheetxl/sdk';
|
|
2
|
+
import { Bounds } from '@sheetxl/utils';
|
|
3
|
+
/**
|
|
4
|
+
* How a kind of chart group is painted: the ECharts series and `graphic` elements for a group of
|
|
5
|
+
* the kind's layout, and the key its series show in the legend. The built-in kinds register
|
|
6
|
+
* through {@link ChartPaintKinds} the way a host's kind does; a custom group
|
|
7
|
+
* (`ChartLayout.CustomGroupLayout`) is painted by the kind registered under `custom:<its kind>`.
|
|
8
|
+
*
|
|
9
|
+
* @remarks
|
|
10
|
+
* The painter translates the layout and decides nothing (DESIGN-CHART §2): a kind reads where the
|
|
11
|
+
* layout put things, in px, and says how ECharts draws them. It is given the shared vocabulary as
|
|
12
|
+
* a {@link ChartPaintKind.Context}: fills and strokes as ECharts states them, markers, text boxes,
|
|
13
|
+
* and for a group on axes the grid indexes and how a series' data is placed on them.
|
|
14
|
+
*
|
|
15
|
+
* @beta
|
|
16
|
+
*/
|
|
17
|
+
export interface ChartPaintKind {
|
|
18
|
+
/** The layout group types the kind paints: `'bar'`, `'line'`..., or `custom:<kind>` for a custom group. */
|
|
19
|
+
readonly types: readonly string[];
|
|
20
|
+
/**
|
|
21
|
+
* The ECharts pieces the kind's series need (`echarts/charts`, `echarts/components`), registered
|
|
22
|
+
* with `echarts.use` before a chart with a group of the kind is first painted. A kind drawn as
|
|
23
|
+
* `graphic` elements alone needs none.
|
|
24
|
+
*/
|
|
25
|
+
modules?(): readonly unknown[];
|
|
26
|
+
/**
|
|
27
|
+
* Whether the kind's series sit on the grid's axes.
|
|
28
|
+
* @defaultValue the group names two axes
|
|
29
|
+
*/
|
|
30
|
+
readonly grid?: boolean;
|
|
31
|
+
/** Whether the group's categories run up a vertical axis (horizontal bars), which the grid is told. */
|
|
32
|
+
horizontal?(group: ChartLayout.GroupLayout): boolean;
|
|
33
|
+
/** The ECharts series for a group. */
|
|
34
|
+
series?(group: ChartLayout.GroupLayout, context: ChartPaintKind.Context): any[];
|
|
35
|
+
/** The `graphic` elements for a group, drawn with its series: a radar's spokes, an of-pie's bar. */
|
|
36
|
+
graphic?(group: ChartLayout.GroupLayout, context: ChartPaintKind.Context): any[];
|
|
37
|
+
/**
|
|
38
|
+
* The key a legend entry for one of the group's series shows, as `graphic` elements in `key`:
|
|
39
|
+
* a line's line and marker, a slice's colors. `undefined` for the default, a swatch of the
|
|
40
|
+
* series' fill and line.
|
|
41
|
+
*/
|
|
42
|
+
legendKey?(entry: ChartLayout.LegendEntryLayout, series: ChartLayout.SeriesLayout, group: ChartLayout.GroupLayout, key: Bounds, context: ChartPaintKind.Context): any[] | undefined;
|
|
43
|
+
}
|
|
44
|
+
export declare namespace ChartPaintKind {
|
|
45
|
+
/** A group on the grid's axes: where its series go and how their data is placed. */
|
|
46
|
+
interface Cartesian {
|
|
47
|
+
xAxisIndex: number;
|
|
48
|
+
yAxisIndex: number;
|
|
49
|
+
/** Whether the value axis is logarithmic: nothing is drawn at zero or below. */
|
|
50
|
+
isLog: boolean;
|
|
51
|
+
/**
|
|
52
|
+
* A series' data as ECharts places it: by category index, or on a date axis as `[slot, value]`
|
|
53
|
+
* pairs; a log axis's zero and negative values dropped.
|
|
54
|
+
*/
|
|
55
|
+
placed(series: ChartLayout.SeriesLayout, data: any[]): any[];
|
|
56
|
+
/** What every ECharts series of the group states: its id and name, axes, data and no emphasis. */
|
|
57
|
+
base(series: ChartLayout.SeriesLayout): Record<string, any>;
|
|
58
|
+
}
|
|
59
|
+
/** What a kind is given to paint a group. */
|
|
60
|
+
interface Context {
|
|
61
|
+
readonly layout: ChartLayout;
|
|
62
|
+
axisOf(id: number): ChartLayout.AxisLayout | undefined;
|
|
63
|
+
/** The grid a group's axes are on. */
|
|
64
|
+
cartesian(group: {
|
|
65
|
+
axisIds: number[];
|
|
66
|
+
}): Cartesian;
|
|
67
|
+
/** A fill as ECharts paints it; `none` for no fill. */
|
|
68
|
+
paint(fill: IFill.JSON | null | undefined, none?: string): any;
|
|
69
|
+
/** A stroke as a `graphic` element's style states it. */
|
|
70
|
+
stroke(stroke: IStroke.JSON | null | undefined): Record<string, unknown>;
|
|
71
|
+
/** A stroke as a series' `lineStyle` states it. */
|
|
72
|
+
line(stroke: IStroke.JSON | null | undefined): Record<string, unknown>;
|
|
73
|
+
/** A stroke's width in px, 0 for none. */
|
|
74
|
+
width(stroke: IStroke.JSON | null | undefined): number;
|
|
75
|
+
/** A series drawn as a line with its markers, straight or smooth, broken or not at a blank. */
|
|
76
|
+
lineSeries(series: ChartLayout.SeriesLayout, smooth: boolean, spanBlanks?: boolean): Record<string, any>;
|
|
77
|
+
/** `drawn` with, beneath it, the squares under the series' filled x, star or plus markers. */
|
|
78
|
+
withMarkerFills(series: ChartLayout.SeriesLayout, drawn: any): any[];
|
|
79
|
+
readonly marker: {
|
|
80
|
+
/** How ECharts draws a marker: its symbol, box and offset. */
|
|
81
|
+
symbol(marker: ChartLayout.MarkerLayout): {
|
|
82
|
+
symbol: string;
|
|
83
|
+
symbolSize: number | [number, number];
|
|
84
|
+
symbolOffset?: [number, number];
|
|
85
|
+
};
|
|
86
|
+
/** The square under a filled x, star or plus; `null` for any other marker. */
|
|
87
|
+
fill(marker: ChartLayout.MarkerLayout | null): IFill.JSON | null;
|
|
88
|
+
/** A marker centered on a point, as `graphic` elements. */
|
|
89
|
+
graphic(marker: ChartLayout.MarkerLayout, cx: number, cy: number, z: number): any[];
|
|
90
|
+
};
|
|
91
|
+
/** A text box of the layout as `graphic` elements. */
|
|
92
|
+
text(text: ChartLayout.TextLayout, fill: IFill.JSON | null, border: IStroke.JSON | null, lineHeight?: number): any[];
|
|
93
|
+
/** A group's lines (high-low, drop, series lines) as `graphic` lines. */
|
|
94
|
+
lines(lines: ChartLayout.LinesLayout | undefined): any[];
|
|
95
|
+
/** A group's up/down bars as `graphic` rects. */
|
|
96
|
+
upDownBars(bars: ChartLayout.UpDownBarsLayout | undefined): any[];
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
/**
|
|
100
|
+
* The painters of chart groups, by layout group type: the built-ins, and any a host registers.
|
|
101
|
+
*
|
|
102
|
+
* @remarks
|
|
103
|
+
* The built-ins register when a layout is first translated, so before that {@link get} answers
|
|
104
|
+
* `undefined` for `'bar'`; a host's kind registered under a built-in type keeps its place when they
|
|
105
|
+
* do. A registration is a call, never a side effect of an import.
|
|
106
|
+
*
|
|
107
|
+
* @beta
|
|
108
|
+
*/
|
|
109
|
+
export declare namespace ChartPaintKinds {
|
|
110
|
+
/**
|
|
111
|
+
* Registers a kind under each of its types, replacing any earlier registration of them.
|
|
112
|
+
*
|
|
113
|
+
* @returns A function that removes the registration.
|
|
114
|
+
*/
|
|
115
|
+
function register(kind: ChartPaintKind): () => void;
|
|
116
|
+
/** The kind registered under a layout group type, or `undefined`. */
|
|
117
|
+
function get(type: string): ChartPaintKind | undefined;
|
|
118
|
+
function has(type: string): boolean;
|
|
119
|
+
/** The registered types. */
|
|
120
|
+
function getTypes(): string[];
|
|
121
|
+
/** The type a layout group is registered under: its type, or `custom:<kind>` for a custom group. */
|
|
122
|
+
function typeOf(group: ChartLayout.GroupLayout): string;
|
|
123
|
+
/** The kind that paints `group`, or `undefined` when none is registered for it. */
|
|
124
|
+
function of(group: ChartLayout.GroupLayout): ChartPaintKind | undefined;
|
|
125
|
+
/**
|
|
126
|
+
* Registers the painter's own kinds, once, under the types no host has taken. The translation
|
|
127
|
+
* calls it before its first use.
|
|
128
|
+
* @hidden
|
|
129
|
+
*/
|
|
130
|
+
function registerBuiltIns(builtInKinds: (register: (kind: ChartPaintKind) => () => void) => void): void;
|
|
131
|
+
}
|
|
132
|
+
//# sourceMappingURL=ChartPaintKind.d.ts.map
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { ChartLayout } from '@sheetxl/sdk';
|
|
2
|
+
import { Bounds } from '@sheetxl/utils';
|
|
3
|
+
import { ChartPaintKind } from './ChartPaintKind';
|
|
4
|
+
/**
|
|
5
|
+
* A line key: the series' line across the key, with its marker on the middle when it has one
|
|
6
|
+
* (Excel's picture of a scatter's legend; a marker-only series shows the marker alone).
|
|
7
|
+
*/
|
|
8
|
+
export declare const lineLegendKey: (series: ChartLayout.SeriesLayout, key: Bounds, context: ChartPaintKind.Context) => any[];
|
|
9
|
+
export declare const LinePaint: ChartPaintKind;
|
|
10
|
+
//# sourceMappingURL=_Line.d.ts.map
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { ChartLayout } from '@sheetxl/sdk';
|
|
2
|
+
import { Bounds, Point } from '@sheetxl/utils';
|
|
3
|
+
import { ChartPaintKind } from './ChartPaintKind';
|
|
4
|
+
type SliceLayout = ChartLayout.SliceLayout;
|
|
5
|
+
/** A slice and the name its tooltip gives it. */
|
|
6
|
+
export interface NamedSlice {
|
|
7
|
+
slice: SliceLayout;
|
|
8
|
+
name: string;
|
|
9
|
+
}
|
|
10
|
+
/**
|
|
11
|
+
* Slices that go round a pie at `center` as ECharts pies, its ring from `inner` to `outer`. Each
|
|
12
|
+
* slice's value is its span in degrees, so ECharts' share of 360 puts every edge where the layout
|
|
13
|
+
* did. An exploded slice has a center of its own, which a pie series cannot give one slice, so it
|
|
14
|
+
* is drawn by a pie of its own at that center, the rest of that pie's ring left transparent.
|
|
15
|
+
*/
|
|
16
|
+
export declare const piesOf: (id: string, name: string, center: Point, inner: number, outer: number, slices: NamedSlice[], context: ChartPaintKind.Context) => any[];
|
|
17
|
+
/** A swatch of a fill and a line in the key, as a legend entry for one point shows its colors. */
|
|
18
|
+
export declare const swatchKey: (fill: ChartLayout.SliceLayout["fill"] | undefined, stroke: ChartLayout.SliceLayout["stroke"] | null | undefined, key: Bounds, context: ChartPaintKind.Context) => any[];
|
|
19
|
+
export declare const PiePaint: ChartPaintKind;
|
|
20
|
+
export {};
|
|
21
|
+
//# sourceMappingURL=_Pie.d.ts.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { ChartPaintKind } from './ChartPaintKind';
|
|
2
|
+
/**
|
|
3
|
+
* A region map, painted as its layout's placeholder: the label in the plot saying the type is not
|
|
4
|
+
* drawn, and nothing else of the group. A host may register a painter of its own under the type.
|
|
5
|
+
*/
|
|
6
|
+
export declare const PlaceholderPaint: ChartPaintKind;
|
|
7
|
+
//# sourceMappingURL=_Placeholder.d.ts.map
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { ChartPaintKind } from './ChartPaintKind';
|
|
2
|
+
/**
|
|
3
|
+
* Registers the painters the package ships, through the same door a host's kind comes in by.
|
|
4
|
+
* Called by the translation before its first use.
|
|
5
|
+
*
|
|
6
|
+
* @remarks
|
|
7
|
+
* The built-ins name no ECharts modules of their own: `echarts.ts`, the lazy painter, brings the
|
|
8
|
+
* series types they use when it registers ECharts' pieces, so this module and the kinds stay free
|
|
9
|
+
* of ECharts and the package index stays light (DESIGN-CHART §7).
|
|
10
|
+
*/
|
|
11
|
+
export declare function registerBuiltInPaintKinds(register: (kind: ChartPaintKind) => () => void): void;
|
|
12
|
+
//# sourceMappingURL=_builtIns.d.ts.map
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { EChartsCoreOption } from 'echarts/core';
|
|
2
|
+
import { ChartLayout } from '@sheetxl/sdk';
|
|
3
|
+
/**
|
|
4
|
+
* How the layout is translated.
|
|
5
|
+
*/
|
|
6
|
+
export interface TranslateOptions {
|
|
7
|
+
/**
|
|
8
|
+
* Whether the chart answers the pointer: tooltips. Off when rendering headless.
|
|
9
|
+
* @defaultValue true
|
|
10
|
+
*/
|
|
11
|
+
interactive?: boolean;
|
|
12
|
+
/**
|
|
13
|
+
* How the legend is drawn: by ECharts' `legend` component placed at the layout's rect, which
|
|
14
|
+
* flows the entries itself, or as `graphic` elements at exactly the layout's entry rects.
|
|
15
|
+
* @defaultValue 'graphic'
|
|
16
|
+
*/
|
|
17
|
+
legend?: 'native' | 'graphic';
|
|
18
|
+
}
|
|
19
|
+
/**
|
|
20
|
+
* Translates a {@link ChartLayout} to an ECharts option.
|
|
21
|
+
*
|
|
22
|
+
* @remarks
|
|
23
|
+
* A translation table and nothing else (DESIGN-CHART §2): the grid is the plot rect in px with
|
|
24
|
+
* `containLabel:false`; value axes get `min`, `max` and `interval` and a formatter that answers
|
|
25
|
+
* the layout's strings; bars get `barWidth` in px and `barGap` from the overlap; every DrawingML
|
|
26
|
+
* axis is an ECharts axis, a deleted one with `show:false`. Nothing is left for ECharts to decide.
|
|
27
|
+
*/
|
|
28
|
+
export declare function toEChartsOption(layout: ChartLayout, options?: TranslateOptions): EChartsCoreOption;
|
|
29
|
+
/** A concrete color for ECharts: it parses colors, so a CSS variable would not do. */
|
|
30
|
+
export declare const isConcreteColor: (color: string) => boolean;
|
|
31
|
+
//# sourceMappingURL=toEChartsOption.d.ts.map
|