first commit

This commit is contained in:
2024-07-15 11:28:08 +02:00
commit f52d538ea5
21891 changed files with 6161164 additions and 0 deletions

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@@ -0,0 +1 @@
.jet-location-edit{position:relative}.jet-location-edit__link{position:absolute;opacity:0;top:0;left:0;right:0;bottom:0;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-transition:opacity 200ms linear;transition:opacity 200ms linear;border:4px solid #71d7f7;background:rgba(113,215,247,0.2);color:#fff;z-index:99999;cursor:pointer;font-weight:400;font-size:16px;font-family:-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif}.jet-location-edit__link-content{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;background-image:-webkit-gradient(linear, left top, left bottom, from(#41c9f4), to(#71d7f7));background-image:linear-gradient(to bottom, #41c9f4, #71d7f7);padding:4px 15px 6px 10px}.jet-location-edit__link .dashicons{margin-right:4px}.jet-location-edit:hover .jet-location-edit__link{color:#fff;opacity:1;text-decoration:none}.elementor-add-new-section .add-jet-template{color:#fff;background-image:none;background:#398ffc !important;font-size:13px;font-family:Arial, Helvetica, sans-serif;font-weight:normal;font-style:normal;text-transform:uppercase;line-height:1;height:40px;min-width:170px;padding:0 20px;border:none;border-radius:3px;cursor:pointer;margin-right:25px;-webkit-transition:all 0.5s;transition:all 0.5s;display:-webkit-inline-box;display:-ms-inline-flexbox;display:inline-flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;vertical-align:bottom}.elementor-add-new-section .add-jet-template svg{width:17px;margin:-2px 9px 0px -3px}.elementor-add-new-section .add-jet-template:hover{opacity:0.85;-webkit-box-shadow:0 0 2px rgba(0,0,0,0.12),0 2px 2px rgba(0,0,0,0.2);box-shadow:0 0 2px rgba(0,0,0,0.12),0 2px 2px rgba(0,0,0,0.2)}

View File

@@ -0,0 +1 @@
.jet-template-types-popup{display:none;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;position:fixed;top:0;left:0;right:0;bottom:0;z-index:999}.jet-template-types-popup.jet-template-types-popup-active{display:-webkit-box;display:-ms-flexbox;display:flex}.jet-template-types-popup__overlay{position:absolute;left:0;right:0;top:0;bottom:0;background:rgba(0,0,0,0.8);z-index:1;-webkit-transition:opacity 200ms linear;transition:opacity 200ms linear;opacity:0;z-index:1000}.jet-template-types-popup-active .jet-template-types-popup__overlay{opacity:1}.jet-template-types-popup__content{background:#fff;padding:40px;width:500px;position:relative;z-index:2;-webkit-transition:opacity 200ms linear;transition:opacity 200ms linear;opacity:0;z-index:1001}.jet-template-types-popup-active .jet-template-types-popup__content{opacity:1}.jet-template-types-popup__heading{margin:0 0 20px}.jet-template-types-popup__form-row{padding:0 0 20px}.jet-template-types-popup__form-row label{display:block;padding:0 0 4px}.jet-template-types-popup__form-row input,.jet-template-types-popup__form-row select{width:100%;padding:10px 20px;line-height:20px;height:auto}.jet-template-types-popup__form-actions button{width:100%}.jet-template-types-popup__error{border-color:#dc3232}.jet-conditions{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center}.jet-conditions-active{margin-left:10px;color:#39b54a}

View File

@@ -0,0 +1,9 @@
<svg enable-background="new 0 0 483.719 483.719" version="1.1" viewBox="0 0 483.719 483.719" xml:space="preserve" xmlns="http://www.w3.org/2000/svg">
<path fill="currentColor" d="m441.76 451l-153-194.43c-6.461 4.764-14.325 7.427-22.477 7.427-3.488 0-6.952-0.481-10.326-1.438l-17.934-5.081 171.96 218.53c3.993 5.072 9.917 7.715 15.902 7.715 4.38 0 8.782-1.414 12.499-4.327 8.762-6.913 10.283-19.62 3.376-28.393z"/>
<path fill="currentColor" d="m282.49 164.19l1.961 4.943 6.3 15.899 51.397-2.399c4.948-0.244 9.035-4.14 9.511-8.917 0.554-4.912-2.619-9.582-7.395-10.852l-51.615-13.836-9.511 14.207-0.648 0.955z"/>
<path fill="currentColor" d="m207.97 248.96l-1.624-0.458-4.343 3.603-13.177 10.907 19.063 50.513c1.488 3.872 5.264 6.469 9.398 6.469l2.054-0.213c4.885-1.011 8.25-5.362 7.997-10.377l-2.926-55.781-16.442-4.663z"/>
<path fill="currentColor" d="m223.62 62.903l2.208 2.817 2.59-0.165 17.061-1.091 14.366-52.222c2.915-10.599-11.341-17.028-17.354-7.826l-29.438 45.049 10.567 13.438z"/>
<path fill="currentColor" d="m102.8 206.58l-0.173-4.449-2.623-1.665-14.458-9.152-44.231 35.364c-8.574 6.856-0.844 20.421 9.425 16.536l52.69-19.93-0.63-16.704z"/>
<path fill="currentColor" d="m93.34 97.02l16.047-5.898 5.294-1.946 0.297-1.183 4.235-16.578-47.447-31.203c-9.18-6.036-19.688 5.531-12.8 14.09l34.374 42.718z"/>
<path fill="currentColor" d="m264.77 231.43c0.508 0.143 1.01 0.214 1.516 0.214 1.551 0 3.049-0.648 4.105-1.824 1.424-1.575 1.818-3.8 1.044-5.767l-25.289-63.743 38.167-56.967c1.178-1.753 1.248-4.019 0.202-5.852-0.995-1.723-2.814-2.779-4.787-2.779-0.122 0-0.253 5e-3 -0.376 0.016l-68.447 4.358-42.376-53.911c-1.075-1.348-2.683-2.116-4.379-2.116-0.376 0-0.753 0.041-1.138 0.119-2.054 0.442-3.689 2.006-4.215 4.054l-16.993 66.432-64.373 23.665c-1.985 0.726-3.376 2.517-3.599 4.619-0.234 2.093 0.762 4.136 2.542 5.268l57.94 36.694 2.602 68.527c0.081 2.109 1.349 3.988 3.273 4.85 0.728 0.326 1.503 0.483 2.257 0.483 1.281 0 2.549-0.436 3.555-1.279l52.791-43.748 65.978 18.687z"/>
</svg>

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 805 B

View File

@@ -0,0 +1,988 @@
(function( $ ) {
'use strict';
var JetThemeCoreData = window.JetThemeCoreData || {},
JetThemeEditor,
JetThemeViews,
JetThemeControlsViews,
JetThemeModules;
JetThemeViews = {
LibraryLayoutView: null,
LibraryHeaderView: null,
LibraryLoadingView: null,
LibraryErrorView: null,
LibraryBodyView: null,
LibraryCollectionView: null,
FiltersCollectionView: null,
LibraryTabsCollectionView: null,
LibraryTabsItemView: null,
FiltersItemView: null,
LibraryTemplateItemView: null,
LibraryInsertTemplateBehavior: null,
LibraryTabsCollection: null,
LibraryCollection: null,
CategoriesCollection: null,
LibraryTemplateModel: null,
CategoryModel: null,
TabModel: null,
KeywordsModel: null,
KeywordsView: null,
LibraryPreviewView: null,
LibraryHeaderBack: null,
LibraryHeaderInsertButton: null,
init: function() {
var self = this;
self.LibraryTemplateModel = Backbone.Model.extend( {
defaults: {
template_id: 0,
name: '',
title: '',
thumbnail: '',
preview: '',
source: '',
categories: [],
keywords: []
}
} );
self.CategoryModel = Backbone.Model.extend( {
defaults: {
slug: '',
title: ''
}
} );
self.CategoryModel = Backbone.Model.extend( {
defaults: {
slug: '',
title: ''
}
} );
self.TabModel = Backbone.Model.extend( {
defaults: {
slug: '',
title: ''
}
} );
self.KeywordsModel = Backbone.Model.extend( {
defaults: {
keywords: {}
}
} );
self.LibraryCollection = Backbone.Collection.extend( {
model: self.LibraryTemplateModel
} );
self.CategoriesCollection = Backbone.Collection.extend( {
model: self.CategoryModel
} );
self.LibraryTabsCollection = Backbone.Collection.extend( {
model: self.TabModel
} );
self.LibraryLoadingView = Marionette.ItemView.extend( {
id: 'jet-template-library-loading',
template: '#tmpl-jet-template-library-loading'
} );
self.LibraryErrorView = Marionette.ItemView.extend( {
id: 'jet-template-library-error',
template: '#tmpl-jet-template-library-error'
} );
self.KeywordsView = Marionette.ItemView.extend( {
id: 'jet-template-library-keywords',
template: '#tmpl-jet-template-library-keywords',
ui: {
keywords: '.jet-library-keywords'
},
events: {
'change @ui.keywords': 'onSelectKeyword'
},
onSelectKeyword: function( event ) {
var selected = event.currentTarget.selectedOptions[0].value;
JetThemeEditor.setFilter( 'keyword', selected );
}
} );
self.LibraryHeaderView = Marionette.LayoutView.extend( {
id: 'jet-template-library-header',
template: '#tmpl-jet-template-library-header',
ui: {
closeModal: '#jet-template-library-header-close-modal'
},
events: {
'click @ui.closeModal': 'onCloseModalClick'
},
regions: {
headerTabs: '#jet-template-library-header-tabs',
headerActions: '#jet-template-library-header-actions'
},
onCloseModalClick: function() {
JetThemeEditor.closeModal();
}
} );
self.LibraryPreviewView = Marionette.ItemView.extend( {
template: '#tmpl-jet-template-library-preview',
id: 'jet-template-library-preview',
ui: {
img: 'img'
},
onRender: function() {
this.ui.img.attr( 'src', this.getOption( 'preview' ) );
}
} );
self.LibraryHeaderBack = Marionette.ItemView.extend( {
template: '#tmpl-jet-template-library-header-back',
id: 'jet-template-library-header-back',
ui: {
button: 'button'
},
events: {
'click @ui.button': 'onBackClick',
},
onBackClick: function() {
JetThemeEditor.setPreview( 'back' );
}
} );
self.LibraryInsertTemplateBehavior = Marionette.Behavior.extend( {
ui: {
insertButton: '.jet-template-library-template-insert'
},
events: {
'click @ui.insertButton': 'onInsertButtonClick'
},
onInsertButtonClick: function() {
var templateModel = this.view.model,
options = {};
JetThemeEditor.layout.showLoadingView();
elementor.templates.requestTemplateContent(
templateModel.get( 'source' ),
templateModel.get( 'template_id' ),
{
data: {
tab: JetThemeEditor.getTab(),
page_settings: true
},
success: function( data ) {
if ( data.licenseError ) {
JetThemeEditor.layout.showLicenseError();
return;
}
JetThemeEditor.closeModal();
elementor.channels.data.trigger( 'template:before:insert', templateModel );
if ( null !== JetThemeEditor.atIndex ) {
options.at = JetThemeEditor.atIndex;
}
elementor.sections.currentView.addChildModel( data.content, options );
if ( data.page_settings ) {
elementor.settings.page.model.set( data.page_settings );
}
elementor.channels.data.trigger( 'template:after:insert', templateModel );
JetThemeEditor.atIndex = null;
}
}
);
}
} );
self.LibraryHeaderInsertButton = Marionette.ItemView.extend( {
template: '#tmpl-jet-template-library-insert-button',
id: 'jet-template-library-insert-button',
behaviors: {
insertTemplate: {
behaviorClass: self.LibraryInsertTemplateBehavior
}
}
} );
self.LibraryTemplateItemView = Marionette.ItemView.extend( {
template: '#tmpl-jet-template-library-item',
className: function() {
var urlClass = ' jet-template-has-url',
sourceClass = ' elementor-template-library-template-';
if ( '' === this.model.get( 'preview' ) ) {
urlClass = ' jet-template-no-url';
}
if ( 'jet-local' === this.model.get( 'source' ) ) {
sourceClass += 'local';
} else {
sourceClass += 'remote';
}
return 'elementor-template-library-template' + sourceClass + urlClass;
},
ui: function() {
return {
previewButton: '.elementor-template-library-template-preview',
cloneButton: '.jet-clone-to-library',
};
},
events: function() {
return {
'click @ui.previewButton': 'onPreviewButtonClick',
'click @ui.cloneButton': 'onCloneButtonClick'
};
},
onPreviewButtonClick: function() {
if ( '' === this.model.get( 'preview' ) ) {
return;
}
JetThemeEditor.setPreview( this.model );
},
onCloneButtonClick: function() {
JetThemeEditor.layout.showLoadingView();
$.ajax({
url: ajaxurl,
type: 'post',
dataType: 'json',
data: {
action: 'jet_theme_core_clone_template',
template: this.model.attributes,
tab: JetThemeEditor.getTab()
}
}).done( function( response ) {
if ( true === response.success ) {
JetThemeEditor.channels.layout.trigger( 'template:cloned' );
JetThemeEditor.tabs.local.data = {};
JetThemeEditor.setTab( 'local' );
} else {
JetThemeEditor.setTab( JetThemeEditor.getTab() );
}
});
},
behaviors: {
insertTemplate: {
behaviorClass: self.LibraryInsertTemplateBehavior
}
}
} );
self.FiltersItemView = Marionette.ItemView.extend( {
template: '#tmpl-jet-template-library-filters-item',
className: function() {
return 'jet-filter-item';
},
ui: function() {
return {
filterLabels: '.jet-template-library-filter-label'
};
},
events: function() {
return {
'click @ui.filterLabels': 'onFilterClick'
};
},
onFilterClick: function( event ) {
var $clickedInput = jQuery( event.target );
JetThemeEditor.setFilter( 'category', $clickedInput.val() );
}
} );
self.LibraryTabsItemView = Marionette.ItemView.extend( {
template: '#tmpl-jet-template-library-tabs-item',
className: function() {
return 'elementor-template-library-menu-item';
},
ui: function() {
return {
tabsLabels: 'label',
tabsInput: 'input'
};
},
events: function() {
return {
'click @ui.tabsLabels': 'onTabClick'
};
},
onRender: function() {
if ( this.model.get( 'slug' ) === JetThemeEditor.getTab() ) {
this.ui.tabsInput.attr( 'checked', 'checked' );
}
},
onTabClick: function( event ) {
var $clickedInput = jQuery( event.target );
JetThemeEditor.setTab( $clickedInput.val() );
JetThemeEditor.setFilter( 'keyword', '' );
}
} );
self.LibraryCollectionView = Marionette.CompositeView.extend( {
template: '#tmpl-jet-template-library-templates',
id: 'jet-template-library-templates',
childViewContainer: '#jet-template-library-templates-container',
initialize: function() {
this.listenTo( JetThemeEditor.channels.templates, 'filter:change', this._renderChildren );
},
filter: function( childModel ) {
var filter = JetThemeEditor.getFilter( 'category' ),
keyword = JetThemeEditor.getFilter( 'keyword' );
if ( ! filter && ! keyword ) {
return true;
}
if ( keyword && ! filter ) {
return _.contains( childModel.get( 'keywords' ), keyword );
}
if ( filter && ! keyword ) {
return _.contains( childModel.get( 'categories' ), filter );
}
return _.contains( childModel.get( 'categories' ), filter ) && _.contains( childModel.get( 'keywords' ), keyword );
},
getChildView: function( childModel ) {
return self.LibraryTemplateItemView;
},
onRenderCollection: function() {
var container = this.$childViewContainer,
items = this.$childViewContainer.children(),
tab = JetThemeEditor.getTab();
if ( 'jet_page' === tab || 'local' === tab ) {
return;
}
setTimeout( function() {
self.masonry.init({
container: container,
items: items,
});
}, 200 );
}
} );
self.LibraryTabsCollectionView = Marionette.CompositeView.extend( {
template: '#tmpl-jet-template-library-tabs',
childViewContainer: '#jet-template-library-tabs-items',
initialize: function() {
this.listenTo( JetThemeEditor.channels.layout, 'tamplate:cloned', this._renderChildren );
},
getChildView: function( childModel ) {
return self.LibraryTabsItemView;
}
} );
self.FiltersCollectionView = Marionette.CompositeView.extend( {
id: 'jet-template-library-filters',
template: '#tmpl-jet-template-library-filters',
childViewContainer: '#jet-template-library-filters-container',
getChildView: function( childModel ) {
return self.FiltersItemView;
}
} );
self.LibraryBodyView = Marionette.LayoutView.extend( {
id: 'jet-template-library-content',
className: function() {
return 'library-tab-' + JetThemeEditor.getTab();
},
template: '#tmpl-jet-template-library-content',
regions: {
contentTemplates: '.jet-templates-list',
contentFilters: '.jet-filters-list',
contentKeywords: '.jet-keywords-list'
}
} );
self.LibraryLayoutView = Marionette.LayoutView.extend( {
el: '#jet-template-library-modal',
regions: JetThemeCoreData.modalRegions,
initialize: function() {
this.getRegion( 'modalHeader' ).show( new self.LibraryHeaderView() );
this.listenTo( JetThemeEditor.channels.tabs, 'filter:change', this.switchTabs );
this.listenTo( JetThemeEditor.channels.layout, 'preview:change', this.switchPreview );
},
switchTabs: function() {
this.showLoadingView();
JetThemeEditor.setFilter( 'keyword', '' );
JetThemeEditor.requestTemplates( JetThemeEditor.getTab() );
},
switchPreview: function() {
var header = this.getHeaderView(),
preview = JetThemeEditor.getPreview();
if ( 'back' === preview ) {
header.headerTabs.show( new self.LibraryTabsCollectionView( {
collection: JetThemeEditor.collections.tabs
} ) );
header.headerActions.empty();
JetThemeEditor.setTab( JetThemeEditor.getTab() );
return;
}
if ( 'initial' === preview ) {
header.headerActions.empty();
return;
}
this.getRegion( 'modalContent' ).show( new self.LibraryPreviewView( {
'preview': preview.get( 'preview' )
} ) );
header.headerTabs.show( new self.LibraryHeaderBack() );
header.headerActions.show( new self.LibraryHeaderInsertButton( {
model: preview
} ) );
},
getHeaderView: function() {
return this.getRegion( 'modalHeader' ).currentView;
},
getContentView: function() {
return this.getRegion( 'modalContent' ).currentView;
},
showLoadingView: function() {
this.modalContent.show( new self.LibraryLoadingView() );
},
showLicenseError: function() {
this.modalContent.show( new self.LibraryErrorView() );
},
showTemplatesView: function( templatesCollection, categoriesCollection, keywords ) {
this.getRegion( 'modalContent' ).show( new self.LibraryBodyView() );
var contentView = this.getContentView(),
header = this.getHeaderView(),
keywordsModel = new self.KeywordsModel( {
keywords: keywords
} );
JetThemeEditor.collections.tabs = new self.LibraryTabsCollection( JetThemeEditor.getTabs() );
header.headerTabs.show( new self.LibraryTabsCollectionView( {
collection: JetThemeEditor.collections.tabs
} ) );
contentView.contentTemplates.show( new self.LibraryCollectionView( {
collection: templatesCollection
} ) );
contentView.contentFilters.show( new self.FiltersCollectionView( {
collection: categoriesCollection
} ) );
contentView.contentKeywords.show( new self.KeywordsView( { model: keywordsModel } ) );
}
} );
},
masonry: {
self: {},
elements: {},
init: function( settings ) {
var self = this;
self.settings = $.extend( self.getDefaultSettings(), settings );
self.elements = self.getDefaultElements();
self.run();
},
getSettings: function( key ) {
if ( key ) {
return this.settings[ key ];
} else {
return this.settings;
}
},
getDefaultSettings: function() {
return {
container: null,
items: null,
columnsCount: 3,
verticalSpaceBetween: 30
};
},
getDefaultElements: function() {
return {
$container: jQuery( this.getSettings( 'container' ) ),
$items: jQuery( this.getSettings( 'items' ) )
};
},
run: function() {
var heights = [],
distanceFromTop = this.elements.$container.position().top,
settings = this.getSettings(),
columnsCount = settings.columnsCount;
distanceFromTop += parseInt( this.elements.$container.css( 'margin-top' ), 10 );
this.elements.$container.height( '' );
this.elements.$items.each( function( index ) {
var row = Math.floor( index / columnsCount ),
indexAtRow = index % columnsCount,
$item = jQuery( this ),
itemPosition = $item.position(),
itemHeight = $item[0].getBoundingClientRect().height + settings.verticalSpaceBetween;
if ( row ) {
var pullHeight = itemPosition.top - distanceFromTop - heights[ indexAtRow ];
pullHeight -= parseInt( $item.css( 'margin-top' ), 10 );
pullHeight *= -1;
$item.css( 'margin-top', pullHeight + 'px' );
heights[ indexAtRow ] += itemHeight;
} else {
heights.push( itemHeight );
}
} );
this.elements.$container.height( Math.max.apply( Math, heights ) );
}
}
};
JetThemeControlsViews = {
JetSearchView: null,
init: function() {
var self = this;
self.JetSearchView = window.elementor.modules.controls.BaseData.extend( {
onReady: function() {
var action = this.model.attributes.action,
queryParams = this.model.attributes.query_params;
this.ui.select.find( 'option' ).each(function(index, el) {
$( this ).attr( 'selected', true );
});
this.ui.select.select2( {
ajax: {
url: function() {
var query = '';
if ( queryParams.length > 0 ) {
$.each( queryParams, function( index, param ) {
if ( window.elementor.settings.page.model.attributes[ param ] ) {
query += '&' + param + '=' + window.elementor.settings.page.model.attributes[ param ];
}
});
}
return ajaxurl + '?action=' + action + query;
},
dataType: 'json'
},
placeholder: 'Please enter 3 or more characters',
minimumInputLength: 3
} );
},
onBeforeDestroy: function() {
if ( this.ui.select.data( 'select2' ) ) {
this.ui.select.select2( 'destroy' );
}
this.$el.remove();
}
} );
window.elementor.addControlView( 'jet_search', self.JetSearchView );
}
};
JetThemeModules = {
getDataToSave: function( data ) {
data.id = window.elementor.config.post_id;
return data;
},
init: function() {
if ( window.elementor.settings.jet_template ) {
window.elementor.settings.jet_template.getDataToSave = this.getDataToSave;
}
if ( window.elementor.settings.jet_page ) {
window.elementor.settings.jet_page.getDataToSave = this.getDataToSave;
window.elementor.settings.jet_page.changeCallbacks = {
custom_header: function() {
this.save( function() {
elementor.reloadPreview();
elementor.once( 'preview:loaded', function() {
elementor.getPanelView().setPage( 'jet_page_settings' );
} );
} );
},
custom_footer: function() {
this.save( function() {
elementor.reloadPreview();
elementor.once( 'preview:loaded', function() {
elementor.getPanelView().setPage( 'jet_page_settings' );
} );
} );
}
};
}
}
};
JetThemeEditor = {
modal: false,
layout: false,
collections: {},
tabs: {},
defaultTab: '',
channels: {},
atIndex: null,
init: function() {
window.elementor.on(
'preview:loaded',
window._.bind( JetThemeEditor.onPreviewLoaded, JetThemeEditor )
);
JetThemeViews.init();
JetThemeControlsViews.init();
//JetThemeModules.init();
},
onPreviewLoaded: function() {
this.initMagicButton();
window.elementor.$previewContents.on(
'click.addJetTemplate',
'.add-jet-template',
_.bind( this.showTemplatesModal, this )
);
this.channels = {
templates: Backbone.Radio.channel( 'JET_THEME_EDITOR:templates' ),
tabs: Backbone.Radio.channel( 'JET_THEME_EDITOR:tabs' ),
layout: Backbone.Radio.channel( 'JET_THEME_EDITOR:layout' ),
};
this.tabs = JetThemeCoreData.tabs;
this.defaultTab = JetThemeCoreData.defaultTab;
},
initMagicButton: function() {
var $addNewSection = window.elementor.$previewContents.find( '.elementor-add-new-section' ),
addJetTemplate = '<button class="add-jet-template" type="button">' + JetThemeCoreData.libraryButton + '</button>',
$addJetTemplate;
if ( $addNewSection.length && JetThemeCoreData.libraryButton ) {
$addJetTemplate = $( addJetTemplate ).prependTo( $addNewSection );
}
window.elementor.$previewContents.on(
'click.addJetTemplate',
'.elementor-editor-section-settings .elementor-editor-element-add',
function() {
var $this = $( this ),
$section = $this.closest( '.elementor-top-section' ),
modelID = $section.data( 'model-cid' );
if ( window.elementor.sections.currentView.collection.length ) {
$.each( window.elementor.sections.currentView.collection.models, function( index, model ) {
if ( modelID === model.cid ) {
JetThemeEditor.atIndex = index;
}
});
}
if ( JetThemeCoreData.libraryButton ) {
setTimeout( function() {
var $addNew = $section.prev( '.elementor-add-section' ).find( '.elementor-add-new-section' );
$addNew.prepend( addJetTemplate );
}, 100 );
}
}
);
},
getFilter: function( name ) {
return this.channels.templates.request( 'filter:' + name );
},
setFilter: function( name, value ) {
this.channels.templates.reply( 'filter:' + name, value );
this.channels.templates.trigger( 'filter:change' );
},
getTab: function() {
return this.channels.tabs.request( 'filter:tabs' );
},
setTab: function( value, silent ) {
this.channels.tabs.reply( 'filter:tabs', value );
if ( ! silent ) {
this.channels.tabs.trigger( 'filter:change' );
}
},
getTabs: function() {
var tabs = [];
_.each( this.tabs, function( item, slug ) {
tabs.push({
slug: slug,
title: item.title
});
} );
return tabs;
},
getPreview: function( name ) {
return this.channels.layout.request( 'preview' );
},
setPreview: function( value, silent ) {
this.channels.layout.reply( 'preview', value );
if ( ! silent ) {
this.channels.layout.trigger( 'preview:change' );
}
},
getKeywords: function() {
var keywords = [];
_.each( this.keywords, function( title, slug ) {
tabs.push({
slug: slug,
title: title
});
} );
return keywords;
},
showTemplatesModal: function() {
this.getModal().show();
if ( ! this.layout ) {
this.layout = new JetThemeViews.LibraryLayoutView();
this.layout.showLoadingView();
}
this.setTab( this.defaultTab, true );
this.requestTemplates( this.defaultTab );
this.setPreview( 'initial' );
},
requestTemplates: function( tabName ) {
var self = this,
tab = self.tabs[ tabName ];
self.setFilter( 'category', false );
if ( tab.data.templates && tab.data.categories ) {
self.layout.showTemplatesView( tab.data.templates, tab.data.categories, tab.data.keywords );
} else {
$.ajax({
url: ajaxurl,
type: 'get',
dataType: 'json',
data: {
action: 'jet_theme_get_templates',
tab: tabName,
},
success: function( response ) {
var templates = new JetThemeViews.LibraryCollection( response.data.templates ),
categories = new JetThemeViews.CategoriesCollection( response.data.categories );
self.tabs[ tabName ].data = {
templates: templates,
categories: categories,
keywords: response.data.keywords
};
self.layout.showTemplatesView( templates, categories, response.data.keywords );
}
});
}
},
closeModal: function() {
this.getModal().hide();
},
getModal: function() {
if ( ! this.modal ) {
this.modal = elementor.dialogsManager.createWidget( 'lightbox', {
id: 'jet-template-library-modal',
closeButton: false
} );
}
return this.modal;
}
};
$( window ).on( 'elementor:init', JetThemeEditor.init );
})( jQuery );

File diff suppressed because one or more lines are too long

View File

@@ -0,0 +1,123 @@
(function( $, pluginsData ) {
'use strict';
var JetPluginsPage = {
init: function() {
var self = this;
$( document )
.on( 'click.JetPluginsPage', 'a[data-action="install"]', self.installPlugin )
.on( 'click.JetPluginsPage', 'a[data-action="activate"]', self.activatePlugin )
.on( 'click.JetPluginsPage', 'a[data-action="update"]', self.updatePlugin );
},
showError: function( $button, message ) {
$button.closest( '.jet-plugin' ).find( '.jet-plugin__errors' ).html( message );
},
installPlugin: function( event ) {
event.preventDefault();
var $this = $( this ),
plugin = $this.data( 'plugin' );
$this.html( pluginsData.installing );
$.ajax({
url: ajaxurl,
type: 'post',
dataType: 'json',
data: {
action: 'jet_core_install_plugin',
plugin: plugin
}
}).done( function( response ) {
if ( true === response.success ) {
$this.html( pluginsData.activate );
$this.data( 'activate' );
$this.attr( 'data-action', 'activate' );
$this.closest( '.jet-plugin' ).find( '.user-version b' ).html( response.data.version );
} else {
JetPluginsPage.showError( $this, response.data.errorMessage );
$this.html( pluginsData.failed );
}
});
},
activatePlugin: function( event ) {
event.preventDefault();
var $this = $( this ),
plugin = $this.data( 'plugin' );
$this.html( pluginsData.activating );
$.ajax({
url: ajaxurl,
type: 'post',
dataType: 'json',
data: {
action: 'jet_core_activate_plugin',
plugin: plugin
}
}).done( function( response ) {
if ( true === response.success ) {
$this.replaceWith( pluginsData.activated );
} else {
JetPluginsPage.showError( $this, response.data.errorMessage );
$this.html( pluginsData.failed );
}
});
},
updatePlugin: function( event ) {
event.preventDefault();
var $this = $( this ),
plugin = $this.data( 'plugin' );
$this.html( pluginsData.updating );
$.ajax({
url: ajaxurl,
type: 'post',
dataType: 'json',
data: {
action: 'jet_core_update_plugin',
plugin: plugin
}
}).done( function( response ) {
if ( true === response.success ) {
$this.closest( '.jet-plugin' ).find( '.user-version b' ).html( response.data.newVersion );
$this.replaceWith( pluginsData.updated );
} else {
JetPluginsPage.showError( $this, response.data.errorMessage );
$this.html( pluginsData.failed );
}
});
}
};
JetPluginsPage.init();
})( jQuery, window.JetPluginsData );

View File

@@ -0,0 +1,39 @@
(function( $, settingsData ) {
'use strict';
var JetSettingsPage = {
init: function() {
var self = this;
$( document )
.on( 'click.JetSettingsPage', '#jet_activate_license', self.activateLicese )
.on( 'click.JetSettingsPage', '#jet_deactivate_license', self.deactivateLicese );
},
activateLicese: function() {
var $licenseInput = $( '#jet_core_license' ),
licesne = $licenseInput.val();
if ( ! licesne ) {
$licenseInput.addClass( 'jet-error' );
$( '.jet-core-license__errors' ).html( settingsData.messages.empty );
} else {
window.location = settingsData.activateUrl.replace( '%license_key%', licesne );
}
},
deactivateLicese: function() {
window.location = settingsData.deactivateUrl;
}
};
JetSettingsPage.init();
})( jQuery, window.JetSettingsData );

View File

@@ -0,0 +1,86 @@
(function( $, skinsData ) {
'use strict';
var JetSkinsPage = {
init: function() {
var self = this;
$( document )
.on( 'click.JetSkinsPage', 'a[data-action="install-wizard"]', self.installWizard )
.on( 'click.JetSkinsPage', 'a[data-action="activate-wizard"]', self.activateWizard );
},
showError: function( $button, message ) {
$button.next( '.jet-install-wizard__msg' ).html( message );
},
installWizard: function( event ) {
event.preventDefault();
var $this = $( this );
$this.html( skinsData.installing );
$.ajax({
url: ajaxurl,
type: 'post',
dataType: 'json',
data: {
action: 'jet_core_install_plugins_wizard',
}
}).done( function( response ) {
if ( true === response.success ) {
$this.html( skinsData.activate );
$this.data( 'action', 'activate-wizard' );
$this.attr( 'data-action', 'activate-wizard' );
} else {
JetSkinsPage.showError( $this, response.data.errorMessage );
$this.html( skinsData.failed );
}
});
},
activateWizard: function( event ) {
event.preventDefault();
var $this = $( this );
$this.html( skinsData.activating );
$.ajax({
url: ajaxurl,
type: 'post',
dataType: 'json',
data: {
action: 'jet_core_activate_plugins_wizard'
}
}).done( function( response ) {
if ( true === response.success ) {
$this.replaceWith( response.data.pageContent );
window.location.reload();
} else {
JetSkinsPage.showError( $this, response.data.errorMessage );
$this.html( skinsData.failed );
}
});
},
};
JetSkinsPage.init();
})( jQuery, window.JetSkinsData );

View File

@@ -0,0 +1,63 @@
(function( $ ) {
'use strict';
var JetTemplatesType = {
errorClass: 'jet-template-types-popup__error',
init: function() {
var self = this;
$( document )
.on( 'click.JetTemplatesType', '.page-title-action', self.openPopup )
.on( 'click.JetTemplatesType', '.jet-template-types-popup__overlay', self.closePopup )
.on( 'click.JetTemplatesType', '#templates_type_submit', self.validateForm )
.on( 'change.JetTemplatesType', '#template_type', self.changeType );
},
openPopup: function( event ) {
event.preventDefault();
$( '.jet-template-types-popup' ).addClass( 'jet-template-types-popup-active' );
},
closePopup: function() {
$( '.jet-template-types-popup' ).removeClass( 'jet-template-types-popup-active' );
},
changeType: function() {
var $this = $( this ),
value = $this.find( 'option:selected' ).val();
if ( '' !== value ) {
$this.removeClass( JetTemplatesType.errorClass );
}
},
validateForm: function() {
var $this = $( this ),
$form = $this.closest( '#templates_type_form' ),
$type = $form.find( '#template_type' ),
$name = $form.find( '#template_name' ),
type = $type.find( 'option:selected' ).val();
$type.removeClass( JetTemplatesType.errorClass );
if ( '' !== type ) {
$form.submit();
} else {
$type.addClass( JetTemplatesType.errorClass );
}
}
};
JetTemplatesType.init();
})( jQuery );

View File

@@ -0,0 +1 @@
!function(e){"use strict";var t={errorClass:"jet-template-types-popup__error",init:function(){e(document).on("click.JetTemplatesType",".page-title-action",this.openPopup).on("click.JetTemplatesType",".jet-template-types-popup__overlay",this.closePopup).on("click.JetTemplatesType","#templates_type_submit",this.validateForm).on("change.JetTemplatesType","#template_type",this.changeType)},openPopup:function(t){t.preventDefault(),e(".jet-template-types-popup").addClass("jet-template-types-popup-active")},closePopup:function(){e(".jet-template-types-popup").removeClass("jet-template-types-popup-active")},changeType:function(){var p=e(this);""!==p.find("option:selected").val()&&p.removeClass(t.errorClass)},validateForm:function(){var p=e(this).closest("#templates_type_form"),s=p.find("#template_type"),a=(p.find("#template_name"),s.find("option:selected").val());s.removeClass(t.errorClass),""!==a?p.submit():s.addClass(t.errorClass)}};t.init()}(jQuery);

View File

@@ -0,0 +1,159 @@
(function( $, themeData ) {
'use strict';
var JetThemePage = {
xhr: null,
init: function() {
var self = this;
$( document )
.on( 'click.JetThemePage', 'a[data-action="update-theme"]', self.updateTheme )
.on( 'click.JetThemePage', 'button[data-action="install-child"]', self.installChild )
.on( 'click.JetThemePage', '.jet-backup-delete', self.confirmDelete )
.on( 'click.JetThemePage', 'button[data-action="activate-child"]', self.activateChild );
$( window ).on( 'cx-switcher-change', self.updateBackupsSetting );
},
confirmDelete: function( event ) {
event.preventDefault();
var $this = $( this );
if ( confirm( 'Are you sure you want to delete this file?' ) ) {
window.location = $this.attr( 'href' );
}
},
updateBackupsSetting: function( event ) {
var controlName = event.controlName,
controlStatus = event.controlStatus;
if ( 'jet_core_auto_backup' !== controlName ) {
return;
}
if ( null !== JetThemePage.xhr ) {
JetThemePage.xhr.abort();
}
JetThemePage.xhr = $.ajax({
url: ajaxurl,
type: 'post',
dataType: 'json',
data: {
action: 'jet_core_update_backup_status',
new_value: controlStatus,
}
}).done( function( response ) {
JetThemePage.xhr = null;
});
},
updateTheme: function( event ) {
event.preventDefault();
var $this = $( this );
$this.html( themeData.updating );
$.ajax({
url: ajaxurl,
type: 'post',
dataType: 'json',
data: {
action: 'jet_core_update_theme'
}
}).done( function( response ) {
if ( true === response.success ) {
$( '.jet-theme__update-notice' ).remove();
$( '.jet-theme__version-val' ).html( response.data.newVersion );
} else {
$this.replaceWith( themeData.failed );
$( '.jet-theme__errors' ).html( response.data.errorMessage );
}
if ( response.data.backupsList ) {
$( '.jet-backups-wrap' ).html( response.data.backupsList );
}
});
},
installChild: function( event ) {
event.preventDefault();
var $this = $( this );
$this.html( themeData.installing );
$.ajax({
url: ajaxurl,
type: 'post',
dataType: 'json',
data: {
action: 'jet_core_install_child_theme'
}
}).done( function( response ) {
if ( true === response.success ) {
$this.html( themeData.activate );
$this.data( 'action', 'activate-child' );
$this.attr( 'data-action', 'activate-child' );
$this.data( 'theme', response.data.theme );
$( '.jet-child-theme__status span' ).html( themeData.installed );
} else {
$this.replaceWith( themeData.failed );
$( '.jet-child-theme__errors' ).html( response.data.errorMessage );
}
});
},
activateChild: function( event ) {
event.preventDefault();
var $this = $( this );
$this.html( themeData.activating );
$.ajax({
url: ajaxurl,
type: 'post',
dataType: 'json',
data: {
action: 'jet_core_activate_child_theme'
}
}).done( function( response ) {
if ( true === response.success ) {
$this.remove();
$( '.jet-child-theme__status span' ).html( themeData.activated );
} else {
$this.replaceWith( themeData.failed );
$( '.jet-child-theme__errors' ).html( response.data.errorMessage );
}
});
}
};
JetThemePage.init();
})( jQuery, window.JetThemeData );

View File

@@ -0,0 +1,25 @@
// Editor colors
$editor-darkest:#495157;
$editor-darker: #556068;
$editor-dark: #6d7882;
$editor-light: #a4afb7;
$editor-lighter: #c2cbd2;
$editor-lightest: #d5dadf;
$editor-accent: #9b0a46;
$editor-background: #e6e9ec;
$editor-background-light: #f1f3f5;
$editor-orange: #fcb92c;
$editor-danger: #f00;
$editor-warning: #b01b1b;
$editor-success: #39b54a;
$editor-info: #71d7f7;
// Panel style
$panel-top-shadow: -2px -5px 8px rgba(0, 0, 0, 0.1);
$panel-bottom-shadow: 0 0 8px rgba(0, 0, 0, 0.1);
$ui_success_color: #3ba956;

View File

@@ -0,0 +1,354 @@
@import "variables";
$link-color: #298ffc;
$text-color: #23282d;
.jet-core-dashboard {
.cx-tab.cx-tab--vertical {
padding: 0;
> .cx-tab__body {
.cx-tab__button {
color: $text-color;
display: block;
box-sizing: border-box;
order: 0;
flex: 0 1 100%;
align-self: auto;
padding: 8px 15px;
border: 0;
background: none;
cursor: pointer;
position: relative;
text-align: left;
transition: all 150ms linear;
display: flex;
align-items: center;
outline: none;
border: none;
box-shadow: none;
&.active{
&:after {
display: none;
}
}
.cx-tab__title {
font-weight: 600;
font-size: 14px;
line-height: 19px;
margin: 0;
transition: all 150ms linear;
}
.cx-tab__icon {
transition: all 150ms linear;
margin: 0 10px 0 0;
color: #c4ccd7;
}
& + .cx-tab__button {
&:before {
display: none;
}
}
}
.cx-tab__button:hover,
.cx-tab__button.active {
background: #f6f7f9;
.cx-tab__icon,
.cx-tab__title {
color: $link-color;
}
}
> .cx-tab__tabs {
flex: 0 1 12%;
padding: 20px;
}
> .cx-tab__content {
flex: 0 1 88%;
padding: 20px;
.cx-component {
padding: 0;
}
}
}
}
.jet-core-license {
&__form {
display: flex;
align-items: center;
padding: 15px 0;
}
&__input {
min-width: 250px;
margin: 0 10px 0 0;
outline: none;
}
&__status {
font-weight: bold;
&.status-success {
color: $ui_success_color;
}
}
label {
padding: 10px 0 5px;
display: block;
font-weight: bold;
}
}
.cx-button {
outline: none;
}
.cx-button-success-style:hover,
.cx-button-primary-style:hover {
color: #fff;
}
.jet-plugins-actions {
padding: 0 0 25px;
.cx-button {
margin: 0 10px 0 0;
}
}
.jet-plugin {
display: flex;
align-items: flex-start;
padding: 25px 0;
border-top: 1px solid rgba( 0, 0, 0, 0.1 );
&:last-child {
padding-bottom: 10px;
}
&.jet-core {
border-top: none;
padding-top: 0;
}
&__thumb {
display: block;
margin-right: 20px;
}
&__title {
margin: 0 0 5px;
font-size: 16px;
color: $text-color;
font-weight: 500;
}
&__version {
color: $text-color;
b {
font-weight: normal;
}
}
&__actions {
padding: 5px 0 0 0;
a + a {
margin: 0 0 0 15px;
}
}
&__errors {
color: red;
}
}
.jet-theme {
padding: 0 0 25px;
border-bottom: 1px solid rgba( 0, 0, 0, .1 );
margin: 0 0 20px;
max-width: 600px;
&__content {
display: flex;
flex-wrap: wrap;
}
&__thumb {
width: 600px;
height: auto;
display: block;
border: 1px solid rgba( 0, 0, 0, .1 );
margin: 0 0 25px;
}
&__name {
font-size: 16px;
font-weight: 500;
margin: 0 0 15px;
flex: 0 0 100%;
max-width: 100%;
}
&__status {
margin: 0 8px 0 0;
}
&__version {
display: flex;
&-val {
margin: 0 8px 0 0;
}
}
}
.jet-child-theme {
padding: 0 0 25px;
border-bottom: 1px solid rgba( 0, 0, 0, .1 );
max-width: 600px;
&__name {
font-size: 16px;
font-weight: 500;
margin: 0 0 15px;
}
}
.cx-control {
padding: 25px 0 20px;
}
.tab-theme {
.cx-control {
max-width: 600px;
.cx-control__info {
flex: 0 1 70%;
}
.cx-control__content {
flex: 0 1 30%;
overflow: hidden;
.cx-ui-container {
float: right;
}
}
}
}
.jet_core_create_backup {
padding: 30px 0 0 0;
}
.jet-backups {
padding: 15px 0 0 0;
max-width: 600px;
table {
border-collapse: collapse;
tr {
padding: 0;
margin: 0;
}
thead {
th {
padding: 4px 10px;
font-weight: 500;
font-size: 13px;
line-height: 20px;
text-align: left;
}
}
tbody {
td {
padding: 4px 10px;
font-size: 13px;
line-height: 20px;
}
tr:nth-child(odd) {
background: #f6f7f9;
}
}
}
.jet-backups-file {
width: 190px;
}
.jet-backups-date {
width: 220px;
}
.jet-backups-actions {
width: 170px;
a + a {
margin: 0 0 0 10px;
}
}
}
.jet-skins-actions {
padding: 0 0 10px 0;
a + a {
margin: 0 0 0 10px;
}
}
.jet-skins {
display: flex;
flex-wrap: wrap;
margin: 0 -10px;
}
.jet-skin {
padding: 10px;
flex: 0 0 290px;
max-width: 290px;
&__wrap {
border: 1px solid rgba( 0, 0, 0, .1 );
padding: 20px;
}
&__thumb {
display: block;
&-img {
display: block;
width: 100%;
height: auto;
}
}
&__title {
margin: 10px 0 15px;
font-size: 16px;
font-weight: 500;
}
&__actions {
display: flex;
justify-content: space-between;
.cx-button {
width: 70px;
text-align: center;
}
}
}
.jet-guide-title {
font-size: 16px;
font-weight: 500;
margin: 0 0 15px;
}
.jet-guide-content {
margin: 0 0 30px;
}
.jet-guide-links {
&__item {
border-top: 1px solid rgba( 0, 0, 0, .1 );
padding: 12px 0;
display: flex;
align-items: center;
justify-content: space-between;
max-width: 600px;
&:first-child {
border-top: none;
}
&:last-child {
padding-bottom: 0;
}
&-link {
width: 160px;
text-align: center;
padding-left: 0;
padding-right: 0;
}
&-desc {
display: flex;
align-items: center;
.dashicons {
margin: 0 10px 0 0;
opacity: .2;
}
}
}
}
}
.jet-install-wizard {
&__content {
padding: 0 0 20px;
}
}

View File

@@ -0,0 +1,4 @@
@import 'variables';
@import 'modules/templates-modal';
@import 'modules/templates-tabs';
@import 'modules/templates-filters';

View File

@@ -0,0 +1,203 @@
#jet-template-library-content {
display: flex;
height: calc( 100% - 20px );
.jet-filters-list {
width: 15%;
padding: 25px 10px 10px;
height: 100%;
overflow: auto;
}
.jet-templates-wrap {
width: 85%;
}
.jet-templates-list {
height: 100%;
overflow: auto;
}
.jet-keywords-list {
padding-left: 10px;
}
.jet-template-library-filter-label {
display: block;
position: relative;
text-align: left;
padding: 12px 0;
text-transform: uppercase;
input[type="radio"] {
position: absolute;
left: 0;
top: 0;
right: 0;
bottom: 0;
margin: 0;
opacity: 0;
display: block;
width: 100%;
height: 100%;
}
&:hover span,
input:checked + span {
color: $editor-accent;
}
}
.jet-filter-item {
border-top: 1px solid #d5dadf;
&:first-child {
border-top: none;
}
}
&.library-tab-local {
.jet-filters-list {
display: none;
}
.jet-templates-wrap {
width: 100%;
}
.jet-template-library-template-insert {
padding: 5px 12px;
i {
margin-right: 2px;
}
span {
font-size: 11px;
}
}
.elementor-template-library-template-controls {
width: 120px;
}
.elementor-template-library-template-name {
width: 200px;
}
}
}
#jet-template-library-templates-container {
display: flex;
flex-wrap: wrap;
align-items: flex-start;
.elementor-template-library-template {
position: relative;
}
.elementor-template-library-template-remote {
width: calc( 33.3333% - 30px );
margin: 15px;
}
#jet-template-library-content:not(.library-tab-local) & {
.elementor-template-library-template-controls {
position: absolute;
left: 0;
bottom: 0;
right: 0;
display: flex;
justify-content: space-between;
padding: 0 10px 9px 8px;
z-index: 10;
}
.jet-template-library-template-insert {
padding: 0;
margin: 0;
color: $editor-success;
background: none;
width: auto;
text-transform: none;
font-size: 12px;
&:hover {
box-shadow: none;
color: darken( $editor-success, 15% );
}
}
.elementor-template-library-template-name {
padding: 5px 0 0 0;
display: block !important;
}
.elementor-template-library-template-name-holder {
height: 23px;
}
.template-library-activate-license {
display: none;
color: $editor-orange;
font-size: 12px;
&:hover {
color: darken( $editor-orange, 15% );
}
}
.jet-clone-to-library {
background: none;
border: none;
padding: 0;
margin: 0;
color: $editor-accent;
cursor: pointer;
display: none;
font-size: 12px;
box-shadow: none;
outline: none;
font-weight: bold;
i {
margin: 0 2px 0 0;
font-size: 12px;
font-weight: normal;
}
&:hover {
color: darken( $editor-accent, 15% );
}
}
.elementor-template-library-template:hover {
.elementor-template-library-template-name {
opacity: 0;
}
}
}
.library-tab-jet_page & {
.elementor-template-library-template-remote {
width: calc( 25% - 20px );
margin: 10px;
&
.elementor-template-library-template-preview {
}
.elementor-template-library-template-action {
padding: 8px;
}
}
}
.jet-template-no-url {
.elementor-template-library-template-preview {
cursor: default !important;
opacity: 0 !important;
}
.fa-search-plus {
display: none !important;
}
}
.elementor-template-library-template:hover {
.jet-clone-to-library {
display: block !important;
}
.template-library-activate-license {
display: block !important;
}
}
}
.elementor-template-library-template-screenshot {
img {
width: 100%;
max-width: 100%;
height: auto;
display: block;
}
}
#jet-template-library-preview {
img {
width: 100%;
max-width: 100%;
height: auto;
}
}

View File

@@ -0,0 +1,184 @@
#jet-template-library-modal {
.dialog-widget-content {
width: 90%;
max-width: 1200px;
background-color: $editor-background-light;
}
.dialog-widget-header,
.dialog-header {
padding: 0;
background-color: #fff;
box-shadow: $panel-bottom-shadow;
position: relative; // Show the shadow above the scrolled list
z-index: 1;
}
.dialog-buttons-wrapper {
display: none;
}
.dialog-message {
height: 630px;
max-height: 85vh;
overflow: auto;
padding: 15px;
}
a {
&,
&:hover {
color: inherit;
}
}
a.elementor-template-library-blank-footer-link {
transition: color .5s;
&:hover {
color: $editor-accent;
}
}
.elementor-button {
text-transform: uppercase;
}
::-webkit-scrollbar {
width: 6px;
height: 0;
border-radius: 3px;
}
::-webkit-scrollbar-button {
width: 0px;
height: 10px;
}
::-webkit-scrollbar-thumb {
background-color: #d5dadf;
border: 0px none #d5dadf;
border-radius: 0;
border-radius: 3px;
}
::-webkit-scrollbar-track {
border: 0px none #fff;
border-radius: 0;
}
::-webkit-scrollbar-corner {
background: transparent;
}
}
#jet-template-library-header {
display: flex;
justify-content: space-between;
.jet-template-library-back {
background: none;
border: none;
border-right: 1px solid $editor-background;
padding: 15px 20px 15px 15px;
line-height: 20px;
font-size: 13px;
font-weight: bold;
outline: none;
transition: all 200ms linear;
cursor: pointer;
color: $editor-dark;
&:not(:hover) {
color: $editor-light;
}
}
.elementor-button {
padding: 8px 10px;
margin: 9px 10px 0 0;
}
}
#jet-template-library-header-close-modal {
width: 45px;
border-left: 1px solid $editor-background;
display: flex;
align-items: center;
justify-content: center;
cursor: pointer;
transition: all 200ms linear;
i {
color: $editor-light;
font-size: 16px;
}
&:hover {
i {
color: $editor-dark;
}
}
}
#jet-template-library-header-actions {
.template-library-activate-license {
display: block;
margin: 17px 20px 0 0;
color: $editor-orange;
&:hover {
color: darken( $editor-orange, 15% );
}
}
}
#jet-template-library-modal {
.elementor-loader {
position: relative;
.elementor-loader-box:first-of-type {
left: 40px;
top: 40px;
width: 14px;
height: 70px;
}
.elementor-loader-box:not(:first-of-type) {
right: 40px;
height: 14px;
width: 42px;
}
.elementor-loader-box:nth-of-type(2) {
top: 40px;
}
.elementor-loader-box:nth-of-type(3) {
top: 68px;
}
.elementor-loader-box:nth-of-type(4) {
bottom: 40px;
}
}
.elementor-library-error {
margin: 18% 0 0 0;
&-message {
font-size: 18px;
padding: 0 0 20px;
}
&-link {
a {
display: inline-block;
color: #fff;
background-image: none;
background: $editor-orange;
font-size: 13px;
font-weight: normal;
font-style: normal;
text-transform: uppercase;
line-height: 1;
height: 40px;
line-height: 40px;
min-width: 170px;
padding: 0 20px;
border: none;
border-radius: 3px;
cursor: pointer;
-webkit-transition: all 0.5s;
transition: all 0.5s;
&:hover {
opacity: 0.85;
box-shadow: 0 0 2px rgba(0, 0, 0, 0.12), 0 2px 2px rgba(0, 0, 0, 0.2);
}
}
}
}
}

View File

@@ -0,0 +1,41 @@
#jet-template-library-header {
min-height: 52px;
}
#jet-template-library-tabs-items {
.elementor-template-library-menu-item {
display: inline-block;
position: relative;
text-align: left;
padding: 0;
width: auto;
font-size: 13px;
color: $editor-dark;
input[type="radio"] {
position: absolute;
left: 0;
top: 0;
right: 0;
bottom: 0;
margin: 0;
opacity: 0;
display: block;
width: 100%;
height: 100%;
}
span {
display: block;
padding: 20px 19px 16px 19px;
border-bottom: 3px solid transparent;
}
&:hover span,
input:checked + span {
background: #fafafa;
border-bottom: 3px solid $editor-accent;
}
}
}
#jet-template-library-header-tabs {
flex: 1 1 auto;
text-align: left;
}

View File

@@ -0,0 +1,76 @@
@import 'variables';
.jet-location-edit {
position: relative;
&__link {
position: absolute;
opacity: 0;
top: 0;
left: 0;
right: 0;
bottom: 0;
display: flex;
justify-content: center;
align-items: center;
transition: opacity 200ms linear;
border: 4px solid $editor-info;
background: rgba( red( $editor-info ), green( $editor-info ), blue( $editor-info ), .2 );
color: #fff;
z-index: 99999;
cursor: pointer;
font-weight: 400;
font-size: 16px;
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
&-content {
display: flex;
justify-content: center;
align-items: center;
background-image: linear-gradient(to bottom, darken($editor-info, 10%), $editor-info);
padding: 4px 15px 6px 10px;
}
.dashicons {
margin-right: 4px;
}
}
&:hover .jet-location-edit__link {
color: #fff;
opacity: 1;
text-decoration: none;
}
}
.elementor-add-new-section {
.add-jet-template {
color: #fff;
background-image: none;
background: #398ffc !important;
font-size: 13px;
font-family: Arial, Helvetica, sans-serif;
font-weight: normal;
font-style: normal;
text-transform: uppercase;
line-height: 1;
height: 40px;
min-width: 170px;
padding: 0 20px;
border: none;
-webkit-border-radius: 3px;
border-radius: 3px;
cursor: pointer;
margin-right: 25px;
transition: all 0.5s;
display: inline-flex;
align-items: center;
vertical-align: bottom;
svg {
width: 17px;
margin: -2px 9px 0px -3px;
}
&:hover {
opacity: 0.85;
box-shadow: 0 0 2px rgba(0, 0, 0, 0.12), 0 2px 2px rgba(0, 0, 0, 0.2);
}
}
}

View File

@@ -0,0 +1,80 @@
@import 'variables';
.jet-template-types-popup {
display: none;
justify-content: center;
align-items: center;
position: fixed;
top: 0;
left: 0;
right: 0;
bottom: 0;
z-index: 999;
&.jet-template-types-popup-active {
display: flex;
}
&__overlay {
position: absolute;
left: 0;
right: 0;
top: 0;
bottom: 0;
background: rgba( 0, 0, 0, .8 );
z-index: 1;
transition: opacity 200ms linear;
opacity: 0;
z-index: 1000;
.jet-template-types-popup-active & {
opacity: 1;
}
}
&__content {
background: #fff;
padding: 40px;
width: 500px;
position: relative;
z-index: 2;
transition: opacity 200ms linear;
opacity: 0;
z-index: 1001;
.jet-template-types-popup-active & {
opacity: 1;
}
}
&__heading {
margin: 0 0 20px;
}
&__form {
&-row {
padding: 0 0 20px;
label {
display: block;
padding: 0 0 4px;
}
input,
select {
width: 100%;
padding: 10px 20px;
line-height: 20px;
height: auto;
}
}
&-actions {
button {
width: 100%;
}
}
}
&__error {
border-color: #dc3232;
}
}
.jet-conditions {
display: flex;
align-items: center;
&-active {
margin-left: 10px;
color: $editor-success;
}
}