refactor: consolidate to Word templates only - remove A4 designer, visual builder, manual JSON, AI generation
This commit is contained in:
@@ -5,15 +5,15 @@ const CARBONE_API = window.location.protocol + '//' + window.location.hostname +
|
||||
// ============================================================
|
||||
// NAVIGATION
|
||||
// ============================================================
|
||||
// Load carbone data when the page is shown via a MutationObserver
|
||||
// Load carbone templates when the templates page is shown
|
||||
const carboneNavObserver = new MutationObserver(() => {
|
||||
if (document.getElementById('page-carbone') && document.getElementById('page-carbone').classList.contains('active')) {
|
||||
if (document.getElementById('page-templates') && document.getElementById('page-templates').classList.contains('active')) {
|
||||
loadCarboneTemplates();
|
||||
}
|
||||
});
|
||||
document.addEventListener('DOMContentLoaded', () => {
|
||||
const carbonePage = document.getElementById('page-carbone');
|
||||
if (carbonePage) carboneNavObserver.observe(carbonePage, { attributes: true, attributeFilter: ['class'] });
|
||||
const templatesPage = document.getElementById('page-templates');
|
||||
if (templatesPage) carboneNavObserver.observe(templatesPage, { attributes: true, attributeFilter: ['class'] });
|
||||
});
|
||||
|
||||
// ============================================================
|
||||
|
||||
Reference in New Issue
Block a user