@sparkelf/dsh-knowledge-base 0.5.3 → 0.5.4
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.
|
@@ -76,8 +76,26 @@ export interface KnowledgeContextMenuProps {
|
|
|
76
76
|
shareCopy: ShareDialogCopy;
|
|
77
77
|
/** Close the menu. */
|
|
78
78
|
onClose: () => void;
|
|
79
|
+
/** Open one file for preview. Absent on a surface with no preview. */
|
|
80
|
+
onOpen?: (path: string) => void;
|
|
81
|
+
/**
|
|
82
|
+
* Move one row into a destination directory, both tree-relative.
|
|
83
|
+
*
|
|
84
|
+
* The destination is typed by the reader and resolved by the caller, because only the
|
|
85
|
+
* page knows the caller's authoritative `personal/<id>/...` path. Absent means this
|
|
86
|
+
* surface has no move route and the entry is not offered.
|
|
87
|
+
*/
|
|
88
|
+
onMove?: (row: ContextTarget, destination: string) => Promise<void> | void;
|
|
79
89
|
/** Open the permission surface for this path. */
|
|
80
|
-
onGrant
|
|
90
|
+
onGrant?: (path: string) => void;
|
|
91
|
+
/**
|
|
92
|
+
* Whether the caller may manage grants.
|
|
93
|
+
*
|
|
94
|
+
* The permission entry is hidden unless this is exactly true AND `onGrant` is present:
|
|
95
|
+
* a row that opens a surface the backend will refuse is worse than no row, and the
|
|
96
|
+
* answer comes from the Host rather than being derived here.
|
|
97
|
+
*/
|
|
98
|
+
canManageGrants?: boolean;
|
|
81
99
|
/** Toggle the pin state for this path. */
|
|
82
100
|
onPin: (path: string, pinned: boolean) => void;
|
|
83
101
|
/** Whether this path is currently pinned. */
|
|
@@ -177,6 +177,29 @@ export interface KnowledgeFileTreeProps {
|
|
|
177
177
|
* reports where the click landed.
|
|
178
178
|
*/
|
|
179
179
|
onPasteInto?: (directory: string) => void;
|
|
180
|
+
/**
|
|
181
|
+
* Open the page's own row menu at the pointer.
|
|
182
|
+
*
|
|
183
|
+
* This is how the KNOWLEDGE menu reaches a tree row. The explorer builds a workspace
|
|
184
|
+
* file menu inside itself (copy path, new folder, upload here), which is the wrong
|
|
185
|
+
* vocabulary for a curated knowledge export and cannot carry knowledge actions such
|
|
186
|
+
* as preview, permissions, or trash. When this hook is present the wrapper suppresses
|
|
187
|
+
* that menu for a row and hands the gesture to the page, which renders the same
|
|
188
|
+
* `KnowledgeContextMenu` the table uses. Omitted (the upload destination picker), the
|
|
189
|
+
* explorer menu is left untouched.
|
|
190
|
+
*/
|
|
191
|
+
onRowContextMenu?: (target: {
|
|
192
|
+
relPath: string;
|
|
193
|
+
name: string;
|
|
194
|
+
isDir: boolean;
|
|
195
|
+
}, at: {
|
|
196
|
+
x: number;
|
|
197
|
+
y: number;
|
|
198
|
+
}, selection?: readonly {
|
|
199
|
+
relPath: string;
|
|
200
|
+
name: string;
|
|
201
|
+
isDir: boolean;
|
|
202
|
+
}[]) => void;
|
|
180
203
|
/**
|
|
181
204
|
* Called the moment an extraction is REQUESTED for one document, before it settles.
|
|
182
205
|
*
|
|
@@ -45,6 +45,7 @@ export declare const en: {
|
|
|
45
45
|
readonly grantsManaged: "Authorization is managed in DataOps.";
|
|
46
46
|
readonly menu: "Sections";
|
|
47
47
|
readonly 'menu.search': "Search";
|
|
48
|
+
readonly actionOpen: "Open preview";
|
|
48
49
|
readonly actionDownload: "Download";
|
|
49
50
|
readonly actionRename: "Rename…";
|
|
50
51
|
readonly actionPin: "Pin";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sparkelf/dsh-knowledge-base",
|
|
3
|
-
"version": "0.5.
|
|
3
|
+
"version": "0.5.4",
|
|
4
4
|
"description": "DataOps-backed knowledge base for DeepSeek Harness: a left-sidebar destination, Settings configuration, and index tooling over a mounted NAS view.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./lib/index.js",
|