feat: exposer le radar business à la racine
This commit is contained in:
@@ -8,7 +8,7 @@
|
||||
|
||||
function handleStrategyRoute() {
|
||||
// Vérifier si on est sur la route stratégie au chargement initial
|
||||
if (window.location.pathname === '/business/strategie' || window.location.pathname === '/business/strategie.html' || window.location.hash === '#strategie') {
|
||||
if (window.location.pathname === '/strategie' || window.location.pathname === '/strategie.html' || window.location.hash === '#strategie') {
|
||||
createStrategyPage();
|
||||
}
|
||||
}
|
||||
@@ -17,7 +17,7 @@
|
||||
function interceptStrategyLinks() {
|
||||
document.addEventListener('click', function(e) {
|
||||
const link = e.target.closest('a');
|
||||
if (link && (link.href.includes('/business/strategie') || link.getAttribute('href') === '/business/strategie' || link.id === 'strategie-link')) {
|
||||
if (link && (link.href.includes('/strategie') || link.getAttribute('href') === '/strategie' || link.id === 'strategie-link')) {
|
||||
e.preventDefault();
|
||||
e.stopPropagation();
|
||||
createStrategyPage();
|
||||
@@ -55,13 +55,13 @@
|
||||
// Réinitialiser les liens après restauration
|
||||
setTimeout(initStrategyLinks, 100);
|
||||
} else {
|
||||
window.location.href = '/business/';
|
||||
window.location.href = '/';
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
// Mettre à jour l'URL sans recharger la page
|
||||
window.history.pushState({page: 'strategie'}, 'Stratégie', '/business/strategie');
|
||||
window.history.pushState({page: 'strategie'}, 'Stratégie', '/strategie');
|
||||
}
|
||||
|
||||
function addStrategyLinkToFooter() {
|
||||
|
||||
Reference in New Issue
Block a user