@acryldev/blends-frame 0.2.7 → 0.2.8

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.
@@ -8,8 +8,9 @@ import { type AppPluginKind, type AppPluginsView, type AppPluginView, type Frame
8
8
  export type ShareTarget = ShareVisibility | 'registry';
9
9
  /** Sharing a local plugin: first what it would do, then, on the person's yes, exactly that. */
10
10
  export interface PluginShare {
11
- plan(target?: ShareTarget): Promise<SharePlan>;
12
- publish(confirmed: SharePlan): Promise<SharedPluginView>;
11
+ /** `owner`: the GitHub account or organization to share to; absent means the person's own. */
12
+ plan(target?: ShareTarget, owner?: string): Promise<SharePlan>;
13
+ publish(confirmed: SharePlan, owner?: string): Promise<SharedPluginView>;
13
14
  }
14
15
  /** What the person can do with one local plugin besides sharing it: keep a packed copy on this machine, and look at its code. */
15
16
  export interface PluginActions {
@@ -71,9 +72,9 @@ export interface AppPluginsApi {
71
72
  read(): Promise<AppPluginsView>;
72
73
  switch(kind: AppPluginKind, name: string, on: boolean): Promise<void>;
73
74
  /** What sharing one local plugin would do (private unless `visibility` says public); nothing is sent. */
74
- planShare(name: string, target?: ShareTarget): Promise<SharePlan>;
75
+ planShare(name: string, target?: ShareTarget, owner?: string): Promise<SharePlan>;
75
76
  /** Share one local plugin as the person confirmed it; answers where it went. */
76
- share(name: string, confirmed: SharePlan): Promise<SharedPluginView>;
77
+ share(name: string, confirmed: SharePlan, owner?: string): Promise<SharedPluginView>;
77
78
  /** Keep a packed copy of one local plugin on this machine. */
78
79
  save(name: string): Promise<SavedPluginResult>;
79
80
  }
@@ -195,6 +195,11 @@ export interface AppSharedView {
195
195
  }
196
196
  export declare function parseAppSharePlan(value: unknown): AppSharePlanView;
197
197
  export declare function parseAppShared(value: unknown): AppSharedView;
198
+ /**
199
+ * The GitHub account or organization a person typed to share a plugin to (blank: theirs). `undefined` when none was asked, `null` when what came is not a GitHub name
200
+ * (it goes to a command line: only a name that cannot start with a dash or hold a space or a slash).
201
+ */
202
+ export declare function parseShareOwner(value: unknown): string | undefined | null;
198
203
  export declare function parseAppShareRequest(value: unknown): AppShareRequest | undefined;
199
204
  export declare const FRAME_PLUGINS_SHARE_PLAN_PATH = "/api/acryl-blends-frame/plugins/share-plan";
200
205
  /** POST `{ name, confirm }`: publish it, only when `confirm` is the plan the person said yes to and it still holds. */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@acryldev/blends-frame",
3
- "version": "0.2.7",
3
+ "version": "0.2.8",
4
4
  "description": "ACRYL Blends frame: the workbench around an app being built - a top bar, the branches and versions on the left, the app alone in the centre, and the agents on the right - as one Cordis plugin with a Host and a client half",
5
5
  "license": "MIT",
6
6
  "repository": {