@skylivellc/lienzo-editor 0.0.0-stage → 0.1.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.
Files changed (89) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +61 -2
  3. package/THIRD_PARTY_NOTICES.md +101 -0
  4. package/dist/LienzoEditor-CQyoS5M0.js +8503 -0
  5. package/dist/LienzoEditor-CQyoS5M0.js.map +1 -0
  6. package/dist/element.js +12 -0
  7. package/dist/element.js.map +1 -0
  8. package/dist/index.js +2 -0
  9. package/dist/standalone/lienzo-editor.js +377 -0
  10. package/dist/standalone/lienzo-editor.js.map +1 -0
  11. package/dist/types/LienzoEditor.vue.d.ts +21 -0
  12. package/dist/types/canvas/Canvas.vue.d.ts +14 -0
  13. package/dist/types/canvas/Overlay.vue.d.ts +38 -0
  14. package/dist/types/canvas/Preview.vue.d.ts +3 -0
  15. package/dist/types/canvas/frame.d.ts +52 -0
  16. package/dist/types/canvas/frameCss.d.ts +6 -0
  17. package/dist/types/canvas/render.d.ts +37 -0
  18. package/dist/types/client.d.ts +48 -0
  19. package/dist/types/dialogs/ConflictDialog.vue.d.ts +3 -0
  20. package/dist/types/dialogs/MediaLibrary.vue.d.ts +3 -0
  21. package/dist/types/dialogs/NewPageDialog.vue.d.ts +3 -0
  22. package/dist/types/dialogs/SiteDialog.vue.d.ts +3 -0
  23. package/dist/types/dialogs/SubmissionsDialog.vue.d.ts +3 -0
  24. package/dist/types/dialogs/ThemeDialog.vue.d.ts +3 -0
  25. package/dist/types/dialogs/VersionsDialog.vue.d.ts +3 -0
  26. package/dist/types/element.d.ts +21 -0
  27. package/dist/types/i18n/en.d.ts +512 -0
  28. package/dist/types/i18n/es.d.ts +2 -0
  29. package/dist/types/i18n/index.d.ts +18 -0
  30. package/dist/types/index.d.ts +7 -0
  31. package/dist/types/model/document.d.ts +46 -0
  32. package/dist/types/model/elements.d.ts +280 -0
  33. package/dist/types/model/geometry.d.ts +74 -0
  34. package/dist/types/model/history.d.ts +17 -0
  35. package/dist/types/model/icons.d.ts +5 -0
  36. package/dist/types/model/templates.d.ts +29 -0
  37. package/dist/types/model/theme.d.ts +40 -0
  38. package/dist/types/panels/ActionPicker.vue.d.ts +25 -0
  39. package/dist/types/panels/AlignButtons.vue.d.ts +3 -0
  40. package/dist/types/panels/DesignPanel.vue.d.ts +3 -0
  41. package/dist/types/panels/ElementPanel.vue.d.ts +8 -0
  42. package/dist/types/panels/FieldControl.vue.d.ts +18 -0
  43. package/dist/types/panels/GradientEditor.vue.d.ts +24 -0
  44. package/dist/types/panels/ModalPanel.vue.d.ts +8 -0
  45. package/dist/types/panels/MultiPanel.vue.d.ts +3 -0
  46. package/dist/types/panels/PagePanel.vue.d.ts +3 -0
  47. package/dist/types/panels/SectionPanel.vue.d.ts +8 -0
  48. package/dist/types/panels/actions.d.ts +52 -0
  49. package/dist/types/panels/content/AppContent.vue.d.ts +9 -0
  50. package/dist/types/panels/content/ButtonContent.vue.d.ts +7 -0
  51. package/dist/types/panels/content/FormFieldContent.vue.d.ts +8 -0
  52. package/dist/types/panels/content/IconContent.vue.d.ts +7 -0
  53. package/dist/types/panels/content/ImageContent.vue.d.ts +7 -0
  54. package/dist/types/panels/content/NavbarContent.vue.d.ts +7 -0
  55. package/dist/types/panels/content/ShapeContent.vue.d.ts +7 -0
  56. package/dist/types/panels/content/TextContent.vue.d.ts +8 -0
  57. package/dist/types/panels/content/VideoContent.vue.d.ts +7 -0
  58. package/dist/types/panels/content/shapes.d.ts +9 -0
  59. package/dist/types/panels/style/FillStyle.vue.d.ts +7 -0
  60. package/dist/types/panels/style/FrameStyle.vue.d.ts +7 -0
  61. package/dist/types/panels/style/MotionStyle.vue.d.ts +7 -0
  62. package/dist/types/panels/style/PositionSection.vue.d.ts +8 -0
  63. package/dist/types/panels/style/TextStyle.vue.d.ts +7 -0
  64. package/dist/types/panels/style/TransformStyle.vue.d.ts +7 -0
  65. package/dist/types/shell/ElementIcon.vue.d.ts +11 -0
  66. package/dist/types/shell/LeftSidebar.vue.d.ts +11 -0
  67. package/dist/types/shell/RightPanel.vue.d.ts +3 -0
  68. package/dist/types/shell/Toolbar.vue.d.ts +3 -0
  69. package/dist/types/shell/typeIcons.d.ts +4 -0
  70. package/dist/types/state/autosave.d.ts +63 -0
  71. package/dist/types/state/editor.d.ts +993 -0
  72. package/dist/types/state/previews.d.ts +26 -0
  73. package/dist/types/state/shortcuts.d.ts +7 -0
  74. package/dist/types/styles/index.d.ts +8 -0
  75. package/dist/types/ui/Button.vue.d.ts +25 -0
  76. package/dist/types/ui/CatalogIcon.vue.d.ts +12 -0
  77. package/dist/types/ui/ColorPicker.vue.d.ts +20 -0
  78. package/dist/types/ui/Dialog.vue.d.ts +33 -0
  79. package/dist/types/ui/Field.vue.d.ts +24 -0
  80. package/dist/types/ui/IconButton.vue.d.ts +24 -0
  81. package/dist/types/ui/ImageField.vue.d.ts +27 -0
  82. package/dist/types/ui/NumberInput.vue.d.ts +22 -0
  83. package/dist/types/ui/PanelSection.vue.d.ts +20 -0
  84. package/dist/types/ui/RangeInput.vue.d.ts +26 -0
  85. package/dist/types/ui/SelectInput.vue.d.ts +33 -0
  86. package/dist/types/ui/TextInput.vue.d.ts +32 -0
  87. package/dist/types/ui/Toasts.vue.d.ts +3 -0
  88. package/dist/types/ui/Toggle.vue.d.ts +17 -0
  89. package/package.json +67 -3
@@ -0,0 +1,280 @@
1
+ import type { AppElement, Catalog, CoreElement, CoreElementType, Element, ElementSpec, StyleGroup } from '@skylivellc/lienzo-core';
2
+ import type { MessageKey } from '../i18n/index.ts';
3
+ type Translate = (key: MessageKey, params?: Record<string, string | number>) => string;
4
+ type Draft = {
5
+ box: {
6
+ x: number;
7
+ w: number;
8
+ h: number;
9
+ };
10
+ props: CoreElement['props'];
11
+ style: CoreElement['style'];
12
+ };
13
+ type CoreSpec = {
14
+ label: MessageKey;
15
+ /** Form fields sit in their own palette group. */
16
+ group: 'content' | 'form';
17
+ /** Style panels the element shows. */
18
+ styles: readonly StyleGroup[];
19
+ /** The prop a double-click edits right on the canvas. */
20
+ inline: 'text' | 'label' | null;
21
+ /** A fresh element with a sensible look and copy in the editor's language. */
22
+ create(t: Translate): Draft;
23
+ };
24
+ /** Everything the editor knows per core type. A new core type does not compile until it is listed here. */
25
+ export declare const coreSpecs: {
26
+ heading: {
27
+ label: "type.heading";
28
+ group: "content";
29
+ styles: readonly StyleGroup[];
30
+ inline: "text";
31
+ create: (t: Translate) => {
32
+ box: {
33
+ x: number;
34
+ w: number;
35
+ h: number;
36
+ };
37
+ props: {
38
+ text: string;
39
+ level: number;
40
+ };
41
+ style: {
42
+ color: string;
43
+ font: "heading";
44
+ size: number;
45
+ weight: 700;
46
+ align: "left";
47
+ line_height: number;
48
+ };
49
+ };
50
+ };
51
+ text: {
52
+ label: "type.text";
53
+ group: "content";
54
+ styles: readonly StyleGroup[];
55
+ inline: "text";
56
+ create: (t: Translate) => {
57
+ box: {
58
+ x: number;
59
+ w: number;
60
+ h: number;
61
+ };
62
+ props: {
63
+ text: string;
64
+ };
65
+ style: {
66
+ color: string;
67
+ font: "body";
68
+ size: number;
69
+ weight: 400;
70
+ align: "left";
71
+ line_height: number;
72
+ };
73
+ };
74
+ };
75
+ image: {
76
+ label: "type.image";
77
+ group: "content";
78
+ styles: readonly StyleGroup[];
79
+ inline: null;
80
+ create: () => {
81
+ box: {
82
+ x: number;
83
+ w: number;
84
+ h: number;
85
+ };
86
+ props: {
87
+ src: string;
88
+ alt: string;
89
+ };
90
+ style: {
91
+ radius: number;
92
+ object_fit: "cover";
93
+ };
94
+ };
95
+ };
96
+ button: {
97
+ label: "type.button";
98
+ group: "content";
99
+ styles: readonly StyleGroup[];
100
+ inline: "label";
101
+ create: (t: Translate) => {
102
+ box: {
103
+ x: number;
104
+ w: number;
105
+ h: number;
106
+ };
107
+ props: {
108
+ label: string;
109
+ action: {
110
+ type: string;
111
+ value: string;
112
+ };
113
+ };
114
+ style: {
115
+ background: string;
116
+ color: string;
117
+ font: "body";
118
+ size: number;
119
+ weight: 600;
120
+ align: "center";
121
+ radius: number;
122
+ };
123
+ };
124
+ };
125
+ divider: {
126
+ label: "type.divider";
127
+ group: "content";
128
+ styles: readonly StyleGroup[];
129
+ inline: null;
130
+ create: () => {
131
+ box: {
132
+ x: number;
133
+ w: number;
134
+ h: number;
135
+ };
136
+ props: {};
137
+ style: {
138
+ color: string;
139
+ };
140
+ };
141
+ };
142
+ video: {
143
+ label: "type.video";
144
+ group: "content";
145
+ styles: readonly StyleGroup[];
146
+ inline: null;
147
+ create: (t: Translate) => {
148
+ box: {
149
+ x: number;
150
+ w: number;
151
+ h: number;
152
+ };
153
+ props: {
154
+ url: string;
155
+ alt: string;
156
+ };
157
+ style: {
158
+ radius: number;
159
+ };
160
+ };
161
+ };
162
+ shape: {
163
+ label: "type.shape";
164
+ group: "content";
165
+ styles: readonly StyleGroup[];
166
+ inline: null;
167
+ create: () => {
168
+ box: {
169
+ x: number;
170
+ w: number;
171
+ h: number;
172
+ };
173
+ props: {
174
+ shape: "rectangle";
175
+ };
176
+ style: {
177
+ background: string;
178
+ radius: number;
179
+ opacity: number;
180
+ };
181
+ };
182
+ };
183
+ icon: {
184
+ label: "type.icon";
185
+ group: "content";
186
+ styles: readonly StyleGroup[];
187
+ inline: null;
188
+ create: () => {
189
+ box: {
190
+ x: number;
191
+ w: number;
192
+ h: number;
193
+ };
194
+ props: {
195
+ icon: string;
196
+ stroke: number;
197
+ };
198
+ style: {
199
+ color: string;
200
+ };
201
+ };
202
+ };
203
+ navbar: {
204
+ label: "type.navbar";
205
+ group: "content";
206
+ styles: readonly StyleGroup[];
207
+ inline: null;
208
+ create: (t: Translate) => {
209
+ name: MessageKey;
210
+ props: CoreElement["props"];
211
+ style: CoreElement["style"];
212
+ box: {
213
+ x: number;
214
+ w: number;
215
+ h: number;
216
+ };
217
+ };
218
+ };
219
+ input: {
220
+ label: "type.input";
221
+ group: "form";
222
+ styles: readonly StyleGroup[];
223
+ inline: null;
224
+ create: (t: Translate) => Draft;
225
+ };
226
+ textarea: {
227
+ label: "type.textarea";
228
+ group: "form";
229
+ styles: readonly StyleGroup[];
230
+ inline: null;
231
+ create: (t: Translate) => Draft;
232
+ };
233
+ select: {
234
+ label: "type.select";
235
+ group: "form";
236
+ styles: readonly StyleGroup[];
237
+ inline: null;
238
+ create: (t: Translate) => Draft;
239
+ };
240
+ checkbox: {
241
+ label: "type.checkbox";
242
+ group: "form";
243
+ styles: readonly StyleGroup[];
244
+ inline: null;
245
+ create: (t: Translate) => Draft;
246
+ };
247
+ };
248
+ /** Ready-made menus: a starting point, then edited link by link like any element. */
249
+ export declare function navbarPresets(t: Translate): {
250
+ name: MessageKey;
251
+ props: CoreElement['props'];
252
+ style: CoreElement['style'];
253
+ }[];
254
+ /** What an element is to the editor: built in, declared by the app, or from a plugin that is gone. */
255
+ export type ElementKind = {
256
+ kind: 'core';
257
+ element: CoreElement;
258
+ spec: CoreSpec;
259
+ } | {
260
+ kind: 'app';
261
+ element: AppElement;
262
+ spec: ElementSpec;
263
+ } | {
264
+ kind: 'opaque';
265
+ element: Element;
266
+ };
267
+ export declare function kindOf(element: Element, catalog: Catalog): ElementKind;
268
+ /** An element type the palette can add. */
269
+ export type Insertable = {
270
+ kind: 'core';
271
+ type: CoreElementType;
272
+ } | {
273
+ kind: 'app';
274
+ spec: ElementSpec;
275
+ };
276
+ /** A new element placed at `top` design pixels, sized and styled by its type. */
277
+ export declare function createElement(insertable: Insertable, top: number, t: Translate): Element;
278
+ /** A short name for layers: the element's own text when it has some, else its type. */
279
+ export declare function elementName(element: Element, label: string): string;
280
+ export {};
@@ -0,0 +1,74 @@
1
+ import type { Box } from '@skylivellc/lienzo-core';
2
+ /**
3
+ * Layout math of the canvas, in design units: x and w are percent of the
4
+ * frame width, y and h are design pixels. Pure, so the canvas gestures and
5
+ * the panels share one copy and the tests drive it directly.
6
+ */
7
+ export type Handle = 'nw' | 'n' | 'ne' | 'e' | 'se' | 's' | 'sw' | 'w';
8
+ export declare const HANDLES: readonly Handle[];
9
+ export type Alignment = 'left' | 'hcenter' | 'right' | 'top' | 'vmiddle' | 'bottom';
10
+ export declare const ALIGNMENTS: readonly Alignment[];
11
+ /** Guide lines that matched, in design pixels from the frame's left and top edges. */
12
+ export type Guides = {
13
+ x: number[];
14
+ y: number[];
15
+ };
16
+ export declare const clamp: (value: number, min: number, max: number) => number;
17
+ /** Rounds to a grid, 4 design pixels by default, so nothing sits on half a pixel. */
18
+ export declare const snap: (value: number, grid?: number) => number;
19
+ /** Keeps a box inside the ranges a document accepts, with room to bleed off the edges. */
20
+ export declare const clampBox: (box: Box) => Box;
21
+ /**
22
+ * The box after dragging by `delta` design pixels: the whole box when
23
+ * `handle` is null, otherwise the edges that handle owns. x snaps to half a
24
+ * percent and y to the 4px grid.
25
+ */
26
+ export declare function dragBox(start: Box, delta: {
27
+ x: number;
28
+ y: number;
29
+ }, handle: Handle | null, frameWidth: number): Box;
30
+ /** Edges and centers worth aligning to: the frame's, then every other element's. */
31
+ export type Anchors = {
32
+ x: number[];
33
+ y: number[];
34
+ };
35
+ export declare function anchorsOf(others: readonly Box[], frameWidth: number, frameHeight: number): Anchors;
36
+ /**
37
+ * Pulls the box onto nearby anchors, like design tools do, and reports the
38
+ * lines that matched. Moving snaps all three edges per axis; resizing snaps
39
+ * only the edges the handle moves. Thresholds are in the units of each axis.
40
+ */
41
+ export declare function snapToAnchors(box: Box, anchors: Anchors, frameWidth: number, threshold: {
42
+ x: number;
43
+ y: number;
44
+ }, handle: Handle | null): {
45
+ box: Box;
46
+ guides: Guides;
47
+ };
48
+ /** Aligns one box inside its canvas. */
49
+ export declare function alignInCanvas(box: Box, where: Alignment, canvasHeight: number): Box;
50
+ /** Aligns several boxes against the box that encloses all of them. */
51
+ export declare function alignTogether(boxes: readonly Box[], where: Alignment): Box[];
52
+ /**
53
+ * Spreads boxes evenly between the first and the last along one axis.
54
+ * Needs three or more; returns the boxes in their original order.
55
+ */
56
+ export declare function distribute(boxes: readonly Box[], axis: 'x' | 'y'): Box[];
57
+ /** The layer that puts an element above (or below) every other one in its canvas. */
58
+ export declare function frontLayer(others: readonly number[]): number;
59
+ export declare function backLayer(others: readonly number[]): number;
60
+ /** Canvas height that fits its content, with a margin below the lowest element. */
61
+ export declare function fitHeight(boxes: readonly Box[]): number;
62
+ /**
63
+ * A phone layout from the desktop one: elements one below the other in
64
+ * reading order (top to bottom, then left to right), 92% wide, heights scaled
65
+ * with the width so proportions hold. Text never shrinks below its desktop
66
+ * height, since it wraps into more lines.
67
+ */
68
+ export declare function stackForMobile(elements: readonly {
69
+ desktop: Box;
70
+ text: boolean;
71
+ }[], reference: number, mobileWidth: number): {
72
+ boxes: Box[];
73
+ height: number;
74
+ };
@@ -0,0 +1,17 @@
1
+ /**
2
+ * Undo and redo over document snapshots (serialized JSON). Pushing a
3
+ * snapshot equal to the current one is a no-op, so callers can push after
4
+ * every gesture without checking whether anything changed.
5
+ */
6
+ export type History = {
7
+ /** Records a new state. Returns false when it equals the current one. */
8
+ push(snapshot: string): boolean;
9
+ /** The state to restore, or null at the edge of the history. */
10
+ undo(): string | null;
11
+ redo(): string | null;
12
+ /** Forgets everything and starts again from `snapshot` (a page switch or a reload). */
13
+ reset(snapshot: string): void;
14
+ readonly canUndo: boolean;
15
+ readonly canRedo: boolean;
16
+ };
17
+ export declare function createHistory(initial: string, limit?: number): History;
@@ -0,0 +1,5 @@
1
+ /** One stroke of a catalog icon, as core renders it. */
2
+ export type IconNode = readonly [tag: 'path' | 'circle' | 'rect' | 'line', attrs: Readonly<Record<string, string>>];
3
+ /** Lienzo's icon catalog (lucide strokes), the same one public pages draw from. */
4
+ export declare const icons: ReadonlyMap<string, readonly IconNode[]>;
5
+ export declare const ICON_NAMES: readonly string[];
@@ -0,0 +1,29 @@
1
+ import type { Section } from '@skylivellc/lienzo-core';
2
+ import { type MessageKey } from '../i18n/index.ts';
3
+ declare const sections: {
4
+ hero: () => Section;
5
+ features: () => Section;
6
+ about: () => Section;
7
+ cta: () => Section;
8
+ contact: () => Section;
9
+ footer: () => Section;
10
+ };
11
+ export type SectionTemplateKey = keyof typeof sections;
12
+ export declare const SECTION_TEMPLATES: readonly {
13
+ key: SectionTemplateKey;
14
+ name: MessageKey;
15
+ }[];
16
+ declare const pages: {
17
+ readonly full: readonly ["hero", "features", "about", "cta", "footer"];
18
+ readonly simple: readonly ["hero", "features", "contact", "footer"];
19
+ readonly landing: readonly ["hero", "cta", "contact", "footer"];
20
+ };
21
+ export type PageTemplateKey = keyof typeof pages;
22
+ export declare const PAGE_TEMPLATES: readonly {
23
+ key: PageTemplateKey;
24
+ name: MessageKey;
25
+ note: MessageKey;
26
+ }[];
27
+ export declare const buildSectionTemplate: (key: SectionTemplateKey) => Section;
28
+ export declare const buildPageTemplate: (key: PageTemplateKey) => Section[];
29
+ export {};
@@ -0,0 +1,40 @@
1
+ import type { Document, Style, Theme, ThemeToken } from '@skylivellc/lienzo-core';
2
+ import type { MessageKey } from '../i18n/index.ts';
3
+ export declare const THEME_TOKENS: readonly ["primary", "secondary", "background", "surface", "text", "muted"];
4
+ export declare const isThemeToken: (value: unknown) => value is ThemeToken;
5
+ export type Palette = Pick<Theme, ThemeToken>;
6
+ export type Gradient = NonNullable<Style['gradient']>;
7
+ export type GradientPreset = {
8
+ type: 'linear' | 'radial';
9
+ from: ThemeToken;
10
+ to: ThemeToken;
11
+ angle: number;
12
+ };
13
+ /** Ready palettes, so nobody has to pick six colors blind. */
14
+ export declare const PALETTES: readonly {
15
+ name: MessageKey;
16
+ colors: Palette;
17
+ }[];
18
+ /** Google fonts picked so that any pairing looks fine. Notes are message keys `font.<name>`. */
19
+ export declare const FONTS: readonly ["Inter", "Poppins", "Montserrat", "DM Sans", "Work Sans", "Nunito", "Lora", "Playfair Display", "Merriweather", "Source Sans 3"];
20
+ export declare const fontNote: (font: (typeof FONTS)[number]) => MessageKey;
21
+ export declare const MAX_WIDTHS: readonly [1080, 1200, 1320, 1440];
22
+ export declare const widthLabel: (width: (typeof MAX_WIDTHS)[number]) => MessageKey;
23
+ /** Gradients suggested from the palette. */
24
+ export declare const GRADIENT_PRESETS: readonly {
25
+ name: MessageKey;
26
+ gradient: GradientPreset;
27
+ }[];
28
+ /** The CSS color of a token or hex, for swatches in the editor chrome. */
29
+ export declare const swatch: (value: string | null | undefined, theme: Theme) => string;
30
+ /** CSS background of a gradient, for preset swatches. */
31
+ export declare function gradientCss(gradient: Gradient, theme: Theme): string;
32
+ /** The theme token closest to a loose hex color. */
33
+ export declare function nearestToken(value: string, theme: Theme): ThemeToken;
34
+ /**
35
+ * Moves fixed colors (canvas backgrounds, element color and background) to
36
+ * the closest theme token, so the page follows the palette from now on.
37
+ */
38
+ export declare function linkToPalette(document: Document, theme: Theme): void;
39
+ /** Stylesheet URL that loads the theme fonts, the same request the public page makes. */
40
+ export declare function fontsHref(fonts: readonly string[]): string;
@@ -0,0 +1,25 @@
1
+ import { type Action } from '@skylivellc/lienzo-core';
2
+ /**
3
+ * What a click does: a core action or one the app registered, plus the value
4
+ * it needs (a modal, a page, a number...). Used by buttons, menu links and
5
+ * app fields of kind `action`. Emits a whole new action on every change.
6
+ */
7
+ type __VLS_Props = {
8
+ modelValue: Action | null | undefined;
9
+ label: string;
10
+ };
11
+ declare const __VLS_export: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
12
+ commit: () => any;
13
+ "update:modelValue": (action: {
14
+ type: string;
15
+ value: string;
16
+ }) => any;
17
+ }, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{
18
+ onCommit?: (() => any) | undefined;
19
+ "onUpdate:modelValue"?: ((action: {
20
+ type: string;
21
+ value: string;
22
+ }) => any) | undefined;
23
+ }>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
24
+ declare const _default: typeof __VLS_export;
25
+ export default _default;
@@ -0,0 +1,3 @@
1
+ declare const __VLS_export: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
2
+ declare const _default: typeof __VLS_export;
3
+ export default _default;
@@ -0,0 +1,3 @@
1
+ declare const __VLS_export: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
2
+ declare const _default: typeof __VLS_export;
3
+ export default _default;
@@ -0,0 +1,8 @@
1
+ import type { Element } from '@skylivellc/lienzo-core';
2
+ /** Settings of the one selected element: its content, its look, and where it sits. */
3
+ type __VLS_Props = {
4
+ element: Element;
5
+ };
6
+ declare const __VLS_export: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
7
+ declare const _default: typeof __VLS_export;
8
+ export default _default;
@@ -0,0 +1,18 @@
1
+ import type { Field, FieldValue } from '@skylivellc/lienzo-core';
2
+ /**
3
+ * One control for a field the app declared (app element props, site fields,
4
+ * app action values). The control and the value's type follow the field's kind.
5
+ */
6
+ type __VLS_Props = {
7
+ field: Field;
8
+ modelValue: FieldValue | undefined;
9
+ };
10
+ declare const __VLS_export: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
11
+ commit: () => any;
12
+ "update:modelValue": (value: FieldValue) => any;
13
+ }, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{
14
+ onCommit?: (() => any) | undefined;
15
+ "onUpdate:modelValue"?: ((value: FieldValue) => any) | undefined;
16
+ }>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
17
+ declare const _default: typeof __VLS_export;
18
+ export default _default;
@@ -0,0 +1,24 @@
1
+ import { type Gradient } from '../model/theme.ts';
2
+ type __VLS_ModelProps = {
3
+ /** A gradient of an element fill or a section background: presets, two colors, shape and angle. */
4
+ modelValue: Gradient | null | undefined;
5
+ };
6
+ declare const __VLS_export: import("vue").DefineComponent<__VLS_ModelProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
7
+ commit: () => any;
8
+ "update:modelValue": (value: {
9
+ type?: "linear" | "radial" | null | undefined;
10
+ from?: string | null | undefined;
11
+ to?: string | null | undefined;
12
+ angle?: number | null | undefined;
13
+ } | null | undefined) => any;
14
+ }, string, import("vue").PublicProps, Readonly<__VLS_ModelProps> & Readonly<{
15
+ onCommit?: (() => any) | undefined;
16
+ "onUpdate:modelValue"?: ((value: {
17
+ type?: "linear" | "radial" | null | undefined;
18
+ from?: string | null | undefined;
19
+ to?: string | null | undefined;
20
+ angle?: number | null | undefined;
21
+ } | null | undefined) => any) | undefined;
22
+ }>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
23
+ declare const _default: typeof __VLS_export;
24
+ export default _default;
@@ -0,0 +1,8 @@
1
+ import type { Modal } from '@skylivellc/lienzo-core';
2
+ /** Settings of the modal being edited. */
3
+ type __VLS_Props = {
4
+ modal: Modal;
5
+ };
6
+ declare const __VLS_export: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
7
+ declare const _default: typeof __VLS_export;
8
+ export default _default;
@@ -0,0 +1,3 @@
1
+ declare const __VLS_export: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
2
+ declare const _default: typeof __VLS_export;
3
+ export default _default;
@@ -0,0 +1,3 @@
1
+ declare const __VLS_export: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
2
+ declare const _default: typeof __VLS_export;
3
+ export default _default;
@@ -0,0 +1,8 @@
1
+ import type { Section } from '@skylivellc/lienzo-core';
2
+ /** Settings of the selected section. */
3
+ type __VLS_Props = {
4
+ section: Section;
5
+ };
6
+ declare const __VLS_export: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
7
+ declare const _default: typeof __VLS_export;
8
+ export default _default;
@@ -0,0 +1,52 @@
1
+ import type { CoreActionType, Field } from '@skylivellc/lienzo-core';
2
+ /** The value control of each core action. Labels are `action.<type>`; core's own order is the picker's. */
3
+ export declare const CORE_ACTIONS: {
4
+ readonly none: {
5
+ readonly kind: "none";
6
+ };
7
+ readonly whatsapp: {
8
+ readonly kind: "text";
9
+ readonly placeholder: "action.placeholder.whatsapp";
10
+ };
11
+ readonly phone: {
12
+ readonly kind: "text";
13
+ readonly placeholder: "action.placeholder.phone";
14
+ };
15
+ readonly email: {
16
+ readonly kind: "text";
17
+ readonly placeholder: "action.placeholder.email";
18
+ };
19
+ readonly url: {
20
+ readonly kind: "text";
21
+ readonly placeholder: "action.placeholder.url";
22
+ };
23
+ readonly anchor: {
24
+ readonly kind: "anchor";
25
+ };
26
+ readonly modal: {
27
+ readonly kind: "modal";
28
+ };
29
+ readonly submit: {
30
+ readonly kind: "submit";
31
+ };
32
+ readonly page: {
33
+ readonly kind: "page";
34
+ };
35
+ readonly top: {
36
+ readonly kind: "none";
37
+ };
38
+ readonly back: {
39
+ readonly kind: "none";
40
+ };
41
+ readonly step_next: {
42
+ readonly kind: "none";
43
+ };
44
+ readonly step_prev: {
45
+ readonly kind: "none";
46
+ };
47
+ };
48
+ export declare const isCoreAction: (type: string) => type is CoreActionType;
49
+ /** An app action's value is stored as a string in `action.value`; this is its starting value. */
50
+ export declare function defaultActionValue(field: Exclude<Field, {
51
+ kind: 'action';
52
+ }> | null): string;
@@ -0,0 +1,9 @@
1
+ import type { AppElement, ElementSpec } from '@skylivellc/lienzo-core';
2
+ /** An app element's content, one control per field it declares. */
3
+ type __VLS_Props = {
4
+ element: AppElement;
5
+ spec: ElementSpec;
6
+ };
7
+ declare const __VLS_export: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
8
+ declare const _default: typeof __VLS_export;
9
+ export default _default;
@@ -0,0 +1,7 @@
1
+ import type { CoreElement } from '@skylivellc/lienzo-core';
2
+ type __VLS_Props = {
3
+ element: CoreElement;
4
+ };
5
+ declare const __VLS_export: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
6
+ declare const _default: typeof __VLS_export;
7
+ export default _default;
@@ -0,0 +1,8 @@
1
+ import type { CoreElement } from '@skylivellc/lienzo-core';
2
+ /** Form fields: text, long text, dropdown and checkbox. */
3
+ type __VLS_Props = {
4
+ element: CoreElement;
5
+ };
6
+ declare const __VLS_export: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
7
+ declare const _default: typeof __VLS_export;
8
+ export default _default;
@@ -0,0 +1,7 @@
1
+ import type { CoreElement } from '@skylivellc/lienzo-core';
2
+ type __VLS_Props = {
3
+ element: CoreElement;
4
+ };
5
+ declare const __VLS_export: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
6
+ declare const _default: typeof __VLS_export;
7
+ export default _default;