feat: deep links for rest of settings

This commit is contained in:
David Ralph
2026-01-24 15:52:16 +00:00
parent 19c2c29df0
commit ae42aa1241
4 changed files with 61 additions and 11 deletions

View File

@@ -7,7 +7,7 @@ import Navbar from '../../navbar/Navbar';
import Preview from '../../helpers/preview/Preview';
import EventBus from 'utils/eventbus';
import { parseDeepLink, shouldAutoOpenModal } from 'utils/deepLinking';
import { parseDeepLink, shouldAutoOpenModal, updateHash } from 'utils/deepLinking';
import Welcome from 'features/welcome/Welcome';
@@ -88,6 +88,10 @@ const Modals = () => {
if (action !== false) {
variables.stats.postEvent('modal', `Opened ${type.replace('Modal', '')}`);
// Set initial hash when opening main modal
if (type === 'mainModal') {
updateHash('#settings');
}
}
};

View File

@@ -95,6 +95,9 @@ function Settings(props) {
current="settings"
currentTab={props.currentTab}
onSectionChange={props.onSectionChange}
deepLinkData={props.deepLinkData}
navigationTrigger={props.navigationTrigger}
sections={sections}
>
{sections.map(({ label, name, component: Component }) => (
<div key={name} label={variables.getMessage(label)} name={name}>