@g1cloud/page-builder-editor 1.0.0-alpha.21 → 1.0.0-alpha.23
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/css/canvas.scss +16 -136
- package/css/{canvas-block.scss → page-block.scss} +15 -3
- package/css/page-builder-editor.scss +6 -14
- package/css/{canvas-page.scss → page-page.scss} +23 -16
- package/css/{canvas-section.scss → page-section.scss} +15 -3
- package/css/{canvas-widget.scss → page-widget.scss} +15 -3
- package/css/page.scss +79 -0
- package/css/property-editor-youtube.scss +16 -0
- package/dist/PageBuilderEditor.vue.d.ts +4 -4
- package/dist/PbHtmlEditorModal-dDR38rNy.js +187 -0
- package/dist/{PbPropertyEditorColor-BFMkFOYX.js → PbPropertyEditorColor-B6yhXmGL.js} +1 -1
- package/dist/{PbPropertyEditorHtml-DZw8qbJH.js → PbPropertyEditorHtml-fgIO3jaY.js} +4 -3
- package/dist/{PbPropertyEditorImage-BQhiQyNM.js → PbPropertyEditorImage-6WNkin_o.js} +3 -3
- package/dist/{PbPropertyEditorMultilineText-CT3vTbYY.js → PbPropertyEditorMultilineText-3hJVRryR.js} +1 -1
- package/dist/{PbPropertyEditorText-DmM_LMjC.js → PbPropertyEditorText-DZA84Sn1.js} +1 -1
- package/dist/PbPropertyEditorYoutube-DtcxO2uZ.js +39 -0
- package/dist/{PbScreenSelectModal-DDATc9n1.js → PbScreenSelectModal-CnI1IsvW.js} +3 -4
- package/dist/{PbWidgetAddModal-BoYfb0dm.js → PbWidgetAddModal-DO1t-xsl.js} +19 -21
- package/dist/PbYoutubeModal-DFb6CQyW.js +68 -0
- package/dist/components/canvas/PbCanvas.vue.d.ts +1 -1
- package/dist/components/depart/PbLoginDepart.vue.d.ts +3 -3
- package/dist/components/menu/PbMenu.vue.d.ts +3 -3
- package/dist/components/menu/PbToolbar.vue.d.ts +3 -3
- package/dist/components/menu/PbToolbarButton.vue.d.ts +3 -3
- package/dist/components/menu/PbToolbarButtonGroup.vue.d.ts +3 -3
- package/dist/components/modal/PbHtmlEditorModal.vue.d.ts +7 -4
- package/dist/components/modal/PbPartAddModal.vue.d.ts +4 -4
- package/dist/components/modal/PbScreenSelectModal.vue.d.ts +2 -2
- package/dist/components/modal/PbWidgetAddModal.vue.d.ts +4 -4
- package/dist/components/modal/PbYoutubeModal.vue.d.ts +19 -0
- package/dist/components/navigator/PbNavigator.vue.d.ts +1 -1
- package/dist/components/part/PbAddWidgetButton.vue.d.ts +1 -1
- package/dist/components/part/PbBlock.vue.d.ts +3 -3
- package/dist/components/part/PbContainerWidget.vue.d.ts +19 -0
- package/dist/components/part/PbPage.vue.d.ts +5 -5
- package/dist/components/part/PbPageFrame.vue.d.ts +21 -0
- package/dist/components/part/PbSection.vue.d.ts +3 -3
- package/dist/components/part/PbWidget.vue.d.ts +3 -3
- package/dist/components/sidebar/PbSidebar.vue.d.ts +1 -1
- package/dist/components/sidebar/PbSidebarProperties.vue.d.ts +1 -1
- package/dist/components/sidebar/PbSidebarPropertyEditor.vue.d.ts +3 -3
- package/dist/components/sidebar/PbSidebarPropertyGroupEditor.vue.d.ts +3 -3
- package/dist/components/sidebar/property/PbPropertyEditorColor.vue.d.ts +4 -4
- package/dist/components/sidebar/property/PbPropertyEditorHtml.vue.d.ts +4 -4
- package/dist/components/sidebar/property/PbPropertyEditorImage.vue.d.ts +7 -6
- package/dist/components/sidebar/property/PbPropertyEditorMultilineText.vue.d.ts +4 -4
- package/dist/components/sidebar/property/PbPropertyEditorReadonlyText.vue.d.ts +3 -3
- package/dist/components/sidebar/property/PbPropertyEditorSelect.vue.d.ts +4 -4
- package/dist/components/sidebar/property/PbPropertyEditorText.vue.d.ts +4 -4
- package/dist/components/sidebar/property/PbPropertyEditorYoutube.vue.d.ts +23 -0
- package/dist/components/sidebar/property/PbPropertyGroupEditorBackground.vue.d.ts +3 -3
- package/dist/components/sidebar/property/PbPropertyGroupEditorBorder.vue.d.ts +3 -3
- package/dist/components/sidebar/property/PbPropertyGroupEditorMargin.vue.d.ts +3 -3
- package/dist/components/sidebar/property/PbPropertyGroupEditorPadding.vue.d.ts +3 -3
- package/dist/components/sidebar/property/PbPropertyGroupEditorPosition.vue.d.ts +3 -3
- package/dist/components/sidebar/property/PbPropertyGroupEditorSize.vue.d.ts +3 -3
- package/dist/components/ui/PbColorPicker.vue.d.ts +20 -7
- package/dist/{index-Cr-_-n9T.js → index-JVyoOgGq.js} +1530 -1262
- package/dist/model/context.d.ts +6 -0
- package/dist/model/default-part-property-group.d.ts +1 -0
- package/dist/model/page-builder-editor.d.ts +4 -0
- package/dist/model/page-builder-util.d.ts +2 -0
- package/dist/model/part-definintion.d.ts +1 -1
- package/dist/model/part-manager.d.ts +2 -0
- package/dist/model/part-property.d.ts +0 -2
- package/dist/page-builder-editor.js +19 -16
- package/dist/page-builder-editor.umd.cjs +1831 -1408
- package/package.json +8 -6
- package/dist/PbHtmlEditorModal-aaecwH7V.js +0 -131
- package/dist/components/canvas/PbCanvasFrame.vue.d.ts +0 -2
package/dist/model/context.d.ts
CHANGED
|
@@ -48,6 +48,8 @@ export declare class PageBuilderContextImpl implements PageBuilderContext {
|
|
|
48
48
|
getProperty: (propertyName: string) => import('@g1cloud/page-builder-viewer').MultiLangText | undefined;
|
|
49
49
|
getClassNames: () => string;
|
|
50
50
|
getStyles: () => Record<string, string>;
|
|
51
|
+
getInlineStyles: () => Record<string, string>;
|
|
52
|
+
getStyleTag: () => string;
|
|
51
53
|
} | undefined;
|
|
52
54
|
getSingleSelectedBlock(): {
|
|
53
55
|
partType: string;
|
|
@@ -66,6 +68,8 @@ export declare class PageBuilderContextImpl implements PageBuilderContext {
|
|
|
66
68
|
getProperty: (propertyName: string) => import('@g1cloud/page-builder-viewer').MultiLangText | undefined;
|
|
67
69
|
getClassNames: () => string;
|
|
68
70
|
getStyles: () => Record<string, string>;
|
|
71
|
+
getInlineStyles: () => Record<string, string>;
|
|
72
|
+
getStyleTag: () => string;
|
|
69
73
|
} | undefined;
|
|
70
74
|
getSingleSelectedSection(): {
|
|
71
75
|
partType: string;
|
|
@@ -84,6 +88,8 @@ export declare class PageBuilderContextImpl implements PageBuilderContext {
|
|
|
84
88
|
getProperty: (propertyName: string) => import('@g1cloud/page-builder-viewer').MultiLangText | undefined;
|
|
85
89
|
getClassNames: () => string;
|
|
86
90
|
getStyles: () => Record<string, string>;
|
|
91
|
+
getInlineStyles: () => Record<string, string>;
|
|
92
|
+
getStyleTag: () => string;
|
|
87
93
|
} | undefined;
|
|
88
94
|
}
|
|
89
95
|
export type ContextMenu = {
|
|
@@ -6,6 +6,7 @@ export declare const marginGroup: () => PartPropertyGroup;
|
|
|
6
6
|
export declare const paddingGroup: () => PartPropertyGroup;
|
|
7
7
|
export declare const commonGroup: () => PartPropertyGroup;
|
|
8
8
|
export declare const layoutGroup: () => PartPropertyGroup;
|
|
9
|
+
export declare const alignGroup: () => PartPropertyGroup;
|
|
9
10
|
export declare const backgroundGroup: () => PartPropertyGroup;
|
|
10
11
|
export declare const borderGroup: () => PartPropertyGroup;
|
|
11
12
|
export declare const defaultPropertyGroups: () => PartPropertyGroup[];
|
|
@@ -24,6 +24,7 @@ export interface PageBuilderEditor extends PageBuilder {
|
|
|
24
24
|
toolButtonRegistry: ToolButtonRegistry;
|
|
25
25
|
title?: string;
|
|
26
26
|
scale: Ref<number>;
|
|
27
|
+
locale: Ref<string>;
|
|
27
28
|
locales: Ref<string[]>;
|
|
28
29
|
registerPlugin(plugin: PageBuilderPlugin): void;
|
|
29
30
|
registerCustomPlugin(plugin: any): void;
|
|
@@ -56,6 +57,8 @@ export declare class PageBuilderEditorImpl implements PageBuilderEditor {
|
|
|
56
57
|
customWidgets: PartDefinition[];
|
|
57
58
|
watchers: Record<string, unknown>;
|
|
58
59
|
providers: Record<string, unknown>;
|
|
60
|
+
externalCssLinks: string[];
|
|
61
|
+
externalCssContent: string;
|
|
59
62
|
constructor();
|
|
60
63
|
getLocale(): string;
|
|
61
64
|
setLocale(locale?: string): void;
|
|
@@ -76,6 +79,7 @@ export declare class PageBuilderEditorImpl implements PageBuilderEditor {
|
|
|
76
79
|
getCustomWidgets(): PartDefinition[];
|
|
77
80
|
extractMedia(part: IPart): string[];
|
|
78
81
|
extractProvider(part: Record<string, unknown>): void;
|
|
82
|
+
getExternalCss(): string;
|
|
79
83
|
private extractMediaFromPart;
|
|
80
84
|
private extractMediaFromHtml;
|
|
81
85
|
private getEmptyPageContent;
|
|
@@ -1,5 +1,7 @@
|
|
|
1
|
+
import { BSModal } from '@g1cloud/bluesea';
|
|
1
2
|
import { IPart, MultiLangText } from '@g1cloud/page-builder-viewer';
|
|
2
3
|
|
|
3
4
|
export declare const getPropertyValueOfParts: (parts: IPart[], propertyName: string) => MultiLangText | undefined;
|
|
4
5
|
export declare const isCursorInElement: (event: MouseEvent, element: Element) => boolean;
|
|
5
6
|
export declare const extractCommonStylesFromProperties: (properties: Record<string, string>) => Record<string, unknown>;
|
|
7
|
+
export declare const selectYoutubeVideo: (modal: BSModal, url?: string, callback?: (url?: string) => void) => void;
|
|
@@ -8,9 +8,9 @@ export type PartDefinition = {
|
|
|
8
8
|
partName: string;
|
|
9
9
|
caption: string;
|
|
10
10
|
icon: string;
|
|
11
|
+
className: string;
|
|
11
12
|
propertyGroups: PartPropertyGroup[];
|
|
12
13
|
initialProperties: Record<string, string>;
|
|
13
|
-
localized: boolean;
|
|
14
14
|
allowsChild: (partOrName?: IPart | string | undefined) => boolean;
|
|
15
15
|
creator: PartCreator;
|
|
16
16
|
component?: Component;
|
|
@@ -17,6 +17,8 @@ export declare class PartManager {
|
|
|
17
17
|
getPropertyDefinition(partName: string, propertyName: string): PartProperty | undefined;
|
|
18
18
|
createPartComponent(part?: IPart): Component | undefined;
|
|
19
19
|
createPartComponents(parts?: IPart[]): PartComponent[];
|
|
20
|
+
getPartClassName(part?: IPart): string | undefined;
|
|
21
|
+
isChildAllowed(part?: IPart): boolean;
|
|
20
22
|
registerPartPropertyGroupEditors(editors: Record<string, PartPropertyGroupEditor>): void;
|
|
21
23
|
getPartPropertyGroupEditor(groupName: string): PartPropertyGroupEditor | undefined;
|
|
22
24
|
registerPartPropertyEditors(editors: Record<PartPropertyType, PartPropertyEditor>): void;
|
|
@@ -9,7 +9,6 @@ export type PartProperty = {
|
|
|
9
9
|
caption: string;
|
|
10
10
|
params?: any;
|
|
11
11
|
propertyEditor?: PartPropertyEditor;
|
|
12
|
-
localized?: boolean;
|
|
13
12
|
multiLang?: boolean;
|
|
14
13
|
};
|
|
15
14
|
export type PartPropertyGroupEditor = (group: PartPropertyGroup, parts: IPart[]) => Component | undefined;
|
|
@@ -19,5 +18,4 @@ export type PartPropertyGroup = {
|
|
|
19
18
|
caption: string;
|
|
20
19
|
showGroupName?: boolean;
|
|
21
20
|
propertyGroupEditor?: PartPropertyGroupEditor;
|
|
22
|
-
localized?: boolean;
|
|
23
21
|
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { B, b, M, c, d, e, _, a, f, g, h, i, j, k, l,
|
|
1
|
+
import { B, b, M, c, d, e, _, a, f, g, h, i, j, k, l, m, n, R, o, S, p, W, q, r, t, v, x, y, z, A, C } from "./index-JVyoOgGq.js";
|
|
2
2
|
export {
|
|
3
3
|
B as BLOCK_TYPE,
|
|
4
4
|
b as Block,
|
|
@@ -10,22 +10,25 @@ export {
|
|
|
10
10
|
a as PageBuilderEditorEvent,
|
|
11
11
|
f as PageBuilderViewer,
|
|
12
12
|
g as Part,
|
|
13
|
-
h as
|
|
14
|
-
i as
|
|
15
|
-
j as
|
|
16
|
-
k as
|
|
17
|
-
l as
|
|
13
|
+
h as PbContainerWidget,
|
|
14
|
+
i as PbCustomWidget,
|
|
15
|
+
j as PbHtmlWidget,
|
|
16
|
+
k as PbIframeWidget,
|
|
17
|
+
l as PbImageWidget,
|
|
18
|
+
m as PbTextWidget,
|
|
19
|
+
n as PbYoutubeWidget,
|
|
18
20
|
R as ROOT_TYPE,
|
|
19
|
-
|
|
21
|
+
o as RootPart,
|
|
20
22
|
S as SECTION_TYPE,
|
|
21
|
-
|
|
23
|
+
p as Section,
|
|
22
24
|
W as WIDGET_TYPE,
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
25
|
+
q as Widget,
|
|
26
|
+
r as createPageBuilderViewer,
|
|
27
|
+
t as createPartComponent,
|
|
28
|
+
v as createPartComponents,
|
|
29
|
+
x as getPartClassName,
|
|
30
|
+
y as providePageBuilder,
|
|
31
|
+
z as providePageBuilderViewer,
|
|
32
|
+
A as usePageBuilder,
|
|
33
|
+
C as usePageBuilderViewer
|
|
31
34
|
};
|