flexdesk 0.4.7 → 0.5.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/package.json CHANGED
@@ -1,81 +1,81 @@
1
- {
2
- "name": "flexdesk",
3
- "version": "0.4.7",
4
- "description": "A tiling window manager and widget set for desktop-class web applications. Zero runtime dependencies.",
5
- "license": "MIT",
6
- "repository": {
7
- "type": "git",
8
- "url": "git+ssh://git@github.com/nor-os/FlexDesk.git"
9
- },
10
- "homepage": "https://github.com/nor-os/FlexDesk",
11
- "bugs": {
12
- "url": "https://github.com/nor-os/FlexDesk/issues"
13
- },
14
- "type": "module",
15
- "sideEffects": [
16
- "*.css"
17
- ],
18
- "files": [
19
- "dist",
20
- "src",
21
- "css",
22
- "README.md",
23
- "LICENSE",
24
- "THIRD_PARTY_LICENSES.md"
25
- ],
26
- "exports": {
27
- "./core": {
28
- "import": "./dist/core.js",
29
- "development": "./core.js"
30
- },
31
- "./host": {
32
- "import": "./dist/host.js",
33
- "development": "./host.js"
34
- },
35
- "./wm": {
36
- "import": "./dist/wm.js",
37
- "development": "./wm.js"
38
- },
39
- "./widgets": {
40
- "import": "./dist/widgets.js",
41
- "development": "./widgets.js"
42
- },
43
- "./css": "./dist/flexdesk.css",
44
- "./css/tokens": "./css/tokens.css",
45
- "./charts": {
46
- "import": "./dist/charts.js",
47
- "development": "./charts.js"
48
- },
49
- "./tiles": {
50
- "import": "./dist/tiles.js",
51
- "development": "./tiles.js"
52
- },
53
- "./editor": {
54
- "import": "./dist/editor.js",
55
- "development": "./editor.js"
56
- }
57
- },
58
- "scripts": {
59
- "build": "node build.mjs",
60
- "check": "node build.mjs --check",
61
- "test": "node tests/run.mjs"
62
- },
63
- "devDependencies": {
64
- "esbuild": "^0.28.1"
65
- },
66
- "peerDependenciesMeta": {
67
- "plotly.js": {
68
- "optional": true
69
- },
70
- "monaco-editor": {
71
- "optional": true
72
- }
73
- },
74
- "keywords": [
75
- "tiling",
76
- "window-manager",
77
- "datatable",
78
- "command-palette",
79
- "ui"
80
- ]
81
- }
1
+ {
2
+ "name": "flexdesk",
3
+ "version": "0.5.0",
4
+ "description": "A tiling window manager and widget set for desktop-class web applications. Zero runtime dependencies.",
5
+ "license": "MIT",
6
+ "repository": {
7
+ "type": "git",
8
+ "url": "git+ssh://git@github.com/nor-os/FlexDesk.git"
9
+ },
10
+ "homepage": "https://github.com/nor-os/FlexDesk",
11
+ "bugs": {
12
+ "url": "https://github.com/nor-os/FlexDesk/issues"
13
+ },
14
+ "type": "module",
15
+ "sideEffects": [
16
+ "*.css"
17
+ ],
18
+ "files": [
19
+ "dist",
20
+ "src",
21
+ "css",
22
+ "README.md",
23
+ "LICENSE",
24
+ "THIRD_PARTY_LICENSES.md"
25
+ ],
26
+ "exports": {
27
+ "./core": {
28
+ "import": "./dist/core.js",
29
+ "development": "./core.js"
30
+ },
31
+ "./host": {
32
+ "import": "./dist/host.js",
33
+ "development": "./host.js"
34
+ },
35
+ "./wm": {
36
+ "import": "./dist/wm.js",
37
+ "development": "./wm.js"
38
+ },
39
+ "./widgets": {
40
+ "import": "./dist/widgets.js",
41
+ "development": "./widgets.js"
42
+ },
43
+ "./css": "./dist/flexdesk.css",
44
+ "./css/tokens": "./css/tokens.css",
45
+ "./charts": {
46
+ "import": "./dist/charts.js",
47
+ "development": "./charts.js"
48
+ },
49
+ "./tiles": {
50
+ "import": "./dist/tiles.js",
51
+ "development": "./tiles.js"
52
+ },
53
+ "./editor": {
54
+ "import": "./dist/editor.js",
55
+ "development": "./editor.js"
56
+ }
57
+ },
58
+ "scripts": {
59
+ "build": "node build.mjs",
60
+ "check": "node build.mjs --check",
61
+ "test": "node tests/run.mjs"
62
+ },
63
+ "devDependencies": {
64
+ "esbuild": "^0.28.1"
65
+ },
66
+ "peerDependenciesMeta": {
67
+ "plotly.js": {
68
+ "optional": true
69
+ },
70
+ "monaco-editor": {
71
+ "optional": true
72
+ }
73
+ },
74
+ "keywords": [
75
+ "tiling",
76
+ "window-manager",
77
+ "datatable",
78
+ "command-palette",
79
+ "ui"
80
+ ]
81
+ }
@@ -3,7 +3,10 @@
3
3
  * pattern used by SFC / Markets / Scenarios / KPIs landings (and the
4
4
  * market-archetype instances table). Three responsibilities:
5
5
  *
6
- * 1. Single-click row → open the entity (handled by callers).
6
+ * 1. Single-click row → open the entity (handled by callers). Since 0.5.0
7
+ * the click is judged by the same rule as `DataTable`'s `onRowActivate`
8
+ * (`ui/components/row_activation.js`); a table that owns its rows can
9
+ * use that option directly instead of this helper.
7
10
  * 2. Right-click row → custom context menu with Open / Edit / Delete
8
11
  * (replaces DataTable's default copy-as-TSV menu for these tables;
9
12
  * the default still applies to data tables outside this helper).
@@ -16,6 +19,7 @@
16
19
  */
17
20
 
18
21
  import { showContextMenu } from '../ui/components/context_menu.js';
22
+ import { isRowActivation } from '../ui/components/row_activation.js';
19
23
  import { registerPanelKeys } from './panel_keys.js';
20
24
 
21
25
  /** Attach the navigation-table interactions to a host element that
@@ -85,10 +89,14 @@ export function attachLandingTableBehavior(host, getRow, entityActions, options
85
89
  dispatch(actionBtn.dataset.twmAction, tr ? getRow(tr.__rowIndex) : null);
86
90
  return;
87
91
  }
88
- // Plain row click → open. Ignore clicks on interactive controls
89
- // (buttons, filter inputs, links) and anything outside a body row
90
- // (pagination strip, header, empty space).
91
- if (ev.target.closest('button, a, input, select, textarea')) return;
92
+ // Plain row click → open — by THE row-activation rule DataTable's own
93
+ // `onRowActivate` uses (0.5.0, `ui/components/row_activation.js`), so
94
+ // the two cannot drift: not on a control (a button, a field, a link),
95
+ // not on the click that ends a drag selecting a cell's text, and not on
96
+ // the second click of a double-click, which used to open the row twice.
97
+ // Anything outside a body row (pagination strip, header, empty space)
98
+ // is not a row either.
99
+ if (!isRowActivation(ev, 'click', { scope: host })) return;
92
100
  const tr = bodyRowFor(ev);
93
101
  if (tr) dispatch('open', getRow(tr.__rowIndex));
94
102
  };