@perspective-dev/viewer 5.4.0 → 5.5.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cdn/perspective-viewer.js +4 -4
- package/dist/cdn/perspective-viewer.js.map +2 -2
- package/dist/css/blueprint.css +1 -1
- package/dist/css/botanical.css +1 -1
- package/dist/css/dracula.css +1 -1
- package/dist/css/eggplant.css +1 -1
- package/dist/css/gruvbox-dark.css +1 -1
- package/dist/css/gruvbox.css +1 -1
- package/dist/css/icons.css +1 -1
- package/dist/css/intl/ar.css +1 -1
- package/dist/css/intl/de.css +1 -1
- package/dist/css/intl/es.css +1 -1
- package/dist/css/intl/fr.css +1 -1
- package/dist/css/intl/ja.css +1 -1
- package/dist/css/intl/pt.css +1 -1
- package/dist/css/intl/zh.css +1 -1
- package/dist/css/intl.css +1 -1
- package/dist/css/ledger.css +1 -1
- package/dist/css/monokai.css +1 -1
- package/dist/css/nord.css +1 -1
- package/dist/css/phosphor.css +1 -1
- package/dist/css/pro-dark.css +1 -1
- package/dist/css/pro.css +1 -1
- package/dist/css/solarized-dark.css +1 -1
- package/dist/css/solarized.css +1 -1
- package/dist/css/themes.css +1 -1
- package/dist/css/vaporwave.css +1 -1
- package/dist/css/velvet.css +1 -1
- package/dist/docs/perspective-docs.json +1 -1
- package/dist/esm/perspective-viewer.d.ts +2 -0
- package/dist/esm/perspective-viewer.inline.js +9 -9
- package/dist/esm/perspective-viewer.inline.js.map +3 -3
- package/dist/esm/perspective-viewer.js +4 -4
- package/dist/esm/perspective-viewer.js.map +2 -2
- package/dist/esm/plugin.d.ts +9 -0
- package/dist/esm/ts-rs/AddPanelOptions.d.ts +9 -0
- package/dist/esm/ts-rs/ExportMethod.d.ts +1 -1
- package/dist/esm/ts-rs/GetViewMode.d.ts +4 -0
- package/dist/esm/ts-rs/GetViewOptions.d.ts +8 -0
- package/dist/esm/ts-rs/RestoreOptions.d.ts +6 -0
- package/dist/esm/ts-rs/RestoreWorkspaceOptions.d.ts +9 -0
- package/dist/esm/ts-rs/WorkspaceConfigUpdate.d.ts +30 -22
- package/dist/wasm/perspective-viewer.d.ts +102 -47
- package/dist/wasm/perspective-viewer.js +233 -142
- package/dist/wasm/perspective-viewer.wasm +0 -0
- package/dist/wasm/perspective-viewer.wasm.d.ts +18 -18
- package/package.json +7 -7
- package/src/css/column-selector.css +11 -3
- package/src/css/column-style.css +162 -0
- package/src/css/config-selector.css +1 -1
- package/src/css/form/debug.css +9 -0
- package/src/css/status-bar.css +11 -0
- package/src/css/ui/containers/tabs.css +2 -1
- package/src/rust/agent/tools.rs +80 -7
- package/src/rust/components/column_selector/active_column.rs +9 -0
- package/src/rust/components/column_selector.rs +11 -0
- package/src/rust/components/column_settings_sidebar/style_tab/alignment_field.rs +90 -0
- package/src/rust/components/column_settings_sidebar/style_tab/font_field.rs +267 -0
- package/src/rust/components/column_settings_sidebar/style_tab/primitive_field.rs +1 -1
- package/src/rust/components/column_settings_sidebar/style_tab.rs +68 -9
- package/src/rust/components/debug_panel.rs +107 -50
- package/src/rust/components/export_dropdown.rs +6 -0
- package/src/rust/components/main_panel/msg.rs +4 -0
- package/src/rust/components/main_panel.rs +14 -0
- package/src/rust/components/mod.rs +0 -1
- package/src/rust/components/plugin_tab.rs +57 -3
- package/src/rust/components/settings_panel.rs +6 -0
- package/src/rust/components/status_bar.rs +12 -3
- package/src/rust/components/status_indicator.rs +4 -0
- package/src/rust/components/viewer/filters.rs +2 -2
- package/src/rust/components/viewer/msg.rs +4 -0
- package/src/rust/components/viewer/panels.rs +6 -3
- package/src/rust/components/viewer/render.rs +1 -0
- package/src/rust/components/viewer/wiring.rs +14 -2
- package/src/rust/components/viewer.rs +2 -2
- package/src/rust/config/column_config_schema.rs +312 -8
- package/src/rust/config/datetime_column_style.rs +0 -11
- package/src/rust/config/export_method.rs +24 -0
- package/src/rust/config/mod.rs +0 -2
- package/src/rust/config/options.rs +50 -0
- package/src/rust/config/workspace_config.rs +69 -24
- package/src/rust/custom_elements/viewer.rs +214 -113
- package/src/rust/js/plugin.rs +3 -1
- package/src/rust/lib.rs +7 -3
- package/src/rust/queries/plugin_column_styles.rs +6 -5
- package/src/rust/renderer/plugin_config.rs +200 -41
- package/src/rust/renderer/plugin_store.rs +2 -1
- package/src/rust/renderer/props.rs +5 -0
- package/src/rust/renderer.rs +9 -0
- package/src/rust/session/metadata.rs +5 -10
- package/src/rust/session/props.rs +4 -0
- package/src/rust/session.rs +273 -195
- package/src/rust/tasks/copy_export.rs +67 -0
- package/src/rust/tasks/create_panel.rs +16 -13
- package/src/rust/tasks/pipeline.rs +26 -8
- package/src/rust/tasks/restore_panel.rs +129 -30
- package/src/rust/tasks/send_column_config.rs +3 -0
- package/src/rust/tasks/sync_update_panels.rs +148 -68
- package/src/rust/tasks/table_lifecycle.rs +7 -1
- package/src/rust/ui/containers/tab_list.rs +1 -1
- package/src/rust/ui/form/intl_label.rs +4 -23
- package/src/rust/ui/portal.rs +1 -0
- package/src/rust/utils/css_vars.rs +13 -0
- package/src/rust/{config/datetime_column_style/color_mode.rs → utils/in_flight.rs} +47 -35
- package/src/rust/utils/local_fonts.rs +395 -0
- package/src/rust/utils/mod.rs +4 -0
- package/src/rust/utils/pending_effects.rs +6 -30
- package/src/rust/workspace.rs +12 -0
- package/src/svg/status_pending.svg +3 -0
- package/src/themes/icons.css +1 -0
- package/src/themes/intl/ar.css +20 -7
- package/src/themes/intl/de.css +20 -7
- package/src/themes/intl/es.css +20 -7
- package/src/themes/intl/fr.css +20 -7
- package/src/themes/intl/ja.css +20 -7
- package/src/themes/intl/pt.css +20 -7
- package/src/themes/intl/zh.css +20 -7
- package/src/themes/intl.css +20 -7
- package/src/themes/monokai.css +1 -1
- package/src/themes/vaporwave.css +1 -1
- package/src/ts/perspective-viewer.ts +2 -0
- package/src/ts/plugin.ts +9 -0
- package/src/ts/ts-rs/AddPanelOptions.ts +10 -0
- package/src/ts/ts-rs/ExportMethod.ts +1 -1
- package/src/ts/ts-rs/{DatetimeColorMode.ts → GetViewMode.ts} +4 -1
- package/src/ts/ts-rs/GetViewOptions.ts +7 -0
- package/src/ts/ts-rs/RestoreOptions.ts +7 -1
- package/src/ts/ts-rs/RestoreWorkspaceOptions.ts +10 -0
- package/src/ts/ts-rs/WorkspaceConfigUpdate.ts +31 -20
- package/dist/esm/ts-rs/DatetimeColorMode.d.ts +0 -1
- package/dist/esm/ts-rs/FormatMode.d.ts +0 -1
- package/dist/esm/ts-rs/StringColorMode.d.ts +0 -1
- package/src/rust/components/string_column_style.rs +0 -120
- package/src/rust/config/string_column_style.rs +0 -135
- package/src/ts/ts-rs/FormatMode.ts +0 -3
- package/src/ts/ts-rs/StringColorMode.ts +0 -3
- /package/dist/wasm/snippets/{perspective-viewer-adc6f3f79141112b → perspective-viewer-6813b568219c6763}/inline0.js +0 -0
- /package/dist/wasm/snippets/{perspective-viewer-adc6f3f79141112b → perspective-viewer-6813b568219c6763}/inline1.js +0 -0
- /package/dist/wasm/snippets/{perspective-viewer-adc6f3f79141112b → perspective-viewer-6813b568219c6763}/inline2.js +0 -0
- /package/dist/wasm/snippets/{perspective-viewer-adc6f3f79141112b → perspective-viewer-6813b568219c6763}/inline3.js +0 -0
- /package/dist/wasm/snippets/{perspective-viewer-adc6f3f79141112b → perspective-viewer-6813b568219c6763}/inline4.js +0 -0
- /package/dist/wasm/snippets/{perspective-viewer-adc6f3f79141112b → perspective-viewer-6813b568219c6763}/inline5.js +0 -0
package/dist/esm/plugin.d.ts
CHANGED
|
@@ -88,6 +88,15 @@ export interface IPerspectiveViewerPlugin {
|
|
|
88
88
|
kind: string;
|
|
89
89
|
}>;
|
|
90
90
|
};
|
|
91
|
+
/**
|
|
92
|
+
* The plugin-level settings schema as it applies to `current_value`, the
|
|
93
|
+
* `plugin_config` state the schema should describe.
|
|
94
|
+
*/
|
|
95
|
+
plugin_config_schema?(view_config?: Record<string, unknown>, current_value?: Record<string, unknown> | null): {
|
|
96
|
+
fields: Array<Record<string, unknown> & {
|
|
97
|
+
kind: string;
|
|
98
|
+
}>;
|
|
99
|
+
};
|
|
91
100
|
/**
|
|
92
101
|
* Render this plugin using the provided `View`. While there is no
|
|
93
102
|
* provision to cancel a render in progress per se, calling a method on
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export type ExportMethod = "csv" | "csv-all" | "csv-selected" | "json" | "json-all" | "json-selected" | "ndjson" | "ndjson-all" | "ndjson-selected" | "html" | "plugin" | "arrow" | "arrow-selected" | "arrow-all" | "json-config";
|
|
1
|
+
export type ExportMethod = "csv" | "csv-all" | "csv-selected" | "json" | "json-all" | "json-selected" | "ndjson" | "ndjson-all" | "ndjson-selected" | "html" | "plugin" | "arrow" | "arrow-selected" | "arrow-all" | "arrow-lz4" | "arrow-lz4-selected" | "arrow-lz4-all" | "arrow-zstd" | "arrow-zstd-selected" | "arrow-zstd-all" | "json-config";
|
|
@@ -16,4 +16,10 @@ export type RestoreOptions = {
|
|
|
16
16
|
* known-good config to recover exactly.
|
|
17
17
|
*/
|
|
18
18
|
suppress_errors?: boolean;
|
|
19
|
+
/**
|
|
20
|
+
* When `true`, a `table` no loaded client hosts yet leaves the panel
|
|
21
|
+
* empty and pending until the table is created, instead of the default
|
|
22
|
+
* error.
|
|
23
|
+
*/
|
|
24
|
+
wait_for_table?: boolean;
|
|
19
25
|
};
|
|
@@ -1,39 +1,47 @@
|
|
|
1
1
|
import type { Filter } from "./Filter.js";
|
|
2
2
|
import type { Layout } from "./Layout.js";
|
|
3
|
+
import type { OptionalUpdate } from "./OptionalUpdate.js";
|
|
3
4
|
import type { ViewerConfigInitial } from "./ViewerConfigInitial.js";
|
|
4
5
|
/**
|
|
5
|
-
* The
|
|
6
|
-
* [`
|
|
7
|
-
*
|
|
8
|
-
*
|
|
9
|
-
* stray per-panel `settings` key is ignored; it is element-level state,
|
|
10
|
-
* carried by the top-level `active` field).
|
|
6
|
+
* The [`PerspectiveViewerElement::restoreWorkspace`] argument: a field-wise
|
|
7
|
+
* update of the element's workspace state, like [`ViewerConfigUpdate`] for a
|
|
8
|
+
* panel, where an absent key is unchanged, `null` resets and a value
|
|
9
|
+
* replaces.
|
|
11
10
|
*/
|
|
12
11
|
export type WorkspaceConfigUpdate = {
|
|
13
|
-
|
|
12
|
+
/**
|
|
13
|
+
* The panel to activate with the settings sidebar open, by `panels` key
|
|
14
|
+
* or existing panel id; `null` closes the sidebar.
|
|
15
|
+
*/
|
|
16
|
+
active?: OptionalUpdate<string>;
|
|
17
|
+
/**
|
|
18
|
+
* The layout tree to stage, naming `panels` keys or existing panel ids.
|
|
19
|
+
*/
|
|
14
20
|
layout?: Layout;
|
|
15
|
-
|
|
21
|
+
/**
|
|
22
|
+
* The complete replacement panel set, each [`ViewerConfigInitial`] entry
|
|
23
|
+
* creating a new panel (`{}` empties the element); absent keeps the
|
|
24
|
+
* existing panels.
|
|
25
|
+
*/
|
|
26
|
+
panels?: {
|
|
16
27
|
[key in string]?: ViewerConfigInitial;
|
|
17
28
|
};
|
|
18
29
|
/**
|
|
19
|
-
* The element-level
|
|
20
|
-
*
|
|
21
|
-
* unattributed bucket: the next selection on any master replaces it.
|
|
22
|
-
* `Option` so an explicit `undefined` property deserializes as
|
|
23
|
-
* `None` like an absent key (also `masters` / `palette` below).
|
|
30
|
+
* The element-level cross-filter set applied to every detail panel as
|
|
31
|
+
* one unattributed bucket, replacing the current set; `null` clears it.
|
|
24
32
|
*/
|
|
25
|
-
global_filters?: Array<Filter
|
|
33
|
+
global_filters?: OptionalUpdate<Array<Filter>>;
|
|
26
34
|
/**
|
|
27
|
-
* The master (filter-source) panels
|
|
28
|
-
* `
|
|
35
|
+
* The master (filter-source) panels by `panels` key or existing panel
|
|
36
|
+
* id, unknown ids dropped with a warning; `null` demotes every panel.
|
|
29
37
|
*/
|
|
30
|
-
masters?: Array<string
|
|
38
|
+
masters?: OptionalUpdate<Array<string>>;
|
|
31
39
|
/**
|
|
32
|
-
* Named color-scale definitions
|
|
33
|
-
* [`WorkspaceConfig::palette`]), replacing
|
|
34
|
-
*
|
|
40
|
+
* Named color-scale definitions applied to the host (see
|
|
41
|
+
* [`WorkspaceConfig::palette`]), replacing the previous palette; `null`
|
|
42
|
+
* clears it.
|
|
35
43
|
*/
|
|
36
|
-
palette?: {
|
|
44
|
+
palette?: OptionalUpdate<{
|
|
37
45
|
[key in string]?: string;
|
|
38
|
-
}
|
|
46
|
+
}>;
|
|
39
47
|
};
|
|
@@ -113,25 +113,29 @@ export type * from "../../src/ts/ts-rs/WorkspaceConfigUpdate.d.ts";
|
|
|
113
113
|
export type * from "../../src/ts/ts-rs/ExportMethod.d.ts";
|
|
114
114
|
export type * from "../../src/ts/ts-rs/PanelOptions.d.ts";
|
|
115
115
|
export type * from "../../src/ts/ts-rs/RestoreOptions.d.ts";
|
|
116
|
+
export type * from "../../src/ts/ts-rs/RestoreWorkspaceOptions.d.ts";
|
|
117
|
+
export type * from "../../src/ts/ts-rs/AddPanelOptions.d.ts";
|
|
116
118
|
export type * from "../../src/ts/ts-rs/SaveWorkspaceOptions.d.ts";
|
|
117
119
|
export type * from "../../src/ts/ts-rs/ClientOptions.d.ts";
|
|
118
120
|
export type * from "../../src/ts/ts-rs/ExportOptions.d.ts";
|
|
119
121
|
export type * from "../../src/ts/ts-rs/GetTableOptions.d.ts";
|
|
120
122
|
export type * from "../../src/ts/ts-rs/GetClientOptions.d.ts";
|
|
123
|
+
export type * from "../../src/ts/ts-rs/GetViewOptions.d.ts";
|
|
124
|
+
export type * from "../../src/ts/ts-rs/GetViewMode.d.ts";
|
|
121
125
|
export type * from "../../src/ts/ts-rs/CustomNumberFormatConfig.d.ts";
|
|
122
126
|
export type * from "../../src/ts/ts-rs/NumberFormatStyle.d.ts";
|
|
123
127
|
export type * from "../../src/ts/ts-rs/Notation.d.ts";
|
|
124
128
|
export type * from "../../src/ts/ts-rs/DatetimeFormatType.d.ts";
|
|
125
|
-
export type * from "../../src/ts/ts-rs/StringColorMode.d.ts";
|
|
126
|
-
export type * from "../../src/ts/ts-rs/DatetimeColorMode.d.ts";
|
|
127
|
-
export type * from "../../src/ts/ts-rs/FormatMode.d.ts";
|
|
128
129
|
|
|
129
130
|
import type {GetTableOptions} from "../../src/ts/ts-rs/GetTableOptions.d.ts";
|
|
130
131
|
import type {PanelOptions} from "../../src/ts/ts-rs/PanelOptions.d.ts";
|
|
131
132
|
import type {RestoreOptions} from "../../src/ts/ts-rs/RestoreOptions.d.ts";
|
|
133
|
+
import type {RestoreWorkspaceOptions} from "../../src/ts/ts-rs/RestoreWorkspaceOptions.d.ts";
|
|
134
|
+
import type {AddPanelOptions} from "../../src/ts/ts-rs/AddPanelOptions.d.ts";
|
|
132
135
|
import type {SaveWorkspaceOptions} from "../../src/ts/ts-rs/SaveWorkspaceOptions.d.ts";
|
|
133
136
|
import type {ExportOptions} from "../../src/ts/ts-rs/ExportOptions.d.ts";
|
|
134
137
|
import type {GetClientOptions} from "../../src/ts/ts-rs/GetClientOptions.d.ts";
|
|
138
|
+
import type {GetViewOptions} from "../../src/ts/ts-rs/GetViewOptions.d.ts";
|
|
135
139
|
import type {ClientOptions} from "../../src/ts/ts-rs/ClientOptions.d.ts";
|
|
136
140
|
import type {ViewerConfig} from "../../src/ts/ts-rs/ViewerConfig.d.ts";
|
|
137
141
|
import type {ViewerConfigUpdate} from "../../src/ts/ts-rs/ViewerConfigUpdate.d.ts";
|
|
@@ -525,8 +529,15 @@ export class PerspectiveViewerElement {
|
|
|
525
529
|
*
|
|
526
530
|
* The element-level `settings` field does not exist on the argument
|
|
527
531
|
* type (it is shared across the element, not per-panel).
|
|
532
|
+
*
|
|
533
|
+
* # Arguments
|
|
534
|
+
*
|
|
535
|
+
* - `config` - The new panel's initial config, whose `table` is required.
|
|
536
|
+
* - `options.wait_for_table` - when `true`, a `table` no loaded client
|
|
537
|
+
* hosts yet creates the panel empty and pending until the table is
|
|
538
|
+
* created, instead of the default rejection.
|
|
528
539
|
*/
|
|
529
|
-
addPanel(config: ViewerConfigInitial): Promise<any>;
|
|
540
|
+
addPanel(config: ViewerConfigInitial, options?: AddPanelOptions | null): Promise<any>;
|
|
530
541
|
/**
|
|
531
542
|
* Configure the embedded LLM agent (see `prompt()`), replacing any prior
|
|
532
543
|
* configuration and conversation.
|
|
@@ -814,27 +825,46 @@ export class PerspectiveViewerElement {
|
|
|
814
825
|
getTable(options?: GetTableOptions | null): Promise<any>;
|
|
815
826
|
getThemes(): Promise<any>;
|
|
816
827
|
/**
|
|
817
|
-
* Get
|
|
828
|
+
* Get a [`View`] for a panel of this viewer, as currently configured by
|
|
829
|
+
* the user.
|
|
818
830
|
*
|
|
819
|
-
*
|
|
820
|
-
* configured by the user, for e.g. serializing as an
|
|
821
|
-
* [Apache Arrow](https://arrow.apache.org/) before passing to another
|
|
822
|
-
* library.
|
|
831
|
+
* # Arguments
|
|
823
832
|
*
|
|
824
|
-
*
|
|
825
|
-
* [`
|
|
826
|
-
*
|
|
827
|
-
*
|
|
828
|
-
*
|
|
829
|
-
*
|
|
833
|
+
* - `mode` - which [`View`] to return:
|
|
834
|
+
* - `"live"` (default) - the panel's own [`View`], which the viewer
|
|
835
|
+
* replaces on every config change and deletes when auto-paused or
|
|
836
|
+
* [`PerspectiveViewerElement::delete`]d, so calls on it may fail with
|
|
837
|
+
* "View already deleted", it must never be deleted by the caller, and
|
|
838
|
+
* it rejects with `No View for panel "<name>"` while none is bound
|
|
839
|
+
* (auto-paused or not yet rendered).
|
|
840
|
+
* - `"clone"` - a new [`View`] built from the panel's effective config
|
|
841
|
+
* (global filter included), independent of the render lifecycle, which
|
|
842
|
+
* the caller owns and must [`View::delete`].
|
|
843
|
+
* - `"auto"` - `"live"` when the panel has a bound [`View`], else
|
|
844
|
+
* `"clone"`.
|
|
845
|
+
* - `panel` - the target panel, or the active panel when omitted.
|
|
846
|
+
*
|
|
847
|
+
* Plugins which rely on the live [`View`] for their
|
|
848
|
+
* [`HTMLPerspectiveViewerPluginElement::draw`] implementations should
|
|
849
|
+
* treat "View already deleted" as a _cancellation_ by silently aborting.
|
|
830
850
|
*
|
|
831
851
|
* # JavaScript Examples
|
|
832
852
|
*
|
|
833
853
|
* ```javascript
|
|
834
854
|
* const view = await viewer.getView();
|
|
835
855
|
* ```
|
|
856
|
+
*
|
|
857
|
+
* Export every panel without borrowing the viewer's own [`View`]:
|
|
858
|
+
*
|
|
859
|
+
* ```javascript
|
|
860
|
+
* for (const panel of viewer.getPanelNames()) {
|
|
861
|
+
* const view = await viewer.getView({ panel, mode: "clone" });
|
|
862
|
+
* const arrow = await view.to_arrow();
|
|
863
|
+
* await view.delete();
|
|
864
|
+
* }
|
|
865
|
+
* ```
|
|
836
866
|
*/
|
|
837
|
-
getView(options?:
|
|
867
|
+
getView(options?: GetViewOptions | null): Promise<any>;
|
|
838
868
|
/**
|
|
839
869
|
* Get a copy of the [`ViewConfig`] for the current [`View`]. This is
|
|
840
870
|
* non-blocking as it does not need to access the plugin (unlike
|
|
@@ -1035,12 +1065,13 @@ export class PerspectiveViewerElement {
|
|
|
1035
1065
|
* - `options.panel` - The panel to target, or the active panel when
|
|
1036
1066
|
* omitted.
|
|
1037
1067
|
* - `options.suppress_errors` - when `true`, a failed restore only rejects
|
|
1038
|
-
* the returned `Promise
|
|
1039
|
-
* visible error state and
|
|
1040
|
-
*
|
|
1041
|
-
*
|
|
1042
|
-
*
|
|
1043
|
-
*
|
|
1068
|
+
* the returned `Promise` and rolls the view config back, leaving the
|
|
1069
|
+
* viewer's visible error state and any element-level state the call
|
|
1070
|
+
* already applied (theme, title, plugin, a successful `table` change)
|
|
1071
|
+
* untouched.
|
|
1072
|
+
* - `options.wait_for_table` - when `true`, a `table` no loaded client
|
|
1073
|
+
* hosts yet leaves the panel empty and pending until the table is
|
|
1074
|
+
* created, instead of the default error.
|
|
1044
1075
|
*
|
|
1045
1076
|
* # JavaScript Examples
|
|
1046
1077
|
*
|
|
@@ -1060,20 +1091,33 @@ export class PerspectiveViewerElement {
|
|
|
1060
1091
|
*/
|
|
1061
1092
|
restore(update: ViewerConfigUpdate, options?: RestoreOptions | null): Promise<void>;
|
|
1062
1093
|
/**
|
|
1063
|
-
*
|
|
1064
|
-
*
|
|
1065
|
-
*
|
|
1066
|
-
*
|
|
1067
|
-
*
|
|
1068
|
-
*
|
|
1094
|
+
* Apply a [`WorkspaceConfigUpdate`] to the element — the multi-panel
|
|
1095
|
+
* counterpart of [`Self::restore`] and like it a field-wise update, where
|
|
1096
|
+
* an absent field is unchanged, `null` resets and a value replaces.
|
|
1097
|
+
*
|
|
1098
|
+
* # Arguments
|
|
1099
|
+
*
|
|
1100
|
+
* - `update` - The workspace config update: a [`Self::saveWorkspace`]
|
|
1101
|
+
* token replaces every panel (`panels` is the whole set), while a token
|
|
1102
|
+
* without `panels` keeps them and `layout`, `active` and `masters` name
|
|
1103
|
+
* them by their existing ids.
|
|
1104
|
+
* - `options.wait_for_table` - when `true`, a panel whose `table` no
|
|
1105
|
+
* loaded client hosts yet is created empty and pending until the table
|
|
1106
|
+
* is created, instead of the default error.
|
|
1069
1107
|
*
|
|
1070
1108
|
* # JavaScript Examples
|
|
1071
1109
|
*
|
|
1072
1110
|
* ```javascript
|
|
1073
1111
|
* await viewer.restoreWorkspace(await otherViewer.saveWorkspace());
|
|
1074
1112
|
* ```
|
|
1113
|
+
*
|
|
1114
|
+
* Cross-filter the current panels without re-creating them:
|
|
1115
|
+
*
|
|
1116
|
+
* ```javascript
|
|
1117
|
+
* await viewer.restoreWorkspace({ global_filters: [["Region", "==", "West"]] });
|
|
1118
|
+
* ```
|
|
1075
1119
|
*/
|
|
1076
|
-
restoreWorkspace(update: WorkspaceConfigUpdate): Promise<void>;
|
|
1120
|
+
restoreWorkspace(update: WorkspaceConfigUpdate, options?: RestoreWorkspaceOptions | null): Promise<void>;
|
|
1077
1121
|
/**
|
|
1078
1122
|
* Restyle all plugins from current document.
|
|
1079
1123
|
*
|
|
@@ -1647,6 +1691,17 @@ export class View {
|
|
|
1647
1691
|
set_depth(depth: number): Promise<void>;
|
|
1648
1692
|
/**
|
|
1649
1693
|
* Serializes a [`View`] to the Apache Arrow data format.
|
|
1694
|
+
*
|
|
1695
|
+
* # Arguments
|
|
1696
|
+
*
|
|
1697
|
+
* - `window` - a [`ViewWindow`]; its `compression` key selects Arrow IPC
|
|
1698
|
+
* body compression, `"lz4"` or `"zstd"` (uncompressed when omitted).
|
|
1699
|
+
*
|
|
1700
|
+
* # JavaScript Examples
|
|
1701
|
+
*
|
|
1702
|
+
* ```javascript
|
|
1703
|
+
* const arrow = await view.to_arrow({ compression: "zstd" });
|
|
1704
|
+
* ```
|
|
1650
1705
|
*/
|
|
1651
1706
|
to_arrow(window?: ViewWindow | null): Promise<ArrayBuffer>;
|
|
1652
1707
|
/**
|
|
@@ -1755,7 +1810,7 @@ export interface InitOutput {
|
|
|
1755
1810
|
readonly perspectivedebugpluginelement_select_mode: (a: number, b: number) => void;
|
|
1756
1811
|
readonly perspectivedebugpluginelement_update: (a: number, b: number) => number;
|
|
1757
1812
|
readonly perspectiveviewerelement___get_model: (a: number) => number;
|
|
1758
|
-
readonly perspectiveviewerelement_addPanel: (a: number, b: number) => number;
|
|
1813
|
+
readonly perspectiveviewerelement_addPanel: (a: number, b: number, c: number) => number;
|
|
1759
1814
|
readonly perspectiveviewerelement_agentConfig: (a: number, b: number, c: number) => void;
|
|
1760
1815
|
readonly perspectiveviewerelement_agentPrompt: (a: number, b: number, c: number) => number;
|
|
1761
1816
|
readonly perspectiveviewerelement_agentReset: (a: number) => number;
|
|
@@ -1786,7 +1841,7 @@ export interface InitOutput {
|
|
|
1786
1841
|
readonly perspectiveviewerelement_resetThemes: (a: number, b: number, c: number) => number;
|
|
1787
1842
|
readonly perspectiveviewerelement_resize: (a: number, b: number) => number;
|
|
1788
1843
|
readonly perspectiveviewerelement_restore: (a: number, b: number, c: number) => number;
|
|
1789
|
-
readonly perspectiveviewerelement_restoreWorkspace: (a: number, b: number) => number;
|
|
1844
|
+
readonly perspectiveviewerelement_restoreWorkspace: (a: number, b: number, c: number) => number;
|
|
1790
1845
|
readonly perspectiveviewerelement_restyleElement: (a: number) => number;
|
|
1791
1846
|
readonly perspectiveviewerelement_save: (a: number, b: number) => number;
|
|
1792
1847
|
readonly perspectiveviewerelement_saveWorkspace: (a: number, b: number) => number;
|
|
@@ -1895,22 +1950,22 @@ export interface InitOutput {
|
|
|
1895
1950
|
readonly virtualdataslice_setStringCol: (a: number, b: number, c: number, d: number, e: number, f: number, g: number) => void;
|
|
1896
1951
|
readonly virtualserver_handleRequest: (a: number, b: number, c: number) => number;
|
|
1897
1952
|
readonly virtualserver_new: (a: number, b: number) => void;
|
|
1898
|
-
readonly
|
|
1899
|
-
readonly
|
|
1900
|
-
readonly
|
|
1901
|
-
readonly
|
|
1902
|
-
readonly
|
|
1903
|
-
readonly
|
|
1904
|
-
readonly
|
|
1905
|
-
readonly
|
|
1906
|
-
readonly
|
|
1907
|
-
readonly
|
|
1908
|
-
readonly
|
|
1909
|
-
readonly
|
|
1910
|
-
readonly
|
|
1911
|
-
readonly
|
|
1912
|
-
readonly
|
|
1913
|
-
readonly
|
|
1953
|
+
readonly __wasm_bindgen_func_elem_18919: (a: number, b: number) => void;
|
|
1954
|
+
readonly __wasm_bindgen_func_elem_4482: (a: number, b: number) => void;
|
|
1955
|
+
readonly __wasm_bindgen_func_elem_19628: (a: number, b: number) => void;
|
|
1956
|
+
readonly __wasm_bindgen_func_elem_20538: (a: number, b: number) => void;
|
|
1957
|
+
readonly __wasm_bindgen_func_elem_25347: (a: number, b: number) => void;
|
|
1958
|
+
readonly __wasm_bindgen_func_elem_33507: (a: number, b: number, c: number, d: number) => void;
|
|
1959
|
+
readonly __wasm_bindgen_func_elem_19039: (a: number, b: number, c: number) => void;
|
|
1960
|
+
readonly __wasm_bindgen_func_elem_7893: (a: number, b: number, c: number) => void;
|
|
1961
|
+
readonly __wasm_bindgen_func_elem_7894: (a: number, b: number, c: number) => void;
|
|
1962
|
+
readonly __wasm_bindgen_func_elem_7895: (a: number, b: number, c: number) => void;
|
|
1963
|
+
readonly __wasm_bindgen_func_elem_7891: (a: number, b: number, c: number) => void;
|
|
1964
|
+
readonly __wasm_bindgen_func_elem_19633: (a: number, b: number, c: number) => void;
|
|
1965
|
+
readonly __wasm_bindgen_func_elem_25364: (a: number, b: number, c: number) => void;
|
|
1966
|
+
readonly __wasm_bindgen_func_elem_21577: (a: number, b: number) => number;
|
|
1967
|
+
readonly __wasm_bindgen_func_elem_19632: (a: number, b: number) => void;
|
|
1968
|
+
readonly __wasm_bindgen_func_elem_21578: (a: number, b: number) => void;
|
|
1914
1969
|
readonly __wbindgen_export: (a: number, b: number) => number;
|
|
1915
1970
|
readonly __wbindgen_export2: (a: number, b: number, c: number, d: number) => number;
|
|
1916
1971
|
readonly __wbindgen_export3: (a: number) => void;
|