Skip to content

Commit ae68c19

Browse files
committed
update to 1.4.1
1 parent 6ff9eb0 commit ae68c19

File tree

587 files changed

+252217
-2282
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

587 files changed

+252217
-2282
lines changed

core/admin/admin.scss

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -311,8 +311,7 @@ body.toplevel_page_maxi-blocks-dashboard {
311311
&:nth-child(6),
312312
&:nth-child(5),
313313
&:nth-child(4),
314-
&:nth-child(3),
315-
&:nth-child(2) {
314+
&:nth-child(3) {
316315
p {
317316
&:first-child {
318317
padding-top: 11px;
@@ -322,7 +321,7 @@ body.toplevel_page_maxi-blocks-dashboard {
322321
}
323322
}
324323
}
325-
&:nth-child(3),
324+
//&:nth-child(3),
326325
&:nth-child(4),
327326
&:nth-child(7) {
328327
h4 {

core/admin/class-maxi-dashboard.php

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1098,6 +1098,41 @@ public function generate_setting(
10981098
return $content;
10991099
}
11001100

1101+
public function generate_styles_button()
1102+
{
1103+
echo '
1104+
<script type="text/javascript">
1105+
document.addEventListener("DOMContentLoaded", function() {
1106+
var button = document.getElementById("maxi-regenerate-styles-button");
1107+
1108+
if(button) document.getElementById("maxi-regenerate-styles-button").addEventListener("click", function() {
1109+
button.disabled = true; // disable the button
1110+
1111+
var loadingMessage = document.createElement("div");
1112+
loadingMessage.id = "loading";
1113+
loadingMessage.innerHTML = "<p>Running... Please wait.</p>";
1114+
button.parentNode.insertBefore(loadingMessage, button.nextSibling); // show loading message
1115+
1116+
fetch(ajaxurl, {
1117+
method: "POST",
1118+
headers: {
1119+
"Content-Type": "application/x-www-form-urlencoded"
1120+
},
1121+
body: "action=maxi_process_all_site_content"
1122+
})
1123+
.then(response => response.text())
1124+
.then(response => {
1125+
document.getElementById("loading").remove(); // remove loading message
1126+
button.disabled = false; // re-enable the button
1127+
alert(response); // alert the response from the server
1128+
});
1129+
});
1130+
});
1131+
</script>
1132+
';
1133+
}
1134+
1135+
11011136
public function maxi_blocks_allowed_html()
11021137
{
11031138
if (!function_exists('maxi_blocks_allowed_html')) {

core/admin/maxi-allowed-html-tags.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,7 @@ function maxi_blocks_allowed_html()
6262
'name' => true,
6363
'type' => true,
6464
'value' => true,
65+
'id' => true,
6566
),
6667
'caption' => array(
6768
'align' => true,
@@ -468,4 +469,4 @@ function maxi_blocks_allowed_html()
468469
);
469470

470471
return $allowed_tags;
471-
}
472+
}

0 commit comments

Comments
 (0)