@phreshos/core 0.1.1 → 0.1.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/README.md CHANGED
@@ -220,6 +220,13 @@ from its Client; its stable capability addresses the Client's current, live
220
220
  presentation state and rejects reads or mutations while that Client is
221
221
  absent.
222
222
 
223
+ `LaunchClient.title` supplies a dynamic initial title when starting a declared
224
+ Client. The system resolves it with the remaining launch shape before the
225
+ Client is announced, so the first rendered Window already has its final title.
226
+ Omission uses the Program declaration; `window.changeTitle()` remains the live
227
+ operation after startup. Window operations are never queued while the Client
228
+ is absent.
229
+
223
230
  Core also defines the independent, environment-neutral `FileWallpaper` and
224
231
  `DesktopWallpaper` contracts. The desktop variant additionally accepts a
225
232
  Program and the deliberately narrow `WallpaperLaunch`, containing only `name`,
@@ -231,10 +238,9 @@ persistence, upload, Process creation, or rendering implementation.
231
238
 
232
239
  `client.window.surface` addresses the optional host-rendered material belonging
233
240
  to one Window. Its source of truth is authoritative, server-owned Window state,
234
- not iframe state. `snapshot()` explicitly reads the current target, while the
235
- ordinary `change` subscription receives only replacements published after that
236
- subscription exists. A `null` target means no Surface exists in the render
237
- tree.
241
+ not iframe state. Program endpoints may explicitly replace or remove that
242
+ target, but cannot read or subscribe to it. A `null` target means no Surface
243
+ exists in the render tree.
238
244
 
239
245
  Only Windows currently occupying the `under` or `over` layer may call `set()`
240
246
  or `remove()`; `window` and `wallpaper` layers reject those operations. Calling
package/dist/launch.d.ts CHANGED
@@ -19,6 +19,8 @@ export type Layer = "window" | "under" | "over";
19
19
  export declare const layers: readonly Layer[];
20
20
  /** Per-Process overrides used when starting a Client and its Window. */
21
21
  export type LaunchClient = Readonly<{
22
+ /** Initial Window title for this Client incarnation. */
23
+ title?: string;
22
24
  /** Initial Window size for this Process. */
23
25
  size?: Size;
24
26
  /** Initial Window position for this Process. */
package/dist/main.d.ts CHANGED
@@ -18,6 +18,6 @@ export { Server, type AnswerCapture, type AnswerMessage, type AnswerObserver, ty
18
18
  export { Client, type ClientTraffic } from "./client.js";
19
19
  export { Process, type Exit, type ProcessEvents } from "./process.js";
20
20
  export { Program, type ClientDeclaration, type EndpointDeclaration, type ProgramEvents, type ProgramIconSize, type ProgramProcessExit } from "./program.js";
21
- export { type Window, type WindowEvents, type WindowLayer, type WindowState, type WindowSurface, type WindowSurfaceEasing, type WindowSurfaceEvents, type WindowSurfaceSettings, type WindowSurfaceTransaction } from "./window.js";
21
+ export { type Window, type WindowEvents, type WindowLayer, type WindowState, type WindowSurface, type WindowSurfaceEasing, type WindowSurfaceSettings, type WindowSurfaceTransaction } from "./window.js";
22
22
  export { layers, type Launch, type LaunchClient, type Layer, type Position, type Size } from "./launch.js";
23
23
  export { defineConfig, type ClientConfig, type ClientDevelopment, type Config, type ServerConfig, type ServerDevelopment } from "./config.js";
package/dist/window.d.ts CHANGED
@@ -21,15 +21,8 @@ export type WindowSurfaceSettings = Readonly<{
21
21
  /** Optional motion from the currently rendered values to this target. */
22
22
  transaction?: WindowSurfaceTransaction;
23
23
  }>;
24
- /** Live changes emitted by one Window Surface capability. */
25
- export type WindowSurfaceEvents = {
26
- /** The authoritative target changed, including immediate removal as null. */
27
- change: WindowSurfaceSettings | null;
28
- };
29
24
  /** Optional host-rendered material owned by one authoritative Window. */
30
- export interface WindowSurface extends Subscribable<WindowSurfaceEvents, never> {
31
- /** Explicitly reads the authoritative target, or null when no Surface exists. */
32
- snapshot(): Promise<WindowSurfaceSettings | null>;
25
+ export interface WindowSurface {
33
26
  /** Creates or replaces the authoritative target. Omission creates the default Surface. */
34
27
  set(settings?: WindowSurfaceSettings): Promise<void>;
35
28
  /** Immediately removes the authoritative Surface. */
@@ -64,8 +57,6 @@ export type WindowState = Readonly<{
64
57
  layer: WindowLayer;
65
58
  /** Current page beneath the declared Client location. */
66
59
  location: string;
67
- /** Current authoritative host Surface target, or null when absent. */
68
- surface: WindowSurfaceSettings | null;
69
60
  }>;
70
61
  /** Presentation capability owned by one Client handle. */
71
62
  export interface Window extends Subscribable<WindowEvents, never> {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@phreshos/core",
3
- "version": "0.1.1",
3
+ "version": "0.1.2",
4
4
  "description": "Environment-neutral contracts and domain objects for PhreshOS Programs.",
5
5
  "type": "module",
6
6
  "sideEffects": false,