Merge branch 'SillyTavern:staging' into staging

This commit is contained in:
Tony Ribeiro
2023-10-10 01:51:30 +02:00
committed by GitHub
14 changed files with 270 additions and 116 deletions

View File

@ -47,8 +47,10 @@ function downloadAssetsList(url) {
}
console.debug(DEBUG_PREFIX, "Updated available assets to", availableAssets);
// First extensions, then everything else
const assetTypes = Object.keys(availableAssets).sort((a, b) => (a === 'extension') ? -1 : (b === 'extension') ? 1 : 0);
for (const assetType in availableAssets) {
for (const assetType of assetTypes) {
let assetTypeMenu = $('<div />', { id: "assets_audio_ambient_div", class: "assets-list-div" });
assetTypeMenu.append(`<h3>${assetType}</h3>`)
for (const i in availableAssets[assetType]) {