diff --git a/src/components/Elements/MainModal/Main.jsx b/src/components/Elements/MainModal/Main.jsx
index 059acb26..b0898ea9 100644
--- a/src/components/Elements/MainModal/Main.jsx
+++ b/src/components/Elements/MainModal/Main.jsx
@@ -162,10 +162,14 @@ function MainModal({ modalClose, deepLinkData }) {
const handleSectionChange = (section, sectionName) => {
setCurrentSection(section);
setCurrentSectionName(sectionName);
- setCurrentSubSection(null);
- const entry = { section, sectionName, subSection: null };
+ // Only reset subsection if we're actually changing to a different section
+ // Don't reset on initial section set (when currentSectionName is empty)
+ if (currentSectionName !== '' && currentSectionName !== sectionName) {
+ setCurrentSubSection(null);
+ }
+ const entry = { section, sectionName, subSection: (currentSectionName === '' || currentSectionName === sectionName) ? currentSubSection : null };
const current = historyRef.current[historyIndexRef.current];
- if (!current || current.sectionName !== sectionName || current.subSection !== null) {
+ if (!current || current.sectionName !== sectionName || current.subSection !== entry.subSection) {
historyRef.current = historyRef.current.slice(0, historyIndexRef.current + 1).concat(entry);
historyIndexRef.current = historyRef.current.length - 1;
updateNavButtons();
@@ -183,7 +187,11 @@ function MainModal({ modalClose, deepLinkData }) {
updateHash(`#${currentTab}/${sectionKey}`);
}
} else if (currentTab === TAB_TYPES.SETTINGS && sectionName) {
- updateHash(`#${currentTab}/${sectionName}`, false);
+ // Include subsection in hash if it exists and we're not changing sections
+ const hash = currentSubSection && (currentSectionName === '' || currentSectionName === sectionName)
+ ? `#${currentTab}/${sectionName}/${currentSubSection}`
+ : `#${currentTab}/${sectionName}`;
+ updateHash(hash, false);
}
};
diff --git a/src/components/Elements/MainModal/scss/modules/_modalTabContent.scss b/src/components/Elements/MainModal/scss/modules/_modalTabContent.scss
index ebaf8a34..702100f6 100644
--- a/src/components/Elements/MainModal/scss/modules/_modalTabContent.scss
+++ b/src/components/Elements/MainModal/scss/modules/_modalTabContent.scss
@@ -13,10 +13,11 @@
// height: 100%;
overflow-y: auto;
+ margin-bottom: 0;
+ padding-bottom: 2rem;
@include themed {
background: t($modal-background);
- margin: 0;
border-radius: t($borderRadius);
}
diff --git a/src/features/background/options/sections/SourceSection.jsx b/src/features/background/options/sections/SourceSection.jsx
index 95cbad14..7f79dec9 100644
--- a/src/features/background/options/sections/SourceSection.jsx
+++ b/src/features/background/options/sections/SourceSection.jsx
@@ -4,6 +4,7 @@ import { Dropdown } from 'components/Form/Settings';
import { Row, Content, Action } from 'components/Layout/Settings/Item';
import { Button } from 'components/Elements';
import Items from 'features/marketplace/components/Items/Items';
+import SuggestedPacks from 'features/marketplace/components/SuggestedPacks';
import { getBackgroundOptionItems } from '../optionTypes';
const SourceSection = ({
@@ -70,6 +71,7 @@ const SourceSection = ({
viewType="grid"
showChips={false}
/>
+