@ai-ecoverse/slicc-spectrum 1.26.0 → 1.27.1

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.
@@ -1,5 +1,8 @@
1
1
  import '@adobe/spectrum-wc/components/action-button/swc-action-button.js';
2
2
  import '@adobe/spectrum-wc/components/button/swc-button.js';
3
+ import '@adobe/spectrum-wc/components/tooltip/swc-tooltip.js';
4
+ import '@adobe/spectrum-wc-icons/swc-icon-alert-diamond.js';
5
+ import '@adobe/spectrum-wc-icons/swc-icon-folder-add.js';
3
6
  import { type TemplateResult } from 'lit';
4
7
  import type { GitStatusEntry } from '../components/file-tree.js';
5
8
  import type { Change, FileEntry, SliccModel } from '../model/types.js';
@@ -23,6 +26,7 @@ export declare const statusLabels: {
23
26
  readonly deleted: 'Deleted';
24
27
  };
25
28
  export declare function statusMark(status: Change['status'], announce?: boolean): TemplateResult;
29
+ export declare function failure(error: unknown): string;
26
30
  export declare class SliccFiles extends ModelElement {
27
31
  #private;
28
32
  static properties: {
@@ -32,8 +36,24 @@ export declare class SliccFiles extends ModelElement {
32
36
  count: {
33
37
  state: boolean;
34
38
  };
39
+ mounted: {
40
+ state: boolean;
41
+ };
42
+ mounting: {
43
+ state: boolean;
44
+ };
45
+ ejecting: {
46
+ state: boolean;
47
+ };
48
+ error: {
49
+ state: boolean;
50
+ };
35
51
  };
36
52
  count: number;
53
+ mounted: readonly string[];
54
+ mounting: boolean;
55
+ ejecting: ReadonlySet<string>;
56
+ error: string;
37
57
  constructor();
38
58
  static styles: import("lit").CSSResult[];
39
59
  protected subscribe(model: SliccModel): Array<() => void>;
@@ -36,6 +36,7 @@ export declare class SliccSprinkle extends ThemedElement {
36
36
  constructor();
37
37
  static styles: import("lit").CSSResult;
38
38
  protected willUpdate(changed: PropertyValues): void;
39
+ connectedCallback(): void;
39
40
  focus(): void;
40
41
  protected subscribe(model: SliccModel): Array<() => void>;
41
42
  protected updated(changed: PropertyValues): void;
@@ -1,9 +1,19 @@
1
1
  import { Emitter } from '../model/emitter.js';
2
2
  import type { Change, FileEntry, FileEvents, FilePort } from '../model/types.js';
3
3
  import type { Clock } from './clock.js';
4
+ export type MountScenario = 'mount' | 'cancel' | 'fail';
5
+ export interface DummyMount {
6
+ scenario: MountScenario;
7
+ point: string;
8
+ files: Record<string, string>;
9
+ }
4
10
  export declare class DummyFiles extends Emitter<FileEvents> implements FilePort {
5
11
  #private;
6
- constructor(contents: Record<string, string>, directories: readonly string[], changes: readonly Change[], clock: Clock);
12
+ mount: DummyMount | null;
13
+ mountFolder?: () => Promise<string | null>;
14
+ mounts?: () => readonly string[];
15
+ eject?: (path: string) => Promise<void>;
16
+ constructor(contents: Record<string, string>, directories: readonly string[], changes: readonly Change[], clock: Clock, mount?: DummyMount | null);
7
17
  list(): Promise<readonly FileEntry[]>;
8
18
  read(path: string): Promise<string>;
9
19
  write(path: string, text: string, agentId?: string | null): Promise<void>;
@@ -1,6 +1,8 @@
1
1
  import type { Account, Agent, BrowserTab, Change, Message, ModelOption, Settings, TerminalInfo, UserMessage } from '../model/types.js';
2
2
  export declare const files: Record<string, string>;
3
3
  export declare const directories: string[];
4
+ export declare const mountPoint = "/mnt/photos";
5
+ export declare const mounted: Record<string, string>;
4
6
  export declare const pending: Change[];
5
7
  export declare const models: ModelOption[];
6
8
  export declare const defaults: Settings;
@@ -1,11 +1,13 @@
1
1
  import type { SliccModel } from '../model/types.js';
2
+ import { type MountScenario } from './files.js';
2
3
  import { DummyUpdates, type UpdateScenario } from './updates.js';
3
4
  export interface DummyOptions {
4
5
  delay?: number;
5
6
  storage?: Storage | null;
6
7
  updates?: UpdateScenario;
8
+ mounts?: MountScenario | 'off';
7
9
  }
8
10
  export interface DummyModel extends SliccModel {
9
11
  updates: DummyUpdates;
10
12
  }
11
- export declare function createDummyModel({ delay, storage, updates, }?: DummyOptions): DummyModel;
13
+ export declare function createDummyModel({ delay, storage, updates, mounts, }?: DummyOptions): DummyModel;
@@ -1,3 +1,4 @@
1
+ export type { DummyMount, MountScenario } from './dummy/files.js';
1
2
  export type { DummyModel, DummyOptions } from './dummy/index.js';
2
3
  export { createDummyModel } from './dummy/index.js';
3
4
  export type { UpdateScenario } from './dummy/updates.js';
@@ -283,6 +283,7 @@ export interface FileEvents {
283
283
  files: readonly FileEntry[];
284
284
  file: string;
285
285
  changes: readonly Change[];
286
+ mounts: readonly string[];
286
287
  }
287
288
  export interface FilePort extends Subscribable<FileEvents> {
288
289
  list(): Promise<readonly FileEntry[]>;
@@ -292,6 +293,9 @@ export interface FilePort extends Subscribable<FileEvents> {
292
293
  changes(): readonly Change[];
293
294
  accept(path: string): void;
294
295
  revert(path: string): Promise<void>;
296
+ mountFolder?(): Promise<string | null>;
297
+ mounts?(): readonly string[];
298
+ eject?(path: string): Promise<void>;
295
299
  }
296
300
  export interface TerminalInfo {
297
301
  id: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ai-ecoverse/slicc-spectrum",
3
- "version": "1.26.0",
3
+ "version": "1.27.1",
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",
@@ -73,7 +73,7 @@
73
73
  "@adobe/spectrum-wc": "2.0.0-beta.4",
74
74
  "@adobe/spectrum-wc-icons": "2.0.0-beta.4",
75
75
  "@ai-ecoverse/slicc-kernel": "1.17.4",
76
- "@ai-ecoverse/slicc-shared-web": "1.8.0",
76
+ "@ai-ecoverse/slicc-shared-web": "1.9.0",
77
77
  "@ai-ecoverse/wasm-bash": "5.3.0-8",
78
78
  "@ai-ecoverse/wasm-coreutils": "9.7.0-3",
79
79
  "@biomejs/biome": "2.5.15",