@ai-ecoverse/slicc-spectrum 1.72.0 → 1.73.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.
@@ -47,6 +47,7 @@ export interface Handlers {
47
47
  export interface Owner {
48
48
  id?: string;
49
49
  at: number;
50
+ stamp?: boolean;
50
51
  }
51
52
  export type RunContext = Pick<Handlers, 'color' | 'model' | 'owners' | 'agentId'>;
52
53
  export declare const lickLabels: Record<LickChannel, [string, string]>;
@@ -71,6 +72,7 @@ export declare function target(command: string): Target | null;
71
72
  export declare function chip(call: ToolCall, model?: SliccModel | null): TemplateResult;
72
73
  export declare function time(at: number): string;
73
74
  export declare function day(at: number): string;
75
+ export declare function stamps(messages: readonly Message[]): Set<string>;
74
76
  export declare function size(bytes: number): string;
75
77
  export declare function host(url: string): string | null;
76
78
  export interface CardOptions {
@@ -85,10 +87,10 @@ export declare const clusterSize = 3;
85
87
  export declare function parts(entries: MessagePart[], handlers: Handlers, showThinking: boolean, extra?: ToolCall[]): Array<TemplateResult | typeof nothing>;
86
88
  export declare function toolTail(message: Message, showThinking: boolean): boolean;
87
89
  export declare function toolOnly(message: Message, showThinking: boolean): ToolCall[] | null;
88
- export declare function user(message: UserMessage): TemplateResult;
89
- export declare function assistant(message: AssistantMessage, name: string, model: string, handlers: Handlers, showThinking: boolean, suggestion?: string | null, extra?: ToolCall[]): TemplateResult;
90
- export declare function toolMessage(message: ToolMessage, context?: RunContext & Partial<Pick<Handlers, 'suggest'>>, extra?: ToolCall[], suggestion?: string | null): TemplateResult;
90
+ export declare function user(message: UserMessage, stamp?: boolean): TemplateResult;
91
+ export declare function assistant(message: AssistantMessage, name: string, model: string, handlers: Handlers, showThinking: boolean, suggestion?: string | null, extra?: ToolCall[], stamp?: boolean): TemplateResult;
92
+ export declare function toolMessage(message: ToolMessage, context?: RunContext & Partial<Pick<Handlers, 'suggest'>>, extra?: ToolCall[], suggestion?: string | null, stamp?: boolean): TemplateResult;
91
93
  export declare function system(message: SystemMessage, handlers: Handlers): TemplateResult;
92
- export declare function lick(message: LickMessage, handlers: Handlers): TemplateResult;
94
+ export declare function lick(message: LickMessage, handlers: Handlers, stamp?: boolean): TemplateResult;
93
95
  export declare const messageCss: import("lit").CSSResult;
94
96
  export {};
@@ -13,7 +13,7 @@ import '@adobe/spectrum-wc-icons/swc-icon-info-circle.js';
13
13
  import '@adobe/spectrum-wc-icons/swc-icon-visibility.js';
14
14
  import '@adobe/spectrum-wc-icons/swc-icon-visibility-off.js';
15
15
  import { type TemplateResult } from 'lit';
16
- import type { AccessKey, BrowserAutomation, DeviceAccess, LinkedDevice, LinkState, NetworkExit, NetworkLinks, NetworkPort, NetworkRoute, NetworkStatus, RemoteControlMode, SliccModel, TailnetState, TailnetStatus } from '../model/types.js';
16
+ import type { AccessKey, BrowserAutomation, DeviceAccess, Leader, LeaderState, LinkedDevice, LinkState, NetworkExit, NetworkLinks, NetworkPort, NetworkRoute, NetworkStatus, RemoteControlMode, SliccModel, TailnetState, TailnetStatus } from '../model/types.js';
17
17
  import { ModelElement } from './base.js';
18
18
  import { type ConfirmOptions } from './confirm.js';
19
19
  export { command } from './reach.js';
@@ -41,6 +41,8 @@ export interface RemoteLight {
41
41
  }
42
42
  export declare function deviceName(name: string): string;
43
43
  export declare function networkStatus(port: NetworkPort): NetworkStatus;
44
+ export declare const leaderStates: Record<LeaderState, readonly ['neutral' | 'info' | 'positive' | 'notice' | 'negative', string]>;
45
+ export declare function leaderConfirm(leader: Leader): ConfirmOptions;
44
46
  export declare function remoteLight(status: NetworkStatus | undefined): RemoteLight | null;
45
47
  export type LinksSummary = 'permission' | 'none' | 'reconnecting' | 'connecting' | 'offline' | 'linked';
46
48
  export declare function linksSummary(links: NetworkLinks): LinksSummary;
@@ -92,6 +94,9 @@ export declare class SliccNetwork extends ModelElement {
92
94
  syncError: {
93
95
  state: boolean;
94
96
  };
97
+ leaderError: {
98
+ state: boolean;
99
+ };
95
100
  };
96
101
  checking: boolean;
97
102
  copied: string | null;
@@ -103,6 +108,7 @@ export declare class SliccNetwork extends ModelElement {
103
108
  revealed: Record<string, string>;
104
109
  linksError: string;
105
110
  syncError: string;
111
+ leaderError: string;
106
112
  constructor();
107
113
  static styles: import("lit").CSSResult[];
108
114
  protected subscribe(model: SliccModel): Array<() => void>;
@@ -4,7 +4,7 @@ import { type BrowserScenario, DummyBrowser } from './browser.js';
4
4
  import { type ChangesScenario } from './changes.js';
5
5
  import { type MountScenario } from './files.js';
6
6
  import { DummyFollow, type FollowScenario } from './follow.js';
7
- import { DummyNetwork, type LinksScenario, type NetworkScenario, type TailnetScenario } from './network.js';
7
+ import { DummyNetwork, type LeadersScenario, type LinksScenario, type NetworkScenario, type TailnetScenario } from './network.js';
8
8
  import { DummyNotices, type NoticeScenario } from './notices.js';
9
9
  import { DummyTabs, type TabsScenario } from './tabs.js';
10
10
  import { DummyUpdates, type PackageConfirm, type PackageScenario, type UpdateScenario } from './updates.js';
@@ -19,6 +19,7 @@ export interface DummyOptions {
19
19
  network?: NetworkScenario | 'off';
20
20
  tailnet?: TailnetScenario;
21
21
  links?: LinksScenario;
22
+ leaders?: LeadersScenario;
22
23
  changes?: ChangesScenario;
23
24
  notices?: NoticeScenario | 'off';
24
25
  tabs?: TabsScenario | 'off';
@@ -43,4 +44,4 @@ export interface DummyModel extends SliccModel {
43
44
  vault?: DummyVault;
44
45
  }
45
46
  export declare function vaultAccounts(accounts: readonly Account[]): Account[];
46
- export declare function createDummyModel({ delay, storage, updates, packages, confirm, mounts, network, tailnet, links, changes, notices, tabs, approvals, follow, vault, accounts, providers, hold, browser: scenario, sprinkles, monitor, }?: DummyOptions): DummyModel;
47
+ export declare function createDummyModel({ delay, storage, updates, packages, confirm, mounts, network, tailnet, links, leaders, changes, notices, tabs, approvals, follow, vault, accounts, providers, hold, browser: scenario, sprinkles, monitor, }?: DummyOptions): DummyModel;
@@ -1,10 +1,12 @@
1
1
  import { Emitter } from '../model/emitter.js';
2
- import type { AccessKey, LinkedDevice, LinkedFolder, NetworkExit, NetworkLinks, NetworkPort, NetworkStatus, TailnetStatus } from '../model/types.js';
2
+ import type { AccessKey, Leader, LinkedDevice, LinkedFolder, NetworkExit, NetworkLinks, NetworkPort, NetworkStatus, TailnetStatus } from '../model/types.js';
3
3
  import type { Clock } from './clock.js';
4
4
  import type { DummyFiles } from './files.js';
5
5
  export type NetworkScenario = 'ok' | 'limited' | 'failing';
6
6
  export type TailnetScenario = 'off' | 'needs-login' | 'running' | 'failed';
7
7
  export type LinksScenario = 'none' | 'preparing' | 'linked' | 'reconnecting' | 'exit' | 'prompt' | 'denied' | 'remote' | 'followers';
8
+ export type LeadersScenario = 'connected' | 'failed' | 'unlinked' | 'disconnected' | 'two';
9
+ export declare function leadersFixtures(scenario: LeadersScenario): Leader[];
8
10
  export declare function networkFixtures(scenario: NetworkScenario, now?: number): NetworkStatus;
9
11
  export declare function tailnetFixtures(scenario: TailnetScenario): TailnetStatus;
10
12
  export declare function folderFiles(folder: LinkedFolder): Record<string, string>;
@@ -28,7 +30,11 @@ export declare class DummyNetwork extends Emitter<{
28
30
  retryLinks?: () => Promise<void>;
29
31
  mountFolder?: (source: string) => Promise<string>;
30
32
  ejectFolder?: (source: string) => Promise<void>;
31
- constructor(scenario: NetworkScenario, clock: Clock, tailnet?: TailnetScenario, links?: LinksScenario, files?: DummyFiles);
33
+ retryLeader?: (id: string) => Promise<void>;
34
+ disconnectLeader?: (id: string) => Promise<void>;
35
+ reconnectLeader?: (id: string) => Promise<void>;
36
+ forgetLeader?: (id: string) => Promise<void>;
37
+ constructor(scenario: NetworkScenario, clock: Clock, tailnet?: TailnetScenario, links?: LinksScenario, files?: DummyFiles, leaders?: LeadersScenario);
32
38
  setLinks(scenario: LinksScenario): void;
33
39
  status(): NetworkStatus;
34
40
  setScenario(scenario: NetworkScenario): void;
@@ -9,8 +9,8 @@ export type { FollowScenario } from './dummy/follow.js';
9
9
  export { DummyFollow, followFixtures } from './dummy/follow.js';
10
10
  export type { DummyModel, DummyOptions } from './dummy/index.js';
11
11
  export { createDummyModel } from './dummy/index.js';
12
- export type { NetworkScenario, TailnetScenario } from './dummy/network.js';
13
- export { DummyNetwork, joinUrl, linksFixtures, networkFixtures, tailnetFixtures, } from './dummy/network.js';
12
+ export type { LeadersScenario, NetworkScenario, TailnetScenario } from './dummy/network.js';
13
+ export { DummyNetwork, joinUrl, leadersFixtures, linksFixtures, networkFixtures, tailnetFixtures, } from './dummy/network.js';
14
14
  export type { NoticeScenario } from './dummy/notices.js';
15
15
  export { DummyNotices, noticeFixtures } from './dummy/notices.js';
16
16
  export type { TabsScenario } from './dummy/tabs.js';
@@ -655,6 +655,15 @@ export interface NetworkStatus {
655
655
  tailnet?: TailnetStatus;
656
656
  links?: NetworkLinks;
657
657
  exit?: NetworkExit;
658
+ leaders?: readonly Leader[];
659
+ }
660
+ export type LeaderState = 'connecting' | 'reconnecting' | 'connected' | 'disconnected' | 'failed' | 'unlinked';
661
+ export interface Leader {
662
+ id: string;
663
+ name: string;
664
+ hub: string;
665
+ state: LeaderState;
666
+ error?: string;
658
667
  }
659
668
  export type LinkMode = 'local' | 'remote';
660
669
  export type LinkOffer = 'net' | 'http' | 'ssh';
@@ -752,6 +761,10 @@ export interface NetworkPort extends Subscribable<{
752
761
  retryLinks?(): Promise<void>;
753
762
  mountFolder?(source: string): Promise<string>;
754
763
  ejectFolder?(source: string): Promise<void>;
764
+ retryLeader?(id: string): Promise<void>;
765
+ disconnectLeader?(id: string): Promise<void>;
766
+ reconnectLeader?(id: string): Promise<void>;
767
+ forgetLeader?(id: string): Promise<void>;
755
768
  }
756
769
  export interface NoticeAction {
757
770
  id: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ai-ecoverse/slicc-spectrum",
3
- "version": "1.72.0",
3
+ "version": "1.73.0",
4
4
  "description": "Web components for SLICC on Spectrum Web Components: the terminal, the app shell and its surfaces",
5
5
  "type": "module",
6
6
  "license": "Apache-2.0",
@@ -70,10 +70,10 @@
70
70
  }
71
71
  },
72
72
  "devDependencies": {
73
- "@adobe/spectrum-wc": "2.0.0-beta.4",
74
- "@adobe/spectrum-wc-icons": "2.0.0-beta.4",
75
- "@ai-ecoverse/slicc-kernel": "1.88.1",
76
- "@ai-ecoverse/slicc-shared-web": "1.14.0",
73
+ "@adobe/spectrum-wc": "2.0.0-beta.5",
74
+ "@adobe/spectrum-wc-icons": "2.0.0-beta.5",
75
+ "@ai-ecoverse/slicc-kernel": "1.92.0",
76
+ "@ai-ecoverse/slicc-shared-web": "1.16.0",
77
77
  "@ai-ecoverse/slicc-vault": "1.9.1",
78
78
  "@ai-ecoverse/wasm-bash": "5.3.0-18",
79
79
  "@ai-ecoverse/wasm-coreutils": "9.7.0-3",
@@ -103,8 +103,8 @@
103
103
  "dockview-core": "8.4.1",
104
104
  "esbuild": "0.28.2",
105
105
  "happy-dom": "20.14.5",
106
- "lefthook": "2.2.0",
107
- "lucide": "1.52.0",
106
+ "lefthook": "2.2.1",
107
+ "lucide": "1.53.0",
108
108
  "monocart-coverage-reports": "2.13.2",
109
109
  "playwright-core": "1.64.0",
110
110
  "semantic-release": "25.0.9",