@g1cloud/page-builder-editor 1.0.0-alpha.14 → 1.0.0-alpha.15

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.
@@ -6894,8 +6894,8 @@ var __publicField = (obj, key, value) => {
6894
6894
  this.rootPart = vue.ref(new RootPart());
6895
6895
  }
6896
6896
  };
6897
- const _hoisted_1$8$1 = ["data-model-id"];
6898
- const _hoisted_2$4$1 = {
6897
+ const _hoisted_1$7$1 = ["data-model-id"];
6898
+ const _hoisted_2$3$1 = {
6899
6899
  key: 1,
6900
6900
  class: "pb-nested-widget"
6901
6901
  };
@@ -6921,7 +6921,7 @@ var __publicField = (obj, key, value) => {
6921
6921
  key: 0,
6922
6922
  part: _ctx.part
6923
6923
  }, null, 8, ["part"])) : vue.createCommentVNode("", true),
6924
- childComponents.value && childComponents.value.length > 0 ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_2$4$1, [
6924
+ childComponents.value && childComponents.value.length > 0 ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_2$3$1, [
6925
6925
  (vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(childComponents.value, (child) => {
6926
6926
  return vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(child.component), {
6927
6927
  key: child.part.partId,
@@ -6929,11 +6929,11 @@ var __publicField = (obj, key, value) => {
6929
6929
  }, null, 8, ["part"]);
6930
6930
  }), 128))
6931
6931
  ])) : vue.createCommentVNode("", true)
6932
- ], 16, _hoisted_1$8$1);
6932
+ ], 16, _hoisted_1$7$1);
6933
6933
  };
6934
6934
  }
6935
6935
  });
6936
- const _hoisted_1$7$1 = ["data-model-id"];
6936
+ const _hoisted_1$6$1 = ["data-model-id"];
6937
6937
  const _sfc_main$8$1 = /* @__PURE__ */ vue.defineComponent({
6938
6938
  __name: "PbBlock",
6939
6939
  props: {
@@ -6957,12 +6957,12 @@ var __publicField = (obj, key, value) => {
6957
6957
  part: child
6958
6958
  }, null, 8, ["part"]);
6959
6959
  }), 128))
6960
- ], 16, _hoisted_1$7$1);
6960
+ ], 16, _hoisted_1$6$1);
6961
6961
  };
6962
6962
  }
6963
6963
  });
6964
- const _hoisted_1$6$1 = { class: "pb-block" };
6965
- const _hoisted_2$3$1 = /* @__PURE__ */ vue.createElementVNode("div", {
6964
+ const _hoisted_1$5$1 = { class: "pb-block" };
6965
+ const _hoisted_2$2$1 = /* @__PURE__ */ vue.createElementVNode("div", {
6966
6966
  class: "pb-widget",
6967
6967
  style: { "margin": "0 auto" }
6968
6968
  }, [
@@ -6970,8 +6970,8 @@ var __publicField = (obj, key, value) => {
6970
6970
  /* @__PURE__ */ vue.createElementVNode("h3", null, "Login Design Part")
6971
6971
  ])
6972
6972
  ], -1);
6973
- const _hoisted_3$2$1 = [
6974
- _hoisted_2$3$1
6973
+ const _hoisted_3$1$1 = [
6974
+ _hoisted_2$2$1
6975
6975
  ];
6976
6976
  const _sfc_main$7$1 = /* @__PURE__ */ vue.defineComponent({
6977
6977
  __name: "PbLoginDepart",
@@ -6980,11 +6980,11 @@ var __publicField = (obj, key, value) => {
6980
6980
  },
6981
6981
  setup(__props) {
6982
6982
  return (_ctx, _cache) => {
6983
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$6$1, _hoisted_3$2$1);
6983
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$5$1, _hoisted_3$1$1);
6984
6984
  };
6985
6985
  }
6986
6986
  });
6987
- const _hoisted_1$5$1 = ["data-model-id"];
6987
+ const _hoisted_1$4$1 = ["data-model-id"];
6988
6988
  const _sfc_main$6$1 = /* @__PURE__ */ vue.defineComponent({
6989
6989
  __name: "PbSection",
6990
6990
  props: {
@@ -7010,19 +7010,19 @@ var __publicField = (obj, key, value) => {
7010
7010
  part: block
7011
7011
  }, null, 8, ["part"]);
7012
7012
  }), 128)) : vue.createCommentVNode("", true)
7013
- ], 16, _hoisted_1$5$1);
7013
+ ], 16, _hoisted_1$4$1);
7014
7014
  };
7015
7015
  }
7016
7016
  });
7017
- const _hoisted_1$4$1 = { class: "pb-image-widget" };
7018
- const _hoisted_2$2$1 = ["src"];
7019
- const _hoisted_3$1$1 = {
7017
+ const _hoisted_1$3$1 = { class: "pb-image-widget" };
7018
+ const _hoisted_2$1$1 = ["src"];
7019
+ const _hoisted_3$s = {
7020
7020
  key: 1,
7021
7021
  class: "empty"
7022
7022
  };
7023
- const _hoisted_4$1$1 = /* @__PURE__ */ vue.createElementVNode("span", { class: "font-icon" }, "image", -1);
7024
- const _hoisted_5$1$1 = [
7025
- _hoisted_4$1$1
7023
+ const _hoisted_4$i = /* @__PURE__ */ vue.createElementVNode("span", { class: "font-icon" }, "image", -1);
7024
+ const _hoisted_5$8 = [
7025
+ _hoisted_4$i
7026
7026
  ];
7027
7027
  const _sfc_main$5$1 = /* @__PURE__ */ vue.defineComponent({
7028
7028
  __name: "PbImageWidget",
@@ -7033,18 +7033,18 @@ var __publicField = (obj, key, value) => {
7033
7033
  setup(__props) {
7034
7034
  return (_ctx, _cache) => {
7035
7035
  var _a, _b;
7036
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$4$1, [
7036
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$3$1, [
7037
7037
  ((_a = _ctx.part.properties) == null ? void 0 : _a.image) ? (vue.openBlock(), vue.createElementBlock("img", {
7038
7038
  key: 0,
7039
7039
  src: (_b = _ctx.part.properties) == null ? void 0 : _b.image,
7040
7040
  alt: "",
7041
7041
  class: "image"
7042
- }, null, 8, _hoisted_2$2$1)) : !_ctx.viewMode ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_3$1$1, _hoisted_5$1$1)) : vue.createCommentVNode("", true)
7042
+ }, null, 8, _hoisted_2$1$1)) : !_ctx.viewMode ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_3$s, _hoisted_5$8)) : vue.createCommentVNode("", true)
7043
7043
  ]);
7044
7044
  };
7045
7045
  }
7046
7046
  });
7047
- const _hoisted_1$3$1 = ["textContent"];
7047
+ const _hoisted_1$2$1 = ["textContent"];
7048
7048
  const _sfc_main$4$1 = /* @__PURE__ */ vue.defineComponent({
7049
7049
  __name: "PbTextWidget",
7050
7050
  props: {
@@ -7106,13 +7106,13 @@ var __publicField = (obj, key, value) => {
7106
7106
  }, [
7107
7107
  vue.createElementVNode("div", vue.mergeProps({ class: "text" }, style.value, {
7108
7108
  textContent: vue.toDisplayString(text.value)
7109
- }), null, 16, _hoisted_1$3$1)
7109
+ }), null, 16, _hoisted_1$2$1)
7110
7110
  ], 2);
7111
7111
  };
7112
7112
  }
7113
7113
  });
7114
- const _hoisted_1$2$1 = ["innerHTML"];
7115
- const _hoisted_2$1$1 = { key: 1 };
7114
+ const _hoisted_1$1$1 = ["innerHTML"];
7115
+ const _hoisted_2$v = { key: 1 };
7116
7116
  const _sfc_main$3$1 = /* @__PURE__ */ vue.defineComponent({
7117
7117
  __name: "PbHtmlWidget",
7118
7118
  props: {
@@ -7159,112 +7159,12 @@ ${_html.style}
7159
7159
  key: 0,
7160
7160
  class: "html",
7161
7161
  innerHTML: html.value
7162
- }, null, 8, _hoisted_1$2$1)) : (vue.openBlock(), vue.createElementBlock("span", _hoisted_2$1$1, "Empty HTML"))
7162
+ }, null, 8, _hoisted_1$1$1)) : (vue.openBlock(), vue.createElementBlock("span", _hoisted_2$v, "Empty HTML"))
7163
7163
  ], 2);
7164
7164
  };
7165
7165
  }
7166
7166
  });
7167
- function mitt(n) {
7168
- return { all: n = n || /* @__PURE__ */ new Map(), on: function(t, e) {
7169
- var i = n.get(t);
7170
- i ? i.push(e) : n.set(t, [e]);
7171
- }, off: function(t, e) {
7172
- var i = n.get(t);
7173
- i && (e ? i.splice(i.indexOf(e) >>> 0, 1) : n.set(t, []));
7174
- }, emit: function(t, e) {
7175
- var i = n.get(t);
7176
- i && i.slice().map(function(n2) {
7177
- n2(e);
7178
- }), (i = n.get("*")) && i.slice().map(function(n2) {
7179
- n2(t, e);
7180
- });
7181
- } };
7182
- }
7183
- const emitter = mitt();
7184
- const PageBuilderViewerEvent = {
7185
- on: {
7186
- requestProductMapping: (listener) => {
7187
- emitter.on("requestProductMapping", listener);
7188
- }
7189
- },
7190
- off: {
7191
- requestProductMapping: (listener) => {
7192
- emitter.off("requestProductMapping", listener);
7193
- }
7194
- },
7195
- emit: {
7196
- requestProductMapping: (param) => {
7197
- emitter.emit("requestProductMapping", param);
7198
- }
7199
- }
7200
- };
7201
- const _hoisted_1$1$1 = { class: "pb-product-list-widget" };
7202
- const _hoisted_2$w = { class: "product" };
7203
- const _hoisted_3$t = { class: "image" };
7204
- const _hoisted_4$i = ["src"];
7205
- const _hoisted_5$8 = { class: "name" };
7206
- const _hoisted_6$7 = { class: "price" };
7207
- const _hoisted_7$6 = {
7208
- key: 1,
7209
- class: "empty"
7210
- };
7211
- const _hoisted_8$6 = /* @__PURE__ */ vue.createElementVNode("span", { class: "font-icon" }, "image", -1);
7212
- const _hoisted_9$6 = [
7213
- _hoisted_8$6
7214
- ];
7215
- const _sfc_main$2$1 = /* @__PURE__ */ vue.defineComponent({
7216
- __name: "PbProductListWidget",
7217
- props: {
7218
- part: {},
7219
- viewMode: { type: Boolean, default: false }
7220
- },
7221
- setup(__props) {
7222
- const props = __props;
7223
- const products = vue.ref([]);
7224
- const productCount = vue.computed(() => props.viewMode ? products.value.length : Math.max(4, products.value.length));
7225
- const updateProducts = () => {
7226
- var _a, _b;
7227
- if ((_a = props.part.properties) == null ? void 0 : _a.products) {
7228
- PageBuilderViewerEvent.emit.requestProductMapping({
7229
- pageBuilderId: props.part.getPageBuilderId(),
7230
- itemCodes: (_b = props.part.properties) == null ? void 0 : _b.products,
7231
- callback: (_products) => {
7232
- products.value = _products;
7233
- }
7234
- });
7235
- }
7236
- };
7237
- vue.onMounted(() => updateProducts());
7238
- vue.watch(() => {
7239
- var _a;
7240
- return (_a = props.part.properties) == null ? void 0 : _a.products;
7241
- }, () => updateProducts());
7242
- return (_ctx, _cache) => {
7243
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$1$1, [
7244
- products.value ? (vue.openBlock(true), vue.createElementBlock(vue.Fragment, { key: 0 }, vue.renderList(productCount.value, (index) => {
7245
- return vue.openBlock(), vue.createElementBlock("div", {
7246
- key: index,
7247
- class: "product-wrapper"
7248
- }, [
7249
- vue.createElementVNode("div", _hoisted_2$w, [
7250
- products.value[index - 1] ? (vue.openBlock(), vue.createElementBlock(vue.Fragment, { key: 0 }, [
7251
- vue.createElementVNode("div", _hoisted_3$t, [
7252
- vue.createElementVNode("img", {
7253
- src: products.value[index - 1].image,
7254
- alt: ""
7255
- }, null, 8, _hoisted_4$i)
7256
- ]),
7257
- vue.createElementVNode("div", _hoisted_5$8, vue.toDisplayString(products.value[index - 1].itemName), 1),
7258
- vue.createElementVNode("div", _hoisted_6$7, vue.toDisplayString(products.value[index - 1].price), 1)
7259
- ], 64)) : (vue.openBlock(), vue.createElementBlock("div", _hoisted_7$6, _hoisted_9$6))
7260
- ])
7261
- ]);
7262
- }), 128)) : vue.createCommentVNode("", true)
7263
- ]);
7264
- };
7265
- }
7266
- });
7267
- const partDefinitions$1 = {
7167
+ const defaultPartDefinitions = {
7268
7168
  "Section": {
7269
7169
  partType: "Section",
7270
7170
  partName: "Section",
@@ -7304,15 +7204,11 @@ ${_html.style}
7304
7204
  partType: "Widget",
7305
7205
  partName: "HtmlWidget",
7306
7206
  creator: () => _sfc_main$3$1
7307
- },
7308
- "ProductListWidget": {
7309
- partType: "Widget",
7310
- partName: "ProductListWidget",
7311
- creator: () => _sfc_main$2$1
7312
7207
  }
7313
7208
  };
7314
7209
  const PAGE_BUILDER_KEY = "PageBuilder";
7315
7210
  const PAGE_BUILDER_VIEWER_KEY = "PageBuilderViewer";
7211
+ let partDefinitions$1 = { ...defaultPartDefinitions };
7316
7212
  class PageBuilderViewerImpl {
7317
7213
  constructor() {
7318
7214
  __publicField2(this, "instanceId");
@@ -7326,6 +7222,18 @@ ${_html.style}
7326
7222
  setLocale(locale) {
7327
7223
  this.locale.value = locale || "en";
7328
7224
  }
7225
+ registerCustomPlugin(plugin) {
7226
+ if (plugin.widgets) {
7227
+ plugin.widgets.forEach((v) => {
7228
+ partDefinitions$1[v.partName] = {
7229
+ partType: "Widget",
7230
+ partName: v.partName,
7231
+ creator: () => _sfc_main$B,
7232
+ component: v.component
7233
+ };
7234
+ });
7235
+ }
7236
+ }
7329
7237
  render(pageContent) {
7330
7238
  const rootPart = new RootPart();
7331
7239
  rootPart.pageBuilderId = this.instanceId;
@@ -7367,6 +7275,12 @@ ${_html.style}
7367
7275
  return new Widget();
7368
7276
  }
7369
7277
  }
7278
+ getCustomWidgetComponent(part) {
7279
+ const def = getPartDefinition(part.partName);
7280
+ if (def) {
7281
+ return def.component;
7282
+ }
7283
+ }
7370
7284
  }
7371
7285
  const createPageBuilderViewer = () => {
7372
7286
  const viewer = new PageBuilderViewerImpl();
@@ -7405,7 +7319,7 @@ ${_html.style}
7405
7319
  }
7406
7320
  };
7407
7321
  const getPartDefinition = (partName) => partDefinitions$1[partName];
7408
- const _sfc_main$1$1 = /* @__PURE__ */ vue.defineComponent({
7322
+ const _sfc_main$2$1 = /* @__PURE__ */ vue.defineComponent({
7409
7323
  __name: "PbPage",
7410
7324
  props: {
7411
7325
  page: {},
@@ -7434,20 +7348,23 @@ ${_html.style}
7434
7348
  };
7435
7349
  }
7436
7350
  });
7437
- const _hoisted_1$G = { class: "pb-viewer" };
7438
- const _sfc_main$C = /* @__PURE__ */ vue.defineComponent({
7351
+ const _hoisted_1$F = { class: "pb-viewer" };
7352
+ const _sfc_main$1$1 = /* @__PURE__ */ vue.defineComponent({
7439
7353
  __name: "PageBuilderViewer",
7440
7354
  props: {
7441
7355
  instanceId: {},
7442
7356
  pageContent: {},
7443
7357
  isMobilePage: { type: Boolean },
7444
- language: {}
7358
+ language: {},
7359
+ plugin: {}
7445
7360
  },
7446
7361
  setup(__props) {
7447
7362
  const props = __props;
7448
7363
  const pageBuilderViewer = createPageBuilderViewer();
7449
7364
  pageBuilderViewer.instanceId = props.instanceId;
7450
7365
  pageBuilderViewer.setLocale(props.language);
7366
+ if (props.plugin)
7367
+ pageBuilderViewer.registerCustomPlugin(props.plugin);
7451
7368
  providePageBuilderViewer(pageBuilderViewer);
7452
7369
  providePageBuilder(pageBuilderViewer);
7453
7370
  const page = vue.computed(() => pageBuilderViewer.model.rootPart.value.children && pageBuilderViewer.model.rootPart.value.children[props.isMobilePage ? 0 : 1]);
@@ -7465,8 +7382,8 @@ ${_html.style}
7465
7382
  }
7466
7383
  );
7467
7384
  return (_ctx, _cache) => {
7468
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$G, [
7469
- page.value ? (vue.openBlock(), vue.createBlock(_sfc_main$1$1, {
7385
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$F, [
7386
+ page.value ? (vue.openBlock(), vue.createBlock(_sfc_main$2$1, {
7470
7387
  key: 0,
7471
7388
  "is-mobile-page": _ctx.isMobilePage,
7472
7389
  page: page.value
@@ -7475,6 +7392,60 @@ ${_html.style}
7475
7392
  };
7476
7393
  }
7477
7394
  });
7395
+ const _sfc_main$B = /* @__PURE__ */ vue.defineComponent({
7396
+ __name: "PbCustomWidget",
7397
+ props: {
7398
+ part: {},
7399
+ viewMode: { type: Boolean, default: false }
7400
+ },
7401
+ setup(__props) {
7402
+ const props = __props;
7403
+ const pageBuilder = usePageBuilder();
7404
+ const comp = vue.computed(() => pageBuilder.getCustomWidgetComponent(props.part));
7405
+ const bind = vue.computed(() => ({
7406
+ pageBuilderId: pageBuilder.instanceId,
7407
+ properties: props.part.properties,
7408
+ placeholder: true
7409
+ }));
7410
+ return (_ctx, _cache) => {
7411
+ return comp.value ? (vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(comp.value), vue.normalizeProps(vue.mergeProps({ key: 0 }, bind.value)), null, 16)) : vue.createCommentVNode("", true);
7412
+ };
7413
+ }
7414
+ });
7415
+ function mitt(n) {
7416
+ return { all: n = n || /* @__PURE__ */ new Map(), on: function(t, e) {
7417
+ var i = n.get(t);
7418
+ i ? i.push(e) : n.set(t, [e]);
7419
+ }, off: function(t, e) {
7420
+ var i = n.get(t);
7421
+ i && (e ? i.splice(i.indexOf(e) >>> 0, 1) : n.set(t, []));
7422
+ }, emit: function(t, e) {
7423
+ var i = n.get(t);
7424
+ i && i.slice().map(function(n2) {
7425
+ n2(e);
7426
+ }), (i = n.get("*")) && i.slice().map(function(n2) {
7427
+ n2(t, e);
7428
+ });
7429
+ } };
7430
+ }
7431
+ const emitter = mitt();
7432
+ const PageBuilderViewerEvent = {
7433
+ on: {
7434
+ requestProductMapping: (listener) => {
7435
+ emitter.on("requestProductMapping", listener);
7436
+ }
7437
+ },
7438
+ off: {
7439
+ requestProductMapping: (listener) => {
7440
+ emitter.off("requestProductMapping", listener);
7441
+ }
7442
+ },
7443
+ emit: {
7444
+ requestProductMapping: (param) => {
7445
+ emitter.emit("requestProductMapping", param);
7446
+ }
7447
+ }
7448
+ };
7478
7449
  const PART_ID_KEY = "partId";
7479
7450
  const PART_NAME_KEY = "partName";
7480
7451
  const RESERVED_ATTRIBUTES = [PART_ID_KEY, PART_NAME_KEY];
@@ -8064,8 +8035,7 @@ ${_html.style}
8064
8035
  "select": () => vue.defineAsyncComponent(() => Promise.resolve().then(() => PbPropertyEditorSelect)),
8065
8036
  "color": () => vue.defineAsyncComponent(() => Promise.resolve().then(() => PbPropertyEditorColor)),
8066
8037
  "image": () => vue.defineAsyncComponent(() => Promise.resolve().then(() => PbPropertyEditorImage)),
8067
- "html": () => vue.defineAsyncComponent(() => Promise.resolve().then(() => PbPropertyEditorHtml)),
8068
- "product": () => vue.defineAsyncComponent(() => Promise.resolve().then(() => PbPropertyEditorProduct))
8038
+ "html": () => vue.defineAsyncComponent(() => Promise.resolve().then(() => PbPropertyEditorHtml))
8069
8039
  };
8070
8040
  };
8071
8041
  const getPropertyValueOfParts = (parts, propertyName) => {
@@ -8295,22 +8265,22 @@ ${_html.style}
8295
8265
  }
8296
8266
  return target;
8297
8267
  };
8298
- const _sfc_main$B = {};
8299
- const _hoisted_1$F = { class: "pb-add-widget-button" };
8300
- const _hoisted_2$v = /* @__PURE__ */ vue.createElementVNode("span", { class: "icon material-icons-outlined" }, "add_box", -1);
8301
- const _hoisted_3$s = /* @__PURE__ */ vue.createElementVNode("span", { class: "text" }, "Add Widget", -1);
8268
+ const _sfc_main$A = {};
8269
+ const _hoisted_1$E = { class: "pb-add-widget-button" };
8270
+ const _hoisted_2$u = /* @__PURE__ */ vue.createElementVNode("span", { class: "icon material-icons-outlined" }, "add_box", -1);
8271
+ const _hoisted_3$r = /* @__PURE__ */ vue.createElementVNode("span", { class: "text" }, "Add Widget", -1);
8302
8272
  const _hoisted_4$h = [
8303
- _hoisted_2$v,
8304
- _hoisted_3$s
8273
+ _hoisted_2$u,
8274
+ _hoisted_3$r
8305
8275
  ];
8306
8276
  function _sfc_render$1(_ctx, _cache) {
8307
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$F, [
8277
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$E, [
8308
8278
  vue.createElementVNode("button", {
8309
8279
  onClick: _cache[0] || (_cache[0] = ($event) => _ctx.$emit("add-widget", $event))
8310
8280
  }, _hoisted_4$h)
8311
8281
  ]);
8312
8282
  }
8313
- const PbAddWidgetButton = /* @__PURE__ */ _export_sfc(_sfc_main$B, [["render", _sfc_render$1]]);
8283
+ const PbAddWidgetButton = /* @__PURE__ */ _export_sfc(_sfc_main$A, [["render", _sfc_render$1]]);
8314
8284
  const MOUSE_TRACKER_KEY = "mouseTracker";
8315
8285
  const MOUSE_TRACKER_NOT_FOUND = "MouseTracker not found";
8316
8286
  class MouseTracker {
@@ -8341,12 +8311,12 @@ ${_html.style}
8341
8311
  throw Error(MOUSE_TRACKER_NOT_FOUND);
8342
8312
  return mouseTracker;
8343
8313
  };
8344
- const _hoisted_1$E = ["data-model-id", "draggable"];
8345
- const _hoisted_2$u = {
8314
+ const _hoisted_1$D = ["data-model-id", "draggable"];
8315
+ const _hoisted_2$t = {
8346
8316
  key: 1,
8347
8317
  class: "children"
8348
8318
  };
8349
- const _sfc_main$A = /* @__PURE__ */ vue.defineComponent({
8319
+ const _sfc_main$z = /* @__PURE__ */ vue.defineComponent({
8350
8320
  __name: "PbWidget",
8351
8321
  props: {
8352
8322
  part: {}
@@ -8792,7 +8762,7 @@ ${_html.style}
8792
8762
  key: 0,
8793
8763
  part: _ctx.part
8794
8764
  }, null, 8, ["part"])) : vue.createCommentVNode("", true),
8795
- childComponents.value && childComponents.value.length > 0 ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_2$u, [
8765
+ childComponents.value && childComponents.value.length > 0 ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_2$t, [
8796
8766
  (vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(childComponents.value, (child) => {
8797
8767
  return vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(child.component), {
8798
8768
  key: child.part.partId,
@@ -8810,14 +8780,14 @@ ${_html.style}
8810
8780
  class: "resize-handle",
8811
8781
  onMousedown: _resize_mousedown
8812
8782
  }, null, 32)) : vue.createCommentVNode("", true)
8813
- ], 16, _hoisted_1$E)), [
8783
+ ], 16, _hoisted_1$D)), [
8814
8784
  [vue.unref(vPartHandler), { pageBuilder: vue.unref(pageBuilder), part: _ctx.part, droppable: true, locatePositionMark, calculateDropIndex, acceptChildPart }]
8815
8785
  ]);
8816
8786
  };
8817
8787
  }
8818
8788
  });
8819
- const _hoisted_1$D = ["data-model-id"];
8820
- const _sfc_main$z = /* @__PURE__ */ vue.defineComponent({
8789
+ const _hoisted_1$C = ["data-model-id"];
8790
+ const _sfc_main$y = /* @__PURE__ */ vue.defineComponent({
8821
8791
  __name: "PbBlock",
8822
8792
  props: {
8823
8793
  part: {}
@@ -9007,19 +8977,19 @@ ${_html.style}
9007
8977
  onAddWidget: addWidget
9008
8978
  })) : vue.createCommentVNode("", true),
9009
8979
  (vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(_ctx.part.children, (child) => {
9010
- return vue.openBlock(), vue.createBlock(_sfc_main$A, {
8980
+ return vue.openBlock(), vue.createBlock(_sfc_main$z, {
9011
8981
  key: child.partId,
9012
8982
  part: child
9013
8983
  }, null, 8, ["part"]);
9014
8984
  }), 128))
9015
- ], 16, _hoisted_1$D)), [
8985
+ ], 16, _hoisted_1$C)), [
9016
8986
  [vue.unref(vPartHandler), { pageBuilder: vue.unref(pageBuilder), part: _ctx.part, droppable: true, locatePositionMark, calculateDropIndex, acceptChildPart }]
9017
8987
  ]);
9018
8988
  };
9019
8989
  }
9020
8990
  });
9021
- const _hoisted_1$C = { class: "pb-block" };
9022
- const _hoisted_2$t = /* @__PURE__ */ vue.createElementVNode("div", {
8991
+ const _hoisted_1$B = { class: "pb-block" };
8992
+ const _hoisted_2$s = /* @__PURE__ */ vue.createElementVNode("div", {
9023
8993
  class: "pb-widget",
9024
8994
  style: { "margin": "0 auto" }
9025
8995
  }, [
@@ -9027,22 +8997,22 @@ ${_html.style}
9027
8997
  /* @__PURE__ */ vue.createElementVNode("h3", null, "Login Design Part")
9028
8998
  ])
9029
8999
  ], -1);
9030
- const _hoisted_3$r = [
9031
- _hoisted_2$t
9000
+ const _hoisted_3$q = [
9001
+ _hoisted_2$s
9032
9002
  ];
9033
- const _sfc_main$y = /* @__PURE__ */ vue.defineComponent({
9003
+ const _sfc_main$x = /* @__PURE__ */ vue.defineComponent({
9034
9004
  __name: "PbLoginDepart",
9035
9005
  props: {
9036
9006
  part: {}
9037
9007
  },
9038
9008
  setup(__props) {
9039
9009
  return (_ctx, _cache) => {
9040
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$C, _hoisted_3$r);
9010
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$B, _hoisted_3$q);
9041
9011
  };
9042
9012
  }
9043
9013
  });
9044
- const _hoisted_1$B = ["data-model-id"];
9045
- const _sfc_main$x = /* @__PURE__ */ vue.defineComponent({
9014
+ const _hoisted_1$A = ["data-model-id"];
9015
+ const _sfc_main$w = /* @__PURE__ */ vue.defineComponent({
9046
9016
  __name: "PbSection",
9047
9017
  props: {
9048
9018
  part: {}
@@ -9153,13 +9123,13 @@ ${_html.style}
9153
9123
  style: (_a = _ctx.part.properties) == null ? void 0 : _a.css
9154
9124
  }, properties.value), [
9155
9125
  ((_b = _ctx.part.properties) == null ? void 0 : _b.sectionType) === "static" ? (vue.openBlock(), vue.createElementBlock(vue.Fragment, { key: 0 }, [
9156
- ((_c = _ctx.part.properties) == null ? void 0 : _c.name) === "Login Design Part" ? (vue.openBlock(), vue.createBlock(_sfc_main$y, {
9126
+ ((_c = _ctx.part.properties) == null ? void 0 : _c.name) === "Login Design Part" ? (vue.openBlock(), vue.createBlock(_sfc_main$x, {
9157
9127
  key: 0,
9158
9128
  part: _ctx.part
9159
9129
  }, null, 8, ["part"])) : vue.createCommentVNode("", true)
9160
9130
  ], 64)) : (vue.openBlock(), vue.createElementBlock(vue.Fragment, { key: 1 }, [
9161
9131
  _ctx.part.children && _ctx.part.children.length > 0 ? (vue.openBlock(true), vue.createElementBlock(vue.Fragment, { key: 0 }, vue.renderList(_ctx.part.children, (block) => {
9162
- return vue.openBlock(), vue.createBlock(_sfc_main$z, {
9132
+ return vue.openBlock(), vue.createBlock(_sfc_main$y, {
9163
9133
  key: block.partId,
9164
9134
  part: block
9165
9135
  }, null, 8, ["part"]);
@@ -9168,15 +9138,15 @@ ${_html.style}
9168
9138
  onAddWidget: addWidget
9169
9139
  }))
9170
9140
  ], 64))
9171
- ], 16, _hoisted_1$B)), [
9141
+ ], 16, _hoisted_1$A)), [
9172
9142
  [vue.unref(vPartHandler), { pageBuilder: vue.unref(pageBuilder), part: _ctx.part, droppable: true, locatePositionMark, calculateDropIndex, acceptChildPart }]
9173
9143
  ]);
9174
9144
  };
9175
9145
  }
9176
9146
  });
9177
- const _hoisted_1$A = { class: "group-editor group-editor-position" };
9178
- const _hoisted_2$s = { class: "flex-align-center" };
9179
- const _hoisted_3$q = /* @__PURE__ */ vue.createElementVNode("div", { class: "title" }, [
9147
+ const _hoisted_1$z = { class: "group-editor group-editor-position" };
9148
+ const _hoisted_2$r = { class: "flex-align-center" };
9149
+ const _hoisted_3$p = /* @__PURE__ */ vue.createElementVNode("div", { class: "title" }, [
9180
9150
  /* @__PURE__ */ vue.createElementVNode("label", { textContent: "Position" })
9181
9151
  ], -1);
9182
9152
  const _hoisted_4$g = { class: "flex-grow-1" };
@@ -9190,7 +9160,7 @@ ${_html.style}
9190
9160
  /* @__PURE__ */ vue.createElementVNode("span", { class: "font-icon" }, "add")
9191
9161
  ], -1);
9192
9162
  const _hoisted_9$5 = { class: "text-center" };
9193
- const _sfc_main$w = /* @__PURE__ */ vue.defineComponent({
9163
+ const _sfc_main$v = /* @__PURE__ */ vue.defineComponent({
9194
9164
  __name: "PbPropertyGroupEditorPosition",
9195
9165
  props: {
9196
9166
  group: {},
@@ -9214,9 +9184,9 @@ ${_html.style}
9214
9184
  const updateTop = (value) => updatePropertyValue({ top: value });
9215
9185
  const updateBottom = (value) => updatePropertyValue({ bottom: value });
9216
9186
  return (_ctx, _cache) => {
9217
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$A, [
9218
- vue.createElementVNode("div", _hoisted_2$s, [
9219
- _hoisted_3$q,
9187
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$z, [
9188
+ vue.createElementVNode("div", _hoisted_2$r, [
9189
+ _hoisted_3$p,
9220
9190
  vue.createElementVNode("div", _hoisted_4$g, [
9221
9191
  vue.createElementVNode("div", _hoisted_5$7, [
9222
9192
  vue.createElementVNode("div", _hoisted_6$6, [
@@ -9261,13 +9231,13 @@ ${_html.style}
9261
9231
  };
9262
9232
  }
9263
9233
  });
9264
- const _hoisted_1$z = { class: "group-editor group-editor-size" };
9265
- const _hoisted_2$r = { class: "flex-align-center" };
9266
- const _hoisted_3$p = /* @__PURE__ */ vue.createElementVNode("div", { class: "title" }, [
9234
+ const _hoisted_1$y = { class: "group-editor group-editor-size" };
9235
+ const _hoisted_2$q = { class: "flex-align-center" };
9236
+ const _hoisted_3$o = /* @__PURE__ */ vue.createElementVNode("div", { class: "title" }, [
9267
9237
  /* @__PURE__ */ vue.createElementVNode("label", { textContent: "Size" })
9268
9238
  ], -1);
9269
9239
  const _hoisted_4$f = { class: "flex-grow-1 bs-layout-horizontal" };
9270
- const _sfc_main$v = /* @__PURE__ */ vue.defineComponent({
9240
+ const _sfc_main$u = /* @__PURE__ */ vue.defineComponent({
9271
9241
  __name: "PbPropertyGroupEditorSize",
9272
9242
  props: {
9273
9243
  group: {},
@@ -9287,9 +9257,9 @@ ${_html.style}
9287
9257
  const updateWidth = (value) => updatePropertyValue({ width: value });
9288
9258
  const updateHeight = (value) => updatePropertyValue({ height: value });
9289
9259
  return (_ctx, _cache) => {
9290
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$z, [
9291
- vue.createElementVNode("div", _hoisted_2$r, [
9292
- _hoisted_3$p,
9260
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$y, [
9261
+ vue.createElementVNode("div", _hoisted_2$q, [
9262
+ _hoisted_3$o,
9293
9263
  vue.createElementVNode("div", _hoisted_4$f, [
9294
9264
  vue.createVNode(vue.unref(bluesea.BSTextInput), {
9295
9265
  "model-value": width.value,
@@ -9466,9 +9436,9 @@ ${_html.style}
9466
9436
  }
9467
9437
  }
9468
9438
  };
9469
- const _hoisted_1$y = { class: "vc-alpha" };
9470
- const _hoisted_2$q = { class: "vc-alpha-checkboard-wrap" };
9471
- const _hoisted_3$o = /* @__PURE__ */ vue.createElementVNode(
9439
+ const _hoisted_1$x = { class: "vc-alpha" };
9440
+ const _hoisted_2$p = { class: "vc-alpha-checkboard-wrap" };
9441
+ const _hoisted_3$n = /* @__PURE__ */ vue.createElementVNode(
9472
9442
  "div",
9473
9443
  { class: "vc-alpha-picker" },
9474
9444
  null,
@@ -9476,12 +9446,12 @@ ${_html.style}
9476
9446
  /* HOISTED */
9477
9447
  );
9478
9448
  const _hoisted_4$e = [
9479
- _hoisted_3$o
9449
+ _hoisted_3$n
9480
9450
  ];
9481
9451
  function render$4(_ctx, _cache, $props, $setup, $data, $options) {
9482
9452
  const _component_Checkboard = vue.resolveComponent("Checkboard");
9483
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$y, [
9484
- vue.createElementVNode("div", _hoisted_2$q, [
9453
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$x, [
9454
+ vue.createElementVNode("div", _hoisted_2$p, [
9485
9455
  vue.createVNode(_component_Checkboard)
9486
9456
  ]),
9487
9457
  vue.createElementVNode(
@@ -10584,12 +10554,12 @@ ${_html.style}
10584
10554
  // }
10585
10555
  }
10586
10556
  };
10587
- const _hoisted_1$x = { class: "vc-editable-input" };
10588
- const _hoisted_2$p = ["aria-labelledby"];
10589
- const _hoisted_3$n = ["id", "for"];
10557
+ const _hoisted_1$w = { class: "vc-editable-input" };
10558
+ const _hoisted_2$o = ["aria-labelledby"];
10559
+ const _hoisted_3$m = ["id", "for"];
10590
10560
  const _hoisted_4$d = { class: "vc-input__desc" };
10591
10561
  function render$3(_ctx, _cache, $props, $setup, $data, $options) {
10592
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$x, [
10562
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$w, [
10593
10563
  vue.withDirectives(vue.createElementVNode("input", {
10594
10564
  ref: "input",
10595
10565
  "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => $options.val = $event),
@@ -10597,14 +10567,14 @@ ${_html.style}
10597
10567
  class: "vc-input__input",
10598
10568
  onKeydown: _cache[1] || (_cache[1] = (...args) => $options.handleKeyDown && $options.handleKeyDown(...args)),
10599
10569
  onInput: _cache[2] || (_cache[2] = (...args) => $options.update && $options.update(...args))
10600
- }, null, 40, _hoisted_2$p), [
10570
+ }, null, 40, _hoisted_2$o), [
10601
10571
  [vue.vModelText, $options.val]
10602
10572
  ]),
10603
10573
  vue.createElementVNode("span", {
10604
10574
  id: $options.labelId,
10605
10575
  for: $props.label,
10606
10576
  class: "vc-input__label"
10607
- }, vue.toDisplayString($options.labelSpanText), 9, _hoisted_3$n),
10577
+ }, vue.toDisplayString($options.labelSpanText), 9, _hoisted_3$m),
10608
10578
  vue.createElementVNode(
10609
10579
  "span",
10610
10580
  _hoisted_4$d,
@@ -10684,21 +10654,21 @@ ${_html.style}
10684
10654
  }
10685
10655
  }
10686
10656
  };
10687
- const _hoisted_1$w = /* @__PURE__ */ vue.createElementVNode(
10657
+ const _hoisted_1$v = /* @__PURE__ */ vue.createElementVNode(
10688
10658
  "div",
10689
10659
  { class: "vc-saturation--white" },
10690
10660
  null,
10691
10661
  -1
10692
10662
  /* HOISTED */
10693
10663
  );
10694
- const _hoisted_2$o = /* @__PURE__ */ vue.createElementVNode(
10664
+ const _hoisted_2$n = /* @__PURE__ */ vue.createElementVNode(
10695
10665
  "div",
10696
10666
  { class: "vc-saturation--black" },
10697
10667
  null,
10698
10668
  -1
10699
10669
  /* HOISTED */
10700
10670
  );
10701
- const _hoisted_3$m = /* @__PURE__ */ vue.createElementVNode(
10671
+ const _hoisted_3$l = /* @__PURE__ */ vue.createElementVNode(
10702
10672
  "div",
10703
10673
  { class: "vc-saturation-circle" },
10704
10674
  null,
@@ -10706,7 +10676,7 @@ ${_html.style}
10706
10676
  /* HOISTED */
10707
10677
  );
10708
10678
  const _hoisted_4$c = [
10709
- _hoisted_3$m
10679
+ _hoisted_3$l
10710
10680
  ];
10711
10681
  function render$2(_ctx, _cache, $props, $setup, $data, $options) {
10712
10682
  return vue.openBlock(), vue.createElementBlock(
@@ -10720,8 +10690,8 @@ ${_html.style}
10720
10690
  onTouchstart: _cache[2] || (_cache[2] = (...args) => $options.handleChange && $options.handleChange(...args))
10721
10691
  },
10722
10692
  [
10723
- _hoisted_1$w,
10724
- _hoisted_2$o,
10693
+ _hoisted_1$v,
10694
+ _hoisted_2$n,
10725
10695
  vue.createElementVNode(
10726
10696
  "div",
10727
10697
  {
@@ -10869,16 +10839,16 @@ ${_html.style}
10869
10839
  }
10870
10840
  }
10871
10841
  };
10872
- const _hoisted_1$v = ["aria-valuenow"];
10873
- const _hoisted_2$n = /* @__PURE__ */ vue.createElementVNode(
10842
+ const _hoisted_1$u = ["aria-valuenow"];
10843
+ const _hoisted_2$m = /* @__PURE__ */ vue.createElementVNode(
10874
10844
  "div",
10875
10845
  { class: "vc-hue-picker" },
10876
10846
  null,
10877
10847
  -1
10878
10848
  /* HOISTED */
10879
10849
  );
10880
- const _hoisted_3$l = [
10881
- _hoisted_2$n
10850
+ const _hoisted_3$k = [
10851
+ _hoisted_2$m
10882
10852
  ];
10883
10853
  function render$1(_ctx, _cache, $props, $setup, $data, $options) {
10884
10854
  return vue.openBlock(), vue.createElementBlock(
@@ -10905,11 +10875,11 @@ ${_html.style}
10905
10875
  style: vue.normalizeStyle({ top: $options.pointerTop, left: $options.pointerLeft }),
10906
10876
  role: "presentation"
10907
10877
  },
10908
- _hoisted_3$l,
10878
+ _hoisted_3$k,
10909
10879
  4
10910
10880
  /* STYLE */
10911
10881
  )
10912
- ], 40, _hoisted_1$v)
10882
+ ], 40, _hoisted_1$u)
10913
10883
  ],
10914
10884
  2
10915
10885
  /* CLASS */
@@ -11005,9 +10975,9 @@ ${_html.style}
11005
10975
  }
11006
10976
  }
11007
10977
  };
11008
- const _hoisted_1$u = { class: "vc-sketch-saturation-wrap" };
11009
- const _hoisted_2$m = { class: "vc-sketch-controls" };
11010
- const _hoisted_3$k = { class: "vc-sketch-sliders" };
10978
+ const _hoisted_1$t = { class: "vc-sketch-saturation-wrap" };
10979
+ const _hoisted_2$l = { class: "vc-sketch-controls" };
10980
+ const _hoisted_3$j = { class: "vc-sketch-sliders" };
11011
10981
  const _hoisted_4$b = { class: "vc-sketch-hue-wrap" };
11012
10982
  const _hoisted_5$6 = {
11013
10983
  key: 0,
@@ -11048,14 +11018,14 @@ ${_html.style}
11048
11018
  class: vue.normalizeClass(["vc-sketch", [$props.disableAlpha ? "vc-sketch__disable-alpha" : ""]])
11049
11019
  },
11050
11020
  [
11051
- vue.createElementVNode("div", _hoisted_1$u, [
11021
+ vue.createElementVNode("div", _hoisted_1$t, [
11052
11022
  vue.createVNode(_component_Saturation, {
11053
11023
  value: _ctx.colors,
11054
11024
  onChange: $options.childChange
11055
11025
  }, null, 8, ["value", "onChange"])
11056
11026
  ]),
11057
- vue.createElementVNode("div", _hoisted_2$m, [
11058
- vue.createElementVNode("div", _hoisted_3$k, [
11027
+ vue.createElementVNode("div", _hoisted_2$l, [
11028
+ vue.createElementVNode("div", _hoisted_3$j, [
11059
11029
  vue.createElementVNode("div", _hoisted_4$b, [
11060
11030
  vue.createVNode(_component_Hue, {
11061
11031
  value: _ctx.colors,
@@ -11160,7 +11130,7 @@ ${_html.style}
11160
11130
  script.render = render;
11161
11131
  script.__file = "src/components/sketch/sketch.vue";
11162
11132
  script.install = install;
11163
- const _sfc_main$u = vue.defineComponent({
11133
+ const _sfc_main$t = vue.defineComponent({
11164
11134
  name: "PbColorPicker",
11165
11135
  components: {
11166
11136
  Sketch: script
@@ -11224,10 +11194,10 @@ ${_html.style}
11224
11194
  };
11225
11195
  }
11226
11196
  });
11227
- const _hoisted_1$t = { class: "buttons" };
11228
- const _hoisted_2$l = /* @__PURE__ */ vue.createElementVNode("i", { class: "material-icons-outlined" }, "delete", -1);
11229
- const _hoisted_3$j = [
11230
- _hoisted_2$l
11197
+ const _hoisted_1$s = { class: "buttons" };
11198
+ const _hoisted_2$k = /* @__PURE__ */ vue.createElementVNode("i", { class: "material-icons-outlined" }, "delete", -1);
11199
+ const _hoisted_3$i = [
11200
+ _hoisted_2$k
11231
11201
  ];
11232
11202
  const _hoisted_4$a = { class: "sketch-wrap" };
11233
11203
  function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
@@ -11238,7 +11208,7 @@ ${_html.style}
11238
11208
  onKeydown: _cache[3] || (_cache[3] = vue.withModifiers(() => {
11239
11209
  }, ["stop"]))
11240
11210
  }, [
11241
- vue.createElementVNode("div", _hoisted_1$t, [
11211
+ vue.createElementVNode("div", _hoisted_1$s, [
11242
11212
  vue.renderSlot(_ctx.$slots, "button", vue.normalizeProps(vue.guardReactiveProps({ toggle: _ctx.toggle, color: _ctx.color })), () => [
11243
11213
  vue.createElementVNode("button", {
11244
11214
  class: vue.normalizeClass([{ none: !_ctx.color }, "pb-button picker-button"]),
@@ -11250,7 +11220,7 @@ ${_html.style}
11250
11220
  key: 0,
11251
11221
  class: "pb-button",
11252
11222
  onClick: _cache[1] || (_cache[1] = (...args) => _ctx.emptyColor && _ctx.emptyColor(...args))
11253
- }, _hoisted_3$j)) : vue.createCommentVNode("", true)
11223
+ }, _hoisted_3$i)) : vue.createCommentVNode("", true)
11254
11224
  ]),
11255
11225
  vue.createElementVNode("div", _hoisted_4$a, [
11256
11226
  _ctx.isShowColorPicker ? (vue.openBlock(), vue.createBlock(_component_Sketch, {
@@ -11264,15 +11234,15 @@ ${_html.style}
11264
11234
  [_directive_click_outside, () => _ctx.toggle(false)]
11265
11235
  ]);
11266
11236
  }
11267
- const PbColorPicker = /* @__PURE__ */ _export_sfc(_sfc_main$u, [["render", _sfc_render]]);
11268
- const _hoisted_1$s = { class: "group-editor group-editor-background" };
11269
- const _hoisted_2$k = { class: "flex-align-center" };
11270
- const _hoisted_3$i = /* @__PURE__ */ vue.createElementVNode("div", { class: "title" }, [
11237
+ const PbColorPicker = /* @__PURE__ */ _export_sfc(_sfc_main$t, [["render", _sfc_render]]);
11238
+ const _hoisted_1$r = { class: "group-editor group-editor-background" };
11239
+ const _hoisted_2$j = { class: "flex-align-center" };
11240
+ const _hoisted_3$h = /* @__PURE__ */ vue.createElementVNode("div", { class: "title" }, [
11271
11241
  /* @__PURE__ */ vue.createElementVNode("label", { textContent: "Background" })
11272
11242
  ], -1);
11273
11243
  const _hoisted_4$9 = { class: "bs-layout-horizontal" };
11274
11244
  const _hoisted_5$5 = { class: "color" };
11275
- const _sfc_main$t = /* @__PURE__ */ vue.defineComponent({
11245
+ const _sfc_main$s = /* @__PURE__ */ vue.defineComponent({
11276
11246
  __name: "PbPropertyGroupEditorBackground",
11277
11247
  props: {
11278
11248
  group: {},
@@ -11302,9 +11272,9 @@ ${_html.style}
11302
11272
  });
11303
11273
  };
11304
11274
  return (_ctx, _cache) => {
11305
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$s, [
11306
- vue.createElementVNode("div", _hoisted_2$k, [
11307
- _hoisted_3$i,
11275
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$r, [
11276
+ vue.createElementVNode("div", _hoisted_2$j, [
11277
+ _hoisted_3$h,
11308
11278
  vue.createElementVNode("div", _hoisted_4$9, [
11309
11279
  vue.createElementVNode("div", _hoisted_5$5, [
11310
11280
  vue.createVNode(PbColorPicker, {
@@ -11335,9 +11305,9 @@ ${_html.style}
11335
11305
  const TopRightCornerIcon = "data:image/svg+xml,%3c!DOCTYPE%20svg%20PUBLIC%20'-//W3C//DTD%20SVG%201.1//EN'%20'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd'%3e%3c!--%20Uploaded%20to:%20SVG%20Repo,%20www.svgrepo.com,%20Transformed%20by:%20SVG%20Repo%20Mixer%20Tools%20--%3e%3csvg%20width='800px'%20height='800px'%20viewBox='0%200%2024%2024'%20xmlns='http://www.w3.org/2000/svg'%20fill='%23000000'%3e%3cg%20id='SVGRepo_bgCarrier'%20stroke-width='0'/%3e%3cg%20id='SVGRepo_tracerCarrier'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cg%20id='SVGRepo_iconCarrier'%3e%3cg%3e%3cpath%20fill='none'%20d='M0%200H24V24H0z'/%3e%3cpath%20d='M21%2019v2h-2v-2h2zm-4%200v2h-2v-2h2zm-4%200v2h-2v-2h2zm-4%200v2H7v-2h2zm-4%200v2H3v-2h2zm16-4v2h-2v-2h2zM5%2015v2H3v-2h2zm0-4v2H3v-2h2zm11-8c2.687%200%204.882%202.124%204.995%204.783L21%208v5h-2V8c0-1.591-1.255-2.903-2.824-2.995L16%205h-5V3h5zM5%207v2H3V7h2zm0-4v2H3V3h2zm4%200v2H7V3h2z'/%3e%3c/g%3e%3c/g%3e%3c/svg%3e";
11336
11306
  const BottomLeftCornerIcon = "data:image/svg+xml,%3c!DOCTYPE%20svg%20PUBLIC%20'-//W3C//DTD%20SVG%201.1//EN'%20'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd'%3e%3c!--%20Uploaded%20to:%20SVG%20Repo,%20www.svgrepo.com,%20Transformed%20by:%20SVG%20Repo%20Mixer%20Tools%20--%3e%3csvg%20width='800px'%20height='800px'%20viewBox='0%200%2024%2024'%20xmlns='http://www.w3.org/2000/svg'%20fill='%23000000'%20transform='rotate(180)'%3e%3cg%20id='SVGRepo_bgCarrier'%20stroke-width='0'/%3e%3cg%20id='SVGRepo_tracerCarrier'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cg%20id='SVGRepo_iconCarrier'%3e%3cg%3e%3cpath%20fill='none'%20d='M0%200H24V24H0z'/%3e%3cpath%20d='M21%2019v2h-2v-2h2zm-4%200v2h-2v-2h2zm-4%200v2h-2v-2h2zm-4%200v2H7v-2h2zm-4%200v2H3v-2h2zm16-4v2h-2v-2h2zM5%2015v2H3v-2h2zm0-4v2H3v-2h2zm11-8c2.687%200%204.882%202.124%204.995%204.783L21%208v5h-2V8c0-1.591-1.255-2.903-2.824-2.995L16%205h-5V3h5zM5%207v2H3V7h2zm0-4v2H3V3h2zm4%200v2H7V3h2z'/%3e%3c/g%3e%3c/g%3e%3c/svg%3e";
11337
11307
  const BottomRightCornerIcon = "data:image/svg+xml,%3c!DOCTYPE%20svg%20PUBLIC%20'-//W3C//DTD%20SVG%201.1//EN'%20'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd'%3e%3c!--%20Uploaded%20to:%20SVG%20Repo,%20www.svgrepo.com,%20Transformed%20by:%20SVG%20Repo%20Mixer%20Tools%20--%3e%3csvg%20width='800px'%20height='800px'%20viewBox='0%200%2024%2024'%20xmlns='http://www.w3.org/2000/svg'%20fill='%23000000'%20transform='rotate(90)'%3e%3cg%20id='SVGRepo_bgCarrier'%20stroke-width='0'/%3e%3cg%20id='SVGRepo_tracerCarrier'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cg%20id='SVGRepo_iconCarrier'%3e%3cg%3e%3cpath%20fill='none'%20d='M0%200H24V24H0z'/%3e%3cpath%20d='M21%2019v2h-2v-2h2zm-4%200v2h-2v-2h2zm-4%200v2h-2v-2h2zm-4%200v2H7v-2h2zm-4%200v2H3v-2h2zm16-4v2h-2v-2h2zM5%2015v2H3v-2h2zm0-4v2H3v-2h2zm11-8c2.687%200%204.882%202.124%204.995%204.783L21%208v5h-2V8c0-1.591-1.255-2.903-2.824-2.995L16%205h-5V3h5zM5%207v2H3V7h2zm0-4v2H3V3h2zm4%200v2H7V3h2z'/%3e%3c/g%3e%3c/g%3e%3c/svg%3e";
11338
- const _hoisted_1$r = { class: "group-editor group-editor-border" };
11339
- const _hoisted_2$j = { class: "flex-align-center" };
11340
- const _hoisted_3$h = /* @__PURE__ */ vue.createElementVNode("div", { class: "title" }, [
11308
+ const _hoisted_1$q = { class: "group-editor group-editor-border" };
11309
+ const _hoisted_2$i = { class: "flex-align-center" };
11310
+ const _hoisted_3$g = /* @__PURE__ */ vue.createElementVNode("div", { class: "title" }, [
11341
11311
  /* @__PURE__ */ vue.createElementVNode("label", { textContent: "Border" })
11342
11312
  ], -1);
11343
11313
  const _hoisted_4$8 = { class: "" };
@@ -11368,7 +11338,7 @@ ${_html.style}
11368
11338
  const _hoisted_18 = { class: "bg-gray-100 py-5 rounded-8" };
11369
11339
  const _hoisted_19 = { class: "" };
11370
11340
  const _hoisted_20 = { class: "mt-2" };
11371
- const _sfc_main$s = /* @__PURE__ */ vue.defineComponent({
11341
+ const _sfc_main$r = /* @__PURE__ */ vue.defineComponent({
11372
11342
  __name: "PbPropertyGroupEditorBorder",
11373
11343
  props: {
11374
11344
  group: {},
@@ -11406,9 +11376,9 @@ ${_html.style}
11406
11376
  const updateBorderBottomLeftRadius = (value) => updatePropertyValue({ borderBottomLeftRadius: value });
11407
11377
  const updateBorderBottomRightRadius = (value) => updatePropertyValue({ borderBottomRightRadius: value });
11408
11378
  return (_ctx, _cache) => {
11409
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$r, [
11410
- vue.createElementVNode("div", _hoisted_2$j, [
11411
- _hoisted_3$h,
11379
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$q, [
11380
+ vue.createElementVNode("div", _hoisted_2$i, [
11381
+ _hoisted_3$g,
11412
11382
  vue.createElementVNode("div", _hoisted_4$8, [
11413
11383
  _hoisted_5$4,
11414
11384
  vue.createElementVNode("div", _hoisted_6$4, [
@@ -11515,9 +11485,9 @@ ${_html.style}
11515
11485
  };
11516
11486
  }
11517
11487
  });
11518
- const _hoisted_1$q = { class: "group-editor group-editor-margin" };
11519
- const _hoisted_2$i = { class: "flex-align-center" };
11520
- const _hoisted_3$g = /* @__PURE__ */ vue.createElementVNode("div", { class: "title" }, [
11488
+ const _hoisted_1$p = { class: "group-editor group-editor-margin" };
11489
+ const _hoisted_2$h = { class: "flex-align-center" };
11490
+ const _hoisted_3$f = /* @__PURE__ */ vue.createElementVNode("div", { class: "title" }, [
11521
11491
  /* @__PURE__ */ vue.createElementVNode("label", { textContent: "Margin" })
11522
11492
  ], -1);
11523
11493
  const _hoisted_4$7 = { class: "flex-grow-1" };
@@ -11531,7 +11501,7 @@ ${_html.style}
11531
11501
  /* @__PURE__ */ vue.createElementVNode("span", { class: "font-icon" }, "add")
11532
11502
  ], -1);
11533
11503
  const _hoisted_9$2 = { class: "text-center" };
11534
- const _sfc_main$r = /* @__PURE__ */ vue.defineComponent({
11504
+ const _sfc_main$q = /* @__PURE__ */ vue.defineComponent({
11535
11505
  __name: "PbPropertyGroupEditorMargin",
11536
11506
  props: {
11537
11507
  group: {},
@@ -11555,9 +11525,9 @@ ${_html.style}
11555
11525
  const updateTop = (value) => updatePropertyValue({ marginTop: value });
11556
11526
  const updateBottom = (value) => updatePropertyValue({ marginBottom: value });
11557
11527
  return (_ctx, _cache) => {
11558
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$q, [
11559
- vue.createElementVNode("div", _hoisted_2$i, [
11560
- _hoisted_3$g,
11528
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$p, [
11529
+ vue.createElementVNode("div", _hoisted_2$h, [
11530
+ _hoisted_3$f,
11561
11531
  vue.createElementVNode("div", _hoisted_4$7, [
11562
11532
  vue.createElementVNode("div", _hoisted_5$3, [
11563
11533
  vue.createElementVNode("div", _hoisted_6$3, [
@@ -11602,9 +11572,9 @@ ${_html.style}
11602
11572
  };
11603
11573
  }
11604
11574
  });
11605
- const _hoisted_1$p = { class: "group-editor group-editor-padding" };
11606
- const _hoisted_2$h = { class: "flex-align-center" };
11607
- const _hoisted_3$f = /* @__PURE__ */ vue.createElementVNode("div", { class: "title" }, [
11575
+ const _hoisted_1$o = { class: "group-editor group-editor-padding" };
11576
+ const _hoisted_2$g = { class: "flex-align-center" };
11577
+ const _hoisted_3$e = /* @__PURE__ */ vue.createElementVNode("div", { class: "title" }, [
11608
11578
  /* @__PURE__ */ vue.createElementVNode("label", { textContent: "Padding" })
11609
11579
  ], -1);
11610
11580
  const _hoisted_4$6 = { class: "flex-grow-1" };
@@ -11618,7 +11588,7 @@ ${_html.style}
11618
11588
  /* @__PURE__ */ vue.createElementVNode("span", { class: "font-icon" }, "add")
11619
11589
  ], -1);
11620
11590
  const _hoisted_9$1 = { class: "text-center" };
11621
- const _sfc_main$q = /* @__PURE__ */ vue.defineComponent({
11591
+ const _sfc_main$p = /* @__PURE__ */ vue.defineComponent({
11622
11592
  __name: "PbPropertyGroupEditorPadding",
11623
11593
  props: {
11624
11594
  group: {},
@@ -11642,9 +11612,9 @@ ${_html.style}
11642
11612
  const updateTop = (value) => updatePropertyValue({ paddingTop: value });
11643
11613
  const updateBottom = (value) => updatePropertyValue({ paddingBottom: value });
11644
11614
  return (_ctx, _cache) => {
11645
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$p, [
11646
- vue.createElementVNode("div", _hoisted_2$h, [
11647
- _hoisted_3$f,
11615
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$o, [
11616
+ vue.createElementVNode("div", _hoisted_2$g, [
11617
+ _hoisted_3$e,
11648
11618
  vue.createElementVNode("div", _hoisted_4$6, [
11649
11619
  vue.createElementVNode("div", _hoisted_5$2, [
11650
11620
  vue.createElementVNode("div", _hoisted_6$2, [
@@ -11715,7 +11685,7 @@ ${_html.style}
11715
11685
  propertyType: "text"
11716
11686
  }
11717
11687
  ],
11718
- propertyGroupEditor: () => _sfc_main$w
11688
+ propertyGroupEditor: () => _sfc_main$v
11719
11689
  };
11720
11690
  };
11721
11691
  const sizeGroup = () => {
@@ -11754,7 +11724,7 @@ ${_html.style}
11754
11724
  propertyType: "text"
11755
11725
  }
11756
11726
  ],
11757
- propertyGroupEditor: () => _sfc_main$v
11727
+ propertyGroupEditor: () => _sfc_main$u
11758
11728
  };
11759
11729
  };
11760
11730
  const marginGroup = () => {
@@ -11783,7 +11753,7 @@ ${_html.style}
11783
11753
  propertyType: "text"
11784
11754
  }
11785
11755
  ],
11786
- propertyGroupEditor: () => _sfc_main$r
11756
+ propertyGroupEditor: () => _sfc_main$q
11787
11757
  };
11788
11758
  };
11789
11759
  const paddingGroup = () => {
@@ -11812,7 +11782,7 @@ ${_html.style}
11812
11782
  propertyType: "text"
11813
11783
  }
11814
11784
  ],
11815
- propertyGroupEditor: () => _sfc_main$q
11785
+ propertyGroupEditor: () => _sfc_main$p
11816
11786
  };
11817
11787
  };
11818
11788
  const commonGroup = () => {
@@ -11879,7 +11849,7 @@ ${_html.style}
11879
11849
  propertyType: "image"
11880
11850
  }
11881
11851
  ],
11882
- propertyGroupEditor: () => _sfc_main$t
11852
+ propertyGroupEditor: () => _sfc_main$s
11883
11853
  };
11884
11854
  };
11885
11855
  const borderGroup = () => {
@@ -11933,7 +11903,7 @@ ${_html.style}
11933
11903
  propertyType: "text"
11934
11904
  }
11935
11905
  ],
11936
- propertyGroupEditor: () => _sfc_main$s
11906
+ propertyGroupEditor: () => _sfc_main$r
11937
11907
  };
11938
11908
  };
11939
11909
  const defaultPropertyGroups = () => {
@@ -11957,7 +11927,7 @@ ${_html.style}
11957
11927
  },
11958
11928
  localized: false,
11959
11929
  allowsChild: () => true,
11960
- creator: () => _sfc_main$x
11930
+ creator: () => _sfc_main$w
11961
11931
  },
11962
11932
  {
11963
11933
  partType: "Section",
@@ -11973,7 +11943,7 @@ ${_html.style}
11973
11943
  },
11974
11944
  localized: true,
11975
11945
  allowsChild: () => true,
11976
- creator: () => _sfc_main$x
11946
+ creator: () => _sfc_main$w
11977
11947
  },
11978
11948
  {
11979
11949
  partType: "Section",
@@ -11989,7 +11959,7 @@ ${_html.style}
11989
11959
  },
11990
11960
  localized: true,
11991
11961
  allowsChild: () => true,
11992
- creator: () => _sfc_main$x
11962
+ creator: () => _sfc_main$w
11993
11963
  }
11994
11964
  ];
11995
11965
  const sectionParts = [
@@ -12006,7 +11976,7 @@ ${_html.style}
12006
11976
  },
12007
11977
  localized: false,
12008
11978
  allowsChild: () => true,
12009
- creator: () => _sfc_main$x
11979
+ creator: () => _sfc_main$w
12010
11980
  }
12011
11981
  ];
12012
11982
  const blockParts = [
@@ -12021,7 +11991,7 @@ ${_html.style}
12021
11991
  initialProperties: {},
12022
11992
  localized: false,
12023
11993
  allowsChild: () => true,
12024
- creator: () => _sfc_main$z
11994
+ creator: () => _sfc_main$y
12025
11995
  }
12026
11996
  ];
12027
11997
  const widgets = [
@@ -12120,32 +12090,6 @@ ${_html.style}
12120
12090
  localized: true,
12121
12091
  allowsChild: () => false,
12122
12092
  creator: () => _sfc_main$3$1
12123
- },
12124
- {
12125
- partType: "Widget",
12126
- partName: "ProductListWidget",
12127
- caption: "Product List Widget",
12128
- icon: "lists",
12129
- propertyGroups: [
12130
- {
12131
- groupName: "productList",
12132
- caption: "Product List",
12133
- properties: [
12134
- {
12135
- propertyName: "product",
12136
- caption: "Product",
12137
- propertyType: "product",
12138
- params: "",
12139
- localized: true
12140
- }
12141
- ]
12142
- },
12143
- ...defaultWidgetPropertyGroups()
12144
- ],
12145
- initialProperties: {},
12146
- localized: true,
12147
- allowsChild: () => false,
12148
- creator: () => _sfc_main$2$1
12149
12093
  }
12150
12094
  ];
12151
12095
  const partDefinitions = {};
@@ -13383,6 +13327,12 @@ ${_html.style}
13383
13327
  setLocales(locales) {
13384
13328
  this.locales.value = locales || ["en"];
13385
13329
  }
13330
+ getCustomWidgetComponent(part) {
13331
+ const def = this.partManager.getPartDefinition(part.partName);
13332
+ if (def) {
13333
+ return def.component;
13334
+ }
13335
+ }
13386
13336
  registerPlugin(plugin) {
13387
13337
  if (plugin.partDefinitions)
13388
13338
  this.partManager.registerPartDefinitions(plugin.partDefinitions);
@@ -13399,6 +13349,22 @@ ${_html.style}
13399
13349
  if (plugin.toolButtonGroups)
13400
13350
  this.toolButtonRegistry.registerToolButtonGroups(plugin.toolButtonGroups);
13401
13351
  }
13352
+ registerCustomPlugin(plugin) {
13353
+ if (plugin.widgets) {
13354
+ const partDefinitions2 = {};
13355
+ plugin.widgets.forEach((v) => {
13356
+ const w = { ...v };
13357
+ w.partName = "Widget";
13358
+ w.creator = () => _sfc_main$B;
13359
+ w.propertyGroups = [...w.propertyGroups, ...defaultWidgetPropertyGroups()];
13360
+ partDefinitions2[v.partName] = w;
13361
+ });
13362
+ this.partManager.registerPartDefinitions(partDefinitions2);
13363
+ }
13364
+ if (plugin.propertyEditors) {
13365
+ this.partManager.registerPartPropertyEditors(plugin.propertyEditors);
13366
+ }
13367
+ }
13402
13368
  initData(content) {
13403
13369
  this.model.rootPart.pageBuilderId = this.instanceId;
13404
13370
  this.model.rootPart.language = this.locale.value;
@@ -13490,11 +13456,11 @@ ${_html.style}
13490
13456
  });
13491
13457
  }
13492
13458
  }
13493
- const _hoisted_1$o = /* @__PURE__ */ vue.createElementVNode("i", { class: "material-icons-outlined" }, "add_circle_outline", -1);
13494
- const _hoisted_2$g = [
13495
- _hoisted_1$o
13459
+ const _hoisted_1$n = /* @__PURE__ */ vue.createElementVNode("i", { class: "material-icons-outlined" }, "add_circle_outline", -1);
13460
+ const _hoisted_2$f = [
13461
+ _hoisted_1$n
13496
13462
  ];
13497
- const _sfc_main$p = /* @__PURE__ */ vue.defineComponent({
13463
+ const _sfc_main$o = /* @__PURE__ */ vue.defineComponent({
13498
13464
  __name: "PbPage",
13499
13465
  props: {
13500
13466
  page: {},
@@ -13527,7 +13493,7 @@ ${_html.style}
13527
13493
  class: vue.normalizeClass([selected.value && "selected", _ctx.isMobilePage ? "mobile" : "pc", "pb-page-content"])
13528
13494
  }, [
13529
13495
  (vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList((_a = _ctx.page) == null ? void 0 : _a.children, (section, index) => {
13530
- return vue.openBlock(), vue.createBlock(_sfc_main$x, {
13496
+ return vue.openBlock(), vue.createBlock(_sfc_main$w, {
13531
13497
  key: section.partId,
13532
13498
  part: section
13533
13499
  }, null, 8, ["part"]);
@@ -13539,13 +13505,13 @@ ${_html.style}
13539
13505
  var _a2, _b;
13540
13506
  return insertSection(((_b = (_a2 = _ctx.page) == null ? void 0 : _a2.children) == null ? void 0 : _b.length) || 0);
13541
13507
  })
13542
- }, _hoisted_2$g)
13508
+ }, _hoisted_2$f)
13543
13509
  ], 4);
13544
13510
  };
13545
13511
  }
13546
13512
  });
13547
- const _hoisted_1$n = /* @__PURE__ */ vue.createElementVNode("div", { style: { "width": "20px" } }, null, -1);
13548
- const _sfc_main$o = /* @__PURE__ */ vue.defineComponent({
13513
+ const _hoisted_1$m = /* @__PURE__ */ vue.createElementVNode("div", { style: { "width": "20px" } }, null, -1);
13514
+ const _sfc_main$n = /* @__PURE__ */ vue.defineComponent({
13549
13515
  __name: "PbCanvas",
13550
13516
  setup(__props) {
13551
13517
  const pageBuilder = usePageBuilderEditor();
@@ -13592,13 +13558,13 @@ ${_html.style}
13592
13558
  style: vue.normalizeStyle(style.value),
13593
13559
  class: "pb-canvas"
13594
13560
  }, [
13595
- vue.createVNode(_sfc_main$p, {
13561
+ vue.createVNode(_sfc_main$o, {
13596
13562
  "is-mobile-page": true,
13597
13563
  page: pageS.value,
13598
13564
  width: 420
13599
13565
  }, null, 8, ["page"]),
13600
- _hoisted_1$n,
13601
- vue.createVNode(_sfc_main$p, {
13566
+ _hoisted_1$m,
13567
+ vue.createVNode(_sfc_main$o, {
13602
13568
  "is-mobile-page": false,
13603
13569
  page: pageL.value,
13604
13570
  width: 1024
@@ -13609,8 +13575,8 @@ ${_html.style}
13609
13575
  }
13610
13576
  });
13611
13577
  const canvasStyle = '.pb-page {\n margin: 0 auto;\n margin-top: 20px;\n background-position: 50% 50%;\n background-repeat: no-repeat;\n background-size: cover;\n}\n.pb-page .pb-page-content.selected {\n outline: 2px solid #4998f8;\n outline-offset: 5px;\n}\n.pb-page * {\n box-sizing: border-box;\n}\n.pb-add-widget-button {\n width: 100%;\n height: 100%;\n min-height: 200px;\n position: relative;\n}\n.pb-add-widget-button button {\n position: absolute;\n top: 50%;\n left: 50%;\n transform: translate(-50%, -50%);\n padding: 8px;\n background: none;\n border: none;\n cursor: pointer;\n}\n.pb-add-widget-button button:hover {\n background-color: #eeeeee;\n}\n.pb-add-widget-button .icon {\n font-size: 1rem;\n vertical-align: middle;\n}\n.pb-add-widget-button .text {\n font-size: 1rem;\n vertical-align: middle;\n margin-left: 0.4rem;\n}\n.pb-section {\n position: relative;\n background-position: 50% 50%;\n background-repeat: no-repeat;\n background-size: cover;\n outline: 1px dashed #ccc;\n background-color: #fff;\n}\n.pb-section:hover:not(:has(.pb-block:hover)) {\n background-color: #f0f0f0;\n}\n.pb-section.selected {\n outline: 1px solid #e67e22;\n outline-offset: 1px;\n z-index: 999;\n}\n.pb-section.pb-section-static {\n width: 100%;\n display: flex;\n justify-content: center;\n align-items: center;\n pointer-events: none;\n}\n.pb-section.pb-section-static:after {\n content: "";\n position: absolute;\n left: 0;\n right: 0;\n top: 0;\n bottom: 0;\n background-color: rgba(0, 0, 0, 0.2);\n}\n.pb-section-static .pb-widget {\n outline: none;\n}\n.pb-block {\n display: flex;\n min-width: 1px;\n position: relative;\n background-position: 50% 50%;\n background-repeat: no-repeat;\n background-size: cover;\n width: 100%;\n outline: 1px dashed #ccc;\n}\n.pb-block:hover:not(:has(.pb-widget:hover)) {\n background-color: #f0f0f0;\n}\n.pb-block.selected {\n outline: 1px solid #8e44ad;\n outline-offset: 1px;\n z-index: 999;\n}\n.pb-widget {\n position: relative;\n outline: 1px dashed #ccc;\n background-position: 50% 50%;\n background-repeat: no-repeat;\n background-size: cover;\n}\n.pb-widget.selected {\n outline: 2px solid #27ae60;\n outline-offset: 1px;\n z-index: 999;\n}\n.pb-widget .children {\n position: absolute;\n width: 100%;\n height: 100%;\n}\n.pb-widget .pan-handle {\n position: absolute;\n left: -6px;\n top: -6px;\n width: 12px;\n height: 12px;\n background-color: #27ae60;\n cursor: move;\n}\n.pb-widget .resize-handle {\n position: absolute;\n right: -6px;\n bottom: -6px;\n width: 12px;\n height: 12px;\n background-color: #27ae60;\n cursor: nwse-resize;\n}\n.pb-widget {\n position: relative;\n background-position: 50% 50%;\n background-repeat: no-repeat;\n background-size: cover;\n width: 100%;\n}\n.pb-widget .children {\n position: absolute;\n width: 100%;\n height: 100%;\n}\n.pb-text-widget {\n width: 100%;\n height: fit-content;\n}\n.pb-text-widget .text {\n color: #333;\n}\n.pb-text-widget.empty .text {\n color: #999;\n}\n.pb-image-widget {\n width: 100%;\n}\n.pb-image-widget .image {\n width: 100%;\n}\n.pb-image-widget .empty {\n height: 100px;\n background-color: #eee;\n text-align: center;\n}\n.pb-image-widget .empty span {\n font-size: 40px;\n color: #999;\n line-height: 100px;\n vertical-align: middle;\n}\n.pb-html-widget {\n width: 100%;\n height: fit-content;\n}\n.pb-html-widget.empty {\n padding: 4px 0;\n font-size: 18px;\n color: #999;\n}\n.pb-product-list-widget {\n width: 100%;\n display: flex;\n flex-direction: row;\n flex-wrap: wrap;\n justify-content: flex-start;\n align-items: center;\n}\n.pb-product-list-widget .product-wrapper {\n width: 25%;\n}\n.pb-product-list-widget .product-wrapper .product {\n width: 95%;\n margin: 0 auto;\n padding-top: 8px;\n padding-bottom: 8px;\n}\n.pb-product-list-widget .product-wrapper img {\n width: 100%;\n}\n.pb-product-list-widget .product-wrapper .name {\n margin-top: 8px;\n font-size: 14px;\n}\n.pb-product-list-widget .product-wrapper .price {\n margin-top: 8px;\n font-size: 14px;\n font-weight: bold;\n}\n.pb-product-list-widget .product-wrapper .empty {\n height: 200px;\n background-color: #eee;\n text-align: center;\n}\n.pb-product-list-widget .product-wrapper .empty span {\n font-size: 40px;\n color: #999;\n line-height: 200px;\n vertical-align: middle;\n}\n@media (max-width: 768px) {\n .pb-product-list-widget .product-wrapper {\n width: 50%;\n }\n}\n.mobile .pb-product-list-widget .product-wrapper {\n width: 50%;\n}\n.pb-login-widget {\n height: 200px;\n text-align: center;\n}\n.pb-login-widget h3 {\n padding: 0;\n margin: 0;\n font-size: 32px;\n font-weight: bold;\n color: #ccc;\n line-height: 200px;\n vertical-align: middle;\n}\n.font-icon {\n font-family: Material Symbols Outlined, monospace;\n font-size: 1rem;\n max-width: 1em;\n}\nhtml, body {\n font-family: Noto Sans, Noto Sans KR, Noto Sans JP, Arial, sans-serif;\n font-size: 12px;\n}\nbody {\n background-color: white;\n height: 100%;\n margin: 0;\n}\n.pb-canvas-wrapper {\n padding: 32px 40px 56px 40px;\n height: 100%;\n background-color: #aaa;\n overflow: auto;\n}\n.pb-canvas-wrapper .pb-canvas {\n display: flex;\n flex-direction: row;\n transform-origin: top left;\n width: fit-content;\n min-width: 40px;\n min-height: 40px;\n margin: 0 auto;\n}\n.pb-position-mark {\n background-color: #ff3333;\n opacity: 0.5;\n border-radius: 2px;\n}\n.pb-add-section-handle {\n position: relative;\n text-align: center;\n cursor: pointer;\n z-index: 5;\n height: 0;\n}\n.pb-add-section-handle.top::before, .pb-add-section-handle.bottom::before, .pb-add-section-handle.middle::before {\n content: "";\n position: absolute;\n left: 0;\n right: 0;\n top: 0;\n opacity: 0;\n pointer-events: none;\n}\n.pb-add-section-handle.bottom {\n left: 50%;\n bottom: -32px;\n}\n.pb-add-section-handle:hover.top::before, .pb-add-section-handle:hover.bottom::before, .pb-add-section-handle:hover.middle::before,\n.pb-add-section-handle:hover > i {\n opacity: 1;\n}\n.pb-add-section-handle > i {\n vertical-align: middle;\n position: absolute;\n top: 50%;\n left: -20px;\n font-size: 2rem;\n transform: translate(-50%, -50%);\n opacity: 0.2;\n}\n.pb-button {\n background: none;\n border: none;\n cursor: pointer;\n vertical-align: middle;\n}\n.pb-guideline {\n position: absolute;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n pointer-events: none;\n}\n.pb-guideline.selected {\n z-index: 3;\n}\n.pb-guideline.preselect {\n z-index: 4;\n}';
13612
- const _hoisted_1$m = { class: "pb-canvas-frame" };
13613
- const _sfc_main$n = /* @__PURE__ */ vue.defineComponent({
13578
+ const _hoisted_1$l = { class: "pb-canvas-frame" };
13579
+ const _sfc_main$m = /* @__PURE__ */ vue.defineComponent({
13614
13580
  __name: "PbCanvasFrame",
13615
13581
  setup(__props) {
13616
13582
  const pageBuilderEditor = usePageBuilderEditor();
@@ -13652,7 +13618,7 @@ ${_html.style}
13652
13618
  );
13653
13619
  return (_ctx, _cache) => {
13654
13620
  var _a, _b, _c, _d;
13655
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$m, [
13621
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$l, [
13656
13622
  vue.createElementVNode("iframe", {
13657
13623
  ref_key: "iframeRef",
13658
13624
  ref: iframeRef,
@@ -13662,14 +13628,14 @@ ${_html.style}
13662
13628
  key: 0,
13663
13629
  to: (_d = (_c = iframeRef.value) == null ? void 0 : _c.contentWindow) == null ? void 0 : _d.document.body
13664
13630
  }, [
13665
- vue.createVNode(_sfc_main$o)
13631
+ vue.createVNode(_sfc_main$n)
13666
13632
  ], 8, ["to"])) : vue.createCommentVNode("", true)
13667
13633
  ]);
13668
13634
  };
13669
13635
  }
13670
13636
  });
13671
- const _hoisted_1$l = { class: "pb-tool-button bs-layout-horizontal flex-align-center" };
13672
- const _sfc_main$m = /* @__PURE__ */ vue.defineComponent({
13637
+ const _hoisted_1$k = { class: "pb-tool-button bs-layout-horizontal flex-align-center" };
13638
+ const _sfc_main$l = /* @__PURE__ */ vue.defineComponent({
13673
13639
  __name: "PbToolbarButton",
13674
13640
  props: {
13675
13641
  button: {}
@@ -13682,7 +13648,7 @@ ${_html.style}
13682
13648
  (_b = (_a = props.button).handler) == null ? void 0 : _b.call(_a, pageBuilder);
13683
13649
  };
13684
13650
  return (_ctx, _cache) => {
13685
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$l, [
13651
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$k, [
13686
13652
  vue.createElementVNode("div", {
13687
13653
  class: "tool-button bs-clickable",
13688
13654
  onClick: handleClick
@@ -13697,17 +13663,17 @@ ${_html.style}
13697
13663
  };
13698
13664
  }
13699
13665
  });
13700
- const _hoisted_1$k = { class: "pb-tool-button-group bs-layout-horizontal flex-align-center" };
13701
- const _sfc_main$l = /* @__PURE__ */ vue.defineComponent({
13666
+ const _hoisted_1$j = { class: "pb-tool-button-group bs-layout-horizontal flex-align-center" };
13667
+ const _sfc_main$k = /* @__PURE__ */ vue.defineComponent({
13702
13668
  __name: "PbToolbarButtonGroup",
13703
13669
  props: {
13704
13670
  group: {}
13705
13671
  },
13706
13672
  setup(__props) {
13707
13673
  return (_ctx, _cache) => {
13708
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$k, [
13674
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$j, [
13709
13675
  (vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(_ctx.group.buttons, (button) => {
13710
- return vue.openBlock(), vue.createBlock(_sfc_main$m, {
13676
+ return vue.openBlock(), vue.createBlock(_sfc_main$l, {
13711
13677
  key: button.buttonId,
13712
13678
  button
13713
13679
  }, null, 8, ["button"]);
@@ -13716,11 +13682,11 @@ ${_html.style}
13716
13682
  };
13717
13683
  }
13718
13684
  });
13719
- const _hoisted_1$j = { class: "pb-toolbar bs-layout-horizontal align-items-center" };
13720
- const _hoisted_2$f = { class: "bs-layout-horizontal align-items-center" };
13721
- const _hoisted_3$e = /* @__PURE__ */ vue.createElementVNode("div", { class: "flex-grow-1" }, null, -1);
13685
+ const _hoisted_1$i = { class: "pb-toolbar bs-layout-horizontal align-items-center" };
13686
+ const _hoisted_2$e = { class: "bs-layout-horizontal align-items-center" };
13687
+ const _hoisted_3$d = /* @__PURE__ */ vue.createElementVNode("div", { class: "flex-grow-1" }, null, -1);
13722
13688
  const _hoisted_4$5 = { class: "mr-8" };
13723
- const _sfc_main$k = /* @__PURE__ */ vue.defineComponent({
13689
+ const _sfc_main$j = /* @__PURE__ */ vue.defineComponent({
13724
13690
  __name: "PbToolbar",
13725
13691
  props: {
13726
13692
  plugin: {}
@@ -13771,10 +13737,10 @@ ${_html.style}
13771
13737
  });
13772
13738
  return (_ctx, _cache) => {
13773
13739
  var _a, _b, _c;
13774
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$j, [
13775
- vue.createElementVNode("div", _hoisted_2$f, [
13740
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$i, [
13741
+ vue.createElementVNode("div", _hoisted_2$e, [
13776
13742
  (vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(vue.unref(buttonGroups), (group) => {
13777
- return vue.openBlock(), vue.createBlock(_sfc_main$l, {
13743
+ return vue.openBlock(), vue.createBlock(_sfc_main$k, {
13778
13744
  key: group.groupId,
13779
13745
  group
13780
13746
  }, null, 8, ["group"]);
@@ -13796,7 +13762,7 @@ ${_html.style}
13796
13762
  placeholder: "Scale"
13797
13763
  }, null, 8, ["modelValue"])
13798
13764
  ]),
13799
- _hoisted_3$e,
13765
+ _hoisted_3$d,
13800
13766
  vue.createElementVNode("div", _hoisted_4$5, [
13801
13767
  _ctx.plugin ? (vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent((_a = _ctx.plugin) == null ? void 0 : _a.component), vue.mergeProps({ key: 0 }, (_b = _ctx.plugin) == null ? void 0 : _b.bind, vue.toHandlers((_c = _ctx.plugin) == null ? void 0 : _c.on)), null, 16)) : vue.createCommentVNode("", true)
13802
13768
  ])
@@ -13804,25 +13770,25 @@ ${_html.style}
13804
13770
  };
13805
13771
  }
13806
13772
  });
13807
- const _hoisted_1$i = { class: "pb-menu bs-layout-vertical" };
13808
- const _sfc_main$j = /* @__PURE__ */ vue.defineComponent({
13773
+ const _hoisted_1$h = { class: "pb-menu bs-layout-vertical" };
13774
+ const _sfc_main$i = /* @__PURE__ */ vue.defineComponent({
13809
13775
  __name: "PbMenu",
13810
13776
  props: {
13811
13777
  toolbarPlugin: {}
13812
13778
  },
13813
13779
  setup(__props) {
13814
13780
  return (_ctx, _cache) => {
13815
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$i, [
13816
- vue.createVNode(_sfc_main$k, { plugin: _ctx.toolbarPlugin }, null, 8, ["plugin"])
13781
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$h, [
13782
+ vue.createVNode(_sfc_main$j, { plugin: _ctx.toolbarPlugin }, null, 8, ["plugin"])
13817
13783
  ]);
13818
13784
  };
13819
13785
  }
13820
13786
  });
13821
- const _hoisted_1$h = {
13787
+ const _hoisted_1$g = {
13822
13788
  key: 1,
13823
13789
  class: "bs-layout-vertical border"
13824
13790
  };
13825
- const _sfc_main$i = /* @__PURE__ */ vue.defineComponent({
13791
+ const _sfc_main$h = /* @__PURE__ */ vue.defineComponent({
13826
13792
  __name: "PbNavigator",
13827
13793
  setup(__props) {
13828
13794
  const pageBuilder = usePageBuilderEditor();
@@ -14048,7 +14014,7 @@ ${_html.style}
14048
14014
  ], 512)
14049
14015
  ]),
14050
14016
  _: 1
14051
- }, 8, ["tab-id"])) : (vue.openBlock(), vue.createElementBlock("div", _hoisted_1$h, [
14017
+ }, 8, ["tab-id"])) : (vue.openBlock(), vue.createElementBlock("div", _hoisted_1$g, [
14052
14018
  vue.createElementVNode("div", {
14053
14019
  ref_key: "treeS",
14054
14020
  ref: treeS,
@@ -14081,7 +14047,7 @@ ${_html.style}
14081
14047
  };
14082
14048
  }
14083
14049
  });
14084
- const _sfc_main$h = /* @__PURE__ */ vue.defineComponent({
14050
+ const _sfc_main$g = /* @__PURE__ */ vue.defineComponent({
14085
14051
  __name: "PbSidebarPropertyEditor",
14086
14052
  props: {
14087
14053
  property: {},
@@ -14136,13 +14102,13 @@ ${_html.style}
14136
14102
  };
14137
14103
  }
14138
14104
  });
14139
- const _hoisted_1$g = { class: "pb-sidebar-property-group" };
14140
- const _hoisted_2$e = {
14105
+ const _hoisted_1$f = { class: "pb-sidebar-property-group" };
14106
+ const _hoisted_2$d = {
14141
14107
  key: 0,
14142
14108
  class: "group-title"
14143
14109
  };
14144
- const _hoisted_3$d = ["textContent"];
14145
- const _sfc_main$g = /* @__PURE__ */ vue.defineComponent({
14110
+ const _hoisted_3$c = ["textContent"];
14111
+ const _sfc_main$f = /* @__PURE__ */ vue.defineComponent({
14146
14112
  __name: "PbSidebarPropertyGroupEditor",
14147
14113
  props: {
14148
14114
  group: {},
@@ -14176,11 +14142,11 @@ ${_html.style}
14176
14142
  return (_b = (_a = props.group).propertyGroupEditor) == null ? void 0 : _b.call(_a, props.group, props.selectedParts);
14177
14143
  });
14178
14144
  return (_ctx, _cache) => {
14179
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$g, [
14180
- _ctx.group.showGroupName ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_2$e, [
14145
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$f, [
14146
+ _ctx.group.showGroupName ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_2$d, [
14181
14147
  vue.createElementVNode("label", {
14182
14148
  textContent: vue.toDisplayString(_ctx.group.caption)
14183
- }, null, 8, _hoisted_3$d)
14149
+ }, null, 8, _hoisted_3$c)
14184
14150
  ])) : vue.createCommentVNode("", true),
14185
14151
  _ctx.partsKey ? (vue.openBlock(), vue.createElementBlock(vue.Fragment, { key: 1 }, [
14186
14152
  groupEditor.value ? (vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(groupEditor.value), {
@@ -14188,7 +14154,7 @@ ${_html.style}
14188
14154
  group: _ctx.group,
14189
14155
  "selected-parts": _ctx.selectedParts
14190
14156
  }, null, 8, ["group", "selected-parts"])) : (vue.openBlock(true), vue.createElementBlock(vue.Fragment, { key: 1 }, vue.renderList(_ctx.group.properties, (property) => {
14191
- return vue.openBlock(), vue.createBlock(_sfc_main$h, {
14157
+ return vue.openBlock(), vue.createBlock(_sfc_main$g, {
14192
14158
  key: `${_ctx.partsKey}_${property.propertyName}`,
14193
14159
  property,
14194
14160
  "selected-parts": _ctx.selectedParts
@@ -14199,17 +14165,17 @@ ${_html.style}
14199
14165
  };
14200
14166
  }
14201
14167
  });
14202
- const _hoisted_1$f = { class: "property-editor property-editor-local-part flex-align-center pt-16" };
14203
- const _hoisted_2$d = /* @__PURE__ */ vue.createElementVNode("div", { class: "title" }, [
14168
+ const _hoisted_1$e = { class: "property-editor property-editor-local-part flex-align-center pt-16" };
14169
+ const _hoisted_2$c = /* @__PURE__ */ vue.createElementVNode("div", { class: "title" }, [
14204
14170
  /* @__PURE__ */ vue.createElementVNode("label", { textContent: "Display Schedule" })
14205
14171
  ], -1);
14206
- const _hoisted_3$c = { class: "bs-layout-horizontal" };
14172
+ const _hoisted_3$b = { class: "bs-layout-horizontal" };
14207
14173
  const _hoisted_4$4 = { class: "mr-2" };
14208
14174
  const _hoisted_5$1 = /* @__PURE__ */ vue.createElementVNode("span", { class: "font-icon" }, "more_horiz", -1);
14209
14175
  const _hoisted_6$1 = [
14210
14176
  _hoisted_5$1
14211
14177
  ];
14212
- const _sfc_main$f = /* @__PURE__ */ vue.defineComponent({
14178
+ const _sfc_main$e = /* @__PURE__ */ vue.defineComponent({
14213
14179
  __name: "PbPropertyLocalMarketingPart",
14214
14180
  props: {
14215
14181
  selectedPart: {}
@@ -14278,9 +14244,9 @@ ${_html.style}
14278
14244
  }
14279
14245
  };
14280
14246
  return (_ctx, _cache) => {
14281
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$f, [
14282
- _hoisted_2$d,
14283
- vue.createElementVNode("div", _hoisted_3$c, [
14247
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$e, [
14248
+ _hoisted_2$c,
14249
+ vue.createElementVNode("div", _hoisted_3$b, [
14284
14250
  vue.createElementVNode("div", _hoisted_4$4, [
14285
14251
  vue.createVNode(vue.unref(bluesea.BSDateRange), {
14286
14252
  "from-value": startDt.value,
@@ -14297,8 +14263,8 @@ ${_html.style}
14297
14263
  };
14298
14264
  }
14299
14265
  });
14300
- const _hoisted_1$e = { class: "pb-sidebar-properties" };
14301
- const _sfc_main$e = /* @__PURE__ */ vue.defineComponent({
14266
+ const _hoisted_1$d = { class: "pb-sidebar-properties" };
14267
+ const _sfc_main$d = /* @__PURE__ */ vue.defineComponent({
14302
14268
  __name: "PbSidebarProperties",
14303
14269
  setup(__props) {
14304
14270
  const pageBuilder = usePageBuilderEditor();
@@ -14324,8 +14290,8 @@ ${_html.style}
14324
14290
  return part.isLocalMarketingPart();
14325
14291
  });
14326
14292
  return (_ctx, _cache) => {
14327
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$e, [
14328
- showLocalMarketingPart.value ? (vue.openBlock(), vue.createBlock(_sfc_main$f, {
14293
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$d, [
14294
+ showLocalMarketingPart.value ? (vue.openBlock(), vue.createBlock(_sfc_main$e, {
14329
14295
  key: 0,
14330
14296
  "selected-part": vue.unref(selectedParts)[0]
14331
14297
  }, null, 8, ["selected-part"])) : vue.createCommentVNode("", true),
@@ -14333,7 +14299,7 @@ ${_html.style}
14333
14299
  return vue.openBlock(), vue.createElementBlock("div", {
14334
14300
  key: `${partsKey.value}_${group.groupName}`
14335
14301
  }, [
14336
- vue.createVNode(_sfc_main$g, {
14302
+ vue.createVNode(_sfc_main$f, {
14337
14303
  group,
14338
14304
  partsKey: partsKey.value,
14339
14305
  "selected-parts": vue.unref(selectedParts)
@@ -14344,20 +14310,20 @@ ${_html.style}
14344
14310
  };
14345
14311
  }
14346
14312
  });
14347
- const _hoisted_1$d = { class: "pb-sidebar" };
14348
- const _sfc_main$d = /* @__PURE__ */ vue.defineComponent({
14313
+ const _hoisted_1$c = { class: "pb-sidebar" };
14314
+ const _sfc_main$c = /* @__PURE__ */ vue.defineComponent({
14349
14315
  __name: "PbSidebar",
14350
14316
  setup(__props) {
14351
14317
  return (_ctx, _cache) => {
14352
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$d, [
14353
- vue.createVNode(_sfc_main$e)
14318
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$c, [
14319
+ vue.createVNode(_sfc_main$d)
14354
14320
  ]);
14355
14321
  };
14356
14322
  }
14357
14323
  });
14358
- const _hoisted_1$c = { class: "pb-editor bs-layout-vertical flex-grow-1" };
14359
- const _hoisted_2$c = { class: "pb-editor-body bs-layout-horizontal flex-grow-1" };
14360
- const _sfc_main$c = /* @__PURE__ */ vue.defineComponent({
14324
+ const _hoisted_1$b = { class: "pb-editor bs-layout-vertical flex-grow-1" };
14325
+ const _hoisted_2$b = { class: "pb-editor-body bs-layout-horizontal flex-grow-1" };
14326
+ const _sfc_main$b = /* @__PURE__ */ vue.defineComponent({
14361
14327
  __name: "PageBuilderEditor",
14362
14328
  props: {
14363
14329
  instanceId: {},
@@ -14366,7 +14332,8 @@ ${_html.style}
14366
14332
  pageContent: {},
14367
14333
  locales: {},
14368
14334
  locale: {},
14369
- toolbarPlugin: {}
14335
+ toolbarPlugin: {},
14336
+ plugin: {}
14370
14337
  },
14371
14338
  setup(__props, { expose: __expose }) {
14372
14339
  const props = __props;
@@ -14379,6 +14346,8 @@ ${_html.style}
14379
14346
  pageBuilderEditor.setLocales(props.locales);
14380
14347
  if (props.locale)
14381
14348
  pageBuilderEditor.setLocale(props.locale);
14349
+ if (props.plugin)
14350
+ pageBuilderEditor.registerCustomPlugin(props.plugin);
14382
14351
  pageBuilderEditor.registerPlugin({
14383
14352
  // TODO
14384
14353
  commands: createDefaultCommands(modal)
@@ -14395,75 +14364,30 @@ ${_html.style}
14395
14364
  });
14396
14365
  const colorHistory = vue.ref([]);
14397
14366
  vue.provide("colorHistory", colorHistory);
14398
- const getLocalDesignPartContent = () => {
14399
- let content;
14400
- if (pageBuilderEditor.model.rootPart) {
14401
- content = doGetLocalDesignPartContent(pageBuilderEditor.model.rootPart);
14402
- }
14403
- return content;
14404
- };
14405
- const doGetLocalDesignPartContent = (part) => {
14406
- let content;
14407
- if (part.isGlobalDesignPart() || part.isLocalMarketingPart()) {
14408
- const properties = getLocalDesignPartProperties(part);
14409
- if (properties) {
14410
- if (!content)
14411
- content = [];
14412
- content.push({ partId: part.partId, data: properties });
14413
- }
14414
- }
14415
- if (part.children) {
14416
- for (const child of part.children) {
14417
- const childContent = doGetLocalDesignPartContent(child);
14418
- if (childContent)
14419
- content = [...content || [], ...childContent];
14420
- }
14421
- }
14422
- return content;
14423
- };
14424
- const getLocalDesignPartProperties = (part) => {
14425
- let properties;
14426
- if (part.isWidget()) {
14427
- const defs = pageBuilderEditor.partManager.getLocalDesignPartPropertyDefinitions(part.partName);
14428
- if (defs) {
14429
- const data = {};
14430
- for (const def of defs) {
14431
- if (part.properties)
14432
- data[def.propertyName] = part.properties[def.propertyName];
14433
- }
14434
- properties = { [part.partId]: data };
14435
- }
14436
- }
14437
- if (part.children) {
14438
- for (const child of part.children) {
14439
- const childProperties = getLocalDesignPartProperties(child);
14440
- if (childProperties) {
14441
- properties = { ...properties, ...childProperties };
14442
- }
14443
- }
14444
- }
14445
- return properties;
14367
+ const getPageContent = () => {
14368
+ const partIds = (pageBuilderEditor.model.rootPart.children || []).map((v) => v.partId);
14369
+ return pageBuilderEditor.model.serializePageModel(partIds);
14446
14370
  };
14447
14371
  __expose({
14448
- getLocalDesignPartContent
14372
+ getPageContent
14449
14373
  });
14450
14374
  return (_ctx, _cache) => {
14451
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$c, [
14452
- vue.createVNode(_sfc_main$j, { "toolbar-plugin": _ctx.toolbarPlugin }, null, 8, ["toolbar-plugin"]),
14453
- vue.createElementVNode("div", _hoisted_2$c, [
14454
- vue.createVNode(_sfc_main$i),
14455
- vue.createVNode(_sfc_main$n, { class: "flex-grow-1" }),
14456
- vue.createVNode(_sfc_main$d)
14375
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$b, [
14376
+ vue.createVNode(_sfc_main$i, { "toolbar-plugin": _ctx.toolbarPlugin }, null, 8, ["toolbar-plugin"]),
14377
+ vue.createElementVNode("div", _hoisted_2$b, [
14378
+ vue.createVNode(_sfc_main$h),
14379
+ vue.createVNode(_sfc_main$m, { class: "flex-grow-1" }),
14380
+ vue.createVNode(_sfc_main$c)
14457
14381
  ])
14458
14382
  ]);
14459
14383
  };
14460
14384
  }
14461
14385
  });
14462
- const _hoisted_1$b = { class: "property-editor property-editor-readonly-text" };
14463
- const _hoisted_2$b = { class: "title" };
14464
- const _hoisted_3$b = ["textContent"];
14386
+ const _hoisted_1$a = { class: "property-editor property-editor-readonly-text" };
14387
+ const _hoisted_2$a = { class: "title" };
14388
+ const _hoisted_3$a = ["textContent"];
14465
14389
  const _hoisted_4$3 = ["textContent"];
14466
- const _sfc_main$b = /* @__PURE__ */ vue.defineComponent({
14390
+ const _sfc_main$a = /* @__PURE__ */ vue.defineComponent({
14467
14391
  __name: "PbPropertyEditorReadonlyText",
14468
14392
  props: {
14469
14393
  property: {},
@@ -14471,11 +14395,11 @@ ${_html.style}
14471
14395
  },
14472
14396
  setup(__props) {
14473
14397
  return (_ctx, _cache) => {
14474
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$b, [
14475
- vue.createElementVNode("div", _hoisted_2$b, [
14398
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$a, [
14399
+ vue.createElementVNode("div", _hoisted_2$a, [
14476
14400
  vue.createElementVNode("label", {
14477
14401
  textContent: vue.toDisplayString(_ctx.property.caption)
14478
- }, null, 8, _hoisted_3$b)
14402
+ }, null, 8, _hoisted_3$a)
14479
14403
  ]),
14480
14404
  vue.createElementVNode("div", null, [
14481
14405
  vue.createElementVNode("div", {
@@ -14488,12 +14412,12 @@ ${_html.style}
14488
14412
  });
14489
14413
  const PbPropertyEditorReadonlyText = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
14490
14414
  __proto__: null,
14491
- default: _sfc_main$b
14415
+ default: _sfc_main$a
14492
14416
  }, Symbol.toStringTag, { value: "Module" }));
14493
- const _hoisted_1$a = { class: "property-editor property-editor-text flex-align-center" };
14494
- const _hoisted_2$a = { class: "title" };
14495
- const _hoisted_3$a = ["textContent"];
14496
- const _sfc_main$a = /* @__PURE__ */ vue.defineComponent({
14417
+ const _hoisted_1$9 = { class: "property-editor property-editor-text flex-align-center" };
14418
+ const _hoisted_2$9 = { class: "title" };
14419
+ const _hoisted_3$9 = ["textContent"];
14420
+ const _sfc_main$9 = /* @__PURE__ */ vue.defineComponent({
14497
14421
  __name: "PbPropertyEditorText",
14498
14422
  props: {
14499
14423
  property: {},
@@ -14509,11 +14433,11 @@ ${_html.style}
14509
14433
  emit("update-property-value", properties);
14510
14434
  };
14511
14435
  return (_ctx, _cache) => {
14512
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$a, [
14513
- vue.createElementVNode("div", _hoisted_2$a, [
14436
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$9, [
14437
+ vue.createElementVNode("div", _hoisted_2$9, [
14514
14438
  vue.createElementVNode("label", {
14515
14439
  textContent: vue.toDisplayString(_ctx.property.caption)
14516
- }, null, 8, _hoisted_3$a)
14440
+ }, null, 8, _hoisted_3$9)
14517
14441
  ]),
14518
14442
  vue.createElementVNode("div", null, [
14519
14443
  vue.createVNode(vue.unref(bluesea.BSTextInput), {
@@ -14528,12 +14452,12 @@ ${_html.style}
14528
14452
  });
14529
14453
  const PbPropertyEditorText = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
14530
14454
  __proto__: null,
14531
- default: _sfc_main$a
14455
+ default: _sfc_main$9
14532
14456
  }, Symbol.toStringTag, { value: "Module" }));
14533
- const _hoisted_1$9 = { class: "property-editor property-editor-multiline-text" };
14534
- const _hoisted_2$9 = { class: "title" };
14535
- const _hoisted_3$9 = ["textContent"];
14536
- const _sfc_main$9 = /* @__PURE__ */ vue.defineComponent({
14457
+ const _hoisted_1$8 = { class: "property-editor property-editor-multiline-text" };
14458
+ const _hoisted_2$8 = { class: "title" };
14459
+ const _hoisted_3$8 = ["textContent"];
14460
+ const _sfc_main$8 = /* @__PURE__ */ vue.defineComponent({
14537
14461
  __name: "PbPropertyEditorMultilineText",
14538
14462
  props: {
14539
14463
  property: {},
@@ -14559,11 +14483,11 @@ ${_html.style}
14559
14483
  emit("update-property-value", properties);
14560
14484
  };
14561
14485
  return (_ctx, _cache) => {
14562
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$9, [
14563
- vue.createElementVNode("div", _hoisted_2$9, [
14486
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$8, [
14487
+ vue.createElementVNode("div", _hoisted_2$8, [
14564
14488
  vue.createElementVNode("label", {
14565
14489
  textContent: vue.toDisplayString(_ctx.property.caption)
14566
- }, null, 8, _hoisted_3$9)
14490
+ }, null, 8, _hoisted_3$8)
14567
14491
  ]),
14568
14492
  vue.createElementVNode("div", null, [
14569
14493
  _ctx.property.multiLang ? (vue.openBlock(), vue.createBlock(vue.unref(bluesea.BSMultiLangTextArea), {
@@ -14593,12 +14517,12 @@ ${_html.style}
14593
14517
  });
14594
14518
  const PbPropertyEditorMultilineText = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
14595
14519
  __proto__: null,
14596
- default: _sfc_main$9
14520
+ default: _sfc_main$8
14597
14521
  }, Symbol.toStringTag, { value: "Module" }));
14598
- const _hoisted_1$8 = { class: "property-editor property-editor-select flex-align-center" };
14599
- const _hoisted_2$8 = { class: "title" };
14600
- const _hoisted_3$8 = ["textContent"];
14601
- const _sfc_main$8 = /* @__PURE__ */ vue.defineComponent({
14522
+ const _hoisted_1$7 = { class: "property-editor property-editor-select flex-align-center" };
14523
+ const _hoisted_2$7 = { class: "title" };
14524
+ const _hoisted_3$7 = ["textContent"];
14525
+ const _sfc_main$7 = /* @__PURE__ */ vue.defineComponent({
14602
14526
  __name: "PbPropertyEditorSelect",
14603
14527
  props: {
14604
14528
  property: {},
@@ -14617,11 +14541,11 @@ ${_html.style}
14617
14541
  emit("update-property-value", properties);
14618
14542
  };
14619
14543
  return (_ctx, _cache) => {
14620
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$8, [
14621
- vue.createElementVNode("div", _hoisted_2$8, [
14544
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$7, [
14545
+ vue.createElementVNode("div", _hoisted_2$7, [
14622
14546
  vue.createElementVNode("label", {
14623
14547
  textContent: vue.toDisplayString(_ctx.property.caption)
14624
- }, null, 8, _hoisted_3$8)
14548
+ }, null, 8, _hoisted_3$7)
14625
14549
  ]),
14626
14550
  vue.createElementVNode("div", null, [
14627
14551
  vue.createVNode(vue.unref(bluesea.BSSelect), {
@@ -14636,13 +14560,13 @@ ${_html.style}
14636
14560
  });
14637
14561
  const PbPropertyEditorSelect = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
14638
14562
  __proto__: null,
14639
- default: _sfc_main$8
14563
+ default: _sfc_main$7
14640
14564
  }, Symbol.toStringTag, { value: "Module" }));
14641
- const _hoisted_1$7 = { class: "property-editor property-editor-color" };
14642
- const _hoisted_2$7 = { class: "title" };
14643
- const _hoisted_3$7 = ["textContent"];
14565
+ const _hoisted_1$6 = { class: "property-editor property-editor-color" };
14566
+ const _hoisted_2$6 = { class: "title" };
14567
+ const _hoisted_3$6 = ["textContent"];
14644
14568
  const _hoisted_4$2 = { class: "bs-layout-horizontal flex-align-center color" };
14645
- const _sfc_main$7 = /* @__PURE__ */ vue.defineComponent({
14569
+ const _sfc_main$6 = /* @__PURE__ */ vue.defineComponent({
14646
14570
  __name: "PbPropertyEditorColor",
14647
14571
  props: {
14648
14572
  property: {},
@@ -14662,11 +14586,11 @@ ${_html.style}
14662
14586
  emit("update-property-value", properties);
14663
14587
  };
14664
14588
  return (_ctx, _cache) => {
14665
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$7, [
14666
- vue.createElementVNode("div", _hoisted_2$7, [
14589
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$6, [
14590
+ vue.createElementVNode("div", _hoisted_2$6, [
14667
14591
  vue.createElementVNode("label", {
14668
14592
  textContent: vue.toDisplayString(_ctx.property.caption)
14669
- }, null, 8, _hoisted_3$7)
14593
+ }, null, 8, _hoisted_3$6)
14670
14594
  ]),
14671
14595
  vue.createElementVNode("div", _hoisted_4$2, [
14672
14596
  vue.createVNode(PbColorPicker, {
@@ -14691,12 +14615,12 @@ ${_html.style}
14691
14615
  });
14692
14616
  const PbPropertyEditorColor = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
14693
14617
  __proto__: null,
14694
- default: _sfc_main$7
14618
+ default: _sfc_main$6
14695
14619
  }, Symbol.toStringTag, { value: "Module" }));
14696
- const _hoisted_1$6 = { class: "property-editor property-editor-image flex-align-center" };
14697
- const _hoisted_2$6 = { class: "title" };
14698
- const _hoisted_3$6 = ["textContent"];
14699
- const _sfc_main$6 = /* @__PURE__ */ vue.defineComponent({
14620
+ const _hoisted_1$5 = { class: "property-editor property-editor-image flex-align-center" };
14621
+ const _hoisted_2$5 = { class: "title" };
14622
+ const _hoisted_3$5 = ["textContent"];
14623
+ const _sfc_main$5 = /* @__PURE__ */ vue.defineComponent({
14700
14624
  __name: "PbPropertyEditorImage",
14701
14625
  props: {
14702
14626
  property: {},
@@ -14716,11 +14640,11 @@ ${_html.style}
14716
14640
  });
14717
14641
  };
14718
14642
  return (_ctx, _cache) => {
14719
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$6, [
14720
- vue.createElementVNode("div", _hoisted_2$6, [
14643
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$5, [
14644
+ vue.createElementVNode("div", _hoisted_2$5, [
14721
14645
  vue.createElementVNode("label", {
14722
14646
  textContent: vue.toDisplayString(_ctx.property.caption)
14723
- }, null, 8, _hoisted_3$6)
14647
+ }, null, 8, _hoisted_3$5)
14724
14648
  ]),
14725
14649
  vue.createElementVNode("div", null, [
14726
14650
  vue.createElementVNode("button", { onClick: selectImage }, "Select Image")
@@ -14731,12 +14655,12 @@ ${_html.style}
14731
14655
  });
14732
14656
  const PbPropertyEditorImage = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
14733
14657
  __proto__: null,
14734
- default: _sfc_main$6
14658
+ default: _sfc_main$5
14735
14659
  }, Symbol.toStringTag, { value: "Module" }));
14736
- const _hoisted_1$5 = { class: "property-editor property-editor-image flex-align-center" };
14737
- const _hoisted_2$5 = { class: "title" };
14738
- const _hoisted_3$5 = ["textContent"];
14739
- const _sfc_main$5 = /* @__PURE__ */ vue.defineComponent({
14660
+ const _hoisted_1$4 = { class: "property-editor property-editor-image flex-align-center" };
14661
+ const _hoisted_2$4 = { class: "title" };
14662
+ const _hoisted_3$4 = ["textContent"];
14663
+ const _sfc_main$4 = /* @__PURE__ */ vue.defineComponent({
14740
14664
  __name: "PbPropertyEditorHtml",
14741
14665
  props: {
14742
14666
  property: {},
@@ -14771,53 +14695,6 @@ ${_html.style}
14771
14695
  }
14772
14696
  });
14773
14697
  };
14774
- return (_ctx, _cache) => {
14775
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$5, [
14776
- vue.createElementVNode("div", _hoisted_2$5, [
14777
- vue.createElementVNode("label", {
14778
- textContent: vue.toDisplayString(_ctx.property.caption)
14779
- }, null, 8, _hoisted_3$5)
14780
- ]),
14781
- vue.createElementVNode("div", null, [
14782
- vue.createElementVNode("button", { onClick: editHtml }, "Edit HTML")
14783
- ])
14784
- ]);
14785
- };
14786
- }
14787
- });
14788
- const PbPropertyEditorHtml = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
14789
- __proto__: null,
14790
- default: _sfc_main$5
14791
- }, Symbol.toStringTag, { value: "Module" }));
14792
- const _hoisted_1$4 = { class: "property-editor property-editor-product flex-align-center" };
14793
- const _hoisted_2$4 = { class: "title" };
14794
- const _hoisted_3$4 = ["textContent"];
14795
- const _sfc_main$4 = /* @__PURE__ */ vue.defineComponent({
14796
- __name: "PbPropertyEditorProduct",
14797
- props: {
14798
- property: {},
14799
- value: {}
14800
- },
14801
- emits: ["update-property-value"],
14802
- setup(__props, { emit: __emit }) {
14803
- const pageBuilder = usePageBuilderEditor();
14804
- bluesea.useModal();
14805
- const emit = __emit;
14806
- const selectProducts = () => {
14807
- var _a;
14808
- let itemCodes = "";
14809
- const selectedParts = pageBuilder.context.getSelectedParts();
14810
- if (selectedParts && selectedParts.length === 1) {
14811
- itemCodes = ((_a = selectedParts[0].properties) == null ? void 0 : _a.products) || "";
14812
- }
14813
- PageBuilderEditorEvent.emit.requestProducts({
14814
- pageBuilderId: pageBuilder.instanceId,
14815
- itemCodes,
14816
- callback: (products) => {
14817
- emit("update-property-value", { products: products.map((v) => v.itemCode).join(",") });
14818
- }
14819
- });
14820
- };
14821
14698
  return (_ctx, _cache) => {
14822
14699
  return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$4, [
14823
14700
  vue.createElementVNode("div", _hoisted_2$4, [
@@ -14826,13 +14703,13 @@ ${_html.style}
14826
14703
  }, null, 8, _hoisted_3$4)
14827
14704
  ]),
14828
14705
  vue.createElementVNode("div", null, [
14829
- vue.createElementVNode("button", { onClick: selectProducts }, "Select Product")
14706
+ vue.createElementVNode("button", { onClick: editHtml }, "Edit HTML")
14830
14707
  ])
14831
14708
  ]);
14832
14709
  };
14833
14710
  }
14834
14711
  });
14835
- const PbPropertyEditorProduct = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
14712
+ const PbPropertyEditorHtml = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
14836
14713
  __proto__: null,
14837
14714
  default: _sfc_main$4
14838
14715
  }, Symbol.toStringTag, { value: "Module" }));
@@ -15141,14 +15018,14 @@ ${_html.style}
15141
15018
  exports2.PAGE_BUILDER_KEY = PAGE_BUILDER_KEY;
15142
15019
  exports2.PAGE_TYPE = PAGE_TYPE$1;
15143
15020
  exports2.Page = Page;
15144
- exports2.PageBuilderEditor = _sfc_main$c;
15021
+ exports2.PageBuilderEditor = _sfc_main$b;
15145
15022
  exports2.PageBuilderEditorEvent = PageBuilderEditorEvent;
15146
- exports2.PageBuilderViewer = _sfc_main$C;
15023
+ exports2.PageBuilderViewer = _sfc_main$1$1;
15147
15024
  exports2.PageBuilderViewerEvent = PageBuilderViewerEvent;
15148
15025
  exports2.Part = Part;
15026
+ exports2.PbCustomWidget = _sfc_main$B;
15149
15027
  exports2.PbHtmlWidget = _sfc_main$3$1;
15150
15028
  exports2.PbImageWidget = _sfc_main$5$1;
15151
- exports2.PbProductListWidget = _sfc_main$2$1;
15152
15029
  exports2.PbTextWidget = _sfc_main$4$1;
15153
15030
  exports2.ROOT_TYPE = ROOT_TYPE$1;
15154
15031
  exports2.RootPart = RootPart;