fix GrapesJS save button spinner visibility
Replace Bootstrap-dependent class toggling (d-none) with inline style.display for the save button spinner. Update the pagebuilder view to use inline display:none instead of the d-none class on the spinner element.
This commit is contained in:
Vendored
+1
-1
File diff suppressed because one or more lines are too long
+1
-1
File diff suppressed because one or more lines are too long
@@ -573,11 +573,11 @@
|
||||
if (button.classList.contains('waiting')) {
|
||||
button.removeAttribute("disabled");
|
||||
button.classList.remove('waiting');
|
||||
if (spinner) spinner.classList.add('d-none');
|
||||
if (spinner) spinner.style.display = "none";
|
||||
} else {
|
||||
button.setAttribute("disabled", "true");
|
||||
button.classList.add('waiting');
|
||||
if (spinner) spinner.classList.remove('d-none');
|
||||
if (spinner) spinner.style.display = "";
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -129,7 +129,7 @@ require __DIR__ . '/grapesjs/trait-manager.php';
|
||||
|
||||
<div id="sidebar-bottom-buttons" class="flex items-center justify-between">
|
||||
<button id="save-page" class="btn btn-sm btn-success flex-1 rounded-none text-white gap-2" data-url="<?= phpb_url('pagebuilder', ['action' => 'store', 'page' => $page->getId()]) ?>">
|
||||
<span class="loading loading-spinner loading-xs d-none" role="status" aria-hidden="true"></span>
|
||||
<span class="loading loading-spinner loading-xs" style="display: none;" role="status" aria-hidden="true"></span>
|
||||
<i class="fa fa-save"></i>
|
||||
<span><?= phpb_trans('pagebuilder.save-page') ?></span>
|
||||
</button>
|
||||
|
||||
Reference in New Issue
Block a user