Version Description
Download this release
Release Info
Developer | brainstormworg |
Plugin | |
Version | 2.1.0 |
Comparing to | |
See all releases |
Code changes from version 2.0.2 to 2.1.0
- astra-sites.php +2 -2
- inc/assets/css/admin-rtl.css +5 -0
- inc/assets/css/admin.css +5 -0
- inc/assets/css/elementor-admin-dark-rtl.css +9 -11
- inc/assets/css/elementor-admin-dark.css +9 -11
- inc/assets/css/elementor-admin-rtl.css +135 -31
- inc/assets/css/elementor-admin.css +135 -31
- inc/assets/js/admin-page.js +80 -40
- inc/assets/js/elementor-admin-page.js +238 -26
- inc/assets/js/helper.js +174 -0
- inc/classes/class-astra-sites-importer-log.php +11 -5
- inc/classes/class-astra-sites-importer.php +33 -5
- inc/classes/class-astra-sites-wp-cli.php +62 -4
- inc/classes/class-astra-sites.php +61 -61
- inc/classes/compatibility/astra-pro/class-astra-sites-compatibility-astra-pro.php +9 -0
- inc/importers/batch-processing/class-astra-sites-batch-processing-beaver-builder.php +10 -0
- inc/importers/batch-processing/class-astra-sites-batch-processing-brizy.php +13 -0
- inc/importers/batch-processing/class-astra-sites-batch-processing-elementor.php +10 -0
- inc/importers/batch-processing/class-astra-sites-batch-processing-gutenberg.php +69 -20
- inc/importers/batch-processing/class-astra-sites-batch-processing-importer.php +13 -2
- inc/importers/batch-processing/class-astra-sites-batch-processing-misc.php +12 -0
- inc/importers/batch-processing/class-astra-sites-batch-processing-widgets.php +8 -0
- inc/importers/batch-processing/class-astra-sites-batch-processing.php +71 -27
- inc/importers/batch-processing/helpers/class-astra-sites-image-importer.php +23 -14
- inc/importers/class-astra-sites-helper.php +9 -2
- inc/importers/wxr-importer/class-astra-wxr-importer.php +61 -16
- inc/includes/admin-page.php +3 -1
- inc/includes/templates.php +76 -38
- inc/json/astra-blocks-1.json +1 -1
- inc/json/astra-blocks-2.json +1 -1
- inc/json/astra-blocks-3.json +1 -1
- inc/json/astra-blocks-categories.json +1 -1
- inc/json/astra-sites-and-pages-page-1.json +1 -1
- inc/json/astra-sites-and-pages-page-10.json +1 -1
- inc/json/astra-sites-and-pages-page-11.json +1 -1
- inc/json/astra-sites-and-pages-page-12.json +1 -1
- inc/json/astra-sites-and-pages-page-13.json +1 -1
- inc/json/astra-sites-and-pages-page-14.json +1 -1
- inc/json/astra-sites-and-pages-page-15.json +1 -1
- inc/json/astra-sites-and-pages-page-16.json +1 -1
- inc/json/astra-sites-and-pages-page-17.json +1 -1
- inc/json/astra-sites-and-pages-page-2.json +1 -1
- inc/json/astra-sites-and-pages-page-3.json +1 -1
- inc/json/astra-sites-and-pages-page-4.json +1 -1
- inc/json/astra-sites-and-pages-page-5.json +1 -1
- inc/json/astra-sites-and-pages-page-6.json +1 -1
- inc/json/astra-sites-and-pages-page-7.json +1 -1
- inc/json/astra-sites-and-pages-page-8.json +1 -1
- inc/json/astra-sites-and-pages-page-9.json +1 -1
- languages/astra-sites.pot +269 -207
- readme.txt +13 -2
astra-sites.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Plugin Name: Starter Templates
|
4 |
* Plugin URI: https://wpastra.com/
|
5 |
* Description: Starter Templates is all in one solution for complete starter sites, single page templates, blocks & images. This plugin offers the premium library of ready templates & provides quick access to beautiful Pixabay images that can be imported in your website easily.
|
6 |
-
* Version: 2.0
|
7 |
* Author: Brainstorm Force
|
8 |
* Author URI: https://www.brainstormforce.com
|
9 |
* Text Domain: astra-sites
|
@@ -19,7 +19,7 @@ if ( ! defined( 'ASTRA_SITES_NAME' ) ) {
|
|
19 |
}
|
20 |
|
21 |
if ( ! defined( 'ASTRA_SITES_VER' ) ) {
|
22 |
-
define( 'ASTRA_SITES_VER', '2.0
|
23 |
}
|
24 |
|
25 |
if ( ! defined( 'ASTRA_SITES_FILE' ) ) {
|
3 |
* Plugin Name: Starter Templates
|
4 |
* Plugin URI: https://wpastra.com/
|
5 |
* Description: Starter Templates is all in one solution for complete starter sites, single page templates, blocks & images. This plugin offers the premium library of ready templates & provides quick access to beautiful Pixabay images that can be imported in your website easily.
|
6 |
+
* Version: 2.1.0
|
7 |
* Author: Brainstorm Force
|
8 |
* Author URI: https://www.brainstormforce.com
|
9 |
* Text Domain: astra-sites
|
19 |
}
|
20 |
|
21 |
if ( ! defined( 'ASTRA_SITES_VER' ) ) {
|
22 |
+
define( 'ASTRA_SITES_VER', '2.1.0' );
|
23 |
}
|
24 |
|
25 |
if ( ! defined( 'ASTRA_SITES_FILE' ) ) {
|
inc/assets/css/admin-rtl.css
CHANGED
@@ -425,6 +425,11 @@
|
|
425 |
padding: 20px 35px 30px 35px;
|
426 |
}
|
427 |
|
|
|
|
|
|
|
|
|
|
|
428 |
.astra-sites-import-content .install-theme-info {
|
429 |
display: block;
|
430 |
padding: 0;
|
425 |
padding: 20px 35px 30px 35px;
|
426 |
}
|
427 |
|
428 |
+
#astra-sites-skip-and-import-notice-update-available ul {
|
429 |
+
list-style-type: disc;
|
430 |
+
margin-right: 15px;
|
431 |
+
}
|
432 |
+
|
433 |
.astra-sites-import-content .install-theme-info {
|
434 |
display: block;
|
435 |
padding: 0;
|
inc/assets/css/admin.css
CHANGED
@@ -425,6 +425,11 @@
|
|
425 |
padding: 20px 35px 30px 35px;
|
426 |
}
|
427 |
|
|
|
|
|
|
|
|
|
|
|
428 |
.astra-sites-import-content .install-theme-info {
|
429 |
display: block;
|
430 |
padding: 0;
|
425 |
padding: 20px 35px 30px 35px;
|
426 |
}
|
427 |
|
428 |
+
#astra-sites-skip-and-import-notice-update-available ul {
|
429 |
+
list-style-type: disc;
|
430 |
+
margin-left: 15px;
|
431 |
+
}
|
432 |
+
|
433 |
.astra-sites-import-content .install-theme-info {
|
434 |
display: block;
|
435 |
padding: 0;
|
inc/assets/css/elementor-admin-dark-rtl.css
CHANGED
@@ -1,7 +1,7 @@
|
|
1 |
.ast-sites-dark-mode #ast-sites-modal .astra-sites-library-template-inner,
|
2 |
.ast-sites-dark-mode #ast-sites-modal .inner,
|
3 |
.ast-sites-dark-mode #ast-sites-modal .astra-sites-library-template:not(.elementor-template-library-template-page) .elementor-template-library-template-footer,
|
4 |
-
.ast-sites-dark-mode #ast-sites-modal .
|
5 |
background-color: #404349;
|
6 |
}
|
7 |
|
@@ -11,7 +11,8 @@
|
|
11 |
color: #ffffff;
|
12 |
}
|
13 |
|
14 |
-
.ast-sites-dark-mode #ast-sites-modal .astra-blocks-filter
|
|
|
15 |
border-color: #7d7e82;
|
16 |
}
|
17 |
|
@@ -21,7 +22,8 @@
|
|
21 |
|
22 |
|
23 |
.ast-sites-dark-mode #ast-sites-modal .astra-sites-content-wrap::-webkit-scrollbar,
|
24 |
-
.ast-sites-dark-mode #ast-sites-modal .single-site-pages::-webkit-scrollbar
|
|
|
25 |
background-color: #34383C;
|
26 |
}
|
27 |
|
@@ -44,9 +46,10 @@
|
|
44 |
|
45 |
.ast-sites-dark-mode #ast-sites-modal .dialog-widget-content,
|
46 |
.ast-sites-dark-mode #ast-sites-modal .elementor-template-library-menu-item,
|
47 |
-
.ast-sites-dark-mode #ast-sites-modal .astra-sites-sync-library-button,
|
48 |
.ast-sites-dark-mode #ast-sites-modal .ast-sites-modal__header__item > i:not(:hover),
|
49 |
.ast-sites-dark-mode #ast-sites-modal .astra-blocks-filter,
|
|
|
50 |
.ast-sites-dark-mode.astra-sites__elementor-open #ast-sites-modal .select2-container--default .select2-selection__rendered,
|
51 |
.ast-sites-dark-mode #ast-sites-modal .astra-sites-no-sites h3,
|
52 |
.ast-sites-dark-mode #ast-sites-modal .back-to-layout,
|
@@ -64,11 +67,7 @@
|
|
64 |
box-shadow: 0 0 8px rgba(0, 0, 0, 0.3);
|
65 |
}
|
66 |
|
67 |
-
.ast-sites-dark-mode #ast-sites-modal.dialog-type-lightbox .dialog-header
|
68 |
-
.ast-sites-dark-mode #ast-sites-modal #wp-filter-search-input,
|
69 |
-
.ast-sites-dark-mode #ast-sites-modal #wp-filter-search-input:hover,
|
70 |
-
.ast-sites-dark-mode #ast-sites-modal #wp-filter-search-input:focus,
|
71 |
-
.ast-sites-dark-mode #ast-sites-modal #wp-filter-search-input:active {
|
72 |
background-color: #26292C;
|
73 |
}
|
74 |
|
@@ -85,7 +84,7 @@
|
|
85 |
}
|
86 |
|
87 |
.ast-sites-dark-mode #ast-sites-modal #wp-filter-search-input {
|
88 |
-
border-color: #
|
89 |
}
|
90 |
|
91 |
.ast-sites-dark-mode #ast-sites-modal .ast-sites-modal__header__logo,
|
@@ -94,7 +93,6 @@
|
|
94 |
border-left: 1px solid #32363A;
|
95 |
}
|
96 |
|
97 |
-
.ast-sites-dark-mode #ast-sites-modal .elementor-template-library-menu-item,
|
98 |
.ast-sites-dark-mode #ast-sites-modal .astra-sites__sync-wrap,
|
99 |
.ast-sites-dark-mode #ast-sites-modal .ast-sites-modal__header__close--normal,
|
100 |
.ast-sites-dark-mode #ast-sites-modal .astra-sites-tooltip {
|
1 |
.ast-sites-dark-mode #ast-sites-modal .astra-sites-library-template-inner,
|
2 |
.ast-sites-dark-mode #ast-sites-modal .inner,
|
3 |
.ast-sites-dark-mode #ast-sites-modal .astra-sites-library-template:not(.elementor-template-library-template-page) .elementor-template-library-template-footer,
|
4 |
+
.ast-sites-dark-mode #ast-sites-modal .elementor-template-library-order-input {
|
5 |
background-color: #404349;
|
6 |
}
|
7 |
|
11 |
color: #ffffff;
|
12 |
}
|
13 |
|
14 |
+
.ast-sites-dark-mode #ast-sites-modal .astra-blocks-filter,
|
15 |
+
.ast-sites-dark-mode #ast-sites-modal .elementor-template-library-order-input {
|
16 |
border-color: #7d7e82;
|
17 |
}
|
18 |
|
22 |
|
23 |
|
24 |
.ast-sites-dark-mode #ast-sites-modal .astra-sites-content-wrap::-webkit-scrollbar,
|
25 |
+
.ast-sites-dark-mode #ast-sites-modal .single-site-pages::-webkit-scrollbar,
|
26 |
+
.ast-sites-dark-mode #ast-sites-modal .astra-blocks-filter {
|
27 |
background-color: #34383C;
|
28 |
}
|
29 |
|
46 |
|
47 |
.ast-sites-dark-mode #ast-sites-modal .dialog-widget-content,
|
48 |
.ast-sites-dark-mode #ast-sites-modal .elementor-template-library-menu-item,
|
49 |
+
.ast-sites-dark-mode #ast-sites-modal .astra-sites-sync-library-button span,
|
50 |
.ast-sites-dark-mode #ast-sites-modal .ast-sites-modal__header__item > i:not(:hover),
|
51 |
.ast-sites-dark-mode #ast-sites-modal .astra-blocks-filter,
|
52 |
+
.ast-sites-dark-mode #ast-sites-modal .elementor-template-library-order-input,
|
53 |
.ast-sites-dark-mode.astra-sites__elementor-open #ast-sites-modal .select2-container--default .select2-selection__rendered,
|
54 |
.ast-sites-dark-mode #ast-sites-modal .astra-sites-no-sites h3,
|
55 |
.ast-sites-dark-mode #ast-sites-modal .back-to-layout,
|
67 |
box-shadow: 0 0 8px rgba(0, 0, 0, 0.3);
|
68 |
}
|
69 |
|
70 |
+
.ast-sites-dark-mode #ast-sites-modal.dialog-type-lightbox .dialog-header {
|
|
|
|
|
|
|
|
|
71 |
background-color: #26292C;
|
72 |
}
|
73 |
|
84 |
}
|
85 |
|
86 |
.ast-sites-dark-mode #ast-sites-modal #wp-filter-search-input {
|
87 |
+
border-color: #d5dadf;
|
88 |
}
|
89 |
|
90 |
.ast-sites-dark-mode #ast-sites-modal .ast-sites-modal__header__logo,
|
93 |
border-left: 1px solid #32363A;
|
94 |
}
|
95 |
|
|
|
96 |
.ast-sites-dark-mode #ast-sites-modal .astra-sites__sync-wrap,
|
97 |
.ast-sites-dark-mode #ast-sites-modal .ast-sites-modal__header__close--normal,
|
98 |
.ast-sites-dark-mode #ast-sites-modal .astra-sites-tooltip {
|
inc/assets/css/elementor-admin-dark.css
CHANGED
@@ -1,7 +1,7 @@
|
|
1 |
.ast-sites-dark-mode #ast-sites-modal .astra-sites-library-template-inner,
|
2 |
.ast-sites-dark-mode #ast-sites-modal .inner,
|
3 |
.ast-sites-dark-mode #ast-sites-modal .astra-sites-library-template:not(.elementor-template-library-template-page) .elementor-template-library-template-footer,
|
4 |
-
.ast-sites-dark-mode #ast-sites-modal .
|
5 |
background-color: #404349;
|
6 |
}
|
7 |
|
@@ -11,7 +11,8 @@
|
|
11 |
color: #ffffff;
|
12 |
}
|
13 |
|
14 |
-
.ast-sites-dark-mode #ast-sites-modal .astra-blocks-filter
|
|
|
15 |
border-color: #7d7e82;
|
16 |
}
|
17 |
|
@@ -21,7 +22,8 @@
|
|
21 |
|
22 |
|
23 |
.ast-sites-dark-mode #ast-sites-modal .astra-sites-content-wrap::-webkit-scrollbar,
|
24 |
-
.ast-sites-dark-mode #ast-sites-modal .single-site-pages::-webkit-scrollbar
|
|
|
25 |
background-color: #34383C;
|
26 |
}
|
27 |
|
@@ -44,9 +46,10 @@
|
|
44 |
|
45 |
.ast-sites-dark-mode #ast-sites-modal .dialog-widget-content,
|
46 |
.ast-sites-dark-mode #ast-sites-modal .elementor-template-library-menu-item,
|
47 |
-
.ast-sites-dark-mode #ast-sites-modal .astra-sites-sync-library-button,
|
48 |
.ast-sites-dark-mode #ast-sites-modal .ast-sites-modal__header__item > i:not(:hover),
|
49 |
.ast-sites-dark-mode #ast-sites-modal .astra-blocks-filter,
|
|
|
50 |
.ast-sites-dark-mode.astra-sites__elementor-open #ast-sites-modal .select2-container--default .select2-selection__rendered,
|
51 |
.ast-sites-dark-mode #ast-sites-modal .astra-sites-no-sites h3,
|
52 |
.ast-sites-dark-mode #ast-sites-modal .back-to-layout,
|
@@ -64,11 +67,7 @@
|
|
64 |
box-shadow: 0 0 8px rgba(0, 0, 0, 0.3);
|
65 |
}
|
66 |
|
67 |
-
.ast-sites-dark-mode #ast-sites-modal.dialog-type-lightbox .dialog-header
|
68 |
-
.ast-sites-dark-mode #ast-sites-modal #wp-filter-search-input,
|
69 |
-
.ast-sites-dark-mode #ast-sites-modal #wp-filter-search-input:hover,
|
70 |
-
.ast-sites-dark-mode #ast-sites-modal #wp-filter-search-input:focus,
|
71 |
-
.ast-sites-dark-mode #ast-sites-modal #wp-filter-search-input:active {
|
72 |
background-color: #26292C;
|
73 |
}
|
74 |
|
@@ -85,7 +84,7 @@
|
|
85 |
}
|
86 |
|
87 |
.ast-sites-dark-mode #ast-sites-modal #wp-filter-search-input {
|
88 |
-
border-color: #
|
89 |
}
|
90 |
|
91 |
.ast-sites-dark-mode #ast-sites-modal .ast-sites-modal__header__logo,
|
@@ -94,7 +93,6 @@
|
|
94 |
border-right: 1px solid #32363A;
|
95 |
}
|
96 |
|
97 |
-
.ast-sites-dark-mode #ast-sites-modal .elementor-template-library-menu-item,
|
98 |
.ast-sites-dark-mode #ast-sites-modal .astra-sites__sync-wrap,
|
99 |
.ast-sites-dark-mode #ast-sites-modal .ast-sites-modal__header__close--normal,
|
100 |
.ast-sites-dark-mode #ast-sites-modal .astra-sites-tooltip {
|
1 |
.ast-sites-dark-mode #ast-sites-modal .astra-sites-library-template-inner,
|
2 |
.ast-sites-dark-mode #ast-sites-modal .inner,
|
3 |
.ast-sites-dark-mode #ast-sites-modal .astra-sites-library-template:not(.elementor-template-library-template-page) .elementor-template-library-template-footer,
|
4 |
+
.ast-sites-dark-mode #ast-sites-modal .elementor-template-library-order-input {
|
5 |
background-color: #404349;
|
6 |
}
|
7 |
|
11 |
color: #ffffff;
|
12 |
}
|
13 |
|
14 |
+
.ast-sites-dark-mode #ast-sites-modal .astra-blocks-filter,
|
15 |
+
.ast-sites-dark-mode #ast-sites-modal .elementor-template-library-order-input {
|
16 |
border-color: #7d7e82;
|
17 |
}
|
18 |
|
22 |
|
23 |
|
24 |
.ast-sites-dark-mode #ast-sites-modal .astra-sites-content-wrap::-webkit-scrollbar,
|
25 |
+
.ast-sites-dark-mode #ast-sites-modal .single-site-pages::-webkit-scrollbar,
|
26 |
+
.ast-sites-dark-mode #ast-sites-modal .astra-blocks-filter {
|
27 |
background-color: #34383C;
|
28 |
}
|
29 |
|
46 |
|
47 |
.ast-sites-dark-mode #ast-sites-modal .dialog-widget-content,
|
48 |
.ast-sites-dark-mode #ast-sites-modal .elementor-template-library-menu-item,
|
49 |
+
.ast-sites-dark-mode #ast-sites-modal .astra-sites-sync-library-button span,
|
50 |
.ast-sites-dark-mode #ast-sites-modal .ast-sites-modal__header__item > i:not(:hover),
|
51 |
.ast-sites-dark-mode #ast-sites-modal .astra-blocks-filter,
|
52 |
+
.ast-sites-dark-mode #ast-sites-modal .elementor-template-library-order-input,
|
53 |
.ast-sites-dark-mode.astra-sites__elementor-open #ast-sites-modal .select2-container--default .select2-selection__rendered,
|
54 |
.ast-sites-dark-mode #ast-sites-modal .astra-sites-no-sites h3,
|
55 |
.ast-sites-dark-mode #ast-sites-modal .back-to-layout,
|
67 |
box-shadow: 0 0 8px rgba(0, 0, 0, 0.3);
|
68 |
}
|
69 |
|
70 |
+
.ast-sites-dark-mode #ast-sites-modal.dialog-type-lightbox .dialog-header {
|
|
|
|
|
|
|
|
|
71 |
background-color: #26292C;
|
72 |
}
|
73 |
|
84 |
}
|
85 |
|
86 |
.ast-sites-dark-mode #ast-sites-modal #wp-filter-search-input {
|
87 |
+
border-color: #d5dadf;
|
88 |
}
|
89 |
|
90 |
.ast-sites-dark-mode #ast-sites-modal .ast-sites-modal__header__logo,
|
93 |
border-right: 1px solid #32363A;
|
94 |
}
|
95 |
|
|
|
96 |
.ast-sites-dark-mode #ast-sites-modal .astra-sites__sync-wrap,
|
97 |
.ast-sites-dark-mode #ast-sites-modal .ast-sites-modal__header__close--normal,
|
98 |
.ast-sites-dark-mode #ast-sites-modal .astra-sites-tooltip {
|
inc/assets/css/elementor-admin-rtl.css
CHANGED
@@ -58,9 +58,18 @@
|
|
58 |
justify-content: space-between;
|
59 |
}
|
60 |
|
|
|
|
|
|
|
|
|
61 |
#ast-sites-modal .astra-blocks-filter {
|
|
|
|
|
|
|
|
|
|
|
62 |
background: #fff;
|
63 |
-
width:
|
64 |
padding-right: 5px;
|
65 |
padding-left: 20px;
|
66 |
height: 28px;
|
@@ -68,7 +77,7 @@
|
|
68 |
}
|
69 |
|
70 |
#ast-sites-modal .astra-blocks-category-inner-wrap .select2-container {
|
71 |
-
width:
|
72 |
}
|
73 |
|
74 |
#ast-sites-modal .required-plugins-list li.plugin-card-head {
|
@@ -122,10 +131,11 @@
|
|
122 |
-webkit-transform: translateX(50%) translateY(-50%);
|
123 |
-ms-transform: translateX(50%) translateY(-50%);
|
124 |
transform: translateX(50%) translateY(-50%);
|
125 |
-
font-size:
|
126 |
}
|
127 |
#ast-sites-modal .astra-sites-library-template:not(.elementor-template-library-template-page) .elementor-template-library-template-footer {
|
128 |
padding: 7px;
|
|
|
129 |
padding-right: 5px;
|
130 |
background-color: #fff;
|
131 |
-webkit-transition: -webkit-transform .2s;
|
@@ -134,6 +144,10 @@
|
|
134 |
transition: transform .2s;
|
135 |
transition: transform .2s, -webkit-transform .2s;
|
136 |
}
|
|
|
|
|
|
|
|
|
137 |
#ast-sites-modal .astra-sites-library-template .elementor-template-library-template-footer {
|
138 |
display: -webkit-box;
|
139 |
display: -webkit-flex;
|
@@ -262,6 +276,55 @@
|
|
262 |
font-size: 15px;
|
263 |
}
|
264 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
265 |
#ast-sites-modal .dialog-buttons-wrapper .elementor-button-success:hover {
|
266 |
background-color: #39b54a;
|
267 |
}
|
@@ -317,7 +380,7 @@
|
|
317 |
-webkit-justify-content: space-between;
|
318 |
-ms-flex-pack: justify;
|
319 |
justify-content: space-between;
|
320 |
-
height:
|
321 |
}
|
322 |
|
323 |
#ast-sites-modal .ast-sites-modal__header__logo {
|
@@ -328,6 +391,10 @@
|
|
328 |
border-left: 1px solid #e6e9ec;
|
329 |
}
|
330 |
|
|
|
|
|
|
|
|
|
331 |
#ast-sites-modal .back-to-layout:before {
|
332 |
line-height: 21px;
|
333 |
width: 21px;
|
@@ -341,7 +408,6 @@
|
|
341 |
display: -webkit-flex;
|
342 |
display: -ms-flexbox;
|
343 |
display: flex;
|
344 |
-
width: 150px;
|
345 |
}
|
346 |
|
347 |
#ast-sites-modal .elementor-template-library-header-menu {
|
@@ -356,11 +422,11 @@
|
|
356 |
}
|
357 |
|
358 |
#ast-sites-modal .ast-sites-modal__options .elementor-template-library-header-menu {
|
359 |
-
height:
|
360 |
}
|
361 |
|
362 |
#ast-sites-modal .astra-sites__sync-wrap {
|
363 |
-
padding:
|
364 |
border-right: 1px solid #e6e9ec;
|
365 |
cursor: pointer;
|
366 |
}
|
@@ -466,8 +532,8 @@
|
|
466 |
}
|
467 |
|
468 |
#ast-sites-modal .ast-sites-modal__header__close--normal {
|
469 |
-
width:
|
470 |
-
height:
|
471 |
border-right: 1px solid #e6e9ec;
|
472 |
}
|
473 |
|
@@ -601,7 +667,6 @@
|
|
601 |
|
602 |
#ast-sites-modal .theme-name {
|
603 |
height: auto;
|
604 |
-
width: calc( 100% - 1em );
|
605 |
align-self: center;
|
606 |
box-shadow: none;
|
607 |
background: none;
|
@@ -627,9 +692,8 @@
|
|
627 |
#ast-sites-modal .elementor-template-library-menu-item {
|
628 |
line-height: 1em;
|
629 |
width: 108px;
|
630 |
-
padding:
|
631 |
display: inline-block;
|
632 |
-
border-right: 1px solid #e6e9ec;
|
633 |
}
|
634 |
|
635 |
#ast-sites-modal .elementor-template-library-menu-item:hover {
|
@@ -643,10 +707,11 @@
|
|
643 |
|
644 |
#ast-sites-modal .astra-sites-sync-library-button span {
|
645 |
font-size: 16px;
|
|
|
646 |
}
|
647 |
|
648 |
#ast-sites-modal .elementor-template-library-menu-item.elementor-active {
|
649 |
-
border-bottom:
|
650 |
background-image: linear-gradient(to bottom, #f1f3f5, #fff);
|
651 |
color: #6d7882;
|
652 |
}
|
@@ -816,7 +881,7 @@
|
|
816 |
}
|
817 |
|
818 |
#ast-sites-modal .back-to-layout {
|
819 |
-
height:
|
820 |
padding: 14px;
|
821 |
}
|
822 |
|
@@ -845,20 +910,14 @@
|
|
845 |
#ast-sites-modal #wp-filter-search-input {
|
846 |
width: 100%;
|
847 |
opacity: 1;
|
848 |
-
background:
|
849 |
-
|
|
|
|
|
|
|
850 |
border-bottom: 1px solid #ddd;
|
851 |
-
border-radius: 6px;
|
852 |
-
font-size: 13px;
|
853 |
-
padding: 5px 20px;
|
854 |
-
border: 1px solid #ddd;
|
855 |
box-shadow: none;
|
856 |
-
height:
|
857 |
-
}
|
858 |
-
|
859 |
-
#ast-sites-modal #wp-filter-search-input:hover,
|
860 |
-
#ast-sites-modal #wp-filter-search-input:focus {
|
861 |
-
border: 1px solid #bbb;
|
862 |
}
|
863 |
|
864 |
#ast-sites-modal #wp-filter-search-input.searching {
|
@@ -994,10 +1053,57 @@
|
|
994 |
cursor: pointer;
|
995 |
}
|
996 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
997 |
#ast-sites-modal .ast-library-template-insert {
|
998 |
margin-left: 15px;
|
999 |
}
|
1000 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1001 |
#ast-sites-modal .astra-sites-import-template-action .button-hero.disabled {
|
1002 |
color: #66c6e4 !important;
|
1003 |
background: #008ec2 !important;
|
@@ -1020,8 +1126,7 @@
|
|
1020 |
}
|
1021 |
|
1022 |
#ast-sites-modal .ast-sites-floating-notice-wrap {
|
1023 |
-
margin:
|
1024 |
-
margin-top: 0px !important;
|
1025 |
background: #ffffff;
|
1026 |
padding: 8px 15px;
|
1027 |
border-right: 4px solid #00a0d2;
|
@@ -1030,7 +1135,6 @@
|
|
1030 |
vertical-align: middle;
|
1031 |
z-index: 99999;
|
1032 |
text-align: right;
|
1033 |
-
margin-top: -10px;
|
1034 |
display: none;
|
1035 |
}
|
1036 |
|
@@ -1069,14 +1173,14 @@
|
|
1069 |
margin-left: 15px;
|
1070 |
padding-right: 15px;
|
1071 |
padding-left:15px;
|
1072 |
-
height:
|
1073 |
border-right: 1px solid #e6e9ec;
|
1074 |
border-left: 1px solid #e6e9ec;
|
1075 |
opacity: 0;
|
1076 |
}
|
1077 |
|
1078 |
#ast-sites-modal .astra-sites-tooltip-icon {
|
1079 |
-
line-height:
|
1080 |
}
|
1081 |
|
1082 |
#ast-sites-modal .astra-sites-tooltip .dashicons-editor-help {
|
58 |
justify-content: space-between;
|
59 |
}
|
60 |
|
61 |
+
#ast-sites-modal .elementor-template-library-filter-toolbar > div {
|
62 |
+
margin-left: 10px;
|
63 |
+
}
|
64 |
+
|
65 |
#ast-sites-modal .astra-blocks-filter {
|
66 |
+
border-radius: 3px;
|
67 |
+
}
|
68 |
+
|
69 |
+
#ast-sites-modal .astra-blocks-filter,
|
70 |
+
#ast-sites-modal .elementor-template-library-order-input {
|
71 |
background: #fff;
|
72 |
+
width: 120px;
|
73 |
padding-right: 5px;
|
74 |
padding-left: 20px;
|
75 |
height: 28px;
|
77 |
}
|
78 |
|
79 |
#ast-sites-modal .astra-blocks-category-inner-wrap .select2-container {
|
80 |
+
width: 120px !important;
|
81 |
}
|
82 |
|
83 |
#ast-sites-modal .required-plugins-list li.plugin-card-head {
|
131 |
-webkit-transform: translateX(50%) translateY(-50%);
|
132 |
-ms-transform: translateX(50%) translateY(-50%);
|
133 |
transform: translateX(50%) translateY(-50%);
|
134 |
+
font-size: 34px;
|
135 |
}
|
136 |
#ast-sites-modal .astra-sites-library-template:not(.elementor-template-library-template-page) .elementor-template-library-template-footer {
|
137 |
padding: 7px;
|
138 |
+
padding-top: 5px;
|
139 |
padding-right: 5px;
|
140 |
background-color: #fff;
|
141 |
-webkit-transition: -webkit-transform .2s;
|
144 |
transition: transform .2s;
|
145 |
transition: transform .2s, -webkit-transform .2s;
|
146 |
}
|
147 |
+
#ast-sites-modal .astra-loading-icon, .astra-loading-icon:after {
|
148 |
+
width: 50px;
|
149 |
+
height: 50px;
|
150 |
+
}
|
151 |
#ast-sites-modal .astra-sites-library-template .elementor-template-library-template-footer {
|
152 |
display: -webkit-box;
|
153 |
display: -webkit-flex;
|
276 |
font-size: 15px;
|
277 |
}
|
278 |
|
279 |
+
#ast-sites-modal .elementor-template-library-order {
|
280 |
+
display: -webkit-box;
|
281 |
+
display: -webkit-flex;
|
282 |
+
display: -ms-flexbox;
|
283 |
+
display: flex;
|
284 |
+
}
|
285 |
+
|
286 |
+
#ast-sites-modal .ast-sites-template-library-filter-text-wrapper {
|
287 |
+
width: 200px;
|
288 |
+
position: relative;
|
289 |
+
}
|
290 |
+
|
291 |
+
#ast-sites-modal .ast-sites-template-library-filter-text-wrapper input {
|
292 |
+
border-bottom: 1px solid #d5dadf;
|
293 |
+
-webkit-border-radius: 0;
|
294 |
+
border-radius: 0;
|
295 |
+
font-size: 11px;
|
296 |
+
padding: 0 0 0 15px;
|
297 |
+
-webkit-transition: border 0.5s;
|
298 |
+
-o-transition: border 0.5s;
|
299 |
+
transition: border 0.5s;
|
300 |
+
background-color: transparent;
|
301 |
+
}
|
302 |
+
|
303 |
+
#ast-sites-modal .ast-sites-template-library-filter-text-wrapper i {
|
304 |
+
position: absolute;
|
305 |
+
top: 50%;
|
306 |
+
left: 0;
|
307 |
+
-webkit-transform: translateY(-50%);
|
308 |
+
-ms-transform: translateY(-50%);
|
309 |
+
transform: translateY(-50%);
|
310 |
+
}
|
311 |
+
|
312 |
+
#ast-sites-modal .ast-template-library-toolbar {
|
313 |
+
padding: 10px 45px 0 45px;
|
314 |
+
display: -webkit-box;
|
315 |
+
display: -webkit-flex;
|
316 |
+
display: -ms-flexbox;
|
317 |
+
display: flex;
|
318 |
+
-webkit-box-pack: justify;
|
319 |
+
-webkit-justify-content: space-between;
|
320 |
+
-ms-flex-pack: justify;
|
321 |
+
justify-content: space-between;
|
322 |
+
-webkit-box-align: center;
|
323 |
+
-webkit-align-items: center;
|
324 |
+
-ms-flex-align: center;
|
325 |
+
align-items: center;
|
326 |
+
}
|
327 |
+
|
328 |
#ast-sites-modal .dialog-buttons-wrapper .elementor-button-success:hover {
|
329 |
background-color: #39b54a;
|
330 |
}
|
380 |
-webkit-justify-content: space-between;
|
381 |
-ms-flex-pack: justify;
|
382 |
justify-content: space-between;
|
383 |
+
height: 50px;
|
384 |
}
|
385 |
|
386 |
#ast-sites-modal .ast-sites-modal__header__logo {
|
391 |
border-left: 1px solid #e6e9ec;
|
392 |
}
|
393 |
|
394 |
+
#ast-sites-modal .ast-block-insert i {
|
395 |
+
padding-left: 5px;
|
396 |
+
}
|
397 |
+
|
398 |
#ast-sites-modal .back-to-layout:before {
|
399 |
line-height: 21px;
|
400 |
width: 21px;
|
408 |
display: -webkit-flex;
|
409 |
display: -ms-flexbox;
|
410 |
display: flex;
|
|
|
411 |
}
|
412 |
|
413 |
#ast-sites-modal .elementor-template-library-header-menu {
|
422 |
}
|
423 |
|
424 |
#ast-sites-modal .ast-sites-modal__options .elementor-template-library-header-menu {
|
425 |
+
height: 50px;
|
426 |
}
|
427 |
|
428 |
#ast-sites-modal .astra-sites__sync-wrap {
|
429 |
+
padding: 17px;
|
430 |
border-right: 1px solid #e6e9ec;
|
431 |
cursor: pointer;
|
432 |
}
|
532 |
}
|
533 |
|
534 |
#ast-sites-modal .ast-sites-modal__header__close--normal {
|
535 |
+
width: 50px;
|
536 |
+
height: 50px;
|
537 |
border-right: 1px solid #e6e9ec;
|
538 |
}
|
539 |
|
667 |
|
668 |
#ast-sites-modal .theme-name {
|
669 |
height: auto;
|
|
|
670 |
align-self: center;
|
671 |
box-shadow: none;
|
672 |
background: none;
|
692 |
#ast-sites-modal .elementor-template-library-menu-item {
|
693 |
line-height: 1em;
|
694 |
width: 108px;
|
695 |
+
padding: 15px 0;
|
696 |
display: inline-block;
|
|
|
697 |
}
|
698 |
|
699 |
#ast-sites-modal .elementor-template-library-menu-item:hover {
|
707 |
|
708 |
#ast-sites-modal .astra-sites-sync-library-button span {
|
709 |
font-size: 16px;
|
710 |
+
color: #a4afb7;
|
711 |
}
|
712 |
|
713 |
#ast-sites-modal .elementor-template-library-menu-item.elementor-active {
|
714 |
+
border-bottom: 3px solid #0073aa;
|
715 |
background-image: linear-gradient(to bottom, #f1f3f5, #fff);
|
716 |
color: #6d7882;
|
717 |
}
|
881 |
}
|
882 |
|
883 |
#ast-sites-modal .back-to-layout {
|
884 |
+
height: 50px;
|
885 |
padding: 14px;
|
886 |
}
|
887 |
|
910 |
#ast-sites-modal #wp-filter-search-input {
|
911 |
width: 100%;
|
912 |
opacity: 1;
|
913 |
+
background: transparent;
|
914 |
+
border-bottom: 1px solid #ddd;
|
915 |
+
border-radius: 0;
|
916 |
+
font-size: 11px;
|
917 |
+
border: none;
|
918 |
border-bottom: 1px solid #ddd;
|
|
|
|
|
|
|
|
|
919 |
box-shadow: none;
|
920 |
+
height: auto;
|
|
|
|
|
|
|
|
|
|
|
921 |
}
|
922 |
|
923 |
#ast-sites-modal #wp-filter-search-input.searching {
|
1053 |
cursor: pointer;
|
1054 |
}
|
1055 |
|
1056 |
+
#ast-sites-modal .theme-id-container {
|
1057 |
+
justify-content: space-between;
|
1058 |
+
display: flex;
|
1059 |
+
line-height: 1.5em;
|
1060 |
+
}
|
1061 |
+
|
1062 |
+
#ast-sites-modal .elementor-templates-modal__header__items-area {
|
1063 |
+
height: 50px;
|
1064 |
+
}
|
1065 |
+
|
1066 |
#ast-sites-modal .ast-library-template-insert {
|
1067 |
margin-left: 15px;
|
1068 |
}
|
1069 |
|
1070 |
+
#ast-sites-modal .elementor-template-library-template-insert {
|
1071 |
+
color: #39b54a;
|
1072 |
+
padding: 7px;
|
1073 |
+
font-size: 12px;
|
1074 |
+
line-height: 1.5em;
|
1075 |
+
font-weight: 400;
|
1076 |
+
display: none;
|
1077 |
+
}
|
1078 |
+
|
1079 |
+
/* Uncomment this when Insert Link logic needs to be enabled. */
|
1080 |
+
/* #ast-sites-modal .astra-theme:hover .elementor-template-library-template-insert {
|
1081 |
+
display: block;
|
1082 |
+
} */
|
1083 |
+
|
1084 |
+
#ast-sites-modal .astra-sites-content-wrap.processing > div,
|
1085 |
+
#ast-sites-modal .astra-sites-content-wrap > div.astra-loading-wrap {
|
1086 |
+
opacity: 0;
|
1087 |
+
}
|
1088 |
+
/* Uncomment this when Insert Link logic needs to be enabled. */
|
1089 |
+
/* #ast-sites-modal .astra-sites-content-wrap.processing > div.astra-loading-wrap {
|
1090 |
+
opacity: 1;
|
1091 |
+
} */
|
1092 |
+
|
1093 |
+
#ast-sites-modal .elementor-template-library-template-go-pro {
|
1094 |
+
color: #D30C5C;
|
1095 |
+
padding: 7px;
|
1096 |
+
display: none;
|
1097 |
+
}
|
1098 |
+
|
1099 |
+
#ast-sites-modal .astra-theme:hover .elementor-template-library-template-go-pro {
|
1100 |
+
display: block;
|
1101 |
+
}
|
1102 |
+
|
1103 |
+
#ast-sites-modal .dialog-lightbox-content-block .elementor-template-library-template-insert {
|
1104 |
+
padding: 0;
|
1105 |
+
}
|
1106 |
+
|
1107 |
#ast-sites-modal .astra-sites-import-template-action .button-hero.disabled {
|
1108 |
color: #66c6e4 !important;
|
1109 |
background: #008ec2 !important;
|
1126 |
}
|
1127 |
|
1128 |
#ast-sites-modal .ast-sites-floating-notice-wrap {
|
1129 |
+
margin: 15px 45px -5px 45px;
|
|
|
1130 |
background: #ffffff;
|
1131 |
padding: 8px 15px;
|
1132 |
border-right: 4px solid #00a0d2;
|
1135 |
vertical-align: middle;
|
1136 |
z-index: 99999;
|
1137 |
text-align: right;
|
|
|
1138 |
display: none;
|
1139 |
}
|
1140 |
|
1173 |
margin-left: 15px;
|
1174 |
padding-right: 15px;
|
1175 |
padding-left:15px;
|
1176 |
+
height: 50px;
|
1177 |
border-right: 1px solid #e6e9ec;
|
1178 |
border-left: 1px solid #e6e9ec;
|
1179 |
opacity: 0;
|
1180 |
}
|
1181 |
|
1182 |
#ast-sites-modal .astra-sites-tooltip-icon {
|
1183 |
+
line-height: 50px;
|
1184 |
}
|
1185 |
|
1186 |
#ast-sites-modal .astra-sites-tooltip .dashicons-editor-help {
|
inc/assets/css/elementor-admin.css
CHANGED
@@ -58,9 +58,18 @@
|
|
58 |
justify-content: space-between;
|
59 |
}
|
60 |
|
|
|
|
|
|
|
|
|
61 |
#ast-sites-modal .astra-blocks-filter {
|
|
|
|
|
|
|
|
|
|
|
62 |
background: #fff;
|
63 |
-
width:
|
64 |
padding-left: 5px;
|
65 |
padding-right: 20px;
|
66 |
height: 28px;
|
@@ -68,7 +77,7 @@
|
|
68 |
}
|
69 |
|
70 |
#ast-sites-modal .astra-blocks-category-inner-wrap .select2-container {
|
71 |
-
width:
|
72 |
}
|
73 |
|
74 |
#ast-sites-modal .required-plugins-list li.plugin-card-head {
|
@@ -122,10 +131,11 @@
|
|
122 |
-webkit-transform: translateX(-50%) translateY(-50%);
|
123 |
-ms-transform: translateX(-50%) translateY(-50%);
|
124 |
transform: translateX(-50%) translateY(-50%);
|
125 |
-
font-size:
|
126 |
}
|
127 |
#ast-sites-modal .astra-sites-library-template:not(.elementor-template-library-template-page) .elementor-template-library-template-footer {
|
128 |
padding: 7px;
|
|
|
129 |
padding-left: 5px;
|
130 |
background-color: #fff;
|
131 |
-webkit-transition: -webkit-transform .2s;
|
@@ -134,6 +144,10 @@
|
|
134 |
transition: transform .2s;
|
135 |
transition: transform .2s, -webkit-transform .2s;
|
136 |
}
|
|
|
|
|
|
|
|
|
137 |
#ast-sites-modal .astra-sites-library-template .elementor-template-library-template-footer {
|
138 |
display: -webkit-box;
|
139 |
display: -webkit-flex;
|
@@ -262,6 +276,55 @@
|
|
262 |
font-size: 15px;
|
263 |
}
|
264 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
265 |
#ast-sites-modal .dialog-buttons-wrapper .elementor-button-success:hover {
|
266 |
background-color: #39b54a;
|
267 |
}
|
@@ -317,7 +380,7 @@
|
|
317 |
-webkit-justify-content: space-between;
|
318 |
-ms-flex-pack: justify;
|
319 |
justify-content: space-between;
|
320 |
-
height:
|
321 |
}
|
322 |
|
323 |
#ast-sites-modal .ast-sites-modal__header__logo {
|
@@ -328,6 +391,10 @@
|
|
328 |
border-right: 1px solid #e6e9ec;
|
329 |
}
|
330 |
|
|
|
|
|
|
|
|
|
331 |
#ast-sites-modal .back-to-layout:before {
|
332 |
line-height: 21px;
|
333 |
width: 21px;
|
@@ -341,7 +408,6 @@
|
|
341 |
display: -webkit-flex;
|
342 |
display: -ms-flexbox;
|
343 |
display: flex;
|
344 |
-
width: 150px;
|
345 |
}
|
346 |
|
347 |
#ast-sites-modal .elementor-template-library-header-menu {
|
@@ -356,11 +422,11 @@
|
|
356 |
}
|
357 |
|
358 |
#ast-sites-modal .ast-sites-modal__options .elementor-template-library-header-menu {
|
359 |
-
height:
|
360 |
}
|
361 |
|
362 |
#ast-sites-modal .astra-sites__sync-wrap {
|
363 |
-
padding:
|
364 |
border-left: 1px solid #e6e9ec;
|
365 |
cursor: pointer;
|
366 |
}
|
@@ -466,8 +532,8 @@
|
|
466 |
}
|
467 |
|
468 |
#ast-sites-modal .ast-sites-modal__header__close--normal {
|
469 |
-
width:
|
470 |
-
height:
|
471 |
border-left: 1px solid #e6e9ec;
|
472 |
}
|
473 |
|
@@ -601,7 +667,6 @@
|
|
601 |
|
602 |
#ast-sites-modal .theme-name {
|
603 |
height: auto;
|
604 |
-
width: calc( 100% - 1em );
|
605 |
align-self: center;
|
606 |
box-shadow: none;
|
607 |
background: none;
|
@@ -627,9 +692,8 @@
|
|
627 |
#ast-sites-modal .elementor-template-library-menu-item {
|
628 |
line-height: 1em;
|
629 |
width: 108px;
|
630 |
-
padding:
|
631 |
display: inline-block;
|
632 |
-
border-left: 1px solid #e6e9ec;
|
633 |
}
|
634 |
|
635 |
#ast-sites-modal .elementor-template-library-menu-item:hover {
|
@@ -643,10 +707,11 @@
|
|
643 |
|
644 |
#ast-sites-modal .astra-sites-sync-library-button span {
|
645 |
font-size: 16px;
|
|
|
646 |
}
|
647 |
|
648 |
#ast-sites-modal .elementor-template-library-menu-item.elementor-active {
|
649 |
-
border-bottom:
|
650 |
background-image: linear-gradient(to bottom, #f1f3f5, #fff);
|
651 |
color: #6d7882;
|
652 |
}
|
@@ -816,7 +881,7 @@
|
|
816 |
}
|
817 |
|
818 |
#ast-sites-modal .back-to-layout {
|
819 |
-
height:
|
820 |
padding: 14px;
|
821 |
}
|
822 |
|
@@ -845,20 +910,14 @@
|
|
845 |
#ast-sites-modal #wp-filter-search-input {
|
846 |
width: 100%;
|
847 |
opacity: 1;
|
848 |
-
background:
|
849 |
-
|
|
|
|
|
|
|
850 |
border-bottom: 1px solid #ddd;
|
851 |
-
border-radius: 6px;
|
852 |
-
font-size: 13px;
|
853 |
-
padding: 5px 20px;
|
854 |
-
border: 1px solid #ddd;
|
855 |
box-shadow: none;
|
856 |
-
height:
|
857 |
-
}
|
858 |
-
|
859 |
-
#ast-sites-modal #wp-filter-search-input:hover,
|
860 |
-
#ast-sites-modal #wp-filter-search-input:focus {
|
861 |
-
border: 1px solid #bbb;
|
862 |
}
|
863 |
|
864 |
#ast-sites-modal #wp-filter-search-input.searching {
|
@@ -994,10 +1053,57 @@
|
|
994 |
cursor: pointer;
|
995 |
}
|
996 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
997 |
#ast-sites-modal .ast-library-template-insert {
|
998 |
margin-right: 15px;
|
999 |
}
|
1000 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1001 |
#ast-sites-modal .astra-sites-import-template-action .button-hero.disabled {
|
1002 |
color: #66c6e4 !important;
|
1003 |
background: #008ec2 !important;
|
@@ -1020,8 +1126,7 @@
|
|
1020 |
}
|
1021 |
|
1022 |
#ast-sites-modal .ast-sites-floating-notice-wrap {
|
1023 |
-
margin:
|
1024 |
-
margin-top: 0px !important;
|
1025 |
background: #ffffff;
|
1026 |
padding: 8px 15px;
|
1027 |
border-left: 4px solid #00a0d2;
|
@@ -1030,7 +1135,6 @@
|
|
1030 |
vertical-align: middle;
|
1031 |
z-index: 99999;
|
1032 |
text-align: left;
|
1033 |
-
margin-top: -10px;
|
1034 |
display: none;
|
1035 |
}
|
1036 |
|
@@ -1069,14 +1173,14 @@
|
|
1069 |
margin-right: 15px;
|
1070 |
padding-left: 15px;
|
1071 |
padding-right:15px;
|
1072 |
-
height:
|
1073 |
border-left: 1px solid #e6e9ec;
|
1074 |
border-right: 1px solid #e6e9ec;
|
1075 |
opacity: 0;
|
1076 |
}
|
1077 |
|
1078 |
#ast-sites-modal .astra-sites-tooltip-icon {
|
1079 |
-
line-height:
|
1080 |
}
|
1081 |
|
1082 |
#ast-sites-modal .astra-sites-tooltip .dashicons-editor-help {
|
58 |
justify-content: space-between;
|
59 |
}
|
60 |
|
61 |
+
#ast-sites-modal .elementor-template-library-filter-toolbar > div {
|
62 |
+
margin-right: 10px;
|
63 |
+
}
|
64 |
+
|
65 |
#ast-sites-modal .astra-blocks-filter {
|
66 |
+
border-radius: 3px;
|
67 |
+
}
|
68 |
+
|
69 |
+
#ast-sites-modal .astra-blocks-filter,
|
70 |
+
#ast-sites-modal .elementor-template-library-order-input {
|
71 |
background: #fff;
|
72 |
+
width: 120px;
|
73 |
padding-left: 5px;
|
74 |
padding-right: 20px;
|
75 |
height: 28px;
|
77 |
}
|
78 |
|
79 |
#ast-sites-modal .astra-blocks-category-inner-wrap .select2-container {
|
80 |
+
width: 120px !important;
|
81 |
}
|
82 |
|
83 |
#ast-sites-modal .required-plugins-list li.plugin-card-head {
|
131 |
-webkit-transform: translateX(-50%) translateY(-50%);
|
132 |
-ms-transform: translateX(-50%) translateY(-50%);
|
133 |
transform: translateX(-50%) translateY(-50%);
|
134 |
+
font-size: 34px;
|
135 |
}
|
136 |
#ast-sites-modal .astra-sites-library-template:not(.elementor-template-library-template-page) .elementor-template-library-template-footer {
|
137 |
padding: 7px;
|
138 |
+
padding-top: 5px;
|
139 |
padding-left: 5px;
|
140 |
background-color: #fff;
|
141 |
-webkit-transition: -webkit-transform .2s;
|
144 |
transition: transform .2s;
|
145 |
transition: transform .2s, -webkit-transform .2s;
|
146 |
}
|
147 |
+
#ast-sites-modal .astra-loading-icon, .astra-loading-icon:after {
|
148 |
+
width: 50px;
|
149 |
+
height: 50px;
|
150 |
+
}
|
151 |
#ast-sites-modal .astra-sites-library-template .elementor-template-library-template-footer {
|
152 |
display: -webkit-box;
|
153 |
display: -webkit-flex;
|
276 |
font-size: 15px;
|
277 |
}
|
278 |
|
279 |
+
#ast-sites-modal .elementor-template-library-order {
|
280 |
+
display: -webkit-box;
|
281 |
+
display: -webkit-flex;
|
282 |
+
display: -ms-flexbox;
|
283 |
+
display: flex;
|
284 |
+
}
|
285 |
+
|
286 |
+
#ast-sites-modal .ast-sites-template-library-filter-text-wrapper {
|
287 |
+
width: 200px;
|
288 |
+
position: relative;
|
289 |
+
}
|
290 |
+
|
291 |
+
#ast-sites-modal .ast-sites-template-library-filter-text-wrapper input {
|
292 |
+
border-bottom: 1px solid #d5dadf;
|
293 |
+
-webkit-border-radius: 0;
|
294 |
+
border-radius: 0;
|
295 |
+
font-size: 11px;
|
296 |
+
padding: 0 15px 0 0;
|
297 |
+
-webkit-transition: border 0.5s;
|
298 |
+
-o-transition: border 0.5s;
|
299 |
+
transition: border 0.5s;
|
300 |
+
background-color: transparent;
|
301 |
+
}
|
302 |
+
|
303 |
+
#ast-sites-modal .ast-sites-template-library-filter-text-wrapper i {
|
304 |
+
position: absolute;
|
305 |
+
top: 50%;
|
306 |
+
right: 0;
|
307 |
+
-webkit-transform: translateY(-50%);
|
308 |
+
-ms-transform: translateY(-50%);
|
309 |
+
transform: translateY(-50%);
|
310 |
+
}
|
311 |
+
|
312 |
+
#ast-sites-modal .ast-template-library-toolbar {
|
313 |
+
padding: 10px 45px 0 45px;
|
314 |
+
display: -webkit-box;
|
315 |
+
display: -webkit-flex;
|
316 |
+
display: -ms-flexbox;
|
317 |
+
display: flex;
|
318 |
+
-webkit-box-pack: justify;
|
319 |
+
-webkit-justify-content: space-between;
|
320 |
+
-ms-flex-pack: justify;
|
321 |
+
justify-content: space-between;
|
322 |
+
-webkit-box-align: center;
|
323 |
+
-webkit-align-items: center;
|
324 |
+
-ms-flex-align: center;
|
325 |
+
align-items: center;
|
326 |
+
}
|
327 |
+
|
328 |
#ast-sites-modal .dialog-buttons-wrapper .elementor-button-success:hover {
|
329 |
background-color: #39b54a;
|
330 |
}
|
380 |
-webkit-justify-content: space-between;
|
381 |
-ms-flex-pack: justify;
|
382 |
justify-content: space-between;
|
383 |
+
height: 50px;
|
384 |
}
|
385 |
|
386 |
#ast-sites-modal .ast-sites-modal__header__logo {
|
391 |
border-right: 1px solid #e6e9ec;
|
392 |
}
|
393 |
|
394 |
+
#ast-sites-modal .ast-block-insert i {
|
395 |
+
padding-right: 5px;
|
396 |
+
}
|
397 |
+
|
398 |
#ast-sites-modal .back-to-layout:before {
|
399 |
line-height: 21px;
|
400 |
width: 21px;
|
408 |
display: -webkit-flex;
|
409 |
display: -ms-flexbox;
|
410 |
display: flex;
|
|
|
411 |
}
|
412 |
|
413 |
#ast-sites-modal .elementor-template-library-header-menu {
|
422 |
}
|
423 |
|
424 |
#ast-sites-modal .ast-sites-modal__options .elementor-template-library-header-menu {
|
425 |
+
height: 50px;
|
426 |
}
|
427 |
|
428 |
#ast-sites-modal .astra-sites__sync-wrap {
|
429 |
+
padding: 17px;
|
430 |
border-left: 1px solid #e6e9ec;
|
431 |
cursor: pointer;
|
432 |
}
|
532 |
}
|
533 |
|
534 |
#ast-sites-modal .ast-sites-modal__header__close--normal {
|
535 |
+
width: 50px;
|
536 |
+
height: 50px;
|
537 |
border-left: 1px solid #e6e9ec;
|
538 |
}
|
539 |
|
667 |
|
668 |
#ast-sites-modal .theme-name {
|
669 |
height: auto;
|
|
|
670 |
align-self: center;
|
671 |
box-shadow: none;
|
672 |
background: none;
|
692 |
#ast-sites-modal .elementor-template-library-menu-item {
|
693 |
line-height: 1em;
|
694 |
width: 108px;
|
695 |
+
padding: 15px 0;
|
696 |
display: inline-block;
|
|
|
697 |
}
|
698 |
|
699 |
#ast-sites-modal .elementor-template-library-menu-item:hover {
|
707 |
|
708 |
#ast-sites-modal .astra-sites-sync-library-button span {
|
709 |
font-size: 16px;
|
710 |
+
color: #a4afb7;
|
711 |
}
|
712 |
|
713 |
#ast-sites-modal .elementor-template-library-menu-item.elementor-active {
|
714 |
+
border-bottom: 3px solid #0073aa;
|
715 |
background-image: linear-gradient(to bottom, #f1f3f5, #fff);
|
716 |
color: #6d7882;
|
717 |
}
|
881 |
}
|
882 |
|
883 |
#ast-sites-modal .back-to-layout {
|
884 |
+
height: 50px;
|
885 |
padding: 14px;
|
886 |
}
|
887 |
|
910 |
#ast-sites-modal #wp-filter-search-input {
|
911 |
width: 100%;
|
912 |
opacity: 1;
|
913 |
+
background: transparent;
|
914 |
+
border-bottom: 1px solid #ddd;
|
915 |
+
border-radius: 0;
|
916 |
+
font-size: 11px;
|
917 |
+
border: none;
|
918 |
border-bottom: 1px solid #ddd;
|
|
|
|
|
|
|
|
|
919 |
box-shadow: none;
|
920 |
+
height: auto;
|
|
|
|
|
|
|
|
|
|
|
921 |
}
|
922 |
|
923 |
#ast-sites-modal #wp-filter-search-input.searching {
|
1053 |
cursor: pointer;
|
1054 |
}
|
1055 |
|
1056 |
+
#ast-sites-modal .theme-id-container {
|
1057 |
+
justify-content: space-between;
|
1058 |
+
display: flex;
|
1059 |
+
line-height: 1.5em;
|
1060 |
+
}
|
1061 |
+
|
1062 |
+
#ast-sites-modal .elementor-templates-modal__header__items-area {
|
1063 |
+
height: 50px;
|
1064 |
+
}
|
1065 |
+
|
1066 |
#ast-sites-modal .ast-library-template-insert {
|
1067 |
margin-right: 15px;
|
1068 |
}
|
1069 |
|
1070 |
+
#ast-sites-modal .elementor-template-library-template-insert {
|
1071 |
+
color: #39b54a;
|
1072 |
+
padding: 7px;
|
1073 |
+
font-size: 12px;
|
1074 |
+
line-height: 1.5em;
|
1075 |
+
font-weight: 400;
|
1076 |
+
display: none;
|
1077 |
+
}
|
1078 |
+
|
1079 |
+
/* Uncomment this when Insert Link logic needs to be enabled. */
|
1080 |
+
/* #ast-sites-modal .astra-theme:hover .elementor-template-library-template-insert {
|
1081 |
+
display: block;
|
1082 |
+
} */
|
1083 |
+
|
1084 |
+
#ast-sites-modal .astra-sites-content-wrap.processing > div,
|
1085 |
+
#ast-sites-modal .astra-sites-content-wrap > div.astra-loading-wrap {
|
1086 |
+
opacity: 0;
|
1087 |
+
}
|
1088 |
+
/* Uncomment this when Insert Link logic needs to be enabled. */
|
1089 |
+
/* #ast-sites-modal .astra-sites-content-wrap.processing > div.astra-loading-wrap {
|
1090 |
+
opacity: 1;
|
1091 |
+
} */
|
1092 |
+
|
1093 |
+
#ast-sites-modal .elementor-template-library-template-go-pro {
|
1094 |
+
color: #D30C5C;
|
1095 |
+
padding: 7px;
|
1096 |
+
display: none;
|
1097 |
+
}
|
1098 |
+
|
1099 |
+
#ast-sites-modal .astra-theme:hover .elementor-template-library-template-go-pro {
|
1100 |
+
display: block;
|
1101 |
+
}
|
1102 |
+
|
1103 |
+
#ast-sites-modal .dialog-lightbox-content-block .elementor-template-library-template-insert {
|
1104 |
+
padding: 0;
|
1105 |
+
}
|
1106 |
+
|
1107 |
#ast-sites-modal .astra-sites-import-template-action .button-hero.disabled {
|
1108 |
color: #66c6e4 !important;
|
1109 |
background: #008ec2 !important;
|
1126 |
}
|
1127 |
|
1128 |
#ast-sites-modal .ast-sites-floating-notice-wrap {
|
1129 |
+
margin: 15px 45px -5px 45px;
|
|
|
1130 |
background: #ffffff;
|
1131 |
padding: 8px 15px;
|
1132 |
border-left: 4px solid #00a0d2;
|
1135 |
vertical-align: middle;
|
1136 |
z-index: 99999;
|
1137 |
text-align: left;
|
|
|
1138 |
display: none;
|
1139 |
}
|
1140 |
|
1173 |
margin-right: 15px;
|
1174 |
padding-left: 15px;
|
1175 |
padding-right:15px;
|
1176 |
+
height: 50px;
|
1177 |
border-left: 1px solid #e6e9ec;
|
1178 |
border-right: 1px solid #e6e9ec;
|
1179 |
opacity: 0;
|
1180 |
}
|
1181 |
|
1182 |
#ast-sites-modal .astra-sites-tooltip-icon {
|
1183 |
+
line-height: 50px;
|
1184 |
}
|
1185 |
|
1186 |
#ast-sites-modal .astra-sites-tooltip .dashicons-editor-help {
|
inc/assets/js/admin-page.js
CHANGED
@@ -945,7 +945,7 @@ var AstraSitesAjaxQueue = (function() {
|
|
945 |
})
|
946 |
.fail(function( jqXHR ){
|
947 |
AstraSitesAdmin._log( jqXHR, 'error' );
|
948 |
-
AstraSitesAdmin._importFailMessage( jqXHR.status + jqXHR.statusText, 'Site Count Request Failed
|
949 |
console.groupEnd('Sync Library');
|
950 |
})
|
951 |
.done(function ( response ) {
|
@@ -1034,7 +1034,7 @@ var AstraSitesAjaxQueue = (function() {
|
|
1034 |
})
|
1035 |
.fail(function( jqXHR ){
|
1036 |
AstraSitesAdmin._log( jqXHR );
|
1037 |
-
AstraSitesAdmin._importFailMessage( jqXHR.status + jqXHR.statusText, 'Category Import Failed
|
1038 |
console.groupEnd( 'Importing Categories' );
|
1039 |
}).done(function ( response ) {
|
1040 |
AstraSitesAdmin._log( response );
|
@@ -1055,7 +1055,7 @@ var AstraSitesAjaxQueue = (function() {
|
|
1055 |
})
|
1056 |
.fail(function( jqXHR ){
|
1057 |
AstraSitesAdmin._log( jqXHR );
|
1058 |
-
AstraSitesAdmin._importFailMessage( jqXHR.status + jqXHR.statusText, 'Category Import Failed
|
1059 |
console.groupCollapsed( 'Importing Site Categories' );
|
1060 |
}).done(function ( response ) {
|
1061 |
AstraSitesAdmin._log( response );
|
@@ -1076,7 +1076,7 @@ var AstraSitesAjaxQueue = (function() {
|
|
1076 |
})
|
1077 |
.fail(function( jqXHR ){
|
1078 |
AstraSitesAdmin._log( jqXHR );
|
1079 |
-
AstraSitesAdmin._importFailMessage( jqXHR.status + ' ' + jqXHR.statusText, 'Page Builder Import Failed
|
1080 |
console.groupEnd( 'Importing Page Builders' );
|
1081 |
}).done(function ( response ) {
|
1082 |
AstraSitesAdmin._log( response );
|
@@ -1088,20 +1088,49 @@ var AstraSitesAjaxQueue = (function() {
|
|
1088 |
url : astraSitesVars.ajaxurl,
|
1089 |
type : 'POST',
|
1090 |
data : {
|
1091 |
-
action : 'astra-sites-
|
1092 |
},
|
1093 |
beforeSend: function() {
|
1094 |
-
console.groupCollapsed( '
|
1095 |
-
AstraSitesAdmin._log( '
|
1096 |
},
|
1097 |
})
|
1098 |
.fail(function( jqXHR ){
|
1099 |
-
AstraSitesAdmin._log( jqXHR );
|
1100 |
-
AstraSitesAdmin._importFailMessage( jqXHR.status +
|
1101 |
-
console.groupEnd
|
1102 |
-
|
|
|
1103 |
AstraSitesAdmin._log( response );
|
1104 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1105 |
});
|
1106 |
|
1107 |
// Import Block Categories.
|
@@ -1118,7 +1147,7 @@ var AstraSitesAjaxQueue = (function() {
|
|
1118 |
})
|
1119 |
.fail(function( jqXHR ){
|
1120 |
AstraSitesAdmin._log( jqXHR );
|
1121 |
-
AstraSitesAdmin._importFailMessage( jqXHR.status + ' ' + jqXHR.statusText, 'Category Import Failed
|
1122 |
console.groupEnd( 'Importing Block Categories' );
|
1123 |
}).done(function ( response ) {
|
1124 |
AstraSitesAdmin._log( response );
|
@@ -1142,7 +1171,7 @@ var AstraSitesAjaxQueue = (function() {
|
|
1142 |
|
1143 |
var noticeContent = wp.updates.adminNotice( {
|
1144 |
className: 'astra-sites-sync-library-message astra-sites-notice notice notice-info',
|
1145 |
-
message:
|
1146 |
} );
|
1147 |
$('#screen-meta').after( noticeContent );
|
1148 |
|
@@ -1161,7 +1190,7 @@ var AstraSitesAjaxQueue = (function() {
|
|
1161 |
})
|
1162 |
.fail(function( jqXHR ){
|
1163 |
AstraSitesAdmin._log( jqXHR );
|
1164 |
-
AstraSitesAdmin._importFailMessage( jqXHR.status + ' ' + jqXHR.statusText, 'Sync Library Failed
|
1165 |
console.groupEnd( 'Update Library Request' );
|
1166 |
})
|
1167 |
.done(function ( response ) {
|
@@ -1405,7 +1434,7 @@ var AstraSitesAjaxQueue = (function() {
|
|
1405 |
})
|
1406 |
.fail(function( jqXHR ){
|
1407 |
AstraSitesAdmin._log( jqXHR );
|
1408 |
-
AstraSitesAdmin._importFailMessage( jqXHR.status + ' ' + jqXHR.statusText, 'Favorite/Unfavorite Failed
|
1409 |
console.groupEnd();
|
1410 |
})
|
1411 |
.done(function ( response ) {
|
@@ -1894,7 +1923,7 @@ var AstraSitesAjaxQueue = (function() {
|
|
1894 |
})
|
1895 |
.fail(function( jqXHR ){
|
1896 |
AstraSitesAdmin._log( jqXHR );
|
1897 |
-
AstraSitesAdmin._importFailMessage( jqXHR.status + ' ' + jqXHR.statusText, 'Reset Customizer Settings Failed
|
1898 |
console.groupEnd();
|
1899 |
})
|
1900 |
.done(function ( data ) {
|
@@ -1923,7 +1952,7 @@ var AstraSitesAjaxQueue = (function() {
|
|
1923 |
})
|
1924 |
.fail(function( jqXHR ){
|
1925 |
AstraSitesAdmin._log( jqXHR );
|
1926 |
-
AstraSitesAdmin._importFailMessage( jqXHR.status + ' ' + jqXHR.statusText, 'Reset Site Options Failed
|
1927 |
console.groupEnd();
|
1928 |
})
|
1929 |
.done(function ( data ) {
|
@@ -1951,7 +1980,7 @@ var AstraSitesAjaxQueue = (function() {
|
|
1951 |
})
|
1952 |
.fail(function( jqXHR ){
|
1953 |
AstraSitesAdmin._log( jqXHR );
|
1954 |
-
AstraSitesAdmin._importFailMessage( jqXHR.status + ' ' + jqXHR.statusText, 'Reset Widgets Data Failed
|
1955 |
console.groupEnd();
|
1956 |
})
|
1957 |
.done(function ( data ) {
|
@@ -2164,7 +2193,7 @@ var AstraSitesAjaxQueue = (function() {
|
|
2164 |
})
|
2165 |
.fail(function( jqXHR ){
|
2166 |
AstraSitesAdmin._log( jqXHR );
|
2167 |
-
AstraSitesAdmin._importFailMessage( jqXHR.status + ' ' + jqXHR.statusText, 'Backup Customizer Settings Failed
|
2168 |
console.groupEnd();
|
2169 |
})
|
2170 |
.done(function ( data ) {
|
@@ -2202,7 +2231,7 @@ var AstraSitesAjaxQueue = (function() {
|
|
2202 |
})
|
2203 |
.fail(function( jqXHR ){
|
2204 |
AstraSitesAdmin._log( jqXHR );
|
2205 |
-
AstraSitesAdmin._importFailMessage( jqXHR.status + ' ' + jqXHR.statusText, 'Import Complete Failed
|
2206 |
console.groupEnd();
|
2207 |
})
|
2208 |
.done(function ( response ) {
|
@@ -2249,7 +2278,7 @@ var AstraSitesAjaxQueue = (function() {
|
|
2249 |
})
|
2250 |
.fail(function( jqXHR ){
|
2251 |
AstraSitesAdmin._log( jqXHR );
|
2252 |
-
AstraSitesAdmin._importFailMessage( jqXHR.status + ' ' + jqXHR.statusText, 'Import Widgets Failed
|
2253 |
console.groupEnd();
|
2254 |
})
|
2255 |
.done(function ( response ) {
|
@@ -2294,7 +2323,7 @@ var AstraSitesAjaxQueue = (function() {
|
|
2294 |
})
|
2295 |
.fail(function( jqXHR ){
|
2296 |
AstraSitesAdmin._log( jqXHR );
|
2297 |
-
AstraSitesAdmin._importFailMessage( jqXHR.status + ' ' + jqXHR.statusText, 'Import Site Options Failed
|
2298 |
console.groupEnd();
|
2299 |
})
|
2300 |
.done(function ( response ) {
|
@@ -2339,20 +2368,18 @@ var AstraSitesAjaxQueue = (function() {
|
|
2339 |
})
|
2340 |
.fail(function( jqXHR ){
|
2341 |
AstraSitesAdmin._log( jqXHR );
|
2342 |
-
AstraSitesAdmin._importFailMessage( jqXHR.status + ' ' + jqXHR.statusText, 'Prepare Import XML Failed
|
2343 |
console.groupEnd();
|
2344 |
})
|
2345 |
.done(function ( response ) {
|
2346 |
|
2347 |
AstraSitesAdmin._log( response );
|
2348 |
|
2349 |
-
response.data.url = wp.url.addQueryArgs( response.data.url, { _ajax_nonce: astraSitesVars._ajax_nonce } )
|
2350 |
-
|
2351 |
// 2. Fail - Prepare XML Data.
|
2352 |
if( false === response.success ) {
|
2353 |
var error_msg = response.data.error || response.data;
|
2354 |
|
2355 |
-
AstraSitesAdmin._importFailMessage(
|
2356 |
|
2357 |
console.groupEnd();
|
2358 |
} else {
|
@@ -2472,7 +2499,7 @@ var AstraSitesAjaxQueue = (function() {
|
|
2472 |
})
|
2473 |
.fail(function( jqXHR ){
|
2474 |
AstraSitesAdmin._log( jqXHR );
|
2475 |
-
AstraSitesAdmin._importFailMessage( jqXHR.status + ' ' + jqXHR.statusText, 'Import Cartflows Flow Failed
|
2476 |
console.groupEnd();
|
2477 |
})
|
2478 |
.done(function ( response ) {
|
@@ -2516,7 +2543,7 @@ var AstraSitesAjaxQueue = (function() {
|
|
2516 |
})
|
2517 |
.fail(function( jqXHR ){
|
2518 |
AstraSitesAdmin._log( jqXHR );
|
2519 |
-
AstraSitesAdmin._importFailMessage( jqXHR.status + ' ' + jqXHR.statusText, 'Import WP Forms Failed
|
2520 |
console.groupEnd();
|
2521 |
})
|
2522 |
.done(function ( response ) {
|
@@ -2561,7 +2588,7 @@ var AstraSitesAjaxQueue = (function() {
|
|
2561 |
})
|
2562 |
.fail(function( jqXHR ){
|
2563 |
AstraSitesAdmin._log( jqXHR );
|
2564 |
-
AstraSitesAdmin._importFailMessage( jqXHR.status + ' ' + jqXHR.statusText, 'Import Customizer Settings Failed
|
2565 |
console.groupEnd();
|
2566 |
})
|
2567 |
.done(function ( response ) {
|
@@ -2605,15 +2632,21 @@ var AstraSitesAjaxQueue = (function() {
|
|
2605 |
*
|
2606 |
* @param {string} data Error message.
|
2607 |
*/
|
2608 |
-
_importFailMessage: function( message, heading ) {
|
2609 |
-
|
2610 |
-
var output = '<p>Your website is facing a temporary issue in connecting the template server.</p>';
|
2611 |
-
output += '<p>Read <a href="https://wpastra.com/docs/import-process-interrupted/" target="_blank">article</a> to resolve the issue and continue importing template.</p>';
|
2612 |
|
2613 |
heading = heading || 'The import process interrupted';
|
2614 |
|
2615 |
-
|
2616 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2617 |
}
|
2618 |
|
2619 |
$('.astra-sites-import-content').html( output );
|
@@ -2976,7 +3009,7 @@ var AstraSitesAjaxQueue = (function() {
|
|
2976 |
})
|
2977 |
.fail(function( jqXHR ){
|
2978 |
AstraSitesAdmin._log( jqXHR );
|
2979 |
-
AstraSitesAdmin._importFailMessage( jqXHR.status + ' ' + jqXHR.statusText );
|
2980 |
console.groupEnd();
|
2981 |
})
|
2982 |
.done(function ( response ) {
|
@@ -3081,7 +3114,7 @@ var AstraSitesAjaxQueue = (function() {
|
|
3081 |
})
|
3082 |
.fail(function( jqXHR ){
|
3083 |
AstraSitesAdmin._log( jqXHR );
|
3084 |
-
AstraSitesAdmin._importFailMessage( jqXHR.status + ' ' + jqXHR.statusText, 'Page Import API Request Failed
|
3085 |
console.groupEnd();
|
3086 |
})
|
3087 |
.done(function ( response ) {
|
@@ -3192,7 +3225,7 @@ var AstraSitesAjaxQueue = (function() {
|
|
3192 |
|
3193 |
// Remove loader.
|
3194 |
$('.required-plugins').removeClass('loading').html('');
|
3195 |
-
AstraSitesAdmin._importFailMessage( jqXHR.status + jqXHR.statusText, 'Required Plugins Failed
|
3196 |
console.groupEnd();
|
3197 |
})
|
3198 |
.done(function ( response ) {
|
@@ -3214,6 +3247,13 @@ var AstraSitesAjaxQueue = (function() {
|
|
3214 |
|
3215 |
if( response.data['update_avilable_plugins'].length ) {
|
3216 |
compatibilities.warnings['update-available'] = astraSitesVars.compatibilities_data['update-available'];
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
3217 |
} else {
|
3218 |
delete compatibilities.warnings['update-available'];
|
3219 |
}
|
@@ -3522,7 +3562,7 @@ var AstraSitesAjaxQueue = (function() {
|
|
3522 |
})
|
3523 |
.fail(function( jqXHR ){
|
3524 |
AstraSitesAdmin._log( jqXHR );
|
3525 |
-
AstraSitesAdmin._importFailMessage( jqXHR.status + jqXHR.statusText, 'Import WP Forms Failed
|
3526 |
console.groupEnd();
|
3527 |
})
|
3528 |
.done(function ( response ) {
|
945 |
})
|
946 |
.fail(function( jqXHR ){
|
947 |
AstraSitesAdmin._log( jqXHR, 'error' );
|
948 |
+
AstraSitesAdmin._importFailMessage( jqXHR.status + jqXHR.statusText, 'Site Count Request Failed!', jqXHR );
|
949 |
console.groupEnd('Sync Library');
|
950 |
})
|
951 |
.done(function ( response ) {
|
1034 |
})
|
1035 |
.fail(function( jqXHR ){
|
1036 |
AstraSitesAdmin._log( jqXHR );
|
1037 |
+
AstraSitesAdmin._importFailMessage( jqXHR.status + jqXHR.statusText, 'Category Import Failed!', jqXHR );
|
1038 |
console.groupEnd( 'Importing Categories' );
|
1039 |
}).done(function ( response ) {
|
1040 |
AstraSitesAdmin._log( response );
|
1055 |
})
|
1056 |
.fail(function( jqXHR ){
|
1057 |
AstraSitesAdmin._log( jqXHR );
|
1058 |
+
AstraSitesAdmin._importFailMessage( jqXHR.status + jqXHR.statusText, 'Category Import Failed!', jqXHR );
|
1059 |
console.groupCollapsed( 'Importing Site Categories' );
|
1060 |
}).done(function ( response ) {
|
1061 |
AstraSitesAdmin._log( response );
|
1076 |
})
|
1077 |
.fail(function( jqXHR ){
|
1078 |
AstraSitesAdmin._log( jqXHR );
|
1079 |
+
AstraSitesAdmin._importFailMessage( jqXHR.status + ' ' + jqXHR.statusText, 'Page Builder Import Failed!', jqXHR );
|
1080 |
console.groupEnd( 'Importing Page Builders' );
|
1081 |
}).done(function ( response ) {
|
1082 |
AstraSitesAdmin._log( response );
|
1088 |
url : astraSitesVars.ajaxurl,
|
1089 |
type : 'POST',
|
1090 |
data : {
|
1091 |
+
action : 'astra-sites-get-blocks-request-count',
|
1092 |
},
|
1093 |
beforeSend: function() {
|
1094 |
+
console.groupCollapsed( 'Updating Blocks' );
|
1095 |
+
AstraSitesAdmin._log( 'Updating Blocks' );
|
1096 |
},
|
1097 |
})
|
1098 |
.fail(function( jqXHR ){
|
1099 |
+
AstraSitesAdmin._log( jqXHR, 'error' );
|
1100 |
+
AstraSitesAdmin._importFailMessage( jqXHR.status + jqXHR.statusText, 'Blocks Count Request Failed!', jqXHR );
|
1101 |
+
console.groupEnd('Updating Blocks');
|
1102 |
+
})
|
1103 |
+
.done(function ( response ) {
|
1104 |
AstraSitesAdmin._log( response );
|
1105 |
+
if( response.success ) {
|
1106 |
+
var total = response.data.pages;
|
1107 |
+
|
1108 |
+
AstraSitesAdmin._log( total );
|
1109 |
+
|
1110 |
+
for( let i = 1; i <= total; i++ ) {
|
1111 |
+
AstraSitesAjaxQueue.add({
|
1112 |
+
url: astraSitesVars.ajaxurl,
|
1113 |
+
type: 'POST',
|
1114 |
+
data: {
|
1115 |
+
action : 'astra-sites-import-blocks',
|
1116 |
+
page_no : i,
|
1117 |
+
},
|
1118 |
+
beforeSend: function() {
|
1119 |
+
console.groupCollapsed( 'Importing Blocks - Page ' + i );
|
1120 |
+
AstraSitesAdmin._log( 'Importing Blocks - Page ' + i );
|
1121 |
+
},
|
1122 |
+
success: function( response ){
|
1123 |
+
AstraSitesAdmin._log( response );
|
1124 |
+
console.groupEnd( 'Importing Blocks - Page ' + i );
|
1125 |
+
}
|
1126 |
+
});
|
1127 |
+
}
|
1128 |
+
|
1129 |
+
// Run the AJAX queue.
|
1130 |
+
AstraSitesAjaxQueue.run();
|
1131 |
+
} else {
|
1132 |
+
AstraSitesAdmin._importFailMessage( response.data, 'Blocks Count Request Failed!' );
|
1133 |
+
}
|
1134 |
});
|
1135 |
|
1136 |
// Import Block Categories.
|
1147 |
})
|
1148 |
.fail(function( jqXHR ){
|
1149 |
AstraSitesAdmin._log( jqXHR );
|
1150 |
+
AstraSitesAdmin._importFailMessage( jqXHR.status + ' ' + jqXHR.statusText, 'Category Import Failed!', jqXHR );
|
1151 |
console.groupEnd( 'Importing Block Categories' );
|
1152 |
}).done(function ( response ) {
|
1153 |
AstraSitesAdmin._log( response );
|
1171 |
|
1172 |
var noticeContent = wp.updates.adminNotice( {
|
1173 |
className: 'astra-sites-sync-library-message astra-sites-notice notice notice-info',
|
1174 |
+
message: astraSitesVars.syncLibraryStart + '<button type="button" class="notice-dismiss"><span class="screen-reader-text">'+commonL10n.dismiss+'</span></button>',
|
1175 |
} );
|
1176 |
$('#screen-meta').after( noticeContent );
|
1177 |
|
1190 |
})
|
1191 |
.fail(function( jqXHR ){
|
1192 |
AstraSitesAdmin._log( jqXHR );
|
1193 |
+
AstraSitesAdmin._importFailMessage( jqXHR.status + ' ' + jqXHR.statusText, 'Sync Library Failed!', jqXHR );
|
1194 |
console.groupEnd( 'Update Library Request' );
|
1195 |
})
|
1196 |
.done(function ( response ) {
|
1434 |
})
|
1435 |
.fail(function( jqXHR ){
|
1436 |
AstraSitesAdmin._log( jqXHR );
|
1437 |
+
AstraSitesAdmin._importFailMessage( jqXHR.status + ' ' + jqXHR.statusText, 'Favorite/Unfavorite Failed!', jqXHR );
|
1438 |
console.groupEnd();
|
1439 |
})
|
1440 |
.done(function ( response ) {
|
1923 |
})
|
1924 |
.fail(function( jqXHR ){
|
1925 |
AstraSitesAdmin._log( jqXHR );
|
1926 |
+
AstraSitesAdmin._importFailMessage( jqXHR.status + ' ' + jqXHR.statusText, 'Reset Customizer Settings Failed!', jqXHR );
|
1927 |
console.groupEnd();
|
1928 |
})
|
1929 |
.done(function ( data ) {
|
1952 |
})
|
1953 |
.fail(function( jqXHR ){
|
1954 |
AstraSitesAdmin._log( jqXHR );
|
1955 |
+
AstraSitesAdmin._importFailMessage( jqXHR.status + ' ' + jqXHR.statusText, 'Reset Site Options Failed!', jqXHR );
|
1956 |
console.groupEnd();
|
1957 |
})
|
1958 |
.done(function ( data ) {
|
1980 |
})
|
1981 |
.fail(function( jqXHR ){
|
1982 |
AstraSitesAdmin._log( jqXHR );
|
1983 |
+
AstraSitesAdmin._importFailMessage( jqXHR.status + ' ' + jqXHR.statusText, 'Reset Widgets Data Failed!', jqXHR );
|
1984 |
console.groupEnd();
|
1985 |
})
|
1986 |
.done(function ( data ) {
|
2193 |
})
|
2194 |
.fail(function( jqXHR ){
|
2195 |
AstraSitesAdmin._log( jqXHR );
|
2196 |
+
AstraSitesAdmin._importFailMessage( jqXHR.status + ' ' + jqXHR.statusText, 'Backup Customizer Settings Failed!', jqXHR );
|
2197 |
console.groupEnd();
|
2198 |
})
|
2199 |
.done(function ( data ) {
|
2231 |
})
|
2232 |
.fail(function( jqXHR ){
|
2233 |
AstraSitesAdmin._log( jqXHR );
|
2234 |
+
AstraSitesAdmin._importFailMessage( jqXHR.status + ' ' + jqXHR.statusText, 'Import Complete Failed!', jqXHR );
|
2235 |
console.groupEnd();
|
2236 |
})
|
2237 |
.done(function ( response ) {
|
2278 |
})
|
2279 |
.fail(function( jqXHR ){
|
2280 |
AstraSitesAdmin._log( jqXHR );
|
2281 |
+
AstraSitesAdmin._importFailMessage( jqXHR.status + ' ' + jqXHR.statusText, 'Import Widgets Failed!', jqXHR );
|
2282 |
console.groupEnd();
|
2283 |
})
|
2284 |
.done(function ( response ) {
|
2323 |
})
|
2324 |
.fail(function( jqXHR ){
|
2325 |
AstraSitesAdmin._log( jqXHR );
|
2326 |
+
AstraSitesAdmin._importFailMessage( jqXHR.status + ' ' + jqXHR.statusText, 'Import Site Options Failed!', jqXHR );
|
2327 |
console.groupEnd();
|
2328 |
})
|
2329 |
.done(function ( response ) {
|
2368 |
})
|
2369 |
.fail(function( jqXHR ){
|
2370 |
AstraSitesAdmin._log( jqXHR );
|
2371 |
+
AstraSitesAdmin._importFailMessage( jqXHR.status + ' ' + jqXHR.statusText, 'Prepare Import XML Failed!', jqXHR );
|
2372 |
console.groupEnd();
|
2373 |
})
|
2374 |
.done(function ( response ) {
|
2375 |
|
2376 |
AstraSitesAdmin._log( response );
|
2377 |
|
|
|
|
|
2378 |
// 2. Fail - Prepare XML Data.
|
2379 |
if( false === response.success ) {
|
2380 |
var error_msg = response.data.error || response.data;
|
2381 |
|
2382 |
+
AstraSitesAdmin._importFailMessage( astraSitesVars.xmlRequiredFilesMissing );
|
2383 |
|
2384 |
console.groupEnd();
|
2385 |
} else {
|
2499 |
})
|
2500 |
.fail(function( jqXHR ){
|
2501 |
AstraSitesAdmin._log( jqXHR );
|
2502 |
+
AstraSitesAdmin._importFailMessage( jqXHR.status + ' ' + jqXHR.statusText, 'Import Cartflows Flow Failed!', jqXHR );
|
2503 |
console.groupEnd();
|
2504 |
})
|
2505 |
.done(function ( response ) {
|
2543 |
})
|
2544 |
.fail(function( jqXHR ){
|
2545 |
AstraSitesAdmin._log( jqXHR );
|
2546 |
+
AstraSitesAdmin._importFailMessage( jqXHR.status + ' ' + jqXHR.statusText, 'Import WP Forms Failed!', jqXHR );
|
2547 |
console.groupEnd();
|
2548 |
})
|
2549 |
.done(function ( response ) {
|
2588 |
})
|
2589 |
.fail(function( jqXHR ){
|
2590 |
AstraSitesAdmin._log( jqXHR );
|
2591 |
+
AstraSitesAdmin._importFailMessage( jqXHR.status + ' ' + jqXHR.statusText, 'Import Customizer Settings Failed!', jqXHR );
|
2592 |
console.groupEnd();
|
2593 |
})
|
2594 |
.done(function ( response ) {
|
2632 |
*
|
2633 |
* @param {string} data Error message.
|
2634 |
*/
|
2635 |
+
_importFailMessage: function( message, heading, jqXHR ) {
|
|
|
|
|
|
|
2636 |
|
2637 |
heading = heading || 'The import process interrupted';
|
2638 |
|
2639 |
+
var status_code = jqXHR.status ? parseInt( jqXHR.status ) : parseInt( jqXHR.status ) || '';
|
2640 |
+
|
2641 |
+
if( 200 == status_code && astraSitesVars.debug ) {
|
2642 |
+
var output = astraSitesVars.importFailedMessageDueToDebug;
|
2643 |
+
|
2644 |
+
} else {
|
2645 |
+
var output = astraSitesVars.importFailedMessage;
|
2646 |
+
|
2647 |
+
if( message ) {
|
2648 |
+
output += '<p class="current-importing-status">Error: ' + message +'</p>';
|
2649 |
+
}
|
2650 |
}
|
2651 |
|
2652 |
$('.astra-sites-import-content').html( output );
|
3009 |
})
|
3010 |
.fail(function( jqXHR ){
|
3011 |
AstraSitesAdmin._log( jqXHR );
|
3012 |
+
AstraSitesAdmin._importFailMessage( jqXHR.status + ' ' + jqXHR.statusText, '', jqXHR );
|
3013 |
console.groupEnd();
|
3014 |
})
|
3015 |
.done(function ( response ) {
|
3114 |
})
|
3115 |
.fail(function( jqXHR ){
|
3116 |
AstraSitesAdmin._log( jqXHR );
|
3117 |
+
AstraSitesAdmin._importFailMessage( jqXHR.status + ' ' + jqXHR.statusText, 'Page Import API Request Failed!', jqXHR );
|
3118 |
console.groupEnd();
|
3119 |
})
|
3120 |
.done(function ( response ) {
|
3225 |
|
3226 |
// Remove loader.
|
3227 |
$('.required-plugins').removeClass('loading').html('');
|
3228 |
+
AstraSitesAdmin._importFailMessage( jqXHR.status + jqXHR.statusText, 'Required Plugins Failed!', jqXHR );
|
3229 |
console.groupEnd();
|
3230 |
})
|
3231 |
.done(function ( response ) {
|
3247 |
|
3248 |
if( response.data['update_avilable_plugins'].length ) {
|
3249 |
compatibilities.warnings['update-available'] = astraSitesVars.compatibilities_data['update-available'];
|
3250 |
+
let list_html = '<ul>';
|
3251 |
+
for (let index = 0; index < response.data['update_avilable_plugins'].length; index++) {
|
3252 |
+
let element = response.data['update_avilable_plugins'][index];
|
3253 |
+
list_html += '<li>' + element.name + '</li>';
|
3254 |
+
}
|
3255 |
+
list_html += '</ul>';
|
3256 |
+
compatibilities.warnings['update-available']['tooltip'] = compatibilities.warnings['update-available']['tooltip'].replace( '##LIST##', list_html );
|
3257 |
} else {
|
3258 |
delete compatibilities.warnings['update-available'];
|
3259 |
}
|
3562 |
})
|
3563 |
.fail(function( jqXHR ){
|
3564 |
AstraSitesAdmin._log( jqXHR );
|
3565 |
+
AstraSitesAdmin._importFailMessage( jqXHR.status + jqXHR.statusText, 'Import WP Forms Failed!', jqXHR );
|
3566 |
console.groupEnd();
|
3567 |
})
|
3568 |
.done(function ( response ) {
|
inc/assets/js/elementor-admin-page.js
CHANGED
@@ -118,6 +118,10 @@ var AstraSitesAjaxQueue = (function() {
|
|
118 |
index : 0,
|
119 |
blockCategory : '',
|
120 |
blockColor : '',
|
|
|
|
|
|
|
|
|
121 |
|
122 |
init: function() {
|
123 |
this._bind();
|
@@ -183,10 +187,12 @@ var AstraSitesAjaxQueue = (function() {
|
|
183 |
$( document ).on( 'click', '#ast-sites-modal .astra-sites__sync-wrap', AstraElementorSitesAdmin._sync );
|
184 |
$( document ).on( 'click', '#ast-sites-modal .ast-sites-modal__header__logo, #ast-sites-modal .back-to-layout-button', AstraElementorSitesAdmin._home );
|
185 |
$( document ).on( 'click', '#ast-sites-modal .notice-dismiss', AstraElementorSitesAdmin._dismiss );
|
|
|
186 |
|
187 |
// Other events.
|
188 |
$elscope.find( '.astra-sites-content-wrap' ).scroll( AstraElementorSitesAdmin._loadLargeImages );
|
189 |
$( document ).on( 'keyup input' , '#ast-sites-modal #wp-filter-search-input', AstraElementorSitesAdmin._search );
|
|
|
190 |
|
191 |
// Triggers.
|
192 |
$( document ).on( "astra-sites__elementor-open-after", AstraElementorSitesAdmin._initSites );
|
@@ -211,6 +217,23 @@ var AstraSitesAjaxQueue = (function() {
|
|
211 |
|
212 |
},
|
213 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
214 |
_categoryChange: function( event ) {
|
215 |
AstraElementorSitesAdmin.blockCategory = $( this ).val();
|
216 |
$elscope.find( '#wp-filter-search-input' ).trigger( 'keyup' );
|
@@ -245,7 +268,7 @@ var AstraSitesAjaxQueue = (function() {
|
|
245 |
|
246 |
console.groupEnd( 'Process Done.' );
|
247 |
|
248 |
-
var str = ( AstraElementorSitesAdmin.type == 'pages' ) ?
|
249 |
$elscope.find( '.ast-import-elementor-template' ).removeClass( 'installing' );
|
250 |
$elscope.find( '.ast-import-elementor-template' ).attr( 'data-demo-link', data.data.link );
|
251 |
setTimeout( function() {
|
@@ -295,7 +318,7 @@ var AstraSitesAjaxQueue = (function() {
|
|
295 |
}
|
296 |
|
297 |
button.addClass( 'updating-message');
|
298 |
-
$elscope.find( '#ast-sites-floating-notice-wrap-id .ast-sites-floating-notice' ).html( '<span class="message">Syncing template library in the background. The process can take anywhere between 2 to 3 minutes. We will notify you once done.<span><button type="button" class="notice-dismiss"><span class="screen-reader-text
|
299 |
$elscope.find( '#ast-sites-floating-notice-wrap-id' ).addClass( 'slide-in' ).removeClass( 'refreshed-notice' );
|
300 |
|
301 |
$.ajax({
|
@@ -312,7 +335,7 @@ var AstraSitesAjaxQueue = (function() {
|
|
312 |
|
313 |
if( response.success ) {
|
314 |
if( 'updated' === response.data ) {
|
315 |
-
$elscope.find( '#ast-sites-floating-notice-wrap-id').addClass('refreshed-notice').find('.ast-sites-floating-notice' ).html( '<span class="message">'+astraElementorSites.syncCompleteMessage+'</span><button type="button" class="notice-dismiss"><span class="screen-reader-text
|
316 |
button.removeClass( 'updating-message');
|
317 |
console.log( 'Already sync all the sites.' );
|
318 |
} else {
|
@@ -341,16 +364,53 @@ var AstraSitesAjaxQueue = (function() {
|
|
341 |
console.log( jqXHR );
|
342 |
});
|
343 |
|
|
|
344 |
// Import Blocks.
|
345 |
$.ajax({
|
346 |
url : astraElementorSites.ajaxurl,
|
347 |
type : 'POST',
|
348 |
data : {
|
349 |
-
action : 'astra-sites-
|
|
|
|
|
|
|
|
|
350 |
},
|
351 |
})
|
352 |
.fail(function( jqXHR ){
|
353 |
-
console.log( jqXHR );
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
354 |
});
|
355 |
|
356 |
// Import Block Categories.
|
@@ -391,7 +451,7 @@ var AstraSitesAjaxQueue = (function() {
|
|
391 |
|
392 |
if( i === total && astraElementorSites.syncCompleteMessage ) {
|
393 |
button.removeClass( 'updating-message');
|
394 |
-
$elscope.find( '#ast-sites-floating-notice-wrap-id').addClass('refreshed-notice').find('.ast-sites-floating-notice' ).html( '<span class="message">'+astraElementorSites.syncCompleteMessage+'</span><button type="button" class="notice-dismiss"><span class="screen-reader-text
|
395 |
}
|
396 |
}
|
397 |
});
|
@@ -427,7 +487,7 @@ var AstraSitesAjaxQueue = (function() {
|
|
427 |
$elscope.find( '.theme-preview' ).html( '' );
|
428 |
$elscope.find( '.theme-preview-block' ).hide();
|
429 |
$elscope.find( '.theme-preview-block' ).html( '' );
|
430 |
-
$elscope.find( '.
|
431 |
|
432 |
$elscope.find( '.dialog-lightbox-content' ).hide();
|
433 |
$elscope.find( '.dialog-lightbox-content-block' ).hide();
|
@@ -440,6 +500,9 @@ var AstraSitesAjaxQueue = (function() {
|
|
440 |
},
|
441 |
|
442 |
_home: function() {
|
|
|
|
|
|
|
443 |
$elscope.find( '#wp-filter-search-input' ).val( '' );
|
444 |
// Hide Back button.
|
445 |
$elscope.find( '.back-to-layout' ).css( 'visibility', 'hidden' );
|
@@ -451,16 +514,22 @@ var AstraSitesAjaxQueue = (function() {
|
|
451 |
if ( 'pages' == type ) {
|
452 |
AstraElementorSitesAdmin._initSites();
|
453 |
$elscope.find( '.dialog-lightbox-content' ).show();
|
|
|
|
|
|
|
454 |
} else {
|
455 |
AstraElementorSitesAdmin._initBlocks();
|
456 |
$elscope.find( '.dialog-lightbox-content-block' ).show();
|
|
|
|
|
|
|
457 |
}
|
458 |
$elscope.find( '.astra-sites-content-wrap' ).trigger( 'scroll' );
|
459 |
},
|
460 |
|
461 |
_importWPForm: function( wpforms_url, callback ) {
|
462 |
|
463 |
-
if ( '' == wpforms_url ) {
|
464 |
if( callback && typeof callback == "function"){
|
465 |
callback( '' );
|
466 |
}
|
@@ -609,10 +678,6 @@ var AstraSitesAjaxQueue = (function() {
|
|
609 |
|
610 |
_bulkPluginInstallActivate: function() {
|
611 |
|
612 |
-
if( 0 === AstraElementorSitesAdmin.requiredPlugins.length ) {
|
613 |
-
return;
|
614 |
-
}
|
615 |
-
|
616 |
console.groupCollapsed( 'Bulk Plugin Install Process Started' );
|
617 |
|
618 |
// If has class the skip-plugins then,
|
@@ -648,7 +713,7 @@ var AstraSitesAjaxQueue = (function() {
|
|
648 |
|
649 |
AstraElementorSitesAdmin.canImport = false;
|
650 |
|
651 |
-
var str = ( AstraElementorSitesAdmin.type == 'pages' ) ?
|
652 |
|
653 |
$( this ).addClass( 'installing' );
|
654 |
$( this ).text( 'Saving ' + str + '...' );
|
@@ -872,6 +937,16 @@ var AstraSitesAjaxQueue = (function() {
|
|
872 |
AstraElementorSitesAdmin._masonry();
|
873 |
},
|
874 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
875 |
_masonry: function() {
|
876 |
|
877 |
//create empty var masonryObj
|
@@ -911,7 +986,9 @@ var AstraSitesAjaxQueue = (function() {
|
|
911 |
|
912 |
} else {
|
913 |
|
914 |
-
AstraElementorSitesAdmin.
|
|
|
|
|
915 |
AstraElementorSitesAdmin.insertData = AstraElementorSitesAdmin.templateData;
|
916 |
if ( 'insert' == AstraElementorSitesAdmin.action ) {
|
917 |
AstraElementorSitesAdmin._insertDemo( AstraElementorSitesAdmin.templateData );
|
@@ -924,6 +1001,118 @@ var AstraSitesAjaxQueue = (function() {
|
|
924 |
}
|
925 |
},
|
926 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
927 |
_insert: function( e ) {
|
928 |
|
929 |
if ( ! AstraElementorSitesAdmin.canInsert ) {
|
@@ -931,7 +1120,7 @@ var AstraSitesAjaxQueue = (function() {
|
|
931 |
}
|
932 |
|
933 |
AstraElementorSitesAdmin.canInsert = false;
|
934 |
-
var str = ( AstraElementorSitesAdmin.type == 'pages' ) ?
|
935 |
|
936 |
$( this ).addClass( 'installing' );
|
937 |
$( this ).text( 'Importing ' + str + '...' );
|
@@ -979,18 +1168,24 @@ var AstraSitesAjaxQueue = (function() {
|
|
979 |
})
|
980 |
.done(function ( response ) {
|
981 |
|
|
|
|
|
|
|
982 |
page_content = response.data;
|
983 |
|
984 |
console.log( page_content );
|
985 |
console.groupEnd();
|
986 |
|
987 |
if ( undefined !== page_content && '' !== page_content ) {
|
988 |
-
elementor.channels.data.trigger('template:before:insert', templateModel);
|
989 |
-
elementor.getPreviewView().addChildModel( page_content, { at : AstraElementorSitesAdmin.index } || {} );
|
990 |
-
elementor.channels.data.trigger('template:after:insert', {});
|
991 |
if ( undefined != $e && 'undefined' != typeof $e.internal ) {
|
|
|
|
|
|
|
992 |
$e.internal( 'document/save/set-is-modified', { status: true } )
|
993 |
} else {
|
|
|
|
|
|
|
994 |
elementor.saver.setFlagEditorChange(true);
|
995 |
}
|
996 |
}
|
@@ -1002,11 +1197,18 @@ var AstraSitesAjaxQueue = (function() {
|
|
1002 |
|
1003 |
_goBack: function( e ) {
|
1004 |
|
|
|
|
|
|
|
|
|
1005 |
let step = $( this ).attr( 'data-step' );
|
1006 |
|
1007 |
$elscope.find( '.astra-sites-step-1-wrap' ).show();
|
1008 |
$elscope.find( '.astra-preview-actions-wrap' ).remove();
|
1009 |
|
|
|
|
|
|
|
1010 |
if ( 'pages' == AstraElementorSitesAdmin.type ) {
|
1011 |
|
1012 |
if ( 3 == step ) {
|
@@ -1045,7 +1247,7 @@ var AstraSitesAjaxQueue = (function() {
|
|
1045 |
$elscope.find( '.theme-preview' ).html( '' );
|
1046 |
$elscope.find( '.theme-preview-block' ).hide();
|
1047 |
$elscope.find( '.theme-preview-block' ).html( '' );
|
1048 |
-
$elscope.find( '.
|
1049 |
|
1050 |
// Show listing page.
|
1051 |
if( AstraElementorSitesAdmin.type == 'pages' ) {
|
@@ -1089,7 +1291,7 @@ var AstraSitesAjaxQueue = (function() {
|
|
1089 |
// Hide Preview page.
|
1090 |
$elscope.find( '.theme-preview' ).hide();
|
1091 |
$elscope.find( '.theme-preview' ).html( '' );
|
1092 |
-
$elscope.find( '.
|
1093 |
$elscope.find( '.theme-preview-block' ).hide();
|
1094 |
$elscope.find( '.theme-preview-block' ).html( '' );
|
1095 |
|
@@ -1149,7 +1351,7 @@ var AstraSitesAjaxQueue = (function() {
|
|
1149 |
$elscope.find( '.astra-preview-actions-wrap' ).remove();
|
1150 |
$elscope.find( '.theme-preview' ).hide();
|
1151 |
$elscope.find( '.theme-preview' ).html( '' );
|
1152 |
-
$elscope.find( '.
|
1153 |
$elscope.find( '.theme-preview-block' ).hide();
|
1154 |
$elscope.find( '.theme-preview-block' ).html( '' );
|
1155 |
$elscope.find( '.dialog-lightbox-content' ).show();
|
@@ -1163,7 +1365,8 @@ var AstraSitesAjaxQueue = (function() {
|
|
1163 |
$elscope.find( '.dialog-lightbox-content-block' ).hide();
|
1164 |
$elscope.find( '.dialog-lightbox-message' ).animate({ scrollTop: 0 }, 50 );
|
1165 |
$elscope.find( '.theme-preview-block' ).show();
|
1166 |
-
$elscope.find( '.
|
|
|
1167 |
|
1168 |
// Hide.
|
1169 |
$elscope.find( '.theme-preview' ).hide();
|
@@ -1181,7 +1384,7 @@ var AstraSitesAjaxQueue = (function() {
|
|
1181 |
$elscope.find( '.astra-sites-step-1-wrap' ).hide();
|
1182 |
|
1183 |
preview_action_html = import_template_header( template_object );
|
1184 |
-
$elscope.find( '.elementor-templates-modal__header__items-area' ).
|
1185 |
AstraElementorSitesAdmin._masonry();
|
1186 |
|
1187 |
let actual_id = AstraElementorSitesAdmin.block_id.replace( 'id-', '' );
|
@@ -1195,6 +1398,8 @@ var AstraSitesAjaxQueue = (function() {
|
|
1195 |
$elscope.find( '.dialog-lightbox-message' ).animate({ scrollTop: 0 }, 50 );
|
1196 |
$elscope.find( '.theme-preview' ).show();
|
1197 |
|
|
|
|
|
1198 |
if ( undefined === AstraElementorSitesAdmin.site_id ) {
|
1199 |
return;
|
1200 |
}
|
@@ -1215,7 +1420,7 @@ var AstraSitesAjaxQueue = (function() {
|
|
1215 |
$elscope.find( '.astra-sites-step-1-wrap' ).hide();
|
1216 |
|
1217 |
preview_action_html = import_template_header( template_object );
|
1218 |
-
$elscope.find( '.elementor-templates-modal__header__items-area' ).
|
1219 |
|
1220 |
let actual_id = AstraElementorSitesAdmin.page_id.replace( 'id-', '' );
|
1221 |
$( document ).trigger( 'astra-sites__elementor-plugin-check', { 'id': actual_id } );
|
@@ -1223,6 +1428,10 @@ var AstraSitesAjaxQueue = (function() {
|
|
1223 |
|
1224 |
_preview : function( e ) {
|
1225 |
|
|
|
|
|
|
|
|
|
1226 |
let step = $( this ).attr( 'data-step' );
|
1227 |
|
1228 |
AstraElementorSitesAdmin.site_id = $( this ).closest( '.astra-theme' ).data( 'site-id' );
|
@@ -1232,6 +1441,9 @@ var AstraSitesAjaxQueue = (function() {
|
|
1232 |
$elscope.find( '.back-to-layout' ).css( 'visibility', 'visible' );
|
1233 |
$elscope.find( '.back-to-layout' ).css( 'opacity', '1' );
|
1234 |
|
|
|
|
|
|
|
1235 |
if ( 1 == step ) {
|
1236 |
|
1237 |
$elscope.find( '.back-to-layout' ).attr( 'data-step', 2 );
|
@@ -1286,7 +1498,7 @@ var AstraSitesAjaxQueue = (function() {
|
|
1286 |
}
|
1287 |
} else {
|
1288 |
if ( undefined !== AstraElementorSitesAdmin.templateData['post-meta']['astra-blocks-required-plugins'] ) {
|
1289 |
-
AstraElementorSitesAdmin._requiredPluginsMarkup( AstraElementorSitesAdmin.templateData['post-meta']['astra-blocks-required-plugins'] );
|
1290 |
}
|
1291 |
}
|
1292 |
}
|
@@ -1410,7 +1622,7 @@ var AstraSitesAjaxQueue = (function() {
|
|
1410 |
}
|
1411 |
|
1412 |
if ( '' != output ) {
|
1413 |
-
output = '<li class="plugin-card-head"><strong
|
1414 |
$elscope.find('.required-plugins-list').html( output );
|
1415 |
$elscope.find('.ast-tooltip-wrap').css( 'opacity', 1 );
|
1416 |
$elscope.find('.astra-sites-tooltip').css( 'opacity', 1 );
|
118 |
index : 0,
|
119 |
blockCategory : '',
|
120 |
blockColor : '',
|
121 |
+
processing: false,
|
122 |
+
siteType: '',
|
123 |
+
page: 1,
|
124 |
+
per_page: 20,
|
125 |
|
126 |
init: function() {
|
127 |
this._bind();
|
187 |
$( document ).on( 'click', '#ast-sites-modal .astra-sites__sync-wrap', AstraElementorSitesAdmin._sync );
|
188 |
$( document ).on( 'click', '#ast-sites-modal .ast-sites-modal__header__logo, #ast-sites-modal .back-to-layout-button', AstraElementorSitesAdmin._home );
|
189 |
$( document ).on( 'click', '#ast-sites-modal .notice-dismiss', AstraElementorSitesAdmin._dismiss );
|
190 |
+
$( document ).on( 'click', '#ast-sites-modal .elementor-template-library-template-insert.ast-block-insert', AstraElementorSitesAdmin._insert_from_link );
|
191 |
|
192 |
// Other events.
|
193 |
$elscope.find( '.astra-sites-content-wrap' ).scroll( AstraElementorSitesAdmin._loadLargeImages );
|
194 |
$( document ).on( 'keyup input' , '#ast-sites-modal #wp-filter-search-input', AstraElementorSitesAdmin._search );
|
195 |
+
$( document ).on( 'change', '#ast-sites-modal .elementor-template-library-order-input', AstraElementorSitesAdmin._changeType );
|
196 |
|
197 |
// Triggers.
|
198 |
$( document ).on( "astra-sites__elementor-open-after", AstraElementorSitesAdmin._initSites );
|
217 |
|
218 |
},
|
219 |
|
220 |
+
_paginateBlocks: function() {
|
221 |
+
if ( AstraElementorSitesAdmin.type == 'blocks' ) {
|
222 |
+
if ( undefined != $elscope.find( '.astra-sites-library-template:last' ).offset() ) {
|
223 |
+
if( ( $( '.dialog-widget-content' ).scrollTop() + 600 ) >= ( $elscope.find( '.astra-sites-library-template:last' ).offset().top ) ) {
|
224 |
+
AstraElementorSitesAdmin.page = ( AstraElementorSitesAdmin.page + 1 );
|
225 |
+
// Set listing HTML.
|
226 |
+
AstraElementorSitesAdmin._appendPaginationBlocks( astraElementorSites.astra_blocks );
|
227 |
+
}
|
228 |
+
}
|
229 |
+
}
|
230 |
+
},
|
231 |
+
|
232 |
+
_changeType: function() {
|
233 |
+
AstraElementorSitesAdmin.siteType = $( this ).val();
|
234 |
+
$elscope.find( '#wp-filter-search-input' ).trigger( 'keyup' );
|
235 |
+
},
|
236 |
+
|
237 |
_categoryChange: function( event ) {
|
238 |
AstraElementorSitesAdmin.blockCategory = $( this ).val();
|
239 |
$elscope.find( '#wp-filter-search-input' ).trigger( 'keyup' );
|
268 |
|
269 |
console.groupEnd( 'Process Done.' );
|
270 |
|
271 |
+
var str = ( AstraElementorSitesAdmin.type == 'pages' ) ? astraElementorSites.template : astraElementorSites.block;
|
272 |
$elscope.find( '.ast-import-elementor-template' ).removeClass( 'installing' );
|
273 |
$elscope.find( '.ast-import-elementor-template' ).attr( 'data-demo-link', data.data.link );
|
274 |
setTimeout( function() {
|
318 |
}
|
319 |
|
320 |
button.addClass( 'updating-message');
|
321 |
+
$elscope.find( '#ast-sites-floating-notice-wrap-id .ast-sites-floating-notice' ).html( '<span class="message">Syncing template library in the background. The process can take anywhere between 2 to 3 minutes. We will notify you once done.<span><button type="button" class="notice-dismiss"><span class="screen-reader-text">' + astraElementorSites.dismiss_text + '</span></button>' );
|
322 |
$elscope.find( '#ast-sites-floating-notice-wrap-id' ).addClass( 'slide-in' ).removeClass( 'refreshed-notice' );
|
323 |
|
324 |
$.ajax({
|
335 |
|
336 |
if( response.success ) {
|
337 |
if( 'updated' === response.data ) {
|
338 |
+
$elscope.find( '#ast-sites-floating-notice-wrap-id').addClass('refreshed-notice').find('.ast-sites-floating-notice' ).html( '<span class="message">'+astraElementorSites.syncCompleteMessage+'</span><button type="button" class="notice-dismiss"><span class="screen-reader-text">' + astraElementorSites.dismiss_text + '</span></button>' );
|
339 |
button.removeClass( 'updating-message');
|
340 |
console.log( 'Already sync all the sites.' );
|
341 |
} else {
|
364 |
console.log( jqXHR );
|
365 |
});
|
366 |
|
367 |
+
|
368 |
// Import Blocks.
|
369 |
$.ajax({
|
370 |
url : astraElementorSites.ajaxurl,
|
371 |
type : 'POST',
|
372 |
data : {
|
373 |
+
action : 'astra-sites-get-blocks-request-count',
|
374 |
+
},
|
375 |
+
beforeSend: function() {
|
376 |
+
console.groupCollapsed( 'Updating Blocks' );
|
377 |
+
console.log( 'Updating Blocks' );
|
378 |
},
|
379 |
})
|
380 |
.fail(function( jqXHR ){
|
381 |
+
console.log( jqXHR, 'error' );
|
382 |
+
console.error( jqXHR.status + jqXHR.statusText, 'Blocks Count Request Failed!', jqXHR );
|
383 |
+
console.groupEnd('Updating Blocks');
|
384 |
+
})
|
385 |
+
.done(function ( response ) {
|
386 |
+
console.log( response );
|
387 |
+
if( response.success ) {
|
388 |
+
var total = response.data.pages;
|
389 |
+
|
390 |
+
for( let i = 1; i <= total; i++ ) {
|
391 |
+
AstraSitesAjaxQueue.add({
|
392 |
+
url: astraElementorSites.ajaxurl,
|
393 |
+
type: 'POST',
|
394 |
+
data: {
|
395 |
+
action : 'astra-sites-import-blocks',
|
396 |
+
page_no : i,
|
397 |
+
},
|
398 |
+
beforeSend: function() {
|
399 |
+
console.groupCollapsed( 'Importing Blocks - Page ' + i );
|
400 |
+
console.log( 'Importing Blocks - Page ' + i );
|
401 |
+
},
|
402 |
+
success: function( response ){
|
403 |
+
console.log( response );
|
404 |
+
console.groupEnd( 'Importing Blocks - Page ' + i );
|
405 |
+
}
|
406 |
+
});
|
407 |
+
}
|
408 |
+
|
409 |
+
// Run the AJAX queue.
|
410 |
+
AstraSitesAjaxQueue.run();
|
411 |
+
} else {
|
412 |
+
console.error( response.data, 'Blocks Count Request Failed!' );
|
413 |
+
}
|
414 |
});
|
415 |
|
416 |
// Import Block Categories.
|
451 |
|
452 |
if( i === total && astraElementorSites.syncCompleteMessage ) {
|
453 |
button.removeClass( 'updating-message');
|
454 |
+
$elscope.find( '#ast-sites-floating-notice-wrap-id').addClass('refreshed-notice').find('.ast-sites-floating-notice' ).html( '<span class="message">'+astraElementorSites.syncCompleteMessage+'</span><button type="button" class="notice-dismiss"><span class="screen-reader-text">' + astraElementorSites.dismiss_text + '</span></button>' );
|
455 |
}
|
456 |
}
|
457 |
});
|
487 |
$elscope.find( '.theme-preview' ).html( '' );
|
488 |
$elscope.find( '.theme-preview-block' ).hide();
|
489 |
$elscope.find( '.theme-preview-block' ).html( '' );
|
490 |
+
$elscope.find( '.ast-template-library-toolbar' ).show();
|
491 |
|
492 |
$elscope.find( '.dialog-lightbox-content' ).hide();
|
493 |
$elscope.find( '.dialog-lightbox-content-block' ).hide();
|
500 |
},
|
501 |
|
502 |
_home: function() {
|
503 |
+
if ( AstraElementorSitesAdmin.processing ) {
|
504 |
+
return;
|
505 |
+
}
|
506 |
$elscope.find( '#wp-filter-search-input' ).val( '' );
|
507 |
// Hide Back button.
|
508 |
$elscope.find( '.back-to-layout' ).css( 'visibility', 'hidden' );
|
514 |
if ( 'pages' == type ) {
|
515 |
AstraElementorSitesAdmin._initSites();
|
516 |
$elscope.find( '.dialog-lightbox-content' ).show();
|
517 |
+
$elscope.find( '.astra-blocks-category-inner-wrap' ).hide();
|
518 |
+
$elscope.find( '.astra-blocks-filter-inner-wrap' ).hide();
|
519 |
+
$elscope.find( '.elementor-template-library-order' ).show();
|
520 |
} else {
|
521 |
AstraElementorSitesAdmin._initBlocks();
|
522 |
$elscope.find( '.dialog-lightbox-content-block' ).show();
|
523 |
+
$elscope.find( '.astra-blocks-category-inner-wrap' ).show();
|
524 |
+
$elscope.find( '.astra-blocks-filter-inner-wrap' ).show();
|
525 |
+
$elscope.find( '.elementor-template-library-order' ).hide();
|
526 |
}
|
527 |
$elscope.find( '.astra-sites-content-wrap' ).trigger( 'scroll' );
|
528 |
},
|
529 |
|
530 |
_importWPForm: function( wpforms_url, callback ) {
|
531 |
|
532 |
+
if ( '' == wpforms_url || 0 == wpforms_url ) {
|
533 |
if( callback && typeof callback == "function"){
|
534 |
callback( '' );
|
535 |
}
|
678 |
|
679 |
_bulkPluginInstallActivate: function() {
|
680 |
|
|
|
|
|
|
|
|
|
681 |
console.groupCollapsed( 'Bulk Plugin Install Process Started' );
|
682 |
|
683 |
// If has class the skip-plugins then,
|
713 |
|
714 |
AstraElementorSitesAdmin.canImport = false;
|
715 |
|
716 |
+
var str = ( AstraElementorSitesAdmin.type == 'pages' ) ? astraElementorSites.template : astraElementorSites.block;
|
717 |
|
718 |
$( this ).addClass( 'installing' );
|
719 |
$( this ).text( 'Saving ' + str + '...' );
|
937 |
AstraElementorSitesAdmin._masonry();
|
938 |
},
|
939 |
|
940 |
+
_appendPaginationBlocks: function( data ) {
|
941 |
+
|
942 |
+
let single_template = wp.template( 'astra-blocks-list' );
|
943 |
+
let blocks_list = single_template( data );
|
944 |
+
$elscope.find( '.dialog-lightbox-message' ).hide();
|
945 |
+
$elscope.find( '.dialog-lightbox-message-block' ).show();
|
946 |
+
$elscope.find( '.dialog-lightbox-content-block' ).append( blocks_list );
|
947 |
+
AstraElementorSitesAdmin._masonry();
|
948 |
+
},
|
949 |
+
|
950 |
_masonry: function() {
|
951 |
|
952 |
//create empty var masonryObj
|
986 |
|
987 |
} else {
|
988 |
|
989 |
+
let url = ( undefined != AstraElementorSitesAdmin.templateData['post-meta'] ) ? AstraElementorSitesAdmin.templateData['post-meta']['astra-blocks-wpform'] : '';
|
990 |
+
|
991 |
+
AstraElementorSitesAdmin._importWPForm( url, function( form_response ) {
|
992 |
AstraElementorSitesAdmin.insertData = AstraElementorSitesAdmin.templateData;
|
993 |
if ( 'insert' == AstraElementorSitesAdmin.action ) {
|
994 |
AstraElementorSitesAdmin._insertDemo( AstraElementorSitesAdmin.templateData );
|
1001 |
}
|
1002 |
},
|
1003 |
|
1004 |
+
_insert_from_link: function( e ) {
|
1005 |
+
|
1006 |
+
if ( AstraElementorSitesAdmin.processing ) {
|
1007 |
+
return;
|
1008 |
+
}
|
1009 |
+
|
1010 |
+
AstraElementorSitesAdmin.processing = true;
|
1011 |
+
|
1012 |
+
$elscope.find( '.astra-sites-content-wrap' ).addClass( 'processing' );
|
1013 |
+
|
1014 |
+
console.groupCollapsed( 'Inserting Demo.' );
|
1015 |
+
|
1016 |
+
$( this ).find( '.elementor-button-title' ).text( 'Processing..' );
|
1017 |
+
|
1018 |
+
AstraElementorSitesAdmin.page_id = $( this ).closest( '.astra-theme' ).data( 'template-id' );
|
1019 |
+
AstraElementorSitesAdmin.block_id = $( this ).closest( '.astra-theme' ).data( 'block-id' );
|
1020 |
+
|
1021 |
+
let actual_id = 0;
|
1022 |
+
AstraElementorSitesAdmin.canInsert = true;
|
1023 |
+
|
1024 |
+
if ( AstraElementorSitesAdmin.type == 'pages' ) {
|
1025 |
+
actual_id = AstraElementorSitesAdmin.page_id.replace( 'id-', '' );
|
1026 |
+
} else {
|
1027 |
+
actual_id = AstraElementorSitesAdmin.block_id.replace( 'id-', '' );
|
1028 |
+
}
|
1029 |
+
|
1030 |
+
if ( 0 != actual_id ) {
|
1031 |
+
|
1032 |
+
console.log( 'Checking Required Plugin status.' );
|
1033 |
+
|
1034 |
+
var api_post = {
|
1035 |
+
slug: 'site-pages' + '/' + actual_id
|
1036 |
+
};
|
1037 |
+
|
1038 |
+
if ( 'blocks' == AstraElementorSitesAdmin.type ) {
|
1039 |
+
api_post = {
|
1040 |
+
slug: 'astra-blocks' + '/' + actual_id
|
1041 |
+
};
|
1042 |
+
}
|
1043 |
+
|
1044 |
+
var params = {
|
1045 |
+
method: 'GET',
|
1046 |
+
cache: 'default',
|
1047 |
+
};
|
1048 |
+
|
1049 |
+
fetch( astraElementorSites.ApiURL + api_post.slug, params ).then( response => {
|
1050 |
+
if ( response.status === 200 ) {
|
1051 |
+
return response.json().then(items => ({
|
1052 |
+
items : items,
|
1053 |
+
items_count : response.headers.get( 'x-wp-total' ),
|
1054 |
+
item_pages : response.headers.get( 'x-wp-totalpages' ),
|
1055 |
+
}))
|
1056 |
+
} else {
|
1057 |
+
return response.json();
|
1058 |
+
}
|
1059 |
+
})
|
1060 |
+
.then(data => {
|
1061 |
+
if( 'object' === typeof data ) {
|
1062 |
+
if ( undefined !== data && undefined !== data['items'] ) {
|
1063 |
+
AstraElementorSitesAdmin.templateData = data['items'];
|
1064 |
+
let requiredPlugins = [];
|
1065 |
+
if ( AstraElementorSitesAdmin.type == 'pages' ) {
|
1066 |
+
|
1067 |
+
if ( undefined !== AstraElementorSitesAdmin.templateData['site-pages-required-plugins'] ) {
|
1068 |
+
requiredPlugins = AstraElementorSitesAdmin.templateData['site-pages-required-plugins'];
|
1069 |
+
}
|
1070 |
+
} else {
|
1071 |
+
if ( undefined !== AstraElementorSitesAdmin.templateData['post-meta']['astra-blocks-required-plugins'] ) {
|
1072 |
+
requiredPlugins = AstraElementorSitesAdmin.templateData['post-meta']['astra-blocks-required-plugins'];
|
1073 |
+
}
|
1074 |
+
}
|
1075 |
+
if ( undefined != requiredPlugins && null != requiredPlugins && requiredPlugins.length > 0 ) {
|
1076 |
+
|
1077 |
+
$.ajax({
|
1078 |
+
url : astraElementorSites.ajaxurl,
|
1079 |
+
type : 'POST',
|
1080 |
+
data : {
|
1081 |
+
action : 'astra-required-plugins',
|
1082 |
+
_ajax_nonce : astraElementorSites._ajax_nonce,
|
1083 |
+
required_plugins : requiredPlugins
|
1084 |
+
},
|
1085 |
+
})
|
1086 |
+
.fail(function( jqXHR ){
|
1087 |
+
console.log( jqXHR );
|
1088 |
+
console.groupEnd();
|
1089 |
+
})
|
1090 |
+
.done(function ( response ) {
|
1091 |
+
AstraElementorSitesAdmin.requiredPlugins = response.data['required_plugins'];
|
1092 |
+
AstraElementorSitesAdmin.canImport = true;
|
1093 |
+
AstraElementorSitesAdmin.canInsert = true;
|
1094 |
+
});
|
1095 |
+
}
|
1096 |
+
}
|
1097 |
+
}
|
1098 |
+
|
1099 |
+
console.log( 'Insert Process for Demo "' + actual_id + '" has started.' );
|
1100 |
+
|
1101 |
+
AstraElementorSitesAdmin.canInsert = false;
|
1102 |
+
AstraElementorSitesAdmin.action = 'insert';
|
1103 |
+
AstraElementorSitesAdmin._bulkPluginInstallActivate();
|
1104 |
+
});
|
1105 |
+
|
1106 |
+
} else {
|
1107 |
+
AstraElementorSitesAdmin.canInsert = true;
|
1108 |
+
AstraElementorSitesAdmin.processing = false;
|
1109 |
+
$elscope.find( '.astra-sites-content-wrap' ).removeClass( 'processing' );
|
1110 |
+
console.log( 'Import Failed. Error: Incorrect Import ID' );
|
1111 |
+
$( this ).find( '.elementor-button-title' ).text( 'Insert' );
|
1112 |
+
}
|
1113 |
+
|
1114 |
+
},
|
1115 |
+
|
1116 |
_insert: function( e ) {
|
1117 |
|
1118 |
if ( ! AstraElementorSitesAdmin.canInsert ) {
|
1120 |
}
|
1121 |
|
1122 |
AstraElementorSitesAdmin.canInsert = false;
|
1123 |
+
var str = ( AstraElementorSitesAdmin.type == 'pages' ) ? astraElementorSites.template : astraElementorSites.block;
|
1124 |
|
1125 |
$( this ).addClass( 'installing' );
|
1126 |
$( this ).text( 'Importing ' + str + '...' );
|
1168 |
})
|
1169 |
.done(function ( response ) {
|
1170 |
|
1171 |
+
AstraElementorSitesAdmin.processing = false;
|
1172 |
+
$elscope.find( '.astra-sites-content-wrap' ).removeClass( 'processing' );
|
1173 |
+
|
1174 |
page_content = response.data;
|
1175 |
|
1176 |
console.log( page_content );
|
1177 |
console.groupEnd();
|
1178 |
|
1179 |
if ( undefined !== page_content && '' !== page_content ) {
|
|
|
|
|
|
|
1180 |
if ( undefined != $e && 'undefined' != typeof $e.internal ) {
|
1181 |
+
elementor.channels.data.trigger('template:before:insert', templateModel);
|
1182 |
+
elementor.getPreviewView().addChildModel( page_content, { at : AstraElementorSitesAdmin.index } || {} );
|
1183 |
+
elementor.channels.data.trigger('template:after:insert', {});
|
1184 |
$e.internal( 'document/save/set-is-modified', { status: true } )
|
1185 |
} else {
|
1186 |
+
elementor.channels.data.trigger('template:before:insert', templateModel);
|
1187 |
+
elementor.getPreviewView().addChildModel( page_content, { at : AstraElementorSitesAdmin.index } || {} );
|
1188 |
+
elementor.channels.data.trigger('template:after:insert', {});
|
1189 |
elementor.saver.setFlagEditorChange(true);
|
1190 |
}
|
1191 |
}
|
1197 |
|
1198 |
_goBack: function( e ) {
|
1199 |
|
1200 |
+
if ( AstraElementorSitesAdmin.processing ) {
|
1201 |
+
return;
|
1202 |
+
}
|
1203 |
+
|
1204 |
let step = $( this ).attr( 'data-step' );
|
1205 |
|
1206 |
$elscope.find( '.astra-sites-step-1-wrap' ).show();
|
1207 |
$elscope.find( '.astra-preview-actions-wrap' ).remove();
|
1208 |
|
1209 |
+
$elscope.find( '.ast-template-library-toolbar' ).show();
|
1210 |
+
$elscope.find( '.ast-sites-modal__header' ).removeClass( 'ast-preview-mode' );
|
1211 |
+
|
1212 |
if ( 'pages' == AstraElementorSitesAdmin.type ) {
|
1213 |
|
1214 |
if ( 3 == step ) {
|
1247 |
$elscope.find( '.theme-preview' ).html( '' );
|
1248 |
$elscope.find( '.theme-preview-block' ).hide();
|
1249 |
$elscope.find( '.theme-preview-block' ).html( '' );
|
1250 |
+
$elscope.find( '.ast-template-library-toolbar' ).show();
|
1251 |
|
1252 |
// Show listing page.
|
1253 |
if( AstraElementorSitesAdmin.type == 'pages' ) {
|
1291 |
// Hide Preview page.
|
1292 |
$elscope.find( '.theme-preview' ).hide();
|
1293 |
$elscope.find( '.theme-preview' ).html( '' );
|
1294 |
+
$elscope.find( '.ast-template-library-toolbar' ).show();
|
1295 |
$elscope.find( '.theme-preview-block' ).hide();
|
1296 |
$elscope.find( '.theme-preview-block' ).html( '' );
|
1297 |
|
1351 |
$elscope.find( '.astra-preview-actions-wrap' ).remove();
|
1352 |
$elscope.find( '.theme-preview' ).hide();
|
1353 |
$elscope.find( '.theme-preview' ).html( '' );
|
1354 |
+
$elscope.find( '.ast-template-library-toolbar' ).show();
|
1355 |
$elscope.find( '.theme-preview-block' ).hide();
|
1356 |
$elscope.find( '.theme-preview-block' ).html( '' );
|
1357 |
$elscope.find( '.dialog-lightbox-content' ).show();
|
1365 |
$elscope.find( '.dialog-lightbox-content-block' ).hide();
|
1366 |
$elscope.find( '.dialog-lightbox-message' ).animate({ scrollTop: 0 }, 50 );
|
1367 |
$elscope.find( '.theme-preview-block' ).show();
|
1368 |
+
$elscope.find( '.ast-template-library-toolbar' ).hide();
|
1369 |
+
$elscope.find( '.ast-sites-modal__header' ).addClass( 'ast-preview-mode' );
|
1370 |
|
1371 |
// Hide.
|
1372 |
$elscope.find( '.theme-preview' ).hide();
|
1384 |
$elscope.find( '.astra-sites-step-1-wrap' ).hide();
|
1385 |
|
1386 |
preview_action_html = import_template_header( template_object );
|
1387 |
+
$elscope.find( '.elementor-templates-modal__header__items-area' ).append( preview_action_html );
|
1388 |
AstraElementorSitesAdmin._masonry();
|
1389 |
|
1390 |
let actual_id = AstraElementorSitesAdmin.block_id.replace( 'id-', '' );
|
1398 |
$elscope.find( '.dialog-lightbox-message' ).animate({ scrollTop: 0 }, 50 );
|
1399 |
$elscope.find( '.theme-preview' ).show();
|
1400 |
|
1401 |
+
$elscope.find( '.ast-sites-modal__header' ).addClass( 'ast-preview-mode' );
|
1402 |
+
|
1403 |
if ( undefined === AstraElementorSitesAdmin.site_id ) {
|
1404 |
return;
|
1405 |
}
|
1420 |
$elscope.find( '.astra-sites-step-1-wrap' ).hide();
|
1421 |
|
1422 |
preview_action_html = import_template_header( template_object );
|
1423 |
+
$elscope.find( '.elementor-templates-modal__header__items-area' ).append( preview_action_html );
|
1424 |
|
1425 |
let actual_id = AstraElementorSitesAdmin.page_id.replace( 'id-', '' );
|
1426 |
$( document ).trigger( 'astra-sites__elementor-plugin-check', { 'id': actual_id } );
|
1428 |
|
1429 |
_preview : function( e ) {
|
1430 |
|
1431 |
+
if ( AstraElementorSitesAdmin.processing ) {
|
1432 |
+
return;
|
1433 |
+
}
|
1434 |
+
|
1435 |
let step = $( this ).attr( 'data-step' );
|
1436 |
|
1437 |
AstraElementorSitesAdmin.site_id = $( this ).closest( '.astra-theme' ).data( 'site-id' );
|
1441 |
$elscope.find( '.back-to-layout' ).css( 'visibility', 'visible' );
|
1442 |
$elscope.find( '.back-to-layout' ).css( 'opacity', '1' );
|
1443 |
|
1444 |
+
$elscope.find( '.ast-template-library-toolbar' ).hide();
|
1445 |
+
$elscope.find( '.ast-sites-modal__header' ).removeClass( 'ast-preview-mode' );
|
1446 |
+
|
1447 |
if ( 1 == step ) {
|
1448 |
|
1449 |
$elscope.find( '.back-to-layout' ).attr( 'data-step', 2 );
|
1498 |
}
|
1499 |
} else {
|
1500 |
if ( undefined !== AstraElementorSitesAdmin.templateData['post-meta']['astra-blocks-required-plugins'] ) {
|
1501 |
+
AstraElementorSitesAdmin._requiredPluginsMarkup( PHP.parse( AstraElementorSitesAdmin.templateData['post-meta']['astra-blocks-required-plugins'] ) );
|
1502 |
}
|
1503 |
}
|
1504 |
}
|
1622 |
}
|
1623 |
|
1624 |
if ( '' != output ) {
|
1625 |
+
output = '<li class="plugin-card-head"><strong>' + astraElementorSites.install_plugin_text + '</strong></li>' + output;
|
1626 |
$elscope.find('.required-plugins-list').html( output );
|
1627 |
$elscope.find('.ast-tooltip-wrap').css( 'opacity', 1 );
|
1628 |
$elscope.find('.astra-sites-tooltip').css( 'opacity', 1 );
|
inc/assets/js/helper.js
ADDED
@@ -0,0 +1,174 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
"use strict";
|
2 |
+
|
3 |
+
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
4 |
+
|
5 |
+
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _nonIterableRest(); }
|
6 |
+
|
7 |
+
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance"); }
|
8 |
+
|
9 |
+
function _iterableToArrayLimit(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"] != null) _i["return"](); } finally { if (_d) throw _e; } } return _arr; }
|
10 |
+
|
11 |
+
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
12 |
+
|
13 |
+
var PHP = {
|
14 |
+
stdClass: function stdClass() {},
|
15 |
+
stringify: function stringify(val) {
|
16 |
+
var hash = new Map([[Infinity, "d:INF;"], [-Infinity, "d:-INF;"], [NaN, "d:NAN;"], [null, "N;"], [undefined, "N;"]]);
|
17 |
+
|
18 |
+
var utf8length = function utf8length(str) {
|
19 |
+
return str ? encodeURI(str).match(/(%.)?./g).length : 0;
|
20 |
+
};
|
21 |
+
|
22 |
+
var serializeString = function serializeString(s) {
|
23 |
+
var delim = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : '"';
|
24 |
+
return "".concat(utf8length(s), ":").concat(delim[0]).concat(s).concat(delim[delim.length - 1]);
|
25 |
+
};
|
26 |
+
|
27 |
+
var ref = 0;
|
28 |
+
|
29 |
+
function serialize(val) {
|
30 |
+
var canReference = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;
|
31 |
+
if (hash.has(val)) return hash.get(val);
|
32 |
+
ref += canReference;
|
33 |
+
if (typeof val === "string") return "s:".concat(serializeString(val), ";");
|
34 |
+
if (typeof val === "number") return "".concat(Math.round(val) === val ? "i" : "d", ":").concat(("" + val).toUpperCase().replace(/(-?\d)E/, "$1.0E"), ";");
|
35 |
+
if (typeof val === "boolean") return "b:".concat(+val, ";");
|
36 |
+
var a = Array.isArray(val) || val.constructor === Object;
|
37 |
+
hash.set(val, "".concat("rR"[+a], ":").concat(ref, ";"));
|
38 |
+
|
39 |
+
if (typeof val.serialize === "function") {
|
40 |
+
return "C:".concat(serializeString(val.constructor.name), ":").concat(serializeString(val.serialize(), "{}"));
|
41 |
+
}
|
42 |
+
|
43 |
+
var vals = Object.entries(val).filter(function (_ref) {
|
44 |
+
var _ref2 = _slicedToArray(_ref, 2),
|
45 |
+
k = _ref2[0],
|
46 |
+
v = _ref2[1];
|
47 |
+
|
48 |
+
return typeof v !== "function";
|
49 |
+
});
|
50 |
+
return (a ? "a" : "O:".concat(serializeString(val.constructor.name))) + ":".concat(vals.length, ":{").concat(vals.map(function (_ref3) {
|
51 |
+
var _ref4 = _slicedToArray(_ref3, 2),
|
52 |
+
k = _ref4[0],
|
53 |
+
v = _ref4[1];
|
54 |
+
|
55 |
+
return serialize(a && /^\d{1,16}#x2F;.test(k) ? +k : k, false) + serialize(v);
|
56 |
+
}).join(""), "}");
|
57 |
+
}
|
58 |
+
|
59 |
+
return serialize(val);
|
60 |
+
},
|
61 |
+
// Provide in second argument the classes that may be instantiated
|
62 |
+
// e.g. { MyClass1, MyClass2 }
|
63 |
+
parse: function parse(str) {
|
64 |
+
var allowedClasses = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
65 |
+
allowedClasses.stdClass = PHP.stdClass; // Always allowed.
|
66 |
+
|
67 |
+
var offset = 0;
|
68 |
+
var values = [null];
|
69 |
+
var specialNums = {
|
70 |
+
"INF": Infinity,
|
71 |
+
"-INF": -Infinity,
|
72 |
+
"NAN": NaN
|
73 |
+
};
|
74 |
+
|
75 |
+
var kick = function kick(msg) {
|
76 |
+
var i = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : offset;
|
77 |
+
throw new Error("Error at ".concat(i, ": ").concat(msg, "\n").concat(str, "\n").concat(" ".repeat(i), "^"));
|
78 |
+
};
|
79 |
+
|
80 |
+
var read = function read(expected, ret) {
|
81 |
+
return expected === str.slice(offset, offset += expected.length) ? ret : kick("Expected '".concat(expected, "'"), offset - expected.length);
|
82 |
+
};
|
83 |
+
|
84 |
+
function readMatch(regex, msg) {
|
85 |
+
var terminator = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : ";";
|
86 |
+
read(":");
|
87 |
+
var match = regex.exec(str.slice(offset));
|
88 |
+
if (!match) kick("Exected ".concat(msg, ", but got '").concat(str.slice(offset).match(/^[:;{}]|[^:;{}]*/)[0], "'"));
|
89 |
+
offset += match[0].length;
|
90 |
+
return read(terminator, match[0]);
|
91 |
+
}
|
92 |
+
|
93 |
+
function readUtf8chars(numUtf8Bytes) {
|
94 |
+
var terminator = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : "";
|
95 |
+
var i = offset;
|
96 |
+
|
97 |
+
while (numUtf8Bytes > 0) {
|
98 |
+
var code = str.charCodeAt(offset++);
|
99 |
+
numUtf8Bytes -= code < 0x80 ? 1 : code < 0x800 || code >> 11 === 0x1B ? 2 : 3;
|
100 |
+
}
|
101 |
+
|
102 |
+
return numUtf8Bytes ? kick("Invalid string length", i - 2) : read(terminator, str.slice(i, offset));
|