@sheetxl/react 0.8.0-beta.11 → 0.8.0-beta.13
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/{B93LSmhnvkxNXTq-.mjs → -wQNyCnoJdQUTTfP.mjs} +1 -1
- package/browser/esm/{Bl2BFCQ00fotauKB.mjs → AL94cpxFjPurAMQG.mjs} +1 -1
- package/browser/esm/{BQYS2Yf-EAV_tBLr.mjs → B4K8rf7TAv0SBkbG.mjs} +1 -1
- package/browser/esm/{ClAtIfYbsUPA073B.mjs → BrwfFgqKdMG_-iar.mjs} +1 -1
- package/browser/esm/ByBGwdqhc_l75i5G.mjs +145 -0
- package/browser/esm/{DgL7Dy-Lqcr1TvW6.mjs → C1zqAqKQ6oa4FiTH.mjs} +4851 -4818
- package/browser/esm/C9lQPmVMIlUwXkKr.mjs +303 -0
- package/browser/esm/{Dnh1kpz3v1JKtRD_.mjs → CIrcPI7uOT93ydNn.mjs} +2 -2
- package/browser/esm/{DS66lAIM-9M-YoZQ.mjs → CZsNidKZjsn0lNnA.mjs} +112 -104
- package/browser/esm/{Bos4Rkp8UTF7QXUB.mjs → CcewpxckpDrXSiZ-.mjs} +1 -1
- package/browser/esm/{BegvsXeRs7e-9t8k.mjs → CdDvFP8Fqm8uU7Rw.mjs} +1 -1
- package/browser/esm/{D2u6THGErqw64KQI.mjs → CfewUx0gINn-wXt3.mjs} +1 -1
- package/browser/esm/{C1pc9F4Rt2C5FKUo.mjs → CfvYfq6ALVqkCsdg.mjs} +1 -1
- package/browser/esm/CulxiChz6lj3G9lw.mjs +341 -0
- package/browser/esm/D5Uy22WeT7vUS36Z.mjs +19 -0
- package/browser/esm/{1-LEUre9ZLG0OYYB.mjs → Dd8deQ2CDMdrhzF1.mjs} +6 -6
- package/browser/esm/Dit7p67J_fDF5RDj.mjs +262 -0
- package/browser/esm/{CPnnESfZz2jjJd82.mjs → DzWFl-_dCN-EOkio.mjs} +3 -3
- package/browser/esm/{94dxo1A-z8lgiiGw.mjs → MIDbAwdzknMaoTU5.mjs} +2 -2
- package/browser/esm/{B26QVfjer2oY2ewK.mjs → ao9zR4H88b7AmZEV.mjs} +1 -1
- package/browser/esm/chart.mjs +28 -27
- package/browser/esm/control.mjs +74 -73
- package/browser/esm/group.mjs +3 -3
- package/browser/esm/index.mjs +6195 -5307
- package/browser/esm/note.mjs +5 -5
- package/browser/esm/picture.mjs +2 -81
- package/browser/esm/sXn9faQLuh4P0TZ9.mjs +401 -0
- package/browser/esm/shape.mjs +2 -2
- package/browser/esm/slicer.mjs +112 -111
- package/browser/esm/{CzRIbc-Lk__VMLKM.mjs → u3A8I4A7GKIOLOOb.mjs} +3 -3
- package/browser/esm/{DMdsMPT0fWBbTkNn.mjs → x6A47UA3fzV361tO.mjs} +1 -1
- package/node/esm/{BiaDWnN3tT7neoRL.mjs → A_4Y7EtzCWp1AG3Y.mjs} +1 -1
- package/node/esm/BNwVylzKMErhrx4i.mjs +406 -0
- package/node/esm/BPBUSXc5TVnD15By.mjs +146 -0
- package/node/esm/{DxQZmb-j4NLUO9Af.mjs → BTT6UB5lGvPxcq3F.mjs} +1 -1
- package/node/esm/{JiQGhLkoL8CJpVvA.mjs → BYiAmyF-aOOuMkD1.mjs} +1 -1
- package/node/esm/BqS8o-CmPoCjHDHp.mjs +263 -0
- package/node/esm/{b-XRVRI1fYQQMkTC.mjs → CC_XgLOFPvqmFyZ_.mjs} +525 -492
- package/node/esm/{BaRfst1euuhquupX.mjs → CMGUrHMaBDeCezK5.mjs} +1 -1
- package/node/esm/{umljAT66yb3_rURh.mjs → CP07qkepi21zlB0n.mjs} +118 -110
- package/node/esm/{BlxXufqBBg1PtsXd.mjs → CQJJMfuXl6mbgHdT.mjs} +1 -1
- package/node/esm/{C_SNx7TlFEcwbYjx.mjs → CVDVFhM7OIpaOlyN.mjs} +1 -1
- package/node/esm/{gpD-9LDW92phhoma.mjs → CVMuO9bpR5YK0pPb.mjs} +1 -1
- package/node/esm/{BMVK5plvmBOAIlxP.mjs → CaZG4HD3SmHvD-Tu.mjs} +1 -1
- package/node/esm/{6zApGj9DozhFy-bx.mjs → CuRPfxQCj2jookWL.mjs} +1 -1
- package/node/esm/D8mYmUPUA6i8oFgR.mjs +19 -0
- package/node/esm/{Dj5FM7_-YWhCtCCt.mjs → DAUtyjkW5uSdnTli.mjs} +1 -1
- package/node/esm/{D_pCpfdQowV_4Aje.mjs → DfvJ0Dpn-AP2mGtz.mjs} +5 -5
- package/node/esm/{DTMTIrYIK1eZswsM.mjs → DipZYwHed-W6QMtQ.mjs} +1 -1
- package/node/esm/{Be9c1GwQkPo8Piuh.mjs → NvP_j9pSsDiJ_PyY.mjs} +3 -3
- package/node/esm/chart.mjs +26 -25
- package/node/esm/control.mjs +79 -78
- package/node/esm/{sigD1UFqvPlWUw_9.mjs → eecr5gnC2KqVhOzX.mjs} +2 -2
- package/node/esm/group.mjs +3 -3
- package/node/esm/index.mjs +6594 -5705
- package/node/esm/note.mjs +18 -18
- package/node/esm/picture.mjs +269 -50
- package/node/esm/shape.mjs +185 -578
- package/node/esm/slicer.mjs +51 -50
- package/package.json +7 -7
- package/resources/locales/de/picture.cmd.json +157 -0
- package/resources/locales/de/sheet.cmd.json +45 -2
- package/resources/locales/de/ui.msg.json +3 -0
- package/resources/locales/de/workbook.cmd.json +6 -0
- package/resources/locales/en/picture.cmd.json +157 -0
- package/resources/locales/en/sheet.cmd.json +45 -2
- package/resources/locales/en/ui.msg.json +5 -0
- package/resources/locales/en/workbook.cmd.json +6 -0
- package/types/src/border/useBorders.d.ts +2 -2
- package/types/src/cell/CellCheckboxRenderer.d.ts +20 -0
- package/types/src/cell/CellContent.d.ts +68 -0
- package/types/src/cell/CellControlContext.d.ts +37 -0
- package/types/src/cell/{FormulaCellRenderer.d.ts → CellFormulaRenderer.d.ts} +5 -5
- package/types/src/cell/CellImageRenderer.d.ts +11 -0
- package/types/src/cell/CellRenderers.d.ts +190 -0
- package/types/src/cell/{SheetCellRenderer.d.ts → CellTextRenderer.d.ts} +9 -6
- package/types/src/cell/ColumnButton.d.ts +3 -3
- package/types/src/cell/OutlineButton.d.ts +4 -4
- package/types/src/cell/SheetHeaderRenderer.d.ts +1 -1
- package/types/src/cell/index.d.ts +8 -2
- package/types/src/cell/useFormulaViewAnchor.d.ts +1 -1
- package/types/src/cell/useInsertableCellControls.d.ts +25 -0
- package/types/src/chart/ChartCommands.d.ts +1 -1
- package/types/src/chart/ChartEditor.d.ts +2 -0
- package/types/src/chart/ChartElement.d.ts +14 -3
- package/types/src/chart/paint/_graphics.d.ts +0 -8
- package/types/src/chart/paint/_mode.d.ts +6 -0
- package/types/src/chart/paint/echarts.d.ts +6 -3
- package/types/src/chart/paint/index.d.ts +1 -1
- package/types/src/chart/paint/kinds/ChartPaintKind.d.ts +9 -1
- package/types/src/chart/paint/kinds/_builtIns.d.ts +0 -9
- package/types/src/chart/paint/toEChartsOption.d.ts +12 -1
- package/types/src/editableLabel/EditableLabel.d.ts +3 -1
- package/types/src/editor/SheetReferenceHeaderLayer.d.ts +1 -1
- package/types/src/editor/useFormulaHints.d.ts +1 -1
- package/types/src/layer/CellErrorLayer.d.ts +3 -2
- package/types/src/layer/CellIndicatorLayer.d.ts +31 -0
- package/types/src/layer/CircularIndicatorLayer.d.ts +1 -1
- package/types/src/layer/HeaderSelectionLayer.d.ts +4 -4
- package/types/src/layer/HyperlinkLayer.d.ts +12 -5
- package/types/src/layer/ProtectionLayer.d.ts +1 -2
- package/types/src/layer/SheetCellLayer.d.ts +11 -4
- package/types/src/layer/SheetMovableLayer.d.ts +2 -1
- package/types/src/layer/SheetOutlineLayer.d.ts +1 -1
- package/types/src/layer/TableLayer.d.ts +1 -1
- package/types/src/layer/TableToolbar.d.ts +1 -1
- package/types/src/layer/ValidationPromptLayer.d.ts +16 -4
- package/types/src/layer/_visibleCellFeatures.d.ts +11 -0
- package/types/src/layer/index.d.ts +1 -0
- package/types/src/layer/useValidationPicker.d.ts +1 -1
- package/types/src/listener/useRangeListener.d.ts +13 -7
- package/types/src/movable/DefaultMovable.d.ts +1 -1
- package/types/src/movable/MovableControl.d.ts +3 -1
- package/types/src/movable/MovableFrame.d.ts +2 -1
- package/types/src/movable/MovableLayer.d.ts +6 -3
- package/types/src/movable/useFramePreview.d.ts +17 -0
- package/types/src/picture/PictureCommands.d.ts +8 -0
- package/types/src/picture/_pictureHyperlink.d.ts +13 -0
- package/types/src/picture/pictureCrop.d.ts +32 -0
- package/types/src/sheet/ISheetHeaderElement.d.ts +2 -2
- package/types/src/sheet/IWorksheetElement.d.ts +21 -22
- package/types/src/sheet/SheetCommandProvider.d.ts +3 -0
- package/types/src/sheet/SheetOutlineElement.d.ts +2 -2
- package/types/src/sheet/SheetPanels.d.ts +2 -2
- package/types/src/sheet/_hyperlinkEdit.d.ts +7 -0
- package/types/src/sheet/circularReferences.d.ts +1 -1
- package/types/src/tabStrip/Sortable.d.ts +5 -5
- package/types/src/tabStrip/TabStrip.d.ts +6 -6
- package/types/src/tabStrip/TabStripItem.d.ts +15 -13
- package/types/src/taskPane/CellControlPane.d.ts +17 -0
- package/types/src/taskPane/index.d.ts +1 -0
- package/types/src/taskPane/useTaskPane.d.ts +6 -3
- package/types/src/theme/buildDocThemeCSS.d.ts +4 -1
- package/types/src/workbook/DefaultRenderers.d.ts +4 -4
- package/types/src/workbook/IWorkbookElement.d.ts +52 -20
- package/types/src/workbook/WorkbookStrip.d.ts +5 -5
- package/browser/esm/CRi6DQ3UXmPEv-w_.mjs +0 -729
- package/browser/esm/cQ6xdPFkEcuDlNTN.mjs +0 -75
- package/browser/esm/ugfE7YeZALQURDKF.mjs +0 -241
- package/node/esm/DJPgbB1X22YmhbaR.mjs +0 -242
- package/node/esm/DgGEHydEjD7nfsDB.mjs +0 -76
|
@@ -36,14 +36,26 @@ export interface ValidationPromptLayerProps extends Omit<LayerProps, 'children'>
|
|
|
36
36
|
offset?: number;
|
|
37
37
|
/**
|
|
38
38
|
* Render the prompt yourself. Spread `floatProps` on the returned element. Omit for the default
|
|
39
|
-
* box: the title in bold over the message.
|
|
39
|
+
* box: the title in bold over the message; `null` for none.
|
|
40
40
|
*/
|
|
41
|
-
renderPrompt?: (
|
|
41
|
+
renderPrompt?: ((props: ValidationPromptRenderProps) => React.ReactNode) | null;
|
|
42
42
|
/**
|
|
43
43
|
* Render the alert yourself. Spread `floatProps` on the returned element. Omit for the default
|
|
44
|
-
* card: the rule's alert title and message, and what to do next.
|
|
44
|
+
* card: the rule's alert title and message, and what to do next; `null` for none.
|
|
45
45
|
*/
|
|
46
|
-
renderAlert?: (
|
|
46
|
+
renderAlert?: ((props: ValidationAlertRenderProps) => React.ReactNode) | null;
|
|
47
|
+
}
|
|
48
|
+
/** What {@link ValidationPromptLayerProps.renderPrompt} is handed. */
|
|
49
|
+
export interface ValidationPromptRenderProps {
|
|
50
|
+
prompt: ValidationPrompt;
|
|
51
|
+
/** Spread on the returned element: its placement and pointer handling. */
|
|
52
|
+
floatProps: React.HTMLAttributes<HTMLElement>;
|
|
53
|
+
}
|
|
54
|
+
/** What {@link ValidationPromptLayerProps.renderAlert} is handed. */
|
|
55
|
+
export interface ValidationAlertRenderProps {
|
|
56
|
+
alert: ValidationAlert;
|
|
57
|
+
/** Spread on the returned element: its placement and pointer handling. */
|
|
58
|
+
floatProps: React.HTMLAttributes<HTMLElement>;
|
|
47
59
|
}
|
|
48
60
|
/**
|
|
49
61
|
* The **input prompt** of a data validation, and the **alert** an entry raised in its place — one
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { ICellRange } from '@sheetxl/sdk';
|
|
2
|
+
/**
|
|
3
|
+
* Every feature a blank cell can be painted through, for the visible-cell scans.
|
|
4
|
+
*
|
|
5
|
+
* @remarks
|
|
6
|
+
* Naming them is what visits blanks at all. The list is the whole cell state, not what the layer
|
|
7
|
+
* draws: per-cell style resolution composes table and named styles through the full intersection,
|
|
8
|
+
* so a partial list breaks effective styles.
|
|
9
|
+
*/
|
|
10
|
+
export declare const VisibleCellFeatures: readonly ICellRange.Feature[];
|
|
11
|
+
//# sourceMappingURL=_visibleCellFeatures.d.ts.map
|
|
@@ -25,6 +25,7 @@ export * from './ValidationDropdownLayer';
|
|
|
25
25
|
export * from './ValidationPromptLayer';
|
|
26
26
|
export * from './useValidationPicker';
|
|
27
27
|
export * from './CircularIndicatorLayer';
|
|
28
|
+
export * from './CellIndicatorLayer';
|
|
28
29
|
export * from './CommentsLayer';
|
|
29
30
|
export * from './CommentCardLayer';
|
|
30
31
|
export * from './RangeAnnotationLayer';
|
|
@@ -48,7 +48,7 @@ export declare const resolveListPickerItems: (rules: readonly IDataValidation[],
|
|
|
48
48
|
*
|
|
49
49
|
* @remarks
|
|
50
50
|
* No search field: a validation list is a short set of choices, and narrowing it belongs to the cell
|
|
51
|
-
* editor's typing
|
|
51
|
+
* editor's typing.
|
|
52
52
|
*/
|
|
53
53
|
export declare const useValidationPicker: (options: ValidationPickerOptions) => CellPicker;
|
|
54
54
|
//# sourceMappingURL=useValidationPicker.d.ts.map
|
|
@@ -1,15 +1,21 @@
|
|
|
1
1
|
import { ICellRange } from '@sheetxl/sdk';
|
|
2
|
-
export
|
|
3
|
-
fireOnAddressChange: boolean;
|
|
4
|
-
}
|
|
2
|
+
export type useRangeListenerOptions = ICellRange.ListenerOptions;
|
|
5
3
|
export interface RangeContainer {
|
|
6
4
|
getRange(address: ICellRange.Address, options?: ICellRange.GetRangeOptions): ICellRange;
|
|
7
5
|
}
|
|
8
6
|
/**
|
|
9
|
-
*
|
|
7
|
+
* Listen to a range of `model` for as long as the component is mounted.
|
|
8
|
+
*
|
|
9
|
+
* @param model What the range is read from: a workbook or a sheet.
|
|
10
|
+
* @param address The range to listen to. Nothing is listened to while it is `null`.
|
|
11
|
+
* @param listener Called with each {@link ICellRange.Event}. The latest render's listener is the
|
|
12
|
+
* one called, so it may close over state without re-subscribing.
|
|
13
|
+
* @param options Which events to hear and how the range follows inserts and deletes
|
|
14
|
+
* ({@link ICellRange.ListenerOptions}). Read once per subscription.
|
|
10
15
|
*
|
|
11
|
-
* @
|
|
12
|
-
*
|
|
16
|
+
* @remarks
|
|
17
|
+
* The subscription is renewed when `model` or `address` changes. Nothing is delivered for that
|
|
18
|
+
* renewal: the listener only hears what the range itself reports.
|
|
13
19
|
*/
|
|
14
|
-
export declare const useRangeListener: (model: RangeContainer, address: ICellRange.Address, listener: ICellRange.Listener, options?: useRangeListenerOptions) => void;
|
|
20
|
+
export declare const useRangeListener: (model: RangeContainer | null | undefined, address: ICellRange.Address | null | undefined, listener: ICellRange.Listener, options?: useRangeListenerOptions) => void;
|
|
15
21
|
//# sourceMappingURL=useRangeListener.d.ts.map
|
|
@@ -4,5 +4,5 @@ import { MovableElementProps } from './IMovableArea';
|
|
|
4
4
|
* Renders a movable with the renderer for its kind of content, or a placeholder for a kind with
|
|
5
5
|
* none. The default `renderMovable` of a sheet element.
|
|
6
6
|
*/
|
|
7
|
-
export declare const
|
|
7
|
+
export declare const defaultRenderMovable: (props: MovableElementProps) => React.ReactElement;
|
|
8
8
|
//# sourceMappingURL=DefaultMovable.d.ts.map
|
|
@@ -2,11 +2,13 @@ import { default as React } from 'react';
|
|
|
2
2
|
import { IMovable } from '@sheetxl/sdk';
|
|
3
3
|
import { ResizeDirection } from './geometry';
|
|
4
4
|
import { MovablePreview } from './framePlacement';
|
|
5
|
+
/** A resize handle by its compass name, as `MovableLayerProps.resizeDirections` lists them. */
|
|
6
|
+
export type ResizeDirectionName = 'nw' | 'n' | 'ne' | 'w' | 'e' | 'sw' | 's' | 'se';
|
|
5
7
|
/** The resize cursor for a handle on a frame turned `rotation` degrees, so it follows the turn. */
|
|
6
8
|
export declare const resizeCursor: (direction: ResizeDirection, rotation: number) => string;
|
|
7
9
|
export interface MovableControlProps {
|
|
8
10
|
/** Compass names of the handles to draw (`nw`, `n`, … `se`). */
|
|
9
|
-
directions: readonly
|
|
11
|
+
directions: readonly ResizeDirectionName[];
|
|
10
12
|
/** Degrees clockwise the frame is turned; only the cursors use it, the box turns itself. */
|
|
11
13
|
rotation: number;
|
|
12
14
|
/**
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { default as React } from 'react';
|
|
2
2
|
import { IMovable } from '@sheetxl/sdk';
|
|
3
|
+
import { RenderSlotFn } from '@sheetxl/utils-react';
|
|
3
4
|
import { MovableElementProps } from './IMovableArea';
|
|
4
5
|
import { MovableGestureHost } from './MovableControl';
|
|
5
6
|
import { MovablePreview } from './framePlacement';
|
|
@@ -14,7 +15,7 @@ export interface MovableFrameProps extends React.HTMLAttributes<HTMLElement> {
|
|
|
14
15
|
* @param props - {@link MovableElementProps}
|
|
15
16
|
* @returns A React Element representing the IMovable.
|
|
16
17
|
*/
|
|
17
|
-
renderMovable:
|
|
18
|
+
renderMovable: RenderSlotFn<MovableElementProps>;
|
|
18
19
|
onRefLoad: (ref: HTMLElement) => void;
|
|
19
20
|
onRefUnload: (ref: HTMLElement) => void;
|
|
20
21
|
onHide: (hide: (movable: IMovable) => boolean | Promise<boolean> | void) => void;
|
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
import { default as React } from 'react';
|
|
2
2
|
import { Bounds } from '@sheetxl/utils';
|
|
3
3
|
import { IMovableCollection, IMovableSelection, IMovable } from '@sheetxl/sdk';
|
|
4
|
+
import { RenderSlotFn } from '@sheetxl/utils-react';
|
|
4
5
|
import { MovableElementProps } from './IMovableArea';
|
|
6
|
+
import { ResizeDirectionName } from './MovableControl';
|
|
5
7
|
export interface MovableLayerAttributes {
|
|
6
8
|
/**
|
|
7
9
|
* Will put focus on the the movable object.
|
|
@@ -45,7 +47,7 @@ export interface MovableLayerProps extends React.HTMLAttributes<HTMLDivElement>
|
|
|
45
47
|
* @param props MovableElementProps
|
|
46
48
|
* @returns A React Element representing the IMovable.
|
|
47
49
|
*/
|
|
48
|
-
renderMovable:
|
|
50
|
+
renderMovable: RenderSlotFn<MovableElementProps>;
|
|
49
51
|
/**
|
|
50
52
|
* Called when the final movable is unselected.
|
|
51
53
|
*/
|
|
@@ -72,9 +74,10 @@ export interface MovableLayerProps extends React.HTMLAttributes<HTMLDivElement>
|
|
|
72
74
|
*/
|
|
73
75
|
disableResize?: boolean;
|
|
74
76
|
/**
|
|
75
|
-
*
|
|
77
|
+
* The resize handles to show, by compass name.
|
|
78
|
+
* @defaultValue all eight
|
|
76
79
|
*/
|
|
77
|
-
|
|
80
|
+
resizeDirections?: ResizeDirectionName[];
|
|
78
81
|
/**
|
|
79
82
|
* Called after the first render of a movable.
|
|
80
83
|
*/
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { IMovable } from '@sheetxl/sdk';
|
|
2
|
+
import { MovableContentPreview } from './framePlacement';
|
|
3
|
+
/**
|
|
4
|
+
* The unzoomed, unrotated size a movable is drawn at: its frame on the canvas (for a member of a
|
|
5
|
+
* group, already mapped through the group's scale, so its line keeps its width), or the size an
|
|
6
|
+
* in-flight resize has it at, so its content is laid out again as the pointer moves rather than
|
|
7
|
+
* stretched, as Excel draws it. With it, the turn the frame is drawn at, and what an in-flight gesture
|
|
8
|
+
* draws the content as: adjust values a handle drag has it at, or the route a glued connector is
|
|
9
|
+
* taking.
|
|
10
|
+
*/
|
|
11
|
+
export declare const useFramePreview: (movable: IMovable | undefined) => {
|
|
12
|
+
width: number;
|
|
13
|
+
height: number;
|
|
14
|
+
rotation: number;
|
|
15
|
+
content: MovableContentPreview | null;
|
|
16
|
+
};
|
|
17
|
+
//# sourceMappingURL=useFramePreview.d.ts.map
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import { Command } from '@sheetxl/utils-react';
|
|
2
2
|
import { MovableKindCommandData } from '../movable';
|
|
3
|
+
/** Excel's Crop > Aspect Ratio, by command: width over height. */
|
|
4
|
+
export declare const PictureCropAspects: Readonly<Record<string, readonly [width: number, height: number]>>;
|
|
3
5
|
/**
|
|
4
6
|
* The picture kind's commands, for the active picture. Chrome is the `picture` catalog.
|
|
5
7
|
*
|
|
@@ -7,6 +9,12 @@ import { MovableKindCommandData } from '../movable';
|
|
|
7
9
|
* (`changePictureFromFile`, a file dialog) or from the web (`changePictureFromURL`, an input
|
|
8
10
|
* dialog). The image is read before the picture takes it, so a bad address or an unreadable file
|
|
9
11
|
* changes nothing. Dialog-driven and self-committing, so `noTransaction` / `noRepeat`.
|
|
12
|
+
*
|
|
13
|
+
* The crop commands are Excel's Crop menu: Crop to Shape takes what a shape gallery entry states,
|
|
14
|
+
* Aspect Ratio frames the picture at a ratio, and Fill and Fit place the image in the frame. A picture
|
|
15
|
+
* that locks its crop (`noCrop`) offers none of them.
|
|
16
|
+
*
|
|
17
|
+
* The link commands add, change, follow and remove the hyperlink a click on the picture follows.
|
|
10
18
|
*/
|
|
11
19
|
export declare const contributePictureCommands: Command.DynamicCommandContributor<MovableKindCommandData>;
|
|
12
20
|
//# sourceMappingURL=PictureCommands.d.ts.map
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { IPicture, IWorksheet } from '@sheetxl/sdk';
|
|
2
|
+
import { IReactNotifier } from '@sheetxl/utils-react';
|
|
3
|
+
/**
|
|
4
|
+
* The surface state that holds the linked picture under the pointer: a frame takes the pointer before
|
|
5
|
+
* the cells do, so the picture says it is hovered and the hyperlink layer draws its card.
|
|
6
|
+
*/
|
|
7
|
+
export declare const HOVERED_PICTURE_LINK = "hovered-picture-link";
|
|
8
|
+
/**
|
|
9
|
+
* Opens the hyperlink dialog on a picture. There is no text to show, so the dialog offers none; a link
|
|
10
|
+
* emptied there is removed. The dialog is read-only for a picture that cannot change.
|
|
11
|
+
*/
|
|
12
|
+
export declare const showPictureHyperlink: (picture: IPicture, sheet: IWorksheet, notifier: IReactNotifier | undefined) => void;
|
|
13
|
+
//# sourceMappingURL=_pictureHyperlink.d.ts.map
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { Bounds, Size } from '@sheetxl/utils';
|
|
2
|
+
import { IFill } from '@sheetxl/sdk';
|
|
3
|
+
/**
|
|
4
|
+
* Excel's Crop > Fill: the image covers the frame, keeping its proportions and centered. What
|
|
5
|
+
* overflows the frame is cropped; the frame stays.
|
|
6
|
+
*/
|
|
7
|
+
export declare const fillCrop: (frame: Size, natural: Size) => IFill.RectInsets;
|
|
8
|
+
/**
|
|
9
|
+
* Excel's Crop > Fit: the whole image shows in the frame, keeping its proportions and centered. Where
|
|
10
|
+
* it falls short of the frame the crop is negative; the frame stays.
|
|
11
|
+
*/
|
|
12
|
+
export declare const fitCrop: (frame: Size, natural: Size) => IFill.RectInsets;
|
|
13
|
+
/**
|
|
14
|
+
* Excel's Crop > Aspect Ratio: the largest frame of that ratio inside the frame, about the same center.
|
|
15
|
+
* The image keeps its scale and position on the sheet, so the crop takes up what the frame gave up.
|
|
16
|
+
*
|
|
17
|
+
* @param bounds The frame.
|
|
18
|
+
* @param crop The crop now.
|
|
19
|
+
* @param ratio Width over height.
|
|
20
|
+
*/
|
|
21
|
+
export declare const aspectCrop: (bounds: Bounds, crop: IFill.RectInsets, ratio: number) => {
|
|
22
|
+
bounds: Bounds;
|
|
23
|
+
crop: IFill.RectInsets;
|
|
24
|
+
};
|
|
25
|
+
/** Where the whole image lies when `crop` of it covers a box, in percentages of the box. */
|
|
26
|
+
export declare const imagePlacement: (crop: IFill.RectInsets | undefined) => {
|
|
27
|
+
left: string;
|
|
28
|
+
top: string;
|
|
29
|
+
width: string;
|
|
30
|
+
height: string;
|
|
31
|
+
};
|
|
32
|
+
//# sourceMappingURL=pictureCrop.d.ts.map
|
|
@@ -3,7 +3,7 @@ import { FixedEdge } from '@sheetxl/utils';
|
|
|
3
3
|
import { ISheetHeader } from '@sheetxl/sdk';
|
|
4
4
|
import { Viewport, ThemeMode } from '@sheetxl/utils-react';
|
|
5
5
|
import { IGridSurface } from '@sheetxl/grid-react';
|
|
6
|
-
import {
|
|
6
|
+
import { CellTextRendererProps, ColumnButtonConfigProps } from '../cell';
|
|
7
7
|
import { SheetLocation } from './IWorksheetElement';
|
|
8
8
|
/**
|
|
9
9
|
* Props for the SheetHeaderElement component.
|
|
@@ -108,7 +108,7 @@ export interface SheetHeaderProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
|
108
108
|
* This is used to customize columnButton popup action and any other customizations desired.
|
|
109
109
|
* This does not invalidate the rendering.
|
|
110
110
|
*/
|
|
111
|
-
propsCellRender?: Partial<
|
|
111
|
+
propsCellRender?: Partial<CellTextRendererProps> & ColumnButtonConfigProps;
|
|
112
112
|
/**
|
|
113
113
|
* Ref for the HTMLDivElement.
|
|
114
114
|
*/
|
|
@@ -1,13 +1,12 @@
|
|
|
1
1
|
import { IWorksheet, ICell, IMovable } from '@sheetxl/sdk';
|
|
2
|
-
import { ViewportMetrics, ScrollPaneProps, Viewport, ThemeMode, LoadingPanelProps, ErrorPanelProps } from '@sheetxl/utils-react';
|
|
2
|
+
import { ViewportMetrics, ScrollPaneProps, Viewport, ThemeMode, LoadingPanelProps, ErrorPanelProps, RenderSlotFn } from '@sheetxl/utils-react';
|
|
3
3
|
import { GridSurfaceProps, IGridSurface, IEditable, LayerNode } from '@sheetxl/grid-react';
|
|
4
|
-
import {
|
|
4
|
+
import { CellTextRendererProps, ColumnButtonConfigProps, OutlineProps } from '../cell';
|
|
5
5
|
import { MovableElementProps } from '../movable';
|
|
6
6
|
import { CommentCardRenderProps } from '../comment';
|
|
7
7
|
import { HyperlinkCardRenderProps, HyperlinkLayerProps } from '../layer/HyperlinkLayer';
|
|
8
8
|
import { CellErrorTip } from '../layer/CellErrorLayer';
|
|
9
|
-
import {
|
|
10
|
-
import { ValidationAlert } from '../editor/validationAlert';
|
|
9
|
+
import { ValidationPromptRenderProps, ValidationAlertRenderProps } from '../layer/ValidationPromptLayer';
|
|
11
10
|
import { TableToolbarRenderProps } from '../layer/TableToolbar';
|
|
12
11
|
import { CommandContext } from '../frame';
|
|
13
12
|
import { ISheetHeaderElement, SheetHeaderProps } from './ISheetHeaderElement';
|
|
@@ -55,12 +54,12 @@ export interface WorksheetElementProps extends React.HTMLAttributes<HTMLDivEleme
|
|
|
55
54
|
* Custom loading panel, shown while a `Promise` {@link WorksheetElementProps.sheet} resolves or the
|
|
56
55
|
* text engine loads. Defaults to a spinner.
|
|
57
56
|
*/
|
|
58
|
-
renderSheetLoading?:
|
|
57
|
+
renderSheetLoading?: RenderSlotFn<LoadingPanelProps> | null;
|
|
59
58
|
/**
|
|
60
59
|
* Custom error panel, shown when a `Promise` {@link WorksheetElementProps.sheet} fails to resolve.
|
|
61
60
|
* Defaults to a minimal message.
|
|
62
61
|
*/
|
|
63
|
-
renderSheetError?:
|
|
62
|
+
renderSheetError?: RenderSlotFn<ErrorPanelProps> | null;
|
|
64
63
|
/**
|
|
65
64
|
* The app (chrome / header) color scheme — selects the header/app surface mode.
|
|
66
65
|
*/
|
|
@@ -149,52 +148,52 @@ export interface WorksheetElementProps extends React.HTMLAttributes<HTMLDivEleme
|
|
|
149
148
|
*/
|
|
150
149
|
viewportComponent?: React.ReactNode;
|
|
151
150
|
/**
|
|
152
|
-
* Render
|
|
151
|
+
* Render a movable element (a chart, shape or picture).
|
|
153
152
|
*
|
|
154
153
|
* @param props - {@link MovableElementProps}
|
|
155
|
-
* @returns A React Element representing the IMovable.
|
|
156
154
|
*/
|
|
157
|
-
renderMovable?:
|
|
155
|
+
renderMovable?: RenderSlotFn<MovableElementProps>;
|
|
158
156
|
/**
|
|
159
157
|
* Renders the card of a threaded comment beside its cell: on hover, on selection, and as a draft
|
|
160
|
-
* when a command asks for one.
|
|
158
|
+
* when a command asks for one. The default shows no card; the indicators are drawn either way.
|
|
161
159
|
*
|
|
162
160
|
* @param props - {@link CommentCardRenderProps}
|
|
163
161
|
*/
|
|
164
|
-
renderCommentCard?:
|
|
162
|
+
renderCommentCard?: RenderSlotFn<CommentCardRenderProps> | null;
|
|
165
163
|
/**
|
|
166
164
|
* Renders the card beside a hovered hyperlink cell: its address, copy, edit and remove. Omit for the
|
|
167
|
-
* plain default card.
|
|
165
|
+
* plain default card; `null` for none.
|
|
168
166
|
*
|
|
169
167
|
* @param props - {@link HyperlinkCardRenderProps}
|
|
170
168
|
*/
|
|
171
|
-
renderHyperlinkCard?:
|
|
169
|
+
renderHyperlinkCard?: RenderSlotFn<HyperlinkCardRenderProps> | null;
|
|
172
170
|
/** The hyperlink card's options — e.g. `preview` to show a picture of the linked page. */
|
|
173
171
|
propsHyperlink?: Omit<HyperlinkLayerProps, 'sheet' | 'renderCard'>;
|
|
174
172
|
/**
|
|
175
173
|
* Renders the tip beside a hovered cell that carries an error, a warning, a reference cycle or a
|
|
176
|
-
* failed validation. Omit for the plain default tip.
|
|
174
|
+
* failed validation. Omit for the plain default tip; `null` for none.
|
|
177
175
|
*
|
|
178
176
|
* @param tip - {@link CellErrorTip}
|
|
179
177
|
*/
|
|
180
|
-
renderCellErrorTip?:
|
|
178
|
+
renderCellErrorTip?: RenderSlotFn<CellErrorTip> | null;
|
|
181
179
|
/**
|
|
182
180
|
* Renders the input prompt of a data validation under the selected cell. Spread `floatProps` on
|
|
183
|
-
* the returned element. Omit for the plain default box: the title in bold over the message
|
|
181
|
+
* the returned element. Omit for the plain default box: the title in bold over the message; `null`
|
|
182
|
+
* for none.
|
|
184
183
|
*/
|
|
185
|
-
renderValidationPrompt?:
|
|
184
|
+
renderValidationPrompt?: RenderSlotFn<ValidationPromptRenderProps> | null;
|
|
186
185
|
/**
|
|
187
186
|
* Renders the alert a refused or questioned entry raises in the prompt's place. Spread `floatProps`
|
|
188
|
-
* on the returned element. Omit for the plain default card.
|
|
187
|
+
* on the returned element. Omit for the plain default card; `null` for none.
|
|
189
188
|
*/
|
|
190
|
-
renderValidationAlert?:
|
|
189
|
+
renderValidationAlert?: RenderSlotFn<ValidationAlertRenderProps> | null;
|
|
191
190
|
/**
|
|
192
191
|
* Renders the toolbar that floats at a hovered table's top-right corner: a quick action and a
|
|
193
|
-
* dropdown of the table's commands. Omit for the plain default split button.
|
|
192
|
+
* dropdown of the table's commands. Omit for the plain default split button; `null` for none.
|
|
194
193
|
*
|
|
195
194
|
* @param props - {@link TableToolbarRenderProps}
|
|
196
195
|
*/
|
|
197
|
-
renderTableToolbar?:
|
|
196
|
+
renderTableToolbar?: RenderSlotFn<TableToolbarRenderProps> | null;
|
|
198
197
|
/**
|
|
199
198
|
* Render element(s) directly onto the `GridSurface`, bottom → top — the same {@link LayerNode} the
|
|
200
199
|
* grid takes for its children (a node or an array of them). Each layer reads its pane from context
|
|
@@ -215,7 +214,7 @@ export interface WorksheetElementProps extends React.HTMLAttributes<HTMLDivEleme
|
|
|
215
214
|
* This is used to customize columnButton popup action and any other customizations desired.
|
|
216
215
|
* This does not invalidate the rendering
|
|
217
216
|
*/
|
|
218
|
-
propsCellRender?: Partial<
|
|
217
|
+
propsCellRender?: Partial<CellTextRendererProps> & ColumnButtonConfigProps;
|
|
219
218
|
/**
|
|
220
219
|
* Props for the outline: the gutters that show row and column groups, and their level buttons.
|
|
221
220
|
*
|
|
@@ -7,6 +7,9 @@ import { SheetCommandData } from './SheetCommands';
|
|
|
7
7
|
* ready-mode `'startEdit'` insert commands). */
|
|
8
8
|
export interface SheetCommandContributorData extends SheetCommandData {
|
|
9
9
|
editable?: SheetEditable | null;
|
|
10
|
+
/** Set when the sheet owns `manager` (no workbook above publishes one): the sheet then also contributes
|
|
11
|
+
* `undo`/`redo`, which a workbook otherwise authors. */
|
|
12
|
+
ownsUndo?: boolean;
|
|
10
13
|
}
|
|
11
14
|
/**
|
|
12
15
|
* The `sheet` feature's command contributor: `static` seeds the catalog presentation; `dynamic` attaches the
|
|
@@ -19,7 +19,7 @@ export interface SheetOutlineElementProps extends React.HTMLAttributes<HTMLEleme
|
|
|
19
19
|
/** The app color scheme. */
|
|
20
20
|
colorScheme?: ThemeMode;
|
|
21
21
|
/** Renders a group's collapse / expand button. Defaults to `OutlineButton`. */
|
|
22
|
-
renderButton?: (props: OutlineButtonProps) => React.ReactNode;
|
|
22
|
+
renderButton?: ((props: OutlineButtonProps) => React.ReactNode) | null;
|
|
23
23
|
/** The space around the buttons, in pixels: between neighbors, before the first and after the last. */
|
|
24
24
|
laneGap?: number;
|
|
25
25
|
/** Space between a bracket's end and its button, in pixels. */
|
|
@@ -56,7 +56,7 @@ export interface SheetOutlineLevelsProps extends React.HTMLAttributes<HTMLElemen
|
|
|
56
56
|
/** The app color scheme. */
|
|
57
57
|
colorScheme?: ThemeMode;
|
|
58
58
|
/** Renders a level button. Defaults to `OutlineLevelButton`. */
|
|
59
|
-
renderLevelButton?: (props: OutlineLevelButtonProps) => React.ReactNode;
|
|
59
|
+
renderLevelButton?: ((props: OutlineLevelButtonProps) => React.ReactNode) | null;
|
|
60
60
|
}
|
|
61
61
|
/**
|
|
62
62
|
* The level buttons `1`..`n` for one axis: button *k* shows the groups above level *k* and collapses
|
|
@@ -3,9 +3,9 @@ import { ErrorPanelProps, LoadingPanelProps } from '@sheetxl/utils-react';
|
|
|
3
3
|
/**
|
|
4
4
|
* The default loading panel of a sheet or workbook element: a spinner, centered.
|
|
5
5
|
*/
|
|
6
|
-
export declare const
|
|
6
|
+
export declare const defaultRenderSheetLoading: (props: LoadingPanelProps) => React.ReactElement;
|
|
7
7
|
/**
|
|
8
8
|
* The default error panel of a sheet or workbook element: the error's message, centered.
|
|
9
9
|
*/
|
|
10
|
-
export declare const
|
|
10
|
+
export declare const defaultRenderSheetError: (props: ErrorPanelProps) => React.ReactElement;
|
|
11
11
|
//# sourceMappingURL=SheetPanels.d.ts.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { IWorksheet } from '@sheetxl/sdk';
|
|
2
|
+
/**
|
|
3
|
+
* Whether the sheet's protection lets a hyperlink be added, changed or removed: the two options
|
|
4
|
+
* `ICellRange.setHyperlink` asks for.
|
|
5
|
+
*/
|
|
6
|
+
export declare const isHyperlinkEditAllowed: (sheet: IWorksheet) => boolean;
|
|
7
|
+
//# sourceMappingURL=_hyperlinkEdit.d.ts.map
|
|
@@ -13,7 +13,7 @@ import { IRange, IWorksheet } from '@sheetxl/sdk';
|
|
|
13
13
|
* makes a cycle a computation rather than a mistake, and its result is what the user turned the
|
|
14
14
|
* setting on for. Excel is the same and this is the measurement it comes from — its
|
|
15
15
|
* `Worksheet.CircularReference` answers `(none)` while iterating and names the cell again the
|
|
16
|
-
* moment `Iteration` is turned off
|
|
16
|
+
* moment `Iteration` is turned off. The cell keeps its marker either
|
|
17
17
|
* way, so an iterated cycle stays discoverable where it is; what goes quiet is the workbook-level
|
|
18
18
|
* alarm, which is the same line `ICell.getErrors()` draws (§7.3).
|
|
19
19
|
*/
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import { default as React } from 'react';
|
|
2
2
|
import { CollisionDetection, DragStartEvent, DropAnimation, KeyboardCoordinateGetter, Modifiers, MeasuringConfiguration, PointerActivationConstraint, UniqueIdentifier } from '@dnd-kit/core';
|
|
3
3
|
import { arrayMove, SortingStrategy, AnimateLayoutChanges, NewIndexGetter } from '@dnd-kit/sortable';
|
|
4
|
+
import { RenderSlotFn } from '@sheetxl/utils-react';
|
|
5
|
+
import { TabStripItemRenderProps } from './TabStripItem';
|
|
4
6
|
export interface SortableProps {
|
|
5
7
|
className?: string;
|
|
6
8
|
activationConstraint?: PointerActivationConstraint;
|
|
@@ -15,11 +17,9 @@ export interface SortableProps {
|
|
|
15
17
|
onMove?: (indexFrom: number, indexTo: number) => void;
|
|
16
18
|
measuring?: MeasuringConfiguration;
|
|
17
19
|
modifiers?: Modifiers;
|
|
18
|
-
renderItem?:
|
|
20
|
+
renderItem?: (props: TabStripItemRenderProps) => React.ReactNode;
|
|
19
21
|
removable?: boolean;
|
|
20
|
-
renderDivider?:
|
|
21
|
-
key: string;
|
|
22
|
-
}) => React.ReactElement;
|
|
22
|
+
renderDivider?: RenderSlotFn<React.HTMLAttributes<HTMLElement>>;
|
|
23
23
|
reorderItems?: typeof arrayMove;
|
|
24
24
|
strategy?: SortingStrategy;
|
|
25
25
|
style?: React.CSSProperties;
|
|
@@ -54,7 +54,7 @@ interface SortableItemProps {
|
|
|
54
54
|
useDragOverlay?: boolean;
|
|
55
55
|
onRemove?(id: string): void;
|
|
56
56
|
style(values: any): React.CSSProperties;
|
|
57
|
-
renderItem?(
|
|
57
|
+
renderItem?(props: TabStripItemRenderProps): React.ReactNode;
|
|
58
58
|
wrapperStyle({ index, isDragging, id, }: {
|
|
59
59
|
index: number;
|
|
60
60
|
isDragging: boolean;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { default as React } from 'react';
|
|
2
|
-
import { ScrollButtonProps } from '@sheetxl/utils-react';
|
|
2
|
+
import { RenderSlotFn, ScrollButtonProps } from '@sheetxl/utils-react';
|
|
3
3
|
import { EditableLabelProps } from '../editableLabel';
|
|
4
4
|
import { TabProps } from './Tab';
|
|
5
5
|
export interface TabStripRef extends HTMLDivElement {
|
|
@@ -12,11 +12,11 @@ export interface TabStripProps extends Omit<React.HTMLAttributes<HTMLDivElement>
|
|
|
12
12
|
onSelectedTabIndexChange?: (index: number) => void;
|
|
13
13
|
onTabNameChange?: (index: number, tabName: string) => void;
|
|
14
14
|
onTabMove?: (indexFrom: number, indexTo: number) => void;
|
|
15
|
-
renderScrollButtonStart?:
|
|
16
|
-
renderScrollButtonEnd?:
|
|
17
|
-
renderScrollButtonEdge?:
|
|
18
|
-
renderTabButton?:
|
|
19
|
-
renderTabDivider?:
|
|
15
|
+
renderScrollButtonStart?: RenderSlotFn<ScrollButtonProps> | null;
|
|
16
|
+
renderScrollButtonEnd?: RenderSlotFn<ScrollButtonProps> | null;
|
|
17
|
+
renderScrollButtonEdge?: RenderSlotFn<ScrollButtonProps> | null;
|
|
18
|
+
renderTabButton?: RenderSlotFn<TabProps>;
|
|
19
|
+
renderTabDivider?: RenderSlotFn<React.HTMLAttributes<HTMLElement>>;
|
|
20
20
|
propsEditLabel?: EditableLabelProps;
|
|
21
21
|
disabled?: boolean;
|
|
22
22
|
disableDrag?: boolean;
|
|
@@ -18,19 +18,21 @@ export interface TabStripItemProps {
|
|
|
18
18
|
wrapperStyle?: React.CSSProperties;
|
|
19
19
|
value: React.ReactNode;
|
|
20
20
|
onRemove?(): void;
|
|
21
|
-
renderItem?(
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
21
|
+
renderItem?(props: TabStripItemRenderProps): React.ReactNode;
|
|
22
|
+
}
|
|
23
|
+
/** What a tab strip's item renderer is handed. */
|
|
24
|
+
export interface TabStripItemRenderProps {
|
|
25
|
+
dragOverlay: boolean;
|
|
26
|
+
dragging: boolean;
|
|
27
|
+
sorting: boolean;
|
|
28
|
+
index: number | undefined;
|
|
29
|
+
fadeIn: boolean;
|
|
30
|
+
listeners: DraggableSyntheticListeners;
|
|
31
|
+
ref: React.Ref<HTMLElement>;
|
|
32
|
+
style: React.CSSProperties | undefined;
|
|
33
|
+
transform: TabStripItemProps['transform'];
|
|
34
|
+
transition: TabStripItemProps['transition'];
|
|
35
|
+
value: TabStripItemProps['value'];
|
|
34
36
|
}
|
|
35
37
|
export declare const TabStripItem: React.NamedExoticComponent<TabStripItemProps & React.RefAttributes<HTMLDivElement>>;
|
|
36
38
|
//# sourceMappingURL=TabStripItem.d.ts.map
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { TaskPaneProps } from './ITaskPane';
|
|
3
|
+
/** The key the cell control pane is registered under, and of the command that opens it. */
|
|
4
|
+
export declare const CELL_CONTROL_PANE_KEY = "formatCellControl";
|
|
5
|
+
/**
|
|
6
|
+
* The cell control pane: follows the selection's anchor and shows the body the anchor's content
|
|
7
|
+
* entry supplies ({@link CellContentEntry.pane}). With no control under the anchor, or for a type
|
|
8
|
+
* without a body, it says so.
|
|
9
|
+
*/
|
|
10
|
+
export declare const CellControlPane: (props: TaskPaneProps) => React.ReactElement;
|
|
11
|
+
/**
|
|
12
|
+
* Registers the cell control pane ({@link CellControlPane}) with the default task pane registry,
|
|
13
|
+
* unless a pane is already registered under its key. The `formatCellControl` command calls it before
|
|
14
|
+
* opening the pane.
|
|
15
|
+
*/
|
|
16
|
+
export declare function registerCellControlPane(): void;
|
|
17
|
+
//# sourceMappingURL=CellControlPane.d.ts.map
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { default as React } from 'react';
|
|
2
|
-
import {
|
|
2
|
+
import { RenderSlotFn } from '@sheetxl/utils-react';
|
|
3
|
+
import { ITaskPaneArea, TaskPaneAreaProps } from './TaskPaneArea';
|
|
3
4
|
import { ITaskPaneRegistry } from './TaskPaneRegistry';
|
|
4
5
|
/**
|
|
5
6
|
* Context provider for task panes. Allows custom task pane manager
|
|
@@ -16,8 +17,10 @@ import { ITaskPaneRegistry } from './TaskPaneRegistry';
|
|
|
16
17
|
*/
|
|
17
18
|
export interface TaskPaneProviderProps {
|
|
18
19
|
children: React.ReactNode;
|
|
19
|
-
|
|
20
|
-
|
|
20
|
+
/** Render the area. Pass `props.ref` on to the {@link ITaskPaneAreaElement}. */
|
|
21
|
+
renderArea: RenderSlotFn<TaskPaneAreaProps>;
|
|
22
|
+
/** The area to mount, or `null` once it closes. */
|
|
23
|
+
onUpdateArea: (area: React.ReactElement | null) => void;
|
|
21
24
|
registry?: ITaskPaneRegistry;
|
|
22
25
|
}
|
|
23
26
|
export declare const TaskPaneProvider: React.FC<TaskPaneProviderProps>;
|
|
@@ -11,6 +11,9 @@ import { ITheme } from '@sheetxl/sdk';
|
|
|
11
11
|
*
|
|
12
12
|
* Wraps the generic {@link buildThemeCSS} (utils-react) — OOXML/`--sxl-doc-*` is a react-layer concept — with
|
|
13
13
|
* the doc-color records cast to the token shape (the emitter is a generic `--sxl-*` matrix, agnostic to keys).
|
|
14
|
+
*
|
|
15
|
+
* @param defaultFontSize The document's default font size, in points.
|
|
16
|
+
* @param lineHeight A cell's line in the document font at that size, in px (`ICellStyle.measureText`).
|
|
14
17
|
*/
|
|
15
|
-
export declare const buildDocThemeCSS: (theme: ITheme, defaultFontSize
|
|
18
|
+
export declare const buildDocThemeCSS: (theme: ITheme, defaultFontSize: number, lineHeight: number, layer?: string, scope?: string) => string;
|
|
16
19
|
//# sourceMappingURL=buildDocThemeCSS.d.ts.map
|
|
@@ -8,8 +8,8 @@ import { WorkbookStripProps } from './WorkbookStrip';
|
|
|
8
8
|
* @remarks
|
|
9
9
|
* These can be replaced by host application layers as needed.
|
|
10
10
|
*/
|
|
11
|
-
export declare const
|
|
12
|
-
export declare const
|
|
13
|
-
export declare const
|
|
14
|
-
export declare const
|
|
11
|
+
export declare const defaultRenderWorksheet: (props: WorksheetElementProps) => React.ReactElement;
|
|
12
|
+
export declare const defaultRenderOpaqueSheet: (props: OpaqueSheetElementProps) => React.ReactElement;
|
|
13
|
+
export declare const defaultRenderTabs: (props: WorkbookStripProps) => React.ReactElement;
|
|
14
|
+
export declare const defaultRenderWorkbookLoading: (props: LoadingPanelProps) => React.ReactElement;
|
|
15
15
|
//# sourceMappingURL=DefaultRenderers.d.ts.map
|