import { localizer } from "../../utils/Localizer.mjs"; const { randomID } = foundry.utils; export function stringSet(input, data) { const label = localizer(input.label); const placeholder = localizer(input.placeholder ?? ``); const id = `${data.meta.idp}-${randomID(10)}`; if (!data.meta.editable) { const tagList = input.value .split(/,\s*/) .filter(t => t.length > 0) .map(t => { return `
${t.trim()}
`; }); let tags = tagList.join(``); if (tagList.length === 0) { tags = `---`; }; if (data.meta.limited) { tags = `???`; }; return `
${label}
${tags}
`; }; return `
`; };