@g1cloud/page-builder-editor 1.0.0-alpha.8 → 1.0.0-alpha.80
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/page-builder-editor.css +385 -0
- package/css/page-builder-viewer.css +195 -0
- package/dist/PageBuilderEditor.vue.d.ts +22 -11
- package/dist/PbHtmlEditorModal-C0MLYY66.js +193 -0
- package/dist/PbPropertyEditorBoolean-c5CNiTpt.js +38 -0
- package/dist/{PbPropertyEditorColor-BonGhf7Z.js → PbPropertyEditorColor-5SJkOBUx.js} +8 -9
- package/dist/{PbPropertyEditorText-BWOKvwD9.js → PbPropertyEditorCssLength-CNHbyz8V.js} +10 -9
- package/dist/PbPropertyEditorHtml-DdQPQqJb.js +62 -0
- package/dist/PbPropertyEditorImage-D0kxh68g.js +106 -0
- package/dist/{PbPropertyEditorMultilineText-bEBZmvFa.js → PbPropertyEditorMultilineText-BRLH4Ayi.js} +28 -27
- package/dist/PbPropertyEditorNumber-B76ArSb5.js +47 -0
- package/dist/{PbPropertyEditorReadonlyText-Dgp_AVOD.js → PbPropertyEditorReadonlyText-BJ5qx69O.js} +6 -6
- package/dist/{PbPropertyEditorSelect-CWedbXJI.js → PbPropertyEditorSelect-B5sfulvx.js} +5 -6
- package/dist/PbPropertyEditorText-DDtYWGlr.js +50 -0
- package/dist/PbPropertyEditorYoutube-BxrZ1nyk.js +40 -0
- package/dist/PbScreenSelectModal-57LXAzjs.js +69 -0
- package/dist/PbWidgetAddModal-uVBBeNVl.js +79 -0
- package/dist/PbYoutubeModal-CU8sClMD.js +73 -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 +16 -1
- package/dist/components/menu/PbToolbar.vue.d.ts +16 -1
- 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 +28 -0
- package/dist/components/modal/PbPartAddModal.vue.d.ts +4 -4
- package/dist/components/modal/PbScreenSelectModal.vue.d.ts +6 -0
- 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 +7 -3
- package/dist/components/part/PbPage.vue.d.ts +5 -5
- package/dist/components/part/PbPageFrame.vue.d.ts +19 -0
- package/dist/components/part/PbSection.vue.d.ts +7 -3
- package/dist/components/part/PbWidget.vue.d.ts +5 -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/{PbPropertyEditorProduct.vue.d.ts → PbPropertyEditorBoolean.vue.d.ts} +4 -4
- package/dist/components/sidebar/property/PbPropertyEditorColor.vue.d.ts +4 -4
- package/dist/components/sidebar/property/PbPropertyEditorCssLength.vue.d.ts +23 -0
- package/dist/components/sidebar/property/PbPropertyEditorHtml.vue.d.ts +4 -4
- package/dist/components/sidebar/property/PbPropertyEditorImage.vue.d.ts +5 -9
- package/dist/components/sidebar/property/PbPropertyEditorMultilineText.vue.d.ts +7 -6
- package/dist/components/sidebar/property/PbPropertyEditorNumber.vue.d.ts +23 -0
- 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 +9 -8
- package/dist/components/sidebar/property/{PbPropertyLocalMarketingPart.vue.d.ts → PbPropertyEditorYoutube.vue.d.ts} +9 -9
- 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/PbPropertyGroupEditorMedia.vue.d.ts +20 -0
- 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 +16 -7
- package/dist/directives/vPartHandler.d.ts +1 -0
- package/dist/{index-CFgXLaTI.js → index-BVTz0PeS.js} +4806 -2151
- package/dist/index.d.ts +6 -0
- package/dist/model/command.d.ts +47 -34
- package/dist/model/context.d.ts +19 -19
- package/dist/model/default-part-property-group.d.ts +4 -0
- package/dist/model/event.d.ts +0 -56
- package/dist/model/model.d.ts +6 -2
- package/dist/model/page-builder-editor.d.ts +39 -10
- package/dist/model/page-builder-util.d.ts +2 -0
- package/dist/model/part-definintion.d.ts +2 -2
- package/dist/model/part-manager.d.ts +2 -1
- package/dist/model/part-property.d.ts +4 -3
- package/dist/model/plugin.d.ts +23 -0
- package/dist/page-builder-editor.js +20 -17
- package/dist/page-builder-editor.umd.cjs +5503 -2460
- package/dist/style.css +377 -1
- package/dist/text/text.d.ts +1 -0
- package/dist/utils/common.d.ts +1 -0
- package/package.json +13 -8
- package/scss/canvas.scss +28 -0
- package/{css/canvas-block.scss → scss/page-block.scss} +15 -3
- package/scss/page-builder-editor.scss +326 -0
- package/scss/page-builder-viewer.scss +1 -0
- package/{css/canvas-page.scss → scss/page-page.scss} +25 -16
- package/{css/canvas-section.scss → scss/page-section.scss} +15 -4
- package/scss/page-widget.scss +66 -0
- package/scss/page.scss +73 -0
- package/{css/property-editor-image.scss → scss/property-editor-html.scss} +5 -4
- package/scss/property-editor-image.scss +17 -0
- package/{css → scss}/property-editor-product.scss +4 -3
- package/scss/property-editor-text.scss +10 -0
- package/{css/property-editor-html.scss → scss/property-editor-youtube.scss} +2 -2
- package/{css → scss}/property-group-editor-background.scss +4 -3
- package/scss/property-group-editor-media.scss +17 -0
- package/css/bluesea.scss +0 -8244
- package/css/canvas-widget.scss +0 -41
- package/css/canvas.scss +0 -147
- package/css/page-builder-editor.scss +0 -265
- package/css/page-builder-viewer.scss +0 -1
- package/css/variable.scss +0 -1
- package/dist/HtmlEditorModal-DDoVYM6n.js +0 -94
- package/dist/PbPartAddModal-DuLpnV4E.js +0 -50
- package/dist/PbPropertyEditorHtml-DfOWZr6S.js +0 -65
- package/dist/PbPropertyEditorImage-Du9R6CBU.js +0 -42
- package/dist/PbPropertyEditorProduct-gzGulWGg.js +0 -49
- package/dist/PbWidgetAddModal-CQvFYzfU.js +0 -55
- package/dist/components/canvas/PbCanvasFrame.vue.d.ts +0 -2
- package/dist/components/modal/HtmlEditorModal.vue.d.ts +0 -23
- /package/{css → scss}/property-editor-color.scss +0 -0
- /package/{css → scss}/property-editor-multiline-text.scss +0 -0
- /package/{css/property-editor-text.scss → scss/property-editor-number.scss} +0 -0
- /package/{css → scss}/property-editor-readonly-text.scss +0 -0
- /package/{css → scss}/property-editor-select.scss +0 -0
- /package/{css → scss}/property-group-editor-border.scss +0 -0
- /package/{css → scss}/property-group-editor-margin.scss +0 -0
- /package/{css → scss}/property-group-editor-padding.scss +0 -0
- /package/{css → scss}/property-group-editor-position.scss +0 -0
- /package/{css → scss}/property-group-editor-size.scss +0 -0
- /package/{css → scss}/property-localpart.scss +0 -0
|
@@ -1,49 +0,0 @@
|
|
|
1
|
-
import { defineComponent, openBlock, createElementBlock, createElementVNode, toDisplayString } from "vue";
|
|
2
|
-
import { useModal } from "@g1cloud/bluesea";
|
|
3
|
-
import { u as usePageBuilderEditor, a as PageBuilderEditorEvent } from "./index-CFgXLaTI.js";
|
|
4
|
-
const _hoisted_1 = { class: "property-editor property-editor-product flex-align-center" };
|
|
5
|
-
const _hoisted_2 = { class: "title" };
|
|
6
|
-
const _hoisted_3 = ["textContent"];
|
|
7
|
-
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
8
|
-
__name: "PbPropertyEditorProduct",
|
|
9
|
-
props: {
|
|
10
|
-
property: {},
|
|
11
|
-
value: {}
|
|
12
|
-
},
|
|
13
|
-
emits: ["update-property-value"],
|
|
14
|
-
setup(__props, { emit: __emit }) {
|
|
15
|
-
const pageBuilder = usePageBuilderEditor();
|
|
16
|
-
useModal();
|
|
17
|
-
const emit = __emit;
|
|
18
|
-
const selectProducts = () => {
|
|
19
|
-
var _a;
|
|
20
|
-
let itemCodes = "";
|
|
21
|
-
const selectedParts = pageBuilder.context.getSelectedParts();
|
|
22
|
-
if (selectedParts && selectedParts.length === 1) {
|
|
23
|
-
itemCodes = ((_a = selectedParts[0].properties) == null ? void 0 : _a.products) || "";
|
|
24
|
-
}
|
|
25
|
-
PageBuilderEditorEvent.emit.requestProducts({
|
|
26
|
-
pageBuilderId: pageBuilder.instanceId,
|
|
27
|
-
itemCodes,
|
|
28
|
-
callback: (products) => {
|
|
29
|
-
emit("update-property-value", { products: products.map((v) => v.itemCode).join(",") });
|
|
30
|
-
}
|
|
31
|
-
});
|
|
32
|
-
};
|
|
33
|
-
return (_ctx, _cache) => {
|
|
34
|
-
return openBlock(), createElementBlock("div", _hoisted_1, [
|
|
35
|
-
createElementVNode("div", _hoisted_2, [
|
|
36
|
-
createElementVNode("label", {
|
|
37
|
-
textContent: toDisplayString(_ctx.property.caption)
|
|
38
|
-
}, null, 8, _hoisted_3)
|
|
39
|
-
]),
|
|
40
|
-
createElementVNode("div", null, [
|
|
41
|
-
createElementVNode("button", { onClick: selectProducts }, "Select Product")
|
|
42
|
-
])
|
|
43
|
-
]);
|
|
44
|
-
};
|
|
45
|
-
}
|
|
46
|
-
});
|
|
47
|
-
export {
|
|
48
|
-
_sfc_main as default
|
|
49
|
-
};
|
|
@@ -1,55 +0,0 @@
|
|
|
1
|
-
import { defineComponent, openBlock, createBlock, unref, withCtx, createElementVNode, createElementBlock, Fragment, renderList, toDisplayString } from "vue";
|
|
2
|
-
import { useModalHandle, BSModalFrame } from "@g1cloud/bluesea";
|
|
3
|
-
const _hoisted_1 = { class: "bs-layout-vertical pb-part-add-modal" };
|
|
4
|
-
const _hoisted_2 = ["textContent"];
|
|
5
|
-
const _hoisted_3 = { class: "bs-layout-horizontal-wrap ml-16 mb-8 gap-8" };
|
|
6
|
-
const _hoisted_4 = ["onClick", "textContent"];
|
|
7
|
-
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
8
|
-
__name: "PbWidgetAddModal",
|
|
9
|
-
props: {
|
|
10
|
-
pageBuilder: {},
|
|
11
|
-
partDefinitionGroups: {}
|
|
12
|
-
},
|
|
13
|
-
emits: ["selectHandler"],
|
|
14
|
-
setup(__props, { emit: __emit }) {
|
|
15
|
-
const emit = __emit;
|
|
16
|
-
const modalHandle = useModalHandle();
|
|
17
|
-
const select = (partDefinition) => {
|
|
18
|
-
emit("selectHandler", partDefinition);
|
|
19
|
-
modalHandle.close();
|
|
20
|
-
};
|
|
21
|
-
return (_ctx, _cache) => {
|
|
22
|
-
return openBlock(), createBlock(unref(BSModalFrame), { title: "Add Block/Widget" }, {
|
|
23
|
-
default: withCtx(() => [
|
|
24
|
-
createElementVNode("div", _hoisted_1, [
|
|
25
|
-
(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.partDefinitionGroups, (group) => {
|
|
26
|
-
return openBlock(), createElementBlock("div", {
|
|
27
|
-
key: group.groupName,
|
|
28
|
-
class: "group mb-16"
|
|
29
|
-
}, [
|
|
30
|
-
createElementVNode("div", {
|
|
31
|
-
class: "mb-8",
|
|
32
|
-
textContent: toDisplayString(group.caption)
|
|
33
|
-
}, null, 8, _hoisted_2),
|
|
34
|
-
createElementVNode("div", _hoisted_3, [
|
|
35
|
-
(openBlock(true), createElementBlock(Fragment, null, renderList(group.partDefinitions, (part) => {
|
|
36
|
-
return openBlock(), createElementBlock("div", {
|
|
37
|
-
key: part.partName,
|
|
38
|
-
class: "part",
|
|
39
|
-
onClick: ($event) => select(part),
|
|
40
|
-
textContent: toDisplayString(part.caption)
|
|
41
|
-
}, null, 8, _hoisted_4);
|
|
42
|
-
}), 128))
|
|
43
|
-
])
|
|
44
|
-
]);
|
|
45
|
-
}), 128))
|
|
46
|
-
])
|
|
47
|
-
]),
|
|
48
|
-
_: 1
|
|
49
|
-
});
|
|
50
|
-
};
|
|
51
|
-
}
|
|
52
|
-
});
|
|
53
|
-
export {
|
|
54
|
-
_sfc_main as default
|
|
55
|
-
};
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
type Html = {
|
|
2
|
-
tags: string;
|
|
3
|
-
style: string;
|
|
4
|
-
};
|
|
5
|
-
declare const _default: import('vue').DefineComponent<__VLS_TypePropsToRuntimeProps<{
|
|
6
|
-
html?: Html | undefined;
|
|
7
|
-
}>, {}, unknown, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
8
|
-
updateHtml: (html: Html) => void;
|
|
9
|
-
}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<__VLS_TypePropsToRuntimeProps<{
|
|
10
|
-
html?: Html | undefined;
|
|
11
|
-
}>>> & {
|
|
12
|
-
onUpdateHtml?: ((html: Html) => any) | undefined;
|
|
13
|
-
}, {}, {}>;
|
|
14
|
-
export default _default;
|
|
15
|
-
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
16
|
-
type __VLS_TypePropsToRuntimeProps<T> = {
|
|
17
|
-
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
18
|
-
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
19
|
-
} : {
|
|
20
|
-
type: import('vue').PropType<T[K]>;
|
|
21
|
-
required: true;
|
|
22
|
-
};
|
|
23
|
-
};
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|