mirror of
https://github.com/PR0M3TH3AN/Artstr-Studio.git
synced 2026-10-27 08:40:39 +00:00
Auto-set modal filter to 'All' when Browse Templates opened from Templates tab
This commit is contained in:
1 parent
6f3c18a344
commit
937ac826f8
1 file changed
+10
-1
+10
-1
@@ -5094,7 +5094,16 @@
|
||||
$('designerNostrLoadBtn').addEventListener('click', openDiscDesignNostrSearch);
|
||||
|
||||
|
||||
$('browseCommunityBtn').addEventListener('click', () => { $('nostrModal').classList.add('open'); switchModalTab('New'); });
|
||||
$('browseCommunityBtn').addEventListener('click', () => {
|
||||
for (const t of ['New', 'Popular', 'Mine']) {
|
||||
_feedState[`filter${t}`] = 'any';
|
||||
document.querySelectorAll(`.feedTypeBtn[data-tab="${t}"]`).forEach(btn => {
|
||||
btn.classList.toggle('active', btn.dataset.type === 'any');
|
||||
});
|
||||
}
|
||||
$('nostrModal').classList.add('open');
|
||||
switchModalTab('New');
|
||||
});
|
||||
$('designerBrowseCommunityBtn').addEventListener('click', () => {
|
||||
for (const t of ['New', 'Popular', 'Mine']) {
|
||||
_feedState[`filter${t}`] = 'disc-design';
|
||||
|
||||
Reference in new issue
Block a user