diff --git a/public/scripts/templates/WorldInfoKeywordHeaders.html b/public/scripts/templates/WorldInfoKeywordHeaders.html new file mode 100644 index 000000000..e6592ae1a --- /dev/null +++ b/public/scripts/templates/WorldInfoKeywordHeaders.html @@ -0,0 +1,8 @@ +
+ Title/Memo + Status + Position + Depth + Order + Trigger % +
diff --git a/public/scripts/world-info.js b/public/scripts/world-info.js index af5c917c0..344fab21e 100644 --- a/public/scripts/world-info.js +++ b/public/scripts/world-info.js @@ -17,6 +17,7 @@ import { commonEnumProviders, enumIcons } from './slash-commands/SlashCommandCom import { SlashCommandClosure } from './slash-commands/SlashCommandClosure.js'; import { callGenericPopup, Popup, POPUP_TYPE } from './popup.js'; import { StructuredCloneMap } from './util/StructuredCloneMap.js'; +import { renderTemplateAsync } from './templates.js'; export const world_info_insertion_strategy = { evenly: 0, @@ -1854,27 +1855,7 @@ function displayWorldEntries(name, data, navigation = navigation_option.none, fl worldEntriesList.find('*').off(); worldEntriesList.empty(); - const keywordHeaders = ` -
- - Title/Memo - - - Status - - - Position - - - Depth - - - Order - - - Trigger % - -
`; + const keywordHeaders = await renderTemplateAsync('WorldInfoKeywordHeaders'); const blocksPromises = page.map(async (entry) => await getWorldEntry(name, data, entry)).filter(x => x); const blocks = await Promise.all(blocksPromises); const isCustomOrder = $('#world_info_sort_order').find(':selected').data('rule') === 'custom';