.astra-widget-social-profiles-inner li>a{-js-display:flex;display:flex;align-items:center}.astra-widget-social-profiles-inner li>a .ast-widget-icon{margin-right:.3em}.astra-widget-social-profiles-inner li>a{margin-bottom:.3em}.astra-widget-social-profiles-inner.stack li>a{margin-right:0}.astra-widget-social-profiles-inner .ast-widget-icon{-js-display:flex;display:flex;align-self:center;justify-content:center;width:1em;transition:all .1s linear}.astra-widget-social-profiles-inner .ast-widget-icon svg{-ms-grid-row-align:center;align-self:center}.astra-widget-social-profiles-inner .ast-widget-icon{vertical-align:middle}.astra-widget-social-profiles-inner.inline li{-js-display:inline-flex;display:inline-flex;text-align:center}.astra-widget-social-profiles-inner.circle-outline .ast-widget-icon,.astra-widget-social-profiles-inner.square-outline .ast-widget-icon{border-width:1px;border-style:solid;border-color:#00000033}.astra-widget-social-profiles-inner.circle .ast-widget-icon,.astra-widget-social-profiles-inner.circle-outline .ast-widget-icon{border-radius:50%}.astra-widget-social-profiles-inner.circle .ast-widget-icon,.astra-widget-social-profiles-inner.circle-outline .ast-widget-icon,.astra-widget-social-profiles-inner.square .ast-widget-icon,.astra-widget-social-profiles-inner.square-outline .ast-widget-icon{height:2em;width:2em;text-align:center;vertical-align:middle}.astra-widget-social-profiles-inner .ast-widget-icon{font-size:15px;line-height:2}.astra-widget-social-profiles-inner.circle .ast-widget-icon,.astra-widget-social-profiles-inner.circle-outline .ast-widget-icon{line-height:2}.astra-widget-social-profiles .astra-widget-social-profiles-inner ul li a{transition:all .1s linear}.astra-widget-social-profiles-inner.circle-outline li .ast-widget-icon svg{transition:all .1s linear}.astra-widget-social-profiles-inner.circle-outline li .ast-widget-icon:hover svg,.astra-widget-social-profiles-inner.square-outline li .ast-widget-icon:hover svg{transition:all .1s linear}
Nada foi encontrado. Tente pesquisar palavras diferentes.
/**
* Edit Element Panel View
* It is used to edit the settings of a shortcode in the editor.
*/
/* global vc, i18nLocale */
( function ( $ ) {
'use strict';
/**
* Shortcode settings panel
*
* @type {*}
*/
window.vc.EditElementPanelView = vc.PanelView
.vcExtendUI( vc.HelperAjax )
.vcExtendUI( vc.HelperEditPanelCache )
.vcExtendUI( vc.HelperEditorElementsAjaxCache )
.vcExtendUI( vc.HelperAddElementEditPanelAjaxCache )
.vcExtendUI( vc.ExtendPresets )
.vcExtendUI( vc.ExtendTemplates )
.vcExtendUI( vc.HelperPrompts )
.extend({
panelName: 'edit_element',
el: '#vc_properties-panel',
// there is more than 1 element with vc_properties-list class name, so we need to increase specificity
contentSelector: '.vc_ui-panel-content.vc_properties-list',
minimizeButtonSelector: '[data-vc-ui-element="button-minimize"]',
closeButtonSelector: '[data-vc-ui-element="button-close"]',
titleSelector: '.vc_panel-title',
tabsInit: false,
doCheckTabs: true,
$tabsMenu: false,
dependent_elements: {},
mapped_params: {},
draggable: false,
panelInit: false,
$spinner: false,
activeTabIndex: 0,
buttonMessageTimeout: false,
// @deprecated 4.7
notRequestTemplate: false,
requiredParamsInitialized: false,
currentModelParams: false,
customButtonMessageTimeout: false,
events: {
'click [data-save=true]': 'save',
'click [data-dismiss=panel]': 'hide',
'mouseover [data-transparent=panel]': 'addOpacity',
'click [data-transparent=panel]': 'toggleOpacity',
'mouseout [data-transparent=panel]': 'removeOpacity'
},
formRender: function () {
var _this = this;
var typingTimer = null;
var typingInterval = 500;
this.$el.find( '.vc_edit-form-tab' ).on( 'input change', function ( e ) {
clearTimeout( typingTimer );
// Need to set vc.saveInProcess to true to prevent the console error from the hide method (this.model === null)
// This happens when the panel is closed and the change event is triggered (if the input had focus) simultaneously.
vc.saveInProcess = true;
typingTimer = setTimeout( function () {
_this.save( e );
}, typingInterval );
});
},
initialize: function () {
_.bindAll( this,
'setSize',
'setTabsSize',
'fixElContainment',
'hookDependent',
'resetAjax',
'removeAllPrompts' );
this.on( 'setSize', this.setResize, this );
this.on( 'render', this.resetMinimize, this );
this.on( 'render', this.setTitle, this );
this.on( 'render', this.prepareContentBlock, this );
if ( window.vc_auto_save ) {
this.on( 'afterRender', this.formRender, this );
}
this.on( 'afterRender', function () {
$( '.edit-form-info' ).initializeTooltips();
this.reInitJsFunctions();
}, this );
},
reInitJsFunctions: function () {
// Add event listener when shortcode is updated
// To trigger re-initialize the JS functions for libraries like flexslider, progress bar, accordion, etc.
// the window.vc.frame_window.vc_js is located in assets/js/js_composer_front.js file
try {
if ( window.vc.frame_window && window.vc.frame_window.vc_js ) {
vc.events.on( 'shortcodeView:updated', window.vc.frame_window.vc_js );
}
} catch ( error ) {
console.error( 'Failed to execute window.vc.frame_window.vc_js function in reInitJsFunctions(): ', error );
}
},
setCustomButtonMessage: function ( $btn, message, type, showInBackend ) {
var currentTextHtml;
if ( 'undefined' === typeof $btn ) {
$btn = this.$el.find( '[data-vc-ui-element="button-save"]' );
}
if ( 'undefined' === typeof ( showInBackend ) ) {
showInBackend = false;
}
// binding to context
this.clearCustomButtonMessage = _.bind( this.clearCustomButtonMessage, this );
// we can show only if frontend and only if old message cleared (to avoid double execution)
if ( ( !showInBackend && !vc.frame_window ) || this.customButtonMessageTimeout ) {
return this;
}
if ( 'undefined' === typeof ( message ) ) {
message = window.i18nLocale.ui_saved;
}
if ( 'undefined' === typeof ( type ) ) {
type = 'success';
}
currentTextHtml = $btn.html();
$btn
.addClass( 'vc_ui-button-' + type + ' vc_ui-button-undisabled' )
.removeClass( 'vc_ui-button-action' )
.data( 'vcCurrentTextHtml', currentTextHtml )
.data( 'vcCurrentTextType', type )
.html( message );
_.delay( this.clearCustomButtonMessage.bind( this, $btn ), 5000 );
this.customButtonMessageTimeout = true;
return this;
},
clearCustomButtonMessage: function ( $btn ) {
var type, currentTextHtml;
if ( this.customButtonMessageTimeout ) {
window.clearTimeout( this.customButtonMessageTimeout );
currentTextHtml = $btn.data( 'vcCurrentTextHtml' ) || 'Save';
type = $btn.data( 'vcCurrentTextType' );
$btn.html( currentTextHtml )
.removeClass( 'vc_ui-button-' + type + ' vc_ui-button-undisabled' )
.addClass( 'vc_ui-button-action' );
this.customButtonMessageTimeout = false;
}
},
showPanel: function ( element ) {
element.css( 'visibility', 'visible' );
element.css( 'opacity', '1' );
},
hidePanel: function ( element ) {
element.css( 'visibility', 'hidden' );
element.css( 'opacity', '0' );
},
/**
*
* @param model
* @param isUsageCount
* @param toCache
* @returns {vc.EditElementPanelView}
*/
render: function ( model, isUsageCount, toCache = false ) {
this.model = model;
var modelId = this.model.get( 'id' );
if ( toCache ) {
this.addEditPanelToCache( modelId, this.$el );
return this.processRender( model, isUsageCount, true );
} else {
if ( this.isEditPanelCached( modelId ) ) {
this.showPanel( window.vc.editPanelCache.element );
this.removeEditPanelCache();
} else {
vc.closeActivePanel();
return this.processRender( model, isUsageCount );
}
}
},
processRender: function ( model, isUsageCount, isHidden = false ) {
var params;
this.model = model;
this.currentModelParams = this.model.get( 'params' );
vc.active_panel = this;
this.resetMinimize();
this.clicked = false;
this.$el.css( 'height', 'auto' );
this.$el.css( 'maxHeight', '75vh' );
if ( isHidden ) {
this.hidePanel( this.$el );
} else {
this.showPanel( this.$el );
}
params = this.model.setting( 'params' ) || [];
var tag = this.model.get( 'shortcode' );
this.$el.attr( 'data-vc-shortcode', tag );
this.tabsInit = false;
this.panelInit = false;
this.activeTabIndex = 0;
this.requiredParamsInitialized = false;
this.mapped_params = {};
this.dependent_elements = {};
_.each( params, function ( param ) {
this.mapped_params[ param.param_name ] = param;
}, this );
this.trigger( 'render' );
this.show();
this.processRenderAjax( tag, model, isUsageCount ).then();
return this;
},
processRenderAjax: async function ( tag, model, isUsageCount ) {
var modelId = this.model.get( 'id' );
var isAddElement = model.attributes && model.attributes.is_add_element;
// we cache ajax for add element panel here.
if ( isAddElement && await this.waitAddElementEditPanelAjaxCache( tag ) ) {
delete model.attributes.is_add_element;
this.buildParamsContent( this.getAddElementEditPanelAjaxCache( tag ) );
// we cache ajax for edit panel for editor elements here.
} else if ( this.isEditPanelEditorElementAjaxCached( modelId ) ) {
this.buildParamsContent( this.getEditPanelEditorElementAjaxCache( modelId ) );
} else {
this.checkAjax();
this.ajax = $.ajax({
type: 'POST',
url: window.ajaxurl,
data: this.ajaxData( isUsageCount ),
context: this
}).done( this.buildParamsContent ).always( this.resetAjax );
}
},
prepareContentBlock: function () {
this.$content = this.$el.find( this.contentSelector ).removeClass( 'vc_with-tabs' );
this.$content.empty(); // if pressed multiple times
this.$spinner = $( '' );
this.$content.prepend( this.$spinner );
},
buildParamsContent: function ( data ) {
var $data, $tabs, $panelHeader, $panelTab;
var modelId = this.model.get( 'id' );
this.setEditPanelEditorElementAjaxCache( modelId, data );
var externalScripts = this.getExternalScriptsFromDataHtml( data );
data = this.removeExternalScriptsFromDataHtml( data );
$data = $( data );
$tabs = $data.find( '[data-vc-ui-element="panel-tabs-controls"]' );
$tabs.find( '.vc_edit-form-tab-control:first-child' ).addClass( 'vc_active' );
$panelHeader = this.$el.find( '[data-vc-ui-element="panel-header-content"]' );
$panelTab = $data.find( '[data-vc-ui-element="panel-edit-element-tab"]' );
// Hide panel parts until render is completed
if ( $panelTab ) {
$panelTab.addClass( 'visually-hidden' );
}
if ( $panelHeader ) {
$panelHeader.addClass( 'visually-hidden' );
}
var $content = this.$content.html ( $data );
this.loadScriptsSequentially( externalScripts, function () {
// we use this flag to check if all our scripts related to edit form are loaded.
// and we ready to show edit element form content.
$content.append( '' );
});
// Add spinner again since it is removed with content html
this.$content.prepend( this.$spinner );
$tabs.prependTo( $panelHeader );
var _self = this;
// render even if something fails after (1000*100ms = 100s)
var counter = 0;
var cb = function () {
if ( !window.wpb_edit_form_loaded && counter < 1000 ) {
counter++;
setTimeout( cb, 100 );
return;
}
_self.$content.removeAttr( 'data-vc-param-initialized' );
_self.activeTabIndex = 0;
_self.tabsInit = false;
_self.panelInit = false;
_self.dependent_elements = {};
_self.requiredParamsInitialized = false;
_self.$content.find( '[data-vc-param-initialized]' ).removeAttr( 'data-vc-param-initialized' );
// Show panel and remove spinner
_self.showPanelContent( $panelTab );
/**
* @deprecated 4.7
*/
_self.$el.trigger( 'vcPanel.shown' ); // old stuff
_self.trigger( 'afterRender' );
vc.events.trigger( 'editElementPanel:ready' );
};
window.setTimeout( cb, 10 );
},
getExternalScriptsFromDataHtml: function ( data ) {
var externalScripts = [];
var regex = this.getExternalScriptRegex();
var match;
while ( match = regex.exec( data ) ) {
externalScripts.push( match[1]);
}
return externalScripts;
},
removeExternalScriptsFromDataHtml: function ( data ) {
return data.replace( this.getExternalScriptRegex(), '' );
},
getExternalScriptRegex: function () {
return /
Leave In Splendida Blond - Loja Gior Scarpetto's
Skip to content