/home/sylamedg/sylantechelectricals.com/wp-content/themes/thrive-theme/inc/assets/dist/main.min.js
!function(){var e={355:function(e,t,i){const n=[],s=[i(806),i(4746),i(3988),i(595),i(2533),i(7392),i(9012),i(5932),i(9796),i(4798)];parseInt(tcb_main_const.is_woo_active)&&s.push(i(5826)),s.forEach((e=>{_.each(e,((e,t)=>{n.push({tag:t,callback:e})}))})),e.exports=n},7392:function(e,t,i){(t=>{const n=i(2952),s=i(3724),o=i(5037);e.exports={"tcb.element.click":e=>{const t=TVE.inner_$(e.currentTarget);if(!t.is(TVE.identifier("sidebar-trigger"))){const e=TVE.Theme.utils.getSectionInstance(t);e&&e.isDynamic()&&!e.inEditMode()&&!e.$element.hasClass("section-no-overlay")&&new TVE.Theme.views.SectionOverlay({section:e})}},"tcb.edit_mode.exit":e=>{if(e.is(n.identifier+", "+o.identifier)){const t=TVE.Theme.utils.getSectionInstance(TVE.inner_$(e));t&&(t.update(),TVE.Editor_Page.focus_element(e))}},"tcb.wordfence.whitelist":(e,t)=>{const i=e.match(/sections\/(\d*)/);if(i&&2===i.length){const e=TVE.Theme.$wrapper.find(`.thrive-section-${i[1]}`);e.length&&TVE.Theme.utils.getSectionInstance(e).update(!0)}},tcb_after_cloud_template:(e,t)=>{"fancy-divider"===t&&e.hasClass("section-background")&&e.removeAttr("data-ct-name data-ct").attr("data-element-name",`${TVE.ucFirst(e.attr("data-section"))} Section`)},"theme.section.after_insert":(e,t)=>{t.$element.find(`.${TVE.Models.Widget.elementClass}`).each(((e,t)=>{new TVE.Models.Widget(TVE.inner_$(t)).maybeAddEmptyPlaceholder()})),t.$element.find(TVE.identifier("post_list")).each(((e,t)=>{const i=TVE.inner_$(t),n=i.attr("data-pagination-type");"numeric"!==n&&"load_more"!==n||TVE.PostList.content.renderPaginationForPostList(i),TVE.PostList.layout.applyLayout(i,!0);const s=_.uniq(i.find(TVE.identifier("article")).map(((e,t)=>parseInt(t.dataset.id)))).filter((e=>void 0===TVE.PostList.posts[e]));s.length&&TVE.PostList.utils.fetchPosts({get_initial_posts:!0,post_ids:s})})),t.$element.find(TVE.identifier("social_follow")).each(((e,t)=>{TVE.Components.social_follow.controls.SocialFollowPalettes.matchGlobal(TVE.inner_$(t))}))},"tcb.dragstart":e=>{TVE.FLAGS.dragFromSectionInstance=TVE.Theme.utils.getSectionInstance(e)},"tcb.image.change":e=>{const t=TVE.Theme.utils.getSectionInstance(TVE.ActiveElement);t&&t.$content.length&&TVE.ActiveElement.width()>t.$content.width()&&TVE.ActiveElement.head_css({width:"100%"})},"tcb.after-insert":e=>{const t=TVE.Theme.utils.getSectionInstance(e);if(!t||t.isDynamic()||!TVE.FLAGS.dragFromSectionInstance)return;const i=TVE.FLAGS.dragFromSectionInstance;if("sidebar"===t.type&&TVE.inner.window.ThriveTheme.sidebar.fixContentHeight(),i.selector!==t.selector){const o=TVE.stylesheet.cssRules,a=TVE.Theme.utils.escapedRegEx;for(let e=0;e<o.length;e++)if(o[e].type===CSSRule.MEDIA_RULE)for(let r=0;r<o[e].cssRules.length;r++){const l=o[e].cssRules[r];if(l.selectorText.includes(i.selector)){const c=l.selectorText.replace(TVE.Theme.utils.pseudoSelectorsRegex(),"").replace(a(TVE.Theme.CONST.body_class,"g"),"").replace(a(s.prefix,"g"),"").replace(a(i.selector,"g"),"").replace(a(i.constructor.backgroundSelector,"g"),"").replace(a(i.constructor.contentSelector,"g"),"").replace(a(TVE.CONST.global_css_prefix,"g"),"").trim();if(c.length&&0===c.split(",").map((e=>e.trim())).filter((e=>n.typographySuffix.includes(e))).length&&t.$element.find(c).length){const n=l.cssText.replace(a(i.selector,"g"),t.baseSelector);o[e].deleteRule(r),o[e].insertRule(TVE.remove_extra_spaces(n),r)}}}e.is(TVE.identifier("post_list"))&&TVE.PostList.dynamicImage.regeneratePostListStyleNodes(e)}TVE.FLAGS.dragFromSectionInstance=null},"tcb.element.focus":e=>{const t=TVE.Theme.utils.getSectionInstance(e);t&&(t.constructor.is(e)||t.isContent(e)||t.isBackground(e))&&setTimeout((()=>t.toggleComponents()))}}})(jQuery)},9796:function(e){e.exports={"tcb.focus_element.before":e=>{if(e.is(TVE.identifier("thrive_dynamic_list"))){const t=e.find(".no-results-text").length;TVE.Components.thrive_dynamic_list&&TVE.Components.thrive_dynamic_list.controls.Limit.update(e),TVE.Components.typography.controls.TextAlign.$el.toggle(!t)}},element_selected:e=>{e.hasClass("thrive-dynamic-styled-list-item")&&(TVE.ActiveElement=e.siblings().addBack())},"thrive_theme.query_modal.rule_after_render":e=>{TVE.Components.thrive_dynamic_list&&TVE.Components.thrive_dynamic_list.isDynamicList(e.model.get("query_type"))&&e.relationSelect.disable(!0)},"thrive_theme.query_modal.collection_add_rule":(e,t)=>{TVE.Components.thrive_dynamic_list&&TVE.Components.thrive_dynamic_list.isDynamicList(e.model.get("query_type"))&&e.model.set("relation","NOT IN")},"thrive_theme.query_modal.add_rule":e=>{TVE.Components.thrive_dynamic_list&&TVE.Components.thrive_dynamic_list.isDynamicList(TVE._type(e.$element))&&e.$("span.no-label").removeAttr("data-no-label")},"tve.query_modal.collection_remove_rule":(e,t)=>{TVE.Components.thrive_dynamic_list.isDynamicList(TVE._type(t.$element))&&1===e.index&&t.newRule()},"thrive_theme.query_modal.rule_before_initialize":e=>{TVE.Components.thrive_dynamic_list&&TVE.Components.thrive_dynamic_list.isDynamicList(e.model.get("query_type"))&&(e.template="theme-main/dynamic-list/query-rule")},"thrive_theme.query_modal.before_close":e=>{if("thrive_dynamic_list"===e.el.dataset.element){const t=TVE.PostList.utils.readQueryFromElement(e.$element[0]);e.$element.attr("data-type",t.post_type)}}}},806:function(e,t,i){function n(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function s(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}(t=>{const o=i(8955),a=e=>{let i=e.$(".ttb-dynamic-toc").hide();if(TVE.CONST.theme.is_theme_template&&TVE.Theme.template.isSingular()){if(!i.length){const n=TVE.tpl("theme-main/toc-dynamic-info")();i=t(n).insertAfter(e.$('[data-fn="refresh"]')),e.$(".tve-toc-no-headings").html(n)}i.toggle(0===TVE.ActiveElement.parents("#tve_editor").length)}},r=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:t();if(0===e.text().trim().length&&0===e.find(".thrv_wrapper").length&&0===e.closest(TVE.identifier("post_list")).length){const t=TVE.Theme.template.secondary(),i=TVE.apply_filters("theme_empty_post_content_placeholder",TVE.tpl("theme-main/empty-post-content-placeholder")({contentType:TVE.apply_filters("theme_empty_post_content_post_type",t)}),t);e.html(i)}};e.exports={"tcb-ready":()=>{TVE.Theme.template.isSingular()&&(TVE.inner.$body.find(TVE.identifier("post_content")).each(((e,t)=>{r(TVE.inner_$(t))})),TVE.main.sidebar_extra.on("drawer_opened",(e=>{if("elements"===e){const e=TVE.Elements.thrive_comments,t=!!TVE.inner_$(e.identifier).length;TVE.main.sidebar_toggle_elements([e.tag],!t)}}))),TVE.Theme.$wrapper.find(`${TVE.identifier("post_content")} [${TVE.Models.ConditionalDisplayManager.displayKeyAttr}]`).each(((e,t)=>{t.removeAttribute(TVE.Models.ConditionalDisplayManager.displayKeyAttr),t.removeAttribute(TVE.Models.ConditionalDisplayManager.groupKeyAttr)}))},"tve.lazyload.done":e=>{if([...Object.values(e.theme_sections||{}),...Object.values(e.headers_and_footers||{})].forEach((e=>{void 0===TVE.Theme.data.local[e.type]&&(TVE.Theme.data.local[e.type]={}),TVE.Theme.data.local[e.type][e.id]=e})),TVE.Theme.template.isSingular()&&e.custom_fields&&TVE.CONST.inline_shortcodes["Custom fields"]){const t=_.findIndex(TVE.CONST.inline_shortcodes["Custom fields"],(e=>"Custom Fields Global"===e.name));Object.assign(TVE.CONST.inline_shortcodes["Custom fields"][t].input.id,_.pick(e.custom_fields,["value","real_data","labels"])),void 0!==TVE.CONST.dynamic_links["Custom Fields Global"]&&(TVE.CONST.dynamic_links["Custom Fields Global"].links=e.custom_fields.links),TVE.CONST.colors.custom_fields=e.custom_fields.colors,TVE.CONST.has_acf_colors=e.custom_fields.has_acf_colors?1:0}},"tve.colors_lazyload.done":e=>{TVE.CONST.acf_is_active&&(TVE.CONST.colors.custom_fields=e.custom_fields.colors,TVE.CONST.has_acf_colors=e.custom_fields.has_acf_colors?1:0)},"tcb.element.remove":e=>{const t=e.attr("data-selector");if(t&&0===TVE.Theme.$wrapper.find(t).length){const e=TVE.main.all_media();let t,i,n;for(let s,o=0;s=e[o++];)for(n=TVE.CSS_Rule_Cache.media_rule(s),t=0;i=n.cssRules[t];)0===TVE.inner_$(i.selectorText).length?n.deleteRule(t):t++}},"tcb.after-insert":e=>{let i,n;e.find(".thrive-shortcode-content").each(((e,s)=>{if(n=t(s),i=n.attr("data-id"),TVE.PostList.posts&&i){const e=TVE.PostList.utils.getArticleID(n);if(!e)return!1;const t=TVE.inner_$(TVE.apply_filters("tcb.post_list_article.sync."+i,TVE.PostList.posts[e][i],TVE.PostList.posts[e],n));n.html(t.text())}}));const s=e.closest(TVE.identifier("article"));if(TVE.Theme.template.isSingular()&&0===s.length&&(!TVE.FLAGS.$dragged_element||TVE.FLAGS.$dragged_element.static_element)){const t=TVE.Elements[TVE._type(e)];if(!t)return void console.warn("Corresponding element not found inside TVE.Elements for:"+e);t.shortcode&&TVE.PostList.content.replaceShortcodeWithData(t.shortcode,e,TVE.Theme.CONST.ID)}e.is(TVE.identifier("post_content"))&&r(e),TVE.Theme.content.init_selectors(e)},"tcb.element.focus":e=>{e.is(TVE.Theme.selectors.editor.no_drag.join(","))&&TVE.drag.hide_handle(),TVE.Theme.$wrapper.find("."+TVE.PostList.constants.SIMILAR_EDIT_CLASS).removeClass(TVE.PostList.constants.SIMILAR_EDIT_CLASS);const t=TVE._type(e);_.each(TVE.Theme.selectors.haveDynamicPrefix,((i,n)=>{i.includes(t)&&e.closest(TVE.identifier(n)).find(TVE.identifier(t)).addClass(TVE.PostList.constants.SIMILAR_EDIT_CLASS)}))},"tcb.show_icons":(e,t,i)=>{TVE.state()!==TVE.STATE_EDIT&&e.is(TVE.Theme.selectors.editor.no_drag.join(","))&&i&&i.$drag_handle.hide()},icon_element_changed(e,i){const n=e.closest(".thrive-dynamic-styled-list-item");n.length&&(n.parents(".thrive-dynamic-list").attr("data-icon",e.find("svg").data("id")),n.siblings().each(((i,n)=>{t(n).find(".thrv_icon").html(e.html())})))},"tcb.link.linkchange":e=>{TVE.ActiveElement.find(".tcb-button-link").removeAttr("data-dynamic-link"),TVE.PostList.utils.checkForPostListSync(TVE.ActiveElement)},"tcb.link.linkreplace":e=>{const t=TVE.ActiveElement.find(".tcb-button-link");t.attr("href")&&!t.attr("href").startsWith("[thrive_")&&(t.removeAttr("data-dynamic-link"),e.unset("dynamic_link")),TVE.PostList.utils.checkForPostListSync(TVE.ActiveElement)},"tcb.component.after_init.button":e=>{const t=e.$('span[data-fn="open_button_search_settings"]'),i=e.$("#tcb-button-link-search-control");t.hide(),t.before(TVE.tpl("theme-main/dynamic-link-buttons")()),i.before(TVE.tpl("theme-main/dynamic-link-dropdown")());const n=e.$("#tcb-button-link-dynamic-control");e.switch_link_settings=function(t,s){const o=s.dataset.link_settings;e.$('span[data-fn="switch_link_settings"]').removeClass("blue-text"),e.$(`span[data-link_settings="${o}"]`).addClass("blue-text"),i.toggle("static"===o),n.toggle("dynamic"===o)},e.select_dynamic_link=function(e,t){const i=TVE.ActiveElement.find(".tcb-button-link"),n=TVE.apply_filters("theme.set_dynamic_link",t.options[t.selectedIndex].value);i.attr("href",TVE.Theme.utils.applyBrackets(n)),i.attr("data-dynamic-link",n.replace(/[\[\]']+/g,"")),TVE.PostList.utils.checkForPostListSync(TVE.ActiveElement)},e.after_update=function(){const t=TVE.ActiveElement.find(".tcb-button-link").attr("data-dynamic-link");t?(n.find("select").val(TVE.Theme.utils.extractShortcodeName(t)),e.$('span[data-link_settings="dynamic"]').click()):(e.$('span[data-link_settings="static"]').click(),n.find("select").val("#"))}},"tcb.component.after_init.animation":e=>{const t=e.views.link.$("#a-link-main");t.before(TVE.tpl("theme-main/dynamic-link")());const i=e.views.link.$(".dynamic-link-select"),n=e.views.link.$(".tcb-link-search"),s=e.views.link.dom;e.views.link.dom=function(){s.apply(this),e.views.link.switch_link_settings(null,{value:"static"})};const o=e.edit;e.edit=function(t,n){if(o.apply(this,[t,n]),this.views.link.$element){const t=this.views.link.$element.attr("data-dynamic-link");t&&(i.val(TVE.Theme.utils.extractShortcodeName(t)),e.views.link.switch_link_settings(null,{value:"dynamic"}))}},e.views.link.switch_link_settings=function(t,s){const o=s.value;this.data.href||(this.data.href="#"),n.toggle("static"===o),i.toggle("dynamic"===o),e.views.link.$(`.link-type[value="${o}"]`).attr("checked",!0)},e.views.link.linkType=function(e,n){this.data.href="#",t.toggle("static"===n.value).find("input").val(this.data.href),this.$element&&("static"===n.value?this.$element.removeAttr("data-dynamic-link"):this.data.href=this.$element.attr("data-dynamic-link")?TVE.Theme.utils.extractShortcodeName(this.$element.attr("data-dynamic-link")):i.find("option:first").val()),i.toggle("dynamic"===n.value).val(this.data.href)},e.views.link.dynamicLink=function(e,t){this.data.href=TVE.apply_filters("theme.set_dynamic_link",TVE.Theme.utils.applyBrackets(t.value)),this.data.dynamic_link=!0}},"tcb.extend-sidebar-right":e=>{i(8004)(e)},"tcb.element.selected":(e,t)=>{if(TVE.CONST.theme.is_theme_template){let e="";switch(t){case"header":case"footer":e="theme-hf";break;case"theme_section":case"template-wrapper":case"template-content":e=t}e&&_.each(TVE.Elements[t].components,((t,i)=>{TVE.Components[i].toggleDropdown("docked",i===e)}))}"post_content"!==t&&o.resetCounter()},"tcb.element.duplicate":(e,t)=>{const i=TVE._type(e);if(TVE.Theme.selectors.haveDynamicPrefix.hasOwnProperty(i)){t.hasClass("tcb-clear")&&(t=t.find(TVE.identifier(i)));const n=TVE.CSS_Rule_Cache.uniq_id(t,!0);TVE.head_css_copy(e.attr("data-css"),n)}e.closest(".sidebar-section").length&&TVE.inner.window.ThriveTheme.sidebar.fixContentHeight()},"tcb.inline_shortcodes.init":e=>{TVE.Theme.utils.inline_shortcodes_init(e)},"tcb.froala.element_editor_init":(e,t)=>{e.froalaEditor(t).on("froalaEditor.popups.show.shortcode.popup",(function(e,t){const i=t.popups.get("shortcode.popup");if(TVE.Theme.template.isSingular()&&TVE.Theme.template.secondary()===TVE.Theme.constants.templates.PAGE){const e=TVE.ActiveElement.closest(TVE.identifier("post_list")).length>0;i.find('option[value="Taxonomies"]').toggle(e)}}))},tcb_after_cloud_template:e=>{TVE.Theme.utils.inline_shortcodes_init(e),TVE.Theme.utils.image_shortcodes_init(e),TVE.Theme.content.init_selectors(e)},"tcb.link_apply":(e,t)=>{t.dynamic_link&&e.attr("data-dynamic-link",t.href.replace(/[\[\]']+/g,""))},"tcb.component.after_init.VideoControls":e=>{(TVE.apply_filters("theme.allow_dynamic_video.provider",!1)||"video"===TVE.Theme.template.format())&&i(5271).init(e)},tcb_before_global_style_save:(e,t)=>{e&&e.is(TVE.Theme.selectors.editor.theme_buttons.join(", "))&&e.attr("data-button-style",t.cls)},"tcb.element.selected.thrive_taxonomy_term_description":e=>{e.find(".tcb-no-taxonomy").length&&TVE.Theme.utils.disable_components(!0)},"tcb.dynamic_image.source_changed":(e,t)=>{0===e.closest(TVE.identifier("post_list")).length&&e.toggleClass("thrive-dynamic-source",t)},"tcb.editorActions.init":()=>{TVE.CONST.theme.is_theme_template&&_.each(function(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?n(Object(i),!0).forEach((function(t){s(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):n(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}({main:TVE.Theme.$main,template_content:TVE.Theme.$content,wrapper:TVE.Theme.$wrapper},TVE.Theme.$sections),(e=>e.removeClass("tve-droppable"))),TVE.$body.append('<div id="tt-loading-wrapper"></div>')},"tcb.page-map.after_update":(e,t)=>{if(e&&e.length){let i;if(TVE.Theme.models.HFSection.is(e)?i=`.thrv_${e.attr("data-section")}`:TVE.Theme.models.Section.is(e)?i=`.${e.attr("data-section")}-section .section-content`:"content"===e.attr("id")&&(i="#content .main-content-background"),i){const n=t.$(`[data-section="${i}"]`);n.length&&(n.addClass("tsp-selected"),n.toggleClass("tsp-dynamic",!!e.attr("data-id")))}}if(Object.values(TVE.Theme.$sections).forEach((e=>{const i=e.attr("data-section"),n=t.$(".tsp-"+i).toggleClass(TVE.Theme.constants.identifiers.HIDE_SECTION_CLASS,e.hasClass("hide-section"));if("top"===i||"bottom"===i){const s=e.parent().is(TVE.Theme.$content),o=t.$(".tsp-wrapper");s?o["top"===i?"prepend":"append"](n):o["top"===i?"before":"after"](n)}})),t.$(".tcb-icon-sticky-sidebar").toggle(TVE.inner.window.ThriveTheme.sidebar&&TVE.inner.window.ThriveTheme.sidebar.isSticky()),t.$el.toggleClass("reverse-columns","left"===TVE.inner.window.ThriveTheme.utils.getSidebarPosition()),TVE.inner.window.ThriveTheme.sidebar){t.$(".tcb-icon-sticky-sidebar").toggle(TVE.inner.window.ThriveTheme.sidebar.isSticky());const e=TVE.inner.window.ThriveTheme.sidebar.isOffScreen()&&!TVE.inner.window.ThriveTheme.sidebar.$element.hasClass(TVE.Theme.constants.identifiers.HIDE_SECTION_CLASS);t.$el.toggleClass("tsp-off-screen-sidebar",e).toggleClass("tsp-off-screen-sidebar-open",e&&TVE.inner.window.ThriveTheme.sidebar.getJsonData("off-screen","visibleInEditor")).attr("data-off-screen-type",TVE.inner.window.ThriveTheme.sidebar.getJsonData("off-screen","display",TVE.main.device))}},"tcb.page-map.extend":e=>{e.visibilityToggle=(e,t,i)=>{const n=TVE.Theme.utils.getSectionInstance(TVE.Theme.$sections[e]);n&&n.toggle(i)}},"tcb.symbol.before_save_logic":e=>{e||(e=TVE.ActiveElement),e.find("[data-selector]").removeAttr("data-selector")},"tcb.element.click":e=>{const t=TVE.inner_$(e.currentTarget);"post_content"===TVE._type(t)&&o.elementClick(t)},"tcb.editor.undo":()=>{TVE.Theme.$sections.header=TVE.Theme.$wrapper.find("header.thrv_symbol"),TVE.Theme.$sections.footer=TVE.Theme.$wrapper.find("footer.thrv_symbol"),TVE.Theme.content.init_selectors()},"component.update.toc.toc":a,"component.update.toc_old.toc_old":a,tcb_set_dynamic_link:(e,t)=>{const i=t.attr("dynamic-postlink");e.removeClass("tcb_post_prev_link tcb_post_next_link"),"tcb_post_prev_link"!==i&&"tcb_post_next_link"!==i||e.addClass(i)},"tcb.wordfence.whitelist":(e,t)=>{/templates\/(\d*)/.test(e)&&TVE.Theme.content.save(!1,!0,!0)},after_undo_redo:(e,t)=>{TVE.inner.window.ThriveTheme.initElements()},"theme.after_section_update":(e,t)=>{e.offset().top<TVE.Theme.content.getTemplatePreviewHeight()&&setTimeout(TVE.Theme.content.previewSavedTemplate,10)}}})(jQuery)},4798:function(e){const t=()=>TVE.inner.window.ThriveTheme.sidebar;let i=null,n=null;e.exports={"theme.section.before_insert.sidebar|11":(e,s)=>{t().isOffScreen()&&(i=t().$element.find(".tve-off-screen-sidebar-trigger").html(),n=t().$element.find(".tve-sidebar-close-icon").html())},"theme.section.after_insert.sidebar|11":(e,s)=>{TVE.refreshIconsOnScroll(t().$content,"sidebar",(()=>TVE.inner.$body.hasClass("theme-has-off-screen-sidebar"))),t().isOffScreen()&&TVE.Components.theme_section.controls.ShowOffscreenInEditor&&TVE.Components.theme_section.controls.ShowOffscreenInEditor.getValue()&&(i&&(t().$element.find(".tve-off-screen-sidebar-trigger").html(i),i=null),n&&(t().$element.find(".tve-sidebar-close-icon").html(n),n=null),t().offScreenRefresh())},"tcb.responsive_visibility_changed":e=>{e.hasClass("sidebar-section")&&t().isOffScreen()&&t().offScreenRefresh()},"component.update.animation":()=>{TVE.$('.action-item [value="sidebar_toggle"] + span').toggle(Object.keys(TVE.main.responsive).some((e=>t().isOffScreen(e))))},"theme.update_template.after":e=>{if(!e&&0===TVE.inner_$('[data-tcb-events*="sidebar_toggle"]').length){const e=Object.keys(TVE.main.responsive).filter((e=>t().isOffScreen(e)&&!t().getJsonData("off-screen","hasDefaultTrigger",e)));e.length&&setTimeout((()=>{TVE.page_message(`Sidebar doesn't have a trigger set for <strong>${e.join(", ")}</strong> !`,-1,6e3)}),5e3)}},icon_element_changed:e=>{if(e.is(TVE.identifier("sidebar-close-icon"))){const i=e.find(".tcb-icon").attr("data-id");t().setJsonData("off-screen","closeIcon",i)}}}},595:function(e){const t=()=>{TVE.Theme.template.isSingular()&&TVE.Theme.utils.allowPostContentDelete()};e.exports={"tcb-ready":()=>{t(),TVE.Theme.$wrapper.find(TVE.identifier("blog_list")).each(((e,t)=>{const i=TVE.PostList.utils.getFeaturedPostList(TVE.inner_$(t));if(i.length>0){const e=new Set;if(i.find(TVE.identifier("article")).each(((t,i)=>{e.add(parseInt(i.getAttribute("data-id")))})),e.size>0){const i=TVE.PostList.utils.readQueryFromElement(t);i&&Array.isArray(i.rules)&&(i.rules=i.rules.filter((t=>{let i=!0;return"post"===t.taxonomy&&"NOT IN"===t.operator&&Array.isArray(t.terms)&&e.has(parseInt(t.terms[0]))&&(i=!1),i})),t.setAttribute("data-query",TVE.PostList.utils.stringifyAndReplace(i)))}}}))},"tcb.after-insert":t,"tcb.element.remove":t,"tcb.element.duplicate":t,"tcb.edit_mode.exit":()=>{TVE.Theme.template.isSingular()&&(TVE.PostList.EditMode.toggleMainElements(!0,!0),TVE.PostList.EditMode.toggleOnlyListElements(!1))},"tcb.post_list.posts_loaded":()=>{const e=TVE.stylesheet.cssRules;for(let t=0;t<e.length;t++)if(e[t].type===CSSRule.MEDIA_RULE)for(let i=0;i<e[t].cssRules.length;i++){const n=e[t].cssRules[i],s=n.selectorText;if(!s.includes(TVE.identifier("post_list"))&&!s.includes(TVE.identifier("blog_list"))&&TVE.Theme.utils.isDynamicCss(n.cssText)){const o=TVE.Theme.$wrapper.find(s.replace(TVE.Theme.utils.pseudoSelectorsRegex(),"")),a=TVE.PostList.utils.getArticleID(o),r=TVE.PostList.dynamicImage.replaceDynamicImage(a,n.cssText);r!==n.cssText&&(e[t].deleteRule(i),e[t].insertRule(r,i))}}}}},9012:function(e,t,i){jQuery,e.exports={"tcb.favorite_colors.after_render":e=>{if(TVE.CONST.theme.skin_palettes&&e.color_picker.options.showGlobals){const t=i(4325);e.$el.find(".tcb-skin-toggle-content").length||(e.$el.append(TVE.tpl("theme-main/theme-style-panel/skin-colors")()),e.skin_color_view=new t({el:e.$("#tcb-skin-color-details")[0],favorites_view:e}),e.variableViews.skin=e.skin_color_view)}},"tcb.favorite_colors.reset_html":e=>{if(TVE.CONST.theme.skin_palettes){const t=1===TVE.CONST.theme.skin_palettes.version?TVE.CONST.theme.skin_variables.colors:TVE.CONST.theme.palette_colors;if(t&&e.color_picker.options.showGlobals){let i="";_.each(t,(t=>{i+=e.global_thumb({global_prefix:TVE.CONST.theme.skin_variables.colors_prefix,css_prop:"background-color",color:TVE.getCssVariableValue(TVE.CONST.theme.skin_variables.colors_prefix+t.id),name:t.name,id:t.id,synced_var:"",custom_name:t.custom_name})})),e.$(".tcb-skin-colors-container").html(i.split("p-thumb-inner").join("p-thumb-inner tcb-tpl-var"))}}}}},5932:function(e,t,i){jQuery,e.exports={"tcb.favorite_gradients.after_render":e=>{if(TVE.CONST.theme.skin_variables&&TVE.CONST.theme.skin_variables.gradients.length){const t=i(3521);e.$el.append(TVE.tpl("theme-main/theme-style-panel/skin-gradients")()),e.skin_gradient_view=new t({el:e.$("#skin-gradient-details")[0],favorites_view:e}),e.variableViews.skin=e.skin_gradient_view}},"tcb.favorite_gradients.reset_html":e=>{if(TVE.CONST.theme.skin_variables&&TVE.CONST.theme.skin_variables.gradients.length){let t="";_.each(TVE.CONST.theme.skin_variables.gradients,(i=>{t+=e.global_thumb({global_prefix:TVE.CONST.theme.skin_variables.gradients_prefix,css_prop:"background-image",color:TVE.getCssVariableValue(TVE.CONST.theme.skin_variables.gradients_prefix+i.id),name:i.name,id:i.id,synced_var:"",custom_name:i.custom_name})})),e.$(".skin-gradients-container").html(t.split("p-thumb-inner").join("p-thumb-inner tcb-tpl-var"))}},"tcb.gradient_picker.toggle_gradient_controls":(e,t)=>{TVE.CONST.theme.skin_variables&&TVE.CONST.theme.skin_variables.gradients.length&&e.css_variable&&e.$(".fav-colors .tcb-skin-toggle-content").toggleClass("tcb-disabled",t&&!e.edit_css_variable)}}},4746:function(e){var t;t=jQuery,e.exports={"tcb.component.after_init.social":function(e){},"tcb.after_social_style_change":function(e,i){!function(e,i,n){const s=e.closest(TVE.identifier("article"));if(s.length>0){const o=s.find(TVE.identifier("thrive_author_follow")).index(e);-1!==o&&TVE.Theme.$wrapper.find(TVE.identifier("article")).each(((e,s)=>{const a=t(s).find(TVE.Elements.thrive_author_follow.identifier).eq(o);i.renderer.set_config(n)._render_to(a,!0)}))}}(e,i,{style:i.model.selected})}}},5065:function(e){e.exports={"theme_section.remove":e=>{let{type:t,id:i}=e;if(void 0!==TVE.Theme.data.local[t][i]){const e=TVE.Theme.utils.getSectionInstance(TVE.Theme.$sections[t]);e&&parseInt(e.ID)===parseInt(i)&&e.unlink(!0),delete TVE.Theme.data.local[t][i],TVE.Theme.modals.sectionTemplates.visible()&&TVE.Theme.modals.sectionTemplates.section.type===t&&(TVE.Theme.modals.sectionTemplates.setSections(),TVE.Theme.modals.sectionTemplates.build_preview())}}}},3988:function(e,t,i){const n=()=>{TVE.drag.editorActions(TVE.Theme.$wrapper),TVE.Editor_Page.selection_manager.init(TVE.Theme.$wrapper),TVE.Editor_Page.editor=TVE.Theme.$wrapper};i(3724),e.exports={"tcb.symbol.after_save":e=>{e.find(".tcb-shortcode").each(((e,t)=>{const i=t.dataset.shortcode,n=TVE.inner_$(t),s=TVE.PostList.utils.getArticleID(n);if(i&&s&&TVE.PostList.posts[s][i]){const e=TVE.inner_$(TVE.apply_filters(`tcb.post_list_article.sync.${i}`,TVE.PostList.posts[s][i],TVE.PostList.posts[s],n));n.html(e.html())}}))},"tcb.symbol.close_edit_mode":n,"tcb.header-footer.edit":n,"tcb.after_insert_symbol":e=>{TVE.Theme.content.init_selectors(e)},"tcb.symbol.before_preview":e=>{TVE.CONST.theme.is_theme_template&&TVE.Theme.utils.getSectionInstance(TVE.Theme[`$${e.element_type}`]).startPreview()},"tcb.symbol.after_preview":(e,t)=>{TVE.CONST.theme.is_theme_template&&TVE.Theme.utils.getSectionInstance(TVE.Theme.$sections[`${t.element_type}`]).applyPreview(e.data)}}},2533:function(e,t,i){i(2952),e.exports={"tcb.inner_actions.hide_right":e=>{e.$hide_sidebar.hide(),e.$show_sidebar.hide()},"tcb.element.selected":(e,t)=>{const i=TVE.Components.theme_section;"theme_section"===t||"header"===t||"footer"===t?i.tooltip?(i.tooltip.$el.removeClass("tooltip-pulse"),i.tooltip.isVisible()&&!i.tooltip.isDismissed()?setTimeout((()=>i.tooltip.$el.addClass("tooltip-pulse"))):i.tooltip.display()):(i.tooltip=new TVE.Views.other.Tooltip({icon:"",title:"Choose a Ready-Made Design",info:"Pick from our large gallery of pre-built designs for sections.",learnMoreLink:"https://help.thrivethemes.com/en/articles/4578543-how-to-use-the-thrive-theme-builder-sections",type:"tooltip-gallery-section"}),i.tooltip.$el.addClass("section-tooltip"),i.$el.parent().append(i.tooltip.$el),i.tooltip.display()):i.tooltip&&i.tooltip.hide()},"tcb.element.selected.theme_section":e=>{TVE.main.$el.attr("data-theme-section",TVE.Theme.utils.getSectionInstance(e).type)}}},5826:function(e,t,i){const n=i(5168),s=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:TVE.Theme.$wrapper;return i.find(TVE.identifier(`${e}-template`)).length>=t},o=(e,t,i)=>(TVE.Theme.utils.getWooElement(i)&&0===t.parents("#theme-content-section").length&&(e=!1),e),a=e=>{TVE.Theme.template.isProduct()&&e.is(TVE.identifier("product-template"))&&new(n(TVE.inner_$,TVE.inner.window,TVE.inner.window.TCB_Front))(e).tabsInit().redoGallery()},r=e=>{const t=TVE.inner.window.TCB_Front.woocommerce.MiniCart;e.$content.find(t.selector).each(((e,i)=>{new t(TVE.inner_$(i)).refreshContentSelector()}))},l=e=>{const t=e.find(".thrv_widget");t.find(".select2-selection__arrow").remove(),t.find('.woocommerce-product-search button[type="Submit"]').remove(),t.find(".tcb-empty-widget").css("background-image","unset"),e.find("noscript").remove(),e.find(".woocommerce-input-wrapper .select2-selection__arrow").remove(),e.find(".woocommerce-ordering select").css("background-image","unset"),e.find(".product-template-wrapper .variations_form select").css("background-image","unset"),e.find(".woocommerce-MyAccount-navigation-link--dashboard a").css("background","unset"),e.find(".woocommerce-product-gallery__trigger").remove()};e.exports={"tcb-ready":()=>{if(!TVE.Theme.template.isWoo())return;TVE.main.sidebar_extra.on("drawer_opened",(e=>{"elements"===e&&TVE.Theme.constants.WOO_ELEMENTS.forEach((e=>TVE.main.sidebar_toggle_elements([`${e}-template`],TVE.Theme.template[`is${TVE.ucFirst(e)}`]()&&!s(e))))}));const e=new(n(TVE.inner_$,TVE.inner.window,TVE.inner.window.TCB_Front));(new(i(6990)(TVE.inner_$,TVE.inner.window))).toggleProductElements(),e.$template.length&&(_.each(TVE.Components["product-template"].controls,(t=>t.update(e.$template))),e.updateGalleryColumnsClass(),["upsells","related"].forEach((t=>{TVE.Components[`${t}-products`].before_update(e.$template).controls.Display.update(e.$template),e.updateProductsSection(t)})),TVE.main.on("device_change",(()=>{e.redoGallery()}))),TVE.inner_$("body").on("init",".wc-tabs-wrapper, .woocommerce-tabs",(()=>{setTimeout((()=>e.selectTab()))})),TVE.inner.$body.bind("update_checkout",(e=>e.stopImmediatePropagation()))},"tcb.after-insert":e=>{a(e)},tcb_after_cloud_template:(e,t)=>{if(TVE.Theme.template.isProduct()&&a(e),TVE.Theme.template.isShop(!0)&&e.is(TVE.identifier("shop"))){const t=new TVE.inner.window.TCB_Front.woocommerce.Shop,i=TVE.identifier("shop-template"),n=e.attr("data-limit");e.removeClass(TVE.identifier("shop").replace(".","")).addClass(`thrive-shortcode thrive-shop ${i.replace(".","")}`).data("tcb-elem-type","shop-template").attr({"data-posts_per_page":n,"data-shortcode":"thrive_shop_template","data-selector":i}).removeAttr(["data-limit","data-category","data-cat_operator","data-taxonomy","data-terms","data-terms_operator","data-tag","data-tag_operator"].join(" ")),TVE.WooCommerceFn.content.initShopSubElements(e),t.toggleProductElements()}},"tcb.show_icons":(e,t,i)=>{if(TVE.Theme.template.isWoo()){const i=TVE.Theme.utils.getWooElement(e);i&&t.find(".tcb-trash").toggleClass("-v",s(i,2))}},"theme.filter_generated_preview":l,"tcb.symbol.filter_generated_preview":l,"tcb.dragstart":e=>{TVE.Theme.template.isWoo()&&TVE.Theme.utils.getWooElement(e)&&TVE.add_filter("allow_dragenter",o)},"tcb.dragend":()=>{TVE.Theme.template.isWoo()&&TVE.remove_filter("allow_dragenter",o)},"theme.section.after_insert":(e,t)=>{t.$element.find(".thrv_woocommerce_price_filter").each(((e,t)=>{TVE.WooCommerce.constructor.initPriceFilter(TVE.inner_$(t))})),t.$element.find(".thrv_woocommerce_product_categories").each(((e,t)=>{TVE.WooCommerce.constructor.initCategoriesSelect(TVE.inner_$(t))})),t.$element.find(".thrv_woocommerce_layered_nav").each(((e,t)=>{TVE.WooCommerce.constructor.initFilterBySelect(TVE.inner_$(t))})),TVE.WooCommerceFn.content.initShopSubElements(t.$content),r(t)},"tcb.edit_mode.enter":e=>{e.is(".thrv_widget")&&TVE.Theme.content.init_selectors(e)},"tcb.element.selected.product-template":()=>{TVE.Components["product-template"].toggleProductComponents(TVE.main.device)},"theme.section.after_unlink":r}},6872:function(e,t,i){function n(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function s(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?n(Object(i),!0).forEach((function(t){o(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):n(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function o(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}let a={BlogList:i(8576),NoResults:i(5221),BreadcrumbsSeparator:i(8276),Breadcrumbs:i(6052),BreadcrumbsLeaf:i(5732),CommentSection:i(6483),CommentForm:i(5365),CommentList:i(1388),CommentFormInput:i(5875),CommentFormLabel:i(5407),CommentFormSubmit:TVE.Views.Components.LeadGenerationSubmit,DynamicList:i(3394),ThemeSection:i(4243),MainContainer:i(6909),SidebarTrigger:i(7949),ThemeHF:i(8221),ThemeButton:i(9540),SidebarSettings:i(8840),AuthorBox:i(3899),WidgetArea:i(7645),ThemeLayout:i(1521),ThriveAuthorLinks:i(70),ThriveAuthorFollow:i(6832),PrevNext:i(7858)};parseInt(TVE.CONST.is_woo_active)&&(a=s(s({},a),{ShopOptions:i(3491),ProductOptions:i(2459),ProductGallery:i(9383),RelatedProducts:i(776)("related"),UpsellsProducts:i(776)("upsells"),CartTemplate:i(5914),CheckoutTemplate:i(1810),ProductRemoveMainOptions:i(7315)})),e.exports=a},3899:function(e){e.exports=TVE.Views.Base.component.extend({controls_init:function(){TVE.add_action("tcb.edit_mode.exit",(e=>{e.is(TVE.identifier("thrive_author_box"))&&(TVE.Editor_Page.focus_element(e),setTimeout((()=>{TVE.ElementEditIcons.show_icons(e)}),50),TVE.Components.thrive_author_box.show(),TVE.Components.cloud_templates.show())})),TVE.add_action("tcb.element.selected",(e=>{e.is(TVE.identifier("thrive_author_box"))&&TVE.main.EditMode.in_edit()&&TVE.ElementEditIcons.hide_icons()})),TVE.add_action("tcb_after_cloud_template",(e=>{if(e.is(TVE.identifier("thrive_author_box"))){const t=e.find(".thrv_author_follow ");t.find("svg").length||TVE.inner.window.TCB_Front.icons.migrate(t)}})),TVE.add_filter("tcb.get_dropzone_target",(e=>(void 0===TVE.FLAGS.$dragged_element&&TVE.main.EditMode.in_edit()&&TVE.main.EditMode.element()&&TVE.main.EditMode.element().is(TVE.identifier("thrive_author_box"))&&(e=TVE.main.EditMode.element().children().last()),e)))},editMode:function(){TVE.main.EditMode.enter(!1,{show_overlay:!0,show_default_message:!0,can_insert_elements:!0,element_selectable:!1,hidden_elements:[TVE.Elements.thrive_author_box.tag]}),TVE.Components.thrive_author_box.hide(),TVE.Components.cloud_templates.hide()},placeholder_action:function(){this.open_modal()},open_modal:function(){return TVE.modal_open("cloud-templates",{element:TVE.ActiveElement}),!1}})},6832:function(e){const t=new TVE.BaseCollection;e.exports=TVE.Views.Components.Social.extend({controls_init:function(e){TVE.Views.Components.Social.prototype.controls_init.call(this,e),TVE.add_filter("tcb.after-social-render",(function(e){return"thrive_author_follow"===TVE._type(e)&&e.find(".tve_s_item ").each(((e,t)=>{const i=TVE.inner_$(t).find("a"),n=t.dataset.s.replace("_share",""),s=`[thrive_author_follow_urls url='${"x"===n?"t":n}']`;i.removeClass("tve_s_link").attr({target:"_blank",href:s})})),e}))},get_collection:function(){return t},open_edit_panel:function(){return!1}})},70:function(e){const t=new TVE.BaseCollection,i=TVE.Views.Controls.DropPanel.extend({template:TVE.tpl("theme-main/controls/business-links-panel"),onOpen:function(e,t,i){const n=t.dataset.key;this.key=n,this.$link=e.find(`.tve_s_${n} a`),this.isDynamic=this.$link.hasClass("tve-dynamic-link"),this.updateUI()},updateUI:function(){this.$('[type="text"]').val(this.$link.attr("href")),this.$('[type="checkbox"]').prop("checked",this.isDynamic).trigger("change")},changeTab:function(e,t){this.isDynamic=t.checked,this.$(".link-option-panel .static-option").toggle(!this.isDynamic),this.$(".link-option-panel .dynamic-option").toggle(this.isDynamic)},apply:function(e,t){const i={renderAll:!1,setDynamic:this.isDynamic,href:this.isDynamic?"":this.$('[type="text"]').val()};TVE.renderers.thrive_author_links.renderItem(this.key,e,i)},cancel:function(){}});e.exports=TVE.Views.Components.Social.extend({controls_init:function(e){this.dropPanel=new i({}),TVE.Views.Components.Social.prototype.controls_init.call(this,e)},get_collection:function(){return t},open_edit_panel:function(e,t){return this.dropPanel.open(TVE.ActiveElement,t),!1}})},8576:function(e){e.exports=TVE.Views.Components.post_list.extend({controls_init:function(e){TVE.Views.Components.post_list.prototype.controls_init.call(this,e),TVE.PostList.EditMode.toggleListElements(!1,!0)},getStates:function(){return TVE.Theme.template.isSearch()?TVE.Theme.constants.blog_list.states:[]},stateChange:function(e){let t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];t&&TVE.main.EditMode.exit();const i=TVE.inner_$(TVE.Theme.constants.blog_list.no_results.selector),n=TVE.inner_$(TVE.Theme.constants.blog_list.no_results.affected_selectors);"no_results"===e?(n.addClass("tcb-permanently-hidden"),i.removeClass("tcb-permanently-hidden").trigger("click",{emulate:!0})):"blog_list"===e&&(i.addClass("tcb-permanently-hidden"),n.removeClass("tcb-permanently-hidden"),TVE.inner_$("#main.tcb-post-list").trigger("click",{emulate:!0})),t&&TVE.Components[e].editMode()},filterBlog:function(){TVE.Components.post_list.filterPosts()},after_init(){TVE.Views.Components.post_list.prototype.after_init.apply(this,arguments),TVE.CONST.dismissed_tooltips.includes("displayTypeBlogList")||(this.displayTypeTooltip=new TVE.Views.other.WarningTooltip({template:TVE.tpl("util/carousel-display-type-tooltip"),type:"displayTypeBlogList",className:"tcb-tooltip-container tcb-display-type-tooltip",identifier:`${TVE.identifier("blog_list")}${TVE.Models.CarouselManager.carouselSelector}`,control:this.controls.Type,afterApplyChange:()=>{this.controls.Type.setActive(this.potentialDisplayType,!0)}}),this.$el.find('[data-view="Type"] .tve-btn-group').append(this.displayTypeTooltip.$el))}})},5732:function(e){e.exports=TVE.Views.Base.component.extend({controls_init:function(e){e.CharactersTruncate.input=function(e,t){const i=e.find("span"),n=parseInt(t.value);this.applyElementCss({"max-width":n+"ch"},i),e.parent().mediaAttr("data-leaf-chars",t.value)},e.CharactersTruncate.update=function(e){const t=e.parent().mediaAttr("data-leaf-chars");this.setValue(parseInt(t))},e.EnableTruncateChars.input=function(t,i){const n=i.checked?e.CharactersTruncate.getValue()+"ch":"none";this.applyElementCss({"max-width":n+" !important"},t.find("span")),t.parent().attr("data-enable-truncate-chars",i.checked?1:0),e.CharactersTruncate.$el.toggleClass("tcb-hidden",!i.checked)},e.EnableTruncateChars.update=function(t){const i="1"===t.parent().attr("data-enable-truncate-chars");e.CharactersTruncate.$el.toggleClass("tcb-hidden",!i),this.setChecked(i)}}})},8276:function(e){const t=()=>TVE.main.EditMode.in_edit()&&TVE.main.EditMode.element().is(TVE.identifier("thrive_breadcrumbs"));e.exports=TVE.Views.Base.component.extend({controls_init:function(e){this.initializeSeparatorControls(e)},initializeSeparatorControls:function(e){function i(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"breadcrumbs_icon";return TVE.Components.breadcrumbs_separator.getBreadcrumbsElement(e).find(TVE.identifier(t))}e.SeparatorSize.update=function(e){const n=i(e);this.setValue(n.head_css("font-size",!1,"",!0,t()?this.model.css_prefix:""))},e.SeparatorSize.input=function(e,n){let s=`${n.value}${this.getUM()}`,o="";t()&&(s+="!important",o=this.config.css_prefix),this.applyElementCss({"font-size":s,width:s,height:s},i(e),this.config.css_suffix,o,!0),e.is(TVE.identifier("thrive_breadcrumbs"))&&(this.applyElementCss({"font-size":s},i(e,"breadcrumbs_path"),this.config.css_suffix,o,!0),this.applyElementCss({"font-size":s},i(e,"breadcrumbs_leaf"),this.config.css_suffix,o,!0))},e.SeparatorSize.change=function(e,n){const s=t()?i(e):TVE.ActiveElement;this.input(s,n),TVE.Editor_Page.reposition_icons()},e.SeparatorSize.onChange=function(e,t){const n=i(e);let s=parseInt(t.value);s=isNaN(s)?0:s,s>parseInt(this.model.config.max)&&(t.value=this.model.config.max),s<parseInt(this.model.config.min)&&(t.value=this.model.config.min),this.setValue(t.value+this.getUM()),TVE.SkipUpdate=!1,this.change(n,t)},e.SeparatorColor.update=function(e){const n=i(e);this.setValue(n.head_css("color",!1,"",!0,t()?this.config.css_prefix:""))},e.SeparatorColor.input=function(e){const n=this.applyTo(),s={color:e};let o="";t()&&(s.color+="!important",o=this.config.css_prefix),this.applyElementCss(s,i(n),this.config.css_suffix,o,!0),n.is(TVE.identifier("thrive_breadcrumbs"))&&(this.applyElementCss(s,i(n,"breadcrumbs_path"),this.config.css_suffix,o,!0),this.applyElementCss(s,i(n,"breadcrumbs_leaf"),this.config.css_suffix,o,!0))},e.IconPicker.setModal(TVE.IconsModal.get_instance(TVE.modal.get_element("icons"))),e.IconPicker.input=function(e,t){const i=t.defaultIcon&&t.defaultIcon.length>0,n=i?t.defaultIcon:"",s=TVE.Components.breadcrumbs_separator.getBreadcrumbsElement(e);let o,a;i&&(t.icon=TVE.$("symbol#"+n,"svg","editor")),t.icon.is("symbol")?(a=TVE.svg_icon({path:t.icon.html(),viewBox:t.icon[0].getAttribute("viewBox"),name:t.icon.find("> title").first().text(),id:t.icon.attr("id")}),o=t.icon.attr("id")||t.icon.find("> title").first().text()):(o=t.icon.data("filter"),a=`<span class="tve_sc_icon ${t.icon.data("filter")}" data-id="${t.icon.data("filter")}"></span>`),s.attr("data-icon-name",o).find(TVE.identifier("breadcrumbs_icon")).html(a),this.update(e)},e.IconPicker.update=function(t){const i=TVE.Components.breadcrumbs_separator.getBreadcrumbsElement(t).attr("data-icon-name");i&&i.length>0?(this.updateValue(i.replace("icon-","")),e.SeparatorColor.update(t),e.SeparatorSize.update(t)):this.updateValue("None")},e.CharacterInput.onInput=function(e,t){this.input(e,t)},e.CharacterInput.input=function(e,t){TVE.Components.breadcrumbs_separator.getBreadcrumbsElement(e).attr("data-separator",t.value).find(TVE.identifier("breadcrumbs_icon")).text(t.value)},e.CharacterInput.update=function(e){let t=TVE.Components.breadcrumbs_separator.getBreadcrumbsElement(e).attr("data-separator");t&&0!==t.length||(t=this.config.config.default),this.setValue(t)}},getBreadcrumbsElement:function(e){const t=TVE.identifier("thrive_breadcrumbs");return e.is(t)?e:e.closest(t)},after_update:function(){const e=this.getBreadcrumbsElement(TVE.ActiveElement).attr("data-separator-type");this.toggleSeparatorControls(e)},toggleSeparatorControls:function(e){this.$(".separator-type-controls").hide(),this.$(`.separator-type-controls[data-separator="${e}"]`).show(),this.$(".tcb-hide-if-no-separator").toggle("none"!==e)}})},6052:function(e){const t=e=>e.find(TVE.identifier("breadcrumbs_icon"));e.exports=TVE.Views.Base.component.extend({after_init:function(){this.categoriesTooltip=new TVE.Views.Controls.Tooltip({tooltipPosition:"top",no_buttons:!0,template:TVE.tpl("theme-main/breadcrumbs-categories"),anim_duration:300,no_callback:!0,validate:()=>!this.categoriesTooltip.FORCE_CLOSE})},controls_init:function(e){setTimeout((()=>{TVE.Components.breadcrumbs_separator.initializeSeparatorControls.call(this,e)}),1e3),e.SeparatorType.change=function(i,n){const s=n.dataset.value,o=t(i);switch(s){case"icon":TVE.Components.breadcrumbs_separator.controls.IconPicker.input(o,{defaultIcon:"icon-arrow-alt-right-light"});break;case"character":TVE.Components.breadcrumbs_separator.controls.CharacterInput.setValue(" / ",!0);break;case"none":o.text("")}TVE.head_css_remove(TVE.identifier("breadcrumbs_icon"),"_ALL",!0),i.attr("data-separator-type",s),TVE.Components.breadcrumbs_separator.toggleSeparatorControls.call(this.component,s),["ItemSpacing","SeparatorSize","SeparatorColor","IconPicker"].forEach((t=>{e[t].update(i)}))},e.SeparatorType.update=function(e){const t=e.attr("data-separator-type");this.setActive(t),TVE.Components.breadcrumbs_separator.toggleSeparatorControls.call(this.component,t)},e.ItemSpacing.update=function(e){this.setValue(t(e).head_css("margin-left",!1,"",!0))},e.ItemSpacing.input=function(e,i){this.applyElementCss({"margin-left":i.value+this.getUM(),"margin-right":i.value+this.getUM()},t(e))},e.Alignment.change=(e,t)=>{e.head_css({"justify-content":t.value+"!important"})},e.Alignment.update=function(e){const t=e.head_css("justify-content")||"flex-start";this.setValue(t)},void 0!==e.ShowCategoriesInPath&&(e.ShowCategoriesInPath.update=function(e){this.setChecked("show"===e.attr("data-show-categories"))},e.ShowCategoriesInPath.input=function(e,t){e.find(".thrive-breadcrumb-category").toggleClass("thrive-hidden-element",!t.checked),e.attr("data-show-categories",t.checked?"show":"hide")}),Object.keys(TVE.CONST.theme.breadcrumbs_labels).filter((t=>e[`${t}Label`])).forEach((t=>{e[`${t}Label`].update=function(e){this.setValue(TVE.CONST.theme.breadcrumbs_labels[t])},e[`${t}Label`].onInput=(e,i)=>{TVE.CONST.theme.breadcrumbs_labels[t]=i.value;const n=this.getBreadcrumbLabelElement(t,e);n.length&&n.find("span").html(i.value)},e[`${t}Label`].change=this.saveBreadcrumbsLabels}))},saveBreadcrumbsLabels:()=>{TVE.$.ajax({url:`${TVE.CONST.theme.routes.skins}/meta`,type:"POST",data:{id:TVE.CONST.theme.skin_id,key:"breadcrumbs_labels",value:TVE.CONST.theme.breadcrumbs_labels},headers:{"X-WP-Nonce":TVE.CONST.rest_nonce}})},getBreadcrumbLabelElement(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:TVE.ActiveElement,i=[];const n=TVE.Theme.template.isBlog();return"home"===e||"blog"===e&&!n?i=t.find(`.${e}-label`):"blog"===e&&n||"search"===e&&TVE.Theme.template.isSearch()||"author"===e&&TVE.Theme.template.isAuthor()||"archive"===e&&TVE.Theme.template.isArchive()&&""===TVE.Theme.template.secondary()?i=t.find(".archive-label"):"shop"===e&&TVE.Theme.template.isWoo()&&(i=t.find(".shop-label")),i},editBreadcrumbsElements:function(){const e=TVE.ActiveElement;TVE.main.EditMode.enter(e,{blur:!0,show_default_message:!0,restore_state:!0,element_selectable:!1,callbacks:{exit:()=>{TVE.Editor_Page.focus_element(e)}}})},openTooltip:function(){return this.categoriesTooltip.isOpen()?this.categoriesTooltip.onCancel():this.categoriesTooltip.open(null,this.$(".tve-switch-info")),!1}})},5914:function(e,t,i){e.exports=TVE.Views.Base.component.extend({before_update:function(){return this.cartTemplate=new(i(4882)(TVE.inner_$,TVE.inner.window))(TVE.ActiveElement),this},editTemplate(){const e=TVE.ActiveElement;e.find("[draggable]").removeAttr("draggable"),e.find(".tve-draggable").removeClass("tve-draggable"),e.find(".tve-droppable").removeClass("tve-droppable"),TVE.inner_$(".woocommerce-input-wrapper").off("click"),TVE.main.EditMode.enter(e,{show_default_message:!0,restore_state:!0,callbacks:{exit:()=>{TVE.Editor_Page.focus_element(e)}}})}})},1810:function(e,t,i){const n=new Backbone.Collection({});e.exports=TVE.Views.Base.component.extend({controls_init:function(e){const t=TVE.inner_$("<div class = 'woocommerce-form-coupon' style='display: none'><button></button></div>"),i=TVE.inner_$("<div class = 'woocommerce-form-login' style='display: none'><button></button></div>");TVE.inner_$(".checkout-template-wrapper").prepend(i).prepend(t),TVE.add_action("tcb.write_css.wc-additional-section",((e,t,i)=>{e.includes(".woocommerce-info")&&Object.keys(t).some((e=>(e=>["family"].some((t=>e.includes(t))))(e)))&&(TVE.write_css(e.replace(TVE.identifier("wc-additional-section"),".woocommerce-form-coupon button"),t,i),TVE.write_css(e.replace(TVE.identifier("wc-additional-section"),".woocommerce-form-login button"),t,i))})),TVE.add_action("tcb-ready",(()=>{const e=TVE.inner_$(".woocommerce-additional-fields");e.find("#order_comments_field").hasClass("hidden-billing-field")&&e.addClass("hidden-billing-field")})),e.CheckoutFields._sortable=!0,e.CheckoutFields.attach_collection(n),e.CheckoutFields.on("toggle_item",_.bind(this.toggleField,this)).on("order_changed",_.bind(this.orderChanged,this)),e.CheckoutFields.update=()=>{const e=[],t=TVE.CONST.woo.checkout_fields;Object.keys(t).forEach((i=>{const n=t[i];e.push({item:TVE.inner_$(`#${n.id}_field`),preventOrderChange:!n.sortable,label:n.label,fieldKey:n.id,toggleControl:n.toggleable,visible:n.visible,preventDelete:!0})})),n.reset(e)}},before_update:function(){return this.checkoutTemplate=new(i(5422)(TVE.inner_$,TVE.inner.window))(TVE.ActiveElement),this},editTemplate(){const e=TVE.ActiveElement;e.find("[draggable]").removeAttr("draggable"),e.find(".tve-draggable").removeClass("tve-draggable"),e.find(".tve-droppable").removeClass("tve-droppable"),TVE.inner_$(".woocommerce-input-wrapper").off("click"),TVE.main.EditMode.enter(e,{show_default_message:!0,restore_state:!0,callbacks:{exit:()=>{TVE.Editor_Page.focus_element(e)}}})},toggleField:function(e){const t=!e.get("visible"),i=TVE.CONST.woo.checkout_fields,n=e.get("fieldKey");let s=e.get("item");e.set("visible",t),"order_comments"===n&&s.closest(".woocommerce-additional-fields").toggleClass("hidden-billing-field",!t),s.toggleClass("hidden-billing-field",!t),i.find((e=>e.id===n)).visible=t},orderChanged:function(e,t){const i=n.at(t);let s=i.get("item");if(t>1&&t<n.length){const e=n.at(t-1).get("item");s=s.detach(),e.after(s),n.forEach(((e,t)=>{TVE.CONST.woo.checkout_fields.find((t=>t.id===e.get("fieldKey"))).priority=10*(t+1)}))}else n.remove(i,{silent:!0}),n.add(i,{at:e,silent:!0}).trigger("change")},getCheckoutFields:()=>TVE.Views.Controls.PreviewList})},5875:function(e){jQuery,e.exports=TVE.Views.Base.component.extend({controls_init:function(e){e.PlaceholderInput.input=function(e,t){e.is("textarea")||e.find("textarea").length>0?e=TVE.main.EditMode.element().find("textarea"):e.is("input")||(e=e.find("input")),e.attr("placeholder",t.value)},e.PlaceholderInput.update=function(e){(e=e.filter(".edit_mode")).is("textarea, input")||(e=e.find("textarea, input")),this.setValue(e.attr("placeholder")||"")},e.TextareaHeight.input=function(e,t){this.prepareValue(t.value,this.getUM()),this.applyElementCss({"min-height":t.value+this.getUM()})},e.TextareaHeight.update=function(e){let t=parseInt(e.head_css("min-height",!1,"",!0));t||(t=e.outerHeight()),this.setValue(t)},e.TextareaHeight.before_update=function(t){e.TextareaHeight.$el.toggleClass("control-hide",t.is(TVE.identifier("comment-form-input")))}}})},5407:function(e){e.exports=TVE.Views.Base.component.extend({controls_init:function(e){e.Label.input=function(e,t){e.html(t.value+(this.isRequired?' <span class="required">*</span>':""))},e.Label.update=function(e){this.isRequired=!!e.find(".required").length;const t=e.filter(".edit_mode");t.find("small").remove(),this.setValue(t.html().replace('<span class="required">*</span>',"").trim())}}})},5365:function(e,t,i){(t=>{const n=new Backbone.Collection({}),s=i(4445);e.exports=TVE.Views.Base.component.extend({controls_init:function(e){this.editFormItem=new s({component:this}),this.controls.FieldsControl.attach_collection(n),this.controls.FieldsControl.update=function(e){const i=e.filter(".edit_mode").find(".comment-form-text, .comment-form-item, .comment-form-cookies-consent"),s=[];_.each(i,(function(e,i){const n=t(e);s.push({item:n,label:n.find("textarea").length?n.find("textarea").attr("placeholder"):n.find("label").text().replace("*","").trim()})})),n.reset(s)},this.controls.FieldsControl.on("item_click",((e,t)=>{if(this.editFormItem.isOpen())this.editFormItem.onCancel();else{const i=e.get("item"),n=void 0!==i.find("input, textarea").attr("placeholder"),s=i.find("label").length>0,o=new TVE.BaseModel({isRequired:void 0!==i.find("input, textarea").attr("required"),hasPlaceholder:n,placeholder:n?i.find("input, textarea").attr("placeholder"):"",hasLabel:s,label:s?i.find("label").html().replace('<span class="required">*</span>',"").trim():""});this.listenTo(o,"change",(e=>{let t=i.find("input, textarea");i.find("textarea").length>0&&(t=TVE.main.EditMode.element().find("textarea")),t.attr("placeholder",e.get("placeholder")),e.get("hasLabel")&&i.find("label").html(e.get("label")+(e.get("isRequired")?' <span class="required">*</span>':""))})),o.saveState(),this.editFormItem.reset(o),this.editFormItem.open(null,t)}return!1})),this.controls.AddRemoveLabels.update=function(e){const t="none"!==e.head_css("display",!1," .theme-c-form-field-label"),i=!!e.find(".theme-c-form-field-label").length;this.component.$(".control-add-remove-label-hr")[i?"show":"hide"](),this.setChecked(t),this.toggle(i,!0)},this.controls.AddRemoveLabels.change=function(e,t){e.head_css({display:t.checked?"":"none !important"},!1," .theme-c-form-field-label")}},getFieldsControl:function(){return TVE.Views.Controls.PreviewList}})})(jQuery)},1388:function(e){e.exports=TVE.Views.Base.component.extend({after_init:function(){this.hooks()},controls_init:function(e){e.ReplySpacing.input=function(e,t){this.applyElementCss({"margin-left":t.value+this.getUM()})},e.ReplySpacing.update=function(e){this.setValue(e.head_css("margin-left","","",!1))}},isCommentsButton:e=>[TVE.Theme.constants.COMMENT_SUBMIT_TYPE,TVE.Theme.constants.COMMENT_REPLY_TYPE].includes(TVE._type(e)),hooks:function(){TVE.add_action("tcb.froala.blur",((e,t)=>{const i=TVE.ActiveElement;void 0!==i&&i.is(TVE.TEXT_ALL)&&i.closest(TVE.identifier("thrive_comments")).length>0&&this.syncCommentsText(i,t.$el)})),TVE.add_action("icon_element_changed",(e=>{const t=e.closest(".theme-button");t.length>0&&this.isCommentsButton(t)&&TVE.Components.theme_button.getSyncedElements(t).find(TVE.identifier("icon")).html(e.html())})),TVE.add_action("theme.selectors.init",(e=>{e.find(".comment-content").attr("data-selector",".comment-content p")})),TVE.add_filter("tcb.button.default_icon",(e=>{const t=TVE.ActiveElement;return this.isCommentsButton(t)&&(e=TVE.tpl("theme-main/icons/comment-submit"),setTimeout((()=>{TVE.Theme.content.init_selectors(TVE.ActiveElement.parent())}),100)),e})),TVE.add_filter("theme.save_shortcodes",(e=>{const t=e.find("#comments");if(TVE.Theme.template.isSingular()&&t.length){let e="";t.attr("data-ct")&&(e=` ct="${t.attr("data-ct")}"`),t.attr("data-ct-name")&&(e+=` ct-name="${t.attr("data-ct-name")}"`),t.replaceWith(`[thrive_comments${e}]`)}return e})),TVE.add_filter("tcb.cloud_templates.element_name",((e,t)=>("thrive_comments"===t&&(e="Comments Section"),e)))},updateCommentsBtnTexts:function(e,t){e.find(".fr-element").length>0?e.find(".fr-element").html(t):e.html(t)},syncCommentsText:function(e,t){const i=e.closest(".theme-button");if(i.length){const e=t.text(),n=TVE.Components.theme_button.getSyncedElements(i);t.closest(".tcb-secondary-text").length>0?_.each(n.find(".tcb-secondary-text"),(t=>{this.updateCommentsBtnTexts(TVE.inner_$(t),e)})):t.closest(".tcb-button-text").length>0&&_.each(n.find(".tcb-button-text"),(t=>{this.updateCommentsBtnTexts(TVE.inner_$(t),e)}))}}})},6483:function(e,t,i){TVE.CommentsErrorMessages=i(8766),e.exports=TVE.Views.Base.component.extend({after_init:function(){TVE.add_action("tcb.froala.blur",((e,t)=>{[".comment-form-reply-title-wrapper",'button[type="submit"]'].forEach((e=>{if(t.$oel.closest("#comments").length>0&&t.$oel.is(e)){const i=t.html.get(),n=t.$oel.closest("#comments").find(e).filter(":hidden");TVE.froala.disable(n),n.html(i)}}))})),TVE.add_action("tcb.submit_element_icon.input",(e=>{e.is(".comment-form-submit")&&(e.find(".thrv_icon").attr("data-selector",".comment-form-submit .thrv_icon"),e.closest("#comments").find(".comment-form-submit").filter(":hidden").prepend(e.find(".thrv_icon")[0].outerHTML))})),TVE.add_action("tcb.submit_element_icon.remove",(()=>{TVE.ActiveElement&&TVE.ActiveElement.is(".comment-form-submit")&&TVE.ActiveElement.closest("#comments").find(".comment-form-submit .thrv_icon").remove()})),TVE.add_filter("tcb.cloud_templates.apply_callback",(e=>(TVE.ActiveElement&&TVE.ActiveElement.length&&TVE.ActiveElement.is("#comments")&&(this.removeCommentsSelectorRules(),e=this.applyCommentsCloudTemplate),e)))},removeCommentsSelectorRules:function(){const e=TVE.main.all_media(),t=new RegExp(".comment-form|.comment-respond|#comments|theme-comments|.comment-reply|.comment-author|.comment-metadata|.comment-content|.reply","g");for(let i,n=0;i=e[n++];)TVE.CSS_Rule_Cache.removeRuleByMatchingSelector(i,t)},applyCommentsCloudTemplate:function(e){const t=TVE.ActiveElement,i={};let n;TVE.ElementSnapshot((function(){const t=TVE.inner_$(e.content);this.applyTo.find(".comment-respond.visitor").html(t.find(".comment-respond.visitor").html()),this.applyTo.find(".comment-respond.no-comments").html(t.find(".comment-respond.no-comments").html()),this.applyTo.find(".comment-respond.logged").html(t.find(".comment-respond.logged").html()),this.applyTo=t.is(".thrv_wrapper")?t:t.find("> .thrv_wrapper").first(),t.find("[data-css]").each((function(){this.dataset.css&&(void 0===i[this.dataset.css]?i[this.dataset.css]=TVE.CSS_Rule_Cache.uniq_id(this,!0):this.dataset.css=i[this.dataset.css])})),TVE.drag.bind_element(this.applyTo),TVE.Editor_Page.reposition_icons()}),this.applyTo,this),n=e.head_css,TVE.inner_$.each(i,(function(e,t){n=n.replace(new RegExp("("+e+")","g"),t)})),TVE.Theme.utils.inline_shortcodes_init(t),t.attr({"data-ct-name":e.name,"data-ct":`${e.type}-${e.id}`}),TVE.Editor_Page.content_manager.insert_head_css(n).done((()=>{TVE.Editor_Page.blur(),TVE.Editor_Page.focus_element(t)}))},afterEnterEditMode:function(e){TVE.Editor_Page.focus_element(e.find(".state:visible")),e.find("input").attr("readonly","readonly"),TVE.main.$(".add-element").addClass("tve-disabled")},dragEnterBubble:function(e,t){return 0===TVE.inner_$(t.target).closest(".comment-respond.no-comments").length&&(e=!1),e},editSectionElements:function(){const e=TVE.ActiveElement;TVE.add_action("tcb.edit_mode.enter",this.afterEnterEditMode),TVE.add_filter("tcb.dragenter.bubble",this.dragEnterBubble),TVE.add_filter("tcb.get_dropzone_target",this.getDropzoneTarget),TVE.main.EditMode.enter(!1,{show_default_message:!0,element_selectable:!1,can_insert_elements:!0,states:TVE.Theme.constants.comments.states,hidden_elements:TVE.Theme.constants.comments.hiddenElements,callbacks:{exit:()=>{e.find(".state").hide(),e.find(".state.logged").show(),TVE.remove_action("tcb.edit_mode.enter",this.afterEnterEditMode),TVE.remove_filter("tcb.dragenter.bubble",this.dragEnterBubble),TVE.remove_filter("tcb.get_dropzone_target",this.getDropzoneTarget),e.find("input").removeAttr("readonly"),TVE.main.$(".add-element").removeClass("tve-disabled"),TVE.Editor_Page.focus_element(e)},state_change:t=>{const i=e.find(`.state.${t}`);e.find(".state").hide(),TVE.main.$(".add-element").toggleClass("tve-disabled","closed"!==t),i.show(),TVE.Editor_Page.focus_element(i),TVE.main.EditMode.refresh()}}})},getDropzoneTarget:function(e){return void 0!==TVE.FLAGS.$dragged_element||TVE.main.EditMode.in_edit()&&TVE.main.EditMode.element()&&TVE.main.EditMode.element().is("div#comments")&&(e=TVE.main.EditMode.element().find(".no-comments").children().last()),e},manageErrorMsg:function(){const e=new Backbone.Model(JSON.parse(TVE.ActiveElement.find(".thrive-theme-comments-error-msg").html())),t=new TVE.CommentsErrorMessages({el:TVE.modal.get_element("cf-error-messages"),model:e});t.render_errors(),t.before_save=function(){const e=[];this.invalid_inputs=e,this.is_valid=function(t){let i=!0;for(const n in t.attributes)t.get(n).length<=0&&(e.push(n),i=!1);return i}(this.model),this.is_valid&&TVE.ActiveElement.find(".thrive-theme-comments-error-msg").html(JSON.stringify(this.model.toJSON()))},t.open()}})},3394:function(e){(t=>{let i={};const n=TVE.Views.InlinePanel.extend({template:TVE.tpl("inline/content-templates"),after_initialize:function(){TVE.Views.InlinePanel.prototype.after_initialize.call(this),this.$(".drop-panel").addClass("small-pad tcb-autocomplete"),this.autocomplete()},autocomplete:function(){const e=_.map(TVE.CONST.theme.dynamic_list_types,(e=>({id:e.value,label:e.name,title:e.name})));this.$input=this.$(".tcb-search").autocomplete({minLength:0,appendTo:this.$(".popup-content"),source:function(t,i){i(TVE.inner_$.ui.autocomplete.filter(e,t.term).slice(0,10))},select:(e,t)=>(this.on_select(t.item.id,t.item.value),e.stopPropagation(),!1)}),this.$input.data("ui-autocomplete")._renderItem=function(e,i){const n=new RegExp(this.term,"i");return e.addClass("tcb-suggest"),t("<li></li>").data("item.autocomplete",i).append('<a href="#" class="tcb-truncate">'+i.label.replace(n,'<span class="highlight">'+this.term+"</span>")+"</a>").appendTo(e)}},onOpen:function(){this.$input.val("").focus().autocomplete("search")}});e.exports=TVE.Views.Base.component.extend({controls_init:function(e){this.listSelector=new n({component:this,minWidth:300,no_buttons:!0,on_select:(e,t)=>{TVE.ActiveElement.attr("data-type",e),TVE.ActiveElement.attr("data-query",TVE.PostList.utils.stringifyAndReplace({filter:"custom",post_type:e,posts_per_page:5,offset:1})),this.fetch_list(TVE.ActiveElement)}}),e.Limit.input=(e,t)=>{const i=TVE.PostList.utils.readQueryFromElement(e[0]);i.posts_per_page=t.value,e.attr("data-query",TVE.PostList.utils.stringifyAndReplace(i)),this.fetch_list(e)},e.Limit.update=function(e){const t=TVE.PostList.utils.readQueryFromElement(e[0]),i=t&&t.posts_per_page?t.posts_per_page:5;this.setValue(i),this.toggle("meta_list"!==e.attr("data-type"))},e.ListLayout.change=function(t,i){const n=i.dataset.value;let s=parseInt(e.ListSpacing.getValue(!1));t.attr("data-layout",n),t.toggleClass("dynamic-inline-list","horizontal"===n),"horizontal"===n&&s<10&&(s=10),e.ListSpacing.setValue(s,!0)},e.ListLayout.update=function(e){this.setActive("horizontal"===e.attr("data-layout")?"horizontal":"vertical")},e.EnableIcons.change=function(i,n){const s=TVE.tpl("theme-main/icons/dynamic"),o=i.find(".thrive-dynamic-styled-list-item");o.toggleClass("dynamic-item-with-icon",n.checked),e.ModalPicker.toggle(n.checked),!0===n.checked&&o.each(((e,i)=>{const n=t(i);0===n.find(".dynamic-list-icon").length&&n.find(".tcb-styled-list-icon").append(s)})),this.component.elementDataIcon(o,"check")},e.EnableIcons.update=function(t){const i=t.attr("data-icon").length;this.setChecked(i),e.ModalPicker[i?"show":"hide"]()},e.ModalPicker.setModal(TVE.IconsModal.get_instance(TVE.modal.get_element("icons"))),e.ModalPicker.input=(t,i)=>{let n,s;i.icon.is("symbol")?(s=i.icon.attr("id")||i.icon.find("> title").first().text(),n=TVE.svg_icon({path:i.icon.html(),viewBox:i.icon[0].getAttribute("viewBox"),name:i.icon.find("> title").first().text(),id:i.icon.attr("id")})):(n=`<span class="tve_sc_icon ${i.icon.data("filter")}" data-id="${i.icon.data("filter")}"></span>`,s=i.icon.data("filter")),t.attr("data-icon",s).find(".thrv_icon").html(n),e.ModalPicker.update(t)},e.ModalPicker.update=function(e){const t=e.attr("data-icon"),i=t?t.replace("icon-",""):"angle-right-light";this.updateValue(i)},e.ListSpacing.input=function(e,t){const i=t.value+this.getUM()+" !important",n=e.hasClass("dynamic-inline-list")?{"padding-right":i}:{"padding-bottom":i};this.applyElementCss(n,e,this.config.css_suffix,this.config.css_prefix)},e.ListSpacing.update=function(e){const t=e.hasClass("dynamic-inline-list")?"right":"bottom",i=e.head_css(`padding-${t}`,null,!1,!0,this.config.css_prefix);this.setValue(i||0)}},placeholder_action:function(e){this.listSelector.open(e,e.find(".tcb-inline-placeholder-action"))},elementDataIcon:function(e,t){e.hasClass("dynamic-item-with-icon")||(t=""),e.closest(".thrive-dynamic-list").attr("data-icon",t)},fetch_list:_.debounce((function(e){const i=TVE.PostList.utils.readQueryFromElement(e[0]),n=e.find(".thrv_icon"),s=n.length?n[0].innerHTML:"",o={css:e.attr("data-css"),icon:e.attr("data-icon"),shortcode:e.attr("data-shortcode"),query:i||{posts_per_page:e.attr("data-limit"),post_type:e.attr("data-type")}};e.addClass("tcb-el-loading"),TVE.Theme.utils.fetch_list(o,(i=>{e.html(t(i.content).html()).removeClass("tcb-elem-placeholder"),n.length&&e.find(".thrv_icon").html(s),e.removeClass("tcb-el-loading"),this.listSelector.hide(e,{}),TVE.Editor_Page.focus_element(e)}))}),300),editListElements:function(){const e=TVE.ActiveElement;TVE.main.EditMode.enter(e,{blur:!0,show_default_message:!0,restore_state:!0,element_selectable:!1,callbacks:{exit:()=>{TVE.Editor_Page.focus_element(e)}}})},filterList:function(){const e=TVE.Components.post_list.q_modal;i=this.prepareListTypes(),e.open({contentTypeSelect:{items:i,extra:{isMultiple:!1,on_select:this.setContentOnSelect.bind(e)}},taxonomiesSelect:{list:i}}),e.toggleOrderBy();const t=e.$element.attr("data-type"),n=e.$(".query-rule").length;n||(e.newRule(),e.taxonomiesSelect.on_select(t)),"post"===t&&n<2&&(e.showTaxonomies(t,!0),e.newRule()),e.$(".tth-items-to-display").html("Lists to Display"),e.save=this.save.bind(e)},setContentOnSelect:function(e){const t=i[e].plural_label;this.$('.query-arg[data-arg="post_type"]').val(e),this.$(".query-post-type-select .tth-elem-selected").text(t),this.$(".no-label").html(t),this.$element.attr("data-type",e),this.updateSelectedPostTypes(e,!1),this.queryRulesCollection.models.forEach((t=>{t.set("taxonomy",e)})),this.maybeRefreshTermsSelect(),"post"===e?(this.showTaxonomies(e,!0),this.newRule()):(this.queryRulesCollection.length>1&&this.queryRulesCollection.at(this.queryRulesCollection.length-1).destroy(),this.toggleNewRules(!1)),this.toggleOrderBy()},save:function(){const e=this.getQueryFromModal(),i=JSON.parse(JSON.stringify(e));i.type=Array.isArray(i.post_type)?i.post_type[0]:i.post_type,delete i.queried_object,delete i.related,delete i.sticky,delete i.exclude_current_post,this.$modalContent.addClass("loading"),TVE.Theme.utils.fetch_list({query:i},(e=>{const n=TVE.ActiveElement.find(".thrv_icon"),s=n.length?n[0].innerHTML:"";TVE.ActiveElement.html(t(e.content).html()).attr("data-query",TVE.PostList.utils.stringifyAndReplace(i)),n.length&&TVE.ActiveElement.find(".thrv_icon").html(s),this.$modalContent.removeClass("loading"),this.close(),TVE.Editor_Page.focus_element(TVE.ActiveElement)}))},isDynamicList:function(e){return"thrive_dynamic_list"===e},prepareListTypes:function(){const e={};return _.each(TVE.CONST.theme.dynamic_list_types,(t=>{e[t.value]={label:t.label,plural_label:t.plural_label}})),e}})})(jQuery)},6909:function(e,t,i){i(3724),e.exports=TVE.Views.Base.component.extend({after_init:function(){TVE.main.on("device_change",(e=>{let{device:t}=e;this.controls.Wrap.toggle("mobile"!==t)}))},controls_init:e=>{const t=_.throttle(TVE.PostList.layout.masonryRedo,500),i=()=>TVE.Theme.$sections.sidebar&&TVE.Theme.$sections.sidebar.hasClass(TVE.Theme.constants.identifiers.HIDE_SECTION_CLASS);e.Position.change=function(e,t){TVE.Components.theme_section.controls.Position.change.apply(this,arguments)},e.Position.update=function(){TVE.Components.theme_section.controls.Position.update.apply(this)},e.Wrap.update=function(e){const t="wrap"===e.css("flex-wrap");this.setChecked(t),e.attr("data-wrap",t?1:0),this.$el.toggleClass("tcb-disabled",i())},e.Wrap.input=(e,t)=>{TVE.Theme.FLAGS.LAYOUT_CSS_WRITE=!0,e.head_css({"flex-wrap":t.checked?"wrap":""}),e.head_css({width:t.checked?"100%":""},!1,` div${TVE.Theme.constants.identifiers.MAIN_COLUMNS_SEPARATOR}`),TVE.Theme.FLAGS.LAYOUT_CSS_WRITE=!1,e.attr("data-wrap",t.checked?1:0)},e.Gutter.input=function(e,i){TVE.Theme.$main.tcbCss("--separator-size",i.value+this.getUM()),t()},e.Gutter.change=function(e,t){TVE.Theme.FLAGS.LAYOUT_CSS_WRITE=!0,TVE.Theme.$main.head_css({"--separator-size":t.value+this.getUM()}),TVE.Theme.FLAGS.LAYOUT_CSS_WRITE=!1,TVE.Theme.$main.tcbCss("--separator-size",""),TVE.Theme.content.updateResizeHandlersPosition(t.value)},e.Gutter.update=function(t){this.setValue(t.find(TVE.Theme.constants.identifiers.MAIN_COLUMNS_SEPARATOR).css(e.Wrap.getValue()?"height":"width")),this.$el.toggleClass("tcb-disabled",i())},e.SidebarVisibility.update=function(){this.setChecked(!i())},e.SidebarVisibility.change=function(t,i){TVE.Theme.$sections.sidebar.toggleClass(TVE.Theme.constants.identifiers.HIDE_SECTION_CLASS,!i.checked),e.PageMap.update(TVE.Theme.$sections.sidebar),TVE.Theme.content.updateResizeHandlersPosition(),TVE.PostList.layout.masonryRedo(),e.Position.update(TVE.Theme.$sections.sidebar),e.Gutter.update(TVE.Theme.$main),e.Wrap.update(TVE.Theme.$main)}}})},5221:function(e){jQuery,e.exports=TVE.Views.Components.ContentBox.extend({controls_init:function(e){TVE.Views.Components.ContentBox.prototype.controls_init.call(this,e),TVE.add_filter("tcb.elem.type",((e,t)=>("contentbox"===e&&t.is(TVE.Theme.constants.blog_list.no_results.selector)&&(e=TVE.Theme.constants.blog_list.no_results.type),e)))},getDropzoneTarget:function(e){return void 0!==TVE.FLAGS.$dragged_element||TVE.main.EditMode.in_edit()&&TVE.main.EditMode.element()&&TVE.main.EditMode.element().is(TVE.Theme.constants.blog_list.no_results.selector)&&(e=TVE.main.EditMode.element().find(".tve-cb:first").children().last()),e},editMode:function(){TVE.add_filter("tcb.get_dropzone_target",this.getDropzoneTarget),TVE.main.EditMode.enter(!1,{show_default_message:!0,element_selectable:!0,can_insert_elements:!0,states:_.clone(TVE.Theme.constants.blog_list.states).reverse(),callbacks:{before_exit:TVE.Views.Controls.DropPanel.close_all,state_change:TVE.Components.blog_list.stateChange,exit:()=>setTimeout((()=>{TVE.remove_filter("tcb.get_dropzone_target",this.getDropzoneTarget),TVE.Components.blog_list.stateChange("blog_list",!1)}))}})}})},7858:function(e){const t=["tcb_post_prev_link","tcb_post_next_link","thrive_prev_column","thrive_next_column","thrive_previous_title_inline_shortcode","thrive_next_title_inline_shortcode"];e.exports=TVE.Views.Base.component.extend({controls_init:function(e){const i=(e,i,n)=>{if(t.includes(n)){const t=i.closest(TVE.identifier("thrive_prev_next"));t.length>0&&(e+=" same-category="+(1===parseInt(t.attr("data-same-category"))?1:0))}return e};TVE.add_filter("tcb.dynamic_link.attributes",i),TVE.add_filter("tcb.inline_shortcode.extra_attributes",i),TVE.add_filter("ttb.wrapper_shortcode.attributes",i),e.BoxWidth.update=function(e){const t=e.head_css("max-width",null,null,!0);this.model.config.max=parseInt(e.parent().width()),this.setValue(t)},e.BoxWidth.input=function(e,t){this.prepareValue(t.value,this.getUM()),this.applyElementCss({"max-width":t.value+this.getUM()},e,"","")},e.Align.update=function(e){let t;"100%"===e.css("min-width")?t="full":(TVE.Components.layout.controls.Alignment.update(),t=TVE.Components.layout.controls.Alignment.getValue()),this.setActive(t),this.component.controls.BoxWidth.$el.toggleClass("tcb-hidden","full"===t)},e.Align.input=function(e,t){const i="full"===t.dataset.value;this.component.alignFull(e,i),TVE.Components.layout.controls.Alignment.$('[data-value="'+(i?"none":t.dataset.value)+'"]').click()},e.Size.update=function(e){const t=e.find(".tcb-button-texts");let i=t.head_css("--tve-font-size")||t.head_css("font-size",!1," input",!0,this.config.css_prefix);TVE.isCssVariable(i)&&(i=TVE.getCssVariableValue(i)),this.setValue(i)},e.Size.input=function(e,t){const i=t.value+this.getUM();this.applyElementCss({"font-size":[`var(--tve-font-size,${i})`]},e.find(".tcb-button-texts")," span"),this.applyElementCss({"--tve-font-size":i},e.find(".tcb-button-texts"),"",""),this.applyElementCss({"font-size":[`var(--tve-font-size,${i})`]},e.find(".tcb-button-icon")," span"),this.applyElementCss({"--tve-font-size":i},e.find(".tcb-button-icon"),"","")},e.NewTab.change=function(e,t){const i=t.checked?"_blank":"_self";e.find(".thrv-prev-next-button").each(((e,t)=>{TVE.inner_$(t).find("a").attr("target",i)}))},e.NewTab.update=function(e){let t="";e.find(".thrv-prev-next-button").each(((e,i)=>{t=TVE.inner_$(i).find("a").attr("target")})),this.setValue("_blank"===t)},e.SameCategory.change=function(e,t){e.attr("data-same-category",t.checked?1:0)},e.SameCategory.update=function(e){this.setValue(1===parseInt(e.attr("data-same-category")))},TVE.add_filter("tcb.get_dropzone_target",(e=>(void 0===TVE.FLAGS.$dragged_element&&TVE.main.EditMode.in_edit()&&TVE.main.EditMode.element()&&TVE.main.EditMode.element().is(TVE.identifier("thrive_prev_next"))&&(e=TVE.main.EditMode.element().find(".thrive-prev-next-container").children().last()),e))),TVE.add_action("tcb.edit_mode.exit",(function(e){e.is(TVE.identifier("thrive_prev_next"))&&e.removeClass("canvas-mode")})),TVE.add_filter("element_drop",(e=>(e&&e.hasClass("thrive_prev_next")&&TVE.Components.button.controls.ButtonPalettes&&e.find(TVE.identifier("button")).each(((e,t)=>{const i=TVE.inner_$(t),n=TVE.Components.button.controls.ButtonPalettes.getDefaultPalette(i),s=TVE.buildCssVariable(`${TVE.CONST.colors.local_prefix}${n.id}, ${n.data.val}`);i.head_css({"background-image":` linear-gradient(${s}, ${s})`},TVE.main.responsive.desktop.media," .tcb-button-link",!1,"")})),e))),TVE.add_filter("tcb.cloud_templates.element_name",((e,t)=>("thrive_prev_next"===t&&(e="Thrive Previous/Next Element"),e)))},alignFull:function(e,t){let i="";i="desktop"===TVE.main.device||t?t?"100%!important":"":"0!important",e.head_css({"min-width":i}),this.controls.BoxWidth.$el.toggleClass("tcb-hidden",t),this.controls.BoxWidth.update(e),TVE.Editor_Page.reposition_icons()},editMode:function(){const e=["text","button","image","contentbox","icon"],t=[];_.each(TVE.Elements,((i,n)=>{e.includes(n)||t.push(i.tag)})),TVE.main.EditMode.enter(!1,{show_overlay:!0,show_default_message:!0,can_insert_elements:!0,element_selectable:!1,blur:!0,hidden_elements:t}),TVE.Components.thrive_prev_next.hide(),TVE.Components.cloud_templates.hide()},open_modal:function(){return TVE.modal_open("cloud-templates",{element:TVE.ActiveElement}),!1},placeholder_action:function(){this.open_modal()}})},9383:function(e,t,i){const n="--tve-woo-gallery-width";e.exports=TVE.Views.Base.component.extend({before_update:function(){const e=TVE.ActiveElement.closest(TVE.identifier("product-template"));return this.productTemplate=new(i(5168)(TVE.inner_$,TVE.inner.window))(e),this},controls_init:function(e){const t=this;e.DisplayMagnifier.input=(e,t)=>{this.productTemplate.setData("hide-magnifier",t.checked?0:1).toggleZoom().redoGallery(),e.find(".woocommerce-product-gallery__trigger").toggle(t.checked)},e.DisplayMagnifier.update=function(e){this.setChecked(!Number(t.productTemplate.getData("hide-magnifier")))},e.GalleryWidth.input=function(e,i){const s=i.value+this.getUM();t.productTemplate.$template.tcbCss(n,s),e.find(".woocommerce-product-gallery__image").css("width",s)},e.GalleryWidth.change=function(e,i){t.productTemplate.$template.tcbCss(n,""),t.productTemplate.$template.head_css({[n]:i.value+this.getUM()}),t.productTemplate.redoGallery()},e.GalleryWidth.update=function(e){this.setValue(parseInt(t.productTemplate.$gallery.css("width")))},e.Columns.input=(e,t)=>{this.productTemplate.setData("gallery-columns",t.value).updateGalleryColumnsClass(t.value)},e.Columns.update=function(e){this.setValue(t.productTemplate.getData("gallery-columns"))}}})},2459:function(e,t,i){const n={title:".product_title",price:".price",description:".woocommerce-product-details__short-description",button:".cart",meta:".product_meta",review:"#tab-title-reviews, #reviews, .woocommerce-product-rating"};e.exports=TVE.Views.Base.component.extend({before_update:function(){return this.productTemplate=new(i(5168)(TVE.inner_$,TVE.inner.window))(TVE.ActiveElement),this},after_init(){TVE.add_action("tcb.write_css.wc-product-add-to-cart",((e,t,i)=>{e.includes("a.button")&&TVE.write_css(e.replace("a.button","a.added_to_cart").replace(":hover",""),t,i)}))},controls_init:e=>{_.each(n,((t,i)=>{const n=`${TVE.ucFirst(i)}Visibility`;e[n].input=(e,n)=>{e.attr(`data-hide-${i}`,n.checked?0:1).find(t).toggle(n.checked)},e[n].update=function(e){const n=!Number(e.attr(`data-hide-${i}`));this.setChecked(n),e.find(t).toggle(n)}})),TVE.main.on("device_change",(e=>TVE.Components["product-template"].toggleProductComponents(e.device)))},toggleProductComponents:e=>{if(TVE.ActiveElement&&TVE.ActiveElement.is(TVE.identifier("product-template"))){const t={"related-products":TVE.Components["related-products"],"upsells-products":TVE.Components["upsells-products"]};TVE.toggleEnabledComponents(t,"desktop"===e,"This cannot be changed in responsive mode")}},editTemplate(){const e=this.productTemplate.$template;e.find("[draggable]").removeAttr("draggable"),e.find(".tve-draggable").removeClass("tve-draggable"),e.find(".tve-droppable").removeClass("tve-droppable"),TVE.main.EditMode.enter(e,{show_default_message:!0,restore_state:!0,states:this.getElementStates(),callbacks:{state_change:TVE.inner.window.ThriveTheme.Product.selectTab,exit:()=>{TVE.inner.window.ThriveTheme.Product.selectTab(),TVE.Editor_Page.focus_element(e)}}}),this.productTemplate.initializeProductViewCartButtons(e)},getElementStates(){const e=TVE.inner.window.ThriveTheme.Product.$template.find(".wc-tabs").children(":visible"),t=[];return e.length>1&&e.each(((e,i)=>{t.push({value:i.id.replace("tab-title-",""),label:`Tab - ${i.innerText.replace(/\(.*\)/,"").trim()}`})})),t}})},776:function(e,t,i){e.exports=e=>{let t;return i(8673),TVE.Views.Base.component.extend({before_update:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:TVE.ActiveElement;return this.productTemplate=new t(e),this},controls_init:function(n){const s=()=>this.productTemplate;n.Display.input=function(t,i){const n=i.checked;s().setData(`hide-${e}`,n?0:1),s().getProductsSection(e).toggle(n),this.component.$(`.${e}-products-controls`).toggle(n)},n.Display.update=function(t){const i=!Number(t.attr(`data-hide-${e}`));this.setChecked(i),s().getProductsSection(e).toggle(i),this.component.$(`.${e}-products-controls`).toggle(i)},t=i(5168)(TVE.inner_$,TVE.inner.window),TVE.WooCommerceFn.productsSectionUtils.initProductSectionControls(n,s,e)},after_update(){TVE.WooCommerceFn.productsSectionUtils.updateOrderLabels(this.controls)}})}},7315:function(e){e.exports=TVE.Views.Base.component.extend({controls_init:function(e){e.color.input=function(e){this.applyElementCss({color:`${e} !important`})},e.color.update=function(e){this.setValue(e.css("color"))},e.size.input=function(e,t){this.applyElementCss({"font-size":`${t.value}${this.getUM()} !important`})},e.size.update=function(e){this.setValue(e.css("font-size"))}}})},3491:function(e,t,i){let n;e.exports=TVE.Views.Components.Shop.extend({before_update:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:TVE.ActiveElement;return this.shopTemplate=new n(e),this},after_update:function(){TVE.WooCommerceFn.productsSectionUtils.updateOrderLabels(this.controls)},controls_init:function(e){const t=()=>this.shopTemplate;n=i(6990)(TVE.inner_$,TVE.inner.window),TVE.WooCommerceFn.productsSectionUtils.initVisibilityControls.call(this,e,n.productElementSelectors,t),TVE.WooCommerceFn.productsSectionUtils.initProductSectionControls(e,t)}})},8840:function(e,t,i){const n=()=>TVE.inner.window.ThriveTheme.sidebar,s=()=>"mobile"===TVE.main.device;let o;e.exports=TVE.Views.Base.component.extend({after_init(){TVE.add_action("theme.section.after_insert.sidebar",((e,t)=>{t.$element.attr("data-display-type",n().$element.attr("data-display-type")).attr("data-off-screen",n().$element.attr("data-off-screen")).attr("data-sticky",n().$element.attr("data-sticky")),TVE.inner.window.ThriveTheme.sidebar=i(9367)(TVE.inner_$,t.$element,TVE.inner.window.TCB_Front,TVE.inner.window,TVE.inner.document.body),this.sidebarSection=TVE.Theme.utils.getSectionInstance(TVE.ActiveElement),this.forceWhiteBackground()})),TVE.main.on("device_change",(e=>{let{device:t}=e;n().updateConfig().sidebarTypeInit(),TVE.ActiveElement&&TVE.ActiveElement.is(`${TVE.identifier("sidebar-trigger")},${TVE.identifier("sidebar-close-icon")}`)&&!n().isOffScreen(t)&&TVE.Editor_Page.selection_manager.select_element(TVE.Theme.$sections.sidebar.find(".section-content"))})),TVE.Theme.$sections.sidebar&&TVE.refreshIconsOnScroll(TVE.Theme.$sections.sidebar.find(".section-content"),"sidebar",(()=>TVE.inner.$body.hasClass("theme-has-off-screen-sidebar"))),this.initTooltip()},initTooltip(){o=new TVE.Views.Controls.Tooltip({tooltipPosition:"top",no_buttons:!0,closeOnLeave:!0,no_callback:!0,template:TVE.tpl("theme-main/off-screen-tooltip")}),o.$el.on("mouseenter.tooltip",(e=>e.currentTarget.classList.add("on-hover"))).on("mouseleave.tooltip",(e=>{e.currentTarget.classList.remove("on-hover"),o.onCancel()})),this.$(".tve-switch-info").addClass("mouseenter").attr("data-fn-mouseenter","toggleOverlayTooltip").addClass("mouseleave").attr("data-fn-mouseleave","toggleOverlayTooltip")},before_update(){this.$(".sticky-options").toggle(n().isSticky(TVE.main.device)&&!s()),this.$(".sticky-element-id").toggle("element"===n().getJsonData("sticky","stickyUntil")&&!s()),this.checkStickyUntilPosition(),this.backwardsCompatibility(),this.sidebarSection=TVE.Theme.utils.getSectionInstance(TVE.ActiveElement)},controls_init(e){const t=this;e.SidebarDisplay.change=(e,t)=>{const i=t.dataset.value,s=n()._get("off-screen");n().setJsonData("display-type",TVE.main.device,i),this.$("[data-sidebar-display]").hide().filter(`[data-sidebar-display="${i}"]`).show(),"off-screen"===i?(e.attr("data-off-screen")||n().setJsonData("off-screen",n().constructor.getDefaultValues("off-screen")),n().offScreenRefresh(),this.forceWhiteBackground()):s.destroy(),this.update(),TVE.Editor_Page.reposition_icons(),setTimeout(TVE.inner.window.TCB_Front.resizePageSection,500),TVE.PostList.layout.masonryRedo()},e.SidebarDisplay.update=function(){t.$("[data-sidebar-display]").hide();const e=n().isOffScreen()?"off-screen":"normal";t.$(`[data-sidebar-display="${e}"]`).show(),this.setValue(e)},e.OffscreenDisplay.change=(e,t)=>{n().setJsonData("off-screen","display",t.dataset.value,TVE.main.device).offScreenRefresh(!0),setTimeout(TVE.inner.window.TCB_Front.resizePageSection,500)},e.OffscreenDisplay.update=function(){this.setValue(n().getJsonData("off-screen","display",TVE.main.device)),this.$el.toggleClass("tcb-disabled",s())},e.OffscreenDefaultState.change=(e,t)=>{n().setJsonData("off-screen","visibleOnLoad","expanded"===t.dataset.value,TVE.main.device)},e.OffscreenDefaultState.update=function(){this.setValue(n().getJsonData("off-screen","visibleOnLoad",TVE.main.device)?"expanded":"collapsed"),this.$el.toggleClass("tcb-disabled",s())},e.ShowOffscreenInEditor.change=(e,t)=>{n().setJsonData("off-screen","visibleInEditor",t.checked);const i=n()._get("off-screen");t.checked?n().offScreenRefresh():i.toggle(!1),TVE.Editor_Page.reposition_icons()},e.ShowOffscreenInEditor.update=function(){this.setValue(n().getJsonData("off-screen","visibleInEditor"))},e.OffscreenOverlayColorSwitch.change=(t,i)=>{n().setJsonData("off-screen","hasOverlay",i.checked,TVE.main.device),e.OffscreenOverlayColor.$el.toggle(i.checked),e.ShowOffscreenInEditor.getValue()&&(t.toggleClass("theme-has-off-screen-overlay",i.checked),TVE.inner_$("body").toggleClass("theme-has-off-screen-overlay",i.checked),i.checked&&e.OffscreenOverlayColor.update(t))},e.OffscreenOverlayColorSwitch.update=function(t){let i=n().getJsonData("off-screen","hasOverlay",TVE.main.device);this.setValue(i),e.OffscreenOverlayColor.$el.toggle(i),i=i&&e.ShowOffscreenInEditor.getValue(),t.toggleClass("theme-has-off-screen-overlay",i),TVE.inner_$("body").toggleClass("theme-has-off-screen-overlay",i)},e.OffscreenOverlayColor.input=function(e){TVE.Theme.$wrapper.head_css({"--tve-off-screen-overlay-color":`${e}!important`})},e.OffscreenOverlayColor.update=function(){this.setValue(TVE.Theme.$wrapper.tcbCss("--tve-off-screen-overlay-color"))},e.OffscreenDefaultTrigger.change=(t,i)=>{n().setJsonData("off-screen","hasDefaultTrigger",i.checked,TVE.main.device),e.OffscreenTriggerPosition.$el.toggle(i.checked),n()._get("off-screen").$trigger.css({display:i.checked?"flex":"none"})},e.OffscreenDefaultTrigger.update=function(){const t=n().getJsonData("off-screen","hasDefaultTrigger",TVE.main.device);this.setValue(t),e.OffscreenTriggerPosition.$el.toggle(t)},e.OffscreenDefaultTrigger.openTooltip=function(){return o.isOpen()?o.onCancel():o.open(null,this.$(".tve-switch-info")),!1},e.OffscreenDefaultTrigger.toggleOverlayTooltip=(e,t,i)=>{o.onIconHover="mouseenter"===i.type,"mouseenter"===i.type?o.open(null,t):setTimeout((()=>{o.$el.hasClass("on-hover")||o.onIconHover||o.onCancel()}),1e3)},e.OffscreenTriggerPosition.change=(e,t)=>{n().setJsonData("off-screen","triggerPosition",t.value,TVE.main.device),e.attr("data-trigger-position",t.value)},e.OffscreenTriggerPosition.update=function(e){const t=n().getJsonData("off-screen","triggerPosition",TVE.main.device);this.setValue(t),e.attr("data-trigger-position",t)},e.OffscreenCloseIcon.change=(e,t)=>{n().setJsonData("off-screen","hasCloseIcon",t.checked,TVE.main.device),n()._get("off-screen").toggleCloseIcon(t.checked),t.checked||e.removeAttr("data-style-d")},e.OffscreenCloseIcon.update=function(){const e=!!n().getJsonData("off-screen","hasCloseIcon",TVE.main.device)&&n().isOffScreen();this.setValue(e),n()._get("off-screen").toggleCloseIcon(e)},e.Sticky.update=function(){this.setChecked("sticky"===n().getDisplayType(TVE.main.device)),this.$el.toggleClass("tcb-disabled",s())},e.Sticky.input=(e,t)=>{n().setJsonData("display-type",TVE.main.device,t.checked?"sticky":"normal"),this.$(".sticky-options").toggle(t.checked)},e.StickyDelta.update=function(){this.setValue(n().getJsonData("sticky","delta"))},e.StickyDelta.input=function(e,t){n().setJsonData("sticky","delta",t.value)},e.StickyUntil.update=function(){this.setValue(n().getJsonData("sticky","stickyUntil"))},e.StickyUntil.input=(e,t)=>{n().setJsonData("sticky","stickyUntil",t.value),this.$(".sticky-element-id").toggle("element"===t.value)},e.StickyElementId.update=function(){this.setValue(n().getJsonData("sticky","element"))},e.StickyElementId.change=(e,t)=>{const i=t.value.replace(/([^a-zA-Z0-9_-])/g,"");n().setJsonData("sticky","element",i),this.checkStickyUntilPosition(i)}},checkStickyUntilPosition(e){let t="";if("element"===n().getJsonData("sticky","stickyUntil"))if(void 0===e&&(e=n().getJsonData("sticky","element")),0===(e=e.trim().replace("#","")).length)t="Please specify element id!";else{const i=TVE.inner_$(`#${e}`);0===i.length?t="Element with the specified ID doesn't exist!":i.offset().top<n().$element.offset().top+n().$element.outerHeight()&&(t="Element must be under the sidebar!")}this.$(".sticky-until-warning").html(t).toggle(t.length>0)},backwardsCompatibility(){if(n().getJsonData("sticky","sticky")){const e=n().getJsonData("sticky","visibleOn");["desktop","tablet"].forEach((t=>{n().setJsonData("display-type",t,e.includes(t)?"sticky":"normal")})),n().setJsonData("sticky","sticky",!1)}},forceWhiteBackground(){const e=[];let t;for(const i in TVE.main.responsive)t=TVE.head_css_get(`${TVE.Theme.CONST.body_class} ${this.sidebarSection.selector} ${this.sidebarSection.constructor.backgroundSelector}`,"background-color",TVE.main.responsive[i].media),n().isOffScreen(i)&&("transparent"===t||""===t&&e.includes("transparent"))&&this.sidebarSection.$background.head_css({"background-color":"white!important"},TVE.main.responsive[i].media),t&&e.push(t)}})},7949:function(e){const t=()=>TVE.inner.window.ThriveTheme.sidebar;e.exports=TVE.Views.Base.component.extend({controls_init(e){e.ExpandedIcon.setModal(TVE.IconsModal.get_instance(TVE.modal.get_element("icons"))),e.ExpandedIcon.change=function(e,i){const n=i.icon.attr("id");e.find(".trigger-expanded-icon").html(TVE.svg_icon({path:i.icon.html(),viewBox:i.icon[0].getAttribute("viewBox"),name:i.icon.find("> title").first().text(),id:n})),t().setJsonData("off-screen","expandedIcon",n),this.updateValue(n)},e.ExpandedIcon.update=function(){this.updateValue(t().getJsonData("off-screen","expandedIcon"))},e.CollapsedIcon.setModal(TVE.IconsModal.get_instance(TVE.modal.get_element("icons"))),e.CollapsedIcon.change=function(e,i){const n=i.icon.attr("id");e.find(".trigger-collapsed-icon").html(TVE.svg_icon({path:i.icon.html(),viewBox:i.icon[0].getAttribute("viewBox"),name:i.icon.find("> title").first().text(),id:n})),t().setJsonData("off-screen","collapsedIcon",n),this.updateValue(n)},e.CollapsedIcon.update=function(){this.updateValue(t().getJsonData("off-screen","collapsedIcon"))},e.IconColor.input=function(e){this.applyElementCss({color:`${e}!important`})},e.IconColor.update=function(e){this.setValue(e.css("color"))},e.Size.input=function(e,t){this.applyElementCss({"font-size":`${t.value}px!important`})},e.Size.update=function(e){this.setValue(e.css("font-size"))}}})},9540:function(e){const t=new TVE.Views.Base.control({model:{},config:{}});t.input=t.update=t.setChecked=jQuery.noop,e.exports=TVE.Views.Components.Button.extend({after_init:function(){this.hooks()},after_update:function(){const e=this.controls.ButtonSize.config.config.name;this.controls.ButtonSize.$el.find(".button-group-name").text(e)},controls_init:function(e){const i=this.getSyncedElements.bind(this);e.SecondaryText=t,TVE.Views.Components.Button.prototype.controls_init.call(this,e),e.ButtonIcon.change=function(e,t){const n=i(e);TVE.Components.button.controls.ButtonIcon.change.call(this,n,t)}},getSyncedElements:function(e){e=e.closest(".theme-button");const t=TVE._type(e);let i;return TVE.Components.thrive_comments_list.isCommentsButton(e)&&(i=e.closest(TVE.identifier("thrive_comments")).find(TVE.identifier(t))),i||e},hooks:function(){TVE.add_filter("tcb.button.styles_templates",(e=>(TVE.ActiveElement.is(TVE.Theme.selectors.editor.theme_buttons.join(", "))&&(e=""),e)))}})},8221:function(e,t,i){const n=i(4243);e.exports=n.extend({controls_init:function(e){n.prototype.controls_init.call(this,e,!1),TVE.add_filter("tcb.toggle_header_scroll_state_components",this.addScrollStateComponents),e.HeaderPosition.change=function(e,t){let i={position:"","z-index":"",top:""};"over"===t.dataset.value&&(i={position:"absolute!important","z-index":9999,top:0}),e.head_css(i)},e.HeaderPosition.update=function(e){const t="absolute"===e.css("position")?"over":"push";this.setActive(t)}},addScrollStateComponents:function(e){return e["theme-hf"]=["HeaderPosition"],e},isBackgroundFullWidth:function(e){return TVE.Theme.$content.outerWidth()===e.find(".symbol-section-out").outerWidth()},after_update:function(){const e=this.section.inEditMode();this.sectionSelect.update(),this.$(".edit-section").html(`Edit ${this.section.type}`),this.$(".dropdown-header").html(`${TVE.ucFirst(this.section.type)} Options`),this.$(".section-type").html(this.section.type),this.$(".default-section-options").toggle(!e),this.$(".section-edit-options").toggle(e||!this.section.isDynamic()),this.controls.ContentWidth.$el.toggle(!e&&!this.section.inheritsContent()),this.controls.StretchContent.$el.toggle(!e&&!this.section.inheritsContent()),this.controls.PageMap.$el.toggle(!e),this.controls.LayoutVisibility.$el.toggle(!e),this.controls.HeaderPosition.$el.toggle("header"===this.section.type)}})},1521:function(e,t,i){const n=i(3724);let s;e.exports=TVE.Views.Base.component.extend({after_init:function(){this.$BoxedControl=this.$(".full-width-control")},controls_init:function(e){const t=_.throttle(TVE.PostList.layout.masonryRedo,500),i=_.throttle(TVE.inner.window.TCB_Front.resizePageSection,50);e.ContentWidth.input=function(e,s){n.setWidth(s.value+this.getUM(),"content",!0),i(),t()},e.ContentWidth.change=function(e,t){n.setWidth(t.value+this.getUM(),"content",!1),TVE.do_action("tcb.content_layout_max_width.change",e)},e.ContentWidth.update=function(){this.setValue(n.getWidth("content")),this.originalConfig.max=TVE.Theme.$wrapper.innerWidth()},e.LayoutWidth.input=function(e,s){const o=s.value+this.getUM();n.setWidth(o,"content",!0).setWidth(o,"background",!0),i(),t()},e.LayoutWidth.change=function(e,t){const i=t.value+this.getUM();n.setWidth(i,"content",!1).setWidth(i,"background",!1),TVE.do_action("tcb.content_layout_max_width.change",e)},e.LayoutWidth.update=function(){this.setValue(n.getWidth("background")),this.originalConfig.max=TVE.inner.$body.innerWidth()},this.progressBarControls(e)},after_update:function(){this.toggleWidthSettings(!n.isFullWidth())},toggleWidthSettings:function(e){this.controls.ContentWidth.$el.toggleClass("tcb-hidden",e),this.controls.LayoutWidth.$el.toggleClass("tcb-hidden",!e),this.$BoxedControl.find(".active").removeClass("active"),this.$BoxedControl.find(`button[data-boxed="${e?1:0}"]`).addClass("active")},toggleFullWidth:function(e,t){const i=parseInt(t.dataset.boxed)?"1080px":"100%";n.setWidth(i,"content",!1).setWidth(i,"background",!1),this.update(),this.controls.PageMap.update(TVE.Theme.$main),TVE.Editor_Page.reposition_icons(),TVE.inner.window.TCB_Front.resizePageSection(),TVE.PostList.layout.masonryRedo(),TVE.do_action("tcb.content_layout_max_width.change",TVE.Theme.$wrapper)},progressBarControls:function(e){const t=this;if(this.$(".progress-indicator-container").length){const i=TVE.inner_$("#thrive-header"),n=TVE.inner_$("#thrive-progress-bar");i[0]&&"undefined"!=typeof ResizeObserver&&new ResizeObserver((()=>{t.setPosition(n,n.attr("data-position"))})).observe(i[0]),this.progressBarTooltip=new TVE.Views.other.Tooltip({template:TVE.tpl("theme-main/controls/progress-tooltip"),type:"progress-bar"}),this.$(".tooltip-container").append(this.progressBarTooltip.$el),e.ProgressIndicator.change=function(i,n){i.attr("data-position",(()=>n.checked?e.ProgressPosition.getValue():null)),t.$(".indicator-location").toggleClass("tcb-hidden",!n.checked)},e.ProgressIndicator.update=function(e){const i=void 0!==e.attr("data-position");t.$(".indicator-location").toggleClass("tcb-hidden",!i),this.setChecked(i)},e.ProgressPosition.change=(e,i)=>{e.attr("data-position",i.value),t.setPosition(e,i.value),t.$(".progress-position-notice").toggleClass("tcb-hidden","top"===i.value)},e.ProgressPosition.update=function(e){const i=e.attr("data-position"),n=void 0===i?"top":i;t.setPosition(e,n),t.$(".progress-position-notice").toggleClass("tcb-hidden","top"===n),this.setValue(n)},e.ProgressBarColor.input=function(e){this.applyElementCss({"--bar-background-color":e&&String(e).replace("var $ ","var")||"","--tcb-applied-color":e&&String(e).replace("var","var$")||""})},e.ProgressBarColor.update=function(e){const t=e.tcbCss("--tcb-applied-color").replace("var$","var").replace("var $ ","var");this.setValue(t)},e.ProgressBarHeight.input=function(e,i){this.applyElementCss({"--bar-height":t.getCorrectHeight(i.value,e)+this.getUM()})},e.ProgressBarHeight.change=function(e,i){this.applyElementCss({"--bar-height":t.getCorrectHeight(i.value,e)+this.getUM()})},e.ProgressBarHeight.update=function(e){this.setValue(e.tcbCss("--bar-height"))},TVE.add_filter("tcb.inline_shortcodes.afterInsert",((e,t)=>("thrive_remaining_time"===t.key?(e.find("span").html(TVE.inner.window.ThriveTheme.utils.readingMinutes(TVE.Editor_Page.editor.find(".tcb-post-content"))),e.after(" minutes remaining")):"thrive_word_count"===t.key&&(e.find("span").html(TVE.inner.window.ThriveTheme.utils.countWords(TVE.Editor_Page.editor.find(".tcb-post-content"))),e.before("(").after(" words)")),e)),9)}},openTooltip:function(e,t){this.progressBarTooltip&&this.progressBarTooltip.display(this.$(".progress-indicator-container").offset().top),s&&clearTimeout(s)},closeTooltip:function(e,t){s=setTimeout((()=>{this.progressBarTooltip&&this.progressBarTooltip.hide()}),500)},setPosition:function(e,t){const i="top"===t?0:e.next(".thrv_header").outerHeight();e.css("top",i+"px")},getCorrectHeight:function(e,t){const i=t.tcbCss("--bar-height"),n=!parseInt(e)||parseInt(e)<2?i:e;return n>10?i:n}})},4243:function(e,t,i){const n=i(3724),s=()=>TVE.inner.window.ThriveTheme.sidebar,o=i(3978);let a;e.exports=TVE.Views.Base.component.extend({after_init:function(){this.sectionSelect=new o({el:this.$(".section-select")})},before_update:function(){return this.section=TVE.Theme.utils.getSectionInstance(TVE.ActiveElement),this.sectionSelect.setSection(this.section).setSectionComponent(this),this},mouseenter:function(){a=setTimeout((function(){TVE.Components.theme_section&&TVE.Components.theme_section.tooltip.$el.hasClass("tcb-visible")&&TVE.Components.theme_section.tooltip.dismiss()}),500)},mouseleave:function(){clearTimeout(a)},controls_init:function(e){let t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];const i=_.throttle(TVE.inner.window.TCB_Front.resizePageSection,10),o=_.throttle(TVE.PostList.layout.masonryRedo,500),a=this;t&&(e.Position.change=function(t,i){const o=i.value;n.setSidebarPosition(o),(a.section&&"sidebar"===a.section.type||t.is(TVE.identifier("main-container")))&&s().offScreenRefresh(!0),TVE.Editor_Page.reposition_icons(),setTimeout(TVE.inner.window.TCB_Front.resizePageSection,500),e.PageMap.update(t),TVE.Theme.content.updateResizeHandlersPosition()},e.Position.update=function(){const e=TVE.inner.window.ThriveTheme.utils.getSidebarPosition();TVE.Theme.$main.hasClass(TVE.Theme.constants.identifiers.FLIP_SECTIONS_CLASS)&&(n.setSidebarPosition(e,TVE.main.responsive.desktop.media),TVE.Theme.$main.removeClass(TVE.Theme.constants.identifiers.FLIP_SECTIONS_CLASS)),this.setValue(e),a.section&&this.$el.toggleClass("tcb-disabled","sidebar"===a.section.type&&!a.section.isVisible())},e.MinWidth.input=function(e,t){this.applyElementCss({"min-width":t.value+this.getUM()}),o(),s().isOffScreen()&&(parseInt(TVE.inner.document.body.style.getPropertyValue("--off-screen-sidebar-size"))<t.value?s()._get("off-screen").updateSidebarWidth(t.value):s()._get("off-screen").updateSidebarWidth())},e.MinWidth.change=function(e,t){this.applyElementCss({"min-width":t.value+this.getUM()}),o()},e.MinWidth.update=function(e){const t=parseInt(e.css("min-width"));this.setValue(isNaN(t)?0:t),this.$el.toggleClass("tcb-disabled","content"===a.section.type&&s().isOffScreen()||"sidebar"===a.section.type&&!a.section.isVisible()),this.originalConfig.max=TVE.Theme.$main.width()}),e.Visibility.change=function(e,t){a.section.toggle(t.checked),TVE.ElementEditIcons.hide_icons()},e.Visibility.update=function(){this.setChecked(a.section.isVisible())},e.StretchBackground.input=function(t,i){const n=i.checked;a.section.setWidth(n?"100%":"","background",!0);const s=a.section.$background.css("width");if(!n&&parseInt(a.section.$content.css("width"))>parseInt(s)){let e="";a.section.inheritsContent()||(e=s),a.section.setWidth(e,"content",!0)}"top"!==a.section.type&&"bottom"!==a.section.type||TVE.Theme.utils.toggleSectionFullWidth(t,n),e.PageMap.update(t),e.ContentWidth.update(),e.StretchContent.update()},e.StretchBackground.update=function(){this.setChecked(a.section.hasFullWidthBackground()),this.$el.toggleClass("tcb-disabled",!a.section.isVisible())},e.ContentWidth.input=function(e,t){a.section.setWidth(t.value+this.getUM(),"content",!1),i(),o()},e.ContentWidth.change=function(e,t){a.section.setWidth(t.value+this.getUM(),"content",!0)},e.ContentWidth.update=function(){const e=a.section.$content.css("width"),t=parseInt(a.section.$background.css("width"));this.$el.toggleClass("tcb-disabled",a.section.hasFullWidthContent()||!a.section.isVisible()),this.originalConfig.max=t,this.setValue(e)},e.StretchContent.input=function(t,n){a.section.setWidth(n.checked?"100%":"","content",!0),i(),o(),e.ContentWidth.update()},e.StretchContent.update=function(){this.setChecked(a.section.hasFullWidthContent()),this.$el.toggleClass("tcb-disabled",!a.section.isVisible()||!a.section.hasFullWidthBackground())},e.InheritContentSize.input=function(t,s){const r=s.checked;a.section.setWidth(r?"":n.getWidth("content"),"content",!0),r||(e.ContentWidth.update(),e.StretchContent.update()),e.ContentWidth.$el.toggle(!r),e.StretchContent.$el.toggle(!r),i(),o()},e.InheritContentSize.update=function(){this.setChecked(a.section.inheritsContent()),this.$el.toggleClass("tcb-disabled",!a.section.isVisible())},e.SectionHeight.input=function(e,t){this.applyElementCss({"min-height":`${t.value}${this.getUM()}!important`})},e.SectionHeight.update=function(e){const t=parseInt(e.css("min-height"));this.setValue(t||0),this.$el.toggleClass("tcb-disabled",!a.section.isVisible()||"sidebar"===a.section.type&&s().isOffScreen())},e.VerticalPosition.change=function(e,t){const i={"justify-content":t.dataset.value,display:"block","flex-direction":""};""!==t.dataset.value&&(i.display="flex",i["flex-direction"]="column"),this.applyElementCss(i)},e.VerticalPosition.update=function(e){this.setActive(e.css("justify-content")),this.$el.toggleClass("tcb-disabled",!a.section.isVisible())}},after_update(){const e=!this.section.isDynamic(),t=this.section.inEditMode(),i="sidebar"===this.section.type||"content"===this.section.type;this.controls.PageMap.$el.toggle(!t),this.controls.LayoutVisibility.$el.toggle(!t),this.controls.Position.$el.toggle("sidebar"===this.section.type),this.controls.MinWidth.$el.toggle(i&&(t||e)),this.controls.InheritContentSize.$el.toggle(!i&&!t),this.controls.ContentWidth.$el.toggle(!i&&!t&&!this.section.inheritsContent()),this.controls.StretchContent.$el.toggle(!t&&!i&&(this.section.hasFullWidthBackground()||n.isFullWidth())&&!this.section.inheritsContent()),this.controls.StretchBackground.$el.toggle(!i&&!t),this.controls.Visibility.$el.toggle(!i&&!t||"sidebar"===this.section.type),this.controls.SectionHeight.$el.toggle(t||e),this.controls.VerticalPosition.$el.toggle(t||e),this.sectionSelect.update()}})},7645:function(e){const t=TVE.Views.InlinePanel.extend({template:TVE.tpl("inline/content-templates"),after_initialize:function(){this.$(".drop-panel").addClass("small-pad tcb-autocomplete"),this.autocomplete()},autocomplete:function(){const e=TVE.CONST.theme.sidebars.map((e=>({id:e.value,label:e.name,title:e.name})));this.$input=this.$(".tcb-search").autocomplete({minLength:0,appendTo:this.$(".popup-content"),source:function(t,i){i(TVE.inner_$.ui.autocomplete.filter(e,t.term).slice(0,5))},select:(e,t)=>(this.on_select(t.item.id,t.item.value),e.stopPropagation(),!1)}),this.$input.data("ui-autocomplete")._renderItem=function(e,t){const i=new RegExp(this.term,"i");return e.addClass("tcb-suggest"),jQuery("<li></li>").data("item.autocomplete",t).append('<a href="#" class="tcb-truncate">'+t.label.replace(i,'<span class="highlight">'+this.term+"</span>")+"</a>").appendTo(e)}},onOpen:function(){this.$input.val("").focus().autocomplete("search")}});e.exports=TVE.Views.Base.component.extend({controls_init:function(e){this.placeholder_panel=new t({component:this,minWidth:300,no_buttons:!0,on_select:(e,t)=>{this.get_sidebar(e,t)}}),e.Sidebars.change=(e,t)=>{this.get_sidebar(t.value,t.text,e)},e.Sidebars.update=function(e){this.setValue(e.attr("data-id"))},e.Orientation.change=(e,t)=>{e.head_css({"flex-direction":t.dataset.value})},e.Orientation.update=function(e){this.setValue(e.css("flex-direction"))}},placeholder_action:function(e){this.placeholder_panel.open(e,e.find(".tcb-inline-placeholder-action"))},get_sidebar:function(e,t,i){void 0===i&&(i=TVE.ActiveElement),i.addClass("tve-loading"),TVE.$.ajax({headers:{"X-WP-Nonce":TVE.CONST.rest_nonce},data:{id:e},url:TVE.CONST.theme.routes.sidebar,method:"GET",success:n=>{n.active?(i.html(n.html).removeClass("tcb-elem-placeholder tcb-sidebar-placeholder tve-loading").attr("data-id",e),TVE.Theme.content.init_selectors(i.parent()),this.placeholder_panel.hide(),TVE.Editor_Page.focus_element(i.removeClass("edit_mode"))):TVE.page_message(`There are no widgets added to <b>${t}</b>.`,!1,5e3)},error:e=>{console.error(e)}})}})},2907:function(e){const t=[".search-submit .thrv_icon",".search-submit .tcb-button-text.thrv-inline-text"];e.exports={identifiers:{EDITOR_CLASS:"ttb-editor-page",FLIP_SECTIONS_CLASS:"flip-sections",HIDE_SECTION_CLASS:"hide-section",MAIN_COLUMNS_SEPARATOR:".main-columns-separator"},templates:{error404:"error404",ARCHIVE:"archive",ARCHIVE_BASE:"archive-base",BLOG:"blog",PAGE:"page",POST:"post",SEARCH:"search",AUTHOR:"author",SINGULAR:"singular",HOME:"home",PRODUCT:"product",CART:"cart",CHECKOUT:"checkout",ACCOUNT:"account"},theme_button:{layout:"button_layout"},blog_list:{no_results:{type:"no_results",selector:".main-no-results",affected_selectors:".tcb-post-list#main,.tcb-pagination,.tcb-featured-list"},states:[{value:"blog_list",label:"Search results found"},{value:"no_results",label:"No results found"}]},comments:{states:[{value:"logged",label:"Logged In User View"},{value:"visitor",label:"Visitor View"},{value:"closed",label:"Comments are Closed"}],hiddenElements:["thrive_author_box","thrive_author_links","thrive_breadcrumbs","thrive_calendar_widget","thrive_widget_area","thrive_comments","thrive_dynamic_list","post_author_picture","post_content","post_thumbnail","contentblock","symbol","post_list","ct_symbol","tl_shortcode","quiz","ultimatum_countdown","ovation_capture","ovation_display","tcb_post_author_bio","thrive_author_follow","tcb_post_author_name","tcb_post_author_picture","tcb_post_categories","tcb_post_content","tcb_post_published_date","tcb_post_comments_number","tcb_post_tags","tcb_post_featured_image","tcb_post_title","tcb_post_read_more","thrive_post_meta"]},search_dynamic_selectors:t,text_dynamic_selectors:[".comment-form-reply-title",".comment-form-comment-notes"],dynamic_selectors:[...t,".comment-form-submit .thrv_icon",".comment-form-submit .tcb-button-text.thrv-inline-text",".comment-reply-link .thrv_icon",".comment-reply-link .tcb-button-text.thrv-inline-text"],dynamicVideo:{placeholderTemplate:"theme-main/video-overlay-placeholder",RESPONSIVE_VIDEO_CONTAINER:".tve_responsive_video_container",THUMBNAIL_UPLOAD_BUTTON_CLASS:".tve-video-thumbnail-control",THUMBNAIL:{STATIC:"static",DYNAMIC:"dynamic",NONE:"none"}},taxonomyShortcodes:["thrive_archive_name","thrive_archive_description","thrive_archive_parent_name"],DEFAULT_EXCERPT_WORDS:55,DEFAULT_READ_MORE:"...",content_switch:{blog_index_text:"Blog Index"},COMMENT_SUBMIT_TYPE:"thrive_comments_form_submit",COMMENT_REPLY_TYPE:"thrive_comment_reply_button",SIDEBAR_CROPPED_HEIGHT:600,SIDEBAR_MAXIMUM_PREVIEW_WIDTH:298,HORIZONTAL_LAYOUT_WIDTH:700,HORIZONTAL_LAYOUT_PADDING:60,VERTICAL_LAYOUT_WIDTH:350,VERTICAL_LAYOUT_PADDING:52,defaultPreviewOptions:{imageTypeCallback:"toJpeg",quality:1,fixWindowWidth:!1,bgcolor:"white",style:{top:0,left:0,right:0,bottom:0}},PREVIEW_SECTION_WRAPPER_CLASS:"preview-section-cloned-content",PREVIEW_TEMPLATE_WRAPPER_CLASS:"preview-template-cloned-content",THEME_SKIN_COLOR_VARIABLE_PREFIX:"--tcb-skin-color-",THEME_CONTEXT:"ttb",ARCHITECT_CONTEXT:"tar",WOO_ELEMENTS:["shop","product","cart","checkout","account"],NORMAL_OVERLAY_MIN_HEIGHT:106,SMALL_OVERLAY_MIN_HEIGHT:52,SMALL_OVERLAY_MIN_WIDTH:236}},7459:function(e,t,i){function n(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function s(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?n(Object(i),!0).forEach((function(t){o(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):n(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function o(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}(t=>{const n=i(3902),o=i(2952),a=i(2806),r={},l={};["top","content","sidebar","bottom"].forEach((e=>r[e]=`${o.identifier}.${e}-section ${o.contentSelector}`)),["header","footer"].forEach((e=>l[e]=`${e}.thrv_symbol ${a.contentSelector}`)),e.exports={save:function(e){let i=arguments.length>1&&void 0!==arguments[1]&&arguments[1],s=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];i||TVE.main.overlay();const o=new n(TVE.Theme.$wrapper);TVE.do_action("theme.update_template.before");let a=JSON.stringify(TVE.apply_filters("theme.update_template.data",o.data()));"function"==typeof TVE.prepareWordfencePostContent&&(a=TVE.prepareWordfencePostContent(a));const r=t.ajax({url:`${TVE.CONST.theme.routes.templates}/${TVE.CONST.post.ID}`,type:"POST",data:{action:"update_template",template:a,"conditional-display-groups":TVE.Models.ConditionalDisplayManager.prepareGroupsForSave()},headers:{"X-WP-Nonce":TVE.CONST.rest_nonce}}).done((t=>{i||TVE.page_message(`Template <b>${TVE.CONST.post.post_title}</b> saved successfully!`,!1,5e3),window.onbeforeunload=null,"function"==typeof e&&e(t)})).fail((e=>{TVE.wordfenceResponse(e)||TVE.page_message("Template was not saved",!0,5e3)})).always((()=>{TVE.main.overlay("close"),TVE.Editor_Page.disableSaveWarning(),TVE.Editor_Page.enableSaveWarning(),TVE.do_action("theme.update_template.after",i,s)}));return s&&setTimeout(this.previewSavedTemplate,10),r},init_selectors:e=>{void 0===e&&(e=TVE.Theme.$wrapper),_.each(TVE.Theme.selectors.shortcodes,((i,n)=>{e.find(n).addBack(n).each(((e,s)=>{const o=t(s),a=TVE.apply_filters("theme.post_list.identifier",TVE.identifier("post_list")),r=o.closest(a);r.length?TVE.PostList.content.initShortcode(r,a,i):(0===o.parents(".thrv_text_element, .thrv_heading").length&&(s.classList.add(TVE.PostList.constants.TCB_SHORTCODE_CLASS,"thrive-shortcode","thrv_wrapper"),s.setAttribute("data-shortcode",i),TVE.Elements[i]&&TVE.Elements[i].has_selector&&s.setAttribute("data-selector",n)),TVE.Theme.template&&TVE.Theme.template.isSingular()&&TVE.Theme.CONST&&0===o.find(".theme-empty-post-content-placeholder").length&&TVE.PostList.content.replaceShortcodeWithData(i,o,TVE.Theme.CONST.ID))}))})),""===TVE.CONST.symbol_type&&TVE.CONST.theme.is_theme_template&&[TVE.Theme.$sections.header,TVE.Theme.$sections.footer].forEach((e=>{const t=TVE.Theme.models.HFSection.getInstance(e);e.addClass(["tcb-shortcode","thrive-shortcode","tve_no_icons"].join(" ")).attr({draggable:!1,"data-tcb-elem-type":t.type,"data-element-name":TVE.ucFirst(t.type)}),t.updateAttr()})),TVE.Components.menu.setDataSelectors(e),_.each(TVE.Theme.selectors.editor.have_selector,(t=>{e.find(t).addBack(t).addClass("thrv_wrapper").attr("data-selector",t)})),_.each(TVE.Theme.constants.text_dynamic_selectors,(t=>{e.find(t).attr("data-selector",t)})),TVE.Theme.$wrapper&&TVE.Theme.$wrapper.attr("data-selector","#wrapper"),TVE.Theme.selectors.editor.no_drag.forEach((t=>e.find(t).addBack(t).removeClass("tve-droppable"))),TVE.do_action("theme.selectors.init",e)},getSectionDropzoneTarget:e=>{if(!TVE.CONST.theme.is_theme_template||void 0!==TVE.FLAGS.$dragged_element)return e;let t;const i=TVE.main.EditMode.element();if(i&&i.length?(TVE.Theme.models.Section.is(i)||TVE.Theme.models.HFSection.is(i))&&(t=i):t=TVE.Theme.utils.getDropTargetSection(),t&&t.length){const i=TVE.Theme.utils.getSectionInstance(t),n=i.$content.children();n.length?e=n.last():(e=TVE.inner_$("<div></div>").appendTo(i.$content),setTimeout((()=>{e.remove()}),100))}return e},previewSavedTemplate:function(){arguments.length>0&&void 0!==arguments[0]||TVE.inner.$body;let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:TVE.CONST.post.ID;const i=TVE.Theme.content.getTemplateContentToPreview(),n=s(s({},TVE.Theme.constants.defaultPreviewOptions),{quality:.1});TVE.generateElementPreview(i,(t=>{i.parent(`.${TVE.Theme.constants.PREVIEW_TEMPLATE_WRAPPER_CLASS}`).remove();const n={url:`${TVE.CONST.theme.routes.templates}/${e}/preview`,action:"template_preview",image:t,ID:TVE.CONST.post.ID};TVE.Theme.utils.savePreviewImage(n)}),t.extend(!0,{},n),!0)},getTemplateContentToPreview:function(){const e=TVE.inner.$body,t=e.clone(),i=this.getTemplatePreviewHeight(),n=TVE.Theme.utils.filterContentByHeight;let s=i;TVE.Theme.utils.fixClonedImageHeights(t,e),TVE.Theme.utils.filterContentToPreview(t),t.find(".section-overlay-actions").remove(),t.children(":not(#wrapper):not(style)").remove().end(),t.wrap(`<div class="${TVE.Theme.constants.PREVIEW_TEMPLATE_WRAPPER_CLASS}">`).parent().css({position:"absolute",top:"-100000px",left:0,right:0,"margin-left":"auto","margin-right":"auto"}).insertAfter(e),s=n(t.find(`${l.header}, ${r.top}`),s);let o=s,a=s;return o=n(t.find(`${r.content}`),o),1===parseInt(TVE.Theme.$main.attr("data-wrap"))&&(a=o),a=n(t.find(`${r.sidebar}`),a),s=Math.min(o,a),s=n(t.find(`${r.bottom}`),s),s=n(t.find(`${r.footer}`),s),s>0&&t.height(e.width()),e.hasClass("theme-has-off-screen-sidebar")&&t.find(`${r.sidebar}`).parent().attr("style",`display:block;height: ${i}px;`),t},getTemplatePreviewHeight:function(){return TVE.inner.$body.width()},renderers:()=>{const e={thrive_taxonomy_term_description:{render_default:()=>TVE.Theme.CONST.archive_description},thrive_breadcrumbs:{render_default:()=>{const e=TVE.inner_$(`<div>${TVE.inner_$("#tve-theme-thrive_breadcrumbs").html()}</div>`);return Object.keys(TVE.CONST.theme.breadcrumbs_labels).filter((e=>TVE.Components.thrive_breadcrumbs.controls[`${e}Label`])).forEach((t=>{TVE.Components.thrive_breadcrumbs.controls[`${t}Label`].onInput(e,{value:TVE.CONST.theme.breadcrumbs_labels[t]})})),e.html()}}};return["thrive_comments","product-template","shop-template","account-template","cart-template","checkout-template"].forEach((t=>{e[t]={render_default:()=>{let e=TVE.inner_$(`#tve-theme-${t}`).html();return e=e.replace(/tve-script/g,"script"),e}}})),e},updateResizeHandlersPosition:_.debounce((function(e){void 0===e&&(e=TVE.Theme.$wrapper.find(TVE.Theme.constants.identifiers.MAIN_COLUMNS_SEPARATOR).width()),(e=parseInt(e))&&(TVE.Theme.$sections.sidebar.find(".ui-resizable-w").css("left",-(e/2+3)+"px"),TVE.Theme.$sections.sidebar.find(".ui-resizable-e").css("right",-(e/2+3)+"px"))}),100)}})(jQuery)},2526:function(e,t,i){e.exports={LayoutVisibility:i(5768),DynamicVideoThumbnail:i(4855),BeautifulSelect:i(9622),SectionSelect:i(3978)}},9622:function(e){const t="tve-beautiful-select-option";e.exports=TVE.Views.Base.control.extend({template:TVE.tpl("theme-main/controls/beautiful-select"),onClick:function(e,t){this.setValue(t.dataset.value,!0),this.toggle(!1)},getValue:function(){const e=this.$(`.${t}`);return e.length?e.attr("data-value"):null},setValue:function(e){let t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];this.renderSelected(parseInt(e)),t&&this.change(this.applyTo(),e)},renderSelected:function(e){const i=TVE.CONST.theme.layouts.find((t=>t.ID===e)),n=this.$(`.${t}`);let s=t;TVE.Theme.models.Layout.hasUnsavedChanges()&&(s+=" has-changes");const o=TVE.tpl("theme-main/controls/beautiful-select-option")({classes:s,fn:"hideSelect",value:e,icon:this.getOptionIcon(e),name:i.post_title,dropDownIcon:TVE.CONST.theme.layouts.length>1});n.length>0?n.html(o):this.$el.prepend(o)},getOptionIcon:function(e){return""},options:function(){return this.get_config("options")},isOpen:function(){return this.$el.hasClass("open")},toggle:function(){let e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];this.$el.toggleClass("open",e)},hideSelect:function(){this.toggle(!this.isOpen())}})},4445:function(e){e.exports=TVE.Views.Controls.DropPanel.extend({template:TVE.tpl("theme-main/controls/edit-c-form-item"),after_render:function(){this.$placeholderInput=this.$(".c-f-placeholder"),this.$labelInput=this.$(".c-f-label"),this.$labelWrapper=this.$("#c-f-label-wrapper"),this.$placeholderWrapper=this.$("#c-f-placeholder-wrapper")},reset:function(e){this.model=e,this.updateControls()},updateControls:function(){const e=this.model.get("hasLabel"),t=this.model.get("hasPlaceholder");this.$labelWrapper.toggleClass("tcb-hidden",!e),this.$placeholderWrapper.toggleClass("tcb-hidden",!t),e&&this.$labelInput.val(this.model.get("label")),t&&this.$placeholderInput.val(this.model.get("placeholder"))},changeSetting:function(e,t){const i={};i[t.getAttribute("data-setting")]=t.value,this.model.set(i)},cancel:function(){this.model.restoreState()},apply:function(){this.component.controls.FieldsControl.update(TVE.ActiveElement)}})},4855:function(e){const t=TVE.Theme.constants.dynamicVideo.THUMBNAIL,i=TVE.Theme.constants.dynamicVideo.RESPONSIVE_VIDEO_CONTAINER,n=TVE.Theme.constants.dynamicVideo.THUMBNAIL_UPLOAD_BUTTON_CLASS,s="data-thumbnail-type",o={input:function(e,a){const r=TVE.ActiveElement,l=a.value===t.DYNAMIC?o.getFeaturedImage():"",c=TVE.Components.responsivevideo.$(n);r.find(i).attr(s,a.value),o.renderOverlay(r,l),a.value===t.DYNAMIC&&r.attr("data-video-cover-type","thumbnail"),c.toggleClass("tcb-hidden",a.value!==t.STATIC),TVE.Components.responsivevideo.$(".tcb-player-icon-wrapper").toggle(a.value!==t.NONE&&!c.is(":visible")),a.value===t.DYNAMIC&&TVE.Components.responsivevideo.update(TVE.Components.responsivevideo.controls.responsive_video)},update:function(e){const o=TVE.Components.responsivevideo.$el;let a=e.find(i).attr(s);a||(a=t.STATIC),o.find(".v-thumbnail-type").val(a),o.find(n).toggleClass("tcb-hidden",a!==t.STATIC),o.find(".tcb-responsive-video-thumbnail").removeClass("tcb-hidden")},renderOverlay:function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";t&&t.length?(e.attr("overlay",1),e.find(".video_overlay").addClass("video_overlay_image").html('<span class="overlay_play_button">'+TVE.Components.responsivevideo.controls.responsive_video.videoOverlaySVG+"</span>").css({"background-image":"url('"+t+"')","background-repeat":"no-repeat","background-size":"cover","background-position":"center"})):e.find(i).show().html(TVE.tpl(TVE.Theme.constants.dynamicVideo.placeholderTemplate)())},getFeaturedImage:function(){return TVE.CONST.post_image.featured},updateDynamicVideoThumbnail:function(){const e=TVE.inner.$body.find(`.thrv_responsive_video[data-is-dynamic="true"] ${i}[data-thumbnail-type="dynamic"]`);e.length&&o.renderOverlay(e.parent(".thrv_responsive_video"),TVE.CONST.theme.post_featured_image.src)}};e.exports=o},5271:function(e,t,i){const n="dynamic",s=i(4855),o=TVE.VideoProviders.Base.extend({show:function(){const e=TVE.Components.responsivevideo.$el,t=TVE.ActiveElement;return t.removeClass("tcb-elem-placeholder"),t.find(".tcb-inline-placeholder-action").remove(),e.find(".responsive-video-time-label").addClass("tcb-hidden"),e.find(".info-text").addClass("tcb-hidden"),this}}),a={init:function(e){const t=e.$(".v-source");t.append('<option value="dynamic">Dynamic Source</option>'),t.on("change",(e=>{const t=e.currentTarget.value,i=TVE.ActiveElement;a.toggleDynamicThumbnailControls(t===n&&"thumbnail"===i.attr("data-video-cover-type")),TVE.do_action("theme.video.source.changed",t,i,a)})),TVE.add_action("tcb.video.cover_type_visibility_changed",((e,t)=>{TVE.ActiveElement.attr("data-type")===n&&(a.toggleDynamicThumbnailControls("thumbnail"===e),"thumbnail"===e?s.update(TVE.ActiveElement):"none"===e&&TVE.ActiveElement.find(".tve_responsive_video_container").removeAttr("data-thumbnail-type"))})),e.$(".tcb-responsive-video-thumbnail").before(TVE.tpl("theme-main/controls/video-thumbnail-type-select")()),e.dynamicThumbnailInput=s.input,e.dynamicThumbnailUpdate=s.update,e.providers.dynamic=new o({el:e.$("#v-settings-dynamic")[0],key:n,control:e}),this.hooks()},toggleDynamicThumbnailControls:function(e){const t=TVE.Components.responsivevideo.$el;t.find(".ttd-video-thumbnail-type").toggleClass("tcb-hidden",!e),t.find(".tcb-responsive-video-thumbnail .label.full-width").toggleClass("tcb-hidden",e),e||t.find(TVE.Theme.constants.dynamicVideo.THUMBNAIL_UPLOAD_BUTTON_CLASS).removeClass("tcb-hidden")},hooks:function(){TVE.add_filter("theme.save_shortcodes",(e=>(e.find('.thrv_responsive_video[data-type="dynamic"]').each(((e,t)=>{a.saveShortcode(t)})),e))),TVE.add_filter("tcb.element_selected",this.elementSelectedCallback),TVE.add_filter("tcb.video.should_hide_advanced_tab",this.shouldHideAdvancedTab)},saveShortcode:function(e){const t=TVE.inner_$(e);let i={"is-floating":t.find(".tcb-video-float-container").length?1:0,"float-close":"true"===t.attr("data-float-close")?1:0,style:t.find(".tve_responsive_video_container").attr("style")},n="";if(t.hasClass("tcb-lazy-load")&&(i["lazy-load"]=1),"cover"===t.attr("data-video-cover-type")){const e=t.find(".tcb-video-cover");e.length>0&&(n=`[thrive_dynamic_video_cover]${e[0].outerHTML}[/thrive_dynamic_video_cover]`)}else i=a.getThumbnailAttrToSave(i,t);let s="[thrive_dynamic_video";_.each(i,((e,t)=>{"string"==typeof e&&(e=e.trim()),s+=` ${t}="${e}"`})),s+=`]${n}[/thrive_dynamic_video]`,e.innerHTML=s},getThumbnailAttrToSave:(e,t)=>{const i=t.find(".tve_responsive_video_container"),n=i.find(".overlay_play_button"),s=i.find(".overlay_play_button svg");let o=i.attr("data-thumbnail-type"),a="";if(o||(o=TVE.Theme.constants.dynamicVideo.THUMBNAIL.STATIC),e["thumbnail-type"]=o,o===TVE.Theme.constants.dynamicVideo.THUMBNAIL.STATIC){const i=t.find(".video_overlay").css("background-image");a=TVE.Theme.utils.getImageUrlFromCss(i),a&&(e["thumbnail-url"]=a)}return o!==TVE.Theme.constants.dynamicVideo.THUMBNAIL.NONE&&s.length&&(e["thumbnail-icon-id"]=s.attr("data-id")?s.attr("data-id"):s.attr("data-icon-id"),e["thumbnail-icon-style"]=s.attr("data-css")||"",e["thumbnail-icon-viewbox"]=s[0].getAttribute("viewBox")||"",e["thumbnail-icon-path"]=n.find("path").filter(":not([fill=none])").attr("d")),e},elementSelectedCallback:function(e){if(e.is(TVE.Elements.responsivevideo.identifier)){const t=e.attr("data-type");a.toggleDynamicThumbnailControls(t===n),t===n&&s.update(e)}return e},shouldHideAdvancedTab:function(e,t){return t===n&&(e=!0),e}};e.exports=a},5768:function(e,t,i){const n=i(3724),s=i(3902),o=i(1378),a=i(9622);e.exports=TVE.Views.Base.control.extend({template:TVE.tpl("theme-main/layout/layout-visibility"),before_initialize(){TVE.add_action("theme.layout.after_update",(()=>{this.layoutSelect.update(),this.toggleInnerDropdown()}))},after_render(){this.initLayoutSelect()},initLayoutSelect(){this.layoutSelect=new a({el:this.$(".layout-select"),model:{config:{name:"Choose Layout",options:TVE.CONST.theme.layouts.map((e=>({name:e.post_title,value:e.ID})))}},component:this.component}),this.layoutSelect.input=function(e,t){n.load(t,s.getLayoutId(),(()=>{this.update(),this.component.controls.PageMap&&this.component.controls.PageMap.update(e)}))},this.layoutSelect.update=function(){this.render(),this.renderSelected(s.getLayoutId())},this.layoutSelect.getOptionIcon=e=>{const t=TVE.CONST.theme.layouts.find((t=>t.ID===parseInt(e))),i=["theme-layout","100%"===t.meta_input.content_width?"full-layout":"inherit-content-size"];return parseInt(t.meta_input.hide_sidebar)||(i.push("with-sidebar"),parseInt(t.meta_input.sidebar_on_left)&&i.push("left-sidebar")),`<i class="${i.join(" ")}"></i>`},this.layoutSelect.options=()=>TVE.CONST.theme.layouts.filter((e=>e.ID!==s.getLayoutId())).map((e=>({name:e.post_title,value:e.ID}))),this.layoutSelect.render()},getHiddenSections(){const e=[];return _.each(TVE.Theme.$sections,((t,i)=>{t.hasClass(TVE.Theme.constants.identifiers.HIDE_SECTION_CLASS)&&e.push(i)})),e},showSection(e,t){const i=TVE.Theme.utils.getSectionInstance(TVE.Theme.$sections[t.dataset.section]);i&&i.toggle(!0),this.render(),TVE.Theme.utils.getSectionInstance()?this.toggleDropdown():this.component.controls.PageMap.update()},openLayoutCreate(){o.open()},toggleDropdown(){this.$el.toggleClass("dropdown-open"),this.$el.hasClass("dropdown-open")&&(this.layoutSelect.update(),this.layoutSelect.toggle(!1))},toggleInnerDropdown:function(){this.$(".layout-inner-box").toggleClass("dropdown-open").find('[data-fn="updateLayout"]').toggle(TVE.Theme.models.Layout.hasUnsavedChanges())},update(){this.$el.removeClass("dropdown-open"),this.render()},input(){},updateLayout(){n.getInstance().update(!1).done((()=>{this.toggleInnerDropdown(),this.layoutSelect.$(".tve-beautiful-select").removeClass("has-changes")}))}})},3978:function(e){e.exports=TVE.Views.Base.control.extend({template:TVE.tpl("theme-main/controls/section-select"),update:function(){this.section.inEditMode()||!this.section.isVisible()?this.$el.hide():this.section.generatingPreview()||this.$el.show().html(TVE.$(this.template({section:this.section})))},setSection:function(e){return this.section=e,this},setSectionComponent:function(e){return this.sectionComponent=e,this},change:function(){},unlinkSection:function(){this.section.unlink(),this.update(this.section)},enterEditMode:function(){if(this.section instanceof TVE.Theme.models.Section)TVE.main.EditMode.enter(!1,{can_insert_elements:!0,show_default_message:!0,show_overlay:!0}),this.sectionComponent.after_update(),this.section.toggleComponents();else{const e=this.section.type;"function"==typeof TVE.Components[e].editSection&&TVE.Components[e].editSection(),TVE.Components["theme-hf"].before_update().after_update()}},getComponentColor:function(){return"LandingpageSection"===this.el.closest(".tve-component").getAttribute("data-view")?"green":"blue"},showPreviewLoader:function(){this.$(".section-preview").addClass("ttd-loading medium-small"),this.$('[data-fn="replaceSection"]').prop("disabled",!0)},openSaveModal:function(){TVE.Theme.modals.sectionSave.open({section:this.section})},openSectionsModal:function(){TVE.Components.theme_section&&TVE.Components.theme_section.tooltip.$el.hasClass("tcb-visible")&&TVE.Components.theme_section.tooltip.dismiss();const e=this.section.constructor.fetchListFromCloud(this.section.type).fail(console.warn);TVE.Theme.modals.sectionTemplates.open({section:this.section,sectionsLoaded:e})}})},5669:function(e,t,i){const n=[],s=[i(4333),i(5004),i(1445),i(2847),i(929),i(4671),i(6425),i(1397),i(8583),i(4205),i(5650),i(3717)];parseInt(tcb_main_const.is_woo_active)&&s.push(i(5442)),s.forEach((e=>{_.each(e,((e,t)=>{n.push({tag:t,callback:e})}))})),e.exports=n},6425:function(e,t,i){const n=i(2952),s=i(7632)(TVE.inner_$),o=i(5037);var a;a=jQuery,e.exports={"tcb.selection.element":(e,t)=>{if((TVE.CONST.landing_page||TVE.CONST.theme.is_theme_template)&&!e.is(TVE.identifier("sidebar-trigger"))){const t=TVE.Theme.utils.getSectionInstance(e);t&&t.isDynamic()&&!t.inEditMode()&&(e=t.$element)}return e},"tcb.show_icons.target":e=>(e.is(n.identifier+", "+o.identifier)?e=e.addClass("edit_mode").find(" > div ").removeClass("edit_mode").filter(".section-background"):e.hasClass("section-content")?e=e.removeClass("on_hover active_highlight ").siblings(".section-background").addClass("on_hover active_highlight "):e.hasClass("main-content-background")&&e.hasClass("edit_mode")?e.removeClass("edit_mode").parents("#content").addClass("edit_mode"):"content"===e.attr("id")&&(e=e.addClass("edit_mode").find(".main-content-background").removeClass("edit_mode")),e),"tcb.jumplinks.change_target":e=>(e.is(`${n.backgroundSelector}, ${n.contentSelector}`)&&(e=e.parent()),e),"tcb.dragenter.bubble":(e,t)=>{const i=a(t.target),n=TVE.Theme.utils.getSectionInstance(i);return n&&(n.constructor.is(i)||n.isContent(i)||n.isBackground(i))&&(n.$content.children(`:not(${s.closeIconSelector})`).length||n.isDynamic()&&!n.inEditMode())&&(e=!1),(TVE.Theme.models.HFSection.is(i)||TVE.Theme.models.HFSection.is(i.parent()))&&(e=!1),e},"tcb.allow_drop_near":(e,t)=>(t.hasClass("section-content")&&(e=!1),e),"tcb.post_list.add_linked_elements":(e,t)=>(t.is(TVE.Theme.models.Section.contentSelector)&&(e=!1),e),"tve.css_variable.selector|20":(e,t)=>{const i=TVE.Theme.utils.getSectionInstance(t);return i&&t.closest(i.$element).length&&!e.includes(i.selector)&&(e=i.ID?`${i.selector} ${e}`:`${TVE.Theme.CONST.body_class} ${i.baseSelector} ${e}`),e}}},929:function(e){const t={"tcb.dynamic_image.show_tab":(e,t)=>(TVE.Theme.template.isList()&&!TVE.PostList.utils.isInsidePostList(t)&&(e=!1),e),"tcb.dynamic_image.change_selector":(e,t)=>(e.includes(TVE.identifier("blog_list"))&&!e.includes(TVE.identifier("article"))&&(e=e.replace(new RegExp(TVE.identifier("blog_list"),"g"),TVE.identifier("blog_list")+" "+t)),e),"tcb.default_featured_image.change_sizes":(e,t)=>(_.isEmpty(e)&&(e=TVE.Theme.CONST.featured_image_sizes),e),"tcb.default_featured_image.change":(e,t)=>(_.isEmpty(e)&&(e=TVE.PostList.dynamicImage.getFeaturedImageBySize(TVE.Theme.CONST.featured_image_sizes,t)),e)};e.exports=t},4205:function(e){e.exports={set_new_css_id:e=>(void 0!==TVE.ActiveElement&&TVE.ActiveElement.is(TVE.identifier("thrive_dynamic_list"))&&(e=!1),e),"thrive_theme.query_modal.rule_terms_url":(e,t)=>{const i=Array.isArray(t.get("post_type"))?t.get("post_type")[0]:t.get("post_type");return TVE.Components.thrive_dynamic_list&&TVE.Components.thrive_dynamic_list.isDynamicList(t.get("query_type"))&&"post"!==i&&(e=TVE.CONST.theme.routes.list+"/terms"),e},"thrive_theme.query_modal.rule_relations":(e,t)=>{const i=t.model;if(TVE.Components.thrive_dynamic_list&&TVE.Components.thrive_dynamic_list.isDynamicList(i.get("query_type"))&&"post"===i.get("post_type")[0]&&"post"!==i.get("taxonomy")){const t=_.find(e,(e=>"NOT IN"===e.value));t&&(t.label="and exclude")}return e},"thrive_theme.query_modal.should_add_rule":(e,t)=>(TVE.Components.thrive_dynamic_list&&TVE.Components.thrive_dynamic_list.isDynamicList(t.get("query_type"))&&(e=!0),e)}},4333:function(e,t,i){function n(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function s(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?n(Object(i),!0).forEach((function(t){o(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):n(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function o(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}(t=>{const n=i(3902),o=i(3724),a=i(8955);e.exports={"tcb.outerSelector":e=>(TVE.CONST.theme.is_theme_template&&(e=TVE.CONST.tcb_selection_root),e),draggable_elements:e=>e+","+TVE.Theme.selectors.editor.draggable.join(","),non_draggable:e=>e+","+TVE.Theme.selectors.editor.no_drag.join(","),dropzone_elements:e=>e+","+TVE.Theme.selectors.editor.containers.join(","),editor_wrapper:e=>{const t=TVE.inner.$body.find("#wrapper");return TVE.Theme.$wrapper=t.length?t:e,TVE.Theme.$content=TVE.inner.$body.find("#content"),TVE.Theme.$main=TVE.inner.$body.find(".main-container"),TVE.Theme.$sections={header:TVE.Theme.$wrapper.find("header.thrv_symbol"),footer:TVE.Theme.$wrapper.find("footer.thrv_symbol")},TVE.inner.$body.find(TVE.Theme.models.Section.identifier).each(((e,t)=>{TVE.Theme.$sections[t.dataset.section]=TVE.inner_$(t)})),TVE.CONST.theme.is_theme_template&&(TVE.CONST.tcb_selection_root="#wrapper",e=TVE.Theme.$wrapper),e},allow_dragenter:(e,t)=>(TVE.main.EditMode.in_edit()&&TVE.main.EditMode.element()&&TVE.main.EditMode.element().is(TVE.identifier("post_list"))||TVE.CONST.theme.is_theme_template&&(e=t.is(TVE.Theme.selectors.editor.dragenter.join(","))),e),css_style_selector:e=>TVE.CONST.theme.is_theme_template?"style#thrive-template-css":e,head_css_selector:e=>{const i=t(e.element),n=TVE.Theme.utils.getDynamicElementPrefix(i);return n.length&&(e.prefix=e.prefix.trimRight()+" "+n+" "),e},tcb_head_css_prefix:(e,t)=>TVE.Theme.utils.getHeadCssPrefix(e,t,!1),"tve.css_variable.selector":(e,t)=>TVE.Theme.utils.getHeadCssPrefix(e,t,!1),hover_prefix_selector:(e,t)=>{const i=TVE.inner_$(t);return TVE.PostList.utils.isInsidePostList(i)||(e=TVE.Theme.utils.getHeadCssPrefix(e,i,!0)),e},"tcb.includes":e=>(t.extend(!0,e.Views.Components,i(6872)),t.extend(!0,e.Views.Controls,i(2526)),t.extend(!0,e.renderers,e.Theme.content.renderers()),e.renderers.thrive_author_follow=new(i(7444))({key:"author_follow"}),e.renderers.thrive_author_links=new(i(5011))({key:"author_links"}),e.Theme.views=i(1828),_.each(i(5065),((t,i)=>{e.StorageManager.on(i,t)})),e),"tcb.dragenter":e=>{if(TVE.CONST.theme.is_theme_template){const t=e.parents(TVE.Theme.selectors.editor.compact_elements.join(",")),i=`${TVE.Theme.models.Section.contentSelector},${TVE.Theme.models.HFSection.contentSelector}`,n=e.closest(i);if(TVE.Theme.$wrapper.find(".tve_editor_main_content").removeClass("tve_editor_main_content"),n.length&&(n.addClass("tve_editor_main_content"),TVE.Theme.sectionHover.showIcons(n[0].parentElement,!0)),TVE.Theme.models.Section.is(e))return TVE.Theme.sectionHover.showIcons(e[0],!0),e.find(i).addClass("tve_editor_main_content");if(t.length)return t;if(TVE.Theme.template.isSingular()||TVE.FLAGS.$dragged_element.static_element)return e}return e},should_have_width_on_float:e=>(e.push("thrive-calendar-widget"),e),"tcb.header-footer.root":e=>TVE.Theme.$wrapper,"tcb.get_dropzone_target":e=>((e=TVE.Theme.content.getSectionDropzoneTarget(e)).offset().top+e.height()<TVE.inner.$window.scrollTop()&&TVE.inner_$("html, body").animate({scrollTop:e.offset().top+e.height()}),e),css_rules_before_insert:TVE.Theme.utils.cssRulesBeforeInsert,hover_head_css_selector:e=>(e.selector=TVE.Theme.utils.getHeadCssPrefix(e.selector,TVE.inner_$(e.current_element),!0),e.state_preview_selector=TVE.Theme.utils.getHeadCssPrefix(e.state_preview_selector,TVE.inner_$(e.current_element),!0),e.selector.includes("dynamic-list-icon")&&(e.selector=TVE.Theme.utils.replace_all_but_first(e.selector,'\\[data-css="(.+?)"\\]',""),e.state_preview_selector=TVE.Theme.utils.replace_all_but_first(e.state_preview_selector,'\\[data-css="(.+?)"\\]',"")),e.selector.includes("thrive-dynamic-styled-list-text")&&(e.selector=TVE.Theme.utils.replace_all_but_first(e.selector,TVE.Theme.utils.escapedRegEx(TVE.CONST.global_css_prefix,"g"),""),e.state_preview_selector=TVE.Theme.utils.replace_all_but_first(e.state_preview_selector,TVE.Theme.utils.escapedRegEx(TVE.CONST.global_css_prefix,"g"),"")),e),"theme.set_dynamic_link":e=>("thrive_comments_link"===e.replace(/[\[\]']+/g,"")&&0!==TVE.ActiveElement.parents(TVE.identifier("post_list")).length&&(e="thrive_comments_link list='1'"),e),"tcb.link_read":(e,t)=>(t.attr("data-dynamic-link")&&(e.dynamic_link=!0),e),"tcb.get_link_text":(e,t)=>(t.get("dynamic_link")&&(e="Dynamic"),e),"tcb.insert_section_placeholder":()=>TVE.CONST.theme.is_theme_template,"tcb-social-add-networks":e=>s(s({},e),{},{yt_share:"Youtube",ig_share:"Instagram",tiktok_share:"TikTok"}),"theme.save_shortcodes":e=>(e.find(TVE.identifier("social")).each(((e,t)=>{TVE.inner_$(t).find('[data-href="{tcb_post_url}"]').attr("data-href","[thrive_the_permalink inline='1']")})),e.find(`${TVE.identifier("thrive_author_follow")} .tve_s_item`).each(((e,t)=>{const i=TVE.inner_$(t).find("a"),n=t.dataset.s.replace("_share","");i.attr("href",`[thrive_author_follow_urls url='${"x"===n?"t":n}']`)})),e.find('.thrv_audio[data-type="dynamic"]').each(((e,t)=>t.innerHTML="[thrive_dynamic_audio]")),e),"tcb.templates.before_save":e=>{const t=TVE.inner_$("<div>"+e.get("template_content")+"</div>");return n.shortcodes(t),e.set("template_content",t.html()),e.set("media_rules",TVE.Theme.utils.replaceInSymbolCss(e.get("media_rules"))),e},"tcb.audio_sources":e=>("audio"===TVE.Theme.template.format()&&(e.push({key:"dynamic",name:"Dynamic"}),TVE.AudioProviders.dynamic=TVE.AudioProviders.Base.extend({setChosen:function(){this.control.apply(),this.control.activeView.hide()},getAudio:function(){return""}})),e),editor_loaded_callback:()=>{TVE.Theme.utils.loadingMessage(!1);const e=new URLSearchParams(window.location.href);e.has("from_tar")&&(a.greetingMessage(`<span>Thrive Theme Builder</span>You are now editing the <strong>${TVE.CONST.theme.template.post_title} Template</strong>`,2e3),history.pushState({},document.title,location.pathname+location.search.replace(`&from_tar=${e.get("from_tar")}`,"")))},"tcb.content_templates.data":(e,t)=>(e&&e.media_css&&TVE.main.all_media().forEach((i=>{e.media_css[i]&&(e.media_css[i]=e.media_css[i].split("}").map((e=>e.trim().length?TVE.Theme.utils.templatePrefix(t,e):e)).join("}"))})),e),"tcb.button_extra_styles":e=>(_.isEmpty(TVE.CONST.theme.skin_styles.tve_global_button_styles)||(e=e.concat(Object.values(TVE.CONST.theme.skin_styles.tve_global_button_styles))),e),"tcb.show_dynamic_links":e=>(TVE.Theme.template.isSingular()&&(e=!0),e),"tcb.breadcrumbs.items":(e,t)=>{if(!TVE.main.EditMode.in_edit()){const i=t.parents("#content");i.length&&e.splice(-1,0,{element:i.find(".main-content-background"),edited:!1,name:"Layout Container"})}return e},"tcb.components.hide":(e,t,i)=>("post_content"!==i||"post_content"!==t&&"typography"!==t||TVE.PostList.utils.isInsidePostList(TVE.ActiveElement)||(e=!0),e),"tcb.lazyload.data":e=>(e.is_theme_template=Number(!!TVE.CONST.theme.is_theme_template),e.is_theme_template&&(e.theme_template_id=TVE.CONST.theme.template.ID),e),allow_remove:(e,t)=>{const n=t[0];if(n.is(TVE.identifier("post_content"))&&0===n.closest(TVE.identifier("post_list")).length&&!TVE.Theme.FLAGS.DELETING_POST_CONTENT){if(e=!1,!TVE.Theme.modals.deletePostContentModal){const e=i(102);TVE.Theme.modals.deletePostContentModal=new e({el:TVE.modal.get_element("post-content-delete")})}TVE.Theme.modals.deletePostContentModal.open({$target:n})}return e},"tcb.is_page_fullwidth":e=>(TVE.CONST.theme.is_theme_template&&(e=o.isFullWidth()),e),"tcb.page-map.template":e=>TVE.CONST.theme.is_theme_template?"theme-main/controls/sections-preview":e,"tve.dash.return.save.label":e=>("thrive_template"===TVE.CONST.post.post_type&&(e="Save and Return to Template Dashboard"),e),"tcb.toc.target":()=>".tcb-post-content","tve.toc.should_sync":(e,t)=>(TVE.CONST.theme.is_theme_template&&(e=!1,t.removeAttr("data-target")),e),"tcb.general_pre_save_options":e=>(TVE.CONST.theme.is_theme_template&&(e.forms_filter=(e,t)=>!t.closest(".thrive-shortcode-html,.tcb-post-content,.theme-section[data-id]"),e.post_id=TVE.CONST.theme.template.ID),e),tve_social_networks_items:(e,t)=>("social"===TVE._type(t)&&(e=e.filter((e=>!("yt_share"===e.key||"ig_share"===e.key||"tiktok_share"===e.key)))),e),"tcb.menu.init":e=>e.filter((function(e,t){return!TVE.inner_$(t).parents(".tcb-post-content").length})),"tcb.conditional_display.save_html":e=>{const i=t(`<div>${e}</div>`);return TVE.Theme.content.init_selectors(i),n.elementClasses(i),n.shortcodes(i),i[0].innerHTML}}})(jQuery)},2847:function(e){const t=["theme_button","thrive_comment_reply_button","thrive_comments_form_submit"];e.exports={"tcb.get_global_rules":e=>(e.css=TVE.Theme.utils.replaceThemeSectionsCss(TVE.ActiveElement,e.css),e),"tcb.global_preview_css":e=>(TVE.CONST.theme.is_theme_template&&(e=TVE.Theme.utils.replaceThemeSectionsCss(TVE.ActiveElement,e)),e),"tcb.get_non_global_css_selector":(e,t)=>(t&&(e=TVE.Theme.utils.templatePrefix(t,e)),e),"tcb.copy_styles_different_stylesheet":e=>TVE.USE_GLOBALSHEET?TVE.Theme.utils.replaceThemeSectionsCss(TVE.ActiveElement,e):TVE.Theme.utils.templatePrefix(TVE.ActiveElement,e),global_style_selector:(e,t,i,n)=>(n.is(".theme-button")&&n.attr("data-selector")&&(e=e.replace("."+t,n.attr("data-selector")+"."+t)),TVE.Theme.utils.replaceThemeSectionsCss(TVE.ActiveElement,e)),"tcb.content_selector_prefix":e=>TVE.Theme.utils.templatePrefix(TVE.ActiveElement,e),tcb_shared_styles_elements_types:e=>e.concat(["theme_button"]),tcb_shared_styles_button_types:e=>e.concat(t),"tcb.shared_style.element_type":(e,t)=>(t&&t.is(TVE.Theme.selectors.editor.theme_buttons.join(", "))&&(e="button"),e),"tcb.global_preview_class":(e,t)=>(t.is(".theme-button")&&t.attr("data-selector")&&(e=t.attr("data-selector").replace(/\./g,"")),e),"tcb.copy_stylesheet_rule":(e,t,i)=>{if(!e.includes(i)){const t=TVE.Theme.utils.templatePrefix(TVE.ActiveElement);e=e.includes(t)?e.replace(TVE.Theme.utils.escapedRegEx(t,"g"),i+" ").trim():i+e}return e},"tcb.new_global_style":e=>(TVE.ActiveElement.is(TVE.Theme.selectors.editor.theme_buttons.join(", "))&&(e.attr["data-btn-type"]=TVE._type(TVE.ActiveElement)),e),"tcb.btn_template_list_preview":(e,t)=>{if(t.attr["data-btn-type"]){const i="global-"+t.attr["data-btn-type"].replace(/_/g,"-"),n=TVE.tpl("theme-main/theme-buttons/"+i)({template:t});""!==n&&(e=n)}return e}}},1397:function(e){e.exports={"tcb.inline_shortcodes.shortcode_group":function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];return TVE.Theme.template.isList()&&e.push("Archive"),TVE.Theme.template.isSearch()&&e.push("Search Result Page"),e},"tcb.inline_shortcodes.insert":e=>(TVE.Theme.constants.taxonomyShortcodes.includes(e.key)&&TVE.Theme.CONST.taxonomy[e.key]&&(e.name=TVE.Theme.CONST.taxonomy[e.key]),e),"tcb.inline_shortcodes.shortcode_value":(e,t)=>{if(!["thrive_previous_title_inline_shortcode","thrive_next_title_inline_shortcode"].includes(t.key))return e;if(!e||e===t.shortcodeName){const i=t.configOptions.filter((e=>"default"===e.key))[0];i&&i.value&&(e=i.value)}const i=t.configOptions.filter((e=>"link"===e.key))[0];return i&&"1"===i.value&&(e='<a href="#">'+e+"</a>"),e}}},3717:function(e){function t(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function i(e){for(var i=1;i<arguments.length;i++){var s=null!=arguments[i]?arguments[i]:{};i%2?t(Object(s),!0).forEach((function(t){n(e,t,s[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(s)):t(Object(s)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(s,t))}))}return e}function n(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}e.exports={"theme.update_template.data":e=>i(i({},e),TVE.Lightspeed.getLightspeedData({$content:TVE.Theme.$wrapper}))}},5650:function(e){e.exports={"tcb.breadcrumbs.items":(e,t)=>{if(t.is(TVE.identifier("sidebar-trigger"))){const t=e.shift();e.unshift(t,{edited_element:!1,element:TVE.Theme.$sections.sidebar.find(".section-content"),name:"Sidebar Section"})}return e},"tcb_head_css_prefix|100":(e,t,i)=>((t.is(`${TVE.identifier("sidebar-close-icon")},${TVE.identifier("sidebar-trigger")}`)||i&&void 0!==i["--tve-off-screen-overlay-color"])&&(e=`${TVE.Theme.CONST.body_class} `),e),"tcb.icon.default_size":(e,t)=>(t.is(TVE.identifier("sidebar-close-icon"))&&(e=18),e),"hover_head_css_selector|11":e=>{const t="tve-off-screen-sidebar-trigger";return e.current_element.classList.contains(t)&&(e.selector=`${TVE.CONST.global_css_prefix} ${TVE.Theme.CONST.body_class} .${t}${TVE.state_manager.get_pseudo()}`,e.state_preview_selector=`${TVE.CONST.global_css_prefix} ${TVE.Theme.CONST.body_class} .${t}${TVE.state_manager.css_class()}`),e}}},1445:function(e){const t={"tcb.post_list_extra_elements":e=>(e.push(TVE.Elements.thrive_author_links.tag),e),"tcb.post_list_article.sync.tcb_post_content":(e,t,i)=>(0===i.closest(TVE.identifier("post_list")).length&&0!==TVE.Theme.$wrapper.find(i).length&&(e=`<div>${TVE.PostList.content.getPostContent(t.ID,"content")}</div>`,i.attr("data-size","content")),e),"tcb.post_list.component":function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";return 0===t.length&&(TVE.ActiveElement&&TVE.ActiveElement.length?t=TVE.ActiveElement:TVE.main.EditMode.in_edit()&&TVE.main.EditMode.element()&&(t=TVE.main.EditMode.element())),t&&(t.is(TVE.identifier("blog_list"))||t.closest(TVE.identifier("blog_list")).length)&&(e=TVE.Components.blog_list),e},"tcb.post_list.identifier":(e,t)=>(t.is(TVE.identifier("blog_list"))&&(e=TVE.identifier("blog_list")),e),"tcb.post_list.prefix":(e,t)=>(t.is(TVE.identifier("blog_list"))&&(e=""),e),"tcb.write_css.has_post_list_selector":(e,t)=>(t.includes(TVE.identifier("blog_list"))&&(e=!0),e),"tcb.post_data.existing_post_ids":e=>(TVE.Theme.template.isSingular()&&e.push(parseInt(TVE.Theme.CONST.ID)),e),"tcb.post_list.article_id":(e,t)=>(0===t.closest(TVE.identifier("article")).length&&(e=TVE.Theme.CONST.ID),e),"tcb.post_list.shortcode_tag":(e,t)=>(t.is(TVE.identifier("blog_list"))&&(e="thrive_blog_list"),e),"tcb.show_post_inline_shortcodes":e=>(TVE.Theme.template.isSingular()&&(e=!0),e),"tcb.post_list.query_builder.show_related_taxonomies":()=>TVE.Theme.template.isSingular(),editor_loaded_callback:()=>{TVE.apply_filters("tcb.show_post_list_elements_in_sidebar",TVE.Theme.template.isSingular())&&(TVE.main.sidebar_toggle_elements(_.filter(TVE.Elements,(e=>"Article Components"===e.category)).map((e=>e.tag)),!0),TVE.PostList.EditMode.toggleOnlyListElements(!1)),TVE.Components.post_list.filterPosts=()=>{TVE.Components.post_list.q_modal.$el.toggleClass("blog-list-query",TVE.ActiveElement.is(TVE.identifier("blog_list"))),TVE.Views.Components.post_list.prototype.filterPosts.call(TVE.Components.post_list)}},"tcb.post_list.import.before_css_insert":(e,t)=>{const i=TVE.identifier("blog_list");if(t.is(i)){const n=TVE.identifier("post_list"),s=`[data-css="${t.attr("data-css")}"]`;e=(e=(e=e.replace(TVE.Theme.utils.escapedRegEx(`${n}${s}`,"g"),i)).replace(TVE.Theme.utils.escapedRegEx(`${s}${n}`,"g"),i)).replace(TVE.Theme.utils.escapedRegEx(s,"g"),i),t.attr("data-element-name",(TVE.Theme.template.isSearch()?"Search":"Blog")+" List"),t.removeAttr("data-css"),TVE.head_css_remove(TVE.Theme.utils.escapedRegEx(i,"g"),"_ALL")}return e},tcb_post_list_attr:(e,t,i)=>{if(i){const e=TVE.PostList.utils.getPostListForFeatured(t);e.length&&e.is(TVE.identifier("blog_list"))&&t.attr("data-template-id",TVE.Theme.template.ID)}return e},"theme.convert_section_selector":e=>{const t=TVE.identifier("post_list");return TVE.Theme.template.isSingular()&&!e.includes(t)&&(e=TVE.PostList.dynamicImage.replaceDynamicImage(TVE.Theme.CONST.ID,e)),e},"ttb.css.save.whitelist_rule":(e,t)=>((t.includes(TVE.identifier("post_list"))||t.includes(TVE.identifier("blog_list")))&&t.includes(":nth-child")&&(t=(t=t.replace(/:not\((:nth-child\(.*\))\)/g,"")).replace(/(:nth-child\(.*\))/g,""),TVE.inner.$document.find(t).length&&(e=!0)),e),"tcb.filter_inline_shortcodes.enter":(e,t)=>(TVE.CONST.rememberInlineShortcodes=Object.assign({},e),t.is(TVE.identifier("post_list"))&&(e.Content=_.reject(e.Content,(e=>"thrive_remaining_time"===e.value))),e),"tcb.filter_inline_shortcodes.exit":(e,t)=>(t.is(TVE.identifier("post_list"))&&TVE.CONST.rememberInlineShortcodes&&(e=TVE.CONST.rememberInlineShortcodes),e)};e.exports=t},8583:function(e){jQuery,e.exports={"tcb.inner_actions.right_icons":e=>(e.show_sidebar={name:"eye-regular",fn:"showSidebar",selector:"show_sidebar",property:"show_sidebar",text:"Show Sidebar",textPosition:"left"},e.hide_sidebar={name:"eye-slash-regular2",fn:"hideSidebar",selector:"hide_sidebar",property:"hide_sidebar",text:"Hide Sidebar",textPosition:"left"},e),before_editor_events:()=>{TVE.IconsView=TVE.IconsView.extend({showSidebar:function(){TVE.Theme.utils.getSectionInstance(TVE.Theme.$sections.sidebar).toggle(!0),TVE.Theme.$sections.content.removeClass("content-full-width"),this.afterSidebarToggle()},hideSidebar:function(){TVE.Theme.utils.getSectionInstance(TVE.Theme.$sections.sidebar).toggle(!1),TVE.Theme.$sections.content.addClass("content-full-width"),this.afterSidebarToggle()},afterSidebarToggle:function(){TVE.Theme.utils.getSectionInstance()||TVE.Theme.utils.refreshThemeContainerComponent(TVE.ActiveElement),this.hide_icons()}})},"tcb.inner_actions.hide_icon":(e,t,i)=>{if(["showSidebar","hideSidebar"].includes(t.fn)&&(e=!0,!i.hasClass("tve-off-screen-sidebar-trigger")&&TVE.Theme.models.Section.is(i.parent()))){const n=TVE.Theme.utils.getSectionInstance(i);("showSidebar"===t.fn&&"content"===n.type&&TVE.Theme.models.Layout.isSidebarHidden()||"hideSidebar"===t.fn&&"sidebar"===n.type)&&(e=!1)}return e},"tcb.inner_actions.can_show_icons":(e,t)=>(TVE.Theme.models.Section.is(t)&&(e=!0),e)}},5004:function(e,t,i){(t=>{const n=i(3902);e.exports={"tcb.symbol.before_save":e=>{const i=t("<div>"+e.symbol_content+"</div>");return e.icons=n.icons(i),TVE.Theme.content.init_selectors(i),n.elementClasses(i),n.shortcodes(i),TVE.apply_filters("theme.parse_content",i,"symbol"),e.symbol_content=i.html(),e.symbol_css=TVE.Theme.utils.replaceInSymbolCss(e.symbol_css),e},"tcb.symbol_classes":e=>(TVE.CONST.theme.is_theme_template&&(e+=" tcb-selector-no_clone tcb-selector-no_save"),e),"tcb.symbol_css_before_save":e=>TVE.Theme.utils.replaceInSymbolCss(e),"tcb.symbol.unlink_css":e=>(TVE.Theme.FLAGS.INSIDE_SYMBOL_OVERWRITE=!1,e=e.replace(/\){([^@]*)}/g,((e,t)=>{let i="";return t.split("}").forEach((e=>{e.trim().length&&(i+=TVE.Theme.utils.templatePrefix(TVE.ActiveElement,e)+"}")})),`){ ${i}}`})),delete TVE.Theme.FLAGS.INSIDE_SYMBOL_OVERWRITE,TVE.remove_extra_spaces(e)),"tcb.insert_section_element":(e,t)=>{const i=e.find(".thrv_wrapper");return TVE.PostList.utils.replaceElementTag(i,"<"+t+"></"+t+">"),e},"tve.hf.head_css_selector":(e,t)=>(e.selector&&TVE.ActiveElement&&"header"===TVE._type(TVE.ActiveElement)&&e.selector.includes(TVE.identifier("template-wrapper"))&&(e.selector=e.selector.replaceAll(`.${t}`,"")),e)}})(jQuery)},4671:function(e,t,i){(t=>{const n=i(2952);e.exports={"tcb.element_selected":(e,t)=>("theme_section"===t&&(e=n.parentSection(e)),"template-content"===t&&(e=e.closest("#content")),e),"tcb.bg_effects_elements":e=>e.concat("theme_section"),"tcb.elements.allow_insert_on_click":e=>(TVE.CONST.theme.is_theme_template&&void 0===_.find(TVE.Theme.$sections,(e=>TVE.Theme.utils.canDropIntoSection(e)))&&(e=!1),e),"tcb.change_target":e=>TVE.Theme.content.getSectionDropzoneTarget(e)}})(jQuery)},5442:function(e,t,i){const n=e=>(TVE.main.EditMode&&TVE.main.EditMode.element()&&TVE.main.EditMode.element().is(`${TVE.identifier("product-template")},${TVE.identifier("cart-template")}`)&&(e="#nothing-can-be-dragged"),e),s=()=>TVE.Theme.template.isCart()&&TVE.main.EditMode&&TVE.main.EditMode.element()&&TVE.main.EditMode.element().is(TVE.identifier("cart-template"))&&"desktop"!==TVE.main.device;e.exports={draggable_elements:n,droppable_targets:n,dropzone_elements:n,"theme.section.data.extra":e=>{if(TVE.Theme.template.isShop(!0)){const t=new(i(6990)(TVE.inner_$,TVE.inner.window));e.posts_per_page=t.getData("posts_per_page"),e.ordering=`${t.getData("orderby")}-${t.getData("order")}`}if(TVE.Theme.template.isCheckout()){let t=JSON.parse(JSON.stringify(TVE.CONST.woo.checkout_fields));t=t.map((e=>_.omit(e,["sortable","toggleable","label","required"]))),e.checkout_field_data=t}return e},"tcb.inline_shortcodes.shortcode_value":(e,t)=>{if(TVE.Theme.template.isShop()&&!TVE.PostList.utils.isInPostListEditMode())switch(t.extra_key){case"the_ID":e=TVE.CONST.woo.shop_id;break;case"the_title":e=TVE.CONST.woo.shop_title;break;case"permalink":e=TVE.CONST.woo.shop_url}return e},"tve.shortcode.options.html":(e,t)=>{if(TVE.Theme.template.isShop()&&"Content"===t&&!TVE.PostList.utils.isInPostListEditMode()){const t=TVE.$(`<div>${e}</div>`);t.find("option").each(((e,t)=>{switch(t.dataset.extraKey){case"the_ID":t.text="Shop ID";break;case"the_title":t.text="Shop title";break;case"permalink":t.text="Shop URL";break;default:t.remove()}})),e=t.html()}return e},"tcb.inline_shortcodes.afterInsert":(e,t)=>{if(TVE.Theme.template.isShop()&&!TVE.PostList.utils.isInPostListEditMode()){let i="";switch(t.extra_key){case"the_ID":i="thrive_woocommerce_shop_id";break;case"the_title":i="thrive_woocommerce_shop_title";break;case"permalink":i="thrive_woocommerce_shop_url"}i&&e.find("[data-shortcode]").attr("data-shortcode",i)}return e},tcb_read_element_type:(e,t)=>(TVE.Theme.utils.getWooElement(t)&&!t.is(TVE.identifier("shop-template"))&&(e+="-template"),e),"tcb.cloud_templates.before_css_insert":(e,t)=>{if(TVE.Theme.template.isShop(!0)&&t.is(TVE.identifier("shop"))){const i=`[data-css="${t.attr("data-css")}"]`,n=`${TVE.identifier("shop")}${i}`,s=TVE.identifier("shop-template");e=(e=e.replace(TVE.Theme.utils.escapedRegEx(n,"g"),s)).replace(TVE.Theme.utils.escapedRegEx(i,"g"),s),t.removeAttr("data-css")}return e},"tcb.cloud_templates.element_name":(e,t)=>(TVE.Theme.constants.WOO_ELEMENTS.includes(t.replace("-template",""))&&(e=TVE.Elements[t]&&TVE.Elements[t].name),e),"tcb.woocommerce.shop_selector":(e,t)=>(t.closest(TVE.identifier("shop-template")).length>0&&(e=TVE.identifier("shop-template")),e),"tcb.woocommerce.shop_identifier":(e,t)=>{const i=".shop-template-wrapper";return t?t.closest(i).length>0&&(e=i):e=`.shop-template-wrapper,${e}`,e},"theme.is_element_inside_symbol":(e,t)=>{if(t){const i=t.closest(".tcb-woo-mini-cart-content-wrapper");i.length&&void 0!==i.attr("data-symbol-id")&&(e=!0)}return e},"theme.css.change_prefix_target":e=>{const t=e.closest(".tcb-woo-mini-cart-content-wrapper");return t.length>0&&(e=t.data("source")),e},"theme.sections_modal.available_sections":(e,t)=>(e&&TVE.Theme.template.isProduct()&&"content"===t&&(e=e.filter((e=>"local"===e.source))),e),"tcb.reset-state.rules_to_reset":(e,t,i,n)=>{if(["wc-product-main-add-to-cart","wc-place-order-button","wc-cart-apply-coupon","wc-cart-update-button","wc-cart-related-product-button","wc-cart-to-checkout-button"].includes(TVE._type(t))){const s=TVE.escapedRegEx(t.attr("data-selector")).toString().slice(0,-1).slice(1);e={from:new RegExp(`${s}.*(\\.tve-state-${i}|:${i})`),to:new RegExp(`${s}.*(\\.tve-state-${n}|:${n})`)}}return e},"tcb.cloud_template_download_params":e=>(TVE.Theme.template.isWoo()&&(e.data.query_vars=TVE.Theme.CONST.query_vars),e),"tcb.show_icons.target":(e,t)=>(t.target&&s()&&"TD"===t.target.tagName&&(t.target.classList.add("tve_no_icons","tcb-no-title"),e=TVE.inner_$(t.target)),e),"tcb.selection.element":(e,t)=>{const i=TVE.inner_$(t.target);return t.target&&s()&&"TD"===t.target.tagName&&(i.closest(".cart_totals").length>0&&(e=TVE.inner_$(t.target.previousElementSibling)),i.closest(".cart_item").length>0&&(e=TVE.inner_$(TVE.identifier("wc-cart-table-headers")).first())),e}}},8766:function(e){let t=null;e.exports=TVE.modal.base.extend({is_valid:!0,invalid_inputs:[],has_fixed_footer:function(){return!0},render_errors:function(){this._get_fields_container().empty(),_.each(this.model.attributes,(function(e,t,i){this.render_error({key:t,value:e,label:TVE.CONST.theme.comments_form.error_defaults[t]})}),this)},restore_defaults:function(){_.each(TVE.CONST.theme.comments_form.error_defaults,(function(e,t,i){this._set(t,e)}),this),this.render_errors()},change:function(e,t){const i=t.value,n=t.getAttribute("data-key");this._set(n,i)},input:function(e,t){if(t.classList.contains("tcb-invalid")){t.classList.remove("tcb-invalid");const e=jQuery(t).next().removeClass("tcb-invalid");e.text(e.data("label"))}},_set:function(e,t){return this.model.set(e,t),!0},_get_fields_container:function(){return this.$container||(this.container=this.$(".tcb-fields-error").first()),this.container},render_error:function(e){const t=TVE.tpl("lead-generation/errors/item");e=e||{},e=_.extend({key:"key",label:"label",value:"value"},e),this._get_fields_container().append('<div class="col-xs-6">'+t({item:e})+"</div>")},save:function(e){if("function"==typeof this.before_save&&this.before_save.call(this,e),!1===this.is_valid)for(const e in this.invalid_inputs){const t=this.$('input[name="'+this.invalid_inputs[e]+'"]').addClass("tcb-invalid").next("label");t.addClass("tcb-invalid").attr("data-label",t.text().trim()).html(TVE.ucFirst(this.invalid_inputs[e]+" error is required"))}else this.close(),this.undelegateEvents(),e.preventDefault();return!1}},{get_instance:function(e,i){return t||(i||(i=new Backbone.Model),t=new TVE.CommentsErrorMessages({el:e,model:i})),t}})},1378:function(e,t,i){const n=i(3724),s=TVE.modal.base.extend({after_initialize:function(){this.$el.addClass("ttd-templates-modal"),this.$layoutName=this.$(".new-template-name")},before_open:function(){this.$layoutName.val("")},save:function(){const e=this.$layoutName.val();e&&n.getInstance().save(e,(()=>{this.close()}))}});e.exports=new s({el:TVE.modal.get_element("layout-templates")})},102:function(e){e.exports=TVE.modal.base.extend({after_initialize:function(){this.$el.addClass("medium-small")},after_open:function(e){this.$target=e.$target},deletePostContentElement:function(){this.close(),TVE.Theme.FLAGS.DELETING_POST_CONTENT=!0,TVE.Editor_Page.remove_element(this.$target),delete TVE.Theme.FLAGS.DELETING_POST_CONTENT}})},5200:function(e){var t;t=jQuery,e.exports=TVE.modal.base.extend({after_initialize:function(){this.$el.addClass("medium-small")},reset:function(){this.$el.addClass("ttd-loading"),t.ajax({url:`${TVE.CONST.theme.routes.templates}/${TVE.CONST.post.ID}`,type:"POST",data:{action:"reset_template"},headers:{"X-WP-Nonce":TVE.CONST.rest_nonce}}).done((e=>{let t=0;e.success||!1!==e.success||(TVE.page_message(e.message,!0,5e3),t=4),setTimeout((()=>location.reload()),t)})).fail((()=>TVE.page_message("Unable to reset template",!0,5e3))).always((()=>this.$el.removeClass("ttd-loading")))}})},6802:function(e){var t;t=jQuery,e.exports=TVE.modal.base.extend({after_initialize:function(){this.$sectionName=this.$(".new-section-name"),this.$sectionType=this.$(".new-section-type"),t(this.el).addClass("modal-w-sidebar"),this.$imageContainer=this.$(".section-preview-image"),this.$image=this.$imageContainer.find("img")},before_open:function(e){this.section=e.section;const t=TVE.ucFirst(this.section.type);this.$section=this.section.$element,this.$sectionName.val(`Custom ${TVE.ucFirst(this.section.type)} Section`).trigger("focus"),this.$sectionType.html(t),this.$el.toggleClass("vertical-sections",this.section.isVertical()),this.beforeImageLoad()},after_open:function(){setTimeout((()=>{const e=this.section.getContentToPreview();TVE.generateElementPreview(e,(t=>{e.parent(`.${TVE.Theme.constants.PREVIEW_SECTION_WRAPPER_CLASS}`).remove(),this.afterImageLoad(t)}),TVE.Theme.constants.defaultPreviewOptions,!0)}),10)},beforeImageLoad:function(){const e=this.$section.outerWidth(!0);let t,i;this.section.isHorizontal()?(t=TVE.Theme.constants.HORIZONTAL_LAYOUT_WIDTH-TVE.Theme.constants.HORIZONTAL_LAYOUT_PADDING,i=this.$section.outerHeight(!0)*t/e):(t=TVE.Theme.constants.VERTICAL_LAYOUT_WIDTH-TVE.Theme.constants.VERTICAL_LAYOUT_PADDING,i=TVE.Theme.constants.SIDEBAR_CROPPED_HEIGHT),this.$imageContainer.addClass("ttd-loading-spinner").css({height:i+"px",width:t+"px"}),this.$image.attr("src",this.$image.attr("data-loading-src"))},afterImageLoad:function(e){this.$imageContainer.removeClass("ttd-loading-spinner").css({height:"",width:""}),this.$image.attr("src",e),this.section.previewImage=e},save:function(){if(!this.duringAjax){const e=this.$sectionName.val();e?(this.duringAjax=!0,this.section.save(e,(e=>{this.close()})).always((()=>{this.duringAjax=!1}))):TVE.page_message("Please enter the section title!",!0,3e3)}}})},7287:function(e){function t(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function i(e){for(var i=1;i<arguments.length;i++){var s=null!=arguments[i]?arguments[i]:{};i%2?t(Object(s),!0).forEach((function(t){n(e,t,s[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(s)):t(Object(s)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(s,t))}))}return e}function n(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}var s;s=jQuery,TVE.BlockModal&&(e.exports=TVE.BlockModal.extend({blocksCollection:new Backbone.Collection({}),item_template:TVE.tpl("theme-main/template-item"),itemClass:".section-template-item ",filters:{category:[],group:[],search:[]},groupMap:{},tooltipOpen:!1,renameInProgress:!1,after_initialize:function(){this.$content=this.$el,this.$content.addClass("modal-w-sidebar"),this.$cloudMenu=this.$("#cb-cloud-menu"),this.$packTitle=this.$("#lp-blk-pack-title"),this.$packDescription=this.$("#lp-blk-pack-description"),this.$packContent=this.$("#cb-pack-content"),this.$packGroupsWrapper=this.$("#lp-groups-wrapper"),this.$error=this.$(".error-container").hide(),window.addEventListener("resize",(()=>{this.windowResized=!0})),this.initClickHandler()},before_open:function(e){this.resetFilters(),this.section=e.section,this.$el.attr("data-columns",this.section.isHorizontal()?2:4),this.$packContent.empty(),this.$section=e.section.$element,this.displayName=TVE.ucFirst(this.section.type),this.groupMap={cloud:{key:`Theme ${this.displayName} Sections`},local:{key:`My Saved ${this.displayName} Sections`}},this.$packTitle.text(`${this.displayName} Sections`),this.$packDescription.text(`${this.displayName} Sections available for the current theme.`),this.$el.addClass("loading"),this.$(".tve-modal-content").attr("class",`tve-modal-content tpl-${this.section.type}`),this.currentSectionTemplate=this.section.ID,TVE.do_action("theme.sections_modal.before_open",this)},initClickHandler:function(){this.$el.on("click",(e=>{const t=s(e.target);this.tooltipOpen&&0===t.closest(".tcb-template-options-tooltip, .ttd-dropdown-dots").length?this.closeOptionsTooltip():this.renameInProgress&&0===t.closest(".template-name-section-edit, .tcb-template-options-tooltip").length&&this.triggerRename()}))},triggerRename(){const e=this.$packContent.find(".section-template-edit");e.length>0&&e.find(".template-name-check").click()},handle_keyup:function(e){if(this.renameInProgress)switch(e.which){case 13:this.triggerRename();break;case 27:this.closeRename()}return!1},after_open:function(e){s.when(e.sectionsLoaded).always((()=>setTimeout((()=>{this.$el.removeClass("loading")}),80))).then((()=>{this.setSections(),this.activateFirstTab(),TVE.BlockModal.prototype.after_open.call(this)})).catch((e=>{this.$error.fadeIn(200).html(TVE.tpl("inline-error")({error_message:e}))}))},setSections:function(){let e=[...this.addSourceToTemplates(TVE.Theme.data.cloud[this.section.type],"cloud"),...this.addSourceToTemplates(TVE.Theme.data.local[this.section.type],"local")];e=TVE.apply_filters("theme.sections_modal.available_sections",e,this.section.type),e=this.addThumbnailRatios(e),this.blocksCollection.reset(e),this.groups={[this.groupMap.cloud.key]:{counter:_.filter(e,(e=>"cloud"===e.source)).length},[this.groupMap.local.key]:{counter:_.filter(e,(e=>"local"===e.source)).length}},this.$packGroupsWrapper.empty(),_.each(this.groups,((e,t)=>{this.$packGroupsWrapper.append(this.group_item({group:t,counter:e.counter}))}))},getCurrentSectionTemplate:function(){return this.currentSectionTemplate},activateFirstTab:function(){this.filters.group.push(this.groupMap.cloud.key),this.$packGroupsWrapper.find(".lp-group").first().addClass("active")},load:function(e,t){this.close();const i=t.dataset.id.replace(t.dataset.source[0],"");this.section.load(i,t.dataset.source,t.dataset.version)},openRename:function(e){const t=s(e.target).closest(this.itemClass);t.addClass("section-template-edit").find(".template-rename-input").focus().select(),this.closeOptionsTooltip(),this.renameInProgress=t.attr("data-id")},closeRename:function(){let e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];const t=this.$(this.itemClass.trim()+`[data-id="${this.renameInProgress}"]`),i=t.find(".template-rename-input"),n=t.find(".template-name");t.removeClass("section-template-edit").find(".template-name-check").removeClass("ttd-loading small"),e?i.val(n.text()):n.text(i.val())},renameSection:function(e){const t=s(e.target).closest(".template-name-check"),i=t.closest(this.itemClass),n=t.prev(".template-rename-input").val();t.addClass("ttd-loading small"),n?this.duringAjax||(this.duringAjax=!0,TVE.$.ajax({url:`${TVE.CONST.theme.routes.sections}/${i.attr("data-id").substring(1)}`,type:"POST",data:{title:n},headers:{"X-WP-Nonce":TVE.CONST.rest_nonce}}).done((e=>{TVE.Theme.utils.loadingMessage("Section renamed successfully!"),setTimeout((()=>TVE.Theme.utils.loadingMessage(!1)),1e3),this.closeRename(!1);const t=_.findWhere(TVE.Theme.data.local[this.section.type],{id:parseInt(e)});t&&(t.name=n),TVE.Components.theme_section.sectionSelect.section||TVE.Components.theme_section.sectionSelect.setSection(TVE.Theme.utils.getSectionInstance(TVE.ActiveElement)),TVE.Components.theme_section.sectionSelect.update()})).always((()=>{this.duringAjax=!1,this.renameInProgress=!1}))):TVE.page_message("Please enter a section title!",!0,3e3)},openDelete:function(e){s(e.target).closest(this.itemClass).addClass("section-template-delete").find(".cb-template-wrapper").removeClass("click"),this.closeOptionsTooltip()},hideDelete:function(e){s(e.target).closest(this.itemClass).removeClass("section-template-delete")},delete:function(e){const t=e.target,i=parseInt(t.dataset.id.substring(1));i&&!this.duringAjax&&(this.duringAjax=!0,this.section.delete(i).done((e=>{this.blocksCollection.remove(this.blocksCollection.get(i)),s(t).closest(this.itemClass).remove();const n=this.$packGroupsWrapper.find(".active .lp-group-count"),o=parseInt(n.text())-1;n.text(o),o>0?this.applyMasonry():this.$packContent.html(this.no_templates())})).always((()=>{this.duringAjax=!1})))},openOptionsTooltip:function(e){s(e.target).closest(".template-name-section").toggleClass("tooltip-open"),this.tooltipOpen=!0},closeOptionsTooltip:function(){this.tooltipOpen&&(this.$packContent.find(".tooltip-open").removeClass("tooltip-open"),this.tooltipOpen=!1)},addSourceToTemplates:function(e,t){return _.map(_.sortBy(e,(e=>e.order)),(e=>i(i({},e),{},{id:`${t[0]}${e.id}`,source:t,group:[this.groupMap[t].key],name:e.name||e.post_title})))},addThumbnailRatios:function(e){return e.map((e=>{let t=1;if(e.thumb&&e.thumb.w&&e.thumb.h){const i=parseInt(e.thumb.w),n=parseInt(e.thumb.h);t=parseFloat(n/i).toFixed(3)}return e.ratio=t,e}))},no_templates:function(){return TVE.tpl("theme-main/no-sections-available")({modal:this})},renderFirstTab:function(){this.resetFilters(),this.activateFirstTab(),this.build_preview()},getMasonryOptions:function(){return{gutter:".tpl-gutter-sizer",columnWidth:this.itemClass,isAnimated:!0}}}))},9941:function(e){e.exports=TVE.modal.base.extend({after_initialize:function(){this.$el.addClass("medium-small")},after_open:function(e){this.href=e.href,this.context=e.context},continueWithoutSaving:function(){window.onbeforeunload=null,this.close(),window.location=this.href},saveAndContinue:function(){window.onbeforeunload=null,this.close();const e=()=>{window.location=this.href};this.context===TVE.Theme.constants.THEME_CONTEXT?TVE.Theme.content.save(e,!0,!1):this.context===TVE.Theme.constants.ARCHITECT_CONTEXT&&TVE.Editor_Page.save(!0,e,{},!0)}})},569:function(e,t,i){e.exports={Content:i(3902),Layout:i(3724),Section:i(2952),HFSection:i(2806),Template:i(2147)}},6780:function(e){function t(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function i(e){for(var i=1;i<arguments.length;i++){var s=null!=arguments[i]?arguments[i]:{};i%2?t(Object(s),!0).forEach((function(t){n(e,t,s[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(s)):t(Object(s)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(s,t))}))}return e}function n(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}e.exports=class{static get identifier(){return""}static get component(){throw Error("Class should implement component function")}get selector(){return""}get baseSelector(){return""}static get contentSelector(){return""}static get backgroundSelector(){return""}isHorizontal(){throw Error("Class should implement the isHorizontal function")}isVertical(){throw Error("Class should implement the isVertical function")}constructor(e){this.$element=e,this.ID=parseInt(this.attr("data-id")||0),this.type=this.attr("data-section")||TVE._type(e),TVE.Theme.data.local[this.type]&&TVE.Theme.data.local[this.type][this.ID]&&(this.sectionData=TVE.Theme.data.local[this.type][this.ID]),this.setElements()}setElements(){this.$content=this.$element.find(this.constructor.contentSelector),this.$background=this.$element.find(this.constructor.backgroundSelector)}updateAttr(){this.$element.attr("data-selector",this.selector),this.isDynamic()?(this.$content.attr("data-selector",`${this.constructor.contentSelector}`),this.$background.attr("data-selector",`${this.constructor.backgroundSelector}`)):(this.$content.attr("data-selector",`${this.baseSelector} ${this.constructor.contentSelector}`),this.$background.attr("data-selector",`${this.baseSelector} ${this.constructor.backgroundSelector}`))}beforeUnlink(){"function"==typeof TVE.Components.lead_generation.removeSettingsId&&TVE.Components.lead_generation.removeSettingsId(this.$element)}afterUnlink(){TVE.do_action("theme.section.after_unlink",this)}isDynamic(){return!!this.ID}isVisible(){return!this.$element.hasClass(TVE.Theme.constants.identifiers.HIDE_SECTION_CLASS)}toggle(){let e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];if(this.$element.toggleClass(TVE.Theme.constants.identifiers.HIDE_SECTION_CLASS,!e),"sidebar"===this.type){const t=TVE.inner.window.ThriveTheme.sidebar;t.isOffScreen()&&(e?t.offScreenRefresh():t._get("off-screen").destroy()),TVE.Theme.content.updateResizeHandlersPosition(),TVE.inner.window.TCB_Front.resizePageSection(),TVE.PostList.layout.masonryRedo()}this.constructor.component.controls.PageMap.update(this.$element),this.constructor.is(TVE.ActiveElement)&&this.constructor.component.update(TVE.ActiveElement)}isContent(e){return e.is(this.$content)}isBackground(e){return e.is(this.$background)}inEditMode(){return this.$element.hasClass("tcb-compact-edit-mode")}inheritsContent(){return 0===TVE.Theme.$wrapper.tcbCss(`--${this.type}-content-width`).length}setWidth(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",i=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];const n=`--${this.type}-${t}-width`;i?(TVE.Theme.$wrapper.head_css({[n]:e}),TVE.Theme.$wrapper.tcbCss(n,"")):TVE.Theme.$wrapper.tcbCss(n,e)}getWidth(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"content";return TVE.Theme.$wrapper.tcbCss(`--${this.type}-${e}-width`)}hasFullWidthContent(){return"100%"===this.getWidth("content")}hasFullWidthBackground(){return"100%"===this.getWidth("background")}startPreview(){this.$element.addClass("tcb-generating-preview"),this.constructor.component.sectionSelect.showPreviewLoader()}applyPreview(e){this.$element.removeClass("tcb-generating-preview section-no-overlay"),e.url=e.url+"?v="+Math.random().toString(16).slice(2),TVE.Theme.data.local[this.type]&&TVE.Theme.data.local[this.type][this.ID]&&(TVE.Theme.data.local[this.type][this.ID].thumb=e),this.sectionData&&this.sectionData.thumb&&(this.sectionData.thumb=e),this.constructor.component.sectionSelect.setSection(this).update()}generatingPreview(){return this.$element.hasClass("tcb-generating-preview")}attr(e){return this.$element.attr(e)}name(){let e=`Unlinked ${this.type}`;return e=this.sectionData?this.sectionData.name:this.attr("data-section-name")||e,e}preview(){let e="";return this.sectionData&&this.sectionData.thumb&&(e=this.sectionData.thumb.url),e}beforeSave(e){this.ID=parseInt(e),this.updateAttr(),this.convertCssToSection()}afterSave(){this.focus(),TVE.Theme.utils.loadingMessage(!1,"save-section"),this.constructor.saveTemplate(!0,!1)}beforeInsert(e){TVE.do_action("theme.section.before_insert",e,this),TVE.do_action(`theme.section.before_insert.${this.type}`,e,this);const t=(this.isDynamic()?"":TVE.Theme.CONST.body_class+" ")+this.selector;TVE.head_css_remove(TVE.Theme.utils.escapedRegEx(t,"g"),"_ALL"),this.ID=parseInt(e.id),TVE.Theme.FLAGS.duringImport=!0}afterInsert(e){TVE.Theme.FLAGS.duringImport=!1,TVE.froala.init(),this.focus(),TVE.Theme.content.init_selectors(this.$element),this.constructor.saveTemplate(!0),TVE.do_action("theme.section.after_insert",e,this),TVE.do_action(`theme.section.after_insert.${this.type}`,e,this),TVE.do_action("tcb.new-editor-content",this.$element),TVE.Theme.utils.loadingMessage(!1),this.bindElementActions(),TVE.inner.window.TCB_Front.$window.trigger("tve_after_content_toggle",[this.$element]),TVE.inner.window.TCB_Front.icons.migrate(this.$element)}convertCssToTemplate(e){void 0===e&&(e=TVE.stylesheet.cssRules);for(let t=0;t<e.length;t++){const n=TVE.compat.conditionText(e[t]),s={};if(e[t].type===CSSRule.MEDIA_RULE&&n&&n.length){for(let n=0;n<e[t].cssRules.length;n++){let o=e[t].cssRules[n].selectorText;o.includes(this.selector)&&(o=o.replace(TVE.Theme.utils.escapedRegEx(`${this.selector}`,"g"),`${TVE.Theme.CONST.body_class} ${this.baseSelector}`),o=TVE.apply_filters("theme.convert_section_selector",o),void 0===s[o]&&(s[o]={}),s[o]=i(i({},s[o]),TVE.CSS_Rule_Cache.cssToObject(e[t].cssRules[n].cssText)),e[t].deleteRule(n--))}for(const e in s)TVE.head_css(e,s[e],n)}}}convertCssToSection(e){void 0===e&&(e=TVE.stylesheet.cssRules);for(let t=0;t<e.length;t++)if(e[t].type===CSSRule.MEDIA_RULE)for(let i=0;i<e[t].cssRules.length;i++){const n=e[t].cssRules[i];if(n.selectorText.includes(this.baseSelector)){const s=n.cssText.replace(TVE.Theme.utils.escapedRegEx(`${TVE.Theme.CONST.body_class} ${this.baseSelector}`,"g"),this.selector);e[t].deleteRule(i),e[t].insertRule(TVE.remove_extra_spaces(s),i)}}}getContentToPreview(){const e=this.$element.clone(),t=this.$element.width(),i=t*(this.isHorizontal()?1:2);let n=t;return TVE.Theme.utils.fixClonedImageHeights(e,this.$element),"sidebar"===this.type&&TVE.inner.window.ThriveTheme.sidebar.isOffScreen()&&n>=TVE.Theme.constants.SIDEBAR_MAXIMUM_PREVIEW_WIDTH&&(n=TVE.Theme.constants.SIDEBAR_MAXIMUM_PREVIEW_WIDTH),"top"!==this.type&&"bottom"!==this.type||this.hasFullWidthBackground()||(n=this.$content.outerWidth()),e.attr("style",`display:block !important; position:absolute !important; width: ${n}px !important;`).wrap(`<div class="${TVE.Theme.constants.PREVIEW_SECTION_WRAPPER_CLASS}"></div>`).parent().attr("style",`position: absolute !important; top: -100000px !important; width: ${t}px !important`).insertAfter(this.$element),e.removeClass("edit_mode layout-highlight"),e.children(".ui-resizable-handle").remove(),TVE.Theme.utils.filterContentToPreview(e),TVE.Theme.utils.filterContentByHeight(e.find(this.constructor.contentSelector),i),e}toggleComponents(){}focus(){TVE.Editor_Page.focus_element(this.$element.removeClass("edit_mode"))}static saveTemplate(){let e=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];arguments.length>0&&void 0!==arguments[0]&&arguments[0]||TVE.Theme.utils.loadingMessage("Updating also the template!","save-template"),TVE.Theme.content.save((()=>{TVE.Theme.utils.loadingMessage(!1,"save-template")}),!0,e)}static is(e){return e.is(this.identifier)}static parentSection(e){return e&&e.closest(this.identifier)}static getInstance(e){let t=null;if(void 0===e&&(e=TVE.ActiveElement),(this.is(e)||(e=this.parentSection(e)).length)&&(t=new this(e)),null===t)throw Error("Those are not the sections you're looking for!");return t}static getTemplateId(){return 0}static fetchListFromCloud(e){const t=TVE.$.Deferred();return TVE.Theme.data.cloud[e]?setTimeout((()=>{t.resolve(TVE.Theme.data.cloud[e])}),1):TVE.$.ajax({url:`${TVE.CONST.theme.routes.sections}/cloud`,type:"GET",data:TVE.apply_filters("theme.sections.cloud_fetch_list_args",{type:e,template_id:this.getTemplateId()}),headers:{"X-WP-Nonce":TVE.CONST.rest_nonce}}).done((i=>{i.success?(TVE.Theme.data.cloud[e]=i.data,t.resolve(i.data)):t.reject("The sections could not be retrieved")})).fail((e=>{e.responseJSON&&t.reject(e.responseJSON.message)})),t.promise()}delete(e){return TVE.$.ajax({url:TVE.CONST.theme.routes.sections+"/"+e,type:"DELETE",headers:{"X-WP-Nonce":TVE.CONST.rest_nonce},data:{type:this.type}}).done((()=>{delete TVE.Theme.data.local[this.type][e],parseInt(this.ID)===parseInt(e)&&this.unlink(!0),TVE.StorageManager.set("theme_section.remove",{id:e,type:this.type}),TVE.Theme.utils.loadingMessage("Section deleted successfully!"),setTimeout((()=>TVE.Theme.utils.loadingMessage(!1)),1e3)})).fail((e=>{TVE.wordfenceResponse(e)||TVE.page_message("Error deleting the section!",!0,3e3)}))}unlink(){throw Error("Class should implement the unlink function")}bindElementActions(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.$element;TVE.drag.bind_element(e)}}},3902:function(e){function t(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function i(e){for(var i=1;i<arguments.length;i++){var s=null!=arguments[i]?arguments[i]:{};i%2?t(Object(s),!0).forEach((function(t){n(e,t,s[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(s)):t(Object(s)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(s,t))}))}return e}function n(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}class s{constructor(e){this.$content=e}data(){const e=TVE.Theme.utils.getSpecificStyle((e=>!e.includes(TVE.identifier("symbol"))&&e.includes(TVE.Theme.CONST.body_class))),t=s.icons(this.$content),n=s.clean(this.$content);return s.elementClasses(n),TVE.apply_filters("theme.parse_content",n,"template"),i(i({icons:t,style:e,layout:s.getLayoutId(),layout_data:TVE.Theme.template.getLayoutDataToSave(),structure:this.structure(n),tve_globals:s.getGlobals()},s.extraData(this.$content)),{},{sections:this.saveSections(n)})}static clean(e){TVE.Components.pagination.cleanFroalaContent(e),e=TVE.inner_$(`<div>${TVE.Editor_Page.content_manager.get_clean_content({},e)}</div>`);const t=["edit_mode","on_hover","active_highlight","tve-droppable","tve-draggable","tcb_similar_edit","tcb-compact-edit-mode"],i=new RegExp([".top-",".bottom-",".sidebar","#content",".main-container","thrv_header","thrv_footer"].join("|"),"g");return["data-selector","draggable"].forEach((t=>e.find(`[${t}]`).each(((e,t)=>{i.test(t.dataset.selector)&&t.removeAttribute("data-selector")})))),e.find("."+t.join(",.")).removeClass(t.join(" ")),e.find(".thrv_widget").children(":not(.widget-config)").remove(),e.find(TVE.Theme.selectors.removeOnSave.join(",")).remove(),e}static shortcodes(e){(e=TVE.apply_filters("theme.save_shortcodes",e)).find(".thrive-shortcode").each(((e,t)=>{let i=t.dataset.shortcode;if(i){const e=TVE.Theme.utils.element_attributes(t,["data-shortcode","data-selector"],!0,!0),n=t.getAttribute("id");n&&(e.id=n),_.each(e,((e,t)=>{e=e.replace(/\'/g,"__SHORTCODE_SINGLE_QUOTE__"),i+=` ${t}='${e}'`})),TVE.inner_$(t).replaceWith(`[${i}]`)}})),e.find('[data-dynamic-link!=""][data-dynamic-link]:not(.tve-dynamic-link)').each(((e,t)=>{t.href=TVE.Theme.utils.applyBrackets(t.getAttribute("data-dynamic-link"))})),TVE.PostList.dynamicImage.saveDynamicImageSources(e),e.find(".wrapper-shortcode").each(((e,t)=>{const i=t.dataset.shortcode;let n=t.dataset.css?` data-css=${t.dataset.css}`:"";if(i.length){const e=TVE.inner_$(t);n=TVE.apply_filters("ttb.wrapper_shortcode.attributes",n,e,i),e.replaceWith(`[${i}${n}]${t.innerHTML}[/${i}]`)}}))}structure(e){return void 0===e&&(e=TVE.Theme.$wrapper.clone()),(e=s.clean(e)).find(`.main-content-background, ${TVE.Theme.constants.identifiers.MAIN_COLUMNS_SEPARATOR}`).remove(),e.find(`${TVE.Theme.models.Section.identifier}`).each(((e,t)=>{const i=TVE.inner_$(t),n=parseInt(t.dataset.id),s={type:i.attr("data-section")},o=["[thrive_template_section"];n&&o.push(`id="${n}"`),_.each(s,((e,t)=>{o.push(`${t}="${e}"`)})),o.push("]"),i.replaceWith(o.join(" "))})),e.find(TVE.identifier("main-container")).each(((e,t)=>{TVE.inner_$(t).replaceWith(`[thrive_main_container]${t.innerHTML}[/thrive_main_container]`)})),e.find("#content").each(((e,t)=>{TVE.inner_$(t).replaceWith(`[thrive_template_content]${t.innerHTML}[/thrive_template_content]`)})),e.html()}static elementClasses(e){e.find(".thrive-shortcode.tve_evt_manager_listen, .thrive-shortcode .tve_evt_manager_listen").each(((e,t)=>{t.setAttribute("data-class",TVE.PostList.utils.getEventClasses(t.className));const i=t.getAttribute("data-tcb-events");i&&t.setAttribute("data-tcb-events",i.replace(/\[/g,"|{|").replace(/\]/g,"|}|"))})),e.find(".tcb-desktop-hidden, .tcb-tablet-hidden, .tcb-mobile-hidden").each(((e,t)=>{const i=TVE.Theme.utils.getElementResponsiveClasses(t);let n=t.dataset.class?t.dataset.class:"";i.forEach((e=>{n.includes(e)||(n+=` ${e}`)})),t.setAttribute("data-class",n)})),e.find('[data-class*="-hidden"]').each(((e,t)=>{let i=t.dataset.class;const n=i.match(/(tcb-\w*-hidden)/g);n&&n.forEach((e=>{t.classList.contains(e)||(i=i.replace(e,""))})),t.setAttribute("data-class",i.trim())}))}static extraData(e){const t={"sidebar-type":TVE.Theme.$sections.sidebar.attr("data-display-type")||"","sticky-sidebar":TVE.Theme.$sections.sidebar.attr("data-sticky")||"","off-screen-sidebar":TVE.Theme.$sections.sidebar.attr("data-off-screen")||""},i=e.find(TVE.Theme.constants.blog_list.no_results.selector);if(TVE.Theme.template.isSearch()&&i.length>0){const e=TVE.inner_$(`<div>${i[0].outerHTML.replace("tcb-permanently-hidden","")}</div>`);t.no_search_results=TVE.Editor_Page.content_manager.get_clean_content({},e)}return t}saveSections(e){const t={};return e.find(TVE.Theme.models.Section.identifier).each(((e,n)=>{const s=TVE.inner_$(n),o=TVE.Theme.models.Section.getInstance(s),a=o.type;TVE.Theme.savedSection=a,o.isDynamic()?t[a]={id:o.ID}:t[a]=i({id:0,content:o.getContent()},o.getExtra()),t[a].hide=n.classList.contains("hide-section")?1:0})),[TVE.Theme.$sections.header,TVE.Theme.$sections.footer].forEach((e=>{const i=TVE.Theme.models.HFSection.getInstance(e),n={id:i.ID,hide:e.hasClass(TVE.Theme.constants.identifiers.HIDE_SECTION_CLASS)?1:0,extraClass:[...TVE.Editor_Page.getResponsiveClasses(e)]};TVE.Theme.savedSection=i.type,i.isDynamic()||(n.content=i.getContent(),n.sticky=i.$html.attr("data-tve-scroll")||""),t[i.type]=n})),delete TVE.Theme.savedSection,t}static getGlobals(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:TVE.Editor_Page.editor;return{js_sdk:TVE.Editor_Page.content_manager.getUsedSDKs(e),fb_comment_admins:TVE.Editor_Page.content_manager.getFacebookCommentsModerators(e),progress_bar:s.getProgressBarPosition()}}static icons(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:TVE.Theme.$wrapper;const t={};for(const i of TVE.Theme.selectors.icons)e.find(i+" svg.tcb-icon").each(((e,i)=>{t[void 0===i.dataset.id?i.dataset.name:i.dataset.id]=i.outerHTML}));return t}static parseContentString(e){return TVE.PostList.dynamicImage.replaceImageShortcodeSrc(e)}static getLayoutId(){const e=/thrive-layout-(\d*)/.exec(TVE.inner.$body.attr("class"));return e?parseInt(e.pop()):0}static getProgressBarPosition(){const e=(arguments.length>0&&void 0!==arguments[0]?arguments[0]:TVE.Editor_Page.editor).find(".thrive-progress-bar"),t=e.attr("data-position");let i="";return e.length&&"undefined"!==t&&(i=t),i}}e.exports=s},2806:function(e,t,i){function n(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function s(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}const o=i(6780);e.exports=class extends o{static get identifier(){return".thrv_header,.thrv_footer"}static get component(){return TVE.Components["theme-hf"]}get baseSelector(){return`.thrv_${this.type}`}get selector(){return this.ID?`.thrv_symbol_${this.ID}`:this.baseSelector}static get contentSelector(){return".symbol-section-in"}static get backgroundSelector(){return".symbol-section-out"}static getTemplateId(){return TVE.Theme.template.ID}setElements(){this.$content=this.$element.find(this.constructor.contentSelector),this.$html=this.$element.find(".thrive-symbol-shortcode:first"),this.$style=this.$element.find(".tve-symbol-custom-style"),this.$background=this.$element.find(".symbol-section-out")}isHorizontal(){return!0}isVertical(){return!1}save(e,t){return TVE.ajax("save_symbol","post",{symbol_title:e,tcb_symbols_tax:this.getSectionTermId()}).done((i=>{this.beforeSave(i.data.id),this.update((()=>{this.afterSave()})),void 0===TVE.Theme.data.local[this.type]&&(TVE.Theme.data.local[this.type]={}),TVE.Theme.data.local[this.type][this.ID]=this.sectionData={id:this.ID,name:e,type:this.type,thumb:{url:i.data.thumb_url,w:2,h:1}},"function"==typeof t&&t(i)})).fail(console.warn)}update(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,t=function(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?n(Object(i),!0).forEach((function(t){s(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):n(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}({id:this.ID,symbol_content:this.getContent(),symbol_css:this.getStyle()},TVE.Lightspeed.getLightspeedData({$content:this.$element}));t=TVE.apply_filters("tcb.symbol.before_save",t),TVE.ajax("save_symbol","post",t).done((i=>{TVE.Theme.data.local[this.type][this.ID].content=t.symbol_content,TVE.Theme.data.local[this.type][this.ID].style=t.symbol_css,TVE.Components.symbol.content_preview.savePreview(this.$element,{post_id:i.data.symbol.ID,file_name:i.data.symbol.ID+".png"}),"function"==typeof e&&e(i)})).fail(console.warn)}unlink(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];this.beforeUnlink(),this.convertCssToTemplate(),this.ID=0,this.updateAttr();let t="";this.$style&&this.$style.length&&(t=this.$style.html()),TVE.Editor_Page.content_manager.insert_head_css(this.convertStyle(t)).done((()=>{this.focus(),this.constructor.saveTemplate(e,!1),this.bindElementActions(),this.afterUnlink()}))}load(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"local";this.$element.addClass("element-loading");const i={id:e,type:this.type},n="local"===t?"get_symbol":"cloud_content_template_download";TVE.ajax(n,"get",i).done((i=>{const n=i.data;"local"===t?(n.id=e,n.style=i.data.css):(n.id=0,n.style=this.convertStyle(i.data.head_css)),this.insert(n)})).fail(console.warn)}insert(e){this.beforeInsert(e),this.$html.html(e.content),TVE.Editor_Page.content_manager.insert_head_css(e.style).done((()=>{this.$element.removeClass("element-loading"),this.afterInsert(e)})),this.setElements(),this.updateAttr()}beforeInsert(e){super.beforeInsert(e),TVE.head_css_remove(TVE.Theme.utils.escapedRegEx(this.baseSelector,"g"),"_ALL"),e.content=TVE.inner_$(e.content),e.content.filter(".symbol-section-out[data-css], .symbol-section-in[data-css]").each(((t,i)=>{const n=TVE.escapedRegEx(`[data-css="${i.dataset.css}"]`,"g");e.style=e.style.replace(n,"."+TVE.getClassThatContains(i,"symbol-section-")),delete i.dataset.css}))}afterInsert(e){super.afterInsert(e),this.$element.find(".thrv_widget_menu").removeClass("tve-custom-menu-switch-icon-tablet tve-custom-menu-switch-icon-mobile")}convertStyle(e){const t="__TEMP_SELECTOR__";return(e=(e=(e=e.replace(/\.thrv_symbol_\|TEMPLATE_ID\|*/g,t)).replace(/\.thrv_symbol_\d*/g,t)).replace(/\.thrv_symbol\.thrv_\S*/g,t)).replace(new RegExp(t,"g"),`${TVE.Theme.CONST.body_class} ${this.baseSelector}`)}updateAttr(){this.$element.attr("data-selector",this.selector);const e=this.$element.attr("class").replace(/thrv_symbol_\d*/,"");if(this.$element.attr("class",e),this.isDynamic())this.$element.addClass(this.selector.replace(".","")).attr("data-id",this.ID),this.$html.attr("data-symbol-id",this.ID),this.$content.attr("data-selector",`${this.constructor.contentSelector}`),this.$background.attr("data-selector",`${this.constructor.backgroundSelector}`);else{const e="header"===this.type?".tve-default-state":"";this.$content.attr("data-selector",`${this.baseSelector}${e} ${this.constructor.contentSelector}${e}`),this.$background.attr("data-selector",`${this.baseSelector}${e} ${this.constructor.backgroundSelector}${e}`),"header"===this.type&&(this.$content.addClass("tve-default-state"),this.$background.addClass("tve-default-state")),this.$element.removeAttr("data-id").removeAttr("data-section-name"),this.$html.removeAttr("data-symbol-id")}this.$element.toggleClass("symbol-edit-mode",!this.isDynamic()||this.inEditMode()),this.$html.attr("data-selector",`${this.selector} .thrive-symbol-shortcode`).toggleClass("thrive-shortcode-html",this.isDynamic()&&!this.inEditMode())}getStyle(){const e=TVE.Theme.utils.getSpecificStyle((e=>{const t=this.isDynamic(),i=e.includes(TVE.Theme.CONST.body_class),n=(t&&!i||!t&&i)&&e.includes(this.selector);return TVE.apply_filters("theme.section.keep_styles_for_selector",n,e,this.$content)}));let t=e.fonts.join("");return _.each(e.css,((e,i)=>{t+=`@media ${i} {${e}}`})),t}getContent(){const e=TVE.Theme.models.Content.clean(this.$html);return e.find(".tve-symbol-custom-style").remove(),TVE.Theme.models.Content.elementClasses(e),TVE.Theme.models.Content.shortcodes(e),TVE.apply_filters("theme.parse_content",e,"section"),e.html()}getSectionTermId(){const e=TVE.CONST.sections_tax_terms.find((e=>e.slug===`${this.type}s`));return e&&e.term_id?e.term_id:0}getBlockTarget(){let e;if("header"===this.type){const t=this.$element.next();TVE.Theme.models.LPSection.isLPSection(t)&&(e=t)}else{const t=this.$element.prev();TVE.Theme.models.LPSection.isLPSection(t)&&(e=t)}return e}allowBlockControlsBelow(e){const t=this.getBlockTarget();return t&&t.length&&(e="none"===t.css("display")),"footer"===this.type&&(e=!1),e}}},3724:function(e){function t(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function i(e){for(var i=1;i<arguments.length;i++){var s=null!=arguments[i]?arguments[i]:{};i%2?t(Object(s),!0).forEach((function(t){n(e,t,s[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(s)):t(Object(s)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(s,t))}))}return e}function n(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}const s=()=>TVE.inner.window.ThriveTheme.sidebar;class o{static get prefix(){return":not(#layout)"}get selector(){return`.thrive-layout-${this.ID}`}constructor(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this.ID=e,this.setMeta(t)}getMeta(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return e?this.meta[e]:this.meta}setMeta(e){e&&e.meta_input&&!e.meta_input.content_width&&(e.meta_input.content_width=o.getContentWidth()),this.meta=e.meta_input}name(){let e="Custom";if(this.ID){const t=TVE.CONST.theme.layouts.find((e=>e.ID===this.ID));t&&(e=t.post_title)}return e}save(e,t){TVE.Theme.utils.loadingMessage("Saving Layout"),TVE.$.ajax({url:TVE.CONST.theme.routes.layouts,type:"POST",data:{post_title:e},headers:{"X-WP-Nonce":TVE.CONST.rest_nonce}}).done((i=>{this.convertCss(i),TVE.CONST.theme.layouts.push({ID:i,post_title:e}),this.update(!0),"function"==typeof t&&t(i)})).fail((()=>{TVE.page_message("Error saving the layout!",!0,3e3)})).always((()=>{TVE.Theme.utils.loadingMessage(!1)}))}update(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];if(this.ID)return!e&&TVE.Theme.utils.loadingMessage("Updating layout"),TVE.$.ajax({url:`${TVE.CONST.theme.routes.layouts}/${this.ID}`,type:"POST",data:{meta_input:i({template_id:TVE.Theme.template.ID,style:{css:this.getStyle()}},o.getDataFromPage())},headers:{"X-WP-Nonce":TVE.CONST.rest_nonce}}).done((e=>{const t=TVE.CONST.theme.layouts.findIndex((t=>t.ID===e.data.ID));-1===t?TVE.CONST.theme.layouts.push(e.data):TVE.CONST.theme.layouts[t]=e.data,o.getStyleNode().html(e.style),TVE.head_css_remove(TVE.Theme.utils.escapedRegEx(o.prefix,"g"),"_ALL"),TVE.do_action("theme.layout.after_update")})).fail((e=>{TVE.page_message("Error saving the layout!",!0,3e3)})).always((e=>{setTimeout((()=>{TVE.Theme.utils.loadingMessage(!1)}),2e3)}));TVE.page_message("Unknown layout to save!",!0,300)}static load(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:TVE.$.noop;e=parseInt(e),t=parseInt(t),e!==t&&(TVE.Theme.utils.loadingMessage("Loading layout"),TVE.$.ajax({url:`${TVE.CONST.theme.routes.layouts}/${e}`,type:"GET",headers:{"X-WP-Nonce":TVE.CONST.rest_nonce}}).done((n=>{t&&TVE.inner.$body.removeClass(`thrive-layout-${t}`),TVE.inner.$body.addClass(`thrive-layout-${e}`),o.getStyleNode().html(n.style),o.fixLayoutStructure(n),TVE.head_css_remove(TVE.Theme.utils.escapedRegEx(o.prefix,"g"),"_ALL"),setTimeout((()=>{TVE.Theme.utils.loadingMessage(!1),TVE.Theme.content.updateResizeHandlersPosition(),TVE.PostList.layout.masonryRedo(),TVE.Theme.utils.loadingMessage("Updating also the template!","save-template"),TVE.Theme.content.save((()=>{TVE.Theme.utils.loadingMessage(!1,"save-template"),"function"==typeof i&&i(e)}),!0,!0)}),42)})).fail((()=>{TVE.page_message("Error loading layout!",!0,3e3),TVE.Theme.utils.loadingMessage(!1)})))}static getStyleNode(){let e=TVE.inner.jQuery("#thrive-theme-layout-css");return 0===e.length&&(e=TVE.inner.jQuery('<style id="thrive-theme-layout-css" type="text/css"></style>'),e.insertBefore(TVE.inner.jQuery("#thrive-template-css"))),e}getStyle(){const e=TVE.stylesheet;TVE.stylesheet=o.getStyleNode()[0].sheet;const t=this.convertSelector(TVE.CSS_Rule_Cache.getCssForSelector(this.selector),this.selector);TVE.stylesheet=e;const i=TVE.$.extend(!0,{},t,this.convertSelector(TVE.CSS_Rule_Cache.getCssForSelector(o.prefix),TVE.Theme.CONST.body_class));for(const e in i)i.hasOwnProperty(e)&&(i[e]=_.map(i[e],((e,t)=>t+"{"+_.map(e,((e,t)=>`${t}:${e}`)).join("; ")+"}")).join(""));return i}convertSelector(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";const i={};for(const n in e)if(e.hasOwnProperty(n)&&"@imports"!==n){i[n]={};for(const s in e[n])if(e[n].hasOwnProperty(s)){const a=s.replace(o.prefix,"").replace(t,this.selector).trim();i[n][a]=e[n][s]}}return i}convertCss(e){TVE.inner.$body.addClass(`thrive-layout-${e}`);const t=o.getStyleNode(),i=t.html().replace(TVE.Theme.utils.escapedRegEx(`thrive-layout-${this.ID}`,"g"),`thrive-layout-${e}`);t.html(i),TVE.inner.$body.removeClass(`thrive-layout-${this.ID}`),this.ID=e}static hasUnsavedChanges(){const e=o.getInstance().getMeta();let t=void 0!==_.find(o.getDataFromPage(),((t,i)=>e[i]!==t));return t||(t=_.some(TVE.CSS_Rule_Cache.getCssForSelector(o.prefix),(e=>Object.values(e).length>0))),t}static fixLayoutStructure(e){const t=!!parseInt(e.meta_input.hide_sidebar);TVE.Theme.$main.toggleClass(TVE.Theme.constants.identifiers.FLIP_SECTIONS_CLASS,!!parseInt(e.meta_input.sidebar_on_left)),TVE.Theme.$sections.sidebar.toggleClass(TVE.Theme.constants.identifiers.HIDE_SECTION_CLASS,t),s().isOffScreen()&&(t?s()._get("off-screen").destroy():s().offScreenRefresh())}static fixBadLayoutId(){var e,t;let i=TVE.inner.$body.attr("class");var n;null!==(e=TVE.CONST.theme.layouts)&&void 0!==e&&e.length&&null!==(t=TVE.CONST.theme.layouts[0])&&void 0!==t&&t.ID&&i.includes("thrive-layout-")&&(i=i.replace(/thrive-layout-(\S*)/gm,`thrive-layout-${null===(n=TVE.CONST.theme.layouts[0])||void 0===n?void 0:n.ID}`)),TVE.inner.$body.attr("class",i)}static getDataFromPage(){return{sidebar_on_left:TVE.Theme.$main.hasClass(TVE.Theme.constants.identifiers.FLIP_SECTIONS_CLASS)?1:0,content_width:this.getContentWidth(),hide_sidebar:this.isSidebarHidden()}}static isSidebarHidden(){return TVE.Theme.$sections.sidebar.hasClass(TVE.Theme.constants.identifiers.HIDE_SECTION_CLASS)?1:0}static getContentWidth(){return o.isFullWidth()?"100%":o.getWidth("content")}static setWidth(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";return arguments.length>2&&void 0!==arguments[2]&&!arguments[2]?(TVE.Theme.FLAGS.LAYOUT_CSS_WRITE=!0,TVE.Theme.$wrapper.head_css({[`--layout-${t}-width`]:e}),TVE.Theme.FLAGS.LAYOUT_CSS_WRITE=!1,TVE.Theme.$wrapper.tcbCss(`--layout-${t}-width`,"")):TVE.Theme.$wrapper.tcbCss(`--layout-${t}-width`,e),o}static getWidth(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return TVE.Theme.$wrapper.tcbCss(`--layout-${e}-width`)}static isFullWidth(){return"100%"===o.getWidth("background")}static getInstance(){const e=TVE.Theme.models.Content.getLayoutId();return new o(e,TVE.CONST.theme.layouts.find((t=>t.ID===e)))}static setSidebarPosition(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:TVE.main.media_query_tpl();TVE.write_css(`${TVE.Theme.CONST.body_class} ${o.prefix} .sidebar-section`,{order:"left"===e?1:3},t),TVE.write_css(`${TVE.Theme.CONST.body_class} ${o.prefix} .content-section`,{order:"left"===e?3:1},t)}}e.exports=o},2952:function(e,t,i){function n(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function s(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?n(Object(i),!0).forEach((function(t){o(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):n(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function o(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}const a=i(6780);e.exports=class extends a{static get identifier(){return".theme-section"}static get component(){return TVE.Components.theme_section}static get typographySuffix(){return["p","li","label",".tcb-plain-text","h1","h2","h3","h4","h5","h6"]}get baseSelector(){return`.${this.type}-section`}get selector(){return this.ID?`.thrive-section-${this.ID}`:this.baseSelector}static get contentSelector(){return".section-content"}static get backgroundSelector(){return".section-background"}setElements(){this.$content=this.$element.find(this.constructor.contentSelector),this.$background=this.$element.find(".section-background")}static getTemplateId(){return TVE.Theme.template.ID}static isOnSingularTemplate(){return TVE.Theme.template.isSingular()}save(e,t){if(!this.ID)return this.removeOverlay(),TVE.Theme.utils.loadingMessage("Saving Section","save-section"),TVE.$.ajax({url:TVE.CONST.theme.routes.sections,type:"POST",data:{post_title:e,meta_input:{type:this.type,singular:this.constructor.isOnSingularTemplate()?1:0}},headers:{"X-WP-Nonce":TVE.CONST.rest_nonce}}).done((i=>{this.beforeSave(i),this.update(!0,(()=>{this.afterSave()})),void 0===TVE.Theme.data.local[this.type]&&(TVE.Theme.data.local[this.type]={}),TVE.Theme.data.local[this.type][i]=this.sectionData={id:i,name:e,type:this.type},"function"==typeof t&&t(i)})).fail(console.warn).always((()=>{setTimeout((()=>{TVE.Theme.utils.loadingMessage(!1)}),4200)}));console.warn(`Section already saved with ID: ${this.ID}`)}update(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;if(!this.ID)return void(this.isDynamic()&&console.warn("Error saving dynamic section!"));this.removeOverlay(),e||TVE.Theme.utils.loadingMessage("Updating Section");const i=()=>{const e=s({style:this.getStyle(),icons:TVE.Theme.models.Content.icons(this.$content),content:this.getContent(),tve_globals:TVE.Theme.models.Content.getGlobals(this.$content)},this.getExtra());TVE.$.ajax({url:`${TVE.CONST.theme.routes.sections}/${this.ID}`,type:"POST",data:s({meta_input:JSON.stringify(e)},TVE.Lightspeed.getLightspeedData({$content:this.$element})),headers:{"X-WP-Nonce":TVE.CONST.rest_nonce}}).done((e=>{this.generatePreview(),TVE.do_action("theme.after_section_update",this.$element,e),"function"==typeof t&&t(e)})).fail((e=>{TVE.wordfenceResponse(e)?TVE.Editor_Page.blur():TVE.page_message("Error saving the section!",!0,3e3)})).always((()=>{TVE.Theme.utils.loadingMessage(!1)}))};"function"==typeof TVE.Editor_Page.processPreSave?TVE.Editor_Page.processPreSave(this.$content,{forms_filter:(e,t)=>!t.closest(".thrive-shortcode-html"),post_id:this.ID}).then(i):i()}unlink(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];this.beforeUnlink(),this.convertCssToTemplate(),this.ID=0,this.updateAttr(),this.focus(),this.$element.find(TVE.identifier("post_list")).each(((e,t)=>{TVE.PostList.dynamicImage.regeneratePostListStyleNodes(TVE.inner_$(t))})),this.constructor.saveTemplate(e,!1),this.bindElementActions(),this.afterUnlink()}static getLoadArguments(){return{query_vars:TVE.Theme.CONST.query_vars,template_id:TVE.Theme.template.ID}}load(e){let t=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;const i="cloud"===(arguments.length>1&&void 0!==arguments[1]?arguments[1]:"local")?"/cloud":"",n=this.constructor.getLoadArguments();return _.isEmpty(t)||(n.version=t),this.$element.removeClass("hide-section"),this.$background.addClass("section-loading"),this.$background.outerHeight()>600&&this.$background.addClass("long-content"),TVE.$.ajax({url:`${TVE.CONST.theme.routes.sections}${i}/${e}`,type:"GET",data:n,headers:{"X-WP-Nonce":TVE.CONST.rest_nonce}}).done(this.insert.bind(this)).fail((e=>{TVE.Theme.utils.loadingMessage(!1)}))}insert(e){this.beforeInsert(e),this.$element.replaceWith(TVE.inner_$(e.content)),TVE.Theme.$sections[this.type]=TVE.ActiveElement=this.$element=TVE.inner_$(this.selector),this.$element.find(".tcb-post-content-placeholder").removeClass("tcb-post-content-placeholder"),TVE.Theme.sectionHover.listenersInit(this.type),TVE.inner_$("html").animate({scrollTop:this.$element.offset().top-24},1e3),TVE.Editor_Page.content_manager.insert_head_css(e.style).done((()=>{this.$background.removeClass("section-loading long-content"),this.afterInsert(e)})),TVE.inner.window.ThriveTheme.initElements()}getStyle(){return TVE.Theme.utils.getSpecificStyle((e=>{const t=e.includes(TVE.Theme.CONST.body_class),i=e.includes(this.selector),n=e.includes(TVE.identifier("symbol")),s=i&&!t&&!n;return TVE.apply_filters("theme.section.keep_styles_for_selector",s,e,this.$content)}))}getContent(){const e=TVE.Theme.models.Content.clean(this.$content);return TVE.Theme.models.Content.elementClasses(e),TVE.Theme.models.Content.shortcodes(e),TVE.apply_filters("theme.parse_content",e,"section"),TVE.Theme.models.Content.parseContentString(e.html())}updateAttr(){if(super.updateAttr(),this.isDynamic())this.$element.attr("data-id",this.ID).addClass(`thrive-section-${this.ID}`);else{let e=this.$element.attr("class");e=e.replace(/thrive-section-\d*/,""),this.$element.attr("class",e).removeAttr("data-id")}}generatePreview(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];e||TVE.Theme.utils.loadingMessage("Updating section preview.","update-preview"),this.startPreview(),this.getPreviewPromise().then((t=>this.savePreview(t,e)))}getPreviewPromise(){return new Promise(((e,t)=>{if(this.previewImage)e(this.previewImage),delete this.previewImage;else{const t=this.getContentToPreview();TVE.generateElementPreview(t,(i=>{t.parent(`.${TVE.Theme.constants.PREVIEW_SECTION_WRAPPER_CLASS}`).remove(),e(i)}),TVE.$.extend(!0,{},TVE.Theme.constants.defaultPreviewOptions),!0)}}))}savePreview(e){let t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];TVE.Theme.utils.savePreviewImage({url:`${TVE.CONST.theme.routes.sections}/${this.ID}/preview/`,action:"section_preview",image:e,ID:this.ID}).done(this.applyPreview.bind(this)).always((()=>{t||TVE.Theme.utils.loadingMessage(!1,"update-preview"),this.$element.removeClass("tcb-generating-preview section-no-overlay")}))}toggleComponents(){const e=this.isDynamic()&&this.inEditMode()||!this.isDynamic();TVE.Components.background.toggle(e),TVE.Components.borders.toggle(e),TVE.Components.shadow.toggle(e),TVE.Components.layout.toggle(e),TVE.Components.decoration.toggle(e),TVE.Components.typography.toggle(e),TVE.Components.responsive.toggle(e)}getBackgroundVideo(){if(this.$background.is(".tcb-custom-field-source.tcb-video-background-el")){if(this.$background.find(".dynamic-source").length>0){let e=this.$background.clone().wrap("<div></div>").parent();return e=TVE.Theme.models.Content.clean(e),e.find(".tcb-custom-field-source").text()}return this.$background.html()}let e=!1;const t=this.$background.children("iframe"),i=this.$background.children(".wistia_embed").empty(),n=this.$background.children("video.tcb-bg-video"),s=this.$background.children("div.tcb-yt-bg");return t.length?e=t.hasClass("tcb-yt-bg")?'<div id="'+t.attr("id")+'" class="tcb-yt-bg" data-url="'+t.attr("data-url")+'" data-yt-id="'+t.attr("data-yt-id")+'"></div>':t.get(0).outerHTML:s.length?e=s[0].outerHTML:i.length?(e="",i.siblings("script").add(i).each((function(){e+=this.outerHTML}))):n.length&&(e=n.get(0).outerHTML),e}getDecoration(){let e={};const t=this.getBackgroundVideo(),i=this.$background.find("svg");return i.length&&(e={"clip-id":this.$background.attr("data-clip-id")||"",svg:""},i.each(((t,i)=>{e.svg+=i.outerHTML}))),t&&(e.video=t),e}getExtra(){const e={decoration:this.getDecoration(),comments:this.getCommentsMeta(),attr:this.getAttributes()};if(TVE.Theme.template.isList()){const t=TVE.inner.$body.find(TVE.identifier("blog_list"));e.posts_per_page=t.attr("data-posts_per_page"),e.query=t.attr("data-query")}return TVE.apply_filters("theme.section.data.extra",e,this)}getAttributes(){return{class:TVE.Theme.utils.getElementResponsiveClasses(this.$element[0]).join(" ")}}getCommentsMeta(){let e={};const t=this.$element.find(TVE.identifier("thrive_comments"));if(t.length>0){const i={},n={};_.each(t,(e=>{const t=TVE.$(e),n=t.find(".theme-comments-label"),s=t.find("input, textarea");TVE.Editor_Page.content_manager.cleanup_froala(n),_.each(n,(e=>{TVE.$(e).find("small").remove(),i[e.getAttribute("data-comments-label")]=e.innerHTML.replace('<span class="required">*</span>',"")})),_.each(s,(e=>{i[`placeholder_${e.getAttribute("name")}`]||(i[`placeholder_${e.getAttribute("name")}`]=e.getAttribute("placeholder"))}))}));const o=t.find(".comment-list .reply").first(),a=this.getReplyAttr(o),r=t.find(".comment-form-submit .thrv_icon");n.submit_button=r.length?r.get(0).outerHTML:"",n.reply_button=t.find(".comment-reply-link .thrv_icon").first().html(),i.no_comments=TVE.Editor_Page.content_manager.get_clean_content({},this.$element.find(".no-comments")),i.error_msg=this.$element.find(".thrive-theme-comments-error-msg").html(),e={labels:s(s({},i),a),icons:n}}return e}getReplyAttr(e){return{reply_icon_flip:e.hasClass("tcb-flip")?"tcb-flip":"","reply-button-style":e.attr("data-button-style"),"reply-button_layout":e.attr("data-button_layout"),"reply-button-size":e.attr("data-button-size"),reply_label:e.find(".tcb-button-text").first().text()}}isOutsideContent(){return this.$element.parent().is(TVE.identifier("template-wrapper"))}removeOverlay(){this.$element.addClass("section-no-overlay").remove(".section-overlay")}isHorizontal(){return"top"===this.type||"bottom"===this.type}isVertical(){return"content"===this.type||"sidebar"===this.type}}},2147:function(e){e.exports=class{constructor(e){_.each(e,((e,t)=>{this[t]=e}))}meta(e,t){const i=this.meta_input;return void 0!==t&&(i[e]=t,this.meta_input=i),i[e]}primary(){return this.meta("primary_template")}secondary(){return this.meta("secondary_template")}variable(){return this.meta("variable_template")}format(){return this.meta("format")}isSingular(){return this.primary()===TVE.Theme.constants.templates.SINGULAR||this.primary()===TVE.Theme.constants.templates.HOME&&this.secondary()===TVE.Theme.constants.templates.PAGE}isBlog(){return this.primary()===TVE.Theme.constants.templates.HOME&&this.secondary()===TVE.Theme.constants.templates.BLOG}isSearch(){return this.primary()===TVE.Theme.constants.templates.SEARCH}isAuthor(){return this.primary()===TVE.Theme.constants.templates.AUTHOR}isList(){const e=this.primary();return e===TVE.Theme.constants.templates.ARCHIVE||e===TVE.Theme.constants.templates.SEARCH||this.isBlog()}isArchive(){return this.primary()===TVE.Theme.constants.templates.ARCHIVE}is404(){return this.primary()===TVE.Theme.constants.templates.error404}isWoo(){return this.isProduct()||this.isShop(!0)||this.isWooPage()}isShop(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];const t=[TVE.Theme.constants.templates.PRODUCT];return e&&t.push("product_tag","product_cat"),this.isArchive()&&t.includes(this.secondary())}isProduct(){return this.isSingular()&&this.secondary()===TVE.Theme.constants.templates.PRODUCT}isHome(){return this.primary()===TVE.Theme.constants.templates.HOME}isWooPage(){return this.isSingular()&&(this.isCart()||this.isCheckout()||this.isAccount())}isCart(){return this.secondary()===TVE.Theme.constants.templates.CART}isCheckout(){return this.secondary()===TVE.Theme.constants.templates.CHECKOUT}isAccount(){return this.secondary()===TVE.Theme.constants.templates.ACCOUNT}getLayoutDataToSave(){const e=TVE.Theme.models.Layout.getDataFromPage(),t=TVE.Theme.models.Layout.getInstance().getMeta();let i={};return _.each(e,((e,n)=>{t&&t[n]!==e&&(i[n]=e)})),i}}},7444:function(e){e.exports=TVE.renderers.CONSTRUCTORS.social.extend({setup_defaults:function(){this.config={style:"tve_style_1",button_type:"tve_social_ib",selected:[{key:"fb_share",label:"Facebook",checked:!0},{key:"t_share",label:"Twitter",checked:!0},{key:"in_share",label:"Linkedin",checked:!0}]}}})},5011:function(e){var t;t=jQuery,e.exports=TVE.renderers.CONSTRUCTORS.social.extend({setup_defaults:function(){this.config={defaultClasses:"tve_social_items tve_social_custom",style:"tve_links_style_1",button_type:"tve_social_itb",selected:["fb_share","yt_share","t_share"]}},getNetworkFromKey:e=>e.replace("_share",""),renderIcon:function(e){const t=TVE.inner_$("symbol#icon-"+e);return TVE.svg_icon({path:t.html(),viewBox:t[0].getAttribute("viewBox"),name:t.find("> title").first().text(),id:t.attr("id")})},render_default:function(){const e=t(`<div class="thrv_wrapper thrv_social_custom thrive_${this.key}"></div>`);return this.setup_defaults(),this.render_to(e),e},_render_to:function(e,t){const i=e.find(".tve_social_items");i.length>0?i.removeClass().addClass(`${this.config.defaultClasses} ${this.config.style} ${this.config.button_type}`):e.html(TVE.tpl("theme-main/author-links-wrapper")({config:this.config}));const n={renderAll:!0,setDynamic:"",href:""};_.each(this.config.selected,(t=>this.renderItem(t,e,n))),_.each(TVE.CONST.socialNetworks,((e,t)=>{this.config.selected.includes(t)||i.find(`.tve_s_${t}`).remove()}))},renderItem:function(e,t){let i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};const n=this.getNetworkFromKey(e),s=t.find(`.tve_s_${e}`),o=s.find("a"),a=o.length>0;let r,l={key:e,icon:this.renderIcon(n),network:n,class:"",dataset:""};r=!(a&&!i.setDynamic)||!i.href&&o.hasClass("tve-dynamic-link"),r?l=Object.assign(l,{class:"tve-dynamic-link",dataset:` data-dynamic-link="thrive_global_fields_url" data-shortcode-id=${n}`}):l.href=i.href||o.attr("href");const c=TVE.tpl("theme-main/author-links-item")({data:l});i.renderAll?(s.remove(),t.find(".tve_social_items").append(c)):s.replaceWith(c)}})},1732:function(e,t,i){const n=i(2907),s=[".thrive-breadcrumbs",".search-submit",".thrive-dynamic-styled-list-item","#comments",".tve-off-screen-sidebar-trigger",".tve-sidebar-close-icon"],o=["#thrive-header","#thrive-footer",".main-no-results",".preview-cloned-content",".thrive-progress-bar",".tve-sidebar-close-icon",`.${n.PREVIEW_SECTION_WRAPPER_CLASS}`,`.${n.PREVIEW_TEMPLATE_WRAPPER_CLASS}`],a='.theme-section[data-section="content"] > div,.theme-section[data-section="sidebar"] > div',r=".thrive_prev_next .thrv-prev-next-button, .thrive_prev_next .tcb-col, .thrive_prev_next .thrv-columns";let l=_.map(_.filter(tcb_main_const.elements,(e=>!1===e.has_icons)),(e=>e.identifier));s.forEach((e=>l.push(e+" .thrv_icon"))),l=l.concat([".thrv-inline-text",'.theme-section:not([data-section="content"],[data-section="sidebar"]) > div']);const c={},d=_.map(_.filter(tcb_main_const.elements,(e=>!0===e.is_theme_button)),(e=>e.identifier));_.each(tcb_main_const.elements,(e=>{e.shortcode&&(c[e.identifier]=e.shortcode)}));let h=_.map(_.filter(tcb_main_const.elements,(e=>!0===e.has_selector)),(e=>e.identifier));h=h.concat(n.dynamic_selectors);const m=l.concat(["div.tcb-col","a.tve-froala",".theme-section > div",".tve_editable.thrv_symbol",".tve-sidebar-close-icon"]),p=["#comments",".theme-dynamic-icon",a,r],u=[a,r],T=Object.values(TVE.CONST.theme.element_selectors).filter((e=>"#main"!==e&&".tcb-mega-drop li a"!==e)),g={elements:T,containers:[".section-content",".tve_shortcode_editor"],theme_buttons:d,no_drag:m,have_selector:h,compact_elements:[".tcb-post-content","section.widget"]};g.dragenter=g.droppable=_.difference(T.concat([".tve-droppable",".thrv_text_element p"]),m),g.draggable=_.difference(T,m),g.editable=T,g.architect={editable:g.editable,mouseover:g.editable,no_icons:l,no_clone:p,no_delete:u,no_lock:[".thrive-breadcrumbs"],no_unlock:[".thrive-breadcrumbs"],not_editable:[".tcb-post-content *",".thrive_author_box:not(.tcb-compact-edit-mode) *"],no_highlight:[".tcb-post-content *",".thrive_author_box:not(.tcb-compact-edit-mode) *",".theme-section[data-id]:not(.tcb-compact-edit-mode) *"],no_save:[...Object.keys(c),"#comments",".tve_lg_input_container",".thrv_symbol",".tcb-col",a,r]},e.exports={haveDynamicPrefix:{thrive_dynamic_list:["dynamic-list-icon","dynamic-list-item","dynamic-list-text"],thrive_breadcrumbs:["breadcrumbs_leaf","breadcrumbs_path","breadcrumbs_icon"]},removeOnSave:o,shortcodes:c,editor:g,icons:s}},8955:function(e){(t=>{let i=0;e.exports={greetingMessage:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[];if(e){const s=t(`<div>${e}</div>`).appendTo(t("#tt-loading-wrapper"));s.attr("class","greeting-message "+n.join(" ")),setTimeout((()=>s.addClass("greeting-show")),500),setTimeout((()=>{s.removeClass("greeting-show"),setTimeout(s.remove.bind(s),300)}),i+1500)}},handleSidebarTooltip:function(e,t){const i=TVE.main.sidebar_extra.tooltipInstances[`${e}-redirect`];i.display(),t.mouseleave((()=>{setTimeout((()=>i.hide()),2e3)})),setTimeout((()=>i.hide()),5e3)},elementClick:function(e){i++,i>=3&&(this.handleSidebarTooltip("tar",e),this.resetCounter())},tarBlur:function(){i++,3===i&&(this.handleSidebarTooltip("theme",TVE.inner.$body),this.resetCounter())},resetCounter:function(){i=0},showConfirmationModal:(e,t)=>{TVE.Theme.modals.switchConfirmation||(TVE.Theme.modals.switchConfirmation=new TVE.Theme.views.SwitchConfirmation({el:TVE.modal.get_element("switch-confirmation")})),TVE.Theme.modals.switchConfirmation.open({href:e,context:t})}}})(jQuery)},8673:function(e,t,i){(t=>{const n=i(3724),s=i(2952),o=i(2806);e.exports={loadingMessage:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";if(e){const n=t(TVE.tpl("theme-main/loading")({message:e,messageTag:i})).appendTo(t("#tt-loading-wrapper"));setTimeout((()=>{n.css("top","0")}),1)}else{let e=t(".tt-loading");i&&(e=e.filter(`[data-tag="${i}"]`)),e&&(e.css("top","-400px"),setTimeout((()=>{e.remove()}),1e3))}},element_attributes:function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],i=arguments.length>2&&void 0!==arguments[2]&&arguments[2],n=arguments.length>3&&void 0!==arguments[3]&&arguments[3];e.jquery&&(e=e[0]);const s={};return _.each(e.attributes,(e=>{if(-1!==t.indexOf(e.name))return;let o=e.value;n&&(o=o.replace(/\[/g,"|{|").replace(/\]/g,"|}|")),i?0===e.name.indexOf("data-")&&(s[e.name.replace("data-","")]=o):s[e.name]=o})),s},save_options:function(e,i){let n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],s=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"Options saved!",o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:"Error saving options!";t.post({headers:{"X-WP-Nonce":TVE.CONST.rest_nonce},url:TVE.CONST.theme.routes.options,data:{name:e,value:i},success:function(){n||TVE.page_message(s,!1,5e3)},error:function(){n||TVE.page_message(o,!0,5e3)}})},getElementResponsiveClasses:e=>{const t=/tcb-\w*-hidden/g,i=[];let n;for(;null!==(n=t.exec(e.className));)n.index===t.lastIndex&&t.lastIndex++,n.length&&i.push(n[0]);return i},ajax:function(e,i){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"POST",s=arguments.length>3&&void 0!==arguments[3]?arguments[3]:t.noop,o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:t.noop,a=arguments.length>5&&void 0!==arguments[5]?arguments[5]:t.noop;return t.ajax({headers:{"X-WP-Nonce":TVE.CONST.rest_nonce},url:e,method:n,data:i,success:s,error:o,always:a})},fetch_list:(e,i)=>{t.ajax({headers:{"X-WP-Nonce":TVE.CONST.rest_nonce},url:TVE.CONST.theme.routes.list,method:"GET",data:{args:e,"demo-content":TVE.Theme.CONST.is_demo_content},success:function(e){1===e.success&&"function"==typeof i&&i(e)},error:function(){TVE.page_message("There has been an error and the list could not be generated",!0,5e3)}})},pseudoSelectorsRegex:function(){return new RegExp([":hover",":active",":after",":focus","::after",":before","::before","::placeholder",".tve-state-active",".tve-state-expanded"].join("|"),"gi")},replaceElementTag:(e,i)=>{const n=TVE.inner_$(i,{html:e.html()});return t.each(e[0].attributes,(function(){n.attr(this.name,this.value)})),e.replaceWith(n),n},inline_shortcodes_init:function(e){e.find(".thrive-shortcode-content").each((function(e,i){const n=t(i),s=i.dataset.shortcode;if("tcb_post_published_date"===s)return!0;if(TVE.PostList.posts&&TVE.inner.window.thrive_page_params&&s&&0===n.html().trim().length){const e=TVE.PostList.utils.getArticleID(n);if(e&&TVE.PostList.posts[e]){const t=TVE.inner_$(TVE.apply_filters("tcb.post_list_article.sync."+s,TVE.PostList.posts[e][s],TVE.PostList.posts[e],n));t.length&&n.html(t.text())}}}))},image_shortcodes_init:function(e){e.find('.thrive-shortcode-content[data-shortcode="tcb_post_author_picture"]').each((function(e,i){const n=t(i),s=i.dataset.shortcode;if(TVE.PostList.posts&&TVE.inner.window.thrive_page_params&&s){const e=TVE.PostList.utils.getArticleID(n);if(e){const t=TVE.inner_$(TVE.apply_filters("tcb.post_list_article.sync."+s,TVE.PostList.posts[e][s],TVE.PostList.posts[e],n));t.length&&n.replaceWith(t)}}}))},replace_all_but_first:function(e,t,i){const n=new RegExp(t,"g");let s=1;return e.replace(n,(function(e){const t=1===s?e:i;return s++,t}))},applyBrackets:function(e){return`[${e}]`},extractShortcodeName:function(e){return e.split(" ")[0]},isInsideSymbol:function(e){let t;return"boolean"==typeof TVE.Theme.FLAGS.INSIDE_SYMBOL_OVERWRITE?t=TVE.Theme.FLAGS.INSIDE_SYMBOL_OVERWRITE:(t=e&&e.closest(`${TVE.identifier("symbol").trim()}[data-id]`).length>0,t=TVE.apply_filters("theme.is_element_inside_symbol",t,e)),t},toggle_controls:function(e,t,i){for(const n of i)t[n]&&t[n].toggle_disabled(e)},disable_components:function(e,t){const i=TVE.Elements[TVE._type(TVE.ActiveElement)].components;for(const n in i)i.hasOwnProperty(n)&&t!==n&&TVE.Components[n].$el.toggleClass("disabled-children",e)},templatePrefix:function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";if(!e||TVE.Theme.FLAGS.duringImport||!TVE.CONST.theme.is_theme_template||this.isInsideSymbol(e))return t;e=TVE.apply_filters("theme.css.change_prefix_target",e);let i=TVE.Theme.CONST.body_class;const s=this.getSectionInstance(e);return TVE.Theme.FLAGS.LAYOUT_CSS_WRITE&&(i=`${n.prefix} ${i}`),s&&(s.constructor.is(e)?s.isDynamic()&&(i=""):s.isContent(e)||s.isBackground(e)?s.isDynamic()&&(i=s.selector):i=s.isDynamic()?s.selector:`${i} ${s.selector}`),t.includes(i)?t:(t=t.replace(this.escapedRegEx(TVE.Theme.CONST.body_class,"g"),""),t.includes(TVE.CONST.global_css_prefix)&&(i=`${TVE.CONST.global_css_prefix} ${i}`,t=t.replace(this.escapedRegEx(TVE.CONST.global_css_prefix,"g"),"")),i=t.includes("{")?t.replace(/(.*){(.*)/g,((e,t,n)=>t.split(", ").map((e=>`${i} ${e}`)).join(", ")+"{"+n)):t.split(", ").map((e=>`${i} ${e}`)).join(", "),i)},cssRulesBeforeInsert:function(e){if(!TVE.main.EditMode.in_edit()||!TVE.main.EditMode.element().is(TVE.identifier("symbol"))){const t=TVE.CSS_Rule_Cache.media_rule(TVE.main.responsive.desktop.media);for(let i=0;i<e.length;i++)switch(e[i].type){case CSSRule.MEDIA_RULE:for(let t=0;t<e[i].cssRules.length;t++){const n=TVE.Theme.utils.templatePrefix(TVE.ActiveElement,e[i].cssRules[t].cssText);e[i].deleteRule(t),e[i].insertRule(n,t)}break;case CSSRule.STYLE_RULE:const n=e[i];n.selectorText=TVE.Theme.utils.templatePrefix(TVE.ActiveElement,e[i].selectorText),t.insertStyleRule(n)}}return e},getDynamicElementPrefix:function(e){let t="",i=TVE._type(e);return i||(i=TVE._type(e.closest(".thrv_wrapper"))),_.each(TVE.Theme.selectors.haveDynamicPrefix,((n,s)=>{if(n.includes(i)){const i=e.closest(TVE.identifier(s));i.length&&(t=`[data-css="${TVE.CSS_Rule_Cache.uniq_id(i)}"]`)}})),t},replaceThemeSectionsCss:function(e,t){if(TVE.CONST.theme.is_theme_template&&e){const i=this.templatePrefix(e);"string"==typeof t?t=t.replace(this.escapedRegEx(i,"g"),"").trim():_.each(t,((e,n)=>{t[n]=e.map((e=>e.replace(this.escapedRegEx(i,"g"),"").trim()))}))}return t},deleteCssForElement:function(e){e&&e.length?_.each(TVE.stylesheet.cssRules,(t=>{const i=TVE.compat.conditionText(t);if(t.type===CSSRule.MEDIA_RULE&&i&&i.length){const n=_.map(t.cssRules,(e=>e.selectorText)),s=_.filter(n,(t=>TVE.inner.$document.find(t).is(e)&&t.includes(TVE.Theme.CONST.body_class)));_.each(s,(e=>TVE.head_css_remove(e,i)))}})):console.warn('Error - Element does not exist in function "deleteCssForElement"')},getImageUrlFromCss:e=>{const t=/(?:\(['"]?)(.*?)(?:['"]?\))/.exec(e);return null===t?"":t[1]},replaceInSymbolCss:e=>{if(TVE.CONST.theme.is_theme_template){const i=[];function t(e,t){let n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];const s=n?TVE.Theme.utils.escapeString(e):e;i.push({regex:s,replacement:t})}void 0!==TVE.Elements.blog_list&&t(TVE.identifier("blog_list"),""),TVE.ActiveElement&&t(TVE.Theme.utils.templatePrefix(TVE.ActiveElement),""),t(TVE.Theme.CONST.body_class,""),_.each(i,(t=>{e=e.replace(new RegExp(t.regex,"g"),t.replacement)}))}try{const n=JSON.parse(e);TVE.main.all_media().forEach((e=>{_.each(TVE.PostList.constants.dynamicStyles,(t=>{n[e]=n[e].replace(new RegExp(t.regex,"g"),'url("'+t.replacement+'")')}))})),e=JSON.stringify(n)}catch(s){const o=[];e=e.replace(/@import url\((.*?)\);/g,((e,t)=>(o.push(e),""))),_.each(TVE.PostList.constants.dynamicStyles,(t=>{e=e.replace(new RegExp(t.regex,"g"),'url("'+t.replacement+'")')})),e=o.join("")+e}return e},escapedRegEx:(e,t)=>new RegExp(TVE.Theme.utils.escapeString(e),t),escapeString:e=>e.replace(/[-/\\^$*+?.()|[\]{}]/g,"\\$&"),isDynamicCss:e=>e.includes("dynamic_"),isDynamicColor:e=>e.includes(TVE.CONST.colors.dynamic_prefix),getDropTargetSection:()=>{let e,t;if(TVE.ActiveElement&&(t=TVE.Theme.utils.getSectionInstance(TVE.ActiveElement)),t&&TVE.Theme.utils.canDropIntoSection(t.$element))e=t.$element;else{const t=_.find(["content","top","sidebar","bottom"],(e=>TVE.Theme.utils.canDropIntoSection(TVE.Theme.$sections[e])));void 0!==t&&(e=TVE.Theme.$sections[t])}return e},canDropIntoSection:function(e){const t=this.getSectionInstance(e),i=t.isDynamic();return t.isVisible()&&(!i||i&&t.inEditMode())},getSpecificStyle:function(e){const t={},i={};let n=[];return"function"!=typeof e&&(e=()=>!0),_.each(TVE.stylesheet.cssRules,(s=>{const o=TVE.compat.conditionText(s);s.type===CSSRule.MEDIA_RULE&&o&&o.length?_.each(s.cssRules,(n=>{const s=n.selectorText.replace(this.pseudoSelectorsRegex(),""),a=TVE.apply_filters("theme.css_rule.before_save",n.cssText.replace(/\n/g," ")),r=TVE.apply_filters("ttb.css.save.whitelist_rule",!1,s,a);if(n.style.length&&(e(n.selectorText)||r)){const e=TVE.inner.$document.find(s);(e.length||r)&&(void 0===t[o]&&(t[o]=""),t[o].includes(a.trim())||(t[o]+=a),0===e.closest(this.getListItemsIdentifiers()).length&&this.saveDynamicStyle(n,i))}})):s.type!==CSSRule.IMPORT_RULE||n.includes(s.cssText)||n.push(s.cssText)})),n=n.filter((e=>JSON.stringify(t).includes(TVE.FontManager.read_font_name(e)))),{css:t,fonts:n,dynamic:i}},getListItemsIdentifiers:()=>TVE.apply_filters("thrive_list_items_identifiers",TVE.identifier("article")),saveDynamicStyle:function(e,t){let i=e.cssText,n="";if(this.isDynamicCss(i)){const t=/background-image: .[^;]*;/gm,s=TVE.remove_extra_spaces(e.selectorText);_.each(TVE.PostList.constants.dynamicStyles,(e=>{i=i.replace(new RegExp(e.regex,"g"),'url("'+e.replacement+'")')}));const o=i.match(t);o&&(n=s+"{"+o[0]+"}")}if(this.isDynamicColor(i)){const e=/--tcb-dynamic-color-[^,]*_(\d+)/gm.exec(i),t=e?new RegExp(e[1],"gi"):null;t&&(n+=i.replace(t,"[thrive_the_id]"))}if(n){const i=TVE.compat.conditionText(e.parentRule);void 0===t[i]&&(t[i]=""),t[i]+=n}},toggleSectionFullWidth:(e,t)=>{const i=e.attr("data-section");t?TVE.Theme.$content["top"===i?"before":"after"](e):TVE.Theme.$content["top"===i?"prepend":"append"](e),TVE.ActiveElement&&TVE.main.active_elem_nav_view.reset_breadcrumbs()},addDebugButton:()=>{const e=TVE.Theme.template.isSingular()?"single":"list";TVE.main.$("#sidebar-bottom").append(`<a href="${window.location.href}&jstest=${e}" target="_blank" class="test-button-link preview-content tvd-fixed-right"><span>TEST</span></a>`)},getSectionInstance:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:TVE.ActiveElement,t=null;const i=TVE.apply_filters("thrive_theme_sections",[s,o]);return i.forEach((i=>{!t&&i.parentSection(e).length&&(t=i.getInstance(e))})),t},base64ToBlob:e=>{const t=e?atob(e.split(",")[1]):"",i=new ArrayBuffer(t.length),n=new Uint8Array(i);for(let e=0;e<t.length;e++)n[e]=t.charCodeAt(e);return new Blob([i],{type:"image/jpeg"})},savePreviewImage:function(e){const t=new FormData,i=e.imageName?e.imageName:`${e.ID}.png`;return t.append("action",e.action),t.append("img_data",this.base64ToBlob(e.image),i),TVE.$.ajax({url:e.url,type:"POST",data:t,processData:!1,contentType:!1,headers:{"X-WP-Nonce":TVE.CONST.rest_nonce}}).fail((e=>{void 0!==e.message&&TVE.page_message(e.message,!0,3e3)})).done((t=>{TVE.outer.window.opener&&TVE.outer.window.opener.postMessage({action:"ttb.thumbnail.generated",post_id:parseInt(e.ID),thumb:t},"*")}))},fixClonedImageHeights:function(e,t){e.find("img").each(((e,i)=>{const n=t.find(`img:eq(${e})`),s=n.height(),o=n.width();i.style.height=s+"px",i.style.width=o+"px"}))},filterContentByHeight:(e,t)=>(t<=0?e.empty():e.children(":not(style)").each(((e,i)=>{t>0?(i.classList.contains("thrv_wrapper")||"A"!==i.tagName.toUpperCase()||(i=i.firstChild),t-=TVE.$(i).outerHeight(!0)):i.parentNode.removeChild(i)})),t),filterContentToPreview(e){e.find(".edit_mode, .layout-highlight").removeClass("edit_mode layout-highlight"),e.find(".tcb-hamburger-logo").remove(),e.find("[srcset]").removeAttr("srcset").removeAttr("sizes"),TVE.do_action("theme.filter_generated_preview",e)},getSkinVariables:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];const t=["colors","gradients"],i={master_variables:[],other_variables:[]};return _.each(t,(t=>{const n=e[`${t}_prefix`];_.each(e[t],(e=>{const s=parseInt(e.parent),o=`var(${n}${e.id})`,a="colors"===t?`linear-gradient(${o}, ${o})`:o;Object.assign(e,{type:t,css_variable:n+e.id,prefix:n,css:a}),-1===s?i.master_variables.push(e):_.isNaN(s)&&i.other_variables.push(e)}))})),i},saveSkinVariables:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};wp.apiRequest({url:`${TVE.CONST.theme.routes.skins}/${TVE.CONST.theme.skin_id}/skin_variables`,type:"POST",data:e}).done((()=>{TVE.outer.window.opener&&TVE.outer.window.opener.postMessage({action:"ttb.skin_variables_changed",color_data:e},"*")})).fail((e=>{e.responseJSON&&TVE.page_message(e.responseJSON.message,!0,5e3)}))},getOrderLabels:e=>{const t={title:[{name:"A to Z",value:"asc"},{name:"Z to A",value:"desc"}],popularity:[{name:"Lowest first",value:"asc"},{name:"Highest first",value:"desc"}],id:[{name:"Lowest first",value:"asc"},{name:"Highest first",value:"desc"}],date:[{name:"Newest first",value:"asc"},{name:"Oldest first",value:"desc"}],modified:[{name:"Newest first",value:"asc"},{name:"Oldest first",value:"desc"}],menu_order:[{name:"Lowest first",value:"asc"},{name:"Highest first",value:"desc"}],price:[{name:"Lowest first",value:"asc"},{name:"Highest first",value:"desc"}]};return void 0===e?t:t[e]},refreshThemeContainerComponent:e=>{let t;(e.is(TVE.Theme.$wrapper)||e.is(TVE.Theme.$content)||e.is(TVE.Theme.$main))&&(t=TVE.getActiveComponent()),t&&t.controls.PageMap&&t.controls.LayoutVisibility&&(t.controls.PageMap.update(),t.controls.LayoutVisibility.render())},allowPostContentDelete(){const e=[];TVE.Theme.$wrapper.find(TVE.identifier("post_content")).each(((t,i)=>{i.closest(TVE.identifier("post_list"))||e.push(i)}));const t=e.length>1;e.forEach((e=>{e.classList[t?"remove":"add"]("tcb-no-delete")}))},getHeadCssPrefix:function(e,t){let i=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if(!TVE.CONST.theme.is_theme_template)return e;if(!1===i&&TVE.flag_modify_hover_selector&&TVE.state_manager.is_hover())return e;e=this.templatePrefix(t,e);const n=t.parents(TVE.identifier("thrive_widget_area"));return n.length&&(e=e+'[data-css="'+TVE.CSS_Rule_Cache.uniq_id(n)+'"]'+TVE.identifier("thrive_widget_area")+" "),e.replace(/([ ]{2,})/g," ")},getWooElement:e=>{const t=TVE.Theme.constants.WOO_ELEMENTS.find((t=>TVE.Theme.template[`is${TVE.ucFirst(t)}`]()&&e.is(TVE.identifier(`${t}-template`))));return void 0!==t&&t}}})(jQuery)},1828:function(e,t,i){e.exports={Select:i(7808),SwitchContent:i(111),SectionOverlay:i(2130),SwitchConfirmation:i(9941)}},7574:function(e,t,i){(t=>{const n=i(1318),s=i(9587);e.exports=TVE.Views.Base.base_view.extend({tagName:"ul",primary_template:TVE.Theme.template.primary(),secondary_template:TVE.Theme.template.secondary(),initialize:function(e){this.collection=e.collection,TVE.add_filter("editor_loaded_callback",this.init_close_dropdown_listener.bind(this)),this.hide(),this.$list=this.$("#switch-content-select"),this.$(".list-button").html(TVE.tpl("theme-main/content-switch/list-item-load-more")()),this.listenTo(this.collection,"reset add",this.render.bind(this))},render:function(){this.$list.empty(),this.collection.each((e=>{e.set("secondary_template",this.secondary_template),this.$list.append(new n({model:e}).render().$el)}));const e=this.collection.length>TVE.CONST.theme.content_switch.items_to_load-1;return this.$(".content-switch-load-more").toggle(e),this.init_dropdown_content(),this},init_dropdown_content:function(){this.primary_template===TVE.Theme.constants.templates.ARCHIVE&&(this.secondary_template?(this.$el.addClass(this.secondary_template),this.$(".switch-content-info").text(s.get_custom_archive_display_name(this.secondary_template))):(this.archive_collections={},_.each(TVE.CONST.theme.content_switch.data,((e,t)=>{this.archive_collections[t]=new Backbone.Collection(e)}))))},open_dropdown:function(e){e.stopPropagation(),this.$el.toggle(),TVE.main.sidebar_extra.$el.find(".drawer, .sidebar-item").removeClass("active")},open_custom_archive:function(e,t){this.secondary_template=t.dataset.custom_archive,this.toggle_archive_menu(),this.$el.removeClass(TVE.Theme.constants.templates.ARCHIVE_BASE),this.$el.addClass(this.secondary_template),this.collection.reset(this.archive_collections[this.secondary_template].models),this.$(".switch-content-info").text(s.get_custom_archive_display_name(this.secondary_template))},return_to_index:function(){this.hide(),s.content_switch(TVE.CONST.theme.content_switch.site_url,TVE.CONST.theme.content_switch.site_url.preview)},close_custom_archive:function(){this.$(".switch-content-info").text("Your Website Content"),this.$list.empty(),this.$(".content-switch-input").val(""),this.$el.addClass(TVE.Theme.constants.templates.ARCHIVE_BASE),this.$el.removeClass(this.secondary_template),this.toggle_archive_menu()},toggle_archive_menu:function(){this.$([".content-switch-menu-back",".switch-content-subarchives","#switch-content-select"].join(",")).toggle()},select_content:function(){this.hide()},content_search:_.debounce((function(e,i){const n=i.value,o={search:n,primary_template:this.primary_template,secondary_template:this.secondary_template,template_id:TVE.CONST.post.ID,number_of_items:""};if(this.$(".content-switch-search-container").toggleClass("show-clear",n.length>0),n.length>=3)this.$list.addClass("show-loader"),s.fetch_content_switch_data(o,(e=>{this.collection.reset(e),this.$list.removeClass("show-loader"),e.length||this.$list.html(t(TVE.tpl("theme-main/content-switch/list-select-empty")()))}));else if(0===n.length){let e;e=this.primary_template===TVE.Theme.constants.templates.ARCHIVE&&void 0!==TVE.CONST.theme.content_switch.data[this.secondary_template]?TVE.CONST.theme.content_switch.data[this.secondary_template]:TVE.CONST.theme.content_switch.data,this.collection.reset(e)}}),100),clear_input:function(){this.$(".content-switch-input").val("").trigger("input")},load_more:function(e,i){const n=this.$("#switch-content-select li").length-1,o={search:this.$(".content-switch-input").val(),primary_template:this.primary_template,secondary_template:this.secondary_template,template_id:TVE.CONST.post.ID,number_of_items:n};this.$(".content-switch-load-more").addClass("show-loader").text("Loading"),s.fetch_content_switch_data(o,(e=>{this.$(".content-switch-load-more").removeClass("show-loader").text("Load more"),e.length<TVE.CONST.theme.content_switch.items_to_load&&t(i).hide(),this.collection.add(e)}))},init_close_dropdown_listener:function(){TVE.add_filter("tcb.element.editable",(e=>(this.hide(),e))),TVE.outer.$document.add(TVE.inner.$document).click((e=>{t(e.target).closest(this.$el).length||this.hide()}))}})})(jQuery)},1318:function(e,t,i){(t=>{const n=i(9587);e.exports=TVE.Views.Base.base_view.extend({tagName:"li",template:TVE.tpl("theme-main/content-switch/list-item"),initialize:function(e){},render:function(){return this.model.get("has_template")||this.$el.html(this.template({model:this.model})),this},select_content:function(e,t){let i;i=this.model.get("id")||this.model.get("plain_url")||"";const s={name:this.model.get("title"),secondary_template:this.model.get("secondary_template"),variable_template:i};n.content_switch(t.dataset.url,t.dataset.preview_url,s)}})})(jQuery)},111:function(e,t,i){(t=>{const n=i(7574),s=i(9587);e.exports=TVE.Views.Base.base_view.extend({has_dropdown:!1,primary_template:TVE.Theme.template.primary(),secondary_template:TVE.Theme.template.secondary(),open_dropdown:function(e,t){return TVE.main.EditMode.in_edit()?TVE.main.EditMode.overlayClicked(e):this.dropdown.open_dropdown(e),!1},initialize:function(){TVE.add_filter("editor_loaded_callback",this.reinitializeAfterSwitch),TVE.add_action("tcb.edit_mode.enter",(()=>this.$el.addClass("disabled"))),TVE.add_action("tcb.edit_mode.exit",(()=>this.$el.removeClass("disabled"))),this.template_render(),this.render();let e=TVE.CONST.theme.content_switch.content_name;if(e&&(e===TVE.CONST.theme.template.post_title&&TVE.CONST.theme.content_switch.data.length>0&&(e=TVE.CONST.theme.content_switch.data[0].title),this.$("#switch-content-selected").text(e)),this.has_dropdown){const e=new Backbone.Collection(TVE.CONST.theme.content_switch.data);this.dropdown=new n({el:this.$("#switch-content-dropdown"),collection:e}).render()}},demo_content:function(e,t){const i=(e,t)=>{const i="Demo Content";s.content_switch(e,t,{name:i,secondary_template:"thrive_demo_post",variable_template:""}),this.$("#switch-content-selected").text(i)};if(TVE.CONST.theme.demo_content_url&&TVE.CONST.theme.demo_content_preview)i(TVE.CONST.theme.demo_content_url,TVE.CONST.theme.demo_content_preview);else{t.classList.add("show-loader","tve-disabled");const e={singular:TVE.Theme.template.isSingular(),template_id:TVE.Theme.template.ID};TVE.Theme.utils.ajax(TVE.CONST.theme.routes["demo-content"]+"/generate",e,"POST",(e=>{t.classList.remove("show-loader","tve-disabled"),i(e.edit,e.preview)}))}this.dropdown&&this.dropdown.hide()},template_render:function(){switch(this.primary_template){case TVE.Theme.constants.templates.ARCHIVE:this.secondary_template?TVE.Theme.template.isShop()?(this.has_dropdown=!1,this.hide()):this.template=TVE.tpl("theme-main/content-switch/main")({view:this}):this.template=TVE.tpl("theme-main/content-switch/main-archive")({custom_archives:_.map(TVE.CONST.theme.content_switch.custom_archive.counts,((e,t)=>{const i=e.count-TVE.CONST.theme.content_switch.data[t].filter((e=>e.has_template)).length;return Object({key:t,count:i,has_template:e.has_template,display_name:TVE.CONST.theme.content_switch.custom_archive.names[t]})})),view:this}),this.has_dropdown=!0;break;case TVE.Theme.constants.templates.SINGULAR:this.template=TVE.tpl("theme-main/content-switch/main")({view:this}),this.has_dropdown=!0;break;case TVE.Theme.constants.templates.SEARCH:this.template=TVE.tpl("theme-main/content-switch/main-search")();break;case TVE.Theme.constants.templates.BLOG:case TVE.Theme.constants.templates.error404:default:this.has_dropdown=!1,this.hide()}},isDemoContentVisible:()=>!TVE.Theme.template.isWoo(),hasWebsiteContent:()=>TVE.CONST.theme.content_switch.data.length,select_content:function(e,t){this.$("#switch-content-selected").text(t.textContent.trim())},return_to_index:function(){this.$("#switch-content-selected").text(TVE.Theme.constants.content_switch.blog_index_text)},render:function(){this.setElement(t(this.template).appendTo(TVE.main.$("#sidebar-top")))},reinitializeAfterSwitch:function(){if(TVE.FLAGS.theme_content_switch){TVE.Components.header.hooksInit(),TVE.Components.footer.hooksInit(),TVE.inner.window.TCB_Front.floating.init();const e=t("#tcb-edit-mode-button");e.off("click"),TVE.main.EditMode=new TVE.edit_mode({el:e[0]}),TVE.FLAGS.theme_content_switch=!1}},template_search:_.debounce((function(e,t){const i=t.value,n={search:i,primary_template:this.primary_template,template_id:TVE.CONST.post.ID,number_of_items:""};s.fetch_content_switch_data(n,(e=>{const t=e.url,n=e.preview_url;s.content_switch(t,n,{name:i,variable_template:i})}))}),500)})})(jQuery)},9587:function(e){var t;t=jQuery,e.exports={fetch_content_switch_data:(e,i)=>{t.ajax({headers:{"X-WP-Nonce":TVE.CONST.rest_nonce},url:TVE.CONST.theme.routes.content,method:"GET",data:e,success:function(e){"function"==typeof i&&i(e)},error:function(e){TVE.page_message("There was an error and the content could not be loaded.",!0,5e3)}})},reloadFrame:function(e,t){TVE.main.$frame.attr("data-src",e).attr("src",e),TVE.Editor_Page.blur(),TVE.main.sidebar_bottom.$el.find(".preview-content").attr("href",t),TVE.FLAGS.theme_content_switch=!0},content_switch:function(e,t){let i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;TVE.main.EditMode.in_edit()&&TVE.main.EditMode.exit(),this.storeInCookie(i),TVE.Theme.utils.loadingMessage("Loading Content"),window.onbeforeunload?TVE.Theme.content.save((()=>{this.reloadFrame(e,t)}),!0):this.reloadFrame(e,t)},storeInCookie:function(e){const t={primary:TVE.Theme.template.primary(),secondary:TVE.Theme.template.secondary(),variable:TVE.Theme.template.variable(),format:this.getPostFormatKey(TVE.Theme.template.format())},i=this.getCookie("thrive_theme_switched_content");if(!t.variable){let n;if(i)try{n=JSON.parse(i)}catch(e){console.error("Existing Switch Content cookie is corrupted. Resetting the cookie to default."),n={}}n=n||{},n=this.prepareData(t,n,e),this.setCookie("thrive_theme_switched_content",JSON.stringify(n))}},prepareData:function(e,t,i){return t[e.primary+e.secondary+e.format]=i,t},getCookie:function(e){let t;for(let i of document.cookie.split(";"))if(-1!==i.indexOf(e)){t=i.replace(`${e}=`,"");break}return t},setCookie:function(e,t){const i=new Date;i.setTime(i.getTime()+864e7),document.cookie=[e,"=",t,"; expires="+i.toUTCString(),"/"].join("")},getPostFormatKey:e=>"standard"===e?"":e,get_custom_archive_display_name:function(e){return TVE.CONST.theme.content_switch.custom_archive.names[e]}}},2130:function(e,t,i){i(2952),e.exports=TVE.Views.Base.base_view.extend({initialize:function(e){this.section=e.section,this.section.$element.one("mouseleave",(()=>{this.remove(!0)})),this.render()},render:function(){this.section.$element.hasClass("section-hover")&&0===this.section.$element.find(".section-overlay-actions").length&&(this.setElement(TVE.inner_$(TVE.tpl("theme-main/section-overlay")({view:this}))),this.$el.hide().appendTo(this.section.$element).fadeIn())},enterEditMode:function(){this.section.constructor.component.sectionSelect.setSection(this.section).enterEditMode(),this.remove()},unlink:function(){this.section.unlink(),this.section.constructor.component.after_update(),this.remove()},remove:function(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];this.$el.fadeOut(e?400:0,(()=>{this.$el.remove()}))},addResponsiveClasses:function(){const e=[];return this.section.$element.height()<TVE.Theme.constants.NORMAL_OVERLAY_MIN_HEIGHT&&e.push("small-height-overlay"),this.section.$element.height()<TVE.Theme.constants.SMALL_OVERLAY_MIN_HEIGHT&&e.push("no-description-overlay"),this.hasSmallWidht()&&e.push("small-width-overlay"),e.join(" ")},hasSmallWidht:function(){return this.section.$element.width()<TVE.Theme.constants.SMALL_OVERLAY_MIN_WIDTH},openSectionModal:function(){this.section.constructor.component.sectionSelect.setSection(this.section).openSectionsModal()}})},7808:function(e){e.exports=TVE.Views.Base.base_view.extend({template:"theme-main/select",before_initialize:function(e){"function"==typeof e.on_select&&(this.on_select=e.on_select),"function"==typeof e.on_search&&(this.on_search=e.on_search),this.default_selected=e.default_selected?e.default_selected:"Choose",this.listenTo(this.model,"change",this.render_list.bind(this))},after_render:function(){const e=this.model.get("className");let t="";e&&this.$el.addClass(e),this.model.get("default_value")&&(t=this.model.get("default_value")),this.set_value(t),this.select_close(),this.render_list()},render_list:function(){const e=this.$(".tth-dropdown"),t=this.model.get("list");0!==e.length&&(e.empty(),t&&Object.values(t).length?_.each(t,(t=>{e.append('<li class="click" data-fn="set_value" data-value="'+t.value+'">'+t.label+"</li>")})):e.append('<li><div class="loading-when-empty"></div></li>'),this.search_size())},search_size:function(){const e=this.$(".tth-dropdown"),t=e[0].scrollHeight>e[0].clientHeight,i=parseInt(e.css("width"))-6-(t?15:0);this.$(".tth-dropdown-search").css({width:i+"px","max-width":i+"px"})},set_value:function(e){let t,i=this.default_selected;"string"==typeof e?t=e:void 0!==e&&(t=e.currentTarget.dataset.value),0!==parseInt(t)&&(_.each(this.model.get("list"),(e=>{String(e.value)===String(t)&&(i=e.label)})),this.$(".tth-dropdown-search").val(""),this.select_close(),this.$(".tth-elem-selected").html(i),"object"==typeof e&&this.on_select(t,i,e))},get_value:function(){return this.$(".tth-elem-selected").html()},is_open:function(){return this.$el.hasClass("tth-visible")},select_open:function(){this.is_disabled()||(this.$el.addClass("tth-visible"),this.search_size())},select_close:function(){this.$el.removeClass("tth-visible")},select_toggle:function(){this.is_open()?this.select_close():this.select_open()},on_select:function(){},disable:function(e){this.$el.toggleClass("disabled",e)},is_disabled:function(){return this.$el.hasClass("disabled")},search:_.debounce((function(e,t){this.loading(!0),this.on_search(t.value)}),400),on_search:function(e){},loading:function(e){this.$(".tth-dropdown").toggleClass("loading",e)}})},8004:function(e,t,i){e.exports=e=>{const t=i(5200);e.resetTemplate=function(){new t({el:TVE.modal.get_element("reset-template")}).open()},e.switchClickedFromTheme=e=>{window.onbeforeunload&&(e.preventDefault(),i(8955).showConfirmationModal(e.currentTarget.href,TVE.Theme.constants.THEME_CONTEXT))}}},1030:function(e,t,i){const n=2===TVE.CONST.theme.skin_palettes.version?i(5153):i(8056);e.exports=TVE.Views.Controls.CentralStylePanel.Sidebar.extend({initSectionFonts(){TVE.CONST.theme.is_theme_template?(delete this.sections.fonts,this.$(".tve-csp-button-group").remove()):TVE.Views.Controls.CentralStylePanel.Sidebar.prototype.initSectionFonts.apply(this)},initSectionStyles(){delete this.sections.styles},initSectionVars(){this.sections.vars=new n({el:this.$el.find('.c-s-p-section[data-section="vars"]'),sidebar:this.sidebar}),this.sections.vars.render_list().$el.show()},clear_tpl_vars_from_content:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return e}})},5153:function(e){function t(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function i(e){for(var i=1;i<arguments.length;i++){var s=null!=arguments[i]?arguments[i]:{};i%2?t(Object(s),!0).forEach((function(t){n(e,t,s[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(s)):t(Object(s)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(s,t))}))}return e}function n(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}(t=>{const n=TVE.Views.Controls.CentralStylePanel.Vars;e.exports=n.extend({configPaletteSelect:{paletteData:TVE.CONST.theme.skin_palettes,masterVariablePrefix:TVE.CONST.theme.skin_variables.colors_prefix},show_locate_control:!1,controls_init:function(e){n.prototype.controls_init.call(this,e),this.controls.color.reset=function(e){this.model=e,this.changed=!1,this.paletteVarsDependency=TVE.Views.Controls.Palettes.getLocalVariablesDependency([e.get("raw_css_variable")])},this.controls.color.onOpen=function(){let e;this.model.get("master")?(e={h:parseInt(TVE.getCssVariableValue("--tcb-theme-main-master-h")),s:parseInt(TVE.getCssVariableValue("--tcb-theme-main-master-s")),l:parseInt(TVE.getCssVariableValue("--tcb-theme-main-master-l")),a:TVE.getCssVariableValue("--tcb-theme-main-master-a")},this.color.colorPicker.spectrum("set",TVE.TinyColor.fromRatio(e))):(e=TVE.getCssVariableValue(`--tcb-skin-color-${this.model.get("index")}`),this.color.colorPicker.spectrum("set",e)),this.originalHSL=TVE.TinyColor(e).toHsl(),this.model.set("initial_value",e)},this.controls.color.color.input=_.debounce((e=>{if(this.controls.color.changed=!0,this.controls.color.model.get("master")){const t=e.toHsl();0===t.h&&0===t.s&&(t.h=this.controls.color.model.get("initial_value").h),this.changeMasterVariable(t),this.masterColorInput(this.controls.color.model.get("raw_css_variable"),e.toRgbString())}else TVE.changeCssVariableValue(`--tcb-skin-color-${this.controls.color.model.get("index")}`,e.toRgbString());this.modifyDependencies(e)})),this.controls.color.cancel=()=>{const e=this.controls.color.model.get("initial_value");this.controls.color.model.get("master")?(e.s=e.s/100,e.l=e.l/100,this.changeMasterVariable(e),this.masterColorInput(this.controls.color.model.get("raw_css_variable"),TVE.hslToRgb(e.h,e.s,e.l))):TVE.changeCssVariableValue(`--tcb-skin-color-${this.controls.color.model.get("index")}`,e),this.modifyDependencies(e)},this.controls.color.apply=()=>{if(!this.controls.color.changed)return;const e=this.controls.color.color.colorPicker.spectrum("get"),t=TVE.CONST.theme.skin_palettes.active_id;if(this.controls.color.paletteVarsDependency.length&&TVE.Views.Controls.Palettes.updatePaletteVariables(this.controls.color.paletteVarsDependency),this.controls.color.model.get("master")){const n=e.toHsl();0===n.h&&0===n.s&&(n.h=this.controls.color.model.get("initial_value").h);const s={h:parseInt(n.h),s:TVE.functions.toFixed(n.s,2),l:TVE.functions.toFixed(n.l,2),a:TVE.functions.toFixed(n.a,2)};TVE.CONST.theme.skin_palettes.palettes[t].modified_hsl=i(i({},TVE.CONST.theme.skin_palettes.palettes[t].modified_hsl),s),wp.apiRequest({url:TVE.CONST.theme.routes.palette,type:"POST",data:{hsl:TVE.CONST.theme.skin_palettes.palettes[t].modified_hsl}})}else wp.apiRequest({url:`${TVE.CONST.theme.routes.palette}/update_auxiliary_variable`,type:"POST",data:{id:parseInt(this.controls.color.model.get("index")),color:e.toRgbString()}})},_.each(this.controls,(e=>{e.executeAjax=t.noop}))},modifyDependencies:function(e){const t=TVE.TinyColor(e).toHsl(),i=this.controls.color;i.paletteVarsDependency.length&&_.each(i.paletteVarsDependency,(e=>{_.each(e.linked_variables,((n,s)=>{TVE.changeCssVariableValue(s,TVE.Views.Controls.CssVariables.Color.modifyLinkedVarValue(n,t,s,i.hueChanged,e.linked_objects,i.originalHSL),e.rootElement,i.important)}))}))},render_list:function(){return this.list_rendered||(Array.isArray(TVE.CONST.theme.skin_palettes.palettes)&&TVE.CONST.theme.skin_palettes.palettes.length&&(this.$el.append(TVE.tpl("central-style-panel/master-variables-header")()),this.$el.append(TVE.tpl("central-style-panel/palettes")()),this.buildPalettesSelect(),this.buildMasterVariable()),this.list_rendered=!0),this},buildPalettesSelect:function(){const e=this.$("#c-s-p-palettes-select");e.length&&(e.data("select2")&&(e.off("select2:open"),e.off("select2:close"),e.select2("destroy")),e.select2({cache:!1,minimumResultsForSearch:-1,data:this.getSelectList(),templateResult:e=>e.id?t("<div"+(e.selected?' class="active"':"")+' data-tooltip="'+e.text+'" data-side="top">'+e.preview+"</div>"):e.text,templateSelection:e=>t(`<div>${e.preview}<span class="c-s-p-palette-title">${e.text}</span></div>`)}).on("select2:open",(()=>{TVE.Views.Controls.DropPanel.close_all()})).on("select2:close",(()=>{TVE.tooltips.hide()})).data("select2").$dropdown.addClass("tcb-palette-dropdown c-s-p-palettes"))},buildMasterVariable:function(){const e=this.getPalette(TVE.CONST.theme.skin_palettes.active_id),t=this.buildHslString(e.modified_hsl,!0),i=this.getOtherVariables(),n=this.getMainVariable();if(this.$el.append(this.variable_template({name:e.name,css_variable:`--tcb-skin-color-${n.id}`,bg:`linear-gradient(${t}, ${t})`,index:"master",wrapper_class:"master_variable",show_locate_control:this.show_locate_control})),this.template_variables.push(`--tcb-skin-color-${n.id}`),i.length){this.$el.append(TVE.tpl("central-style-panel/other-variables-header")());let e="";i.forEach((t=>{e+=this.variable_template({name:t.name,css_variable:`--tcb-skin-color-${t.id}`,bg:`linear-gradient(var(--tcb-skin-color-${t.id}), var(--tcb-skin-color-${t.id}))`,index:t.id,wrapper_class:"other_variable",show_locate_control:this.show_locate_control}),this.template_variables.push(`--tcb-skin-color-${t.id}`)})),this.$el.append(`<div class="c-s-p-other-vars">${e}</div>`)}},getSelectList:function(){const e=[];return TVE.CONST.theme.skin_palettes.palettes.forEach(((t,i)=>{const n=i===TVE.CONST.theme.skin_palettes.active_id;e.push({id:i,text:t.name,preview:this.getPalettePreview(t,n),selected:n})})),e},getPalettePreview:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];return`<div class="c-s-p-palette"><div class="c-s-p-palette-item" style="background-color: ${this.buildHslString(e.modified_hsl,t)}"></div></div>`},getPalette:function(e){return TVE.CONST.theme.skin_palettes.palettes[e]},getOtherVariables:function(){return Object.values(TVE.CONST.theme.palette_colors).filter((e=>!e.hsla_code))},getMainVariable:function(){return Object.values(TVE.CONST.theme.palette_colors).find((e=>-1===e.parent))},buildHslString:function(e){let t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];const i=t?"var(--tcb-theme-main-master-h)":e.h,n=t?"var(--tcb-theme-main-master-s)":100*e.s+"%",s=t?"var(--tcb-theme-main-master-l)":100*e.l+"%";return`hsl(${i},${n},${s})`},dom_edit_css_variable:function(e,t){return t.classList.contains("variable-name")&&(t=t.parentElement.getElementsByClassName("sp-transparent")[0]),this.controls.color.isOpen()?this.controls.color.onCancel():(this.controls.color.reset(new Backbone.Model({master:"master"===t.getAttribute("data-index"),raw_css_variable:t.getAttribute("data-var"),index:t.getAttribute("data-index")})),this.controls.color.open(null,t)),!1},dom_change_palette:function(e,t){const i=parseInt(t.value),n=parseInt(TVE.CONST.theme.skin_palettes.active_id);if(n===i)return;const s=this.getPalette(i),o=this.getVariableValues();this.changeMasterVariable(s.modified_hsl),TVE.CONST.theme.skin_palettes.active_id=i,this.buildPalettesSelect(),this.$(".master_variable .variable-name").text(TVE.CONST.theme.skin_palettes.palettes[t.value].name);const a=this.getVariableValues();this.afterPaletteChange(a,o),wp.apiRequest({url:`${TVE.CONST.theme.routes.skins}/${TVE.CONST.theme.skin_id}/change_palette`,type:"POST",data:{previous_id:n,active_id:i,version:2}}).fail((e=>{e.responseJSON&&TTD.utils.message(e.responseJSON.message,"error")}))},domResetActivePalette:function(){if(confirm("Are you sure you want to reset this palette?")){const e=this.getPalette(TVE.CONST.theme.skin_palettes.active_id),t=this.getVariableValues();this.changeMasterVariable(e.original_hsl),TVE.CONST.theme.skin_palettes.palettes[TVE.CONST.theme.skin_palettes.active_id].modified_hsl=_.clone(e.original_hsl);const i=this.getVariableValues();this.afterPaletteChange(i,t),wp.apiRequest({url:TVE.CONST.theme.routes.palette,type:"POST",data:{hsl:e.original_hsl}})}},masterColorInput:function(e,t){TVE.do_action("tcb.change.main.css.variable",e,t,TVE.ActiveElement,!0)},afterPaletteChange:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};TVE.Views.Controls.Palettes.templatePaletteChanged(this.template_variables,e,t),TVE.do_action("tve.skin.palette_changed",this.template_variables,e,t)},changeMasterVariable:function(e){const t=parseInt(e.h),i=`${parseInt(100*e.s)}%`,n=`${parseInt(100*e.l)}%`,s=e.a;TVE.changeCssVariableValue("--tcb-theme-main-master-h",t),TVE.changeCssVariableValue("--tcb-theme-main-master-s",i),TVE.changeCssVariableValue("--tcb-theme-main-master-l",n),TVE.changeCssVariableValue("--tcb-theme-main-master-a",s),TVE.changeCssVariableValue("--tcb-main-master-h",t),TVE.changeCssVariableValue("--tcb-main-master-s",i),TVE.changeCssVariableValue("--tcb-main-master-l",n),TVE.changeCssVariableValue("--tcb-main-master-a",s)}})})(jQuery)},4325:function(e){jQuery,e.exports=TVE.GlobalColors.extend({after_initialize:function(){this.enable_remove_color=!1,this.enable_edit_color=!1,this.unlink_label="Unlink Theme Color",this.color_type="theme",this.skinVariables=TVE.CONST.theme.skin_variables.colors},execute_ajax:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};const t=_.findIndex(this.skinVariables,(t=>parseInt(t.id)===parseInt(e.id)));t>-1&&(e=_.extend({},{name:this.$global_color_name_input.val(),value:e.color,type:"colors",key:"color"},e),this.skinVariables[t].hsl_parent_dependency?e.hsl_parent_dependency=this.skinVariables[t].hsl_parent_dependency:this.skinVariables[t].hsl&&(e.hsl=this.skinVariables[t].hsl),TVE.Theme.utils.saveSkinVariables(e),this.skinVariables[t].name=e.name)}})},3521:function(e){jQuery,e.exports=TVE.GlobalGradients.extend({after_initialize:function(){this.enable_remove_color=!1,this.enable_edit_color=!1,this.unlink_label="Unlink Theme Gradient",this.skinVariables=TVE.CONST.theme.skin_variables.gradients},execute_ajax:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};const t=_.findIndex(this.skinVariables,(t=>parseInt(t.id)===parseInt(e.id)));t>-1&&(e=_.extend({},{name:this.$global_color_name_input.val(),value:e.gradient,type:"gradients",key:"gradient"},e),TVE.Theme.utils.saveSkinVariables(e),this.skinVariables[t].name=e.name)}})},8056:function(e){function t(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function i(e){for(var i=1;i<arguments.length;i++){var s=null!=arguments[i]?arguments[i]:{};i%2?t(Object(s),!0).forEach((function(t){n(e,t,s[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(s)):t(Object(s)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(s,t))}))}return e}function n(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}(t=>{const n=TVE.Views.Controls.CentralStylePanel.Vars;e.exports=n.extend({template_variables:[],configPaletteSelect:{paletteData:TVE.CONST.theme.skin_palettes,masterVariablePrefix:TVE.CONST.theme.skin_variables.colors_prefix},show_locate_control:!1,controls_init:function(e){n.prototype.controls_init.call(this,e),this.controls.color.color.input=_.debounce((e=>{if(this.isMasterVariable(this.controls.color.variable.id)){const t=e.toHsl();this.changeMasterVariable({h:parseInt(t.h),s:`${parseInt(100*t.s)}%`,l:`${parseInt(100*t.l)}%`})}else TVE.changeCssVariableValue(this.controls.color.variable.css_variable,e.toRgbString())}),0),this.controls.color.cancel=()=>{this.isMasterVariable(this.controls.color.variable.id)?this.changeMasterVariable({h:parseInt(this.controls.color.variable.hsl.h),s:`${parseInt(100*this.controls.color.variable.hsl.s)}%`,l:`${parseInt(100*this.controls.color.variable.hsl.l)}%`}):TVE.changeCssVariableValue(this.model.get("raw_css_variable"),this.model.get("css_variable_value")||this.model.get("initial_value"))},this.controls.color.apply=()=>{const e=this.controls.color.color.colorPicker.spectrum("get"),t=this.controls.color.model.get("variable"),n=e.toRgbString(),s=TVE.CONST.theme.skin_palettes.active_id,o=TVE.CONST.theme.skin_variables.colors.findIndex((e=>parseInt(e.id)===parseInt(t.id)));let a={id:parseInt(t.id),color:n};if(this.isMasterVariable(t.id)){const t=e.toHsl(),n={h:parseInt(t.h),s:TVE.functions.toFixed(t.s,2),l:TVE.functions.toFixed(t.l,2)};TVE.CONST.theme.skin_variables.colors[o].hsl=n,TVE.CONST.theme.skin_palettes.modified[s].colors[o].hsl=n,a=i(i({},a),n)}TVE.CONST.theme.skin_variables.colors[o].color=n,TVE.CONST.theme.skin_palettes.modified[o]&&(TVE.CONST.theme.skin_palettes.modified[s].colors[o].color=n),wp.apiRequest({url:`${TVE.CONST.theme.routes.skins}/${TVE.CONST.theme.skin_id}/skin_variables`,type:"POST",data:a}).fail((e=>{e.responseJSON&&TTD.utils.message(e.responseJSON.message,"error")}))},_.each(this.controls,(e=>{e.executeAjax=t.noop}))},render_list:function(){if(this.list_rendered)return this;const e=TVE.Theme.utils.getSkinVariables(TVE.CONST.theme.skin_variables);let t=0;if(this.master_variables=e.master_variables,this.other_variables=e.other_variables,this.master_variables.length&&(this.$el.append(TVE.tpl("central-style-panel/master-variables-header")()),_.isEmpty(TVE.CONST.theme.skin_palettes)||(this.$el.append(TVE.tpl("central-style-panel/palettes")()),this.buildPalettesSelect()),_.each(this.master_variables,(e=>{this.$el.append(this.variable_template({name:e.name,css_variable:e.css_variable,bg:e.css,index:t,wrapper_class:"master_variable",show_locate_control:this.show_locate_control})),this.vars_list[t]=new Backbone.Model({custom_action:"skin_variables",css_variable:"var("+e.css_variable+")",variables_set:TVE.CONST.theme.skin_variables[e.type],variable:e,post_params:{id:e.id,type:e.type,key:e.prefix.replace("--tcb-skin-","").replace("-",""),name:e.name}}),this.template_variables.push(e.css_variable),t++}))),this.other_variables.length){this.$el.append(TVE.tpl("central-style-panel/other-variables-header")());let e="";_.each(this.other_variables,(i=>{e+=this.variable_template({name:i.name,css_variable:i.css_variable,bg:i.css,index:t,wrapper_class:"other_variable",show_locate_control:this.show_locate_control}),this.vars_list[t]=new Backbone.Model({custom_action:"template_options",css_variable:"var("+i.css_variable+")",variables_set:[],linked_variables:[],variable:i,post_params:{id:i.id,type:i.type,key:i.prefix.replace("--tcb-skin-","").replace("-",""),name:i.name}}),this.template_variables.push(i.css_variable),t++})),this.$el.append(`<div class="c-s-p-other-vars">${e}</div>`)}return this.list_rendered=!0,this},dom_change_palette:function(e,t){const n=parseInt(t.value),s=parseInt(TVE.CONST.theme.skin_palettes.active_id),o=this.getVariableValues();if(s===n)return;const a=this.getMasterVariable(TVE.CONST.theme.skin_palettes.modified[n].colors),r={previous_id:s,active_id:n,master_id:a.id};this.changeMasterVariable({h:parseInt(a.hsl.h),s:`${parseInt(100*a.hsl.s)}%`,l:`${parseInt(100*a.hsl.l)}%`}),TVE.CONST.theme.skin_palettes.active_id=n,this.buildPalettesSelect(),wp.apiRequest({url:`${TVE.CONST.theme.routes.skins}/${TVE.CONST.theme.skin_id}/change_palette`,type:"POST",data:i(i({},r),{version:1})}).done((()=>{TVE.outer&&TVE.outer.window.opener&&TVE.outer.window.opener.postMessage({action:"ttb.skin_palette_changed",data:r},"*")})).fail((e=>{e.responseJSON&&TVE.page_message(e.responseJSON.message,!0,5e3)}));const l=this.getVariableValues();return TVE.apply_filters("tcb.palette_changed",this.externalPalette,r),TVE.Views.Controls.Palettes.templatePaletteChanged(this.template_variables,l,o),TVE.do_action("tve.skin.palette_changed",this.template_variables,l,o),!1},domResetActivePalette:function(){if(confirm("Are you sure you want to reset this palette?")){const e=TVE.CONST.theme.skin_palettes.active_id,t=TVE.CONST.theme.skin_palettes.original[e],i=this.getMasterVariable(t.colors),n=this.getMasterVariableIndex(TVE.CONST.theme.skin_palettes.modified[e].colors);TVE.CONST.theme.skin_palettes.modified[e].colors[n].hsl=i.hsl,this.changeMasterVariable({h:parseInt(i.hsl.h),s:`${parseInt(100*i.hsl.s)}%`,l:`${parseInt(100*i.hsl.l)}%`}),wp.apiRequest({url:`${TVE.CONST.theme.routes.skins}/${TVE.CONST.theme.skin_id}/reset_palette`,type:"POST",data:{active_id:e}}).done((()=>{TVE.outer.window.opener&&TVE.outer.window.opener.postMessage({action:"ttb.skin_palette_reset",palette:t,masterColor:i},"*")}))}return!1},_updateSkinGradients:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];_.each(e,(e=>{TVE.changeCssVariableValue(TVE.CONST.theme.skin_variables.gradients_prefix+e.id,e.gradient);const t=TVE.CONST.theme.skin_variables.gradients.findIndex((t=>t.id==e.id));t>-1&&(TVE.CONST.theme.skin_variables.gradients[t].gradient=e.gradient)}))},_updateSkinColors:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];_.each(e,(e=>{TVE.changeCssVariableValue(TVE.CONST.theme.skin_variables.colors_prefix+e.id,e.color);const t=TVE.CONST.theme.skin_variables.colors.findIndex((t=>t.id==e.id));t>-1&&(TVE.CONST.theme.skin_variables.colors[t].color=e.color,TVE.CONST.theme.skin_variables.colors[t].hsl_parent_dependency?TVE.CONST.theme.skin_variables.colors[t].hsl_parent_dependency=_.extend({},e.hsl_parent_dependency):TVE.CONST.theme.skin_variables.colors[t].hsl&&(TVE.CONST.theme.skin_variables.colors[t].hsl=_.extend({},e.hsl)))})),TVE.changeMainHSL(this.master_variables[0].hsl)},saveSkinVariable:function(e,t){TVE.Theme.utils.saveSkinVariables(t)},getMasterVariableIndex:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];return e.findIndex((e=>void 0!==e.hsl))},getMasterVariable:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];return e.find((e=>void 0!==e.hsl))},isMasterVariable:function(e){return void 0!==TVE.CONST.theme.skin_variables.colors.find((t=>parseInt(t.id)===parseInt(e))).hsl},changeMasterVariable:function(e){TVE.changeCssVariableValue("--tcb-theme-main-master-h",e.h),TVE.changeCssVariableValue("--tcb-theme-main-master-s",e.s),TVE.changeCssVariableValue("--tcb-theme-main-master-l",e.l),TVE.changeCssVariableValue("--tcb-main-master-h",e.h),TVE.changeCssVariableValue("--tcb-main-master-s",e.s),TVE.changeCssVariableValue("--tcb-main-master-l",e.l)}})})(jQuery)},3302:function(e,t,i){function n(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function s(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?n(Object(i),!0).forEach((function(t){o(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):n(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function o(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}(t=>{const n=i(9012),o=i(5932),a={tcb_after_cloud_template_css_inserted:e=>{e.is(TVE.identifier("block"))&&e.find(TVE.identifier("post_list")).each(((e,t)=>{TVE.PostList.dynamicImage.regeneratePostListStyleNodes(TVE.inner_$(t))}))}};e.exports=s(s(s({},a),n),o)})(jQuery)},1606:function(e,t,i){(t=>{const n=function(){return TVE.CONST.woocommerce&&TVE.CONST.woocommerce.is_woo_page},s=[".top-section",".bottom-section",".sidebar-section",".content-section",".thrv_header",".thrv_footer"];e.exports={tcb_central_style_panel_view:(e,t)=>(1!==parseInt(TVE.CONST.external_palettes)||_.isEmpty(TVE.CONST.theme.skin_palettes)||(e=new(i(1030))({el:t.dom.central_style_panel,sidebar:t})),e),tcb_blocks_modal_filter_select_source:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];return TVE.CONST.landing_page||e.push({id:"special",order:2,text:"Theme Blocks",secondary_text:"Blocks designed to match your website branding. Ideal for full width content that should look and feel like the rest of your site."}),e},tcb_blocks_modal_default_select_source:e=>(TVE.CONST.landing_page&&(e="special"),e),tcb_blocks_modal_default_select_cache_key:e=>(TVE.CONST.landing_page&&["blank_v2","tcb2-blank-page-boxed","tcb2-blank-page-styled"].includes(TVE.CONST.landing_page)&&(e.key="block-modal-blank-lp-theme-content",e.modified=!0),e),"tcb.global_colors_templates":e=>(!TVE.CONST.landing_page&&TVE.CONST.theme.skin_palettes&&(e=1===TVE.CONST.theme.skin_palettes.version?TVE.CONST.theme.skin_variables.colors:Object.values(TVE.CONST.theme.palette_colors)),e),"tcb.page_color_prefix":e=>(TVE.CONST.landing_page||(e=TVE.Theme.constants.THEME_SKIN_COLOR_VARIABLE_PREFIX),e),tcb_color_css_variable_regex:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return _.isEmpty(TVE.CONST.theme.skin_variables)||(e+="("+TVE.CONST.theme.skin_variables.colors_prefix+"[0-9]*)|"),e},tcb_gradient_css_variable_regex:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return _.isEmpty(TVE.CONST.theme.skin_variables)||(e+="(var\\("+TVE.CONST.theme.skin_variables.gradients_prefix+"[0-9]*\\))|"),e},"tcb.allow_template_vars_in_color_picker":e=>(void 0!==TVE.CONST.external_palettes&&1===parseInt(TVE.CONST.external_palettes)&&(e=!1),e),editor_loaded_callback:function(){TVE.CONST.theme.is_theme_template||TVE.inner_$(".tve-dynamic-toc:not(.thrv_symbol *), .tve-toc:not(#tve_editor *)").tableOfContents({target:".tcb-post-content,.content-section",hideEmpty:!1,emptyText:"No headings found. This Table of Contents will be hidden from your visitors. Headings will be updated upon saving your page"})},"thrive_theme.editor_content_notice":e=>(n()&&(e=TVE.tpl("tve-woo-page-notice")()),e),"tcb.should_open_page_wizard":e=>(n()&&(e=!1),e),"theme.section.data.extra":e=>(e["conditional-display-groups"]=TVE.Models.ConditionalDisplayManager.prepareGroupsForSave(),e),"tcb.conditional_display.selector":e=>{if(TVE.Theme.CONST&&e.includes(TVE.Theme.CONST.body_class)){const t=s.map((e=>`(${TVE.Theme.CONST.body_class} ${e})`));e=e.replace(new RegExp(`(${t.join("|")})`,"g"),"")}else e.includes(".thrive-section-")&&(e=e.replace(/\.thrive-section-\d*/g,"").trim());return e},"tcb.carousel_manager.element_instance.blog_list":(e,t)=>new TVE.inner.window.TCB_Front.PostList(t,!0)}})(jQuery)},9367:function(e,t,i){e.exports=function(e,t,n){let s=arguments.length>3&&void 0!==arguments[3]?arguments[3]:window,o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:document.body;const a=i(5420)(e),r=i(7632)(e,s,o);let l=s.outerWidth;class c{static getDefaultValues(){let e;switch(arguments.length>0&&void 0!==arguments[0]?arguments[0]:""){case"sticky":e=a.defaultSettings;break;case"off-screen":e=r.defaultSettings;break;case"display-type":e={desktop:"normal"};break;default:e={}}return e}static get inEditor(){return!!s.tve_frontend_options.is_editor_page}constructor(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:e();this.$element=t,this.$content=t.find(".section-content"),t&&t.length&&(this.init(),c.inEditor?(this.sidebarTypeInit().fixContentHeight(),"undefined"!=typeof ResizeObserver&&new ResizeObserver((()=>{this.fixContentHeight()})).observe(this.$content[0])):(e(s).on("resize",(e=>{e.detail&&e.detail.fromTcb||l===s.outerWidth||(l=s.outerWidth,this.sidebarTypeInit().fixContentHeight())})),e((()=>this.sidebarTypeInit().fixContentHeight()))))}init(){this.$element.data("sticky",new a(this)),this.$element.data("off-screen",new r(this))}sidebarTypeInit(){if(!this.isHidden()){["sticky","off-screen"].forEach((e=>this._get(e)&&this._get(e).destroy()));const e=this.getDisplayType();("sticky"===e&&!c.inEditor||"off-screen"===e)&&this._get(e).init()}return this}_get(e){return this.$element.data(e)}getJsonData(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,n=this.$element.attr(`data-${e}`);try{n=JSON.parse(n)}catch(t){n=c.getDefaultValues(e)}return t&&(n=n[t]),i&&(n=this.getConfigByDevice(n,i)),n}getConfigByDevice(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:n.getDisplayType();const i=this.getDisplayType(t),s=[t];for("mobile"===t&&i===this.getDisplayType("tablet")&&s.push("tablet"),s.push("desktop");void 0===e[s[0]]&&s.length;)s.shift();return s[0]?e[s[0]]:null}setJsonData(){let e,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",i=arguments.length>1?arguments[1]:void 0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"",s=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null;"object"==typeof i?e=i:(e=this.getJsonData(t),s?e[i][s]=n:e[i]=n);try{this.$element.attr(`data-${t}`,JSON.stringify(e))}catch(e){this.$element.attr(`data-${t}`,JSON.stringify(this.getJsonData(t)))}return this}isSticky(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:n.getDisplayType();return"sticky"===this.getDisplayType(e)}isOffScreen(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:n.getDisplayType();return"off-screen"===this.getDisplayType(e)}isHidden(){return this.$element.hasClass("hide-section")}getDisplayType(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:n.getDisplayType();const t=this.getJsonData("display-type");let i;return"mobile"!==e&&this.getJsonData("sticky","sticky")?this.getJsonData("sticky","visibleOn").includes(e)&&(i="sticky"):i=t[e],i||(i="mobile"===e&&t.tablet?t.tablet:t.desktop),"sticky"===i&&"mobile"===e&&(i="sticky"===t.tablet?"sticky"===t.desktop?"normal":t.desktop:t.tablet),i}offScreenRefresh(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];if(this.isOffScreen()){const t=this._get("off-screen"),i=t.isVisible();e&&t.destroy();const n=this.getJsonData("off-screen");t.setConfig(n).init(),(i||c.inEditor&&n.visibleInEditor)&&t.toggle(!0)}}updateConfig(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.getDisplayType();const t=this._get(e);return t&&"function"==typeof t.setConfig&&t.setConfig(this.getJsonData(e)),this}fixContentHeight(){if("normal"!==this.$content.css("justify-content")){this.$content.css("display","block");const t=Array.from(this.$content.children()).reduce(((t,i)=>t+e(i).outerHeight(!0)),0);this.$content.height()>t&&this.$content.css("display","flex")}}}return new c(t)}},7632:function(e){e.exports=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:jQuery,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:window,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:document.body;class n{static get clickListener(){return"click.off-screen"}static get defaultSettings(){return{display:{desktop:"slide",mobile:"slide"},visibleOnLoad:{desktop:!0,mobile:!1},visibleInEditor:!0,hasOverlay:{desktop:!1},hasDefaultTrigger:{desktop:!0},hasCloseIcon:{desktop:!0},sidebarWidth:null,triggerPosition:{desktop:"center"},collapsedIcon:"icon-menu-left-solid",expandedIcon:"icon-menu-right-solid",closeIcon:"icon-close-solid"}}static get triggerSelector(){return".tve-off-screen-sidebar-trigger"}static get closeIconSelector(){return".tve-sidebar-close-icon"}constructor(e){this.sidebarInstance=e,this.$element=e.$element,this.element=e.$element[0],this.$main=e.$element.parent(),this.inEditor=e.constructor.inEditor&&TVE.Theme&&TVE.Theme.template;const t=e.getJsonData("off-screen");this.setConfig(t)}init(){return this.sidebarSide=t.ThriveTheme.utils.getSidebarPosition(),i.setAttribute("data-off-screen-side",this.sidebarSide),i.setAttribute("data-off-screen-type",this.getConfig("display",this.getDevice())),i.classList.add("theme-has-off-screen-sidebar"),this.updateSidebarWidth(),this.initDefaultTrigger(),this.initCloseIcon(),this.toggleCloseIcon(this.getConfig("hasCloseIcon",this.getDevice())),i.classList.remove("visible-off-screen-sidebar"),i.classList.remove("theme-has-off-screen-overlay"),this.element.classList.remove("theme-has-off-screen-overlay"),this.element.classList.remove(`sidebar-off-screen-on-${this.getDevice()}`),this.element.style.display="block",this.inEditor?this.getConfig("visibleInEditor")&&setTimeout((()=>this.toggle(!0)),24):(this.setSidebarTop(),e(document).off("keyup.off-screen").on("keyup.off-screen",this.onKeyUp.bind(this)),this.getConfig("hasOverlay",this.getDevice())&&this.$element.off(n.clickListener).on(n.clickListener,this.onClick.bind(this)),this.isVisibleOnLoad()&&setTimeout((()=>this.toggle(!0)),24),this.$element.appendTo(e("#wrapper"))),this}isVisibleOnLoad(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.getDevice(),t=null;return!this.inEditor&&"mobile"!==e&&ThriveTheme.localize.is_user_logged_in&&ThriveTheme.localize.sidebar_visibility&&void 0!==ThriveTheme.localize.sidebar_visibility[e]&&(t=!!parseInt(ThriveTheme.localize.sidebar_visibility[e])),null===t&&(t=this.getConfig("visibleOnLoad",e)),t}initDefaultTrigger(){this.$trigger=this.$element.find(n.triggerSelector),this.inEditor?(this.$trigger.data("tcb-elem-type","sidebar-trigger"),this.$trigger.attr("data-selector",n.triggerSelector)):this.$trigger.off(n.clickListener).on(n.clickListener,(()=>{this.toggle(!this.isVisible())})),this.$trigger.css({display:this.getConfig("hasDefaultTrigger",this.getDevice())?"flex":"none"});const e=this.getConfig("triggerPosition",this.getDevice());i.classList.contains("admin-bar")&&"top"===e?this.$trigger.css({top:t.TCB_Front.bodyOffsetTop()}):this.$trigger.css({top:""}),this.element.setAttribute("data-trigger-position",e)}initCloseIcon(){this.inEditor?this.$element.find(n.closeIconSelector).attr("data-selector",n.closeIconSelector).addClass("tve_no_icons tve_no_drag"):e(document).off(n.clickListener).on(n.clickListener,n.closeIconSelector,(()=>this.toggle(!1)))}destroy(){return i.classList.remove("theme-has-off-screen-sidebar"),i.classList.remove("visible-off-screen-sidebar"),this.element.style.removeProperty("top"),this.element.style.removeProperty("height"),this.element.style.removeProperty("display"),this.element.style.removeProperty("min-width"),this.element.classList.remove(`sidebar-off-screen-on-${this.getDevice()}`),this.$trigger&&this.$trigger.hide(),this.toggleCloseIcon(!1),"wrapper"===this.$element.parent().attr("id")&&this.$element.insertBefore(e(".main-columns-separator")),this}toggle(n){void 0===n&&(n=!this.isVisible());const s=this.getDevice();return this.$element.hasClass(`tcb-${s}-hidden`)&&(n=!1),n&&this.getConfig("hasOverlay",s)?(this.element.classList.add("theme-has-off-screen-overlay"),i.classList.add("theme-has-off-screen-overlay"),setTimeout((()=>{i.classList.toggle("visible-off-screen-sidebar",n)}),42)):(i.classList.toggle("visible-off-screen-sidebar",n),setTimeout((()=>{this.element.classList.remove("theme-has-off-screen-overlay")}),420)),!this.sidebarInstance.constructor.inEditor&&ThriveTheme.localize.is_user_logged_in&&"mobile"!==s&&this.updateUserSidebarSettings(n),setTimeout((()=>{t.tve_frontend_options.is_editor_page?(t.TCB_Front.resizePageSection(),TVE.inner_$(".tcb-mp").css("z-index",""),t.TCB_Front.menu.zIndexOrder()):"function"==typeof t.TCB_Front.sticky.resetElementsPosition&&t.TCB_Front.sticky.resetElementsPosition(),e(t).trigger("tcb_off_screen_sidebar_toggle"),t.TCB_Front.handleIframes(this.$element,n)}),500),this}setConfig(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return this.config=e,this}getConfig(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,i=this.config;return e&&(i=i[e],t&&(i=this.sidebarInstance.getConfigByDevice(i,t))),i}updateSidebarWidth(n){const s=e(t).width();if(void 0===n){switch(this.getDevice()){case"desktop":const e=getComputedStyle(this.element.parentElement);n="wrap"===e.flexWrap?parseInt(e.width)/2:parseFloat(e.getPropertyValue("--sidebar-size"))*parseInt(e.width)/100-parseFloat(e.getPropertyValue("--separator-size"))/2;break;case"tablet":n=s/2;break;case"mobile":n=s-24}let e=this.$element.css("min-width");e.includes("%")?e=parseInt(e)*s/100:(e=parseInt(e),isNaN(e)&&(e=0)),n=Math.max(e,n)}return n>=s&&(n=s-24),parseInt(this.$element.css("min-width"))&&this.$element.css("min-width",`${n}px`),i.style.setProperty("--off-screen-sidebar-size",`${n}px`),n}toggleCloseIcon(){let e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];this.$element.find(n.closeIconSelector).toggle(e)}setSidebarTop(){const e=t.TCB_Front.bodyOffsetTop();this.$element.css({top:`${e}px`,height:`calc(100vh - ${e}px)`})}updateUserSidebarSettings(i){("object"!=typeof ThriveTheme.localize.sidebar_visibility||Array.isArray(ThriveTheme.localize.sidebar_visibility))&&(ThriveTheme.localize.sidebar_visibility={}),ThriveTheme.localize.sidebar_visibility[this.getDevice()]=i?1:0,e.ajax({url:`${ThriveTheme.localize.routes.frontend}/user_options`,headers:{"X-WP-Nonce":t.tve_frontend_options.nonce},type:"POST",data:{template:ThriveTheme.localize.ID,option:"sidebar_visibility",value:ThriveTheme.localize.sidebar_visibility}})}onClick(e){e.target.classList.contains("sidebar-section")&&this.toggle(!1)}onKeyUp(e){"Escape"===e.key&&this.toggle(!1)}isVisible(){return i.classList.contains("visible-off-screen-sidebar")}getDevice(){return void 0===t.TCB_Front?TVE.main.device:t.TCB_Front.getDisplayType()}}return n}},5420:function(e){e.exports=e=>{const t=e(window),i=e(document),n=e("body");let s=window.innerHeight,o=t.width(),a=n.offset().top;return class{static get defaultSettings(){return{sticky:!1,delta:0,stickyUntil:"main",element:""}}needsExtraScroll(){return this.elementHeight>s}shouldBeSticky(){let e=o>768;if(e){const t=ThriveTheme.$sections.content.outerHeight(),i=ThriveTheme.$sections.content.offset().top;(this.offset.top>=i+t||this.offset.top+this.$element.outerHeight()<i)&&(e=!1)}return e}setConfig(e){this.config=e}isSticky(){return this.element.classList.contains("tve-is-sticky")}constructor(e){this.$element=e.$element,this.element=e.$element[0],this.$content=this.$element.find(".section-content"),this.$parent=e.$element.parent(),this.setConfig(e.getJsonData("sticky")),e.constructor.inEditor||("undefined"!=typeof ResizeObserver&&(new ResizeObserver(this.onContentResize.bind(this)).observe(n[0]),new ResizeObserver(this.onContentResize.bind(this)).observe(this.element)),t.off("ultimatum.form.display").on("ultimatum.form.display",this.onContentResize.bind(this)))}init(){this.isSticky()&&this.destroy(),s=window.innerHeight,o=t.width(),a=n.offset().top,this.delta=parseInt(this.config.delta),this.offset=this.$element.offset(),this.$sidebarClone.hide(),this.prevScroll=0,this._sentinelTop=null,this.stickySide=ThriveTheme.utils.getSidebarPosition(),this.elementWidth=this.$element.outerWidth(),this.parentTopPadding=parseInt(this.$parent.css("padding-top")),t.off("scroll.sidebar"),this.shouldBeSticky()&&(this.element.classList.add("tve-sticky-sidebar"),this.element.style.alignItems=this.$content.css("justify-content"),this.setElementHeight(),this.$sidebarClone.css("height",`${this.elementHeight}px`),t.on("scroll.sidebar",(()=>{this.scrollTop=i.scrollTop(),this.scrollDir=this.scrollTop>=this.prevScroll?"Down":"Up",this.prevScroll=this.scrollTop,this.elementTop=parseInt(this.element.style.top),this.onScroll(),this[`onScroll${this.scrollDir}`]()})).trigger("scroll.sidebar"))}setElementHeight(){return this.elementHeight=this.$content.outerHeight(),this.elementHeight<s&&(this.elementHeight=this.$element.outerHeight()),this}onScroll(){this.hasReachedSentinel()||this.needsExtraScroll()||(this.offset.top<=this.scrollTop+this.delta+a?(this.isSticky()||this.makeItSticky(),this.element.style.position="fixed",this.element.style.left=`${this.offset.left}px`,this.element.style.top=`${this.delta+a}px`):this.isSticky()&&this.destroy())}onScrollDown(){if(this.hasReachedSentinel()&&this.isSticky()){let e=this.sentinelTop+this.parentTopPadding-this.elementHeight-this.offset.top;this.needsExtraScroll()&&(e-=this.delta),this.element.style.removeProperty("left"),this.element.style.removeProperty("bottom"),this.element.style.removeProperty("position"),this.element.style.top=`${e}px`}else if(this.needsExtraScroll()&&("fixed"!==this.element.style.position||!this.element.style.bottom))if("fixed"===this.element.style.position&&this.element.style.top){const e=this.$element.offset();this.element.style.removeProperty("position"),this.element.style.removeProperty("left"),this.element.style.top=e.top+this.delta-this.offset.top+"px"}else{let e=this.offset.top+this.elementHeight;this.elementTop&&(e+=this.elementTop-this.parentTopPadding),this.scrollTop+s>e+this.delta&&(this.isSticky()||this.makeItSticky(),this.element.style.position="fixed",this.element.style.left=`${this.offset.left}px`,this.element.style.bottom=`${this.delta}px`,this.element.style.removeProperty("top"))}}onScrollUp(){if(this.needsExtraScroll()&&this.isSticky()&&!this.hasReachedSentinel())if("fixed"===this.element.style.position&&this.element.style.bottom){const e=this.$element.offset();this.element.style.removeProperty("position"),this.element.style.removeProperty("left"),this.element.style.removeProperty("bottom"),this.element.style.top=e.top+this.parentTopPadding-this.offset.top+"px"}else"fixed"===this.element.style.position&&this.offset.top>this.scrollTop+this.delta+a?this.destroy():this.$element.offset().top>this.scrollTop+this.delta+a&&(this.element.style.position="fixed",this.element.style.left=`${this.offset.left}px`,this.element.style.top=`${a+this.delta}px`)}hasReachedSentinel(){return this.scrollTop+s>this.sentinelTop}onContentResize(){this._sentinelTop=null,a=n.offset().top,this.offset=(this.isSticky()?this.$sidebarClone:this.$element).offset(),this.setElementHeight()}get sentinelTop(){if(null===this._sentinelTop){switch(this.config.stickyUntil){case"end":this._sentinelTop=Math.max(document.body.scrollHeight,document.body.offsetHeight,document.documentElement.clientHeight,document.documentElement.scrollHeight,document.documentElement.offsetHeight);break;case"element":if(this.config.element=this.config.element.replace(/([^a-zA-Z0-9_-])/g,"").trim(),""!==this.config.element){const t=e(`#${this.config.element}`);t.length&&t.offset().top>this.offset.top+this.elementHeight&&(this._sentinelTop=t.offset().top)}}null===this._sentinelTop&&(this._sentinelTop=this.$parent.offset().top+this.$parent.outerHeight())}return this._sentinelTop}get $sidebarClone(){const t=this.$parent.find(".sidebar-empty-clone");return t.length?t:e('<div class="sidebar-section sidebar-empty-clone"></div>').css({height:`${this.elementHeight}px`,display:"none"}).insertAfter(this.$element)}makeItSticky(){this.$sidebarClone.show(),this.element.classList.add("tve-is-sticky"),this.element.style[this.stickySide]=this.$parent.css(`padding-${this.stickySide}`),this.element.style.setProperty("width",`${this.elementWidth}px`,"important"),this.needsExtraScroll()||(this.element.style.minHeight=`calc(100vh - ${a+this.delta}px)`,this.elementHeight=this.$element.outerHeight(),this._sentinelTop=null)}destroy(){this.$sidebarClone.remove(),this.element.classList.remove("tve-is-sticky"),this.element.style.removeProperty(this.stickySide),this.element.style.removeProperty("position"),this.element.style.removeProperty("bottom"),this.element.style.removeProperty("width"),this.element.style.removeProperty("left"),this.element.style.removeProperty("top"),this.needsExtraScroll()||this.element.style.removeProperty("min-height")}}}},5017:function(e){e.exports=e=>{class t extends e.TCB_Front.woocommerce.AbstractWoo{ajaxRenderFunction(e,i){let n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],s=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"POST";const o=t.backendRenderFunction(e);return this.loading(!0),TVE.$.ajax({url:`${TVE.CONST.theme.routes.woo}/render`,type:s,data:{fn:o,args:i,output_buffer:n?1:0,query_vars:TVE.Theme.CONST.query_vars},headers:{"X-WP-Nonce":TVE.CONST.rest_nonce}}).always((()=>{this.loading(!1)}))}loading(){let e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];this.$template.toggleClass("ttb-loading",e)}static backendRenderFunction(e){return{related:"woocommerce_related_products",upsells:"woocommerce_upsell_display",shop:"woocommerce_content"}[e]}}return t}},4882:function(e,t,i){e.exports=(e,t)=>{const n=i(5017)(t);class s extends n{static get subElements(){return["wc-cart-table-headers","wc-cart-product-image","wc-cart-product-name","wc-cart-product-price","wc-cart-product-quantity","wc-cart-coupon-input","wc-cart-apply-coupon","wc-cart-update-button","wc-cart-details","wc-cart-details-header","wc-cart-details-row-header","wc-cart-price","wc-cart-active-shipping","wc-cart-shipping-method","wc-cart-shipping-text","wc-cart-shipping-address","wc-cart-change-address","wc-cart-to-checkout-button","wc-cart-product-list","wc-cart-related-heading","wc-cart-related-product-image","wc-cart-related-product-title","wc-cart-related-product-price","wc-cart-related-product-button","wc-cart-remove-product"]}initializeSelectors(){e(TVE.identifier("wc-cart-product-quantity")).find("input").attr("readonly","readonly"),e(TVE.identifier("wc-cart-coupon-input")).attr("readonly","readonly"),e(TVE.identifier("wc-cart-update-button")).prop("disabled",!1),s.subElements.forEach((e=>{const t=TVE.identifier(e);this.$template.find(t).each(((e,i)=>{i.classList.add("tve_no_icons"),i.classList.add("wc-element-cursor"),i.setAttribute("data-selector",t)}))})),this.$template.find(TVE.identifier("article")).addClass("tcb-selector-not_editable tcb-selector-no_highlight")}constructor(i){super(i),e(".cart tbody .product-quantity:not(:has(>div))").each((function(){e(this).wrapInner("<div class = 'quantity'></div>")})),e(t.document.body).on("updated_shipping_method",(t=>{e(".shipping input:checked").next("label").addClass("checked")})),t.tve_frontend_options.is_editor_page&&this.initializeSelectors()}}return s}},5422:function(e,t,i){e.exports=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:window;const n=i(5017)(t);class s extends n{static get subElements(){return["wc-input-label","wc-input-box","wc-textarea-input","wc-field-header","wc-ordered-product-name","wc-order-details-header","wc-ordered-product-price","wc-final-price","wc-checked-shipping-method","wc-unchecked-shipping-method","wc-place-order-button","wc-checked-payment-method","wc-unchecked-payment-method","wc-payment-method-description","wc-privacy-policy","wc-dropdown","wc-additional-section","wc-additional-section-anchor","wc-paypal-info"]}initializeSelectors(){e(TVE.identifier("wc-input-box")).attr("readonly","readonly"),e(TVE.identifier("wc-dropdown")).on("mousedown",(function(){setTimeout((()=>this.blur()),0)})),s.subElements.forEach((e=>{const t=TVE.identifier(e);this.$template.find(t).each(((e,i)=>{i.classList.add("tve_no_icons"),i.classList.add("wc-element-cursor"),i.setAttribute("data-selector",t)}))}))}constructor(i){super(i),this.addNecessaryClasses(),e(t.document.body).on("updated_checkout",((t,i)=>{"success"===i.result&&(this.addNecessaryClasses(),e("#payment .input-radio").click((()=>{e("#payment .checked").removeClass("checked"),e("#payment input:checked").parent("li").addClass("checked")})))})),t.tve_frontend_options.is_editor_page&&this.initializeSelectors()}addNecessaryClasses(){e("#shipping_method input:checked").next("label").addClass("checked").find("span, bdi").addClass("checked"),e("#payment input:checked").parent("li").addClass("checked"),e(".woocommerce-table .product-purchase-note td").addClass("thrv_text_element")}}return s}},5168:function(e,t,i){e.exports=(e,t)=>{const n=i(5017)(t);class s extends n{static get subElements(){let e=["wc-product-short-description","wc-product-main-add-to-cart","wc-product-add-to-cart","wc-product-star-rating","wc-product-category","wc-product-category-links","wc-product-sku","wc-product-gallery","wc-product-image","wc-product-title","wc-product-price","wc-product-out-of-stock","wc-product-sale","wc-product-tags","wc-product-tags-links","wc-product-customer-review-count","wc-product-quantity","wc-product-select","wc-product-select-label","wc-product-tab","wc-product-description-content","wc-product-additional-label","wc-product-additional-value","wc-product-upsells-heading","wc-product-related-heading","wc-product-review-empty-text","wc-product-review-first-text","wc-product-review-label","wc-product-review-star-rating","wc-product-review-textarea","wc-product-review-submit","wc-product-review-author","wc-product-review-author-image","wc-product-review-date","wc-product-review-comment","wc-product-review-item-star-rating","wc-product-review-container","wc-product-review-only-logged-in-text"];return s.isProductAddonPluginActive()&&(e=[...e,"wc-product-add-on-title","wc-product-add-on-description","wc-product-add-on-text-field","wc-product-add-on-remaining-characters","wc-product-add-on-dropdown","wc-product-add-on-checkbox","wc-product-add-on-radio-button","wc-product-add-on-product-name","wc-product-add-on-product-price"]),e}static get selector(){return".product-template-wrapper"}static get gallerySelector(){return".woocommerce-product-gallery"}constructor(){if(super(arguments.length>0&&void 0!==arguments[0]?arguments[0]:null),this.$template.length){const e=this.$template.find(".post-wrapper.product ");this.ID=e.length?parseInt(e.attr("id").replace("product-","")):0,this.$gallery=this.$template.find(s.gallerySelector)}s.isProductAddonPluginActive()&&(this.$template.find(".wc-pao-addon-container p:has(.wc-pao-addon-radio)").addClass("addon-radio-button"),this.$template.find(".wc-pao-addon-container p:has(.wc-pao-addon-checkbox)").addClass("addon-checkbox")),this.init()}initializeSelectors(){s.isProductAddonPluginActive()&&(e(TVE.identifier("wc-product-add-on-dropdown")).on("mousedown",(e=>e.preventDefault())),e(TVE.identifier("wc-product-add-on-text-field")).attr("readonly","readonly")),[".upsells",".related"].forEach((e=>this.$template.find(e).attr("data-selector",`${e}.products`))),s.subElements.forEach((e=>{const t=TVE.identifier(e);this.$template.find(t).each(((e,i)=>{let n=TVE.identifier("product-template");const s=i.closest(".products[data-selector]");s?n=t.includes(s.dataset.selector)?n:`${n} ${s.dataset.selector}`:i.closest(".woocommerce-tabs")?n=`${n} .woocommerce-tabs`:i.closest(".summary")&&(n=`${n} .summary`),i.classList.add("tve_no_icons"),i.classList.add("wc-element-cursor"),i.setAttribute("data-selector",t.split(",").map((e=>`${n} ${e}`)).join(", "))}))})),this.$template.find(TVE.identifier("article")).addClass("tcb-selector-not_editable tcb-selector-no_highlight"),this.$template.find("#respond").addClass("tcb-selector-not_editable tcb-selector-no_highlight"),this.$template.find(".single_add_to_cart_button").removeClass("disabled wc-variation-selection-needed"),TVE.CONST.theme.is_theme_template&&this.$template.find(".post-wrapper.product ").addClass("thrive-woocommerce-product-editable")}init(){this.toggleZoom(),t.tve_frontend_options.is_editor_page&&this.initializeSelectors()}toggleZoom(){return void 0!==t.wc_single_product_params&&(t.wc_single_product_params.zoom_enabled=!parseInt(this.$template.attr("data-hide-magnifier"))),this}tabsInit(){return this.$template.find(".wc-tabs-wrapper, .woocommerce-tabs, #rating").trigger("init"),this}selectTab(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"description";const t=TVE.Theme.$wrapper.find(`${s.selector} .woocommerce-tabs`);if(t.length){t.find(".wc-tabs > .active").removeClass("active"),t.find(".wc-tab").hide();let i,n=t.find(`#tab-title-${e}`);n.length?i=t.find(`#tab-${e}`):(n=t.find(".wc-tabs").children().first(),i=t.find(".wc-tab").first()),n.addClass("active"),i.show()}}redoGallery(){return this.$gallery.each(((i,n)=>{const s=e(n);s.trigger("wc-product-gallery-before-init",[n,t.wc_single_product_params]),s.wc_product_gallery(t.wc_single_product_params),s.trigger("wc-product-gallery-after-init",[n,t.wc_single_product_params])})),this}updateGalleryColumnsClass(e){void 0===e&&(e=this.getData("gallery-columns"));let t=this.$gallery.attr("class");t=t.replace(/woocommerce-product-gallery--columns-\d/g,`woocommerce-product-gallery--columns-${e}`),this.$gallery.attr("class",t)}initializeProductViewCartButtons(e){e.find(".ajax_add_to_cart").removeClass("ajax_add_to_cart");const t=e.find(".add_to_cart_button"),i=e.find("a.added_to_cart"),n=()=>{t.after('<a class="added_to_cart" style="display:none;"></div>')};0===i.length?n():t.length!==i.length&&(i.remove(),n())}updateProductsSection(t){const i={};return(arguments.length>1&&void 0!==arguments[1]?arguments[1]:["columns","posts_per_page","orderby","order"]).forEach((e=>{i[e]=this.getData(e,t)})),this.ajaxRenderFunction(t,i).done((i=>{i.content&&this.getProductsSection(t).html(e(i.content).html()),this.initializeProductViewCartButtons(this.$template),this.initializeSelectors()}))}static defaultAttr(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";const t={"align-items":"left","related-align-items":"left","upsells-align-items":"left",columns:4,"gallery-columns":4,"related-columns":4,"upsells-columns":4,posts_per_page:8,"related-posts_per_page":4,"upsells-posts_per_page":4,orderby:"date","related-orderby":"rand","upsells-orderby":"rand",order:"desc","related-order":"desc","upsells-order":"desc","show-related":!1,"hide-magnifier":!1};return e?t[e]:t}static isProductAddonPluginActive(){return t.tve_frontend_options.woocommerce_related_plugins.product_addons}}return s}},6990:function(e,t,i){e.exports=(e,t)=>{const n=i(5017)(t);class s extends t.TCB_Front.woocommerce.Shop{static get selector(){return".shop-template-wrapper"}updateProductsSection(){const e={};return(arguments.length>1&&void 0!==arguments[1]?arguments[1]:["columns","posts_per_page","orderby","order"]).forEach((t=>{e[t]=this.getData(t)})),new n(this.$template).ajaxRenderFunction("shop",e).done((e=>{e.content&&(this.$template.html(e.content),this.toggleProductElements(),this.initializeCartButtons(this.$template),TVE.WooCommerceFn.content.initShopSubElements(this.$template))}))}}return s}},5037:function(e,t,i){(t=>{const n=i(2952);class s extends n{static get identifier(){return".landingpage-section"}static get component(){return TVE.Components.landingpage_section}get baseSelector(){return`.${this.type}-section`}static get contentSelector(){return".section-content"}static get backgroundSelector(){return".section-background"}static get contentWidthVariable(){return"--page-section-max-width"}static selectionSelector(){return".landingpage-section > div"}static isLPSection(e){return e.is(this.identifier)}get contentWidth(){return TVE.head_css_get(`${this.baseSelector} ${s.contentSelector}`,"max-width")}isHorizontal(){return!0}isVertical(){return!1}static getTemplateId(){return TVE.CONST.post_id}static getLoadArguments(){return{query_vars:{post_type:TVE.CONST.post_type,page_id:TVE.CONST.post_id}}}getWidth(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"content";return TVE.Editor_Page.editor.tcbCss(`--${this.type}-${e}-width`)}inheritsContent(){return this.contentWidth.includes(s.contentWidthVariable)}setContentWidth(e){arguments.length>1&&void 0!==arguments[1]&&!arguments[1]?this.$content.tcbCss("max-width",`${e}!important`):(TVE.head_css(`${this.baseSelector} ${s.contentSelector}`,{"max-width":`${e}!important`}),this.$content.tcbCss("max-width",""))}getExtra(){const e={decoration:this.getDecoration(),attr:this.getAttributes()};return TVE.apply_filters("theme.section.data.extra",e,this)}static isOnSingularTemplate(){return!0}static saveTemplate(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];TVE.Editor_Page.save(!0,void 0,void 0,e)}toggle(){let e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];this.isPlaceholder()?this.constructor.component.sectionSelect.setSection(this).openSectionsModal():super.toggle(e)}openModal(){this.isPlaceholder()&&this.constructor.component.sectionSelect.setSection(this).openSectionsModal()}isPlaceholder(){return this.$element.hasClass("placeholder-section")}toggleFullWidthBackground(e){TVE.inner.$body.toggleClass(`tcb-full-${this.type}`,e)}hasFullWidthBackground(){return TVE.inner.$body.hasClass(`tcb-full-${this.type}`)}static getEditorContentWidth(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=TVE.Editor_Page.editor.tcbCss(s.contentWidthVariable);return!e||t&&!t.includes("%")||(t=TVE.Editor_Page.editor.css("width")),t}hasFullWidthContent(){const e=this.contentWidth;return"100%"===e||0===e.length}getBlockTarget(){return this.$element}allowBlockControlsBelow(){return"bottom"!==this.type}afterInsert(e){TVE.Theme.FLAGS.duringImport=!1,TVE.froala.init(),this.focus(),this.fixTypography(),TVE.Theme.content.init_selectors(this.$element),this.constructor.saveTemplate(!0),TVE.do_action("theme.section.after_insert",e,this),TVE.do_action(`theme.section.after_insert.${this.type}`,e,this),TVE.do_action("tcb.new-editor-content",this.$element),TVE.Theme.utils.loadingMessage(!1),this.bindElementActions()}fixTypography(e){let t=`${this.selector} ${s.contentSelector}`,i="";this.isDynamic()||(t=TVE.Theme.CONST.body_class+" "+t),i=[" p"," li"," label"," .tcb-plain-text"].map((e=>t+e)).join(", "),void 0===e&&(e=TVE.stylesheet.cssRules);for(let n=0;n<e.length;n++)if(e[n].type===CSSRule.MEDIA_RULE)for(let s=0;s<e[n].cssRules.length;s++){const o=e[n].cssRules[s];if(o.selectorText.includes(i)&&!o.selectorText.includes(TVE.CONST.global_css_prefix)){const i=o.cssText.replace(TVE.Theme.utils.escapedRegEx(`${t}`,"g"),`${TVE.CONST.global_css_prefix} ${t}`);e[n].deleteRule(s),e[n].insertRule(TVE.remove_extra_spaces(i),s)}}}}e.exports=s})(jQuery)}},t={};function i(n){var s=t[n];if(void 0!==s)return s.exports;var o=t[n]={exports:{}};return e[n](o,o.exports,i),o.exports}!function(){function e(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function t(t){for(var i=1;i<arguments.length;i++){var s=null!=arguments[i]?arguments[i]:{};i%2?e(Object(s),!0).forEach((function(e){n(t,e,s[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(s)):e(Object(s)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(s,e))}))}return t}function n(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}jQuery(window).on("tcb_main_ready",(()=>{TVE.CONST.theme.is_theme_template&&(TVE.main.on("tve.tve_save_post",(e=>{e.preventSave=!0,e.return=TVE.Theme.content.save()})),TVE.Theme.switchContent=new TVE.Theme.views.SwitchContent,TVE.Theme.modals.sectionTemplates=new(i(7287))({el:TVE.modal.get_element("section-templates-block")}),TVE.Theme.modals.sectionSave=new(i(6802))({el:TVE.modal.get_element("section-save")}),TVE.CONST.debug_mode&&TVE.Theme.utils.addDebugButton())})).on("tcb.register-hooks",(()=>{TVE.Theme=t(t({},TVE.Theme||{}),{},{selectedSection:null,$wrapper:null,FLAGS:{},modals:{},data:{cloud:{},local:{}},utils:i(8673),content:i(7459),constants:TVE.apply_filters("theme.constants",i(2907)),selectors:i(1732),models:i(569)}),TVE.Theme.template=new TVE.Theme.models.Template(TVE.CONST.theme.template),_.each(TVE.Theme.selectors.editor.architect,((e,t)=>{e.length&&TVE.add_filter("selectors_"+t,(t=>t+","+e.join(",")))})),i(5669).forEach((e=>{let t=10,i=e.tag;i.includes("|")&&([i,t]=e.tag.split("|")),TVE.add_filter(i,e.callback,t)})),i(355).forEach((e=>{let t=10,i=e.tag;i.includes("|")&&([i,t]=e.tag.split("|")),TVE.add_action(i,e.callback,t)})),_.each(i(3302),((e,t)=>TVE.add_action(t,e))),_.each(i(1606),((e,t)=>TVE.add_filter(t,e)))}))}()}();