@goldenhippo/builder-cart-plugin 0.1.0 → 0.2.0

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/README.md ADDED
@@ -0,0 +1,106 @@
1
+ # @goldenhippo/builder-cart-plugin
2
+
3
+ React 18 plugin running inside Builder.io's editor iframe. Manages pages, products, blogs, comments, and brand configuration for Golden Hippo cart/commerce sites.
4
+
5
+ ## Table of Contents
6
+
7
+ - [Features](#features)
8
+ - [Installation in Builder.io](#installation-in-builderio)
9
+ - [Development](#development)
10
+ - [Production (CDN)](#production-cdn)
11
+ - [Plugin Settings](#plugin-settings)
12
+ - [Architecture](#architecture)
13
+ - [Entry Point](#entry-point)
14
+ - [Application](#application)
15
+ - [Core](#core)
16
+ - [Services](#services)
17
+ - [Path Aliases](#path-aliases)
18
+ - [Development Commands](#development-commands)
19
+
20
+ ## Features
21
+
22
+ - **Dashboard** — overview of content across all models
23
+ - **Page Manager** — create, search, filter, and validate pages (General, PDP, Blog)
24
+ - **Products** — browse product catalog from Hippo Commerce API
25
+ - **Blogs** — manage blog content with category filtering
26
+ - **Comments** — approve/reject blog comments
27
+ - **Settings** — user profile and plugin configuration
28
+ - **Auto-provisioning** — automatically creates all 13 Builder.io models on settings save
29
+
30
+ ## Installation in Builder.io
31
+
32
+ ### Development
33
+
34
+ 1. Start the dev server:
35
+ ```bash
36
+ npm run dev:plugin # http://localhost:1268
37
+ ```
38
+ 2. In Builder.io: **Settings > Plugins > Add Plugin**
39
+ 3. Enter URL: `http://localhost:1268/plugin.system.js`
40
+
41
+ ### Production (CDN)
42
+
43
+ After publishing, use the jsdelivr CDN URL:
44
+
45
+ ```
46
+ https://cdn.jsdelivr.net/npm/@goldenhippo/builder-cart-plugin@<version>/dist/plugin.system.js
47
+ ```
48
+
49
+ ## Plugin Settings
50
+
51
+ | Setting | Description |
52
+ | ------------ | ----------------------------------- |
53
+ | Brand | Brand name for multi-brand support |
54
+ | Edit URL | Frontend site URL for page previews |
55
+ | API URL | Hippo Commerce API base URL |
56
+ | API User | Commerce API username |
57
+ | API Password | Commerce API password |
58
+
59
+ Saving settings triggers auto-provisioning of all 13 Builder.io models via the API.
60
+
61
+ ## Architecture
62
+
63
+ ### Entry Point
64
+
65
+ `src/plugin.ts` — registers plugin settings, the app tab ("Hippo CMS"), and the 8-phase model auto-creation flow on settings save.
66
+
67
+ ### Application
68
+
69
+ `src/application/` — app shell and page components:
70
+
71
+ - `AppCore` — MobX state management with cookie-based routing
72
+ - `HippoCMSManager` — wrapper component
73
+ - Pages: Home, PageManager, Products, Blogs, Comments, Settings, Admin
74
+
75
+ ### Core
76
+
77
+ `src/core/models/` — `BuilderHelper` singleton that orchestrates all 13 model definitions. Factory functions are imported from `@goldenhippo/builder-cart-schemas`.
78
+
79
+ ### Services
80
+
81
+ `src/services/` — API clients:
82
+
83
+ - `BuilderApi` — paginated Builder.io content fetching
84
+ - `CommerceApi` — product feed and brand settings via Hippo Commerce API
85
+ - `UserManagementService` — extracts user context from Builder.io
86
+
87
+ ## Path Aliases
88
+
89
+ Configured in both `tsconfig.json` and `webpack.config.js`:
90
+
91
+ | Alias | Path |
92
+ | ---------------- | ------------------ |
93
+ | `@application/*` | `src/application/` |
94
+ | `@components/*` | `src/components/` |
95
+ | `@core/*` | `src/core/` |
96
+ | `@services/*` | `src/services/` |
97
+ | `@utils/*` | `src/utils/` |
98
+
99
+ ## Development Commands
100
+
101
+ ```bash
102
+ npm run dev:plugin # Start dev server on port 1268
103
+ npm run build:plugin # Production build
104
+ npm run typecheck # Type-check with tsc
105
+ npm run lint # Lint with eslint
106
+ ```
@@ -1 +1 @@
1
- System.register(["@builder.io/app-context","@builder.io/react"],function(e,l){var t={},a={};return{setters:[function(e){t.default=e.default||e},function(e){a.Builder=e.Builder}],execute:function(){e((()=>{"use strict";var e={404(e){e.exports=t},522(e){e.exports=a}},l={};function o(t){var a=l[t];if(void 0!==a)return a.exports;var d=l[t]={exports:{}};return e[t](d,d.exports,o),d.exports}var d=o(522),i=o(404);const r="@goldenhippo/hippo-commerce-builder-cart-plugin";var n,p,s,u;!function(e){e.BASIC="BASIC",e.MEDIUM="MEDIUM",e.MEGA="MEGA",e.NONE="NONE",e.DMP="DMP"}(n||(n={})),function(e){e.PRIMARY="primary",e.SECONDARY="secondary",e.OUTLINE="outline",e.LINK="link"}(p||(p={})),function(e){e.SEARCH="search",e.LINKS="links",e.ACCOUNT_LINKS="accountLinks",e.HTML="html",e.TIMED_HTML="timedHtml"}(s||(s={})),function(e){e.LINKS="links",e.LOGO="logo",e.ACCOUNT_LINKS="accountLinks",e.CART_COUNT="cartCount",e.HTML="html"}(u||(u={}));const f={basic:{name:"basicHeaderConfig",showIf:"return options.get('headerType') === 'BASIC'",friendlyName:"Basic Menu Config",type:"object",defaultCollapsed:!0,localized:!1,subFields:[{"@type":"@builder.io/core:Field",name:"logoImage",friendlyName:"Logo Image",type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],required:!1,localized:!0,defaultCollapsed:!0,helperText:"Image displayed in the header"},{"@type":"@builder.io/core:Field",name:"mobileLinks",friendlyName:"Mobile Links",helperText:"Links to display in the mobile dropdown menu",type:"list",localized:!0,defaultCollapsed:!0,subFields:[{name:"title",friendlyName:"Mobile Link Title",helperText:"Title for the mobile link",type:"text",localized:!0,defaultCollapsed:!0,required:!0},{name:"href",friendlyName:"Link URL",helperText:"URL for the mobile link",type:"url",localized:!1,required:!0,defaultCollapsed:!0},{name:"newTab",friendlyName:"New Tab",helperText:"When true, this link will open in a new tab",type:"boolean",localized:!1,defaultCollapsed:!0},{name:"cssClasses",friendlyName:"CSS Classes",helperText:"Used for VWO targeting",type:"Tags",localized:!1,defaultCollapsed:!0}]},{name:"desktopLinks",friendlyName:"Desktop Links",helperText:"Links to display in the desktop menu",type:"list",localized:!0,defaultCollapsed:!0,subFields:[{name:"title",friendlyName:"Desktop Link Title",helperText:"Title for the desktop link",type:"text",localized:!0,defaultCollapsed:!0,required:!0},{name:"href",friendlyName:"Link URL",helperText:"URL for the mobile link",type:"url",localized:!1,defaultCollapsed:!0,required:!0},{name:"newTab",friendlyName:"New Tab",helperText:"When true, this link will open in a new tab",type:"boolean",localized:!1,defaultCollapsed:!0},{name:"cssClasses",friendlyName:"CSS Classes",helperText:"Used for VWO targeting",type:"Tags",localized:!1,defaultCollapsed:!0}]},{name:"ctas",friendlyName:"Call To Action",helperText:"Call to action button(s) to display",type:"list",localized:!0,defaultCollapsed:!0,subFields:[{name:"title",friendlyName:"Desktop Link Title",helperText:"Title for the desktop link",type:"text",localized:!1,defaultCollapsed:!0,required:!0},{name:"href",friendlyName:"Link URL",helperText:"URL for the mobile link",type:"url",localized:!1,defaultCollapsed:!0,required:!0},{name:"type",friendlyName:"CTA Type",helperText:"Select the type of CTA to display",type:"select",localized:!1,defaultCollapsed:!0,required:!0,defaultValue:"primary",enum:[p.PRIMARY,p.SECONDARY,p.OUTLINE,p.LINK]},{name:"newTab",friendlyName:"New Tab",helperText:"When true, this link will open in a new tab",type:"boolean",localized:!1,defaultCollapsed:!0},{name:"cssClasses",friendlyName:"CSS Classes",helperText:"Used for VWO targeting",type:"Tags",localized:!1,defaultCollapsed:!0},{name:"hideOnMobile",friendlyName:"Hide on Mobile",helperText:"Set to true to disable this CTA on mobile devices",type:"boolean",localized:!1,defaultCollapsed:!0}]},{name:"myAccountGuest",friendlyName:"MyAccount Menu Links - Guest",helperText:"Links to show under the My Account menu when the user is logged out.",type:"list",localized:!0,defaultCollapsed:!0,subFields:[{name:"title",friendlyName:"Desktop Link Title",helperText:"Title for the desktop link",type:"text",localized:!1,defaultCollapsed:!0,required:!0},{name:"href",friendlyName:"Link URL",helperText:"URL for the mobile link",type:"url",localized:!1,defaultCollapsed:!0,required:!0},{name:"icon",friendlyName:"Icon",type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],required:!1,defaultCollapsed:!0,helperText:"Link icon"},{name:"newTab",friendlyName:"New Tab",helperText:"When true, this link will open in a new tab",type:"boolean",localized:!1,defaultCollapsed:!0},{name:"cssClasses",friendlyName:"CSS Classes",helperText:"Used for VWO targeting",type:"Tags",localized:!1,defaultCollapsed:!0}]},{name:"myAccountAuthorized",friendlyName:"MyAccount Menu Links - Logged In",helperText:"Links to show under the My Account menu when the user is logged in.",type:"list",localized:!0,defaultCollapsed:!0,subFields:[{name:"title",friendlyName:"Desktop Link Title",helperText:"Title for the desktop link",type:"text",localized:!1,defaultCollapsed:!0,required:!0},{name:"href",friendlyName:"Link URL",helperText:"URL for the mobile link",type:"url",localized:!1,defaultCollapsed:!0,required:!0},{name:"icon",friendlyName:"Icon",type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],required:!1,defaultCollapsed:!0,helperText:"Link icon"},{name:"newTab",friendlyName:"New Tab",helperText:"When true, this link will open in a new tab",type:"boolean",localized:!1,defaultCollapsed:!0},{name:"cssClasses",friendlyName:"CSS Classes",helperText:"Used for VWO targeting",type:"Tags",localized:!1,defaultCollapsed:!0}]},{name:"stickyHeader",type:"object",friendlyName:"Sticky Header Configuration",defaultCollapsed:!0,localized:!1,subFields:[{name:"enabled",type:"boolean",friendlyName:"Enabled?",defaultCollapsed:!0,localized:!1},{name:"backgroundColor",type:"color",friendlyName:"Background Color",defaultCollapsed:!0,localized:!1,helperText:"The header background color at the top of the page. Leave blank for a transparent header"},{name:"scrollBackgroundColor",type:"color",friendlyName:"Background Color - Scroll",defaultCollapsed:!0,localized:!1,helperText:"The header background color while scrolling. Leave blank for a transparent header",defaultValue:"#FFFFFF"},{name:"scrollLogo",friendlyName:"Scroll Logo",type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],required:!1,localized:!0,defaultCollapsed:!0,helperText:"Image displayed in the header while scrolling. Leave blank to use the default header logo"}]},{name:"showLocaleSelection",type:"boolean",friendlyName:"Show Locale Selection?",defaultCollapsed:!0,localized:!1,helperText:"Show Locale Selection"}]},medium:{"@type":"@builder.io/core:Field",name:"mediumHeaderConfig",friendlyName:"Medium Header Configuration",type:"object",showIf:"return options.get('headerType') === 'MEDIUM'",defaultCollapsed:!0,localized:!1,subFields:[{"@type":"@builder.io/core:Field",name:"wrapperID",friendlyName:"Wrapper ID",helperText:"ID for the medium header wrapper",type:"text",localized:!1,defaultValue:"header",defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"wrapperClasses",friendlyName:"Wrapper Classes",helperText:"CSS classes for the medium header wrapper",type:"text",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"showShippingMessage",friendlyName:"Show Shipping Message",helperText:"Display the free shipping message on the mega menu",type:"boolean",localized:!0,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"mobileMenu",friendlyName:"Mobile Menu",helperText:"Mobile menu configuration for the medium header",type:"object",localized:!1,defaultCollapsed:!0,subFields:[{"@type":"@builder.io/core:Field",name:"logo",friendlyName:"Logo",helperText:"Logo for the mobile header",type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"logoClasses",friendlyName:"Logo Classes",helperText:"CSS classes for the mobile logo",type:"text",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"navClasses",friendlyName:"Navigation Classes",helperText:"CSS classes for the mobile navigation",type:"text",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"dropDownWrapperClasses",friendlyName:"Dropdown Wrapper Classes",helperText:"CSS classes for the dropdown wrapper",type:"text",localized:!1,required:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"dropDownContent",friendlyName:"Dropdown Content",helperText:"Content to display in the dropdown",type:"list",localized:!1,required:!1,defaultCollapsed:!0,subFields:[{"@type":"@builder.io/core:Field",name:"type",friendlyName:"Dropdown Type",helperText:"Select the type of dropdown content",type:"select",enum:[s.SEARCH,s.LINKS,s.ACCOUNT_LINKS,s.HTML,s.TIMED_HTML],defaultValue:"links",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"links",friendlyName:"Links",helperText:"Links for this dropdown",type:"list",localized:!1,defaultCollapsed:!0,subFields:[{"@type":"@builder.io/core:Field",name:"itemClasses",friendlyName:"Item Classes",helperText:"CSS classes for the link item",type:"text",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"loggedInOnly",friendlyName:"Logged In Only",helperText:"Display this link only when the user is logged in",type:"boolean",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"loggedOutOnly",friendlyName:"Logged Out Only",helperText:"Display this link only when the user is logged out",type:"boolean",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"text",friendlyName:"Link Title",helperText:"Title for the link",type:"html",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"URL",friendlyName:"URL",helperText:"URL for the link",type:"url",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"subLinksWrapperClasses",friendlyName:"Sub Links Wrapper Classes",helperText:"CSS classes for the sub-links wrapper",type:"text",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"subLinks",friendlyName:"Sub Links",helperText:"Sub-links for this dropdown item",type:"list",localized:!1,defaultCollapsed:!0,subFields:[{"@type":"@builder.io/core:Field",name:"text",friendlyName:"Link Title",helperText:"Title for the link",type:"text",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"URL",friendlyName:"Link Title",helperText:"Title for the link",type:"text",localized:!1,defaultCollapsed:!0}]}]},{"@type":"@builder.io/core:Field",name:"htmlContent",friendlyName:"HTML Content",helperText:"HTML content to display in the dropdown",type:"html",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"inputs",friendlyName:"Inputs",helperText:"Inputs for the dropdown content",type:"object",localized:!1,required:!0,defaultCollapsed:!0,subFields:[{"@type":"@builder.io/core:Field",name:"defaultHtml",friendlyName:"Default HTML",helperText:"Default HTML content that will be displayed",type:"html",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"temporaryHtml",friendlyName:"Temporary HTML",helperText:"Temporary HTML content that will be displayed for a limited time",type:"html",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"startTime",friendlyName:"Start Time",helperText:"Start time for the timed HTML content",type:"timestamp",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"endTime",friendlyName:"End Time",helperText:"End time for the timed HTML content",type:"timestamp",localized:!1,defaultCollapsed:!0}]}]}]},{"@type":"@builder.io/core:Field",name:"desktopMenu",friendlyName:"Desktop Menu",helperText:"Desktop menu configuration for the medium header",type:"object",localized:!1,defaultCollapsed:!0,subFields:[{"@type":"@builder.io/core:Field",name:"logo",friendlyName:"Logo",helperText:"Logo for the desktop header",type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"navClasses",friendlyName:"Navigation Classes",helperText:"CSS classes for the desktop navigation",type:"text",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"content",friendlyName:"Content",helperText:"Content to display in the desktop header",type:"list",localized:!1,required:!1,defaultCollapsed:!0,subFields:[{"@type":"@builder.io/core:Field",name:"type",friendlyName:"Content Type",helperText:"Select the type of content",type:"select",enum:[u.LINKS,u.LOGO,u.ACCOUNT_LINKS,u.CART_COUNT,u.HTML],defaultValue:"links",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"wrapperClasses",friendlyName:"Wrapper Classes",helperText:"CSS classes for the wrapper",type:"text",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"links",friendlyName:"Links",helperText:"Links for the desktop header",type:"list",localized:!1,defaultCollapsed:!0,subFields:[{"@type":"@builder.io/core:Field",name:"text",friendlyName:"Link Text",helperText:"Text for the link",type:"html",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"URL",friendlyName:"URL",helperText:"URL for the link",type:"url",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"loggedInOnly",friendlyName:"Logged In Only",helperText:"Display this link only when the user is logged in",type:"boolean",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"loggedOutOnly",friendlyName:"Logged Out Only",helperText:"Display this link only when the user is logged out",type:"boolean",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"dropdownWrapperClasses",friendlyName:"Dropdown Wrapper Classes",helperText:"CSS classes for the dropdown wrapper",type:"text",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"dropdownItemClasses",friendlyName:"Dropdown Item Classes",helperText:"CSS classes for the dropdown item",type:"text",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"subLinks",friendlyName:"Sub Links",helperText:"Sub-links for this header item",type:"list",localized:!1,defaultCollapsed:!0,subFields:[{"@type":"@builder.io/core:Field",name:"columnHeaderTitle",friendlyName:"Column Header Title",helperText:"Title for the column header",type:"text",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"columnContentType",friendlyName:"Column Content Type",helperText:"Select the type of content for the column",type:"select",enum:["links","html","timedHtml"],defaultValue:"links",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"links",friendlyName:"Links",helperText:"Links for the column",type:"list",localized:!1,defaultCollapsed:!0,subFields:[{"@type":"@builder.io/core:Field",name:"text",friendlyName:"Text",helperText:"Text for the link",type:"text",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"URL",friendlyName:"URL",helperText:"URL for the link",type:"url",localized:!1,defaultCollapsed:!0}]},{"@type":"@builder.io/core:Field",name:"content",friendlyName:"Content",helperText:"Content for the column",type:"html",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"inputs",friendlyName:"Inputs",helperText:"Inputs for the dropdown content",type:"object",localized:!1,required:!0,defaultCollapsed:!0,subFields:[{"@type":"@builder.io/core:Field",name:"defaultHtml",friendlyName:"Default HTML",helperText:"Default HTML content that will be displayed",type:"html",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"temporaryHtml",friendlyName:"Temporary HTML",helperText:"Temporary HTML content that will be displayed for a limited time",type:"html",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"startTime",friendlyName:"Start Time",helperText:"Start time for the timed HTML content",type:"timestamp",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"endTime",friendlyName:"End Time",helperText:"End time for the timed HTML content",type:"timestamp",localized:!1,defaultCollapsed:!0}]}]}]},{"@type":"@builder.io/core:Field",name:"accountLinksConfig",friendlyName:"Account Links Config",helperText:"",type:"object",localized:!1,defaultCollapsed:!0,subFields:[{"@type":"@builder.io/core:Field",name:"dropdownWrapperClasses",friendlyName:"Dropdown Wrapper Classes",helperText:"CSS classes for the dropdown wrapper",type:"text",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"dropdownItemClasses",friendlyName:"Dropdown Item Classes",helperText:"CSS classes for the dropdown item",type:"text",localized:!1,defaultCollapsed:!0}]},{"@type":"@builder.io/core:Field",name:"htmlContent",friendlyName:"HTML Content",helperText:"HTML content to display in the header",type:"html",localized:!1,defaultCollapsed:!0}]}]},{"@type":"@builder.io/core:Field",name:"bannersAboveHeader",friendlyName:"Banners Above Header",helperText:"Banners to display above the header",type:"list",localized:!0,defaultCollapsed:!0,subFields:[{"@type":"@builder.io/core:Field",name:"wrapperClasses",friendlyName:"Wrapper Classes",helperText:"CSS classes for the banner wrapper",type:"text",localized:!0,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"content",friendlyName:"Banner Content",helperText:"Content to display in the banner",type:"html",localized:!0,defaultCollapsed:!0}]},{"@type":"@builder.io/core:Field",name:"contactUrl",friendlyName:"Contact URL",helperText:"URL for the contact page",type:"url",localized:!0,defaultCollapsed:!0}]},mega:{"@type":"@builder.io/core:Field",name:"megaMenuConfig",showIf:"return options.get('headerType') === 'MEGA'",friendlyName:"Mega Menu Config",type:"object",defaultCollapsed:!0,localized:!1,subFields:[{"@type":"@builder.io/core:Field",name:"showShippingMessage",friendlyName:"Show Shipping Message",helperText:"Display the free shipping message on the mega menu",type:"boolean",localized:!0,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"mobileLinks",friendlyName:"Mobile Links",helperText:"Links to display in the mobile mega menu",type:"list",localized:!0,defaultCollapsed:!0,subFields:[{"@type":"@builder.io/core:Field",name:"title",friendlyName:"Mobile Link Title",helperText:"Title for the mobile link",type:"text",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"href",friendlyName:"Link URL",helperText:"URL for the mobile link",type:"url",localized:!1,required:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"expanded",friendlyName:"Expanded",helperText:"Indicates if the mobile link is expanded by default",type:"boolean",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"links",friendlyName:"Sub-Links",helperText:"Sub-links for the mobile link",type:"list",localized:!1,required:!1,defaultCollapsed:!0,subFields:[{"@type":"@builder.io/core:Field",name:"title",friendlyName:"Link Title",helperText:"Title for the link",type:"text",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"href",friendlyName:"Link URL",helperText:"URL for the link",type:"url",localized:!1,required:!0,defaultCollapsed:!0}]}]},{"@type":"@builder.io/core:Field",name:"desktopShopNavLinks",friendlyName:"Desktop Shop Navigation Links",helperText:"Links to display in the desktop shop navigation",type:"list",localized:!0,defaultCollapsed:!0,subFields:[{"@type":"@builder.io/core:Field",name:"title",friendlyName:"Link Title",helperText:"Title for the desktop link",type:"text",localized:!1,required:!0,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"links",friendlyName:"Links",helperText:"Links for the desktop navigation",type:"list",localized:!1,required:!1,defaultCollapsed:!0,subFields:[{"@type":"@builder.io/core:Field",name:"title",friendlyName:"Link Title",helperText:"Title for the link",type:"text",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"href",friendlyName:"Link URL",helperText:"URL for the link",type:"url",localized:!1,required:!0,defaultCollapsed:!0}]},{"@type":"@builder.io/core:Field",name:"shopAllLink",friendlyName:"Shop All Link",helperText:'Link to the "Shop All" page',type:"object",localized:!1,required:!1,defaultCollapsed:!0,subFields:[{"@type":"@builder.io/core:Field",name:"title",friendlyName:"Link Title",helperText:"Title for the link",type:"text",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"href",friendlyName:"Link URL",helperText:"URL for the link",type:"url",localized:!1,required:!0,defaultCollapsed:!0}]}]}]},dmp:{"@type":"@builder.io/core:Field",name:"dmpHeaderConfig",showIf:"return options.get('headerType') === 'DMP'",friendlyName:"DMP Header Config",type:"object",defaultCollapsed:!0,localized:!1,subFields:[{"@type":"@builder.io/core:Field",name:"logoImage",friendlyName:"Logo Image",type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],required:!1,localized:!0,defaultCollapsed:!0,helperText:"Image displayed in the header"},{"@type":"@builder.io/core:Field",name:"mobileLinks",friendlyName:"Mobile Links",helperText:"Links to display in the mobile dropdown menu",type:"list",localized:!0,defaultCollapsed:!0,subFields:[{"@type":"@builder.io/core:Field",name:"title",friendlyName:"Mobile Link Title",helperText:"Title for the mobile link",type:"text",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"href",friendlyName:"Link URL",helperText:"URL for the mobile link",type:"url",localized:!1,required:!1,defaultCollapsed:!0}]},{"@type":"@builder.io/core:Field",name:"desktopLinks",friendlyName:"Desktop Links",helperText:"Links to display in the desktop menu",type:"list",localized:!0,defaultCollapsed:!0,subFields:[{"@type":"@builder.io/core:Field",name:"title",friendlyName:"Desktop Link Title",helperText:"Title for the desktop link",type:"text",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"href",friendlyName:"Link URL",helperText:"URL for the mobile link",type:"url",localized:!1,required:!1,defaultCollapsed:!0}]}]}};var m,c,y;!function(e){e.BASIC="BASIC",e.MEGA="MEGA",e.NONE="NONE"}(m||(m={})),function(e){e.DROPDOWN="Dropdown",e.STACKED_LIST="Stacked List"}(c||(c={})),function(e){e.P="/p",e.PRODUCT="/product"}(y||(y={}));const h=e=>({name:"features",friendlyName:"Features",type:"object",defaultCollapsed:!0,subFields:[{name:"productGridFilterType",friendlyName:"Product Grid Filter Type",type:"select",defaultCollapsed:!0,helperText:"Select the type of filters to use. 'Dropdown' will display a drop down of categories, ingredients, use cases, and tags. \n 'Stacked List' allows you to create your own filter groupings from amongst those four filter types.",enum:[c.DROPDOWN,c.STACKED_LIST],defaultValue:"Dropdown"},{name:"productGridFilterGroups",friendlyName:"Product Grid Filter Groups",type:"list",defaultCollapsed:!0,helperText:"Select the filter groups to use. They will be presented in the order entered",subFields:[{name:"filterConfig",friendlyName:"Product Grid Filter",type:"reference",defaultCollapsed:!0,modelId:e,helperText:"Select a product grid filter group to display",copyOnAdd:!1}],showIf:"return options.get('productGridFilterType') === 'Custom'"},{name:"productGridHideRestricted",friendlyName:"Hide Restricted Products",helperText:"Hide restricted products from your product grid based on the user's selected country",type:"boolean",localized:!1,defaultCollapsed:!0},{name:"productLinkPrefix",friendlyName:"Product Link Prefix",helperText:'Set the prefix to append before product slugs throughout your site. For example, if you enter "p", all links from the product grid will be {website}/p/{product-slug}',type:"select",enum:[y.P,y.PRODUCT],localized:!1,defaultCollapsed:!0,defaultValue:"/p"},{name:"subscriptionAddOnsEnabled",friendlyName:"Subscription Add-Ons Enabled",helperText:"Enable or disable subscription add-ons for the brand",type:"boolean",localized:!1,defaultCollapsed:!0},{name:"shippingThresholdNotificationEnabled",friendlyName:"Shipping Threshold Notification Enabled",helperText:"Enable or disable shipping threshold notifications for the brand",type:"boolean",localized:!0,defaultCollapsed:!0},{name:"bundlingEnabled",friendlyName:"Enable Bundling Experience",helperText:"Enable or disable the bundling experience for the brand",type:"boolean",localized:!1,defaultCollapsed:!0}]});var g,b;!function(e){e.DoNotLike="DoNotLike",e.NotWorking="NotWorking",e.NoBenefits="NoBenefits",e.NoFitNoNeed="NoFitNoNeed",e.Budget="Budget",e.Mistake="Mistake",e.Try="Try",e.TooMuch="TooMuch",e.TravelMove="TravelMove",e.DoNotNeed="DoNotNeed",e.AnotherReason="AnotherReason",e.NotHelpingSkin="NotHelpingSkin",e.SkinImproved="SkinImproved",e.PetDoesNotLike="PetDoesNotLike",e.NotHelpingPet="NotHelpingPet",e.NoneGiven="NoneGiven"}(g||(g={})),function(e){e.Link="link",e.Update="update",e.Keep="keep",e.Continue="continue",e.Cancel="cancel"}(b||(b={}));const C=e=>[{name:"brandDisplayName",friendlyName:"Brand Display Name",type:"text",defaultCollapsed:!0,localized:!1,required:!0},{name:"images",friendlyName:"Brand Images",type:"object",defaultCollapsed:!0,localized:!1,subFields:[{name:"brandLogoSmall",friendlyName:"Logo (Small)",type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],localized:!0,helperText:"Small logo for the brand",defaultCollapsed:!0},{name:"brandLogoLarge",friendlyName:"Logo (Large)",type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],localized:!0,helperText:"Large logo for the brand",defaultCollapsed:!0},{name:"brandLogoFooter",friendlyName:"Logo (Footer)",type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],localized:!0,helperText:"Footer logo for the brand",defaultCollapsed:!0},{name:"bbbImage",friendlyName:"BBB Image",type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],localized:!0,helperText:"BBB logo for the brand",defaultCollapsed:!0},{name:"accesibilityLogo",friendlyName:"Accessibility Logo",type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],localized:!0,helperText:"Accessibility logo for the brand",defaultCollapsed:!0},{name:"brandLogoOffWhite",friendlyName:"Logo (Off-White)",type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],localized:!0,helperText:"Off white logo for the brand",defaultCollapsed:!0},{name:"defaultPetProfileImage",friendlyName:"Default Pet Profile Image",type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],localized:!0,helperText:"Default image for pet profiles",defaultCollapsed:!0},{name:"defaultCatProfileImage",friendlyName:"Default Cat Profile Image",type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],localized:!0,helperText:"Default image for cat profiles",defaultCollapsed:!0},{name:"defaultDogProfileImage",friendlyName:"Default Dog Profile Image",type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],localized:!0,helperText:"Default image for dog profiles",defaultCollapsed:!0},{name:"linklessPageHeaderLogo",friendlyName:"Linkless Header Image",type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],localized:!0,helperText:"Logo Image for the linkless header",defaultCollapsed:!0}]},{name:"links",friendlyName:"General Links",type:"object",defaultCollapsed:!0,localized:!1,subFields:[{name:"termsLink",friendlyName:"Terms of Service Link",type:"url",localized:!1,helperText:"Link to the terms of service page",defaultCollapsed:!0},{name:"subscriptionTermsLink",friendlyName:"Subscription Terms of Service Link",type:"url",localized:!1,helperText:"Link to the subscription terms of service page",defaultCollapsed:!0},{name:"privacyLink",friendlyName:"Privacy Policy Link",type:"url",localized:!1,helperText:"Link to the privacy policy page",defaultCollapsed:!0},{name:"ccpaLink",friendlyName:"CCPA Link",type:"url",localized:!1,helperText:"Link to the CCPA page",defaultCollapsed:!0},{name:"bbbLink",friendlyName:"BBB Link",type:"url",localized:!1,helperText:"Link to the Better Business Bureau page",defaultCollapsed:!0},{name:"accessibiltyLink",friendlyName:"Accessibility Link",type:"url",localized:!1,helperText:"Link to the accessibility page",defaultCollapsed:!0},{name:"socialMedia",friendlyName:"Social Media Links",type:"object",localized:!1,helperText:"",defaultCollapsed:!0,subFields:[{name:"twitter",friendlyName:"Twitter",type:"url",localized:!1,helperText:"",defaultCollapsed:!0},{name:"facebook",friendlyName:"Facebook",type:"url",localized:!1,helperText:"",defaultCollapsed:!0},{name:"youtube",friendlyName:"Youtube",type:"url",localized:!1,helperText:"",defaultCollapsed:!0},{name:"instagram",friendlyName:"Instagram",type:"url",localized:!1,helperText:"",defaultCollapsed:!0},{name:"pinterest",friendlyName:"Pinterest",type:"url",localized:!1,helperText:"",defaultCollapsed:!0},{name:"tiktok",friendlyName:"Tiktok",type:"url",localized:!1,helperText:"",defaultCollapsed:!0}]}]},{name:"banners",friendlyName:"Banners",helperText:"Select the banner(s) to display site-wide. These will be displayed in the\n order provided, and always above page-specific announcements",type:"list",defaultCollapsed:!0,localized:!1,subFields:[{name:"banner",friendlyName:"Sitewide Banner",type:"reference",localized:!1,helperText:"Select the banner to display.",defaultCollapsed:!0,modelId:e,copyOnAdd:!1},{name:"alwaysShow",friendlyName:"Always Show?",type:"boolean",localized:!1,helperText:'By default, we hide sitewide banners on the classic "cart" pages. Use this setting to bypass those restrictions',defaultCollapsed:!0}]}],T={name:"blog-comment",displayName:"Blog Comment",kind:"data",helperText:"Comments on your website's blogs",contentTitleField:void 0,fields:[{name:"name",friendlyName:"Name",helperText:"Name of the user who submitted this comment",type:"text",defaultCollapsed:!1,localized:!1,required:!0},{name:"date",friendlyName:"Date",helperText:"Date this comment was submitted",type:"timestamp",defaultCollapsed:!1,localized:!1,required:!0},{name:"status",friendlyName:"Status",helperText:"Select the status of this comment. Only Approved comments will be displayed",type:"select",enum:["Pending Approval","Approved","Rejected"],defaultValue:"Pending Approval",defaultCollapsed:!1,localized:!1,required:!0},{type:"text",name:"email",friendlyName:"Email",required:!1,defaultCollapsed:!1},{type:"html",name:"comment",friendlyName:"Comment",helperText:"HTML content of the comment",required:!0,defaultCollapsed:!1},{name:"language",friendlyName:"Language",helperText:"The language code of this comment. Legacy comments are synced as 'en'",type:"select",enum:["en"],defaultCollapsed:!0,localized:!1,defaultValue:"en",required:!0},{name:"locale",friendlyName:"Locale",helperText:"The country code of this comment. Legacy comments are synced as 'US'",type:"select",enum:["US"],defaultValue:"US",defaultCollapsed:!0,localized:!1,required:!0},{name:"parentId",friendlyName:"Parent Comment Id",helperText:"If this comment is a reply, this is the Id of the parent",type:"text",required:!1,defaultCollapsed:!0},{name:"internal",friendlyName:"Brand Response",helperText:"Indicates that this is a comment provided by the brand (i.e. a response)",type:"boolean",defaultCollapsed:!1,required:!1}],hideFromUI:!0};var N,x,w,k,S,z,F,L,I;!function(e){e.FlavorOptionGroup="Flavor/Option Group",e.TrialGroup="Trial Group"}(N||(N={})),function(e){e.Inclusive="Inclusive",e.Exclusive="Exclusive"}(x||(x={})),function(e){e.AboveHeader="Above Header",e.BelowHeader="Below Header"}(w||(w={})),function(e){e.GENERAL="General",e.PRODUCT="Product",e.BLOG="Blog"}(k||(k={})),function(e){e.PRODUCT="Product",e.PRODUCT_GROUP="Product Group"}(S||(S={})),function(e){e.VERTICAL="Vertical",e.VERTICAL__FLAVOR_DROPDOWN__TYPE_TOGGLE="Vertical - Flavor Dropdown - Type Toggle",e.STACKED__FLAVOR_BUTTONS__QUANTITY_TOGGLE="Stacked - Flavor Buttons - Quantity Toggle"}(z||(z={})),function(e){e.SLIDER_A="Slider A",e.SLIDER_B="Slider B"}(F||(F={})),function(e){e.ONE_TIME="One-Time Purchase",e.SUBSCRIPTION="Subscription"}(L||(L={})),function(e){e.PERCENT="percentage",e.DOLLAR="dollar"}(I||(I={}));const v=new class{ingredientsModel={name:"product-ingredient",displayName:"Product Ingredient",kind:"data",helperText:"Ingredients used in products",contentTitleField:"name",fields:[{"@type":"@builder.io/core:Field",name:"name",friendlyName:"Ingredient",type:"text",required:!0,defaultCollapsed:!0,localized:!0,defaultValue:{"@type":"@builder.io/core:LocalizedValue"}},{"@type":"@builder.io/core:Field",name:"description",friendlyName:"Description",type:"longText",required:!1,defaultCollapsed:!0,localized:!0,defaultValue:{"@type":"@builder.io/core:LocalizedValue"}},{"@type":"@builder.io/core:Field",name:"image",friendlyName:"Image",type:"file",showTemplatePicker:!0,defaultCollapsed:!0,allowedFileTypes:["jpeg","png","svg","webp"]},{"@type":"@builder.io/core:Field",name:"shortDescription",friendlyName:"Short Description",type:"longText",required:!1,defaultCollapsed:!0,localized:!0,defaultValue:{"@type":"@builder.io/core:LocalizedValue"}},{"@type":"@builder.io/core:Field",name:"searchKeys",friendlyName:"Search Keys",type:"Tags",defaultCollapsed:!0,helperText:'Used when building links (e.g. "products?category=[Search Key]")',required:!1,localized:!1}]};categoryModel={name:"product-category",kind:"data",displayName:"Product Category",helperText:"Categories for products",contentTitleField:"name",fields:[{name:"name",friendlyName:"Category",type:"text",required:!0,defaultCollapsed:!0,localized:!0},{name:"description",friendlyName:"Description",type:"longText",required:!1,defaultCollapsed:!0,localized:!0},{name:"desktopImage",friendlyName:"Desktop Image",type:"file",defaultCollapsed:!0,showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"]},{name:"mobileImage",defaultCollapsed:!0,friendlyName:"Mobile Image",type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"]},{name:"hidden",friendlyName:"Hide Category",type:"boolean",required:!1,localized:!0,defaultCollapsed:!0,helperText:"When true, this category will not be displayed in product grids or search results for this locale"},{name:"slug",friendlyName:"Page Slug",type:"text",defaultCollapsed:!0,helperText:'If this category has a specific web page, provide the path here without a leading slash (e.g. "shop/supplements") for use in breadcrumb navigation. By default, the path "shop" will be used.',required:!1,localized:!1},{name:"searchKeys",friendlyName:"Search Keys",type:"Tags",defaultCollapsed:!0,helperText:'Used when building links (e.g. "products?category=[Search Key]")',required:!1,localized:!1}]};productTagModel={name:"product-tag",kind:"data",displayName:"Product Tag",helperText:"Provides a link between products across categories.",contentTitleField:"name",fields:[{name:"name",friendlyName:"Tag",type:"text",required:!0,defaultCollapsed:!0,localized:!0},{name:"tagColor",friendlyName:"Color",type:"color",required:!0,defaultCollapsed:!0,localized:!1,defaultValue:"gba(255, 233, 214, 1)"},{name:"hidden",friendlyName:"Hide Tag",type:"boolean",required:!1,localized:!0,defaultCollapsed:!0,helperText:"When true, this tag will not be displayed in product grids or search results for this locale"},{name:"image",friendlyName:"Tag Image",type:"file",allowedFileTypes:["jpeg","png","svg","webp"],required:!1,localized:!0,defaultCollapsed:!0,helperText:"For product grids that support tag images, you may provide the image here."},{name:"pluralDisplayName",friendlyName:"Plural Display Name",defaultCollapsed:!0,type:"text",helperText:'This is used when grouping/filtering. Allows us to display "Favorites" instead of "Fave", for example.',required:!1,localized:!0}]};useCaseModel={name:"product-use-case",kind:"data",displayName:"Product Use Case",helperText:"Provides a link between products used for the same goal.",contentTitleField:"name",fields:[{name:"name",defaultCollapsed:!0,friendlyName:"Use Case",type:"text",required:!0,localized:!0},{name:"description",friendlyName:"Description",type:"longText",defaultCollapsed:!0,required:!1,localized:!0},{name:"searchKeys",friendlyName:"Search Keys",type:"Tags",defaultCollapsed:!0,helperText:'Used when building links (e.g. "products?category=[Search Key]")',required:!1,localized:!1},{name:"image",friendlyName:"Image",defaultCollapsed:!0,type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"]},{name:"hidden",friendlyName:"Hide Use Case",type:"boolean",required:!1,localized:!0,defaultCollapsed:!0,helperText:"When true, this use case will not be displayed in product grids or search results for this locale"}]};blogCategoryModel={name:"blog-category",displayName:"Blog Category",kind:"data",helperText:"Category for blog categorization",contentTitleField:void 0,fields:[{name:"name",friendlyName:"Name",helperText:"Name of the category",type:"text",defaultCollapsed:!1,localized:!0,required:!0},{name:"description",friendlyName:"Category Description",helperText:"Provide a description of the category. This may be used in components.",type:"html",defaultCollapsed:!1,localized:!0,required:!1},{name:"slug",friendlyName:"Slug",helperText:"Path to use for linking to this category",type:"text",defaultCollapsed:!1,localized:!1,required:!0},{name:"parentId",friendlyName:"Parent Category Id",helperText:"If this category is a child, provide the Id of the parent category",type:"text",required:!1,defaultCollapsed:!0,localized:!1}]};productModel(e){return(e=>({name:"product",displayName:"Product",kind:"data",helperText:"Product Catalog",contentTitleField:"name",fields:[{name:"displayName",friendlyName:"Display Name",type:"text",required:!0,localized:!0,defaultCollapsed:!0,helperText:"This is the name that will be displayed to the customer"},{name:"featuredImage",friendlyName:"Featured Image",helperText:"Displayed on the product card",defaultCollapsed:!0,type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"]},{name:"secondaryImage",friendlyName:"Secondary Image",helperText:"Displayed on the product card hover for some grids",defaultCollapsed:!0,type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"]},{name:"subHeading",defaultCollapsed:!0,friendlyName:"Product Headline",helperText:"Subheading (tagline) for the product, displayed on the product card",type:"text",localized:!0},{name:"gridTagline",defaultCollapsed:!0,friendlyName:"Grid Tagline",helperText:"By default, we use the Product Headline field. Use this to override the tagline when displayed on the product grid.",type:"text",required:!1,localized:!0},{name:"gridDescription",defaultCollapsed:!0,friendlyName:"Grid Description",helperText:"A small description, used on some product grids as an additional sub-heading or tagline.",type:"text",required:!1,localized:!0},{name:"shortDescription",defaultCollapsed:!0,friendlyName:"Short Description",helperText:"Short description of the product, typically displayed on the PDP",type:"html",required:!1,localized:!0},{name:"quote",friendlyName:"Quote",defaultCollapsed:!0,helperText:"A quote provided by the brand guru or spokesperson",type:"html",localized:!0,required:!1},{name:"packagingLabels",friendlyName:"Packaging Labels",defaultCollapsed:!0,type:"object",subFields:[{name:"singular",friendlyName:"Singular",defaultCollapsed:!0,type:"text",required:!0,localized:!0,helperText:"Provides the name of the packaging for single product (e.g. Unit, Jar, etc.)"},{name:"plural",defaultCollapsed:!0,friendlyName:"Plural",type:"text",required:!0,localized:!0,helperText:"Provides the name of the packaging for multiple quantities of the product (e.g. Units, Jars, etc.)"}]},{name:"hidden",friendlyName:"Hide Product",type:"boolean",required:!1,localized:!0,defaultCollapsed:!0,helperText:"When true, this product will not be displayed in product grids or search results for this locale"},{name:"outOfStock",friendlyName:"Out of Stock",type:"boolean",required:!1,defaultCollapsed:!0,helperText:"Indicates whether this product is currently out of stock. When true, this product is not eligible for purchase."},{name:"cartOutOfStock",friendlyName:"Out of Stock (Site)",type:"boolean",required:!1,defaultCollapsed:!0,helperText:"Indicates that this product should be presented as out of stock on the site, even if it is not truly out of stock. This is used as an override for special cases where the product should not be purchasable on the site while remaining purchasable elsewhere."},{name:"upc",defaultCollapsed:!0,friendlyName:"UPC Code",type:"text",required:!1,helperText:"The UPC code of this product"},{name:"reviews",friendlyName:"Review Data",helperText:"Stores review data for this product. These values are automatically generated and should not be modified.",type:"object",defaultCollapsed:!0,subFields:[{name:"id",defaultCollapsed:!0,friendlyName:"Review ID",type:"text",required:!0,localized:!1,helperText:"ID used by the review service to identify this product. Do not modify this value."},{defaultCollapsed:!0,name:"count",friendlyName:"Review Count",type:"number",defaultValue:0,required:!0,localized:!1,helperText:"The number of reviews for this product. This value is automatically updated by the review service."},{name:"averageRating",friendlyName:"Average Rating",type:"number",defaultCollapsed:!0,defaultValue:0,required:!0,localized:!1,helperText:"The average rating for this product. This value is automatically updated by the review service."}]},{name:"tags",friendlyName:"Tags",type:"list",localized:!0,defaultCollapsed:!0,subFields:[{type:"reference",modelId:e.tagModelId,name:"tag",friendlyName:"Tag",copyOnAdd:!1,defaultCollapsed:!0}]},{name:"categories",friendlyName:"Categories",type:"list",localized:!0,defaultCollapsed:!0,subFields:[{type:"reference",modelId:e.categoryModelId,name:"category",friendlyName:"Category",copyOnAdd:!1,defaultCollapsed:!0}]},{name:"ingredients",friendlyName:"Ingredients",type:"list",localized:!0,defaultCollapsed:!0,subFields:[{type:"reference",modelId:e.ingredientsModelId,name:"ingredient",friendlyName:"Ingredient",copyOnAdd:!1,defaultCollapsed:!0}]},{name:"useCases",defaultCollapsed:!0,friendlyName:"Use Cases",type:"list",localized:!0,subFields:[{type:"reference",modelId:e.useCaseModelId,name:"useCase",friendlyName:"Use Case",copyOnAdd:!1,defaultCollapsed:!0}]},{name:"name",friendlyName:"Name",type:"text",required:!0,defaultCollapsed:!0,localized:!1,helperText:"Internal name for the product, used for identification in the CMS"},{name:"gh",friendlyName:"Golden Hippo Integration Data",helperText:"Stores integration data for Golden Hippo. Do not modify any of these values.",type:"object",subFields:[{name:"slug",friendlyName:"Page Slug",type:"text",required:!0,localized:!1,defaultCollapsed:!0,helperText:"This is the URL slug for this product. This value is unique and required for cross-environment development. Do not modify this value."},{name:"productionId",friendlyName:"Production ID",type:"text",required:!0,localized:!1,defaultCollapsed:!0,helperText:"This is the unique identifier for this product in the production environment. Do not modify this value."},{name:"type",friendlyName:"Product Type",type:"select",required:!0,localized:!1,defaultCollapsed:!0,enum:["Product","Bundle","Trial Size"],defaultValue:"Product",helperText:"Product Type"}],defaultCollapsed:!0,localized:!1}]}))(e)}productGroupModel(e){return(e=>({name:"product-group",displayName:"Product Group",kind:"data",helperText:"Groups related products together (e.g. flavors, trial sizes).",contentTitleField:"displayName",fields:[{name:"displayName",friendlyName:"Display Name",type:"text",required:!0,defaultCollapsed:!0,localized:!0,helperText:"The display name of this product group."},{name:"featuredImage",friendlyName:"Featured Image",type:"file",defaultCollapsed:!0,showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],helperText:"The primary image of this product group."},{name:"subHeading",friendlyName:"Sub Heading",type:"text",required:!1,defaultCollapsed:!0,localized:!0,helperText:"A short tagline displayed beneath the group name."},{name:"gridTagline",friendlyName:"Grid Tagline",type:"text",required:!1,defaultCollapsed:!0,localized:!0,helperText:"A short tagline displayed on product grid cards."},{name:"shortDescription",friendlyName:"Short Description",type:"longText",required:!1,defaultCollapsed:!0,localized:!0,helperText:"A short description of the product group."},{name:"products",friendlyName:"Products",type:"list",defaultCollapsed:!0,helperText:"The products in this group.",subFields:[{name:"product",friendlyName:"Product",type:"reference",defaultCollapsed:!1,modelId:e,copyOnAdd:!1},{name:"displayName",friendlyName:"Display Name",type:"text",defaultCollapsed:!1,localized:!0,helperText:"Override display name for this product in the group context."},{name:"isTrialSize",friendlyName:"Is Trial Size",type:"boolean",defaultCollapsed:!1,helperText:"Whether this product is a trial size variant."}]},{name:"selectionLabel",friendlyName:"Selection Label",type:"text",required:!1,defaultCollapsed:!0,localized:!0,helperText:'Label for the product selector (e.g. "Choose your flavor").'},{name:"hidden",friendlyName:"Hide Group",type:"boolean",required:!1,defaultCollapsed:!0,localized:!0,helperText:"When true, this product group will not be displayed."},{name:"gh",friendlyName:"Golden Hippo",type:"object",defaultCollapsed:!0,subFields:[{name:"productionId",friendlyName:"Production ID",type:"text",defaultCollapsed:!1,helperText:"The production environment content ID for this product group."},{name:"slug",friendlyName:"Slug",type:"text",defaultCollapsed:!1,helperText:"URL slug for this product group."}]},{name:"groupType",friendlyName:"Group Type",type:"select",defaultCollapsed:!0,enum:[N.FlavorOptionGroup,N.TrialGroup],helperText:"The type of product grouping."},{name:"name",friendlyName:"Group Name",type:"text",required:!0,defaultCollapsed:!0,localized:!1,helperText:"The internal name for this product group."}]}))(e)}productGridConfigModel(e){return(e=>({name:"product-grid-filter-group",displayName:"Product Grid Filter Group",kind:"data",helperText:"Build filter group configurations. These can be applied in the brand configuration",contentTitleField:"displayName",fields:[{name:"displayName",friendlyName:"Display Name/Label",type:"text",localized:!0,defaultCollapsed:!1,helperText:"Provide a name to display for this grouping",makeEntryTitle:!0},{name:"categories",friendlyName:"Categories",helperText:"Categories for this group",type:"list",defaultCollapsed:!0,subFields:[{name:"category",friendlyName:"Category",type:"reference",modelId:e.categoryId,required:!0,localized:!1,copyOnAdd:!0,defaultCollapsed:!1}]},{name:"ingredients",friendlyName:"Ingredients",helperText:"Ingredients for this group",type:"list",defaultCollapsed:!0,subFields:[{name:"ingredient",friendlyName:"Ingredient",type:"reference",modelId:e.ingredientId,required:!0,localized:!1,copyOnAdd:!0,defaultCollapsed:!1}]},{name:"useCases",friendlyName:"Use Cases",helperText:"Use Cases for this group",type:"list",defaultCollapsed:!0,subFields:[{name:"useCase",friendlyName:"Use Case",type:"reference",modelId:e.useCaseId,required:!0,localized:!1,copyOnAdd:!0,defaultCollapsed:!1}],copyOnAdd:!1},{name:"tags",friendlyName:"Tags",helperText:"Tags for this group",type:"list",defaultCollapsed:!0,subFields:[{name:"tag",friendlyName:"Tag",type:"reference",modelId:e.tagId,required:!0,localized:!1,copyOnAdd:!0,defaultCollapsed:!1}],copyOnAdd:!1},{name:"filterApplicationType",friendlyName:"Filter Application Type",type:"select",enum:[x.Inclusive,x.Exclusive],defaultValue:"Inclusive",required:!1,defaultCollapsed:!0,helperText:"Select how this filter is applied in relation to other filters. When set to Exclusive, ALL results must match a selected filter of this group."}]}))(e)}brandConfig(e,l){return((e,l)=>({name:"gh-brand-config",kind:"data",displayName:"Brand Configuration",helperText:"Manage global features and settings for your website",contentTitleField:void 0,fields:[...C(l),{name:"header",friendlyName:"Header",type:"object",defaultCollapsed:!0,subFields:[{name:"headerType",friendlyName:"Type",helperText:"Select the type of header to use",defaultCollapsed:!0,type:"select",enum:[n.BASIC,n.MEDIUM,n.MEGA,n.NONE,n.DMP],defaultValue:"MEDIUM"},f.basic,f.medium,f.mega,f.dmp]},{name:"footer","@type":"@builder.io/core:Field",friendlyName:"Footer",type:"object",defaultCollapsed:!0,subFields:[{name:"footerType",friendlyName:"Type",type:"select",enum:[m.BASIC,m.MEGA,m.NONE],defaultValue:m.BASIC,defaultCollapsed:!0}]},h(e),{name:"support",friendlyName:"Support Information",type:"object",defaultCollapsed:!0,localized:!1,subFields:[{name:"email",friendlyName:"Support Email",type:"text",required:!0,localized:!0,helperText:"Email address for customer support inquiries",defaultCollapsed:!0},{name:"phone",friendlyName:"Support Phone Number",type:"text",required:!0,localized:!0,helperText:"Phone number for customer support inquiries",defaultCollapsed:!0},{name:"phoneDisplay",friendlyName:"Support Phone Display",type:"text",required:!0,localized:!0,helperText:"Formatted phone number for display",defaultCollapsed:!0},{name:"address",friendlyName:"Support Address",type:"object",required:!0,localized:!1,helperText:"Support address for customer inquiries",defaultCollapsed:!0,subFields:[{name:"street",friendlyName:"Street",type:"text",required:!0,helperText:"Street address for support",defaultCollapsed:!0},{name:"city",friendlyName:"City",type:"text",required:!0,helperText:"City for support address",defaultCollapsed:!0},{name:"state",friendlyName:"State Code",type:"text",required:!0,helperText:"State code for support address (e.g. CA)",defaultCollapsed:!0},{name:"zipcode",friendlyName:"Zip Code",type:"text",required:!0,helperText:"Zip code for support address",defaultCollapsed:!0}]},{name:"addressString",friendlyName:"Support Address String",type:"text",required:!1,localized:!1,helperText:"The full support address as a string",defaultCollapsed:!0}]},{name:"pageConfig",friendlyName:"Page Configurations",type:"object",defaultCollapsed:!0,subFields:[{name:"accountDetails",friendlyName:"Account Details Page",type:"object",defaultCollapsed:!0,subFields:[{name:"birthdayBannerConfig",friendlyName:"Birthday Banner Configuration",type:"object",defaultCollapsed:!0,subFields:[{name:"content",friendlyName:"Banner Content",type:"html",required:!1,localized:!0,defaultCollapsed:!0},{name:"linkText",friendlyName:"Link Text",type:"text",localized:!0,defaultCollapsed:!0},{name:"linkUrl",friendlyName:"Link URL",type:"url",required:!1,localized:!0,defaultCollapsed:!0},{name:"styles",friendlyName:"Styles",type:"object",defaultCollapsed:!0,subFields:[{name:"display",friendlyName:"Display",type:"text",defaultCollapsed:!0},{name:"alignItems",friendlyName:"Align Items",type:"text",defaultCollapsed:!0},{name:"margin",friendlyName:"Margin",type:"text",defaultCollapsed:!0},{name:"padding",friendlyName:"Padding",type:"text",defaultCollapsed:!0},{name:"backgroundColor",friendlyName:"Background Color",type:"color",required:!1,localized:!1,defaultCollapsed:!0},{name:"color",friendlyName:"Color",type:"color",required:!1,localized:!1,defaultCollapsed:!0}]}]}]},{name:"cart",friendlyName:"Cart Page",type:"object",defaultCollapsed:!0,localized:!1,subFields:[{name:"continueShoppingUrl",friendlyName:"Continue Shopping URL",type:"url",required:!1,localized:!1,defaultCollapsed:!0},{name:"imageContainerBGColor",friendlyName:"Background color for Image Container",type:"color",required:!1,localized:!1,defaultCollapsed:!0},{name:"freeShippingBanner",friendlyName:"Free Shipping Banner Configuration",type:"object",defaultCollapsed:!0,subFields:[{name:"isVisible",friendlyName:"Show Free Shipping Banner",type:"boolean",required:!1,localized:!0,defaultCollapsed:!0},{name:"loggedOutBannerContent",friendlyName:"Logged Out Banner Content",type:"html",required:!1,localized:!0,defaultCollapsed:!0},{name:"loggedInBannerContent",friendlyName:"Logged In Banner Content",type:"html",required:!1,localized:!0,defaultCollapsed:!0},{name:"styles",friendlyName:"Styles",type:"object",defaultCollapsed:!0,subFields:[{name:"backgroundColor",friendlyName:"Background Color",type:"color",required:!1,localized:!1,defaultCollapsed:!0},{name:"color",friendlyName:"Color",type:"color",required:!1,localized:!1,defaultCollapsed:!0}]}]},{name:"notices",friendlyName:"Cart Notices",type:"object",defaultCollapsed:!0,subFields:[{name:"securePaymentNotice",friendlyName:"Secure Payment Notice",type:"object",defaultCollapsed:!0,subFields:[{name:"isVisible",friendlyName:"Visible?",type:"boolean",localized:!0,helperText:"Show the secure payment notice on the cart page",defaultCollapsed:!0},{name:"text",friendlyName:"Text",type:"html",required:!1,localized:!0,helperText:"Content for the secure payment notice",defaultCollapsed:!0},{name:"styles",friendlyName:"Styles",type:"object",helperText:"Styles for the secure payment notice",defaultCollapsed:!0,subFields:[{name:"backgroundColor",friendlyName:"Background Color",type:"color",defaultCollapsed:!0},{name:"color",friendlyName:"Color",type:"color",defaultCollapsed:!0}]}]}]}]},{name:"checkout",friendlyName:"Checkout Page",type:"object",defaultCollapsed:!0,localized:!1,subFields:[{name:"freeShippingBanner",friendlyName:"Free Shipping Banner",type:"object",defaultCollapsed:!0,subFields:[{name:"isVisible",friendlyName:"Visible?",type:"boolean",required:!1,localized:!0,helperText:"Show the free shipping banner on the checkout page",defaultCollapsed:!0},{name:"loggedOutBannerContent",friendlyName:"Logged Out Banner Content",type:"html",required:!1,localized:!0,helperText:"Content for the free shipping banner when the user is not logged in",defaultCollapsed:!0},{name:"loggedInBannerContent",friendlyName:"Logged In Banner Content",type:"html",required:!1,localized:!0,helperText:"Content for the free shipping banner when the user is logged in",defaultCollapsed:!0}]},{name:"securePaymentNotice",friendlyName:"Secure Payment Notice",type:"object",defaultCollapsed:!0,subFields:[{name:"isVisible",friendlyName:"Visible?",type:"boolean",required:!1,localized:!0,helperText:"Show the secure payment notice on the checkout page",defaultCollapsed:!0},{name:"content",friendlyName:"Content",type:"html",required:!1,localized:!0,helperText:"Content for the secure payment notice",defaultCollapsed:!0}]},{name:"autoSignUp",friendlyName:"Auto Sign Up",type:"object",defaultCollapsed:!0,subFields:[{name:"isVisible",friendlyName:"Visible?",type:"boolean",required:!1,localized:!0,helperText:"Show the secure payment notice on the checkout page",defaultCollapsed:!0},{name:"isChecked",friendlyName:"Checked by Default",type:"boolean",required:!1,localized:!0,helperText:"Whether the checkbox is checked by default",defaultCollapsed:!0},{name:"labelText",friendlyName:"Label Text",type:"html",required:!1,localized:!0,helperText:"Text for the auto sign up checkbox",defaultCollapsed:!0},{name:"helpModal",friendlyName:"Help Modal",type:"object",defaultCollapsed:!0,subFields:[{name:"header",friendlyName:"Header",type:"html",required:!1,localized:!0,helperText:"Header content for the auto sign up help modal",defaultCollapsed:!0},{name:"content",friendlyName:"Content",type:"html",required:!1,localized:!0,helperText:"Content for the auto sign up help modal",defaultCollapsed:!0}]}]},{name:"smsOptIn",friendlyName:"SMS Opt In",helperText:"Use these settings to control whether you offer SMS sign up on the checkout form.",type:"object",defaultCollapsed:!0,subFields:[{name:"isVisible",friendlyName:"Enabled?",type:"boolean",required:!1,localized:!0,helperText:"Show SMS opt-in at checkout to guests or returning customers who have not yet opted-in",defaultCollapsed:!0},{name:"title",friendlyName:"Title",type:"text",required:!1,localized:!0,helperText:"The text to display on this section title",defaultCollapsed:!0},{name:"content",friendlyName:"CTA Content",type:"html",required:!1,localized:!0,helperText:"Text for the SMS sign up CTA.",defaultCollapsed:!0}]}]},{name:"orderDetails",friendlyName:"Order Details Page",type:"object",defaultCollapsed:!0,localized:!1,subFields:[{name:"title",friendlyName:"Title",type:"html",required:!1,localized:!0,helperText:"Title for the order details section on the checkout page",defaultCollapsed:!0},{name:"tableHeaderStyle",friendlyName:"Table Header Style",type:"object",required:!1,localized:!1,helperText:"Style for the order details table header",defaultCollapsed:!0,subFields:[{name:"color",friendlyName:"Color",type:"color",required:!1,localized:!1,helperText:"Text color for the order details table header",defaultCollapsed:!0},{name:"backgroundColor",friendlyName:"Background Color",type:"color",required:!1,localized:!1,helperText:"Background color for the order details table header",defaultCollapsed:!0}]},{name:"tableContentStyle",friendlyName:"Table Content Style",type:"object",required:!1,localized:!1,helperText:"Style for the order details table content",defaultCollapsed:!0,subFields:[{name:"backgroundColor",friendlyName:"Background Color",type:"color",required:!1,localized:!1,helperText:"Background color for the order details table content",defaultCollapsed:!0}]},{name:"buyItAgainButton",friendlyName:"Buy It Again Button",type:"object",required:!1,localized:!1,defaultCollapsed:!0,helperText:'Configuration for the "Buy It Again" button in the order details section',subFields:[{name:"text",friendlyName:"Button Text",type:"html",required:!1,localized:!0,helperText:'Text to display on the "Buy It Again" button',defaultCollapsed:!0},{name:"classes",friendlyName:"Classes",type:"text",required:!1,localized:!1,helperText:'CSS classes to apply to the "Buy It Again" button',defaultCollapsed:!0}]},{name:"reOrderAllButton",friendlyName:"Re-Order All Button",type:"object",required:!1,localized:!1,defaultCollapsed:!0,helperText:'Configuration for the "Re-Order All" button in the order details section',subFields:[{name:"text",friendlyName:"Button Text",type:"html",required:!1,localized:!0,helperText:'Text to display on the "Re-Order All" button',defaultCollapsed:!0},{name:"classes",friendlyName:"Classes",type:"text",required:!1,localized:!1,helperText:'CSS classes to apply to the "Re-Order All" button',defaultCollapsed:!0}]}]},{name:"resetPassword",friendlyName:"Reset Password Page",type:"object",defaultCollapsed:!0,localized:!1,subFields:[{name:"title",friendlyName:"Page Title",type:"html",required:!1,localized:!0,helperText:"Title for the reset password page",defaultCollapsed:!0}]},{name:"subscriptionCancel",friendlyName:"Subscription Cancellation Page",type:"object",defaultCollapsed:!0,localized:!1,subFields:[{name:"cancelText",friendlyName:"Cancel Text",type:"html",required:!1,localized:!0,helperText:"Text displayed on the subscription cancellation page",defaultCollapsed:!0},{name:"cancelReasons",friendlyName:"Cancel Reasons",type:"list",required:!1,localized:!0,defaultCollapsed:!0,helperText:"List of reasons for subscription cancellation",subFields:[{name:"title",friendlyName:"Reason",type:"text",required:!0,helperText:"The reason for cancellation.",localized:!0,makeEntryTitle:!0,defaultCollapsed:!0},{name:"text",friendlyName:"Display Content",type:"html",required:!1,helperText:"This is the content that will be displayed for this cancellation reason",localized:!0,defaultCollapsed:!0},{name:"identifier",friendlyName:"Identifier",type:"select",required:!0,defaultCollapsed:!0,helperText:"",enum:[g.DoNotLike,g.NotWorking,g.NoBenefits,g.NoFitNoNeed,g.Budget,g.Mistake,g.Try,g.TooMuch,g.TravelMove,g.DoNotNeed,g.AnotherReason,g.NotHelpingSkin,g.SkinImproved,g.PetDoesNotLike,g.NotHelpingPet,g.NoneGiven]},{name:"buttons",friendlyName:"Buttons",type:"list",required:!1,defaultCollapsed:!0,subFields:[{name:"text",friendlyName:"Button Text",type:"text",required:!1,helperText:"Text to display on the button",defaultCollapsed:!0},{name:"link",friendlyName:"Button Link",type:"url",required:!1,helperText:"",defaultCollapsed:!0},{name:"type",type:"select",friendlyName:"Button Type",required:!1,helperText:"",enum:[b.Link,b.Update,b.Keep,b.Continue,b.Cancel],defaultValue:"link",defaultCollapsed:!0}],helperText:"Buttons to display for this cancellation reason."}]}]},{name:"subscriptionEdit",friendlyName:"Subscription Edit",type:"object",defaultCollapsed:!0,localized:!1,subFields:[{name:"subscriptionItemDefaultImage",friendlyName:"Subscription Item Default Image",type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],required:!1,localized:!1,defaultCollapsed:!0,helperText:"Default image to display for subscription items"},{name:"shipNow",friendlyName:"Ship Now",type:"object",required:!1,defaultCollapsed:!0,localized:!1,subFields:[{name:"modalHeadlineContent",friendlyName:"Modal Headline Content",type:"html",required:!0,helperText:"Headline text displayed in the Ship Now modal",localized:!0,defaultCollapsed:!0},{name:"modalContent",friendlyName:"Modal Content",type:"html",required:!0,helperText:"Main content displayed in the Ship Now modal. You can use $FREQUENCY and it will be replaced with the frequency of the subscription.",localized:!0,defaultCollapsed:!0}]}]},{name:"upsell",friendlyName:"Upsell Page",type:"object",defaultCollapsed:!0,localized:!1,subFields:[{name:"mbgImage",friendlyName:"Money Back Guarantee Image",type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],required:!1,localized:!0,defaultCollapsed:!0,helperText:"Image displayed on the upsell page for the money back guarantee"},{name:"mbgText",friendlyName:"Money Back Guarantee Text",type:"html",required:!1,localized:!0,defaultCollapsed:!0,helperText:"Text displayed on the upsell page for the money back guarantee"}]}]},{name:"cookieConfig",friendlyName:"Cookie Configuration",type:"object",defaultCollapsed:!0,subFields:[{name:"popupBanner",friendlyName:"Cookie Policy Popup Banner",type:"object",defaultCollapsed:!0,helperText:"Configure the cookie policy popup banner",subFields:[{name:"content",friendlyName:"Content",type:"html",localized:!0,defaultCollapsed:!0,helperText:"Content for the cookie policy popup banner"},{name:"bannerStyles",friendlyName:"Banner Styles",type:"object",defaultCollapsed:!0,subFields:[{name:"backgroundColor",friendlyName:"Background Color",type:"color",required:!1,defaultCollapsed:!0},{name:"borderRadius",friendlyName:"Border Radius",type:"text",required:!1,defaultCollapsed:!0}]},{name:"buttonStyles",friendlyName:"Button Styles",type:"object",defaultCollapsed:!0,subFields:[{name:"backgroundColor",friendlyName:"Background Color",type:"color",required:!1,defaultCollapsed:!0},{name:"color",friendlyName:"Color",type:"color",required:!1,defaultCollapsed:!0}]}]}]}]}))(e,l)}siteBanner(e){return(e=>({name:"banner",kind:"component",displayName:"Banner / Announcement",helperText:"Banners / Announcements to display on your website",contentTitleField:void 0,fields:[{name:"position",friendlyName:"Banner Position",type:"select",enum:[w.AboveHeader,w.BelowHeader],defaultValue:"Above Header",helperText:"Select where this banner should appear on the page",defaultCollapsed:!0}],editingUrlLogic:"return `"+e+"/builder-banner-section?builder.preview=true&builder.frameEditing=true`"}))(e)}defaultWebsiteSection(e){return(e=>({name:"default-website-section",kind:"component",displayName:"Default Website Section",helperText:"Default section for the website",contentTitleField:void 0,fields:[{name:"sectionType",friendlyName:"Section Type",type:"select",required:!0,localized:!1,defaultCollapsed:!0,enum:["cartPageAboveSummaryContent","cartPageBelowSummaryContent","cartPageEmptyCartContent","cartPageTopSectionContent","gdprContent","mainFooter","offerSelectorAboveCTAContent","offerSelectorBelowCTAContent","subscriptionManagementNoSubsContent"],helperText:"Section Type"}],editingUrlLogic:"return `"+e+"/builder-default-website-section?builder.preview=true&builder.frameEditing=true`"}))(e)}pageModel(e){return(e=>{const{productModelId:l,productGroupModelId:t,categoryModelId:a,bannerModelId:o,blogCategoryModelId:d,editUrl:i}=e;return{name:"page",displayName:"Page",kind:"page",helperText:"Default model for creating pages",contentTitleField:void 0,fields:[{name:"title",friendlyName:"Title",type:"text",required:!0,helperText:"A short title for this page. If the SEO Page Title is not provided, this field is used for SEO. This field is not localized, so it is highly suggested to use the Heading.",defaultCollapsed:!1},{name:"pageType",friendlyName:"Page Type",type:"select",defaultValue:k.GENERAL,required:!0,helperText:"Select the type of page. This will determine which components are added automatically.",enum:[k.GENERAL,k.BLOG,k.PRODUCT],defaultCollapsed:!1},{name:"pdp",friendlyName:"Product Detail Page",type:"object",required:!1,subFields:[{name:"type",friendlyName:"Type",type:"select",defaultValue:S.PRODUCT,required:!0,helperText:"",enum:[S.PRODUCT,S.PRODUCT_GROUP],defaultCollapsed:!1},{name:"product",friendlyName:"Product",type:"reference",required:!1,helperText:"Select the product to display",modelId:l,copyOnAdd:!0,showIf:"return options.get('type') === 'Product'",defaultCollapsed:!1},{name:"productGroup",friendlyName:"Product Group",type:"reference",required:!1,helperText:"",modelId:t,copyOnAdd:!0,showIf:"return options.get('type') === 'Product Group'",defaultCollapsed:!1},{name:"slides",friendlyName:"Product Slides",type:"list",required:!1,subFields:[{name:"image",friendlyName:"Image",type:"file",required:!0,helperText:"",allowedFileTypes:["jpeg","png","svg","webp"],copyOnAdd:!0,defaultCollapsed:!1}],helperText:"Select the image slides to display for this product. If no slides are provided, the product's default image will be used.",copyOnAdd:!0,defaultCollapsed:!1},{name:"slideThumbs",friendlyName:"Product Slides Thumbnails",type:"list",required:!1,subFields:[{name:"image",friendlyName:"Image",type:"file",required:!0,helperText:"",allowedFileTypes:["jpeg","png","svg","webp"],copyOnAdd:!0,defaultCollapsed:!1}],helperText:"Select the image thumbnails slides to display for this product. If no slides are provided, the Product Slides will be used",copyOnAdd:!0,defaultCollapsed:!1},{name:"sliderComponent",type:"select",enum:[F.SLIDER_A,F.SLIDER_B],friendlyName:"Slider Component",defaultValue:F.SLIDER_A,required:!1,helperText:"Select the style slider component to use for the product images",defaultCollapsed:!1},{"@type":"@builder.io/core:Field",name:"hideNativeOfferSelector",friendlyName:"Hide Native Offer Selector",helperText:"Set to true to fully hide the native Offer Selector to provide your own (e.g. via VWO)",type:"boolean",localized:!1,defaultCollapsed:!0,advanced:!0},{name:"offerSelector",friendlyName:"Offer Selector",type:"object",required:!1,subFields:[{name:"osType",friendlyName:"Type",type:"select",defaultValue:z.VERTICAL__FLAVOR_DROPDOWN__TYPE_TOGGLE,required:!1,helperText:"Select the type of offer selector to display",enum:[z.VERTICAL,z.VERTICAL__FLAVOR_DROPDOWN__TYPE_TOGGLE,z.STACKED__FLAVOR_BUTTONS__QUANTITY_TOGGLE],defaultCollapsed:!1},{name:"features",friendlyName:"Features",type:"object",required:!1,subFields:[{name:"defaultPurchaseType",friendlyName:"Default Purchase Type",type:"select",defaultValue:L.ONE_TIME,required:!1,helperText:"When both purchase options are available to the customer, this is the option that will be selected by default.",enum:[L.ONE_TIME,L.SUBSCRIPTION],defaultCollapsed:!1},{name:"preferredQuantity",friendlyName:"Initial Offer Quantity",type:"number",defaultValue:3,required:!1,helperText:"Enter the quantity you would prefer users see first. If that quantity is not available,\n we will locate the closest quantity available (defaults to 3 if not set).",defaultCollapsed:!1},{name:"showSavings",friendlyName:"Show Savings?",type:"boolean",defaultValue:{Default:!0},required:!1,helperText:"",defaultCollapsed:!1},{name:"savingsType",friendlyName:"Savings Type",type:"select",defaultValue:I.PERCENT,required:!1,helperText:"When showing savings, display as a percentage or value saved.",enum:[I.PERCENT,I.DOLLAR],defaultCollapsed:!1},{name:"showMemberPriceMessage",friendlyName:"Show Member Price Message",type:"boolean",defaultValue:{Default:!0},required:!1,helperText:"",defaultCollapsed:!1},{name:"showSubscriptionPriceMessage",friendlyName:"Show Subscription Price Message",type:"boolean",defaultValue:{Default:!0},required:!1,helperText:"",defaultCollapsed:!1},{name:"scrollToTopOffset",friendlyName:"Scroll to Top Offset (px)",type:"number",defaultValue:170,required:!1,helperText:'The number of pixels to offset the Scroll to Top button. Note: The label for this button may be set in the "Labels" section.',defaultCollapsed:!1},{name:"enableAnonymousSubscriptions",friendlyName:"Always Show Subscriptions",type:"boolean",defaultValue:{},required:!1,helperText:"Enable this to present subscriptions (when available) to non-MyAccount visitors. By default, a user must be logged in to access this option.",defaultCollapsed:!1,hidden:!1,advanced:!0}],helperText:"",defaultCollapsed:!1},{name:"labels",friendlyName:"Labels",type:"object",defaultValue:{subscriptionOffer:{Default:"Or $PRICE when you subscribe & save"},subscriptionToggle:{Default:"Subscribe & save"},scrollButton:{Default:'<span class="material-icons">keyboard_arrow_up</span> Back to top'},actionButton:{Default:"ADD TO CART"},outOfStockFormSuccess:{Default:'<p class="text-center">We will notify you as soon as this item is back in stock.</p>'},otpToggle:{Default:"Single purchase"},flavorSelector:{Default:"Choose a flavor"},outOfStock:{Default:'Sorry, we"re currently out of stock'},memberOffer:{Default:"Or pay member price of"}},required:!1,subFields:[{name:"actionButton",friendlyName:"Action Button",type:"text",defaultValue:{Default:"ADD TO CART"},required:!1,helperText:"",defaultCollapsed:!1},{name:"subscriptionOffer",friendlyName:"Subscription Offer",type:"text",defaultValue:{Default:"Or $PRICE when you subscribe & save"},required:!1,helperText:"Use $PRICE to represent the price, this will be automatically replaced.",defaultCollapsed:!1},{name:"memberOffer",friendlyName:"Member Offer",type:"text",defaultValue:{Default:"Or pay member price of"},required:!1,helperText:"",defaultCollapsed:!1},{name:"subscriptionToggle",friendlyName:"Subscription Toggle",type:"text",defaultValue:{Default:"Subscribe & save"},required:!1,helperText:"The label for the button when selecting a subscription",defaultCollapsed:!1},{name:"otpToggle",friendlyName:"One-Time Purchase Toggle",type:"text",defaultValue:{Default:"Single purchase"},required:!1,helperText:"The label for the button when selecting a single purchase (otp).",defaultCollapsed:!1},{name:"outOfStock",friendlyName:"Out of Stock",type:"text",defaultValue:{Default:'Sorry, we"re currently out of stock'},required:!1,helperText:"The text to display when this product is marked as Out of Stock.",defaultCollapsed:!1},{name:"outOfStockFormSuccess",friendlyName:"OOS Form Success Message",type:"html",defaultValue:{Default:'<p class="text-center">We will notify you as soon as this item is back in stock.</p>'},required:!1,helperText:"The message displayed when a user requests to be notified when this product is back in stock.",defaultCollapsed:!1},{name:"scrollButton",friendlyName:"Scroll Button Content",type:"html",defaultValue:{Default:'<span class="material-icons">keyboard_arrow_up</span> Back to top'},required:!1,helperText:"",defaultCollapsed:!1},{name:"flavorSelector",friendlyName:"Flavor / Option Selector",type:"text",defaultValue:{Default:"Choose a flavor"},required:!1,helperText:"",defaultCollapsed:!1}],helperText:"Customize the various labels on the offer selector",defaultCollapsed:!1},{name:"bestSellerImage",friendlyName:"Best Seller Image",type:"file",allowedFileTypes:["jpeg","png","svg","webp"],defaultValue:"https://cdn.builder.io/api/v1/image/assets%2Fcf992cf7343c4ca182a884e9a45f394e%2F3805efcc18184db8bccf74d5c5aaf891?format=webp",required:!1,helperText:"The small image to display alongside the best seller offer",defaultCollapsed:!0},{name:"bestValueImage",friendlyName:"Best Value Image",type:"file",defaultValue:"https://cdn.builder.io/api/v1/image/assets%2Fcf992cf7343c4ca182a884e9a45f394e%2F82105508987e4459bc4405617d4bee33",required:!1,helperText:"The small image to display alongside the best value offer (highest quantity)",allowedFileTypes:["jpeg","png","svg","webp"],defaultCollapsed:!0},{name:"cssOverrides",friendlyName:"CSS Properties",type:"object",defaultValue:{},required:!1,subFields:[{name:"signupOfferCustomCssProps",friendlyName:"Signup Offer CSS",type:"map",required:!1,helperText:"",defaultCollapsed:!1},{name:"signupOfferPriceCustomCssProps",friendlyName:"Signup Offer Price CSS",type:"map",required:!1,helperText:"",defaultCollapsed:!1}],helperText:"",defaultCollapsed:!0}],helperText:"Configure the offer selector to display.",defaultCollapsed:!0,showIf:"return !(options.get('hideNativeOfferSelector'))"},{name:"category",type:"reference",required:!1,helperText:"Provide the category to display breadcrumb navigation",modelId:a,copyOnAdd:!0,friendlyName:"Category",defaultCollapsed:!1}],helperText:"Configure the PDP options",showIf:"return options.get('pageType') === 'Product'",defaultCollapsed:!1},{name:"blog",friendlyName:"Blog Configuration",type:"object",required:!1,subFields:[{name:"title",friendlyName:"Blog Title",helperText:"Provide a title for this blog when shown on a grid or list. If not provided, the page title will be used.",type:"text",required:!1,localized:!0,defaultCollapsed:!1},{name:"publicationDate",friendlyName:"Publication Date",type:"timestamp",helperText:"Provide the publication date, this is used for sorting.",required:!0,localized:!1,defaultCollapsed:!1},{name:"snippet",friendlyName:"Blog Snippet",helperText:"Provide a snippet of the blog to display when shown on a grid or list. If not provided, we will attempt to use the page description or SEO description (if available)",type:"longText",required:!1,localized:!0,defaultCollapsed:!1},{name:"author",friendlyName:"Blog Author",type:"text",helperText:"Provide an author for this blog to display when shown on a grid or list.",required:!1,localized:!1,defaultCollapsed:!1},{name:"thumbnail",friendlyName:"Blog Thumbnail",type:"file",required:!1,helperText:"Provide an image to display when shown on a grid or list. If not provided, we will attempt to use the SEO image (if available)",allowedFileTypes:["jpeg","png","svg","webp"],copyOnAdd:!0,defaultCollapsed:!1},{name:"categories",friendlyName:"Blog Categories",type:"list",required:!1,copyOnAdd:!0,defaultCollapsed:!0,subFields:[{name:"category",friendlyName:"Blog Category",type:"reference",modelId:d,required:!0,defaultCollapsed:!1,copyOnAdd:!1}]}],helperText:"Configure the blog options",showIf:"return options.get('pageType') === 'Blog'",defaultCollapsed:!0},{name:"heading",friendlyName:"SEO Page Title",type:"text",required:!1,helperText:"Provide an alternate page title to use for SEO purposes (if blank, the page title is used)",defaultCollapsed:!1},{name:"description",friendlyName:"SEO Description",type:"longText",required:!1,helperText:"Set the page description for SEO here. This is automatically embedded in your page.",defaultCollapsed:!0},{name:"seoImage",friendlyName:"SEO Image",type:"file",required:!1,helperText:"Provide an image to be used for SEO purposes",allowedFileTypes:["jpeg","png","svg","webp"],copyOnAdd:!0,defaultCollapsed:!1},{name:"search",friendlyName:"Search Configuration",type:"object",required:!1,subFields:[{name:"title",friendlyName:"Search Title",type:"text",required:!1,helperText:"Used when showing this page in your site's search function. If no value is provided, the page title will be used.",defaultCollapsed:!1},{name:"description",friendlyName:"Search Description",type:"text",required:!1,helperText:"(Optional) Provide a description to be used when showing this page in search results. If no value is provided, the SEO description is used.",defaultCollapsed:!1},{name:"hide",friendlyName:"Hide from Search",type:"boolean",required:!1,helperText:"Use this to hide this page from search results. This does not prevent navigation to the page.",defaultCollapsed:!1},{name:"content",friendlyName:"Content",type:"longText",required:!1,helperText:"(Optional) Use this field to add keywords or phrases to assist in search results (e.g. related products, categories, key words, etc.)",defaultCollapsed:!1}],helperText:"Configure how this page displays in your site's built-in search results. Pages will not show in search results if neither the SEO or Search information is configured. You may also elect to hide the page from search results.",defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"banners",friendlyName:"Banners",helperText:"Select the banner(s) to display on this page. These will be displayed in the\n order provided, but always below site-wide banners.",type:"list",defaultCollapsed:!0,localized:!1,subFields:[{"@type":"@builder.io/core:Field",name:"banner",friendlyName:"Sitewide Banner",type:"reference",localized:!1,helperText:"Select the banner to display.",defaultCollapsed:!0,modelId:o,copyOnAdd:!1}]},{name:"disableStickyHeader",friendlyName:"Disable Sticky Header",helperText:"Disable the sticky header for this page only.",type:"boolean",localized:!1,defaultCollapsed:!0,advanced:!0},{name:"showBundleDrawer",friendlyName:"Show Bundle Drawer",helperText:"Enable the bundle drawer for this page.",type:"boolean",localized:!1,defaultCollapsed:!0,advanced:!0},{name:"robotsMeta",friendlyName:"Robots Meta",type:"object",required:!1,helperText:"Settings for the robots meta tag.",subFields:[{name:"noIndex",friendlyName:"No Index",type:"boolean",required:!1,defaultCollapsed:!0,helperText:"Prevents pages from being indexed and displayed in search engine result pages"},{name:"noFollow",friendlyName:"No Follow",type:"boolean",required:!1,defaultCollapsed:!0,helperText:"Prevents search engines from following links on the pages"},{name:"noArchive",friendlyName:"No Archive",type:"boolean",required:!1,defaultCollapsed:!0,helperText:"Prevents search engines from showing Cached links for pages"},{name:"noImageIndex",friendlyName:"No Image Index",type:"boolean",required:!1,defaultCollapsed:!0,helperText:"This option prevents images on a page from being indexed by Google and other search engines"},{name:"noSnippet",friendlyName:"No Snippet",type:"boolean",required:!1,defaultCollapsed:!0,helperText:"Prevents a snippet from being shown in the search results"}],defaultCollapsed:!0}],editingUrlLogic:"return `"+i+"${targeting.urlPath}?builder.preview=true&builder.frameEditing=true`"}})(e)}blogCommentModel(e){return(e=>({...T,fields:[...T.fields,{name:"blog",friendlyName:"Blog Post",helperText:"The blog that this comment is linked to",type:"reference",modelId:e,required:!0,defaultCollapsed:!1,copyOnAdd:!1}]}))(e)}};function q(e,l){const t=l.find(l=>l.name===e);return console.log(`[Hippo Commerce] Retrieved model "${e}" ---\x3e`,t?.id),t}async function P(e,l,t){const a=crypto.randomUUID().toString();try{await t.models.update({...e,id:l?l.id:a});const o=l?l.id:a;return console.log("[Hippo Commerce] Model update complete ---\x3e",e.name,o),o}catch(l){console.error("[Hippo Commerce] Set model error",l instanceof Error?{message:l.message,name:l.name,stack:l.stack}:l),console.error("[Hippo Commerce] Failed model shape:",e.name)}return l?l.id:e.name}return d.Builder.register("plugin",{id:r,name:"Hippo Commerce",settings:[{type:"select",enum:["Gundry MD","Dr. Marty","Driven Entrepreneur","Other"],name:"brand",friendlyName:"Brand",helperText:"Select your brand. If you select 'Other', provide your brand under the advanced settings.",required:!0},{type:"text",name:"editUrl",friendlyName:"Development Site URL",helperText:"Provide the URL to your development site.",required:!0},{type:"text",name:"apiUrl",friendlyName:"API URL",helperText:"Provide the URL to your instance of the Hippo Commerce API.",required:!0},{type:"text",name:"apiUser",friendlyName:"API User",helperText:"Provide your Hippo Commerce API User.",required:!0},{type:"password",name:"apiPassword",friendlyName:"API Password",helperText:"Provide your Hippo Commerce API Password.",required:!0},{type:"text",name:"otherBrand",friendlyName:"Custom Brand",helperText:"Provide your brand exactly as it is configured in your Hippo Commerce API.",required:!1,advanced:!0}],ctaText:"Save & Create Models",async onSave(e){await e.updateSettings({hasConnected:!0}),await async function(e){const l=function(e){const l=e.user.organization.value.settings.plugins?.get(r),t=l?.get("editUrl");return t??""}(e),t=e.models.result,a=q(v.ingredientsModel.name,t),o=q(v.categoryModel.name,t),d=q(v.productTagModel.name,t),i=q(v.useCaseModel.name,t),n=await P(v.ingredientsModel,a,e),p=await P(v.categoryModel,o,e),s=await P(v.productTagModel,d,e),u=await P(v.useCaseModel,i,e);if(!(n&&p&&s&&u))return;const f=v.productModel({ingredientsModelId:n,categoryModelId:p,tagModelId:s,useCaseModelId:u}),m=q(f.name,t),c=await P(f,m,e);if(!c)return;const y=v.productGroupModel(c),h=q(y.name,t),g=await P(y,h,e),b=v.siteBanner(l),C=q(b.name,t),T=await P(b,C,e),N=q(v.blogCategoryModel.name,t),x=await P(v.blogCategoryModel,N,e);if(!g||!T||!x)return;const w=v.pageModel({productModelId:c,productGroupModelId:g,categoryModelId:p,bannerModelId:T,blogCategoryModelId:x,editUrl:l}),k=q(w.name,t),S=await P(w,k,e);if(!S)return;const z=v.blogCommentModel(S),F=q(z.name,t);await P(z,F,e);const L=v.productGridConfigModel({categoryId:p,useCaseId:u,ingredientId:n,tagId:s}),I=q(L.name,t),D=await P(L,I,e);if(!D)return;const O=v.brandConfig(D,T),A=q(O.name,t);await P(O,A,e);const M=v.defaultWebsiteSection(l),B=q(M.name,t);await P(M,B,e),console.info("[Hippo Commerce] Model setup complete")}(i.default),await i.default.dialogs.alert("Hippo Commerce settings saved.")}}),d.Builder.register("app.onLoad",async({triggerSettingsDialog:e})=>{const l=i.default.user.organization.value.settings.plugins?.get(r),t=l?.get("hasConnected"),a=l?.get("brand"),o=l?.get("apiUser"),d=l?.get("apiPassword"),n=l?.get("apiUrl"),p=l?.get("editUrl");t&&a&&o&&d&&n&&p||await e(r)}),{}})())}}});
1
+ System.register(["@builder.io/app-context","@builder.io/react"],function(e,l){var t={},a={};return{setters:[function(e){t.default=e.default||e},function(e){a.Builder=e.Builder}],execute:function(){e((()=>{"use strict";var e={404(e){e.exports=t},522(e){e.exports=a}},l={};function o(t){var a=l[t];if(void 0!==a)return a.exports;var i=l[t]={exports:{}};return e[t](i,i.exports,o),i.exports}var i=o(522),d=o(404);const r="@goldenhippo/hippo-commerce-builder-cart-plugin";var n,s,p,u;!function(e){e.BASIC="BASIC",e.MEDIUM="MEDIUM",e.MEGA="MEGA",e.LINKLESS="LINKLESS",e.NONE="NONE",e.DMP="DMP"}(n||(n={})),function(e){e.PRIMARY="primary",e.SECONDARY="secondary",e.OUTLINE="outline",e.LINK="link"}(s||(s={})),function(e){e.SEARCH="search",e.LINKS="links",e.ACCOUNT_LINKS="accountLinks",e.HTML="html",e.TIMED_HTML="timedHtml"}(p||(p={})),function(e){e.LINKS="links",e.LOGO="logo",e.ACCOUNT_LINKS="accountLinks",e.CART_COUNT="cartCount",e.HTML="html"}(u||(u={}));const f={basic:{name:"basicHeaderConfig",showIf:"return options.get('headerType') === 'BASIC'",friendlyName:"Basic Menu Config",type:"object",defaultCollapsed:!0,localized:!1,subFields:[{"@type":"@builder.io/core:Field",name:"logoImage",friendlyName:"Logo Image",type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],required:!1,localized:!0,defaultCollapsed:!0,helperText:"Image displayed in the header"},{"@type":"@builder.io/core:Field",name:"mobileLinks",friendlyName:"Mobile Links",helperText:"Links to display in the mobile dropdown menu",type:"list",localized:!0,defaultCollapsed:!0,subFields:[{name:"title",friendlyName:"Mobile Link Title",helperText:"Title for the mobile link",type:"text",localized:!0,defaultCollapsed:!0,required:!0},{name:"href",friendlyName:"Link URL",helperText:"URL for the mobile link",type:"url",localized:!1,required:!0,defaultCollapsed:!0},{name:"newTab",friendlyName:"New Tab",helperText:"When true, this link will open in a new tab",type:"boolean",localized:!1,defaultCollapsed:!0},{name:"cssClasses",friendlyName:"CSS Classes",helperText:"Used for VWO targeting",type:"Tags",localized:!1,defaultCollapsed:!0}]},{name:"desktopLinks",friendlyName:"Desktop Links",helperText:"Links to display in the desktop menu",type:"list",localized:!0,defaultCollapsed:!0,subFields:[{name:"title",friendlyName:"Desktop Link Title",helperText:"Title for the desktop link",type:"text",localized:!0,defaultCollapsed:!0,required:!0},{name:"href",friendlyName:"Link URL",helperText:"URL for the mobile link",type:"url",localized:!1,defaultCollapsed:!0,required:!0},{name:"newTab",friendlyName:"New Tab",helperText:"When true, this link will open in a new tab",type:"boolean",localized:!1,defaultCollapsed:!0},{name:"cssClasses",friendlyName:"CSS Classes",helperText:"Used for VWO targeting",type:"Tags",localized:!1,defaultCollapsed:!0}]},{name:"ctas",friendlyName:"Call To Action",helperText:"Call to action button(s) to display",type:"list",localized:!0,defaultCollapsed:!0,subFields:[{name:"title",friendlyName:"Desktop Link Title",helperText:"Title for the desktop link",type:"text",localized:!1,defaultCollapsed:!0,required:!0},{name:"href",friendlyName:"Link URL",helperText:"URL for the mobile link",type:"url",localized:!1,defaultCollapsed:!0,required:!0},{name:"type",friendlyName:"CTA Type",helperText:"Select the type of CTA to display",type:"select",localized:!1,defaultCollapsed:!0,required:!0,defaultValue:"primary",enum:[s.PRIMARY,s.SECONDARY,s.OUTLINE,s.LINK]},{name:"newTab",friendlyName:"New Tab",helperText:"When true, this link will open in a new tab",type:"boolean",localized:!1,defaultCollapsed:!0},{name:"cssClasses",friendlyName:"CSS Classes",helperText:"Used for VWO targeting",type:"Tags",localized:!1,defaultCollapsed:!0},{name:"hideOnMobile",friendlyName:"Hide on Mobile",helperText:"Set to true to disable this CTA on mobile devices",type:"boolean",localized:!1,defaultCollapsed:!0}]},{name:"myAccountGuest",friendlyName:"MyAccount Menu Links - Guest",helperText:"Links to show under the My Account menu when the user is logged out.",type:"list",localized:!0,defaultCollapsed:!0,subFields:[{name:"title",friendlyName:"Desktop Link Title",helperText:"Title for the desktop link",type:"text",localized:!1,defaultCollapsed:!0,required:!0},{name:"href",friendlyName:"Link URL",helperText:"URL for the mobile link",type:"url",localized:!1,defaultCollapsed:!0,required:!0},{name:"icon",friendlyName:"Icon",type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],required:!1,defaultCollapsed:!0,helperText:"Link icon"},{name:"newTab",friendlyName:"New Tab",helperText:"When true, this link will open in a new tab",type:"boolean",localized:!1,defaultCollapsed:!0},{name:"cssClasses",friendlyName:"CSS Classes",helperText:"Used for VWO targeting",type:"Tags",localized:!1,defaultCollapsed:!0}]},{name:"myAccountAuthorized",friendlyName:"MyAccount Menu Links - Logged In",helperText:"Links to show under the My Account menu when the user is logged in.",type:"list",localized:!0,defaultCollapsed:!0,subFields:[{name:"title",friendlyName:"Desktop Link Title",helperText:"Title for the desktop link",type:"text",localized:!1,defaultCollapsed:!0,required:!0},{name:"href",friendlyName:"Link URL",helperText:"URL for the mobile link",type:"url",localized:!1,defaultCollapsed:!0,required:!0},{name:"icon",friendlyName:"Icon",type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],required:!1,defaultCollapsed:!0,helperText:"Link icon"},{name:"newTab",friendlyName:"New Tab",helperText:"When true, this link will open in a new tab",type:"boolean",localized:!1,defaultCollapsed:!0},{name:"cssClasses",friendlyName:"CSS Classes",helperText:"Used for VWO targeting",type:"Tags",localized:!1,defaultCollapsed:!0}]},{name:"stickyHeader",type:"object",friendlyName:"Sticky Header Configuration",defaultCollapsed:!0,localized:!1,subFields:[{name:"enabled",type:"boolean",friendlyName:"Enabled?",defaultCollapsed:!0,localized:!1},{name:"backgroundColor",type:"color",friendlyName:"Background Color",defaultCollapsed:!0,localized:!1,helperText:"The header background color at the top of the page. Leave blank for a transparent header"},{name:"scrollBackgroundColor",type:"color",friendlyName:"Background Color - Scroll",defaultCollapsed:!0,localized:!1,helperText:"The header background color while scrolling. Leave blank for a transparent header",defaultValue:"#FFFFFF"},{name:"scrollLogo",friendlyName:"Scroll Logo",type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],required:!1,localized:!0,defaultCollapsed:!0,helperText:"Image displayed in the header while scrolling. Leave blank to use the default header logo"}]},{name:"showLocaleSelection",type:"boolean",friendlyName:"Show Locale Selection?",defaultCollapsed:!0,localized:!1,helperText:"Show Locale Selection"}]},medium:{"@type":"@builder.io/core:Field",name:"mediumHeaderConfig",friendlyName:"Medium Header Configuration",type:"object",showIf:"return options.get('headerType') === 'MEDIUM'",defaultCollapsed:!0,localized:!1,subFields:[{"@type":"@builder.io/core:Field",name:"wrapperID",friendlyName:"Wrapper ID",helperText:"ID for the medium header wrapper",type:"text",localized:!1,defaultValue:"header",defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"wrapperClasses",friendlyName:"Wrapper Classes",helperText:"CSS classes for the medium header wrapper",type:"text",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"showShippingMessage",friendlyName:"Show Shipping Message",helperText:"Display the free shipping message on the mega menu",type:"boolean",localized:!0,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"mobileMenu",friendlyName:"Mobile Menu",helperText:"Mobile menu configuration for the medium header",type:"object",localized:!1,defaultCollapsed:!0,subFields:[{"@type":"@builder.io/core:Field",name:"logo",friendlyName:"Logo",helperText:"Logo for the mobile header",type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"logoClasses",friendlyName:"Logo Classes",helperText:"CSS classes for the mobile logo",type:"text",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"navClasses",friendlyName:"Navigation Classes",helperText:"CSS classes for the mobile navigation",type:"text",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"dropDownWrapperClasses",friendlyName:"Dropdown Wrapper Classes",helperText:"CSS classes for the dropdown wrapper",type:"text",localized:!1,required:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"dropDownContent",friendlyName:"Dropdown Content",helperText:"Content to display in the dropdown",type:"list",localized:!1,required:!1,defaultCollapsed:!0,subFields:[{"@type":"@builder.io/core:Field",name:"type",friendlyName:"Dropdown Type",helperText:"Select the type of dropdown content",type:"select",enum:[p.SEARCH,p.LINKS,p.ACCOUNT_LINKS,p.HTML,p.TIMED_HTML],defaultValue:"links",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"links",friendlyName:"Links",helperText:"Links for this dropdown",type:"list",localized:!1,defaultCollapsed:!0,subFields:[{"@type":"@builder.io/core:Field",name:"itemClasses",friendlyName:"Item Classes",helperText:"CSS classes for the link item",type:"text",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"loggedInOnly",friendlyName:"Logged In Only",helperText:"Display this link only when the user is logged in",type:"boolean",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"loggedOutOnly",friendlyName:"Logged Out Only",helperText:"Display this link only when the user is logged out",type:"boolean",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"text",friendlyName:"Link Title",helperText:"Title for the link",type:"html",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"URL",friendlyName:"URL",helperText:"URL for the link",type:"url",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"subLinksWrapperClasses",friendlyName:"Sub Links Wrapper Classes",helperText:"CSS classes for the sub-links wrapper",type:"text",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"subLinks",friendlyName:"Sub Links",helperText:"Sub-links for this dropdown item",type:"list",localized:!1,defaultCollapsed:!0,subFields:[{"@type":"@builder.io/core:Field",name:"text",friendlyName:"Link Title",helperText:"Title for the link",type:"text",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"URL",friendlyName:"Link Title",helperText:"Title for the link",type:"text",localized:!1,defaultCollapsed:!0}]}]},{"@type":"@builder.io/core:Field",name:"htmlContent",friendlyName:"HTML Content",helperText:"HTML content to display in the dropdown",type:"html",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"inputs",friendlyName:"Inputs",helperText:"Inputs for the dropdown content",type:"object",localized:!1,required:!0,defaultCollapsed:!0,subFields:[{"@type":"@builder.io/core:Field",name:"defaultHtml",friendlyName:"Default HTML",helperText:"Default HTML content that will be displayed",type:"html",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"temporaryHtml",friendlyName:"Temporary HTML",helperText:"Temporary HTML content that will be displayed for a limited time",type:"html",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"startTime",friendlyName:"Start Time",helperText:"Start time for the timed HTML content",type:"timestamp",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"endTime",friendlyName:"End Time",helperText:"End time for the timed HTML content",type:"timestamp",localized:!1,defaultCollapsed:!0}]}]}]},{"@type":"@builder.io/core:Field",name:"desktopMenu",friendlyName:"Desktop Menu",helperText:"Desktop menu configuration for the medium header",type:"object",localized:!1,defaultCollapsed:!0,subFields:[{"@type":"@builder.io/core:Field",name:"logo",friendlyName:"Logo",helperText:"Logo for the desktop header",type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"navClasses",friendlyName:"Navigation Classes",helperText:"CSS classes for the desktop navigation",type:"text",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"content",friendlyName:"Content",helperText:"Content to display in the desktop header",type:"list",localized:!1,required:!1,defaultCollapsed:!0,subFields:[{"@type":"@builder.io/core:Field",name:"type",friendlyName:"Content Type",helperText:"Select the type of content",type:"select",enum:[u.LINKS,u.LOGO,u.ACCOUNT_LINKS,u.CART_COUNT,u.HTML],defaultValue:"links",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"wrapperClasses",friendlyName:"Wrapper Classes",helperText:"CSS classes for the wrapper",type:"text",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"links",friendlyName:"Links",helperText:"Links for the desktop header",type:"list",localized:!1,defaultCollapsed:!0,subFields:[{"@type":"@builder.io/core:Field",name:"text",friendlyName:"Link Text",helperText:"Text for the link",type:"html",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"URL",friendlyName:"URL",helperText:"URL for the link",type:"url",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"loggedInOnly",friendlyName:"Logged In Only",helperText:"Display this link only when the user is logged in",type:"boolean",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"loggedOutOnly",friendlyName:"Logged Out Only",helperText:"Display this link only when the user is logged out",type:"boolean",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"dropdownWrapperClasses",friendlyName:"Dropdown Wrapper Classes",helperText:"CSS classes for the dropdown wrapper",type:"text",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"dropdownItemClasses",friendlyName:"Dropdown Item Classes",helperText:"CSS classes for the dropdown item",type:"text",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"subLinks",friendlyName:"Sub Links",helperText:"Sub-links for this header item",type:"list",localized:!1,defaultCollapsed:!0,subFields:[{"@type":"@builder.io/core:Field",name:"columnHeaderTitle",friendlyName:"Column Header Title",helperText:"Title for the column header",type:"text",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"columnContentType",friendlyName:"Column Content Type",helperText:"Select the type of content for the column",type:"select",enum:["links","html","timedHtml"],defaultValue:"links",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"links",friendlyName:"Links",helperText:"Links for the column",type:"list",localized:!1,defaultCollapsed:!0,subFields:[{"@type":"@builder.io/core:Field",name:"text",friendlyName:"Text",helperText:"Text for the link",type:"text",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"URL",friendlyName:"URL",helperText:"URL for the link",type:"url",localized:!1,defaultCollapsed:!0}]},{"@type":"@builder.io/core:Field",name:"content",friendlyName:"Content",helperText:"Content for the column",type:"html",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"inputs",friendlyName:"Inputs",helperText:"Inputs for the dropdown content",type:"object",localized:!1,required:!0,defaultCollapsed:!0,subFields:[{"@type":"@builder.io/core:Field",name:"defaultHtml",friendlyName:"Default HTML",helperText:"Default HTML content that will be displayed",type:"html",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"temporaryHtml",friendlyName:"Temporary HTML",helperText:"Temporary HTML content that will be displayed for a limited time",type:"html",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"startTime",friendlyName:"Start Time",helperText:"Start time for the timed HTML content",type:"timestamp",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"endTime",friendlyName:"End Time",helperText:"End time for the timed HTML content",type:"timestamp",localized:!1,defaultCollapsed:!0}]}]}]},{"@type":"@builder.io/core:Field",name:"accountLinksConfig",friendlyName:"Account Links Config",helperText:"",type:"object",localized:!1,defaultCollapsed:!0,subFields:[{"@type":"@builder.io/core:Field",name:"dropdownWrapperClasses",friendlyName:"Dropdown Wrapper Classes",helperText:"CSS classes for the dropdown wrapper",type:"text",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"dropdownItemClasses",friendlyName:"Dropdown Item Classes",helperText:"CSS classes for the dropdown item",type:"text",localized:!1,defaultCollapsed:!0}]},{"@type":"@builder.io/core:Field",name:"htmlContent",friendlyName:"HTML Content",helperText:"HTML content to display in the header",type:"html",localized:!1,defaultCollapsed:!0}]}]},{"@type":"@builder.io/core:Field",name:"bannersAboveHeader",friendlyName:"Banners Above Header",helperText:"Banners to display above the header",type:"list",localized:!0,defaultCollapsed:!0,subFields:[{"@type":"@builder.io/core:Field",name:"wrapperClasses",friendlyName:"Wrapper Classes",helperText:"CSS classes for the banner wrapper",type:"text",localized:!0,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"content",friendlyName:"Banner Content",helperText:"Content to display in the banner",type:"html",localized:!0,defaultCollapsed:!0}]},{"@type":"@builder.io/core:Field",name:"contactUrl",friendlyName:"Contact URL",helperText:"URL for the contact page",type:"url",localized:!0,defaultCollapsed:!0}]},mega:{"@type":"@builder.io/core:Field",name:"megaMenuConfig",showIf:"return options.get('headerType') === 'MEGA'",friendlyName:"Mega Menu Config",type:"object",defaultCollapsed:!0,localized:!1,subFields:[{"@type":"@builder.io/core:Field",name:"showShippingMessage",friendlyName:"Show Shipping Message",helperText:"Display the free shipping message on the mega menu",type:"boolean",localized:!0,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"mobileLinks",friendlyName:"Mobile Links",helperText:"Links to display in the mobile mega menu",type:"list",localized:!0,defaultCollapsed:!0,subFields:[{"@type":"@builder.io/core:Field",name:"title",friendlyName:"Mobile Link Title",helperText:"Title for the mobile link",type:"text",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"href",friendlyName:"Link URL",helperText:"URL for the mobile link",type:"url",localized:!1,required:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"expanded",friendlyName:"Expanded",helperText:"Indicates if the mobile link is expanded by default",type:"boolean",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"links",friendlyName:"Sub-Links",helperText:"Sub-links for the mobile link",type:"list",localized:!1,required:!1,defaultCollapsed:!0,subFields:[{"@type":"@builder.io/core:Field",name:"title",friendlyName:"Link Title",helperText:"Title for the link",type:"text",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"href",friendlyName:"Link URL",helperText:"URL for the link",type:"url",localized:!1,required:!0,defaultCollapsed:!0}]}]},{"@type":"@builder.io/core:Field",name:"desktopShopNavLinks",friendlyName:"Desktop Shop Navigation Links",helperText:"Links to display in the desktop shop navigation",type:"list",localized:!0,defaultCollapsed:!0,subFields:[{"@type":"@builder.io/core:Field",name:"title",friendlyName:"Link Title",helperText:"Title for the desktop link",type:"text",localized:!1,required:!0,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"links",friendlyName:"Links",helperText:"Links for the desktop navigation",type:"list",localized:!1,required:!1,defaultCollapsed:!0,subFields:[{"@type":"@builder.io/core:Field",name:"title",friendlyName:"Link Title",helperText:"Title for the link",type:"text",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"href",friendlyName:"Link URL",helperText:"URL for the link",type:"url",localized:!1,required:!0,defaultCollapsed:!0}]},{"@type":"@builder.io/core:Field",name:"shopAllLink",friendlyName:"Shop All Link",helperText:'Link to the "Shop All" page',type:"object",localized:!1,required:!1,defaultCollapsed:!0,subFields:[{"@type":"@builder.io/core:Field",name:"title",friendlyName:"Link Title",helperText:"Title for the link",type:"text",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"href",friendlyName:"Link URL",helperText:"URL for the link",type:"url",localized:!1,required:!0,defaultCollapsed:!0}]}]}]},dmp:{"@type":"@builder.io/core:Field",name:"dmpHeaderConfig",showIf:"return options.get('headerType') === 'DMP'",friendlyName:"DMP Header Config",type:"object",defaultCollapsed:!0,localized:!1,subFields:[{"@type":"@builder.io/core:Field",name:"logoImage",friendlyName:"Logo Image",type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],required:!1,localized:!0,defaultCollapsed:!0,helperText:"Image displayed in the header"},{"@type":"@builder.io/core:Field",name:"mobileLinks",friendlyName:"Mobile Links",helperText:"Links to display in the mobile dropdown menu",type:"list",localized:!0,defaultCollapsed:!0,subFields:[{"@type":"@builder.io/core:Field",name:"title",friendlyName:"Mobile Link Title",helperText:"Title for the mobile link",type:"text",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"href",friendlyName:"Link URL",helperText:"URL for the mobile link",type:"url",localized:!1,required:!1,defaultCollapsed:!0}]},{"@type":"@builder.io/core:Field",name:"desktopLinks",friendlyName:"Desktop Links",helperText:"Links to display in the desktop menu",type:"list",localized:!0,defaultCollapsed:!0,subFields:[{"@type":"@builder.io/core:Field",name:"title",friendlyName:"Desktop Link Title",helperText:"Title for the desktop link",type:"text",localized:!1,defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"href",friendlyName:"Link URL",helperText:"URL for the mobile link",type:"url",localized:!1,required:!1,defaultCollapsed:!0}]}]}};var c,m,y;!function(e){e.BASIC="BASIC",e.MEGA="MEGA",e.NONE="NONE"}(c||(c={})),function(e){e.DROPDOWN="Dropdown",e.STACKED_LIST="Stacked List"}(m||(m={})),function(e){e.P="/p",e.PRODUCT="/product"}(y||(y={}));const h=e=>({name:"features",friendlyName:"Features",type:"object",defaultCollapsed:!0,helperText:"Enable or disable site-wide features and behaviors",subFields:[{name:"productGridFilterType",friendlyName:"Product Grid Filter Type",type:"select",defaultCollapsed:!0,helperText:"Select the type of filters to use. 'Dropdown' will display a drop down of categories, ingredients, use cases, and tags. \n 'Stacked List' allows you to create your own filter groupings from amongst those four filter types.",enum:[m.DROPDOWN,m.STACKED_LIST],defaultValue:"Dropdown"},{name:"productGridFilterGroups",friendlyName:"Product Grid Filter Groups",type:"list",defaultCollapsed:!0,helperText:"Select the filter groups to use. They will be presented in the order entered",subFields:[{name:"filterConfig",friendlyName:"Product Grid Filter",type:"reference",defaultCollapsed:!0,modelId:e,helperText:"Select a product grid filter group to display",copyOnAdd:!1}]},{name:"productGridHideRestricted",friendlyName:"Hide Restricted Products",helperText:"Hide restricted products from your product grid based on the user's selected country",type:"boolean",localized:!1,defaultCollapsed:!0},{name:"productLinkPrefix",friendlyName:"Product Link Prefix",helperText:'Set the prefix to append before product slugs throughout your site. For example, if you enter "p", all links from the product grid will be {website}/p/{product-slug}',type:"select",enum:[y.P,y.PRODUCT],localized:!1,defaultCollapsed:!0,defaultValue:"/p"},{name:"subscriptionAddOnsEnabled",friendlyName:"Subscription Add-Ons Enabled",helperText:"Enable or disable subscription add-ons for the brand",type:"boolean",localized:!1,defaultCollapsed:!0},{name:"shippingThresholdNotificationEnabled",friendlyName:"Shipping Threshold Notification Enabled",helperText:"Enable or disable shipping threshold notifications for the brand",type:"boolean",localized:!0,defaultCollapsed:!0},{name:"bundlingEnabled",friendlyName:"Enable Bundling Experience",helperText:"Enable or disable the bundling experience for the brand",type:"boolean",localized:!1,defaultCollapsed:!0},{name:"cartDrawerEnabled",friendlyName:"Enable Cart Drawer",helperText:"Enable or disable the cart drawer experience for the brand",type:"boolean",localized:!1,defaultCollapsed:!0},{name:"subscriptionExperience",friendlyName:"Subscription Experience",type:"select",enum:["Classic","Version 2"],defaultValue:"Classic",defaultCollapsed:!1,helperText:"Select the subscription management experience for customers"},{name:"useDefaultFrequencies",friendlyName:"Use Default Frequencies",type:"boolean",helperText:"When enabled, the selected frequency on an Offer Selector is calculated based on the product and quantity selected.",defaultCollapsed:!1}]});var g,b;!function(e){e.DoNotLike="DoNotLike",e.NotWorking="NotWorking",e.NoBenefits="NoBenefits",e.NoFitNoNeed="NoFitNoNeed",e.Budget="Budget",e.Mistake="Mistake",e.Try="Try",e.TooMuch="TooMuch",e.TravelMove="TravelMove",e.DoNotNeed="DoNotNeed",e.AnotherReason="AnotherReason",e.NotHelpingSkin="NotHelpingSkin",e.SkinImproved="SkinImproved",e.PetDoesNotLike="PetDoesNotLike",e.NotHelpingPet="NotHelpingPet",e.NoneGiven="NoneGiven"}(g||(g={})),function(e){e.Link="link",e.Update="update",e.Keep="keep",e.Continue="continue",e.Cancel="cancel"}(b||(b={}));const T=e=>[{name:"brandDisplayName",friendlyName:"Brand Display Name",type:"text",defaultCollapsed:!0,localized:!1,required:!0,helperText:"The brand name displayed across the website"},{name:"images",friendlyName:"Brand Images",type:"object",defaultCollapsed:!0,localized:!1,helperText:"Logo and brand images used throughout the website",subFields:[{name:"brandLogoSmall",friendlyName:"Logo (Small)",type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],localized:!0,helperText:"Small logo for the brand",defaultCollapsed:!0},{name:"brandLogoLarge",friendlyName:"Logo (Large)",type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],localized:!0,helperText:"Large logo for the brand",defaultCollapsed:!0},{name:"brandLogoFooter",friendlyName:"Logo (Footer)",type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],localized:!0,helperText:"Footer logo for the brand",defaultCollapsed:!0},{name:"bbbImage",friendlyName:"BBB Image",type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],localized:!0,helperText:"BBB logo for the brand",defaultCollapsed:!0},{name:"accesibilityLogo",friendlyName:"Accessibility Logo",type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],localized:!0,helperText:"Accessibility logo for the brand",defaultCollapsed:!0},{name:"brandLogoOffWhite",friendlyName:"Logo (Off-White)",type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],localized:!0,helperText:"Off white logo for the brand",defaultCollapsed:!0},{name:"defaultPetProfileImage",friendlyName:"Default Pet Profile Image",type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],localized:!0,helperText:"Default image for pet profiles",defaultCollapsed:!0},{name:"defaultCatProfileImage",friendlyName:"Default Cat Profile Image",type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],localized:!0,helperText:"Default image for cat profiles",defaultCollapsed:!0},{name:"defaultDogProfileImage",friendlyName:"Default Dog Profile Image",type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],localized:!0,helperText:"Default image for dog profiles",defaultCollapsed:!0},{name:"linklessPageHeaderLogo",friendlyName:"Linkless Header Image",type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],localized:!0,helperText:"Logo Image for the linkless header",defaultCollapsed:!0}]},{name:"links",friendlyName:"General Links",type:"object",defaultCollapsed:!0,localized:!1,helperText:"Links to legal pages and external profiles",subFields:[{name:"termsLink",friendlyName:"Terms of Service Link",type:"url",localized:!1,helperText:"Link to the terms of service page",defaultCollapsed:!0},{name:"subscriptionTermsLink",friendlyName:"Subscription Terms of Service Link",type:"url",localized:!1,helperText:"Link to the subscription terms of service page",defaultCollapsed:!0},{name:"privacyLink",friendlyName:"Privacy Policy Link",type:"url",localized:!1,helperText:"Link to the privacy policy page",defaultCollapsed:!0},{name:"ccpaLink",friendlyName:"CCPA Link",type:"url",localized:!1,helperText:"Link to the CCPA page",defaultCollapsed:!0},{name:"bbbLink",friendlyName:"BBB Link",type:"url",localized:!1,helperText:"Link to the Better Business Bureau page",defaultCollapsed:!0},{name:"accessibiltyLink",friendlyName:"Accessibility Link",type:"url",localized:!1,helperText:"Link to the accessibility page",defaultCollapsed:!0},{name:"socialMedia",friendlyName:"Social Media Links",type:"object",localized:!1,helperText:"Links to the brand's social media profiles",defaultCollapsed:!0,subFields:[{name:"twitter",friendlyName:"Twitter / X",type:"url",localized:!1,helperText:"Link to the brand's Twitter/X profile",defaultCollapsed:!0},{name:"facebook",friendlyName:"Facebook",type:"url",localized:!1,helperText:"Link to the brand's Facebook page",defaultCollapsed:!0},{name:"youtube",friendlyName:"YouTube",type:"url",localized:!1,helperText:"Link to the brand's YouTube channel",defaultCollapsed:!0},{name:"instagram",friendlyName:"Instagram",type:"url",localized:!1,helperText:"Link to the brand's Instagram profile",defaultCollapsed:!0},{name:"pinterest",friendlyName:"Pinterest",type:"url",localized:!1,helperText:"Link to the brand's Pinterest profile",defaultCollapsed:!0},{name:"tiktok",friendlyName:"TikTok",type:"url",localized:!1,helperText:"Link to the brand's TikTok profile",defaultCollapsed:!0}]}]},{name:"banners",friendlyName:"Banners",helperText:"Select the banner(s) to display site-wide. These will be displayed in the\n order provided, and always above page-specific announcements",type:"list",defaultCollapsed:!0,localized:!1,subFields:[{name:"banner",friendlyName:"Sitewide Banner",type:"reference",localized:!1,helperText:"Select the banner to display.",defaultCollapsed:!0,modelId:e,copyOnAdd:!1},{name:"alwaysShow",friendlyName:"Always Show?",type:"boolean",localized:!1,helperText:'By default, we hide sitewide banners on the classic "cart" pages. Use this setting to bypass those restrictions',defaultCollapsed:!0}]}],C={name:"blog-comment",displayName:"Blog Comment",kind:"data",helperText:"Comments on your website's blogs",contentTitleField:void 0,fields:[{name:"name",friendlyName:"Name",helperText:"Name of the user who submitted this comment",type:"text",defaultCollapsed:!1,localized:!1,required:!0},{name:"date",friendlyName:"Date",helperText:"Date this comment was submitted",type:"timestamp",defaultCollapsed:!1,localized:!1,required:!0},{name:"status",friendlyName:"Status",helperText:"Select the status of this comment. Only Approved comments will be displayed",type:"select",enum:["Pending Approval","Approved","Rejected"],defaultValue:"Pending Approval",defaultCollapsed:!1,localized:!1,required:!0},{type:"text",name:"email",friendlyName:"Email",required:!1,defaultCollapsed:!1,helperText:"Email address of the commenter"},{type:"html",name:"comment",friendlyName:"Comment",helperText:"HTML content of the comment",required:!0,defaultCollapsed:!1},{name:"language",friendlyName:"Language",helperText:"The language code of this comment. Legacy comments are synced as 'en'",type:"select",enum:["en"],defaultCollapsed:!0,localized:!1,defaultValue:"en",required:!0},{name:"locale",friendlyName:"Locale",helperText:"The country code of this comment. Legacy comments are synced as 'US'",type:"select",enum:["US"],defaultValue:"US",defaultCollapsed:!0,localized:!1,required:!0},{name:"parentId",friendlyName:"Parent Comment Id",helperText:"If this comment is a reply, this is the Id of the parent",type:"text",required:!1,defaultCollapsed:!0},{name:"internal",friendlyName:"Brand Response",helperText:"Indicates that this is a comment provided by the brand (i.e. a response)",type:"boolean",defaultCollapsed:!1,required:!1}],hideFromUI:!0};var N,x,w,S,k,z,L,F,v;!function(e){e.FlavorOptionGroup="Flavor/Option Group",e.TrialGroup="Trial Group"}(N||(N={})),function(e){e.Inclusive="Inclusive",e.Exclusive="Exclusive"}(x||(x={})),function(e){e.AboveHeader="Above Header",e.BelowHeader="Below Header"}(w||(w={})),function(e){e.GENERAL="General",e.PRODUCT="Product",e.BLOG="Blog"}(S||(S={})),function(e){e.PRODUCT="Product",e.PRODUCT_GROUP="Product Group",e.MULTI_GROUP="Multi-Group"}(k||(k={})),function(e){e.VERTICAL="Vertical",e.VERTICAL__FLAVOR_DROPDOWN__TYPE_TOGGLE="Vertical - Flavor Dropdown - Type Toggle",e.STACKED__FLAVOR_BUTTONS__QUANTITY_TOGGLE="Stacked - Flavor Buttons - Quantity Toggle",e.BUNDLE_GROUP="Bundle Group"}(z||(z={})),function(e){e.SLIDER_A="Slider A",e.SLIDER_B="Slider B",e.SLIDER_ZOOM="Slider Zoom"}(L||(L={})),function(e){e.ONE_TIME="One-Time Purchase",e.SUBSCRIPTION="Subscription"}(F||(F={})),function(e){e.PERCENT="percentage",e.DOLLAR="dollar"}(v||(v={}));const I=new class{ingredientsModel={name:"product-ingredient",displayName:"Product Ingredient",kind:"data",helperText:"Ingredients used in products",contentTitleField:"name",fields:[{"@type":"@builder.io/core:Field",name:"name",friendlyName:"Ingredient",type:"text",required:!0,defaultCollapsed:!0,helperText:"The display name of this ingredient as it appears on the website",localized:!0,defaultValue:{"@type":"@builder.io/core:LocalizedValue"}},{"@type":"@builder.io/core:Field",name:"description",friendlyName:"Description",type:"longText",required:!1,defaultCollapsed:!0,helperText:"A detailed description of this ingredient, shown on product detail pages",localized:!0,defaultValue:{"@type":"@builder.io/core:LocalizedValue"}},{"@type":"@builder.io/core:Field",name:"image",friendlyName:"Image",type:"file",showTemplatePicker:!0,defaultCollapsed:!0,helperText:"An image representing this ingredient, used in ingredient spotlights and carousels",allowedFileTypes:["jpeg","png","svg","webp"]},{"@type":"@builder.io/core:Field",name:"shortDescription",friendlyName:"Short Description",type:"longText",required:!1,defaultCollapsed:!0,helperText:"A brief summary of this ingredient, used in compact displays like product cards",localized:!0,defaultValue:{"@type":"@builder.io/core:LocalizedValue"}},{"@type":"@builder.io/core:Field",name:"searchKeys",friendlyName:"Search Keys",type:"Tags",defaultCollapsed:!0,helperText:'Used when building links (e.g. "products?category=[Search Key]")',required:!1,localized:!1}]};categoryModel={name:"product-category",kind:"data",displayName:"Product Category",helperText:"Categories for products",contentTitleField:"name",fields:[{name:"name",friendlyName:"Category",type:"text",required:!0,defaultCollapsed:!0,localized:!0,helperText:"The name of this category as it appears on the website"},{name:"description",friendlyName:"Description",type:"longText",required:!1,defaultCollapsed:!0,localized:!0,helperText:"A description of this category, used in components that display category details"},{name:"desktopImage",friendlyName:"Desktop Image",type:"file",defaultCollapsed:!0,showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],helperText:"Image displayed for this category on desktop screens"},{name:"mobileImage",defaultCollapsed:!0,friendlyName:"Mobile Image",type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],helperText:"Image displayed for this category on mobile screens"},{name:"hidden",friendlyName:"Hide Category",type:"boolean",required:!1,localized:!0,defaultCollapsed:!0,helperText:"When true, this category will not be displayed in product grids or search results for this locale"},{name:"slug",friendlyName:"Page Slug",type:"text",defaultCollapsed:!0,helperText:'If this category has a specific web page, provide the path here without a leading slash (e.g. "shop/supplements") for use in breadcrumb navigation. By default, the path "shop" will be used.',required:!1,localized:!1},{name:"searchKeys",friendlyName:"Search Keys",type:"Tags",defaultCollapsed:!0,helperText:'Used when building links (e.g. "products?category=[Search Key]")',required:!1,localized:!1}]};productTagModel={name:"product-tag",kind:"data",displayName:"Product Tag",helperText:"Provides a link between products across categories.",contentTitleField:"name",fields:[{name:"name",friendlyName:"Tag",type:"text",required:!0,defaultCollapsed:!0,localized:!0,makeEntryTitle:!0,helperText:'The display name of this tag (e.g. "Favorites", "New", "Best Seller")'},{name:"tagColor",friendlyName:"Color",type:"color",required:!0,defaultCollapsed:!0,localized:!1,defaultValue:"gba(255, 233, 214, 1)",helperText:"The background color shown behind the tag label on product cards"},{name:"hidden",friendlyName:"Hide Tag",type:"boolean",required:!1,localized:!0,defaultCollapsed:!0,helperText:"When true, this tag will not be displayed in product grids or search results for this locale"},{name:"image",friendlyName:"Tag Image",type:"file",allowedFileTypes:["jpeg","png","svg","webp"],required:!1,localized:!0,defaultCollapsed:!0,helperText:"For product grids that support tag images, you may provide the image here."},{name:"pluralDisplayName",friendlyName:"Plural Display Name",defaultCollapsed:!0,type:"text",helperText:'This is used when grouping/filtering. Allows us to display "Favorites" instead of "Fave", for example.',required:!1,localized:!0}]};useCaseModel={name:"product-use-case",kind:"data",displayName:"Product Use Case",helperText:"Provides a link between products used for the same goal.",contentTitleField:"name",fields:[{name:"name",defaultCollapsed:!0,helperText:'The display name of this use case (e.g. "Joint Support", "Weight Management")',friendlyName:"Use Case",type:"text",required:!0,localized:!0},{name:"description",friendlyName:"Description",type:"longText",defaultCollapsed:!0,required:!1,localized:!0,helperText:"A detailed description of this use case, shown when users browse by goal"},{name:"searchKeys",friendlyName:"Search Keys",type:"Tags",defaultCollapsed:!0,helperText:'Used when building links (e.g. "products?category=[Search Key]")',required:!1,localized:!1},{name:"image",friendlyName:"Image",defaultCollapsed:!0,type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],helperText:"An image representing this use case, used in grids and carousels"},{name:"hidden",friendlyName:"Hide Use Case",type:"boolean",required:!1,localized:!0,defaultCollapsed:!0,helperText:"When true, this use case will not be displayed in product grids or search results for this locale"}]};blogCategoryModel={name:"blog-category",displayName:"Blog Category",kind:"data",helperText:"Category for blog categorization",contentTitleField:void 0,fields:[{name:"name",friendlyName:"Name",helperText:"Name of the category",type:"text",defaultCollapsed:!1,localized:!0,required:!0},{name:"description",friendlyName:"Category Description",helperText:"Provide a description of the category. This may be used in components.",type:"html",defaultCollapsed:!1,localized:!0,required:!1},{name:"slug",friendlyName:"Slug",helperText:"Path to use for linking to this category",type:"text",defaultCollapsed:!1,localized:!1,required:!0},{name:"parentId",friendlyName:"Parent Category Id",helperText:"If this category is a child, provide the Id of the parent category",type:"text",required:!1,defaultCollapsed:!0,localized:!1}]};productModel(e){return(e=>({name:"product",displayName:"Product",kind:"data",helperText:"Product Catalog",contentTitleField:"name",fields:[{name:"displayName",friendlyName:"Display Name",type:"text",required:!0,localized:!0,defaultCollapsed:!0,helperText:"This is the name that will be displayed to the customer"},{name:"featuredImage",friendlyName:"Featured Image",helperText:"Displayed on the product card",defaultCollapsed:!0,type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"]},{name:"secondaryImage",friendlyName:"Secondary Image",helperText:"Displayed on the product card hover for some grids",defaultCollapsed:!0,type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"]},{name:"subHeading",defaultCollapsed:!0,friendlyName:"Product Headline",helperText:"Subheading (tagline) for the product, displayed on the product card",type:"text",localized:!0},{name:"gridTagline",defaultCollapsed:!0,friendlyName:"Grid Tagline",helperText:"By default, we use the Product Headline field. Use this to override the tagline when displayed on the product grid.",type:"text",required:!1,localized:!0},{name:"gridDescription",defaultCollapsed:!0,friendlyName:"Grid Description",helperText:"A small description, used on some product grids as an additional sub-heading or tagline.",type:"text",required:!1,localized:!0},{name:"shortDescription",defaultCollapsed:!0,friendlyName:"Short Description",helperText:"Short description of the product, typically displayed on the PDP",type:"html",required:!1,localized:!0},{name:"quote",friendlyName:"Quote",defaultCollapsed:!0,helperText:"A quote provided by the brand guru or spokesperson",type:"html",localized:!0,required:!1},{name:"packagingLabels",friendlyName:"Packaging Labels",defaultCollapsed:!0,type:"object",helperText:"Labels describing the product packaging (e.g. Jar, Bottle, Pouch)",subFields:[{name:"singular",friendlyName:"Singular",defaultCollapsed:!0,type:"text",required:!0,localized:!0,helperText:"Provides the name of the packaging for single product (e.g. Unit, Jar, etc.)"},{name:"plural",defaultCollapsed:!0,friendlyName:"Plural",type:"text",required:!0,localized:!0,helperText:"Provides the name of the packaging for multiple quantities of the product (e.g. Units, Jars, etc.)"}]},{name:"hidden",friendlyName:"Hide Product",type:"boolean",required:!1,localized:!0,defaultCollapsed:!0,helperText:"When true, this product will not be displayed in product grids or search results for this locale"},{name:"outOfStock",friendlyName:"Out of Stock",type:"boolean",required:!1,defaultCollapsed:!0,helperText:"Indicates whether this product is currently out of stock. When true, this product is not eligible for purchase."},{name:"cartOutOfStock",friendlyName:"Out of Stock (Site)",type:"boolean",required:!1,defaultCollapsed:!0,helperText:"Indicates that this product should be presented as out of stock on the site, even if it is not truly out of stock. This is used as an override for special cases where the product should not be purchasable on the site while remaining purchasable elsewhere."},{name:"upc",defaultCollapsed:!0,friendlyName:"UPC Code",type:"text",required:!1,helperText:"The UPC code of this product"},{name:"reviews",friendlyName:"Review Data",helperText:"Stores review data for this product. These values are automatically generated and should not be modified.",type:"object",defaultCollapsed:!0,subFields:[{name:"id",defaultCollapsed:!0,friendlyName:"Review ID",type:"text",required:!0,localized:!1,helperText:"ID used by the review service to identify this product. Do not modify this value."},{defaultCollapsed:!0,name:"count",friendlyName:"Review Count",type:"number",defaultValue:0,required:!0,localized:!1,helperText:"The number of reviews for this product. This value is automatically updated by the review service."},{name:"averageRating",friendlyName:"Average Rating",type:"number",defaultCollapsed:!0,defaultValue:0,required:!0,localized:!1,helperText:"The average rating for this product. This value is automatically updated by the review service."}]},{name:"tags",friendlyName:"Tags",type:"list",localized:!0,defaultCollapsed:!0,helperText:'Tags used to cross-reference products and enable filtering (e.g. "New", "Best Seller")',subFields:[{type:"reference",modelId:e.tagModelId,name:"tag",friendlyName:"Tag",copyOnAdd:!1,defaultCollapsed:!0,helperText:"Select a product tag"}]},{name:"categories",friendlyName:"Categories",type:"list",localized:!0,defaultCollapsed:!0,helperText:"Categories this product belongs to, used for navigation and filtering",subFields:[{type:"reference",modelId:e.categoryModelId,name:"category",friendlyName:"Category",copyOnAdd:!1,defaultCollapsed:!0,helperText:"Select a product category"}]},{name:"ingredients",friendlyName:"Ingredients",type:"list",localized:!0,defaultCollapsed:!0,helperText:"Key ingredients in this product, displayed on product detail pages",subFields:[{type:"reference",modelId:e.ingredientsModelId,name:"ingredient",friendlyName:"Ingredient",copyOnAdd:!1,defaultCollapsed:!0,helperText:"Select an ingredient"}]},{name:"useCases",defaultCollapsed:!0,friendlyName:"Use Cases",type:"list",localized:!0,helperText:"Goals or health benefits this product supports, used for filtering and recommendations",subFields:[{type:"reference",modelId:e.useCaseModelId,name:"useCase",friendlyName:"Use Case",copyOnAdd:!1,defaultCollapsed:!0,helperText:"Select a use case"}]},{name:"servingsPerUnit",friendlyName:"Servings Per Unit",type:"number",defaultValue:void 0,required:!1,defaultCollapsed:!0,localized:!1,helperText:"Typical number of servings (or doses, days of supply) per unit. Used to auto-calculate default subscription frequency for funnel offers (servingsPerUnit × quantity). Defaults to 30 if not set."},{name:"name",friendlyName:"Name",type:"text",required:!0,defaultCollapsed:!0,localized:!1,helperText:"Internal name for the product, used for identification in the CMS"},{name:"components",friendlyName:"Bundle Components",type:"list",required:!1,defaultCollapsed:!1,helperText:"The individual products included in this bundle",showIf:"return options.get('gh')?.get(\"type\") === 'Bundle'",subFields:[{name:"slug",friendlyName:"Slug",type:"text",required:!0,defaultCollapsed:!1,helperText:"The unique identifier for this bundle component"},{name:"displayName",friendlyName:"Display Name",type:"text",localized:!0,defaultCollapsed:!1,helperText:"The name shown for this component on the product page"},{name:"description",friendlyName:"Description",type:"html",required:!1,defaultCollapsed:!1,helperText:"Use this to provide a description display beneath this component on the offer selector."}]},{name:"gh",friendlyName:"Golden Hippo Integration Data",helperText:"Stores integration data for Golden Hippo. Do not modify any of these values.",type:"object",subFields:[{name:"slug",friendlyName:"Page Slug",type:"text",required:!0,localized:!1,defaultCollapsed:!0,helperText:"This is the URL slug for this product. This value is unique and required for cross-environment development. Do not modify this value."},{name:"productionId",friendlyName:"Production ID",type:"text",required:!0,localized:!1,defaultCollapsed:!0,helperText:"This is the unique identifier for this product in the production environment. Do not modify this value."},{name:"type",friendlyName:"Product Type",type:"select",required:!0,localized:!1,defaultCollapsed:!0,enum:["Product","Bundle","Trial Size"],defaultValue:"Product",helperText:"Determines how this product is handled — Product, Bundle, or Trial Size"}],defaultCollapsed:!0,localized:!1}]}))(e)}productGroupModel(e,l){return((e,l)=>({name:"product-group",displayName:"Product Group",kind:"data",helperText:"Groups related products together (e.g. flavors, trial sizes).",contentTitleField:"displayName",fields:[{name:"displayName",friendlyName:"Display Name",type:"text",required:!0,defaultCollapsed:!0,localized:!0,helperText:"The display name of this product group."},{name:"featuredImage",friendlyName:"Featured Image",type:"file",defaultCollapsed:!0,showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],helperText:"The primary image of this product group."},{name:"subHeading",friendlyName:"Sub Heading",type:"text",required:!1,defaultCollapsed:!0,localized:!0,helperText:"A short tagline displayed beneath the group name."},{name:"gridTagline",friendlyName:"Grid Tagline",type:"text",required:!1,defaultCollapsed:!0,localized:!0,helperText:"A short tagline displayed on product grid cards."},{name:"shortDescription",friendlyName:"Short Description",type:"html",required:!1,defaultCollapsed:!0,localized:!0,helperText:"A short description of the product group."},{name:"products",friendlyName:"Products",type:"list",defaultCollapsed:!0,helperText:"The products in this group.",subFields:[{name:"product",friendlyName:"Product",type:"reference",defaultCollapsed:!1,modelId:e,copyOnAdd:!1,helperText:"Select a product to include in this group"},{name:"displayName",friendlyName:"Display Name",type:"text",defaultCollapsed:!1,localized:!0,helperText:"Override display name for this product in the group context."},{name:"isTrialSize",friendlyName:"Is Trial Size",type:"boolean",defaultCollapsed:!1,helperText:"Whether this product is a trial size variant."}]},{name:"selectionLabel",friendlyName:"Selection Label",type:"text",required:!1,defaultCollapsed:!0,localized:!0,helperText:'Label for the product selector (e.g. "Choose your flavor").'},{name:"hidden",friendlyName:"Hide Group",type:"boolean",required:!1,defaultCollapsed:!0,localized:!1,helperText:"When true, this product group will not be displayed."},{name:"gh",friendlyName:"Golden Hippo",type:"object",defaultCollapsed:!0,helperText:"Integration data for Golden Hippo. Do not modify these values.",subFields:[{name:"productionId",friendlyName:"Production ID",type:"text",defaultCollapsed:!1,helperText:"The production environment content ID for this product group."},{name:"slug",friendlyName:"Slug",type:"text",defaultCollapsed:!1,helperText:"URL slug for this product group."}]},{name:"groupType",friendlyName:"Group Type",type:"select",defaultCollapsed:!0,enum:[N.FlavorOptionGroup,N.TrialGroup],helperText:"The type of product grouping."},{name:"name",friendlyName:"Group Name",type:"text",required:!0,defaultCollapsed:!0,localized:!1,helperText:"The internal name for this product group."},{name:"informationCallout",friendlyName:"Information Callout",type:"reference",required:!1,modelId:l,copyOnAdd:!0,defaultCollapsed:!1,helperText:"Optional content section displayed alongside this product group"}]}))(e,l)}productGridConfigModel(e){return(e=>({name:"product-grid-filter-group",displayName:"Product Grid Filter Group",kind:"data",helperText:"Build filter group configurations. These can be applied in the brand configuration",contentTitleField:"displayName",fields:[{name:"displayName",friendlyName:"Display Name/Label",type:"text",localized:!0,defaultCollapsed:!1,helperText:"Provide a name to display for this grouping",makeEntryTitle:!0},{name:"categories",friendlyName:"Categories",helperText:"Categories for this group",type:"list",defaultCollapsed:!0,subFields:[{name:"category",friendlyName:"Category",type:"reference",modelId:e.categoryId,required:!0,localized:!1,copyOnAdd:!0,defaultCollapsed:!1,helperText:"Select a category to include in this filter group"}]},{name:"ingredients",friendlyName:"Ingredients",helperText:"Ingredients for this group",type:"list",defaultCollapsed:!0,subFields:[{name:"ingredient",friendlyName:"Ingredient",type:"reference",modelId:e.ingredientId,required:!0,localized:!1,copyOnAdd:!0,defaultCollapsed:!1,helperText:"Select an ingredient to include in this filter group"}]},{name:"useCases",friendlyName:"Use Cases",helperText:"Use Cases for this group",type:"list",defaultCollapsed:!0,subFields:[{name:"useCase",friendlyName:"Use Case",type:"reference",modelId:e.useCaseId,required:!0,localized:!1,copyOnAdd:!0,defaultCollapsed:!1,helperText:"Select a use case to include in this filter group"}],copyOnAdd:!1},{name:"tags",friendlyName:"Tags",helperText:"Tags for this group",type:"list",defaultCollapsed:!0,subFields:[{name:"tag",friendlyName:"Tag",type:"reference",modelId:e.tagId,required:!0,localized:!1,copyOnAdd:!0,defaultCollapsed:!1,helperText:"Select a tag to include in this filter group"}],copyOnAdd:!1},{name:"filterApplicationType",friendlyName:"Filter Application Type",type:"select",enum:[x.Inclusive,x.Exclusive],defaultValue:"Inclusive",required:!1,defaultCollapsed:!0,helperText:"Select how this filter is applied in relation to other filters. When set to Exclusive, ALL results must match a selected filter of this group."}]}))(e)}brandConfig(e,l){return((e,l)=>({name:"gh-brand-config",kind:"data",displayName:"Brand Configuration",helperText:"Manage global features and settings for your website",contentTitleField:void 0,fields:[...T(l),{name:"header",friendlyName:"Header",type:"object",defaultCollapsed:!0,subFields:[{name:"headerType",friendlyName:"Type",helperText:"Select the type of header to use",defaultCollapsed:!0,type:"select",enum:[n.BASIC,n.MEDIUM,n.MEGA,n.LINKLESS,n.NONE,n.DMP],defaultValue:"MEDIUM"},f.basic,f.medium,f.mega,f.dmp]},{name:"footer","@type":"@builder.io/core:Field",friendlyName:"Footer",type:"object",defaultCollapsed:!0,helperText:"Footer layout and content settings",subFields:[{name:"footerType",friendlyName:"Footer Type",type:"select",enum:[c.BASIC,c.MEGA,c.NONE],defaultValue:c.BASIC,defaultCollapsed:!0,helperText:"Choose the footer layout style for the website"}]},h(e),{name:"support",friendlyName:"Support Information",type:"object",defaultCollapsed:!0,localized:!1,helperText:"Contact information displayed to customers on the website",subFields:[{name:"email",friendlyName:"Support Email",type:"text",required:!0,localized:!0,helperText:"Email address for customer support inquiries",defaultCollapsed:!0},{name:"phone",friendlyName:"Support Phone Number",type:"text",required:!0,localized:!0,helperText:"Phone number for customer support inquiries",defaultCollapsed:!0},{name:"phoneDisplay",friendlyName:"Support Phone Display",type:"text",required:!0,localized:!0,helperText:"Formatted phone number for display",defaultCollapsed:!0},{name:"address",friendlyName:"Support Address",type:"object",required:!0,localized:!1,helperText:"Support address for customer inquiries",defaultCollapsed:!0,subFields:[{name:"street",friendlyName:"Street",type:"text",required:!0,helperText:"Street address for support",defaultCollapsed:!0},{name:"city",friendlyName:"City",type:"text",required:!0,helperText:"City for support address",defaultCollapsed:!0},{name:"state",friendlyName:"State Code",type:"text",required:!0,helperText:"State code for support address (e.g. CA)",defaultCollapsed:!0},{name:"zipcode",friendlyName:"Zip Code",type:"text",required:!0,helperText:"Zip code for support address",defaultCollapsed:!0}]},{name:"addressString",friendlyName:"Support Address String",type:"text",required:!1,localized:!1,helperText:"The full support address as a string",defaultCollapsed:!0}]},{name:"pageConfig",friendlyName:"Page Configurations",type:"object",defaultCollapsed:!0,subFields:[{name:"accountDetails",friendlyName:"Account Details Page",type:"object",defaultCollapsed:!0,subFields:[{name:"birthdayBannerConfig",friendlyName:"Birthday Banner Configuration",type:"object",defaultCollapsed:!0,subFields:[{name:"content",friendlyName:"Banner Content",type:"html",required:!1,localized:!0,defaultCollapsed:!0},{name:"linkText",friendlyName:"Link Text",type:"text",localized:!0,defaultCollapsed:!0},{name:"linkUrl",friendlyName:"Link URL",type:"url",required:!1,localized:!0,defaultCollapsed:!0},{name:"styles",friendlyName:"Styles",type:"object",defaultCollapsed:!0,subFields:[{name:"display",friendlyName:"Display",type:"text",defaultCollapsed:!0},{name:"alignItems",friendlyName:"Align Items",type:"text",defaultCollapsed:!0},{name:"margin",friendlyName:"Margin",type:"text",defaultCollapsed:!0},{name:"padding",friendlyName:"Padding",type:"text",defaultCollapsed:!0},{name:"backgroundColor",friendlyName:"Background Color",type:"color",required:!1,localized:!1,defaultCollapsed:!0},{name:"color",friendlyName:"Color",type:"color",required:!1,localized:!1,defaultCollapsed:!0}]}]}]},{name:"cart",friendlyName:"Cart Page",type:"object",defaultCollapsed:!0,localized:!1,subFields:[{name:"continueShoppingUrl",friendlyName:"Continue Shopping URL",type:"url",required:!1,localized:!1,defaultCollapsed:!0},{name:"imageContainerBGColor",friendlyName:"Background color for Image Container",type:"color",required:!1,localized:!1,defaultCollapsed:!0},{name:"freeShippingBanner",friendlyName:"Free Shipping Banner Configuration",type:"object",defaultCollapsed:!0,subFields:[{name:"isVisible",friendlyName:"Show Free Shipping Banner",type:"boolean",required:!1,localized:!0,defaultCollapsed:!0},{name:"loggedOutBannerContent",friendlyName:"Logged Out Banner Content",type:"html",required:!1,localized:!0,defaultCollapsed:!0},{name:"loggedInBannerContent",friendlyName:"Logged In Banner Content",type:"html",required:!1,localized:!0,defaultCollapsed:!0},{name:"styles",friendlyName:"Styles",type:"object",defaultCollapsed:!0,subFields:[{name:"backgroundColor",friendlyName:"Background Color",type:"color",required:!1,localized:!1,defaultCollapsed:!0},{name:"color",friendlyName:"Color",type:"color",required:!1,localized:!1,defaultCollapsed:!0}]}]},{name:"notices",friendlyName:"Cart Notices",type:"object",defaultCollapsed:!0,subFields:[{name:"securePaymentNotice",friendlyName:"Secure Payment Notice",type:"object",defaultCollapsed:!0,subFields:[{name:"isVisible",friendlyName:"Visible?",type:"boolean",localized:!0,helperText:"Show the secure payment notice on the cart page",defaultCollapsed:!0},{name:"text",friendlyName:"Text",type:"html",required:!1,localized:!0,helperText:"Content for the secure payment notice",defaultCollapsed:!0},{name:"styles",friendlyName:"Styles",type:"object",helperText:"Styles for the secure payment notice",defaultCollapsed:!0,subFields:[{name:"backgroundColor",friendlyName:"Background Color",type:"color",defaultCollapsed:!0},{name:"color",friendlyName:"Color",type:"color",defaultCollapsed:!0}]}]}]}]},{name:"checkout",friendlyName:"Checkout Page",type:"object",defaultCollapsed:!0,localized:!1,subFields:[{name:"freeShippingBanner",friendlyName:"Free Shipping Banner",type:"object",defaultCollapsed:!0,subFields:[{name:"isVisible",friendlyName:"Visible?",type:"boolean",required:!1,localized:!0,helperText:"Show the free shipping banner on the checkout page",defaultCollapsed:!0},{name:"loggedOutBannerContent",friendlyName:"Logged Out Banner Content",type:"html",required:!1,localized:!0,helperText:"Content for the free shipping banner when the user is not logged in",defaultCollapsed:!0},{name:"loggedInBannerContent",friendlyName:"Logged In Banner Content",type:"html",required:!1,localized:!0,helperText:"Content for the free shipping banner when the user is logged in",defaultCollapsed:!0}]},{name:"securePaymentNotice",friendlyName:"Secure Payment Notice",type:"object",defaultCollapsed:!0,subFields:[{name:"isVisible",friendlyName:"Visible?",type:"boolean",required:!1,localized:!0,helperText:"Show the secure payment notice on the checkout page",defaultCollapsed:!0},{name:"content",friendlyName:"Content",type:"html",required:!1,localized:!0,helperText:"Content for the secure payment notice",defaultCollapsed:!0}]},{name:"autoSignUp",friendlyName:"Auto Sign Up",type:"object",defaultCollapsed:!0,subFields:[{name:"isVisible",friendlyName:"Visible?",type:"boolean",required:!1,localized:!0,helperText:"Show the secure payment notice on the checkout page",defaultCollapsed:!0},{name:"isChecked",friendlyName:"Checked by Default",type:"boolean",required:!1,localized:!0,helperText:"Whether the checkbox is checked by default",defaultCollapsed:!0},{name:"labelText",friendlyName:"Label Text",type:"html",required:!1,localized:!0,helperText:"Text for the auto sign up checkbox",defaultCollapsed:!0},{name:"helpModal",friendlyName:"Help Modal",type:"object",defaultCollapsed:!0,subFields:[{name:"header",friendlyName:"Header",type:"html",required:!1,localized:!0,helperText:"Header content for the auto sign up help modal",defaultCollapsed:!0},{name:"content",friendlyName:"Content",type:"html",required:!1,localized:!0,helperText:"Content for the auto sign up help modal",defaultCollapsed:!0}]}]},{name:"smsOptIn",friendlyName:"SMS Opt In",helperText:"Use these settings to control whether you offer SMS sign up on the checkout form.",type:"object",defaultCollapsed:!0,subFields:[{name:"isVisible",friendlyName:"Enabled?",type:"boolean",required:!1,localized:!0,helperText:"Show SMS opt-in at checkout to guests or returning customers who have not yet opted-in",defaultCollapsed:!0},{name:"title",friendlyName:"Title",type:"text",required:!1,localized:!0,helperText:"The text to display on this section title",defaultCollapsed:!0},{name:"content",friendlyName:"CTA Content",type:"html",required:!1,localized:!0,helperText:"Text for the SMS sign up CTA.",defaultCollapsed:!0}]}]},{name:"orderDetails",friendlyName:"Order Details Page",type:"object",defaultCollapsed:!0,localized:!1,subFields:[{name:"title",friendlyName:"Title",type:"html",required:!1,localized:!0,helperText:"Title for the order details section on the checkout page",defaultCollapsed:!0},{name:"tableHeaderStyle",friendlyName:"Table Header Style",type:"object",required:!1,localized:!1,helperText:"Style for the order details table header",defaultCollapsed:!0,subFields:[{name:"color",friendlyName:"Color",type:"color",required:!1,localized:!1,helperText:"Text color for the order details table header",defaultCollapsed:!0},{name:"backgroundColor",friendlyName:"Background Color",type:"color",required:!1,localized:!1,helperText:"Background color for the order details table header",defaultCollapsed:!0}]},{name:"tableContentStyle",friendlyName:"Table Content Style",type:"object",required:!1,localized:!1,helperText:"Style for the order details table content",defaultCollapsed:!0,subFields:[{name:"backgroundColor",friendlyName:"Background Color",type:"color",required:!1,localized:!1,helperText:"Background color for the order details table content",defaultCollapsed:!0}]},{name:"buyItAgainButton",friendlyName:"Buy It Again Button",type:"object",required:!1,localized:!1,defaultCollapsed:!0,helperText:'Configuration for the "Buy It Again" button in the order details section',subFields:[{name:"text",friendlyName:"Button Text",type:"html",required:!1,localized:!0,helperText:'Text to display on the "Buy It Again" button',defaultCollapsed:!0},{name:"classes",friendlyName:"Classes",type:"text",required:!1,localized:!1,helperText:'CSS classes to apply to the "Buy It Again" button',defaultCollapsed:!0}]},{name:"reOrderAllButton",friendlyName:"Re-Order All Button",type:"object",required:!1,localized:!1,defaultCollapsed:!0,helperText:'Configuration for the "Re-Order All" button in the order details section',subFields:[{name:"text",friendlyName:"Button Text",type:"html",required:!1,localized:!0,helperText:'Text to display on the "Re-Order All" button',defaultCollapsed:!0},{name:"classes",friendlyName:"Classes",type:"text",required:!1,localized:!1,helperText:'CSS classes to apply to the "Re-Order All" button',defaultCollapsed:!0}]}]},{name:"resetPassword",friendlyName:"Reset Password Page",type:"object",defaultCollapsed:!0,localized:!1,subFields:[{name:"title",friendlyName:"Page Title",type:"html",required:!1,localized:!0,helperText:"Title for the reset password page",defaultCollapsed:!0}]},{name:"subscriptionCancel",friendlyName:"Subscription Cancellation Page",type:"object",defaultCollapsed:!0,localized:!1,subFields:[{name:"cancelText",friendlyName:"Cancel Text",type:"html",required:!1,localized:!0,helperText:"Text displayed on the subscription cancellation page",defaultCollapsed:!0},{name:"cancelReasons",friendlyName:"Cancel Reasons",type:"list",required:!1,localized:!0,defaultCollapsed:!0,helperText:"List of reasons for subscription cancellation",subFields:[{name:"title",friendlyName:"Reason",type:"text",required:!0,helperText:"The reason for cancellation.",localized:!0,makeEntryTitle:!0,defaultCollapsed:!0},{name:"text",friendlyName:"Display Content",type:"html",required:!1,helperText:"This is the content that will be displayed for this cancellation reason",localized:!0,defaultCollapsed:!0},{name:"identifier",friendlyName:"Identifier",type:"select",required:!0,defaultCollapsed:!0,helperText:"System identifier for this cancellation reason — used for analytics tracking",enum:[g.DoNotLike,g.NotWorking,g.NoBenefits,g.NoFitNoNeed,g.Budget,g.Mistake,g.Try,g.TooMuch,g.TravelMove,g.DoNotNeed,g.AnotherReason,g.NotHelpingSkin,g.SkinImproved,g.PetDoesNotLike,g.NotHelpingPet,g.NoneGiven]},{name:"buttons",friendlyName:"Buttons",type:"list",required:!1,defaultCollapsed:!0,subFields:[{name:"text",friendlyName:"Button Text",type:"text",required:!1,helperText:"Text to display on the button",defaultCollapsed:!0},{name:"link",friendlyName:"Button Link",type:"url",required:!1,helperText:"URL to navigate to when this button is clicked",defaultCollapsed:!0},{name:"type",type:"select",friendlyName:"Button Type",required:!1,helperText:"Determines the button behavior — links navigate away, while other types trigger actions",enum:[b.Link,b.Update,b.Keep,b.Continue,b.Cancel],defaultValue:"link",defaultCollapsed:!0}],helperText:"Buttons to display for this cancellation reason."}]}]},{name:"subscriptionEdit",friendlyName:"Subscription Edit",type:"object",defaultCollapsed:!0,localized:!1,subFields:[{name:"subscriptionItemDefaultImage",friendlyName:"Subscription Item Default Image",type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],required:!1,localized:!1,defaultCollapsed:!0,helperText:"Default image to display for subscription items"},{name:"shipNow",friendlyName:"Ship Now",type:"object",required:!1,defaultCollapsed:!0,localized:!1,subFields:[{name:"modalHeadlineContent",friendlyName:"Modal Headline Content",type:"html",required:!0,helperText:"Headline text displayed in the Ship Now modal",localized:!0,defaultCollapsed:!0},{name:"modalContent",friendlyName:"Modal Content",type:"html",required:!0,helperText:"Main content displayed in the Ship Now modal. You can use $FREQUENCY and it will be replaced with the frequency of the subscription.",localized:!0,defaultCollapsed:!0}]}]},{name:"upsell",friendlyName:"Upsell Page",type:"object",defaultCollapsed:!0,localized:!1,subFields:[{name:"mbgImage",friendlyName:"Money Back Guarantee Image",type:"file",showTemplatePicker:!0,allowedFileTypes:["jpeg","png","svg","webp"],required:!1,localized:!0,defaultCollapsed:!0,helperText:"Image displayed on the upsell page for the money back guarantee"},{name:"mbgText",friendlyName:"Money Back Guarantee Text",type:"html",required:!1,localized:!0,defaultCollapsed:!0,helperText:"Text displayed on the upsell page for the money back guarantee"}]}]},{name:"cookieConfig",friendlyName:"Cookie Configuration",type:"object",defaultCollapsed:!0,helperText:"Settings for the cookie consent popup displayed to visitors",subFields:[{name:"popupBanner",friendlyName:"Cookie Policy Popup Banner",type:"object",defaultCollapsed:!0,helperText:"Configure the cookie policy popup banner",subFields:[{name:"content",friendlyName:"Content",type:"html",localized:!0,defaultCollapsed:!0,helperText:"Content for the cookie policy popup banner"},{name:"bannerStyles",friendlyName:"Banner Styles",type:"object",defaultCollapsed:!0,subFields:[{name:"backgroundColor",friendlyName:"Background Color",type:"color",required:!1,defaultCollapsed:!0},{name:"borderRadius",friendlyName:"Border Radius",type:"text",required:!1,defaultCollapsed:!0}]},{name:"buttonStyles",friendlyName:"Button Styles",type:"object",defaultCollapsed:!0,subFields:[{name:"backgroundColor",friendlyName:"Background Color",type:"color",required:!1,defaultCollapsed:!0},{name:"color",friendlyName:"Color",type:"color",required:!1,defaultCollapsed:!0}]}]}]},{name:"seo",friendlyName:"SEO",type:"object",defaultCollapsed:!0,localized:!1,helperText:"Search engine optimization settings for the brand",subFields:[{name:"description",friendlyName:"Site Description",type:"longText",defaultCollapsed:!1,helperText:"Default meta description for the website, used when pages do not provide their own"},{name:"knowsAbout",friendlyName:"Topics",type:"Tags",defaultCollapsed:!1,helperText:"Topics the brand is knowledgeable about, used in structured data for search engines"}]}]}))(e,l)}siteBanner(e){return(e=>({name:"banner",kind:"component",displayName:"Banner / Announcement",helperText:"Banners / Announcements to display on your website",contentTitleField:void 0,fields:[{name:"position",friendlyName:"Banner Position",type:"select",enum:[w.AboveHeader,w.BelowHeader],defaultValue:"Above Header",helperText:"Select where this banner should appear on the page",defaultCollapsed:!0}],editingUrlLogic:"return `"+e+"/builder-banner-section?builder.preview=true&builder.frameEditing=true`"}))(e)}defaultWebsiteSection(e){return(e=>({name:"default-website-section",kind:"component",displayName:"Default Website Section",helperText:"Default section for the website",contentTitleField:void 0,fields:[{name:"sectionType",friendlyName:"Section Type",type:"select",required:!0,localized:!1,defaultCollapsed:!0,enum:["cartPageAboveSummaryContent","cartPageBelowSummaryContent","cartPageEmptyCartContent","cartPageTopSectionContent","gdprContent","mainFooter","offerSelectorAboveCTAContent","offerSelectorBelowCTAContent","subscriptionManagementNoSubsContent"],helperText:"Choose where this content section appears on the website"}],editingUrlLogic:"return `"+e+"/builder-default-website-section?builder.preview=true&builder.frameEditing=true`"}))(e)}pageModel(e){return(e=>{const{productModelId:l,productGroupModelId:t,categoryModelId:a,bannerModelId:o,blogCategoryModelId:i,sectionModelId:d,editUrl:r}=e;return{name:"page",displayName:"Page",kind:"page",helperText:"Default model for creating pages",contentTitleField:void 0,fields:[{name:"title",friendlyName:"Title",type:"text",required:!0,helperText:"A short title for this page. If the SEO Page Title is not provided, this field is used for SEO. This field is not localized, so it is highly suggested to use the Heading.",defaultCollapsed:!1},{name:"pageType",friendlyName:"Page Type",type:"select",defaultValue:S.GENERAL,required:!0,helperText:"Select the type of page. This will determine which components are added automatically.",enum:[S.GENERAL,S.BLOG,S.PRODUCT],defaultCollapsed:!1},{name:"pdp",friendlyName:"Product Detail Page",type:"object",required:!1,subFields:[{name:"type",friendlyName:"Product Page Type",type:"select",defaultValue:k.PRODUCT,required:!0,helperText:"Choose whether this is a single product, product group, or multi-group page",enum:[k.PRODUCT,k.PRODUCT_GROUP,k.MULTI_GROUP],defaultCollapsed:!1},{name:"product",friendlyName:"Product",type:"reference",required:!1,helperText:"Select the product to display",modelId:l,copyOnAdd:!0,showIf:"return options.get('type') === 'Product'",defaultCollapsed:!1},{name:"productGroup",friendlyName:"Product Group",type:"reference",required:!1,helperText:"Select the product group to display",modelId:t,copyOnAdd:!0,showIf:"return options.get('type') === 'Product Group'",defaultCollapsed:!1},{name:"pdpTitle",friendlyName:"Display Title",type:"text",localized:!0,required:!0,helperText:'For multi-group selectors, provide the "product" title to present.',showIf:"return options.get('type') === 'Multi-Group'",defaultCollapsed:!1},{name:"pdpDescription",friendlyName:"Description",type:"html",localized:!0,required:!1,helperText:'For multi-group selectors, provide the "product" description to present.',showIf:"return options.get('type') === 'Multi-Group'",defaultCollapsed:!1},{name:"multiProductGroup",friendlyName:"Product Groups",type:"list",required:!1,localized:!1,helperText:"Add the product groups to include in this multi-group page",showIf:"return options.get('type') === 'Multi-Group'",defaultCollapsed:!1,subFields:[{name:"group",friendlyName:"Product Group",type:"reference",required:!0,helperText:"Select a product group to include",modelId:t,copyOnAdd:!0,defaultCollapsed:!1},{name:"optionsOverrides",friendlyName:"Offer Options",type:"list",localized:!0,required:!1,copyOnAdd:!1,defaultCollapsed:!1,helperText:"Override the default offer options for this product group",subFields:[{name:"quantity",friendlyName:"Quantity",type:"number",required:!1,defaultValue:void 0,defaultCollapsed:!1,helperText:"The quantity for this offer option"},{name:"description",friendlyName:"Description",type:"html",localized:!0,required:!1,defaultCollapsed:!1,helperText:"Description displayed for this offer option"},{name:"pillLabel",friendlyName:"Pill Label",type:"text",localized:!0,required:!1,defaultCollapsed:!1,helperText:'Text shown in the pill badge for this option (e.g. "Most Popular")'},{name:"pillColor",friendlyName:"Pill Color",type:"color",required:!1,defaultCollapsed:!1,helperText:"Background color of the pill badge"}]},{name:"pillLabel",friendlyName:"Pill Label",type:"text",localized:!0,required:!1,helperText:"(Optional) If provided, used to apply a pill on this option (e.g. Most Popular).",defaultCollapsed:!1}]},{name:"slides",friendlyName:"Product Slides",type:"list",required:!1,subFields:[{name:"image",friendlyName:"Image",type:"file",required:!0,helperText:"Upload a product slide image",allowedFileTypes:["jpeg","png","svg","webp"],copyOnAdd:!0,defaultCollapsed:!1}],helperText:"Select the image slides to display for this product. If no slides are provided, the product's default image will be used.",copyOnAdd:!0,defaultCollapsed:!1},{name:"slideThumbs",friendlyName:"Product Slides Thumbnails",type:"list",required:!1,subFields:[{name:"image",friendlyName:"Image",type:"file",required:!0,helperText:"Upload a thumbnail image",allowedFileTypes:["jpeg","png","svg","webp"],copyOnAdd:!0,defaultCollapsed:!1}],helperText:"Select the image thumbnails slides to display for this product. If no slides are provided, the Product Slides will be used",copyOnAdd:!0,defaultCollapsed:!1},{name:"sliderComponent",type:"select",enum:[L.SLIDER_A,L.SLIDER_B,L.SLIDER_ZOOM],friendlyName:"Slider Component",defaultValue:L.SLIDER_A,required:!1,helperText:"Select the style slider component to use for the product images",defaultCollapsed:!1},{"@type":"@builder.io/core:Field",name:"hideNativeOfferSelector",friendlyName:"Hide Native Offer Selector",helperText:"Set to true to fully hide the native Offer Selector to provide your own (e.g. via VWO)",type:"boolean",localized:!1,defaultCollapsed:!0,advanced:!0},{name:"offerSelector",friendlyName:"Offer Selector",type:"object",required:!1,subFields:[{name:"osType",friendlyName:"Type",type:"select",defaultValue:z.VERTICAL__FLAVOR_DROPDOWN__TYPE_TOGGLE,required:!1,helperText:"Select the type of offer selector to display",enum:[z.VERTICAL,z.VERTICAL__FLAVOR_DROPDOWN__TYPE_TOGGLE,z.STACKED__FLAVOR_BUTTONS__QUANTITY_TOGGLE,z.BUNDLE_GROUP],defaultCollapsed:!1},{name:"features",friendlyName:"Features",type:"object",required:!1,helperText:"Configure behavior and defaults for the offer selector",subFields:[{name:"defaultPurchaseType",friendlyName:"Default Purchase Type",type:"select",defaultValue:F.ONE_TIME,required:!1,helperText:"When both purchase options are available to the customer, this is the option that will be selected by default.",enum:[F.ONE_TIME,F.SUBSCRIPTION],defaultCollapsed:!1},{name:"preferredQuantity",friendlyName:"Initial Offer Quantity",type:"number",defaultValue:3,required:!1,helperText:"Enter the quantity you would prefer users see first. If that quantity is not available,\n we will locate the closest quantity available (defaults to 3 if not set).",defaultCollapsed:!1},{name:"showSavings",friendlyName:"Show Savings?",type:"boolean",defaultValue:{Default:!0},required:!1,helperText:"Display the savings amount on each offer option",defaultCollapsed:!1},{name:"savingsType",friendlyName:"Savings Type",type:"select",defaultValue:v.PERCENT,required:!1,helperText:"When showing savings, display as a percentage or value saved.",enum:[v.PERCENT,v.DOLLAR],defaultCollapsed:!1},{name:"showMemberPriceMessage",friendlyName:"Show Member Price Message",type:"boolean",defaultValue:{Default:!0},required:!1,helperText:"Show the member price message below the offer selector",defaultCollapsed:!1},{name:"showSubscriptionPriceMessage",friendlyName:"Show Subscription Price Message",type:"boolean",defaultValue:{Default:!0},required:!1,helperText:"Show the subscription price message below the offer selector",defaultCollapsed:!1},{name:"scrollToTopOffset",friendlyName:"Scroll to Top Offset (px)",type:"number",defaultValue:170,required:!1,helperText:'The number of pixels to offset the Scroll to Top button. Note: The label for this button may be set in the "Labels" section.',defaultCollapsed:!1},{name:"enableAnonymousSubscriptions",friendlyName:"Always Show Subscriptions",type:"boolean",defaultValue:{},required:!1,helperText:"Enable this to present subscriptions (when available) to non-MyAccount visitors. By default, a user must be logged in to access this option.",defaultCollapsed:!1,hidden:!1,advanced:!0}],defaultCollapsed:!1},{name:"labels",friendlyName:"Labels",type:"object",defaultValue:{quantitySelector:{"@type":"@builder.io/core:LocalizedValue"},actionButton:{Default:"ADD TO CART"},subscriptionOffer:{Default:"Or $PRICE when you subscribe & save"},flavorSelector:{Default:"Choose a flavor"},otpToggle:{Default:"Single purchase"},memberOffer:{Default:"Or pay member price of"},scrollButton:{Default:'<span class="material-icons">keyboard_arrow_up</span> Back to top'},outOfStock:{Default:'Sorry, we"re currently out of stock'},outOfStockFormSuccess:{Default:'<p class="text-center">We will notify you as soon as this item is back in stock.</p>'},subscriptionToggle:{Default:"Subscribe & save"}},required:!1,subFields:[{name:"actionButton",friendlyName:"Action Button",type:"text",defaultValue:{Default:"ADD TO CART"},required:!1,helperText:'Text on the main call-to-action button (e.g. "ADD TO CART")',defaultCollapsed:!1},{name:"subscriptionOffer",friendlyName:"Subscription Offer",type:"text",defaultValue:{Default:"Or $PRICE when you subscribe & save"},required:!1,helperText:"Use $PRICE to represent the price, this will be automatically replaced.",defaultCollapsed:!1},{name:"memberOffer",friendlyName:"Member Offer",type:"text",defaultValue:{Default:"Or pay member price of"},required:!1,helperText:'Message shown for member pricing (e.g. "Or pay member price of")',defaultCollapsed:!1},{name:"subscriptionToggle",friendlyName:"Subscription Toggle",type:"text",defaultValue:{Default:"Subscribe & save"},required:!1,helperText:"The label for the button when selecting a subscription",defaultCollapsed:!1},{name:"otpToggle",friendlyName:"One-Time Purchase Toggle",type:"text",defaultValue:{Default:"Single purchase"},required:!1,helperText:"The label for the button when selecting a single purchase (otp).",defaultCollapsed:!1},{name:"outOfStock",friendlyName:"Out of Stock",type:"text",defaultValue:{Default:'Sorry, we"re currently out of stock'},required:!1,helperText:"The text to display when this product is marked as Out of Stock.",defaultCollapsed:!1},{name:"outOfStockFormSuccess",friendlyName:"Out of Stock Form Success Message",type:"html",defaultValue:{Default:'<p class="text-center">We will notify you as soon as this item is back in stock.</p>'},required:!1,helperText:"The message displayed when a user requests to be notified when this product is back in stock.",defaultCollapsed:!1},{name:"scrollButton",friendlyName:"Scroll Button Content",type:"html",defaultValue:{Default:'<span class="material-icons">keyboard_arrow_up</span> Back to top'},required:!1,helperText:"Content displayed in the scroll-to-top button",defaultCollapsed:!1},{name:"flavorSelector",friendlyName:"Flavor / Option Selector",type:"text",defaultValue:{Default:"Choose a flavor"},required:!1,helperText:'Label for the flavor/option dropdown (e.g. "Choose a flavor")',defaultCollapsed:!1},{name:"quantitySelector",friendlyName:"Quantity Selector",type:"text",localized:!0,required:!1,helperText:"(Optional) Provide a label for the quantity selection. Only displayed if your selected offer selector supports this feature.",defaultCollapsed:!1}],helperText:"Customize the various labels on the offer selector",defaultCollapsed:!1},{name:"bestSellerImage",friendlyName:"Best Seller Image",type:"file",allowedFileTypes:["jpeg","png","svg","webp"],defaultValue:"https://cdn.builder.io/api/v1/image/assets%2Fcf992cf7343c4ca182a884e9a45f394e%2F3805efcc18184db8bccf74d5c5aaf891?format=webp",required:!1,helperText:"The small image to display alongside the best seller offer",defaultCollapsed:!0},{name:"bestValueImage",friendlyName:"Best Value Image",type:"file",defaultValue:"https://cdn.builder.io/api/v1/image/assets%2Fcf992cf7343c4ca182a884e9a45f394e%2F82105508987e4459bc4405617d4bee33",required:!1,helperText:"The small image to display alongside the best value offer (highest quantity)",allowedFileTypes:["jpeg","png","svg","webp"],defaultCollapsed:!0},{name:"cssOverrides",friendlyName:"CSS Properties",type:"object",defaultValue:{},required:!1,helperText:"Advanced CSS customizations for the offer selector",subFields:[{name:"signupOfferCustomCssProps",friendlyName:"Signup Offer CSS",type:"map",required:!1,helperText:"Custom CSS properties for the signup offer section",defaultCollapsed:!1},{name:"signupOfferPriceCustomCssProps",friendlyName:"Signup Offer Price CSS",type:"map",required:!1,helperText:"Custom CSS properties for the signup offer price",defaultCollapsed:!1}],defaultCollapsed:!0}],helperText:"Configure the offer selector to display.",defaultCollapsed:!0,showIf:"return !(options.get('hideNativeOfferSelector'))"},{name:"category",type:"reference",required:!1,helperText:"Provide the category to display breadcrumb navigation",modelId:a,copyOnAdd:!0,friendlyName:"Category",defaultCollapsed:!1},{name:"desktopSliderOverride",friendlyName:"Slider Override (Desktop)",type:"reference",required:!1,helperText:"(Optional) Select content to display in place of your PDP's product image slider. Disables the slider on desktop. On mobile, this content is hidden and the standard slider is displayed.",modelId:d,copyOnAdd:!0,defaultCollapsed:!1}],helperText:"Configure the PDP options",showIf:"return options.get('pageType') === 'Product'",defaultCollapsed:!1},{name:"blog",friendlyName:"Blog Configuration",type:"object",required:!1,subFields:[{name:"title",friendlyName:"Blog Title",helperText:"Provide a title for this blog when shown on a grid or list. If not provided, the page title will be used.",type:"text",required:!1,localized:!0,defaultCollapsed:!1},{name:"publicationDate",friendlyName:"Publication Date",type:"timestamp",helperText:"Provide the publication date, this is used for sorting.",required:!0,localized:!1,defaultCollapsed:!1},{name:"snippet",friendlyName:"Blog Snippet",helperText:"Provide a snippet of the blog to display when shown on a grid or list. If not provided, we will attempt to use the page description or SEO description (if available)",type:"longText",required:!1,localized:!0,defaultCollapsed:!1},{name:"author",friendlyName:"Blog Author",type:"text",helperText:"Provide an author for this blog to display when shown on a grid or list.",required:!1,localized:!1,defaultCollapsed:!1},{name:"thumbnail",friendlyName:"Blog Thumbnail",type:"file",required:!1,helperText:"Provide an image to display when shown on a grid or list. If not provided, we will attempt to use the SEO image (if available)",allowedFileTypes:["jpeg","png","svg","webp"],copyOnAdd:!0,defaultCollapsed:!1},{name:"categories",friendlyName:"Blog Categories",type:"list",required:!1,copyOnAdd:!0,defaultCollapsed:!0,helperText:"Assign blog categories for filtering and navigation",subFields:[{name:"category",friendlyName:"Blog Category",type:"reference",modelId:i,required:!0,defaultCollapsed:!1,copyOnAdd:!1,helperText:"Select a blog category"}]}],helperText:"Configure the blog options",showIf:"return options.get('pageType') === 'Blog'",defaultCollapsed:!0},{name:"heading",friendlyName:"SEO Page Title",type:"text",required:!1,helperText:"Provide an alternate page title to use for SEO purposes (if blank, the page title is used)",defaultCollapsed:!1},{name:"description",friendlyName:"SEO Description",type:"longText",required:!1,helperText:"Set the page description for SEO here. This is automatically embedded in your page.",defaultCollapsed:!0},{name:"seoImage",friendlyName:"SEO Image",type:"file",required:!1,helperText:"Provide an image to be used for SEO purposes",allowedFileTypes:["jpeg","png","svg","webp"],copyOnAdd:!0,defaultCollapsed:!1},{name:"search",friendlyName:"Search Configuration",type:"object",required:!1,subFields:[{name:"title",friendlyName:"Search Title",type:"text",required:!1,helperText:"Used when showing this page in your site's search function. If no value is provided, the page title will be used.",defaultCollapsed:!1},{name:"description",friendlyName:"Search Description",type:"text",required:!1,helperText:"(Optional) Provide a description to be used when showing this page in search results. If no value is provided, the SEO description is used.",defaultCollapsed:!1},{name:"hide",friendlyName:"Hide from Search",type:"boolean",required:!1,helperText:"Use this to hide this page from search results. This does not prevent navigation to the page.",defaultCollapsed:!1},{name:"content",friendlyName:"Content",type:"longText",required:!1,helperText:"(Optional) Use this field to add keywords or phrases to assist in search results (e.g. related products, categories, key words, etc.)",defaultCollapsed:!1}],helperText:"Configure how this page displays in your site's built-in search results. Pages will not show in search results if neither the SEO or Search information is configured. You may also elect to hide the page from search results.",defaultCollapsed:!0},{"@type":"@builder.io/core:Field",name:"banners",friendlyName:"Banners",helperText:"Select the banner(s) to display on this page. These will be displayed in the\n order provided, but always below site-wide banners.",type:"list",defaultCollapsed:!0,localized:!1,subFields:[{"@type":"@builder.io/core:Field",name:"banner",friendlyName:"Sitewide Banner",type:"reference",localized:!1,helperText:"Select the banner to display.",defaultCollapsed:!0,modelId:o,copyOnAdd:!1}]},{name:"disableStickyHeader",friendlyName:"Disable Sticky Header",helperText:"Disable the sticky header for this page only.",type:"boolean",localized:!1,defaultCollapsed:!0,advanced:!0},{name:"showBundleDrawer",friendlyName:"Show Bundle Drawer",helperText:"Enable the bundle drawer for this page.",type:"boolean",localized:!1,defaultCollapsed:!0,advanced:!0},{name:"robotsMeta",friendlyName:"Robots Meta",type:"object",required:!1,helperText:"Settings for the robots meta tag.",subFields:[{name:"noIndex",friendlyName:"No Index",type:"boolean",required:!1,defaultCollapsed:!0,helperText:"Prevents pages from being indexed and displayed in search engine result pages"},{name:"noFollow",friendlyName:"No Follow",type:"boolean",required:!1,defaultCollapsed:!0,helperText:"Prevents search engines from following links on the pages"},{name:"noArchive",friendlyName:"No Archive",type:"boolean",required:!1,defaultCollapsed:!0,helperText:"Prevents search engines from showing Cached links for pages"},{name:"noImageIndex",friendlyName:"No Image Index",type:"boolean",required:!1,defaultCollapsed:!0,helperText:"This option prevents images on a page from being indexed by Google and other search engines"},{name:"noSnippet",friendlyName:"No Snippet",type:"boolean",required:!1,defaultCollapsed:!0,helperText:"Prevents a snippet from being shown in the search results"}],defaultCollapsed:!0}],editingUrlLogic:"return `"+r+"${targeting.urlPath}?builder.preview=true&builder.frameEditing=true`"}})(e)}blogCommentModel(e){return(e=>({...C,fields:[...C.fields,{name:"blog",friendlyName:"Blog Post",helperText:"The blog that this comment is linked to",type:"reference",modelId:e,required:!0,defaultCollapsed:!1,copyOnAdd:!1}]}))(e)}};function q(e,l){const t=l.find(l=>l.name===e);return console.log(`[Hippo Commerce - CART] Retrieved model "${e}" ---\x3e`,t?.id),t}async function P(e,l,t){const a=crypto.randomUUID().toString();try{await t.models.update({...e,id:l?l.id:a});const o=l?l.id:a;return console.log("[Hippo Commerce - CART] Model update complete ---\x3e",e.name,o),o}catch(l){console.error("[Hippo Commerce - CART] Set model error",l instanceof Error?{message:l.message,name:l.name,stack:l.stack}:l),console.error("[Hippo Commerce - CART] Failed model shape:",e.name)}return l?l.id:e.name}return i.Builder.register("plugin",{id:r,name:"Hippo Commerce",settings:[{type:"select",enum:["Gundry MD","Dr. Marty","Driven Entrepreneur","Other"],name:"brand",friendlyName:"Brand",helperText:"Select your brand. If you select 'Other', provide your brand under the advanced settings.",required:!0},{type:"text",name:"editUrl",friendlyName:"Development Site URL",helperText:"Provide the URL to your development site.",required:!0},{type:"text",name:"apiUrl",friendlyName:"API URL",helperText:"Provide the URL to your instance of the Hippo Commerce API.",required:!0},{type:"text",name:"apiUser",friendlyName:"API User",helperText:"Provide your Hippo Commerce API User.",required:!0},{type:"password",name:"apiPassword",friendlyName:"API Password",helperText:"Provide your Hippo Commerce API Password.",required:!0},{type:"text",name:"otherBrand",friendlyName:"Custom Brand",helperText:"Provide your brand exactly as it is configured in your Hippo Commerce API.",required:!1,advanced:!0}],ctaText:"Save & Create Models",async onSave(e){await e.updateSettings({hasConnected:!0}),await async function(e){const l=function(e){const l=e.user.organization.value.settings.plugins?.get(r),t=l?.get("editUrl");return t??""}(e),t=e.models.result,a=q(I.ingredientsModel.name,t),o=q(I.categoryModel.name,t),i=q(I.productTagModel.name,t),d=q(I.useCaseModel.name,t),n=await P(I.ingredientsModel,a,e),s=await P(I.categoryModel,o,e),p=await P(I.productTagModel,i,e),u=await P(I.useCaseModel,d,e);if(!(n&&s&&p&&u))return;const f=I.productModel({ingredientsModelId:n,categoryModelId:s,tagModelId:p,useCaseModelId:u}),c=q(f.name,t),m=await P(f,c,e);if(!m)return;const y=I.siteBanner(l),h=q(y.name,t),g=await P(y,h,e),b=q(I.blogCategoryModel.name,t),T=await P(I.blogCategoryModel,b,e),C=I.defaultWebsiteSection(l),N=q(C.name,t),x=await P(C,N,e);if(!g||!T||!x)return;const w=I.productGroupModel(m,x),S=q(w.name,t),k=await P(w,S,e);if(!k)return;const z=I.pageModel({productModelId:m,productGroupModelId:k,categoryModelId:s,bannerModelId:g,blogCategoryModelId:T,sectionModelId:x,editUrl:l}),L=q(z.name,t),F=await P(z,L,e);if(!F)return;const v=I.blogCommentModel(F),D=q(v.name,t);await P(v,D,e);const O=I.productGridConfigModel({categoryId:s,useCaseId:u,ingredientId:n,tagId:p}),A=q(O.name,t),M=await P(O,A,e);if(!M)return;const B=I.brandConfig(M,g),U=q(B.name,t);await P(B,U,e),console.info("[Hippo Commerce - CART] Model setup complete")}(d.default),await d.default.dialogs.alert("Hippo Commerce Cart settings saved.")}}),i.Builder.register("app.onLoad",async({triggerSettingsDialog:e})=>{const l=d.default.user.organization.value.settings.plugins?.get(r),t=l?.get("hasConnected"),a=l?.get("brand"),o=l?.get("apiUser"),i=l?.get("apiPassword"),n=l?.get("apiUrl"),s=l?.get("editUrl");t&&a&&o&&i&&n&&s||await e(r)}),{}})())}}});
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@goldenhippo/builder-cart-plugin",
3
- "version": "0.1.0",
3
+ "version": "0.2.0",
4
4
  "description": "Builder.io plugin for Golden Hippo commerce brand management",
5
5
  "main": "dist/plugin.system.js",
6
6
  "repository": {
@@ -1,9 +0,0 @@
1
- /**
2
- * @license React
3
- * react-jsx-runtime.production.min.js
4
- *
5
- * Copyright (c) Facebook, Inc. and its affiliates.
6
- *
7
- * This source code is licensed under the MIT license found in the
8
- * LICENSE file in the root directory of this source tree.
9
- */