sort samples in tabs
This commit is contained in:
parent
803b5e56fc
commit
16ad27406d
1 changed files with 4 additions and 2 deletions
|
|
@ -13,7 +13,9 @@ export function SoundsTab() {
|
||||||
const sounds = useStore(soundMap);
|
const sounds = useStore(soundMap);
|
||||||
const { soundsFilter } = useSettings();
|
const { soundsFilter } = useSettings();
|
||||||
const soundEntries = useMemo(() => {
|
const soundEntries = useMemo(() => {
|
||||||
let filtered = Object.entries(sounds).filter(([key]) => !key.startsWith('_'));
|
let filtered = Object.entries(sounds)
|
||||||
|
.filter(([key]) => !key.startsWith('_'))
|
||||||
|
.sort((a, b) => a[0].localeCompare(b[0]));
|
||||||
if (!sounds) {
|
if (!sounds) {
|
||||||
return [];
|
return [];
|
||||||
}
|
}
|
||||||
|
|
@ -43,7 +45,7 @@ export function SoundsTab() {
|
||||||
});
|
});
|
||||||
return (
|
return (
|
||||||
<div id="sounds-tab" className="px-4 flex flex-col w-full h-full dark:text-white text-stone-900">
|
<div id="sounds-tab" className="px-4 flex flex-col w-full h-full dark:text-white text-stone-900">
|
||||||
<div className="pb-2 flex shrink-0 overflow-auto">
|
<div className="pb-2 flex shrink-0 flex-wrap">
|
||||||
<ButtonGroup
|
<ButtonGroup
|
||||||
value={soundsFilter}
|
value={soundsFilter}
|
||||||
onChange={(value) => settingsMap.setKey('soundsFilter', value)}
|
onChange={(value) => settingsMap.setKey('soundsFilter', value)}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue