flexdesk 0.14.0 → 0.15.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +0 -0
- package/README.md +54 -3
- package/THIRD_PARTY_LICENSES.md +0 -0
- package/css/base.css +0 -0
- package/css/flexdesk.css +34 -0
- package/css/overrides.css +0 -0
- package/css/reset.css +0 -0
- package/css/tokens.css +0 -0
- package/dist/canvas.js +0 -0
- package/dist/canvas.js.map +0 -0
- package/dist/charts.js +2 -2
- package/dist/charts.js.map +0 -0
- package/dist/chunk-3PHCPZHT.js +0 -0
- package/dist/chunk-3PHCPZHT.js.map +0 -0
- package/dist/chunk-6JSOVNID.js +0 -0
- package/dist/chunk-6JSOVNID.js.map +0 -0
- package/dist/chunk-CWPMLX67.js +0 -0
- package/dist/chunk-CWPMLX67.js.map +0 -0
- package/dist/{chunk-M2L4XW2U.js → chunk-FBGP5KN5.js} +33 -21
- package/dist/chunk-FBGP5KN5.js.map +7 -0
- package/dist/chunk-FL5KFNQH.js +0 -0
- package/dist/chunk-FL5KFNQH.js.map +0 -0
- package/dist/chunk-FOOS3T5L.js +0 -0
- package/dist/chunk-FOOS3T5L.js.map +0 -0
- package/dist/chunk-JYWURG5T.js +0 -0
- package/dist/chunk-JYWURG5T.js.map +0 -0
- package/dist/chunk-NLTOY57M.js +0 -0
- package/dist/chunk-NLTOY57M.js.map +0 -0
- package/dist/chunk-NNFTETK3.js +0 -0
- package/dist/chunk-NNFTETK3.js.map +0 -0
- package/dist/chunk-O5OHMWBB.js +0 -0
- package/dist/chunk-O5OHMWBB.js.map +0 -0
- package/dist/{chunk-IYMNDPWH.js → chunk-RQM5Z2MU.js} +2 -2
- package/dist/{chunk-IYMNDPWH.js.map → chunk-RQM5Z2MU.js.map} +0 -0
- package/dist/chunk-SN4LSOAR.js +0 -0
- package/dist/chunk-SN4LSOAR.js.map +0 -0
- package/dist/chunk-WVFGV5FT.js +0 -0
- package/dist/chunk-WVFGV5FT.js.map +0 -0
- package/dist/core.js +0 -0
- package/dist/core.js.map +0 -0
- package/dist/editor.js +0 -0
- package/dist/editor.js.map +0 -0
- package/dist/flexdesk.css +34 -0
- package/dist/flow.js +1 -1
- package/dist/flow.js.map +0 -0
- package/dist/host.js +28 -5
- package/dist/host.js.map +2 -2
- package/dist/reset.css +0 -0
- package/dist/tile_registry-6WZPTUZV.js +0 -0
- package/dist/tile_registry-6WZPTUZV.js.map +0 -0
- package/dist/tiles.js +11 -3
- package/dist/tiles.js.map +2 -2
- package/dist/tokens.css +0 -0
- package/dist/widgets.js +101 -10
- package/dist/widgets.js.map +2 -2
- package/dist/wm.js +0 -0
- package/dist/wm.js.map +0 -0
- package/package.json +1 -1
- package/src/canvas/canvas_adapter.js +0 -0
- package/src/canvas/edge_router.js +0 -0
- package/src/canvas/graph/connector_router.js +0 -0
- package/src/canvas/graph/history_service.js +0 -0
- package/src/canvas/graph/node_platform.js +0 -0
- package/src/canvas/index.js +0 -0
- package/src/charts/chart_types.js +0 -0
- package/src/charts/data_series_plot_window.js +0 -0
- package/src/charts/downsample.js +0 -0
- package/src/charts/plot_config.js +0 -0
- package/src/charts/plot_popout_window.js +0 -0
- package/src/charts/plotly_wrapper.js +0 -0
- package/src/core/event_bus.js +0 -0
- package/src/core/logging.js +0 -0
- package/src/core/settings.js +0 -0
- package/src/core/state_guard.js +0 -0
- package/src/core/state_guard_config.js +0 -0
- package/src/core/state_machine.js +0 -0
- package/src/editor/editor_pane.js +0 -0
- package/src/editor/monaco_editor_factory.js +0 -0
- package/src/editor/monaco_loader.js +0 -0
- package/src/editor/notebook_search.js +0 -0
- package/src/editor/notebook_tab_bar.js +0 -0
- package/src/editor/notebook_undo_manager.js +0 -0
- package/src/editor/split_pane_container.js +0 -0
- package/src/flow/canvas_editor/editor.js +0 -0
- package/src/flow/canvas_editor/index.js +0 -0
- package/src/flow/canvas_editor/layout.js +0 -0
- package/src/flow/canvas_editor/strings.js +0 -0
- package/src/flow/kit/always_before.js +0 -0
- package/src/flow/kit/catalogue.js +0 -0
- package/src/flow/kit/chip_input.js +0 -0
- package/src/flow/kit/dom.js +0 -0
- package/src/flow/kit/findings.js +0 -0
- package/src/flow/kit/history.js +0 -0
- package/src/flow/kit/index.js +0 -0
- package/src/flow/kit/keys.js +0 -0
- package/src/flow/kit/logic_graph.js +0 -0
- package/src/flow/kit/references.js +0 -0
- package/src/flow/kit/settings_panel.js +0 -0
- package/src/flow/kit/settings_schema.js +0 -0
- package/src/flow/kit/step_picker.js +0 -0
- package/src/flow/kit/strings.js +0 -0
- package/src/flow/kit/value_picker.js +0 -0
- package/src/flow/kit/widgets.js +0 -0
- package/src/flow/lanes/editor.js +0 -0
- package/src/flow/lanes/index.js +0 -0
- package/src/flow/lanes/layout.js +0 -0
- package/src/flow/lanes/pipeline.js +0 -0
- package/src/flow/lanes/preview.js +0 -0
- package/src/flow/lanes/strings.js +0 -0
- package/src/flow/outline/editor.js +0 -0
- package/src/flow/outline/index.js +0 -0
- package/src/flow/outline/mapping.js +0 -0
- package/src/flow/outline/menu.js +0 -0
- package/src/flow/outline/operations.js +0 -0
- package/src/flow/outline/recognise.js +0 -0
- package/src/flow/outline/strings.js +0 -0
- package/src/help/help_modal.js +0 -0
- package/src/help/help_registry.js +0 -0
- package/src/host/host.js +2 -1
- package/src/host/photino_host.js +31 -3
- package/src/host/photino_host.md +56 -3
- package/src/host/pywebview_host.js +0 -0
- package/src/tiles/chart_tiles.js +14 -1
- package/src/tiles/config_schema.js +0 -0
- package/src/tiles/layout_persistence.js +0 -0
- package/src/tiles/tile_base.js +0 -0
- package/src/tiles/tile_grid.js +0 -0
- package/src/tiles/tile_registry.js +0 -0
- package/src/tiling/bottom_panel_tabs.js +0 -0
- package/src/tiling/command_palette.js +0 -0
- package/src/tiling/content_registry.js +0 -0
- package/src/tiling/desktops.js +0 -0
- package/src/tiling/entity_sources.js +0 -0
- package/src/tiling/keymap.js +0 -0
- package/src/tiling/kind_taxonomy.js +0 -0
- package/src/tiling/landing_table.js +0 -0
- package/src/tiling/loading_overlay.js +0 -0
- package/src/tiling/nav_panel.js +0 -0
- package/src/tiling/page_factory.js +0 -0
- package/src/tiling/panel_keys.js +0 -0
- package/src/tiling/shell.js +0 -0
- package/src/tiling/tab_strip.js +0 -0
- package/src/tiling/tile_breadcrumb.js +0 -0
- package/src/tiling/tile_renderer.js +0 -0
- package/src/tiling/tile_tab_menu.js +0 -0
- package/src/tiling/tile_tree.js +0 -0
- package/src/tiling/wm.js +0 -0
- package/src/tiling/zoom.js +0 -0
- package/src/ui/base/component_base.js +0 -0
- package/src/ui/base/controller_base.js +0 -0
- package/src/ui/base/page_base.js +0 -0
- package/src/ui/components/about_dialog.js +0 -0
- package/src/ui/components/action_dropdown.js +0 -0
- package/src/ui/components/alert_log.js +0 -0
- package/src/ui/components/alerts_pane.js +0 -0
- package/src/ui/components/attribute_list_editor.js +0 -0
- package/src/ui/components/autocomplete_field.js +0 -0
- package/src/ui/components/column_fit.js +0 -0
- package/src/ui/components/computing_status_window.js +0 -0
- package/src/ui/components/confirm_dialog.js +0 -0
- package/src/ui/components/context_menu.js +0 -0
- package/src/ui/components/data_table.js +32 -14
- package/src/ui/components/detail_header.js +0 -0
- package/src/ui/components/drag_reorder.js +0 -0
- package/src/ui/components/fact_table.js +0 -0
- package/src/ui/components/gallery_picker.js +0 -0
- package/src/ui/components/inline_renamer.js +0 -0
- package/src/ui/components/managed_window.js +0 -0
- package/src/ui/components/modal.js +0 -0
- package/src/ui/components/notification_history.js +0 -0
- package/src/ui/components/record_list.js +0 -0
- package/src/ui/components/row_activation.js +0 -0
- package/src/ui/components/slide_out_panel.js +0 -0
- package/src/ui/components/slider_field.js +0 -0
- package/src/ui/components/sortable_list.js +0 -0
- package/src/ui/components/table_filter_chips.js +0 -0
- package/src/ui/components/table_state_store.js +0 -0
- package/src/ui/components/table_values.js +0 -0
- package/src/ui/components/toast.js +0 -0
- package/src/ui/components/tree_view.js +0 -0
- package/src/ui/components/window_taskbar.js +0 -0
- package/src/ui/controllers/panel_state_machine.js +0 -0
- package/src/ui/controllers/window_chrome_controller.js +106 -11
- package/src/ui/notification_center.js +0 -0
- package/src/ui/utils/auto_scrollbars.js +0 -0
- package/src/ui/utils/overlay_scrollbar.js +0 -0
- package/src/ui/utils/raf_resize_observer.js +0 -0
- package/src/ui/utils/scroll_lock.js +0 -0
- package/src/ui/utils/tooltip_service.js +0 -0
- package/dist/chunk-M2L4XW2U.js.map +0 -7
package/dist/tokens.css
CHANGED
|
File without changes
|
package/dist/widgets.js
CHANGED
|
@@ -36,7 +36,7 @@ import {
|
|
|
36
36
|
parseDateValue,
|
|
37
37
|
parseDuration,
|
|
38
38
|
resolvePaging
|
|
39
|
-
} from "./chunk-
|
|
39
|
+
} from "./chunk-FBGP5KN5.js";
|
|
40
40
|
import {
|
|
41
41
|
ManagedWindow,
|
|
42
42
|
ROW_CONTROL_SELECTOR,
|
|
@@ -5050,9 +5050,13 @@ var MIN_WIDTH = 500;
|
|
|
5050
5050
|
var MIN_HEIGHT = 350;
|
|
5051
5051
|
var DRAG_THRESHOLD = 4;
|
|
5052
5052
|
var WindowChromeController = class {
|
|
5053
|
-
constructor({ eventBus, logger, host } = {}) {
|
|
5053
|
+
constructor({ eventBus, logger, host, topBar = ".twm-global-top-bar", controls = null, noDrag = "" } = {}) {
|
|
5054
5054
|
this.eventBus = eventBus;
|
|
5055
5055
|
this.logger = logger || console;
|
|
5056
|
+
this._topBarOpt = topBar;
|
|
5057
|
+
this._controlsOpt = controls;
|
|
5058
|
+
this._noDrag = noDrag;
|
|
5059
|
+
this._createdControls = null;
|
|
5056
5060
|
this.win = host?.window || null;
|
|
5057
5061
|
this.resizingActive = false;
|
|
5058
5062
|
this.lastDblClickTs = 0;
|
|
@@ -5064,12 +5068,21 @@ var WindowChromeController = class {
|
|
|
5064
5068
|
/**
|
|
5065
5069
|
* Initialize the window chrome controller
|
|
5066
5070
|
*/
|
|
5067
|
-
initialize() {
|
|
5068
|
-
if (this._disposed) return;
|
|
5069
|
-
|
|
5071
|
+
async initialize() {
|
|
5072
|
+
if (this._disposed) return false;
|
|
5073
|
+
let chrome = "native";
|
|
5074
|
+
try {
|
|
5075
|
+
chrome = this.win ? await this.win.chrome() : "native";
|
|
5076
|
+
} catch (_) {
|
|
5077
|
+
chrome = "native";
|
|
5078
|
+
}
|
|
5079
|
+
if (this._disposed) return false;
|
|
5080
|
+
if (chrome !== "custom") {
|
|
5070
5081
|
this.logger.info?.("[WindowChrome] Native/browser chrome detected \u2014 custom window chrome disabled");
|
|
5071
|
-
return;
|
|
5082
|
+
return false;
|
|
5072
5083
|
}
|
|
5084
|
+
document.body.classList.add("twm-custom-chrome");
|
|
5085
|
+
this.#createWindowControls();
|
|
5073
5086
|
this.#wireWindowButtons();
|
|
5074
5087
|
this.#createResizeHandles();
|
|
5075
5088
|
this.#wireTopBarDrag();
|
|
@@ -5077,6 +5090,43 @@ var WindowChromeController = class {
|
|
|
5077
5090
|
this.#wireNativeStateSync();
|
|
5078
5091
|
this.#initializeState();
|
|
5079
5092
|
this.logger.info?.("[WindowChrome] Initialized");
|
|
5093
|
+
return true;
|
|
5094
|
+
}
|
|
5095
|
+
/** An element from a selector or an element; null when there is none. */
|
|
5096
|
+
#resolve(target, within = document) {
|
|
5097
|
+
if (!target) return null;
|
|
5098
|
+
if (typeof target !== "string") return target;
|
|
5099
|
+
return within.querySelector(target);
|
|
5100
|
+
}
|
|
5101
|
+
/**
|
|
5102
|
+
* Draw minimise, maximise/restore and close, unless the page has its own
|
|
5103
|
+
* `#win-*` buttons (EcoSim's markup), which are then wired instead.
|
|
5104
|
+
*/
|
|
5105
|
+
#createWindowControls() {
|
|
5106
|
+
if (document.getElementById("win-minimize") || document.getElementById("win-close")) return;
|
|
5107
|
+
const bar = this.#resolve(this._topBarOpt);
|
|
5108
|
+
const host = this.#resolve(this._controlsOpt) || bar?.querySelector(".twm-bar-right") || bar;
|
|
5109
|
+
if (!host) return;
|
|
5110
|
+
const box = document.createElement("div");
|
|
5111
|
+
box.className = "twm-window-controls";
|
|
5112
|
+
const button = (id, icon, label, extra = "") => {
|
|
5113
|
+
const b = document.createElement("button");
|
|
5114
|
+
b.type = "button";
|
|
5115
|
+
b.id = id;
|
|
5116
|
+
b.className = `twm-window-controls__btn${extra}`;
|
|
5117
|
+
b.setAttribute("aria-label", label);
|
|
5118
|
+
b.title = label;
|
|
5119
|
+
const i = document.createElement("span");
|
|
5120
|
+
i.className = "material-symbols-outlined";
|
|
5121
|
+
i.textContent = icon;
|
|
5122
|
+
b.appendChild(i);
|
|
5123
|
+
box.appendChild(b);
|
|
5124
|
+
};
|
|
5125
|
+
button("win-minimize", "remove", "Minimize");
|
|
5126
|
+
button("win-maximize", "check_box_outline_blank", "Maximize");
|
|
5127
|
+
button("win-close", "close", "Close", " twm-window-controls__btn--close");
|
|
5128
|
+
host.appendChild(box);
|
|
5129
|
+
this._createdControls = box;
|
|
5080
5130
|
}
|
|
5081
5131
|
/**
|
|
5082
5132
|
* Wire minimize, maximize, close buttons
|
|
@@ -5122,6 +5172,7 @@ var WindowChromeController = class {
|
|
|
5122
5172
|
const tooltipText = isMax ? "Restore" : "Maximize";
|
|
5123
5173
|
window.LatexTooltip?.set(maxBtn, tooltipText);
|
|
5124
5174
|
maxBtn.setAttribute("aria-label", tooltipText);
|
|
5175
|
+
maxBtn.title = tooltipText;
|
|
5125
5176
|
document.body.classList.toggle("twm-window-maximized", isMax);
|
|
5126
5177
|
}
|
|
5127
5178
|
/**
|
|
@@ -5188,8 +5239,30 @@ var WindowChromeController = class {
|
|
|
5188
5239
|
}
|
|
5189
5240
|
};
|
|
5190
5241
|
let activePointerId = null;
|
|
5242
|
+
const EDGE = {
|
|
5243
|
+
right: "e",
|
|
5244
|
+
left: "w",
|
|
5245
|
+
top: "n",
|
|
5246
|
+
bottom: "s",
|
|
5247
|
+
cornerBR: "se",
|
|
5248
|
+
cornerBL: "sw",
|
|
5249
|
+
cornerTR: "ne",
|
|
5250
|
+
cornerTL: "nw"
|
|
5251
|
+
};
|
|
5191
5252
|
const startDrag = async (e) => {
|
|
5253
|
+
if (e.button != null && e.button !== 0) return;
|
|
5192
5254
|
e.preventDefault();
|
|
5255
|
+
if (this.win.startNativeResize) {
|
|
5256
|
+
this.resizingActive = true;
|
|
5257
|
+
let handled = false;
|
|
5258
|
+
try {
|
|
5259
|
+
handled = await this.win.startNativeResize(EDGE[mode]);
|
|
5260
|
+
} catch (_) {
|
|
5261
|
+
handled = false;
|
|
5262
|
+
}
|
|
5263
|
+
this.resizingActive = false;
|
|
5264
|
+
if (handled) return;
|
|
5265
|
+
}
|
|
5193
5266
|
this.resizingActive = true;
|
|
5194
5267
|
startX = e.clientX;
|
|
5195
5268
|
startY = e.clientY;
|
|
@@ -5300,9 +5373,25 @@ var WindowChromeController = class {
|
|
|
5300
5373
|
* Setup top bar dragging for window movement
|
|
5301
5374
|
*/
|
|
5302
5375
|
#wireTopBarDrag() {
|
|
5303
|
-
this.topBar =
|
|
5376
|
+
this.topBar = this.#resolve(this._topBarOpt);
|
|
5304
5377
|
if (!this.topBar) return;
|
|
5305
|
-
const NO_DRAG_SELECTOR =
|
|
5378
|
+
const NO_DRAG_SELECTOR = [
|
|
5379
|
+
".no-drag",
|
|
5380
|
+
"button",
|
|
5381
|
+
"a",
|
|
5382
|
+
"input",
|
|
5383
|
+
"select",
|
|
5384
|
+
"textarea",
|
|
5385
|
+
"label",
|
|
5386
|
+
'[role="button"]',
|
|
5387
|
+
'[role="menuitem"]',
|
|
5388
|
+
'[role="tab"]',
|
|
5389
|
+
'[contenteditable="true"]',
|
|
5390
|
+
".twm-window-controls",
|
|
5391
|
+
".window-controls",
|
|
5392
|
+
".panel-toggles",
|
|
5393
|
+
this._noDrag
|
|
5394
|
+
].filter(Boolean).join(", ");
|
|
5306
5395
|
let dragging = false;
|
|
5307
5396
|
let startSX = 0, startSY = 0, startX = null, startY = null, winW = 0, winH = 0;
|
|
5308
5397
|
let wasMax = false;
|
|
@@ -5479,8 +5568,7 @@ var WindowChromeController = class {
|
|
|
5479
5568
|
this.topBar.addEventListener("mousedown", blocker, true);
|
|
5480
5569
|
this.topBar.addEventListener("pointerdown", blocker, true);
|
|
5481
5570
|
const dblClickHandler = async (e) => {
|
|
5482
|
-
|
|
5483
|
-
if (e.target.closest(interactiveSelector)) {
|
|
5571
|
+
if (isInteractiveTarget(e.target)) {
|
|
5484
5572
|
return;
|
|
5485
5573
|
}
|
|
5486
5574
|
this.lastDblClickTs = Date.now();
|
|
@@ -5586,6 +5674,9 @@ var WindowChromeController = class {
|
|
|
5586
5674
|
}
|
|
5587
5675
|
});
|
|
5588
5676
|
this.handles = {};
|
|
5677
|
+
this._createdControls?.remove();
|
|
5678
|
+
this._createdControls = null;
|
|
5679
|
+
document.body.classList.remove("twm-custom-chrome", "twm-window-maximized", "window-fullscreen");
|
|
5589
5680
|
this.logger.info?.("[WindowChrome] Disposed");
|
|
5590
5681
|
}
|
|
5591
5682
|
};
|