@charisol/plexo-sdk 1.4.4 → 1.4.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/PlexoRenderer.d.ts +7 -0
- package/dist/{compiler-Zh5KObm4.js → compiler-DjDpXnfB.js} +11 -1
- package/dist/compiler.js +1 -1
- package/dist/{compilerClient-BwRHkl-b.js → compilerClient-CC6VoeEK.js} +8 -1
- package/dist/compilerClient.js +1 -1
- package/dist/components/icons.d.ts +7 -0
- package/dist/components/properties/accordionSections/CommerceProductPropertiesAccordion.d.ts +10 -0
- package/dist/components/sidebarTabs/ContentTab.d.ts +6 -0
- package/dist/{iconSvgStatic-DEgDUD68.js → iconSvgStatic-CBYk07ko.js} +10 -0
- package/dist/index.js +11025 -10661
- package/dist/plexo-sdk.css +1 -1
- package/dist/utilities/playground.helpers.d.ts +214 -0
- package/dist/utilities/playground.interfaces.d.ts +21 -0
- package/dist/utilities/types.d.ts +1 -1
- package/package.json +1 -1
package/dist/PlexoRenderer.d.ts
CHANGED
|
@@ -46,6 +46,13 @@ export declare const ElementJSONSchema: z.ZodObject<{
|
|
|
46
46
|
blog_categories: "blog_categories";
|
|
47
47
|
blog_comments: "blog_comments";
|
|
48
48
|
blog_post_list: "blog_post_list";
|
|
49
|
+
product: "product";
|
|
50
|
+
booking: "booking";
|
|
51
|
+
shop_grid: "shop_grid";
|
|
52
|
+
cart_summary: "cart_summary";
|
|
53
|
+
checkout_flow: "checkout_flow";
|
|
54
|
+
order_confirmation: "order_confirmation";
|
|
55
|
+
order_tracking: "order_tracking";
|
|
49
56
|
}>;
|
|
50
57
|
style: z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodNumber]>>;
|
|
51
58
|
attributes: z.ZodObject<{
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { a as e, c as t, d as n, f as r, g as i, h as a, i as o, j as s, l as c, m as l, n as u, o as d, p as f, r as p, s as m, t as h, u as g, v as _, y as v } from "./iconSvgStatic-
|
|
1
|
+
import { a as e, c as t, d as n, f as r, g as i, h as a, i as o, j as s, l as c, m as l, n as u, o as d, p as f, r as p, s as m, t as h, u as g, v as _, y as v } from "./iconSvgStatic-CBYk07ko.js";
|
|
2
2
|
//#region src/utilities/responsiveDefaults.ts
|
|
3
3
|
var y = {
|
|
4
4
|
tablet: {
|
|
@@ -580,6 +580,16 @@ var K = (s) => {
|
|
|
580
580
|
let e = s.type.replace(/^blog_/, "").replace(/_([a-z])/g, (e, t) => t.toUpperCase()), t = N(_);
|
|
581
581
|
return `<div${C} data-plexo-blog-${e}="true"${B("data-plexo-blog-prefix", S.prefix)} style="${t}"></div>`;
|
|
582
582
|
}
|
|
583
|
+
case "product":
|
|
584
|
+
case "booking":
|
|
585
|
+
case "shop_grid":
|
|
586
|
+
case "cart_summary":
|
|
587
|
+
case "checkout_flow":
|
|
588
|
+
case "order_confirmation":
|
|
589
|
+
case "order_tracking": {
|
|
590
|
+
let e = s.type.replace(/_([a-z])/g, (e, t) => t.toUpperCase()), t = N(_);
|
|
591
|
+
return `<div${C} data-plexo-commerce-${e}="true"${B("data-plexo-product-id", S.productId)}${B("data-plexo-service-id", S.serviceId)} style="${t}"></div>`;
|
|
592
|
+
}
|
|
583
593
|
case "social": {
|
|
584
594
|
let e = r(s), t = _.textAlign === "center" ? "center" : _.textAlign === "right" ? "flex-end" : "flex-start";
|
|
585
595
|
return `<div${C} style="${N({
|
package/dist/compiler.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as e, c as t, d as n, i as r, l as i, n as a, o, r as s, s as c, t as l, u } from "./compiler-
|
|
1
|
+
import { a as e, c as t, d as n, i as r, l as i, n as a, o, r as s, s as c, t as l, u } from "./compiler-DjDpXnfB.js";
|
|
2
2
|
export { l as DEFAULT_BODY_FONT_FAMILY, a as FORM_NON_CSS_STYLE_KEYS, s as collectResponsiveRule, r as compileToHTML, e as compileToHTMLWithStrataAuto, o as compileToPlainText, c as convertSectionRowToPlexoRow, t as getFormDefaultStyle, i as getInlineStylesImportant, u as htmlToPlainText, n as injectStrataBundle };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { d as e, f as t, g as n, h as r, j as i, k as a, m as o, o as s, p as c, t as l, u, v as d, y as f } from "./iconSvgStatic-
|
|
1
|
+
import { d as e, f as t, g as n, h as r, j as i, k as a, m as o, o as s, p as c, t as l, u, v as d, y as f } from "./iconSvgStatic-CBYk07ko.js";
|
|
2
2
|
//#region src/utilities/instrumentation.ts
|
|
3
3
|
var p = "plexo-node", m = "plexo-row", h = "plexo-col";
|
|
4
4
|
function g(e) {
|
|
@@ -217,6 +217,13 @@ var _ = "https://cdn.jsdelivr.net/npm/@charisol/plexo-sdk@latest/dist/social-ico
|
|
|
217
217
|
case "blog_categories":
|
|
218
218
|
case "blog_comments":
|
|
219
219
|
case "blog_post_list": return `${j}<div${h}${k} data-plexo-blog-${i.type.replace(/^blog_/, "").replace(/_([a-z])/g, (e, t) => t.toUpperCase())}="true"${p.prefix ? ` data-plexo-blog-prefix="${y(p.prefix)}"` : ""} style="${m}"></div>`;
|
|
220
|
+
case "product":
|
|
221
|
+
case "booking":
|
|
222
|
+
case "shop_grid":
|
|
223
|
+
case "cart_summary":
|
|
224
|
+
case "checkout_flow":
|
|
225
|
+
case "order_confirmation":
|
|
226
|
+
case "order_tracking": return `${j}<div${h}${k} data-plexo-commerce-${i.type.replace(/_([a-z])/g, (e, t) => t.toUpperCase())}="true"${p.productId ? ` data-plexo-product-id="${y(p.productId)}"` : ""}${p.serviceId ? ` data-plexo-service-id="${y(p.serviceId)}"` : ""} style="${m}"></div>`;
|
|
220
227
|
default: return `${j}<div${h}${k} style="${m}">${y(p.text || "")}</div>`;
|
|
221
228
|
}
|
|
222
229
|
}, R = (e, t, n) => {
|
package/dist/compilerClient.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as e } from "./compilerClient-
|
|
1
|
+
import { t as e } from "./compilerClient-CC6VoeEK.js";
|
|
2
2
|
export { e as parseJsonToTargetFormat };
|
|
@@ -66,4 +66,11 @@ export declare const ICONS: {
|
|
|
66
66
|
blogCategories: import("react").JSX.Element;
|
|
67
67
|
blogComments: import("react").JSX.Element;
|
|
68
68
|
blogPostList: import("react").JSX.Element;
|
|
69
|
+
commerceProduct: import("react").JSX.Element;
|
|
70
|
+
commerceBooking: import("react").JSX.Element;
|
|
71
|
+
commerceShopGrid: import("react").JSX.Element;
|
|
72
|
+
commerceCart: import("react").JSX.Element;
|
|
73
|
+
commerceCheckout: import("react").JSX.Element;
|
|
74
|
+
commerceOrderConfirmation: import("react").JSX.Element;
|
|
75
|
+
commerceOrderTracking: import("react").JSX.Element;
|
|
69
76
|
};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
/**
|
|
3
|
+
* The one-click part of the `product`/`booking` marker blocks: a dropdown of this site's
|
|
4
|
+
* real, live products/services (fetched by PlexoBuilder.tsx into the `commerceProducts`
|
|
5
|
+
* prop the same way `sitePages` already is), setting attrs.productId/serviceId on
|
|
6
|
+
* selection. No id-copying, no snippet-pasting — pick a product, done. `product` only
|
|
7
|
+
* offers PHYSICAL/SERVICE items sold outright; `booking` only offers SERVICE items (a
|
|
8
|
+
* consultation), since a booking card doesn't make sense for a physical product.
|
|
9
|
+
*/
|
|
10
|
+
export declare const CommerceProductPropertiesAccordion: React.FC<any>;
|
|
@@ -7,6 +7,12 @@ interface ContentTabProps {
|
|
|
7
7
|
templateKind?: "landing_page" | "email" | string;
|
|
8
8
|
/** Shows the "Blog" block group below the regular palette — see PlexoBuilderProps.isBlogLayout. */
|
|
9
9
|
isBlogLayout?: boolean;
|
|
10
|
+
/** Shows the "Commerce" block group below the regular palette — true whenever the host
|
|
11
|
+
* app's current site/org has Commerce enabled (see PlexoBuilderProps.commerceEnabled).
|
|
12
|
+
* Unlike isBlogLayout, this isn't tied to a special template type: a Product or Booking
|
|
13
|
+
* card is a reasonable thing to drop on any ordinary page, so the gate is "does this
|
|
14
|
+
* site sell anything," not "is this a special commerce-only template." */
|
|
15
|
+
commerceEnabled?: boolean;
|
|
10
16
|
onTapAdd?: (data: any) => void;
|
|
11
17
|
}
|
|
12
18
|
export declare const ContentTab: React.FC<ContentTabProps>;
|
|
@@ -539,11 +539,21 @@ var a = (e) => `https://picsum.photos/seed/${encodeURIComponent(e)}/1200/800`, o
|
|
|
539
539
|
value: "'Titillium Web', sans-serif",
|
|
540
540
|
style: "sans"
|
|
541
541
|
},
|
|
542
|
+
{
|
|
543
|
+
label: "Public Sans",
|
|
544
|
+
value: "'Public Sans', sans-serif",
|
|
545
|
+
style: "sans"
|
|
546
|
+
},
|
|
542
547
|
{
|
|
543
548
|
label: "Merriweather",
|
|
544
549
|
value: "'Merriweather', serif",
|
|
545
550
|
style: "serif"
|
|
546
551
|
},
|
|
552
|
+
{
|
|
553
|
+
label: "Fraunces",
|
|
554
|
+
value: "'Fraunces', serif",
|
|
555
|
+
style: "serif"
|
|
556
|
+
},
|
|
547
557
|
{
|
|
548
558
|
label: "Playfair Display",
|
|
549
559
|
value: "'Playfair Display', serif",
|