@plitzi/plitzi-builder 0.39.11 → 0.39.13
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/CHANGELOG.md +42 -0
- package/dist/modules/App/AppContext.d.ts +9 -0
- package/dist/modules/App/components/AppHeader/AgentPanel/AgentPanel.d.ts +8 -0
- package/dist/modules/App/components/AppHeader/AgentPanel/agentSteps.d.ts +75 -0
- package/dist/modules/App/components/AppHeader/AgentPanel/index.d.ts +2 -0
- package/dist/modules/App/components/AppHeader/HeaderPopover.d.ts +3 -1
- package/dist/modules/App/components/AppHeader/consoleUrl.d.ts +6 -0
- package/dist/modules/Builder/components/BuilderArea/PreviewDock.d.ts +3 -0
- package/dist/modules/Builder/components/BuilderArea/PreviewVisitor.d.ts +7 -0
- package/dist/modules/Builder/components/BuilderArea/previewDockRoom.d.ts +5 -0
- package/dist/modules/Builder/components/BuilderArea/usePreviewDock.d.ts +7 -0
- package/dist/modules/Builder/components/BuilderTree/utils.d.ts +1 -1
- package/dist/modules/Elements/Element.d.ts +7 -2
- package/dist/modules/Elements/ElementCategory.d.ts +2 -2
- package/dist/modules/Elements/ElementHelper.d.ts +20 -3
- package/dist/modules/StateManager/components/PreviewPanel/PreviewPanel.d.ts +7 -0
- package/dist/modules/StateManager/components/PreviewPanel/index.d.ts +1 -0
- package/dist/modules/StateManager/components/PreviewPanel/panes/DatePane.d.ts +6 -0
- package/dist/modules/StateManager/components/PreviewPanel/panes/FlagsPane.d.ts +6 -0
- package/dist/modules/StateManager/components/PreviewPanel/panes/VariantsPane.d.ts +7 -0
- package/dist/modules/StateManager/components/PreviewPanel/panes/VisitorPane.d.ts +3 -0
- package/dist/modules/StateManager/components/VisitorTab/VisitorTab.d.ts +2 -2
- package/dist/modules/StateManager/components/VisitorTab/components/AudienceFacts/AudienceFacts.d.ts +7 -0
- package/dist/modules/StateManager/components/VisitorTab/components/AudienceFacts/index.d.ts +3 -0
- package/dist/modules/StateManager/components/VisitorTab/components/ExperimentVariants/ExperimentVariants.d.ts +6 -0
- package/dist/modules/StateManager/components/VisitorTab/components/ExperimentVariants/index.d.ts +3 -0
- package/dist/modules/StateManager/components/VisitorTab/components/PageReads/PageReads.d.ts +3 -0
- package/dist/modules/StateManager/components/VisitorTab/components/PageReads/index.d.ts +1 -0
- package/dist/modules/StateManager/components/VisitorTab/components/SimulatedTime/SimulatedTime.d.ts +6 -0
- package/dist/modules/StateManager/components/VisitorTab/components/SimulatedTime/index.d.ts +3 -0
- package/dist/modules/StateManager/components/VisitorTab/components/VisitorPicker/VisitorPicker.d.ts +6 -0
- package/dist/modules/StateManager/components/VisitorTab/components/VisitorPicker/index.d.ts +1 -0
- package/dist/modules/StateManager/helpers.d.ts +5 -0
- package/dist/modules/StateManager/hooks/usePreviewDraws.d.ts +6 -0
- package/dist/modules/StateManager/hooks/useSimulatedVisitor.d.ts +10 -0
- package/dist/modules/StateManager/previewDraws.d.ts +12 -0
- package/dist/package.json.d.ts +3 -3
- package/dist/plitzi-builder.css +1 -1
- package/dist/plitzi-builder.css.gz +0 -0
- package/dist/plitzi-builder.js +2454 -2307
- package/dist/plitzi-builder.js.gz +0 -0
- package/package.json +17 -17
- package/dist/modules/Flags/helpers/flagRuleFields.d.ts +0 -11
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,47 @@
|
|
|
1
1
|
# @plitzi/plitzi-builder
|
|
2
2
|
|
|
3
|
+
## 0.39.13
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- 919736b: Released with every `@plitzi` package at this version. What changed in each, and what to do when you upgrade, is in
|
|
8
|
+
`@plitzi/cli`'s `CHANGELOG.md`: one copy of the notes, not one per package.
|
|
9
|
+
- Updated dependencies [919736b]
|
|
10
|
+
- @plitzi/plitzi-sdk@0.39.13
|
|
11
|
+
- @plitzi/sdk-auth@0.39.13
|
|
12
|
+
- @plitzi/sdk-authoring@0.39.13
|
|
13
|
+
- @plitzi/sdk-dev-tools@0.39.13
|
|
14
|
+
- @plitzi/sdk-elements@0.39.13
|
|
15
|
+
- @plitzi/sdk-event-bridge@0.39.13
|
|
16
|
+
- @plitzi/sdk-interactions@0.39.13
|
|
17
|
+
- @plitzi/sdk-navigation@0.39.13
|
|
18
|
+
- @plitzi/sdk-plugins@0.39.13
|
|
19
|
+
- @plitzi/sdk-schema@0.39.13
|
|
20
|
+
- @plitzi/sdk-shared@0.39.13
|
|
21
|
+
- @plitzi/sdk-style@0.39.13
|
|
22
|
+
- @plitzi/sdk-variables@0.39.13
|
|
23
|
+
|
|
24
|
+
## 0.39.12
|
|
25
|
+
|
|
26
|
+
### Patch Changes
|
|
27
|
+
|
|
28
|
+
- 2f5b44d: Released with every `@plitzi` package at this version. What changed in each, and what to do when you upgrade, is in
|
|
29
|
+
`@plitzi/cli`'s `CHANGELOG.md`: one copy of the notes, not one per package.
|
|
30
|
+
- Updated dependencies [2f5b44d]
|
|
31
|
+
- @plitzi/plitzi-sdk@0.39.12
|
|
32
|
+
- @plitzi/sdk-auth@0.39.12
|
|
33
|
+
- @plitzi/sdk-authoring@0.39.12
|
|
34
|
+
- @plitzi/sdk-dev-tools@0.39.12
|
|
35
|
+
- @plitzi/sdk-elements@0.39.12
|
|
36
|
+
- @plitzi/sdk-event-bridge@0.39.12
|
|
37
|
+
- @plitzi/sdk-interactions@0.39.12
|
|
38
|
+
- @plitzi/sdk-navigation@0.39.12
|
|
39
|
+
- @plitzi/sdk-plugins@0.39.12
|
|
40
|
+
- @plitzi/sdk-schema@0.39.12
|
|
41
|
+
- @plitzi/sdk-shared@0.39.12
|
|
42
|
+
- @plitzi/sdk-style@0.39.12
|
|
43
|
+
- @plitzi/sdk-variables@0.39.12
|
|
44
|
+
|
|
3
45
|
## 0.39.11
|
|
4
46
|
|
|
5
47
|
### Patch Changes
|
|
@@ -19,6 +19,15 @@ export type AppContextValue = {
|
|
|
19
19
|
motionReplays: number;
|
|
20
20
|
/** Plays every motion on the canvas from its start, and leaves it playing. */
|
|
21
21
|
replayMotion: () => void;
|
|
22
|
+
/** How many times the preview's page was reloaded, as a browser's F5: what the canvas is drawn anew on. */
|
|
23
|
+
pageLoads: number;
|
|
24
|
+
/** Reloads the page the preview shows: its state for this visit alone emptied, what it keeps kept, drawn anew. */
|
|
25
|
+
reloadPage: () => void;
|
|
26
|
+
/**
|
|
27
|
+
* Shows the preview's page to a new visitor: the tests it draws drawn again by their shares, nothing the page kept —
|
|
28
|
+
* a first visit's — drawn anew.
|
|
29
|
+
*/
|
|
30
|
+
newVisitor: () => void;
|
|
22
31
|
zoom: number;
|
|
23
32
|
setZoom: Dispatch<SetStateAction<number>>;
|
|
24
33
|
displayMode: DisplayMode;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { AgentSpace } from './agentSteps';
|
|
2
|
+
/**
|
|
3
|
+
* Working on this space with an AI agent — Claude Code, OpenCode, Gemini CLI or Codex: as a collaborator over the MCP,
|
|
4
|
+
* or on the person's computer with the CLI. What to set up once, with this space's address written in, and what to
|
|
5
|
+
* tell the agent as the work goes, each a line to copy.
|
|
6
|
+
*/
|
|
7
|
+
declare const AgentPanel: (space: AgentSpace) => import('react').JSX.Element;
|
|
8
|
+
export default AgentPanel;
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
/** A line to copy: what it is for, the words, and whether it is a command for a terminal or words for the agent. */
|
|
2
|
+
export type AgentLine = {
|
|
3
|
+
id: string;
|
|
4
|
+
label: string;
|
|
5
|
+
text: string;
|
|
6
|
+
kind: 'command' | 'prompt';
|
|
7
|
+
note?: string;
|
|
8
|
+
};
|
|
9
|
+
/** One way of working with an agent: what is set up once, and what to tell it as the work goes. */
|
|
10
|
+
export type AgentWay = {
|
|
11
|
+
setup: AgentLine[];
|
|
12
|
+
prompts: AgentLine[];
|
|
13
|
+
};
|
|
14
|
+
/** The space the lines are written for, and where this deployment's MCP server answers — none where it runs none. */
|
|
15
|
+
export type AgentSpace = {
|
|
16
|
+
name: string;
|
|
17
|
+
permanentUrl: string;
|
|
18
|
+
mcpServer?: string;
|
|
19
|
+
};
|
|
20
|
+
/**
|
|
21
|
+
* The agents the panel writes for: how each adds an MCP server over HTTP, how — and where — it signs in to it, the
|
|
22
|
+
* command that starts it, and whether it reads the project's `AGENTS.md` by itself — Gemini CLI reads its own
|
|
23
|
+
* `GEMINI.md`, so it is told.
|
|
24
|
+
*/
|
|
25
|
+
export declare const AGENTS: readonly [{
|
|
26
|
+
readonly id: "claude";
|
|
27
|
+
readonly label: "Claude Code";
|
|
28
|
+
readonly start: "claude";
|
|
29
|
+
readonly readsAgents: true;
|
|
30
|
+
readonly add: (url: string) => string;
|
|
31
|
+
readonly login: "/mcp";
|
|
32
|
+
readonly loginWhere: "In a new Claude Code session — one already open does not see Plitzi — type /mcp, pick plitzi and Authenticate.";
|
|
33
|
+
}, {
|
|
34
|
+
readonly id: "opencode";
|
|
35
|
+
readonly label: "OpenCode";
|
|
36
|
+
readonly start: "opencode";
|
|
37
|
+
readonly readsAgents: true;
|
|
38
|
+
readonly add: (url: string) => string;
|
|
39
|
+
readonly login: "opencode mcp auth plitzi";
|
|
40
|
+
readonly loginWhere: "In a terminal.";
|
|
41
|
+
}, {
|
|
42
|
+
readonly id: "gemini";
|
|
43
|
+
readonly label: "Gemini CLI";
|
|
44
|
+
readonly start: "gemini";
|
|
45
|
+
readonly readsAgents: false;
|
|
46
|
+
readonly add: (url: string) => string;
|
|
47
|
+
readonly login: "/mcp auth plitzi";
|
|
48
|
+
readonly loginWhere: "Inside gemini, started after the line above.";
|
|
49
|
+
}, {
|
|
50
|
+
readonly id: "codex";
|
|
51
|
+
readonly label: "Codex";
|
|
52
|
+
readonly start: "codex";
|
|
53
|
+
readonly readsAgents: true;
|
|
54
|
+
readonly add: (url: string) => string;
|
|
55
|
+
readonly login: "codex mcp login plitzi";
|
|
56
|
+
readonly loginWhere: "In a terminal.";
|
|
57
|
+
}];
|
|
58
|
+
export type AgentId = (typeof AGENTS)[number]['id'];
|
|
59
|
+
export declare const isAgentId: (value: unknown) => value is AgentId;
|
|
60
|
+
/**
|
|
61
|
+
* Working on a space with an agent, the two ways this builder offers — one list, read by the panel and held by its test:
|
|
62
|
+
*
|
|
63
|
+
* - **As a collaborator**: the agent joins the space itself over Plitzi's MCP server, signed in as the person, and
|
|
64
|
+
* every change it makes is the draft here, made as it makes it — it shows among the collaborators.
|
|
65
|
+
* - **On the computer**: the space taken out as a project with the CLI (`plitzi create --from`), run there, and kept in
|
|
66
|
+
* step with the space in the cloud — its changes brought in (`space pull`), the project's sent back as the draft
|
|
67
|
+
* (`space push`). The project carries `AGENTS.md` and Plitzi's skills for whichever agent works in it.
|
|
68
|
+
*
|
|
69
|
+
* Not both at once on one space: a change made here or over the MCP while the project is out makes its push wait for a
|
|
70
|
+
* pull.
|
|
71
|
+
*/
|
|
72
|
+
export declare const agentSteps: ({ name, permanentUrl, mcpServer }: AgentSpace, agentId: AgentId) => {
|
|
73
|
+
collaborator?: AgentWay;
|
|
74
|
+
local: AgentWay;
|
|
75
|
+
};
|
|
@@ -8,6 +8,8 @@ export type HeaderPopoverProps = {
|
|
|
8
8
|
trigger: ReactNode;
|
|
9
9
|
triggerClassName: string;
|
|
10
10
|
align?: 'start' | 'end';
|
|
11
|
+
/** A panel that holds lines to read whole — commands, prompts: wider, and scrolling within the window's height. */
|
|
12
|
+
wide?: boolean;
|
|
11
13
|
/** The panel's contents, given the way to close it. */
|
|
12
14
|
children: (close: () => void) => ReactNode;
|
|
13
15
|
};
|
|
@@ -15,5 +17,5 @@ export type HeaderPopoverProps = {
|
|
|
15
17
|
* A panel under a header button that says something and offers what to do about it — the draft's status. A dialog,
|
|
16
18
|
* not a menu: focus moves to its first control, Escape and a press outside close it.
|
|
17
19
|
*/
|
|
18
|
-
declare const HeaderPopover: ({ id, label, title, trigger, triggerClassName, align, children }: HeaderPopoverProps) => import('react').JSX.Element;
|
|
20
|
+
declare const HeaderPopover: ({ id, label, title, trigger, triggerClassName, align, wide, children }: HeaderPopoverProps) => import('react').JSX.Element;
|
|
19
21
|
export default HeaderPopover;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* A space's console in the platform it was opened from (`/spaces/split-roast`): by the name its address carries, as the
|
|
3
|
+
* console's own links say it, and by its id until the space has loaded. Where the builder goes back to — the space it
|
|
4
|
+
* was opened for, not the list of every space.
|
|
5
|
+
*/
|
|
6
|
+
export declare const consoleUrlOf: (origin: string, permanentUrl: unknown, webId: number) => string;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The visitor the canvas's preview shows the page to, said where the page is — their language, device, first visit or
|
|
3
|
+
* not, who is signed in and the date read, when one is chosen — and pressed, the Visitor tab's choices, so a preview is
|
|
4
|
+
* tried without leaving it (its side panels are put away there).
|
|
5
|
+
*/
|
|
6
|
+
declare const PreviewVisitor: () => import('react').JSX.Element;
|
|
7
|
+
export default PreviewVisitor;
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
/** The room the preview's visitor panel takes beside the canvas: its width and the gutter around it. */
|
|
2
|
+
export declare const PANEL_WIDTH = 360;
|
|
3
|
+
export declare const GUTTER = 16;
|
|
4
|
+
/** Whether the preview's visitor choices are docked beside the canvas — then the address bar only says who it is. */
|
|
5
|
+
export declare const PreviewDockContext: import('react').Context<boolean>;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { RefObject } from 'react';
|
|
2
|
+
/**
|
|
3
|
+
* Whether the space right of the canvas holds the visitor panel: the canvas is centred in its container and capped at
|
|
4
|
+
* its device's width, so what is left on its right is half of what it does not take. Measured as both are resized.
|
|
5
|
+
*/
|
|
6
|
+
declare const usePreviewDock: (container: RefObject<HTMLDivElement | null>, wanted: boolean) => boolean;
|
|
7
|
+
export default usePreviewDock;
|
|
@@ -7,5 +7,5 @@ type Node = {
|
|
|
7
7
|
parentId?: string;
|
|
8
8
|
items?: Node[];
|
|
9
9
|
};
|
|
10
|
-
export declare const recursiveMap: (flat: Record<string, Element>, componentDefinitions: Record<string, ComponentDefinition>, id: string,
|
|
10
|
+
export declare const recursiveMap: (flat: Record<string, Element>, componentDefinitions: Record<string, ComponentDefinition>, id: string, editing?: boolean, parentId?: string) => undefined | Node;
|
|
11
11
|
export {};
|
|
@@ -1,7 +1,12 @@
|
|
|
1
1
|
import { ComponentDefinition } from '@plitzi/sdk-shared';
|
|
2
2
|
export type ElementProps = {
|
|
3
3
|
component: ComponentDefinition;
|
|
4
|
+
/** The label of the element this one only works inside, when it is a part of one: said under its name. */
|
|
5
|
+
partOf?: string;
|
|
4
6
|
};
|
|
5
|
-
/**
|
|
6
|
-
|
|
7
|
+
/**
|
|
8
|
+
* One element of the catalog, dragged onto the canvas or into Layers: its icon, its whole name, what it is on hover —
|
|
9
|
+
* and, for a part of another element (a test's variant), what it goes inside, its icon drawn as a piece.
|
|
10
|
+
*/
|
|
11
|
+
declare const Element: ({ component, partOf }: ElementProps) => import('react').JSX.Element;
|
|
7
12
|
export default Element;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { CatalogEntry } from './ElementHelper';
|
|
2
2
|
export type ElementCategoryProps = {
|
|
3
|
-
components:
|
|
3
|
+
components: CatalogEntry[];
|
|
4
4
|
category: string;
|
|
5
5
|
/** Said above the grid — when a search lists several categories at once. */
|
|
6
6
|
titled?: boolean;
|
|
@@ -16,10 +16,27 @@ export declare const categoryDisplay: (category: string) => {
|
|
|
16
16
|
label: string;
|
|
17
17
|
icon: string;
|
|
18
18
|
};
|
|
19
|
-
/**
|
|
19
|
+
/**
|
|
20
|
+
* A definition's description, cut to its first sentence — up to a full stop, or to a colon that a long one goes on
|
|
21
|
+
* after (said as a full stop): what the panel says of it on hover. A description begins with that sentence; a lead-in
|
|
22
|
+
* such as "An A/B test:" is no summary (`ElementHelper.test.ts` holds every built-in to it).
|
|
23
|
+
*/
|
|
20
24
|
export declare const summaryOf: (definition: ComponentDefinition) => string;
|
|
25
|
+
/** What the catalog says of an element on hover: its name, where it goes when it is a part, and what it is. */
|
|
26
|
+
export declare const hoverTextOf: (label: string, summary: string, partOf?: string) => string;
|
|
27
|
+
/**
|
|
28
|
+
* The type an element only works somewhere inside — a carousel's track, an A/B test's variant — read where its
|
|
29
|
+
* declaration says it: a plugin's in its manifest, over a built-in type of the same name; a built-in's in its own.
|
|
30
|
+
*/
|
|
31
|
+
export declare const ancestorTypeFor: (type: string, registered: ComponentDefinition | undefined) => string | undefined;
|
|
32
|
+
/** One element of the catalog, and — when it is a part of another — that element's label: what it goes inside. */
|
|
33
|
+
export type CatalogEntry = {
|
|
34
|
+
definition: ComponentDefinition;
|
|
35
|
+
partOf?: string;
|
|
36
|
+
};
|
|
21
37
|
/**
|
|
22
38
|
* The catalog as the elements panel lists it: every definition an author can drag in whose label or type matches
|
|
23
|
-
* `filter`, grouped by category — the categories in the panel's order, the elements in each by their label
|
|
39
|
+
* `filter`, grouped by category — the categories in the panel's order, the elements in each by their label, each part
|
|
40
|
+
* after its container.
|
|
24
41
|
*/
|
|
25
|
-
export declare const definitionsByCategory: (definitions: Record<string, ComponentDefinition>, filter: string) => [string,
|
|
42
|
+
export declare const definitionsByCategory: (definitions: Record<string, ComponentDefinition>, filter: string) => [string, CatalogEntry[]][];
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Everything the canvas's preview is tried with, in one place: who the visitor is, the variant of each Variants
|
|
3
|
+
* element, the feature flags, the date and the address's parameters — each tab marked with how many of its choices are set — and a
|
|
4
|
+
* reload, as a browser's F5. Docked beside the canvas where there is room, under the address bar's button else.
|
|
5
|
+
*/
|
|
6
|
+
declare const PreviewPanel: () => import('react').JSX.Element;
|
|
7
|
+
export default PreviewPanel;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default } from './PreviewPanel';
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Every Variants element of the page the canvas shows — and of the space's components — and what the preview's
|
|
3
|
+
* visitor sees of each: by chance the variant picked here; by rules the one their facts match, which the Visitor and
|
|
4
|
+
* Address tabs change.
|
|
5
|
+
*/
|
|
6
|
+
declare const VariantsPane: () => import('react').JSX.Element;
|
|
7
|
+
export default VariantsPane;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Who the canvas shows the page to
|
|
3
|
-
*
|
|
2
|
+
* Who the canvas shows the page to — the editor's session, a guest or a test account — the facts the space's Variants by
|
|
3
|
+
* rules read, the variant of each by chance, the date, and what the page then reads of its visitor (`auth`).
|
|
4
4
|
*/
|
|
5
5
|
declare const VisitorTab: () => import('react').JSX.Element;
|
|
6
6
|
export default VisitorTab;
|
package/dist/modules/StateManager/components/VisitorTab/components/AudienceFacts/AudienceFacts.d.ts
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* What the canvas's visitor is for the space's audiences — the device, the language, the country, whether they came
|
|
3
|
+
* before — each left to what the builder says by itself until chosen: the device the canvas is sized as, the editor's
|
|
4
|
+
* language, no country.
|
|
5
|
+
*/
|
|
6
|
+
declare const AudienceFacts: () => import('react').JSX.Element;
|
|
7
|
+
export default AudienceFacts;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The variant of each of the space's tests by chance the canvas's preview shows: drawn by its shares, as a visitor's
|
|
3
|
+
* page draws it, until one is picked by hand. The builder's own: never kept, never a visitor's.
|
|
4
|
+
*/
|
|
5
|
+
declare const ExperimentVariants: () => import('react').JSX.Element | null;
|
|
6
|
+
export default ExperimentVariants;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default } from './PageReads';
|
package/dist/modules/StateManager/components/VisitorTab/components/SimulatedTime/SimulatedTime.d.ts
ADDED
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The instant the canvas's preview is shown at, for what the space shows or says by the time (`timeWindow`, `countdown`) — written and read
|
|
3
|
+
* in UTC, as the windows are. Left empty, the editor's own clock.
|
|
4
|
+
*/
|
|
5
|
+
declare const SimulatedTime: () => import('react').JSX.Element;
|
|
6
|
+
export default SimulatedTime;
|
package/dist/modules/StateManager/components/VisitorTab/components/VisitorPicker/VisitorPicker.d.ts
ADDED
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Who the canvas shows the page to: the editor's own session, a guest, or one of the space's test accounts — its roles,
|
|
3
|
+
* and what they give, as a visitor holding them.
|
|
4
|
+
*/
|
|
5
|
+
declare const VisitorPicker: () => import('react').JSX.Element;
|
|
6
|
+
export default VisitorPicker;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default } from './VisitorPicker';
|
|
@@ -52,3 +52,8 @@ export declare const persistenceOf: (settings: Schema["settings"], key: string)
|
|
|
52
52
|
export declare const parseTyped: (text: string) => unknown;
|
|
53
53
|
/** A value in a line: what a change or a computed value shows. */
|
|
54
54
|
export declare const preview: (value: unknown) => string;
|
|
55
|
+
/**
|
|
56
|
+
* The state a page starts again with when it is reloaded, as a browser's F5 does: what the space keeps between visits
|
|
57
|
+
* (`keepState` and its lists), nothing else — everything the page set for this visit alone is gone.
|
|
58
|
+
*/
|
|
59
|
+
export declare const keptOnReload: (state: Record<string, unknown>, settings: Schema["settings"]) => Record<string, unknown>;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* In the preview, every A/B test nobody picked a variant of by hand is drawn by its shares, as a visitor's page draws
|
|
3
|
+
* it — once, when it has none: a reload keeps what was drawn, as a visitor's cookie keeps it.
|
|
4
|
+
*/
|
|
5
|
+
declare const usePreviewDraws: (previewMode: boolean) => void;
|
|
6
|
+
export default usePreviewDraws;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { DisplayMode } from '@plitzi/sdk-shared';
|
|
2
|
+
import { VisitorFacts } from '@plitzi/sdk-shared/audiences';
|
|
3
|
+
/**
|
|
4
|
+
* The visitor the canvas shows the page to, for the space's audiences: the device it is sized as, the editor's own
|
|
5
|
+
* language and a first visit — each replaced by what the State Manager's Visitor tab chose. Published as the page's
|
|
6
|
+
* `visitor`, the facts a server would have read off a request, so the canvas's preview draws the variant it matches —
|
|
7
|
+
* and the instant it is shown at (`clock`), when one is chosen.
|
|
8
|
+
*/
|
|
9
|
+
declare const useSimulatedVisitor: (displayMode: DisplayMode) => VisitorFacts;
|
|
10
|
+
export default useSimulatedVisitor;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { DeclaredExperiment, ExperimentAssignments } from '@plitzi/sdk-shared/experiments';
|
|
2
|
+
/**
|
|
3
|
+
* The variants the preview shows: each test the space runs and nobody picked by hand drawn by its shares — the ones
|
|
4
|
+
* with no variant yet, or every one of them for a new visitor (`fresh`) — and the variants picked kept as they are.
|
|
5
|
+
* What it shows of tests the space no longer runs is left out.
|
|
6
|
+
*/
|
|
7
|
+
export declare const withDraws: (declared: Record<string, DeclaredExperiment>, shown: ExperimentAssignments, picked: readonly string[], { fresh, random }?: {
|
|
8
|
+
fresh?: boolean;
|
|
9
|
+
random?: () => number;
|
|
10
|
+
}) => ExperimentAssignments;
|
|
11
|
+
/** Whether two sets of variants show the same: what spares the store a write that changes nothing. */
|
|
12
|
+
export declare const sameVariants: (a: ExperimentAssignments, b: ExperimentAssignments) => boolean;
|
package/dist/package.json.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
declare const _default: {
|
|
2
2
|
"name": "@plitzi/plitzi-builder",
|
|
3
|
-
"version": "0.39.
|
|
3
|
+
"version": "0.39.13",
|
|
4
4
|
"homepage": "./",
|
|
5
5
|
"license": "AGPL-3.0",
|
|
6
6
|
"files": [
|
|
@@ -34,7 +34,7 @@ declare const _default: {
|
|
|
34
34
|
"@fortawesome/fontawesome-free": "^7.3.1",
|
|
35
35
|
"@plitzi/nexus": "^1.5.1",
|
|
36
36
|
"@plitzi/plitzi-sdk": "workspace:*",
|
|
37
|
-
"@plitzi/plitzi-ui": "^1.6.
|
|
37
|
+
"@plitzi/plitzi-ui": "^1.6.41",
|
|
38
38
|
"@plitzi/sdk-auth": "workspace:*",
|
|
39
39
|
"@plitzi/sdk-authoring": "workspace:*",
|
|
40
40
|
"@plitzi/sdk-dev-tools": "workspace:*",
|
|
@@ -52,7 +52,7 @@ declare const _default: {
|
|
|
52
52
|
"apollo-upload-client": "^20.0.0",
|
|
53
53
|
"clsx": "^2.1.1",
|
|
54
54
|
"comlink": "^4.4.2",
|
|
55
|
-
"graphql": "^
|
|
55
|
+
"graphql": "^16.15.0",
|
|
56
56
|
"graphql-ws": "^6.4.2",
|
|
57
57
|
"immer": "^11.2.10",
|
|
58
58
|
"jszip": "^3.10.2",
|