@deepseek-ai/dsh-client-web 0.1.6-alpha.2 → 0.1.7-alpha.2
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/lib/base.css +40 -0
- package/lib/index.js +8 -4
- package/lib/types/boot-client.d.ts +5 -2
- package/package.json +11 -11
package/lib/base.css
CHANGED
|
@@ -39,6 +39,46 @@ html[data-platform='darwin'] body {
|
|
|
39
39
|
background: transparent;
|
|
40
40
|
}
|
|
41
41
|
|
|
42
|
+
/* The transparent window disables backdrop-filter: Chromium composites it
|
|
43
|
+
against the root surface, which vibrancy leaves transparent, so the blur in
|
|
44
|
+
--dsw-menu-backdrop-filter renders as nothing and half-opaque menu fills
|
|
45
|
+
let underlying text bleed through. Compensate with near-opaque fills on the
|
|
46
|
+
same design-platform hues (light 248 249 250 / dark 48 49 54). */
|
|
47
|
+
html[data-platform='darwin'] body {
|
|
48
|
+
--dsw-specific-menu: rgba(248, 249, 250, 0.94);
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
html[data-platform='darwin'] body[data-ds-dark-theme] {
|
|
52
|
+
--dsw-specific-menu: rgba(48, 49, 54, 0.94);
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
/* macOS desktop: the app frame publishes window drag bands, and Electron
|
|
56
|
+
composes app-regions from geometry, not hit testing — a surface covering a
|
|
57
|
+
band would otherwise drag the window instead of receiving clicks. Every
|
|
58
|
+
overlay portals to document.body beside #root, so one rule subtracts them
|
|
59
|
+
all; drag surfaces all live inside #root. */
|
|
60
|
+
html[data-platform='darwin'] body > :not(#root) {
|
|
61
|
+
-webkit-app-region: no-drag;
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
/* Inside #root, interactive controls and raised surfaces (dialogs, menus)
|
|
65
|
+
subtract themselves from any drag band they overlap, wherever they render.
|
|
66
|
+
Electron composes app-regions from geometry in document order, so this works
|
|
67
|
+
only because the bands are declared before all content (AppFrame's first
|
|
68
|
+
child; the sidebar rows that precede the column's overlay slots) — a drag
|
|
69
|
+
rule on a content container would override every overlay mounted earlier in
|
|
70
|
+
the DOM. One selector on the native elements, ARIA roles, and tabindexed
|
|
71
|
+
custom widgets replaces per-component no-drag opt-outs. */
|
|
72
|
+
html[data-platform='darwin'] :is(
|
|
73
|
+
button, a, input, select, textarea, summary, [contenteditable='true'], [tabindex],
|
|
74
|
+
[role='dialog'], [role='alertdialog'], [role='menu'], [role='listbox'], [role='tooltip'],
|
|
75
|
+
[role='button'], [role='link'], [role='tab'], [role='menuitem'], [role='menuitemcheckbox'],
|
|
76
|
+
[role='menuitemradio'], [role='option'], [role='checkbox'], [role='radio'], [role='switch'],
|
|
77
|
+
[role='slider'], [role='combobox'], [role='textbox']
|
|
78
|
+
) {
|
|
79
|
+
-webkit-app-region: no-drag;
|
|
80
|
+
}
|
|
81
|
+
|
|
42
82
|
code,
|
|
43
83
|
pre,
|
|
44
84
|
[data-diff],
|
package/lib/index.js
CHANGED
|
@@ -41,7 +41,8 @@ const STATE_LABELS = {
|
|
|
41
41
|
* Compose the client: `ctx.plugin(Loader)`, `loader.internal = modules`, one
|
|
42
42
|
* `loader.create({ name })` per manifest row, `loader.await()`, then
|
|
43
43
|
* {@link assertEntriesActive}. A row whose module cannot be imported is marked
|
|
44
|
-
* failed; the Loader logs its import error
|
|
44
|
+
* failed; the Loader logs its import error, the module system records it, and
|
|
45
|
+
* the audit rejects startup with that error text per entry.
|
|
45
46
|
* @param options - context, module system, manifest, optional progress sink.
|
|
46
47
|
* @returns resolves after every entry is active; rejects with the audit report otherwise.
|
|
47
48
|
*/
|
|
@@ -60,19 +61,22 @@ async function bootClient(options) {
|
|
|
60
61
|
await options.modules.entries.start(loader, manifest);
|
|
61
62
|
for (const entry of loader.entries()) if (entry.fiber === void 0) onEntryState?.(entry.options.name, "failed");
|
|
62
63
|
await loader.await();
|
|
63
|
-
assertEntriesActive(ctx);
|
|
64
|
+
assertEntriesActive(ctx, options.modules);
|
|
64
65
|
}
|
|
65
66
|
/**
|
|
66
67
|
* Reject entries that failed import/apply or still wait on missing services.
|
|
67
68
|
* @param ctx - root Context carrying the Loader.
|
|
69
|
+
* @param modules - the module system whose recorded import failures name why an entry
|
|
70
|
+
* has no fiber; a row with no record points at the console.
|
|
68
71
|
* @throws {Error} listing every non-active entry with its reason.
|
|
69
72
|
*/
|
|
70
|
-
function assertEntriesActive(ctx) {
|
|
73
|
+
function assertEntriesActive(ctx, modules) {
|
|
71
74
|
const failures = [];
|
|
72
75
|
for (const entry of ctx.loader.entries()) {
|
|
73
76
|
const name = entry.options.name;
|
|
74
77
|
if (entry.fiber === void 0) {
|
|
75
|
-
|
|
78
|
+
const importError = modules.importError(name);
|
|
79
|
+
failures.push(importError === void 0 ? `${name}: import failed (see console for the import error)` : `${name}: import failed: ${importError.message}`);
|
|
76
80
|
continue;
|
|
77
81
|
}
|
|
78
82
|
const state = STATE_LABELS[entry.fiber.state];
|
|
@@ -24,7 +24,8 @@ export interface ClientBootOptions {
|
|
|
24
24
|
* Compose the client: `ctx.plugin(Loader)`, `loader.internal = modules`, one
|
|
25
25
|
* `loader.create({ name })` per manifest row, `loader.await()`, then
|
|
26
26
|
* {@link assertEntriesActive}. A row whose module cannot be imported is marked
|
|
27
|
-
* failed; the Loader logs its import error
|
|
27
|
+
* failed; the Loader logs its import error, the module system records it, and
|
|
28
|
+
* the audit rejects startup with that error text per entry.
|
|
28
29
|
* @param options - context, module system, manifest, optional progress sink.
|
|
29
30
|
* @returns resolves after every entry is active; rejects with the audit report otherwise.
|
|
30
31
|
*/
|
|
@@ -32,7 +33,9 @@ export declare function bootClient(options: ClientBootOptions): Promise<void>;
|
|
|
32
33
|
/**
|
|
33
34
|
* Reject entries that failed import/apply or still wait on missing services.
|
|
34
35
|
* @param ctx - root Context carrying the Loader.
|
|
36
|
+
* @param modules - the module system whose recorded import failures name why an entry
|
|
37
|
+
* has no fiber; a row with no record points at the console.
|
|
35
38
|
* @throws {Error} listing every non-active entry with its reason.
|
|
36
39
|
*/
|
|
37
|
-
export declare function assertEntriesActive(ctx: Context): void;
|
|
40
|
+
export declare function assertEntriesActive(ctx: Context, modules: Pick<ClientModuleLoader, 'importError'>): void;
|
|
38
41
|
//# sourceMappingURL=boot-client.d.ts.map
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@deepseek-ai/dsh-client-web",
|
|
3
3
|
"description": "Web boot kernel: static module table, Cordis loader, framework-free boot page, and UI-renderer handoff",
|
|
4
|
-
"version": "0.1.
|
|
4
|
+
"version": "0.1.7-alpha.2",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "public"
|
|
7
7
|
},
|
|
@@ -32,18 +32,18 @@
|
|
|
32
32
|
"react": "^18.2.0",
|
|
33
33
|
"react-dom": "^18.2.0",
|
|
34
34
|
"typescript": "^6.0.3",
|
|
35
|
-
"@deepseek-ai/
|
|
36
|
-
"@deepseek-ai/
|
|
37
|
-
"@deepseek-ai/dsh-client-store": "
|
|
38
|
-
"@deepseek-ai/dsh-client-ui-dockkit": "
|
|
39
|
-
"@deepseek-ai/dsh-client-ui-renderer": "
|
|
40
|
-
"@deepseek-ai/dsh-client-ui-
|
|
41
|
-
"@deepseek-ai/
|
|
42
|
-
"@deepseek-ai/
|
|
43
|
-
"@deepseek-ai/dsh-host-webserver": "
|
|
35
|
+
"@deepseek-ai/dsh-client-modules": "0.1.7-alpha.2",
|
|
36
|
+
"@deepseek-ai/cordis-plugin-loader": "~1.0.5",
|
|
37
|
+
"@deepseek-ai/dsh-client-store": "0.1.7-alpha.2",
|
|
38
|
+
"@deepseek-ai/dsh-client-ui-dockkit": "0.1.7-alpha.2",
|
|
39
|
+
"@deepseek-ai/dsh-client-ui-renderer": "0.1.7-alpha.2",
|
|
40
|
+
"@deepseek-ai/dsh-client-ui-primitives": "0.1.7-alpha.2",
|
|
41
|
+
"@deepseek-ai/dsh-client-ui-slots": "0.1.7-alpha.2",
|
|
42
|
+
"@deepseek-ai/cordis": "~4.0.4",
|
|
43
|
+
"@deepseek-ai/dsh-host-webserver": "0.1.7-alpha.2"
|
|
44
44
|
},
|
|
45
45
|
"peerDependencies": {
|
|
46
|
-
"@deepseek-ai/cordis": "
|
|
46
|
+
"@deepseek-ai/cordis": "~4.0.4"
|
|
47
47
|
},
|
|
48
48
|
"files": [
|
|
49
49
|
"lib/index.js",
|