import { get, startCase, uniqueId } from "lodash"; import { ILayoutSettings, PageSectionCategory, } from "@sc/plugins/misc/v2/blocks/weblayouts/types"; import { ComponentTypes } from "@sc/plugins/webcomponents/v2/types"; import { ContentLayouts } from "@sc/plugins/misc/v2/blocks/weblayouts/Content/types"; import { combineData, lorem } from "../../utils"; import { default as defaultData } from "./data.json"; import { style } from "./style"; import { getImagePlaceholder, ImagePlaceholderTypes, getVideoPlaceholder, VideoPlaceholderTypes, } from "../../Placeholders"; import theme from "../../theme"; import { IconTypes } from "../../../../../../webcomponents/v2/Icon"; import { CTALayouts } from "../types"; const content = combineData(defaultData); const settings: ILayoutSettings = { label: CTALayouts.EIGHTEEN, layout: CTALayouts.EIGHTEEN, previewImage: "https://sandcastleassets.s3.amazonaws.com/blocks/cta/CTA18.png", default: { type: ComponentTypes.SECTION, label: PageSectionCategory.CTA, bodyOnly: true, canHaveChildren: false, properties: { ...style.SECTION, ...style.SECTION_INNER, }, children: [ { type: ComponentTypes.CONTAINER, canHaveChildren: true, properties: { padding: 30, }, children: [ { type: ComponentTypes.HEADLINE, canHaveChildren: false, properties: { ...style.HEADLINE, ...get(content, "main_headline.style", {}), }, html: "Get Your Account Now!", }, { type: ComponentTypes.HEADLINE, canHaveChildren: false, properties: { ...style.SUBHEADLINE, ...get(content, "main_headline.style", {}), }, html: "...and LOCK IN YOUR 50%-OFF DISCOUNT", }, { type: ComponentTypes.TEXT, canHaveChildren: false, properties: { ...style.TEXT, fontWeight: "bold" as "bold", color: theme.highlightColor, textAlign: "center", }, html: "** (A SAVINGS of over $400.00) **", }, ], }, { type: ComponentTypes.COLUMNS, canHaveChildren: false, properties: { width: "100%", }, children: [ { type: ComponentTypes.COLUMN, canHaveChildren: true, preventDelete: true, md: parseInt((6 * 100) / 12), properties: { height: "100%", padding: 0, minHeight: 20 }, children: [ getImagePlaceholder({ type: ImagePlaceholderTypes.NONE, src: "https://cdn.pixabay.com/photo/2013/07/12/15/19/box-149665_960_720.png", style: { width: 300, maxWidth: "100%", display: "inline-block", textAlign: "right", backgroundColor: theme.backgroundColor, }, }), { type: ComponentTypes.PICTURE, canHaveChildren: false, properties: { display: "inline-block", width: 220, textAlign: "left", marginTop: -120, }, src: "https://www.centrixdental.com/media/wysiwyg/Centrix-100-percent-GUARANTEE.png", }, ], }, { type: ComponentTypes.COLUMN, canHaveChildren: true, preventDelete: true, md: parseInt((6 * 100) / 12), properties: { height: "100%", padding: 0, minHeight: 20 }, children: [ { type: ComponentTypes.LIST, icon: IconTypes.CheckCircleOutline, iconStyle: style.LISTITEM.iconStyle, contentStyle: style.LISTITEM.contentStyle, style: style.LISTITEM.style, data: [ { id: Math.random() .toString(36) .slice(2), caption: `Free Bonus #1: ${lorem.generateSentences(1)}`, }, { id: Math.random() .toString(36) .slice(2), caption: `Free Bonus #2: ${lorem.generateSentences(1)}`, }, { id: Math.random() .toString(36) .slice(2), caption: `Free Bonus #3: ${lorem.generateSentences(1)}`, }, ], }, ], }, ], }, { type: ComponentTypes.CONTAINER, canHaveChildren: true, properties: { padding: 40, backgroundColor: "#EEE", marginTop: 40, borderRadius: 5, border: "1px solid #DDD", }, children: [ { type: ComponentTypes.HEADLINE, canHaveChildren: false, properties: { ...style.HEADLINE, fontSize: "22pt" }, html: `Your Full 30-Day 100% Money-Back Guarantee`, }, { type: ComponentTypes.HEADLINE, canHaveChildren: false, properties: { ...style.SUBHEADLINE, fontSize: "18pt" }, html: `Just Say "Maybe"...`, }, { type: ComponentTypes.HEADLINE, canHaveChildren: false, properties: { ...style.SUBHEADLINE, fontSize: "14pt" }, html: `And Put It To The Test For An Entire Month... Then Decide`, }, { type: ComponentTypes.TEXT, canHaveChildren: false, properties: { ...style.TEXT, ...get(content, "sub_headline.style", {}), }, html: lorem.generateParagraphs(1), }, { type: ComponentTypes.TEXT, canHaveChildren: false, properties: { ...style.TEXT, ...get(content, "sub_headline.style", {}), }, html: lorem.generateParagraphs(1), }, ], }, { type: ComponentTypes.BUTTON, canHaveChildren: false, properties: style.BUTTON.style, caption1: "Get Your Account Now!", caption1style: style.BUTTON.caption1, }, { type: ComponentTypes.TEXT, canHaveChildren: false, properties: { ...style.TEXT, fontWeight: "bold" as "bold", color: theme.highlightColor, textAlign: "center", }, html: "** This Discount Offer & All Bonuses EXPIRES TONIGHT At Midnight **", }, ], }, }; export default settings;