@cesdk/cesdk-js 1.64.0-nightly.20251026 → 1.64.0-nightly.20251028
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/assets/core/{cesdk-v1.64.0-nightly.20251026-EYEJRRU4.wasm → cesdk-v1.64.0-nightly.20251028-5SLHS4G4.wasm} +0 -0
- package/assets/core/{worker-host-v1.64.0-nightly.20251026.js → worker-host-v1.64.0-nightly.20251028.js} +1 -1
- package/assets/i18n/de.json +6 -2
- package/assets/i18n/en.json +6 -2
- package/assets/ui/stylesheets/cesdk-themes.css +4 -4
- package/assets/ui/stylesheets/cesdk.css +31 -19
- package/cesdk.umd.js +1 -1
- package/index.d.ts +342 -16
- package/index.js +1 -1
- package/package.json +2 -2
- /package/assets/core/{cesdk-v1.64.0-nightly.20251026-44YCFRT6.data → cesdk-v1.64.0-nightly.20251028-44YCFRT6.data} +0 -0
package/index.d.ts
CHANGED
|
@@ -957,6 +957,8 @@ export declare interface BuiltinTranslations {
|
|
|
957
957
|
'common.colorValue': string;
|
|
958
958
|
'common.confirm': string;
|
|
959
959
|
'common.controlKey': string;
|
|
960
|
+
'common.shiftKey': string;
|
|
961
|
+
'common.altKey': string;
|
|
960
962
|
'common.custom': string;
|
|
961
963
|
'common.defaultDuration': string;
|
|
962
964
|
'common.defaultDuration.inUnit': string;
|
|
@@ -1166,6 +1168,8 @@ export declare interface BuiltinTranslations {
|
|
|
1166
1168
|
'component.placeholder.appearance.description': string;
|
|
1167
1169
|
'component.placeholder.arrange': string;
|
|
1168
1170
|
'component.placeholder.arrange.description': string;
|
|
1171
|
+
'component.placeholder.audio': string;
|
|
1172
|
+
'component.placeholder.audio.description': string;
|
|
1169
1173
|
'component.placeholder.create': string;
|
|
1170
1174
|
'component.placeholder.disableAll': string;
|
|
1171
1175
|
'component.placeholder.enableAll': string;
|
|
@@ -2016,6 +2020,8 @@ export declare interface BuiltinTranslations {
|
|
|
2016
2020
|
'scope.appearance.filter.tooltip': string;
|
|
2017
2021
|
'scope.appearance.shadow': string;
|
|
2018
2022
|
'scope.appearance.shadow.tooltip': string;
|
|
2023
|
+
'scope.audio.change': string;
|
|
2024
|
+
'scope.audio.change.tooltip': string;
|
|
2019
2025
|
'scope.editor.select': string;
|
|
2020
2026
|
'scope.fill.change': string;
|
|
2021
2027
|
'scope.fill.change.tooltip': string;
|
|
@@ -2023,8 +2029,6 @@ export declare interface BuiltinTranslations {
|
|
|
2023
2029
|
'scope.fill.change.text.tooltip': string;
|
|
2024
2030
|
'scope.fill.change.graphic': string;
|
|
2025
2031
|
'scope.fill.change.graphic.tooltip': string;
|
|
2026
|
-
'scope.fill.change.audio': string;
|
|
2027
|
-
'scope.fill.change.audio.tooltip': string;
|
|
2028
2032
|
'scope.fill.changeType': string;
|
|
2029
2033
|
'scope.fill.changeType.tooltip': string;
|
|
2030
2034
|
'scope.layer.blendMode': string;
|
|
@@ -2105,7 +2109,7 @@ export declare interface ButtonGroupOptions {
|
|
|
2105
2109
|
* behavior and appearance of a button. These options include settings for the
|
|
2106
2110
|
* input label, input label position, label, label alignment, tooltip, click
|
|
2107
2111
|
* handler, variant, color, size, icon, trailing icon, active state, selected state,
|
|
2108
|
-
* disabled state, loading state, loading progress, and
|
|
2112
|
+
* disabled state, loading state, loading progress, suffix, and keyboard shortcut.
|
|
2109
2113
|
*
|
|
2110
2114
|
* @public
|
|
2111
2115
|
*/
|
|
@@ -2127,6 +2131,12 @@ export declare interface ButtonOptions {
|
|
|
2127
2131
|
isLoading?: boolean;
|
|
2128
2132
|
loadingProgress?: number;
|
|
2129
2133
|
suffix?: Suffix;
|
|
2134
|
+
/**
|
|
2135
|
+
* Keyboard shortcut to display (e.g., 'Meta+C', 'Meta+V', 'Alt+D').
|
|
2136
|
+
* Automatically renders OS-appropriate modifiers (⌘ on macOS, Ctrl on Windows/Linux).
|
|
2137
|
+
* Hidden on small viewports.
|
|
2138
|
+
*/
|
|
2139
|
+
shortcut?: string;
|
|
2130
2140
|
}
|
|
2131
2141
|
|
|
2132
2142
|
/**
|
|
@@ -2196,14 +2206,75 @@ export { Canvas }
|
|
|
2196
2206
|
export declare type CanvasBarComponentId = 'ly.img.separator' | 'ly.img.spacer' | 'ly.img.settings.canvasBar' | 'ly.img.page.add.canvasBar' | (string & {});
|
|
2197
2207
|
|
|
2198
2208
|
/**
|
|
2199
|
-
*
|
|
2209
|
+
* @public
|
|
2210
|
+
* Base interface for action buttons in the canvas menu.
|
|
2211
|
+
* Contains common properties shared across all canvas menu button types.
|
|
2200
2212
|
*
|
|
2201
|
-
*
|
|
2202
|
-
*
|
|
2213
|
+
* - `onClick`: Handler invoked when the button is clicked.
|
|
2214
|
+
* - `label`: Optional label for the button.
|
|
2215
|
+
* - `icon`: Optional icon name to display on the button.
|
|
2216
|
+
* - `variant`: Optional style variant of the button, either 'regular' or 'plain'.
|
|
2217
|
+
* - `isDisabled`: Optional disabled property.
|
|
2218
|
+
* - `shortcut`: Optional keyboard shortcut displayed alongside the action.
|
|
2219
|
+
*/
|
|
2220
|
+
export declare interface CanvasMenuActionButton extends OrderComponent {
|
|
2221
|
+
id: 'ly.img.flipX.canvasMenu' | 'ly.img.flipY.canvasMenu' | 'ly.img.copy.canvasMenu' | 'ly.img.paste.canvasMenu';
|
|
2222
|
+
onClick?: () => void | Promise<void>;
|
|
2223
|
+
label?: string;
|
|
2224
|
+
icon?: string;
|
|
2225
|
+
variant?: 'regular' | 'plain';
|
|
2226
|
+
isDisabled?: boolean;
|
|
2227
|
+
shortcut?: string;
|
|
2228
|
+
}
|
|
2229
|
+
|
|
2230
|
+
/**
|
|
2231
|
+
* A list of the component IDs that can be used in the canvas menu.
|
|
2232
|
+
* @public
|
|
2233
|
+
*/
|
|
2234
|
+
export declare type CanvasMenuComponentId = 'ly.img.separator' | 'ly.img.spacer' | 'ly.img.group.enter.canvasMenu' | 'ly.img.group.select.canvasMenu' | 'ly.img.page.moveUp.canvasMenu' | 'ly.img.page.moveDown.canvasMenu' | 'ly.img.text.edit.canvasMenu' | 'ly.img.replace.canvasMenu' | 'ly.img.placeholder.canvasMenu' | 'ly.img.bringForward.canvasMenu' | 'ly.img.sendBackward.canvasMenu' | 'ly.img.duplicate.canvasMenu' | 'ly.img.delete.canvasMenu' | 'ly.img.options.canvasMenu' | 'ly.img.flipX.canvasMenu' | 'ly.img.flipY.canvasMenu' | 'ly.img.copy.canvasMenu' | 'ly.img.paste.canvasMenu' | 'ly.img.text.color.canvasMenu' | 'ly.img.text.bold.canvasMenu' | 'ly.img.text.italic.canvasMenu' | 'ly.img.text.variables.canvasMenu' | (string & {});
|
|
2235
|
+
|
|
2236
|
+
/**
|
|
2237
|
+
* @public
|
|
2238
|
+
*/
|
|
2239
|
+
export declare type CanvasMenuComponents = CanvasMenuActionButton | CanvasMenuOptionsComponent | CanvasMenuCustomActionButton;
|
|
2240
|
+
|
|
2241
|
+
/**
|
|
2242
|
+
* @public
|
|
2243
|
+
* Interface representing a custom canvas menu action button.
|
|
2244
|
+
* Note: This component requires a key and has a required label, unlike other action buttons.
|
|
2245
|
+
*/
|
|
2246
|
+
export declare interface CanvasMenuCustomActionButton extends OrderComponent {
|
|
2247
|
+
id: 'ly.img.action.canvasMenu';
|
|
2248
|
+
key: string;
|
|
2249
|
+
onClick: () => void | Promise<void>;
|
|
2250
|
+
label: string;
|
|
2251
|
+
icon?: string;
|
|
2252
|
+
variant?: 'regular' | 'plain';
|
|
2253
|
+
isDisabled?: boolean;
|
|
2254
|
+
shortcut?: string;
|
|
2255
|
+
}
|
|
2256
|
+
|
|
2257
|
+
/**
|
|
2258
|
+
* @public
|
|
2259
|
+
* Interface representing the canvas menu options dropdown component.
|
|
2260
|
+
* This component can contain children components that are rendered in a dropdown menu.
|
|
2203
2261
|
*
|
|
2262
|
+
* - `children`: Optional array of child component IDs or components to render in the dropdown.
|
|
2263
|
+
* - `icon`: Optional icon name to display on the dropdown button.
|
|
2264
|
+
* - `variant`: Optional style variant of the dropdown button, either 'regular' or 'plain'.
|
|
2265
|
+
* - `tooltip`: Optional tooltip text to display when hovering over the dropdown button.
|
|
2266
|
+
*/
|
|
2267
|
+
export declare interface CanvasMenuOptionsComponent extends OrderComponentWithChildren<CanvasMenuComponentId, CanvasMenuActionButton> {
|
|
2268
|
+
id: 'ly.img.options.canvasMenu';
|
|
2269
|
+
icon?: string;
|
|
2270
|
+
variant?: 'regular' | 'plain';
|
|
2271
|
+
tooltip?: string;
|
|
2272
|
+
}
|
|
2273
|
+
|
|
2274
|
+
/**
|
|
2204
2275
|
* @public
|
|
2205
2276
|
*/
|
|
2206
|
-
export declare type
|
|
2277
|
+
export declare type CanvasMenuOrderComponent = CanvasMenuComponents | OrderComponentWithChildren<CanvasMenuComponentId, CanvasMenuComponents>;
|
|
2207
2278
|
|
|
2208
2279
|
/**
|
|
2209
2280
|
* @public
|
|
@@ -2709,6 +2780,9 @@ declare class CreativeEditorSDK {
|
|
|
2709
2780
|
*/
|
|
2710
2781
|
unstable_onActivePageChanged(callback: (id: number) => void): () => void;
|
|
2711
2782
|
/**
|
|
2783
|
+
* Focus on a specific page and zoom to fit it in the viewport.
|
|
2784
|
+
* @param pageId - The ID of the page to focus on
|
|
2785
|
+
* @returns A promise that resolves when the focus operation is complete
|
|
2712
2786
|
* @category Page Management
|
|
2713
2787
|
* @experimental This API is experimental and may change or be removed in future versions.
|
|
2714
2788
|
*/
|
|
@@ -3618,7 +3692,7 @@ export declare class FeatureAPI {
|
|
|
3618
3692
|
*
|
|
3619
3693
|
* @public
|
|
3620
3694
|
*/
|
|
3621
|
-
export declare type FeatureId = 'ly.img.navigation.bar' | 'ly.img.navigation.back' | 'ly.img.navigation.close' | 'ly.img.navigation.undoRedo' | 'ly.img.navigation.zoom' | 'ly.img.navigation.actions' | 'ly.img.delete' | 'ly.img.duplicate' | 'ly.img.placeholder' | 'ly.img.preview' | 'ly.img.page.move' | 'ly.img.page.add' | 'ly.img.group' | 'ly.img.replace' | 'ly.img.text.edit' | 'ly.img.text.typeface' | 'ly.img.text.fontSize' | 'ly.img.text.fontStyle' | 'ly.img.text.alignment' | 'ly.img.text.advanced' | 'ly.img.text.background' | 'ly.img.adjustment' | 'ly.img.filter' | 'ly.img.filter.lut' | 'ly.img.filter.duotone' | 'ly.img.effect' | 'ly.img.blur' | 'ly.img.shadow' | 'ly.img.cutout' | 'ly.img.fill' | 'ly.img.shape.options' | 'ly.img.combine' | 'ly.img.trim' | 'ly.img.crop' | 'ly.img.crop.size' | 'ly.img.crop.rotation' | 'ly.img.crop.flip' | 'ly.img.crop.fillMode' | 'ly.img.crop.scale' | 'ly.img.crop.position' | 'ly.img.volume' | 'ly.img.stroke' | 'ly.img.position' | 'ly.img.animations' | 'ly.img.opacity' | 'ly.img.blendMode' | 'ly.img.video.timeline' | 'ly.img.video.clips' | 'ly.img.video.overlays' | 'ly.img.video.audio' | 'ly.img.video.addClip' | 'ly.img.video.controls' | 'ly.img.video.controls.toggle' | 'ly.img.video.controls.background' | 'ly.img.video.controls.playback' | 'ly.img.video.controls.loop' | 'ly.img.video.controls.split' | 'ly.img.video.controls.timelineZoom' | 'ly.img.video.caption' | 'ly.img.transform.position' | 'ly.img.transform.size' | 'ly.img.transform.rotation' | 'ly.img.transform.flip' | 'ly.img.inspector.bar' | 'ly.img.inspector.toggle' | 'ly.img.page.resize' | 'ly.img.dock' | 'ly.img.canvas.bar' | 'ly.img.canvas.menu' | 'ly.img.inspector' | 'ly.img.settings' | 'ly.img.library.panel' | (string & {});
|
|
3695
|
+
export declare type FeatureId = 'ly.img.navigation.bar' | 'ly.img.navigation.back' | 'ly.img.navigation.close' | 'ly.img.navigation.undoRedo' | 'ly.img.navigation.zoom' | 'ly.img.navigation.actions' | 'ly.img.delete' | 'ly.img.duplicate' | 'ly.img.placeholder' | 'ly.img.placeholder.general' | 'ly.img.placeholder.arrange' | 'ly.img.placeholder.fill' | 'ly.img.placeholder.shape' | 'ly.img.placeholder.stroke' | 'ly.img.placeholder.text' | 'ly.img.placeholder.appearance' | 'ly.img.placeholder.general.opacity' | 'ly.img.placeholder.general.blendMode' | 'ly.img.placeholder.general.duplicate' | 'ly.img.placeholder.general.delete' | 'ly.img.placeholder.arrange.move' | 'ly.img.placeholder.arrange.resize' | 'ly.img.placeholder.arrange.rotate' | 'ly.img.placeholder.arrange.flip' | 'ly.img.placeholder.fill.change' | 'ly.img.placeholder.fill.changeType' | 'ly.img.placeholder.fill.actAsPlaceholder' | 'ly.img.placeholder.fill.crop' | 'ly.img.placeholder.shape.change' | 'ly.img.placeholder.stroke.change' | 'ly.img.placeholder.text.edit' | 'ly.img.placeholder.text.actAsPlaceholder' | 'ly.img.placeholder.text.character' | 'ly.img.placeholder.appearance.adjustments' | 'ly.img.placeholder.appearance.filter' | 'ly.img.placeholder.appearance.effect' | 'ly.img.placeholder.appearance.blur' | 'ly.img.placeholder.appearance.shadow' | 'ly.img.placeholder.appearance.animations' | 'ly.img.preview' | 'ly.img.page.move' | 'ly.img.page.add' | 'ly.img.group' | 'ly.img.replace' | 'ly.img.text.edit' | 'ly.img.text.typeface' | 'ly.img.text.fontSize' | 'ly.img.text.fontStyle' | 'ly.img.text.alignment' | 'ly.img.text.advanced' | 'ly.img.text.background' | 'ly.img.adjustment' | 'ly.img.filter' | 'ly.img.filter.lut' | 'ly.img.filter.duotone' | 'ly.img.effect' | 'ly.img.blur' | 'ly.img.shadow' | 'ly.img.cutout' | 'ly.img.fill' | 'ly.img.shape.options' | 'ly.img.combine' | 'ly.img.trim' | 'ly.img.crop' | 'ly.img.crop.size' | 'ly.img.crop.rotation' | 'ly.img.crop.flip' | 'ly.img.crop.fillMode' | 'ly.img.crop.scale' | 'ly.img.crop.position' | 'ly.img.crop.panel.autoOpen' | 'ly.img.volume' | 'ly.img.stroke' | 'ly.img.position' | 'ly.img.animations' | 'ly.img.opacity' | 'ly.img.blendMode' | 'ly.img.video.timeline' | 'ly.img.video.clips' | 'ly.img.video.overlays' | 'ly.img.video.audio' | 'ly.img.video.addClip' | 'ly.img.video.controls' | 'ly.img.video.controls.toggle' | 'ly.img.video.controls.background' | 'ly.img.video.controls.playback' | 'ly.img.video.controls.loop' | 'ly.img.video.controls.split' | 'ly.img.video.controls.timelineZoom' | 'ly.img.video.caption' | 'ly.img.transform.position' | 'ly.img.transform.size' | 'ly.img.transform.rotation' | 'ly.img.transform.flip' | 'ly.img.inspector.bar' | 'ly.img.inspector.toggle' | 'ly.img.page.resize' | 'ly.img.dock' | 'ly.img.canvas.bar' | 'ly.img.canvas.menu' | 'ly.img.inspector' | 'ly.img.settings' | 'ly.img.library.panel' | (string & {});
|
|
3622
3696
|
|
|
3623
3697
|
/**
|
|
3624
3698
|
* The feature predicate is used to enable or disable a feature
|
|
@@ -4360,6 +4434,39 @@ export declare interface RegisteredActions {
|
|
|
4360
4434
|
* Action invoked when the add clip button is pressed in the video timeline
|
|
4361
4435
|
*/
|
|
4362
4436
|
addClip: VoidFunction;
|
|
4437
|
+
/**
|
|
4438
|
+
* Zoom actions for explicit zoom control
|
|
4439
|
+
*/
|
|
4440
|
+
/** Action for zooming to a specific block */
|
|
4441
|
+
'zoom.toBlock': ZoomToBlockAction;
|
|
4442
|
+
/** Action for zooming to the current page with optional padding */
|
|
4443
|
+
'zoom.toPage': ZoomToPageAction;
|
|
4444
|
+
/** Action for zooming to the current selection */
|
|
4445
|
+
'zoom.toSelection': ZoomToSelectionAction;
|
|
4446
|
+
/** Action for zooming in by one step */
|
|
4447
|
+
'zoom.in': ZoomInAction;
|
|
4448
|
+
/** Action for zooming out by one step */
|
|
4449
|
+
'zoom.out': ZoomOutAction;
|
|
4450
|
+
/** Action for setting zoom to a specific level */
|
|
4451
|
+
'zoom.toLevel': ZoomToLevelAction;
|
|
4452
|
+
/**
|
|
4453
|
+
* Scroll actions
|
|
4454
|
+
*/
|
|
4455
|
+
/** Action for scrolling to a specific page */
|
|
4456
|
+
'scroll.toPage': ScrollToPageAction;
|
|
4457
|
+
/**
|
|
4458
|
+
* Video timeline zoom actions
|
|
4459
|
+
*/
|
|
4460
|
+
/** Action for zooming in the video timeline */
|
|
4461
|
+
'timeline.zoom.in': TimelineZoomInAction;
|
|
4462
|
+
/** Action for zooming out the video timeline */
|
|
4463
|
+
'timeline.zoom.out': TimelineZoomOutAction;
|
|
4464
|
+
/** Action for fitting the video timeline to show all content */
|
|
4465
|
+
'timeline.zoom.fit': TimelineZoomToFitAction;
|
|
4466
|
+
/** Action for setting the video timeline zoom to a specific level */
|
|
4467
|
+
'timeline.zoom.toLevel': TimelineZoomToLevelAction;
|
|
4468
|
+
/** Action for resetting the video timeline zoom to default */
|
|
4469
|
+
'timeline.zoom.reset': TimelineZoomResetAction;
|
|
4363
4470
|
}
|
|
4364
4471
|
|
|
4365
4472
|
/**
|
|
@@ -4430,6 +4537,17 @@ export { SceneMode }
|
|
|
4430
4537
|
|
|
4431
4538
|
export { Scope }
|
|
4432
4539
|
|
|
4540
|
+
/**
|
|
4541
|
+
* Action function for scrolling to a specific page
|
|
4542
|
+
* @public
|
|
4543
|
+
*/
|
|
4544
|
+
export declare type ScrollToPageAction = (options?: {
|
|
4545
|
+
/** The page ID to scroll to (defaults to current page) */
|
|
4546
|
+
pageId?: number;
|
|
4547
|
+
/** Whether to animate the scroll (default: false) */
|
|
4548
|
+
animate?: boolean;
|
|
4549
|
+
}) => Promise<void>;
|
|
4550
|
+
|
|
4433
4551
|
/**
|
|
4434
4552
|
* Represents options for a section.
|
|
4435
4553
|
*
|
|
@@ -4631,6 +4749,39 @@ declare type ThemeConfig = Theme | ThemeFn | 'system';
|
|
|
4631
4749
|
*/
|
|
4632
4750
|
declare type ThemeFn = () => Theme;
|
|
4633
4751
|
|
|
4752
|
+
/**
|
|
4753
|
+
* Video timeline zoom action types
|
|
4754
|
+
*/
|
|
4755
|
+
/**
|
|
4756
|
+
* Action function for zooming in the video timeline by one step
|
|
4757
|
+
* @public
|
|
4758
|
+
*/
|
|
4759
|
+
export declare type TimelineZoomInAction = () => void;
|
|
4760
|
+
|
|
4761
|
+
/**
|
|
4762
|
+
* Action function for zooming out the video timeline by one step
|
|
4763
|
+
* @public
|
|
4764
|
+
*/
|
|
4765
|
+
export declare type TimelineZoomOutAction = () => void;
|
|
4766
|
+
|
|
4767
|
+
/**
|
|
4768
|
+
* Action function for resetting the video timeline zoom to default level (1.0)
|
|
4769
|
+
* @public
|
|
4770
|
+
*/
|
|
4771
|
+
export declare type TimelineZoomResetAction = () => void;
|
|
4772
|
+
|
|
4773
|
+
/**
|
|
4774
|
+
* Action function for fitting the video timeline to show all content
|
|
4775
|
+
* @public
|
|
4776
|
+
*/
|
|
4777
|
+
export declare type TimelineZoomToFitAction = () => void;
|
|
4778
|
+
|
|
4779
|
+
/**
|
|
4780
|
+
* Action function for setting the video timeline zoom to a specific level
|
|
4781
|
+
* @public
|
|
4782
|
+
*/
|
|
4783
|
+
export declare type TimelineZoomToLevelAction = (level: number) => void;
|
|
4784
|
+
|
|
4634
4785
|
export { TransientResource }
|
|
4635
4786
|
|
|
4636
4787
|
/**
|
|
@@ -5523,7 +5674,7 @@ export declare class UserInterfaceAPI {
|
|
|
5523
5674
|
* @param canvasMenuOrder - Array of component IDs defining the canvas menu order.
|
|
5524
5675
|
* @param orderContext - Optional context specifying when this order applies.
|
|
5525
5676
|
*/
|
|
5526
|
-
setCanvasMenuOrder(canvasMenuOrder: (CanvasMenuComponentId |
|
|
5677
|
+
setCanvasMenuOrder(canvasMenuOrder: (CanvasMenuComponentId | CanvasMenuOrderComponent)[], orderContext?: OrderContext): void;
|
|
5527
5678
|
/**
|
|
5528
5679
|
* Gets the current rendering order of canvas menu components.
|
|
5529
5680
|
*
|
|
@@ -5535,7 +5686,7 @@ export declare class UserInterfaceAPI {
|
|
|
5535
5686
|
* @param orderContext - Optional context specifying which order to retrieve.
|
|
5536
5687
|
* @returns Array of component configurations defining the canvas menu order.
|
|
5537
5688
|
*/
|
|
5538
|
-
getCanvasMenuOrder(orderContext?: OrderContext):
|
|
5689
|
+
getCanvasMenuOrder(orderContext?: OrderContext): CanvasMenuOrderComponent[];
|
|
5539
5690
|
/**
|
|
5540
5691
|
* Updates a component in the render order of the canvas menu.
|
|
5541
5692
|
*
|
|
@@ -5551,11 +5702,11 @@ export declare class UserInterfaceAPI {
|
|
|
5551
5702
|
* @param matcher - Function or object to match the component to update.
|
|
5552
5703
|
* @param update - New ID, partial properties, or updater function for the component.
|
|
5553
5704
|
* @param orderContext - Optional context specifying which order to update.
|
|
5554
|
-
* @returns
|
|
5705
|
+
* @returns An object containing the number of updated components and the updated canvas menu order array.
|
|
5555
5706
|
*/
|
|
5556
|
-
updateCanvasMenuOrderComponent(matcher: OrderComponentMatcher<OrderComponent<CanvasMenuComponentId>>, update: CanvasMenuComponentId | Partial<
|
|
5707
|
+
updateCanvasMenuOrderComponent(matcher: OrderComponentMatcher<OrderComponent<CanvasMenuComponentId>>, update: CanvasMenuComponentId | Partial<CanvasMenuOrderComponent> | ((component: CanvasMenuOrderComponent) => Partial<CanvasMenuOrderComponent>), orderContext?: OrderContext): {
|
|
5557
5708
|
updated: number;
|
|
5558
|
-
order:
|
|
5709
|
+
order: CanvasMenuOrderComponent[];
|
|
5559
5710
|
};
|
|
5560
5711
|
/**
|
|
5561
5712
|
* Removes a component from the render order of the canvas menu.
|
|
@@ -5568,11 +5719,11 @@ export declare class UserInterfaceAPI {
|
|
|
5568
5719
|
* @category UI Layout
|
|
5569
5720
|
* @param matcher - Function or object to match the component to remove.
|
|
5570
5721
|
* @param orderContext - Optional context specifying which order to update.
|
|
5571
|
-
* @returns
|
|
5722
|
+
* @returns An object containing the number of removed components and the updated canvas menu order array.
|
|
5572
5723
|
*/
|
|
5573
5724
|
removeCanvasMenuOrderComponent(matcher: OrderComponentMatcher<OrderComponent<CanvasMenuComponentId>>, orderContext?: OrderContext): {
|
|
5574
5725
|
removed: number;
|
|
5575
|
-
order:
|
|
5726
|
+
order: CanvasMenuOrderComponent[];
|
|
5576
5727
|
};
|
|
5577
5728
|
/**
|
|
5578
5729
|
* Inserts a component into the render order of the canvas menu.
|
|
@@ -5590,7 +5741,7 @@ export declare class UserInterfaceAPI {
|
|
|
5590
5741
|
* @param orderContext - Optional context specifying which order to update.
|
|
5591
5742
|
* @returns The updated canvas menu order array.
|
|
5592
5743
|
*/
|
|
5593
|
-
insertCanvasMenuOrderComponent(matcher: OrderComponentMatcher<OrderComponent<CanvasMenuComponentId>>, component: CanvasMenuComponentId |
|
|
5744
|
+
insertCanvasMenuOrderComponent(matcher: OrderComponentMatcher<OrderComponent<CanvasMenuComponentId>>, component: CanvasMenuComponentId | CanvasMenuOrderComponent, location?: InsertOrderComponentLocation, orderContext?: OrderContext): {
|
|
5594
5745
|
inserted: boolean;
|
|
5595
5746
|
order: OrderComponent<CanvasMenuComponentId>[];
|
|
5596
5747
|
};
|
|
@@ -6534,6 +6685,34 @@ export declare class UtilsAPI {
|
|
|
6534
6685
|
* @public
|
|
6535
6686
|
*/
|
|
6536
6687
|
localUpload(file: File, context?: UploadCallbackContext): Promise<AssetDefinition>;
|
|
6688
|
+
/**
|
|
6689
|
+
* Calculates the recommended viewport padding based on current viewport size and settings.
|
|
6690
|
+
* This utility matches the internal padding used by the SDK for zoom operations.
|
|
6691
|
+
*
|
|
6692
|
+
* @param width - Optional viewport width to use instead of current camera width
|
|
6693
|
+
* @param height - Optional viewport height to use instead of current camera height
|
|
6694
|
+
* @returns An object containing paddingX and paddingY values
|
|
6695
|
+
*
|
|
6696
|
+
* @example
|
|
6697
|
+
* ```typescript
|
|
6698
|
+
* const padding = cesdk.utils.calculateViewportPadding();
|
|
6699
|
+
* console.log(`Padding: ${padding.paddingX}x${padding.paddingY}`);
|
|
6700
|
+
*
|
|
6701
|
+
* // Use with custom zoom
|
|
6702
|
+
* await cesdk.engine.scene.zoomToBlock(
|
|
6703
|
+
* pageId,
|
|
6704
|
+
* padding.paddingX,
|
|
6705
|
+
* padding.paddingY,
|
|
6706
|
+
* padding.paddingX,
|
|
6707
|
+
* padding.paddingY
|
|
6708
|
+
* );
|
|
6709
|
+
* ```
|
|
6710
|
+
* @public
|
|
6711
|
+
*/
|
|
6712
|
+
calculateViewportPadding(width?: number, height?: number): {
|
|
6713
|
+
paddingX: number;
|
|
6714
|
+
paddingY: number;
|
|
6715
|
+
};
|
|
6537
6716
|
}
|
|
6538
6717
|
|
|
6539
6718
|
export { VariableAPI }
|
|
@@ -6556,6 +6735,153 @@ export { XYWH }
|
|
|
6556
6735
|
|
|
6557
6736
|
export { ZoomAutoFitAxis }
|
|
6558
6737
|
|
|
6738
|
+
/**
|
|
6739
|
+
* Action function for zooming in by one step
|
|
6740
|
+
* @public
|
|
6741
|
+
*/
|
|
6742
|
+
export declare type ZoomInAction = (options?: {
|
|
6743
|
+
/** Custom step size for zoom in (default uses predefined steps) */
|
|
6744
|
+
stepSize?: number;
|
|
6745
|
+
/** Animation configuration - boolean for default animation or object for custom settings */
|
|
6746
|
+
animate?: boolean | {
|
|
6747
|
+
/** Duration of the animation in seconds */
|
|
6748
|
+
duration?: number;
|
|
6749
|
+
/** Easing function for the animation */
|
|
6750
|
+
easing?: 'Linear' | 'EaseIn' | 'EaseOut' | 'EaseInOut';
|
|
6751
|
+
/** Whether the animation can be interrupted */
|
|
6752
|
+
interruptible?: boolean;
|
|
6753
|
+
};
|
|
6754
|
+
/** Maximum allowed zoom level (default: 32) */
|
|
6755
|
+
maxZoom?: number;
|
|
6756
|
+
}) => void | Promise<void>;
|
|
6757
|
+
|
|
6559
6758
|
export { ZoomOptions }
|
|
6560
6759
|
|
|
6760
|
+
/**
|
|
6761
|
+
* Action function for zooming out by one step
|
|
6762
|
+
* @public
|
|
6763
|
+
*/
|
|
6764
|
+
export declare type ZoomOutAction = (options?: {
|
|
6765
|
+
/** Custom step size for zoom out (default uses predefined steps) */
|
|
6766
|
+
stepSize?: number;
|
|
6767
|
+
/** Animation configuration - boolean for default animation or object for custom settings */
|
|
6768
|
+
animate?: boolean | {
|
|
6769
|
+
/** Duration of the animation in seconds */
|
|
6770
|
+
duration?: number;
|
|
6771
|
+
/** Easing function for the animation */
|
|
6772
|
+
easing?: 'Linear' | 'EaseIn' | 'EaseOut' | 'EaseInOut';
|
|
6773
|
+
/** Whether the animation can be interrupted */
|
|
6774
|
+
interruptible?: boolean;
|
|
6775
|
+
};
|
|
6776
|
+
/** Minimum allowed zoom level (default: 0.125) */
|
|
6777
|
+
minZoom?: number;
|
|
6778
|
+
}) => void | Promise<void>;
|
|
6779
|
+
|
|
6780
|
+
/**
|
|
6781
|
+
* Zoom action types for explicit zoom control
|
|
6782
|
+
*/
|
|
6783
|
+
/**
|
|
6784
|
+
* Action function for zooming to a specific block
|
|
6785
|
+
* @public
|
|
6786
|
+
*/
|
|
6787
|
+
export declare type ZoomToBlockAction = (blockId: number, options?: {
|
|
6788
|
+
/** Padding configuration around the block */
|
|
6789
|
+
padding?: number | {
|
|
6790
|
+
x?: number;
|
|
6791
|
+
y?: number;
|
|
6792
|
+
} | {
|
|
6793
|
+
top?: number;
|
|
6794
|
+
bottom?: number;
|
|
6795
|
+
left?: number;
|
|
6796
|
+
right?: number;
|
|
6797
|
+
};
|
|
6798
|
+
/** Animation configuration - boolean for default animation or object for custom settings */
|
|
6799
|
+
animate?: boolean | {
|
|
6800
|
+
/** Duration of the animation in seconds */
|
|
6801
|
+
duration?: number;
|
|
6802
|
+
/** Easing function for the animation */
|
|
6803
|
+
easing?: 'Linear' | 'EaseIn' | 'EaseOut' | 'EaseInOut';
|
|
6804
|
+
/** Whether the animation can be interrupted */
|
|
6805
|
+
interruptible?: boolean;
|
|
6806
|
+
};
|
|
6807
|
+
/** Whether to enable auto-fit mode after zooming (default: false) */
|
|
6808
|
+
autoFit?: boolean;
|
|
6809
|
+
}) => Promise<void>;
|
|
6810
|
+
|
|
6811
|
+
/**
|
|
6812
|
+
* Action function for setting zoom to a specific level
|
|
6813
|
+
* @public
|
|
6814
|
+
*/
|
|
6815
|
+
export declare type ZoomToLevelAction = (level: number, options?: {
|
|
6816
|
+
/** Animation configuration - boolean for default animation or object for custom settings */
|
|
6817
|
+
animate?: boolean | {
|
|
6818
|
+
/** Duration of the animation in seconds */
|
|
6819
|
+
duration?: number;
|
|
6820
|
+
/** Easing function for the animation */
|
|
6821
|
+
easing?: 'Linear' | 'EaseIn' | 'EaseOut' | 'EaseInOut';
|
|
6822
|
+
/** Whether the animation can be interrupted */
|
|
6823
|
+
interruptible?: boolean;
|
|
6824
|
+
};
|
|
6825
|
+
/** Minimum allowed zoom level (default: 0.125) */
|
|
6826
|
+
minZoom?: number;
|
|
6827
|
+
/** Maximum allowed zoom level (default: 32) */
|
|
6828
|
+
maxZoom?: number;
|
|
6829
|
+
}) => void | Promise<void>;
|
|
6830
|
+
|
|
6831
|
+
/**
|
|
6832
|
+
* Action function for zooming to the current page with optional padding
|
|
6833
|
+
* @public
|
|
6834
|
+
*/
|
|
6835
|
+
export declare type ZoomToPageAction = (options?: {
|
|
6836
|
+
/** Padding configuration around the block */
|
|
6837
|
+
padding?: number | {
|
|
6838
|
+
x?: number;
|
|
6839
|
+
y?: number;
|
|
6840
|
+
} | {
|
|
6841
|
+
top?: number;
|
|
6842
|
+
bottom?: number;
|
|
6843
|
+
left?: number;
|
|
6844
|
+
right?: number;
|
|
6845
|
+
};
|
|
6846
|
+
/** Animation configuration - boolean for default animation or object for custom settings */
|
|
6847
|
+
animate?: boolean | {
|
|
6848
|
+
/** Duration of the animation in seconds */
|
|
6849
|
+
duration?: number;
|
|
6850
|
+
/** Easing function for the animation */
|
|
6851
|
+
easing?: 'Linear' | 'EaseIn' | 'EaseOut' | 'EaseInOut';
|
|
6852
|
+
/** Whether the animation can be interrupted */
|
|
6853
|
+
interruptible?: boolean;
|
|
6854
|
+
};
|
|
6855
|
+
/** Whether to enable auto-fit mode after zooming (default: false) */
|
|
6856
|
+
autoFit?: boolean;
|
|
6857
|
+
}) => Promise<void>;
|
|
6858
|
+
|
|
6859
|
+
/**
|
|
6860
|
+
* Action function for zooming to the current selection
|
|
6861
|
+
* @public
|
|
6862
|
+
*/
|
|
6863
|
+
export declare type ZoomToSelectionAction = (options?: {
|
|
6864
|
+
/** Padding configuration around the block */
|
|
6865
|
+
padding?: number | {
|
|
6866
|
+
x?: number;
|
|
6867
|
+
y?: number;
|
|
6868
|
+
} | {
|
|
6869
|
+
top?: number;
|
|
6870
|
+
bottom?: number;
|
|
6871
|
+
left?: number;
|
|
6872
|
+
right?: number;
|
|
6873
|
+
};
|
|
6874
|
+
/** Animation configuration - boolean for default animation or object for custom settings */
|
|
6875
|
+
animate?: boolean | {
|
|
6876
|
+
/** Duration of the animation in seconds */
|
|
6877
|
+
duration?: number;
|
|
6878
|
+
/** Easing function for the animation */
|
|
6879
|
+
easing?: 'Linear' | 'EaseIn' | 'EaseOut' | 'EaseInOut';
|
|
6880
|
+
/** Whether the animation can be interrupted */
|
|
6881
|
+
interruptible?: boolean;
|
|
6882
|
+
};
|
|
6883
|
+
/** Whether to enable auto-fit mode after zooming (default: false) */
|
|
6884
|
+
autoFit?: boolean;
|
|
6885
|
+
}) => Promise<void>;
|
|
6886
|
+
|
|
6561
6887
|
export { }
|