/
var
/
www
/
barefootlaw.org
/
wp-content
/
plugins
/
archub-elementor-addons
/
assets
/
js
/
Upload File
HOME
!function(){"use strict";class e extends elementorModules.ViewModule{getDefaultSettings(){return{editorPreferencesModel:elementor.settings.editorPreferences.model,darkModeLinkID:"liquid-elementor-editor-style-dark-css"}}getDefaultElements(){const e=this.getSettings("darkModeLinkID");return{$darkModeLink:jQuery(`#${e}`)}}bindEvents(){this.getSettings("editorPreferencesModel").on("change:ui_theme",this.checkStyle,this)}onInit(){super.onInit(),this.$link=this.createLink(),this.checkStyle()}createLink(){return this.elements.$darkModeLink.length?this.elements.$darkModeLink:jQuery("<link>",{id:this.getSettings("darkModeLinkID"),rel:"stylesheet",href:this.elements.$darkModeLink.attr("href")})}checkStyle(){const e=this.getSettings("editorPreferencesModel");if("light"===e.get("ui_theme"))return void this.$link.remove();let t=setTimeout((()=>{this.$link.attr("media","auto"===e.get("ui_theme")?"(prefers-color-scheme: dark)":"").appendTo(elementorCommon.elements.$body),clearTimeout(t)}),150)}}const t=Backbone.Model.extend({defaults:{isStuck:!1,isOverLight:!1,isOverDark:!1,currentBgColor:null,backgrounds:{light:"#fff",dark:"#1a1a1a"},classnames:{stickyHeader:"is-stuck",overLightRow:"lqd-active-row-light",overDarktRow:"lqd-active-row-dark"},selectors:{mainHeader:".main-header",dynamicColorElements:".main-header, .main-header > .elementor > .elementor-section > .elementor-container > .elementor-column > .elementor-widget-wrap > .elementor-element"}}}),s=Backbone.View.extend({id:"lqd-header-sim-states",template:_.template('<div class="lqd-header-sim-title"><h3>Simulator</h3></div><button id="lqd-header-sim-sticky" class="lqd-header-sim-btn"><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-credit-card"><rect x="1" y="4" width="22" height="16" rx="2" ry="2"/><rect x="1" y="4" width="22" height="7" rx="2" ry="2" fill="currentColor" stroke="none"></rect></svg><span>Sticky</span></button>\n <button id="lqd-header-sim-light-bg" class="lqd-header-sim-btn" data-scheme="light"><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-sun"><circle cx="12" cy="12" r="5"/><line x1="12" y1="1" x2="12" y2="3"/><line x1="12" y1="21" x2="12" y2="23"/><line x1="4.22" y1="4.22" x2="5.64" y2="5.64"/><line x1="18.36" y1="18.36" x2="19.78" y2="19.78"/><line x1="1" y1="12" x2="3" y2="12"/><line x1="21" y1="12" x2="23" y2="12"/><line x1="4.22" y1="19.78" x2="5.64" y2="18.36"/><line x1="18.36" y1="5.64" x2="19.78" y2="4.22"/></svg><span>Light</span></button>\n <button id="lqd-header-sim-dark-bg" class="lqd-header-sim-btn" data-scheme="dark"><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-moon"><path d="M21 12.79A9 9 0 1 1 11.21 3 7 7 0 0 0 21 12.79z"/></svg><span>Dark</span></button>\n <button id="lqd-header-sim-reset-bg" class="lqd-header-sim-btn" data-scheme="reset"><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-rotate-ccw"><polyline points="1 4 1 10 7 10"/><path d="M3.51 15a9 9 0 1 0 2.13-9.36L1 10"/></svg><span>Reset</span></button>'),events:{"click #lqd-header-sim-sticky":"simSticky","click #lqd-header-sim-light-bg, #lqd-header-sim-dark-bg, #lqd-header-sim-reset-bg":"setScheme"},$body:null,$mainHeader:null,initialize:function(){this.render(),this.$el.appendTo("body"),this.listenTo(this.model,"change:isStuck",this.onStuckChange),this.listenTo(this.model,"change:isOverLight",this.onSchemeChange),this.listenTo(this.model,"change:isOverDark",this.onSchemeChange)},render:function(){return this.$el.html(this.template()),this},simSticky:function(e){this.model.set("isStuck",!this.model.get("isStuck")),e.currentTarget.classList.toggle("active",this.model.get("isStuck"))},setBgColor:function(e){const t=e.currentTarget.dataset.bgColor;this.model.set("currentBgColor",t)},setScheme:function(e){switch(e.currentTarget.dataset.scheme){case"light":this.model.set({isOverLight:!0,isOverDark:!1});break;case"dark":this.model.set({isOverLight:!1,isOverDark:!0});break;default:this.model.set({isOverLight:!1,isOverDark:!1})}},onStuckChange:function(e,t){const{stickyHeader:s}=this.model.get("classnames");this.getMainHeader().toggleClass(s,t)},onSchemeChange:function(){const{overLightRow:e,overDarktRow:t}=this.model.get("classnames"),{dynamicColorElements:s}=this.model.get("selectors"),{light:i,dark:n}=this.model.get("backgrounds"),{changed:r}=this.model,o=elementorFrontend.elements.$document.find(s),a=this.getBody();this.$el.find("[data-scheme]").removeClass("active"),o.add(this.$el).removeClass([e,t]),a.css("background-color",""),r.isOverLight&&(o.add(this.$el).addClass(e),a.css("background-color",i),this.$el.find("[data-scheme=light]").addClass("active")),r.isOverDark&&(o.add(this.$el).addClass(t),a.css("background-color",n),this.$el.find("[data-scheme=dark]").addClass("active"))},getMainHeader(){if(this.$mainHeader)return this.$mainHeader;const{mainHeader:e}=this.model.get("selectors");return elementorFrontend.elements.$document.find(e)},getBody(){return this.$body?this.$body:elementorFrontend.elements.$body}});class i extends Marionette.Behavior{initialize(){super.initialize(),_.defer((()=>{const e=this.view.model.get("settings");this.listenTo(e,"change:liquid_columns_wrap",this.onColumnWrapChange),this.handleResize(e.get("liquid_columns_wrap"))}))}onColumnWrapChange({changed:e}){this.handleResize(e.liquid_columns_wrap)}handleResize(e){const t=["resize-column","resize-column-limit"];"yes"===e?t.forEach((e=>{$e.hooks.data.callbacksFlatList[e].deactivate()})):t.forEach((e=>{$e.hooks.data.callbacksFlatList[e].activate()}))}}var $;elementor.hooks.addFilter("elements/section/behaviors",((e,t)=>(e.liquidColumnsWrap={behaviorClass:i},t.adjustColumns=function(){if("yes"===this.model.get("settings").get("liquid_columns_wrap"))return;const e=elementor.presetsFactory.getPresetByStructure(this.getStructure());this.children.each(((t,s)=>{const i=t.getContainer();$e.run("document/elements/settings",{container:i,settings:{_column_size:e.preset[s],_inline_size:null}})}))},e))),($=jQuery)(window).on("load",(()=>{_.defer((()=>{const i=$("body"),n=ElementorConfig.document.urls.permalink.search(/liquid-header/g)>=0,r=ElementorConfig.document.urls.permalink.search(/liquid-footer/g)>=0;if(n){i.addClass("single-liquid-header");const e=new t;new s({model:e})}r&&i.addClass("single-liquid-footer"),new e,function($){elementor.channels.editor.on("lqd_page_refresh",(async()=>{const e=$(".liquid-page-refresh");e.attr("disabled",!0),elementor.saver.isEditorChanged()||_.defer((()=>{e.removeAttr("disabled")})),await $e.run("document/save/update",{force:!0}),elementor.reloadPreview(),elementor.once("preview:loaded",(()=>{_.defer((()=>{e.removeAttr("disabled"),$e.route("panel/page-settings/settings")}))}))}))}($)}))}))}(); //# sourceMappingURL=liquid-elementor-fe.min.js.map