@jean-is/render 0.8.0-rb7dd9e653b35 → 0.8.0-rc16b69aeba0b
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/brand.js +3 -2
- package/caps/charts/charts.css +5 -2
- package/caps/charts/charts.js +58 -28
- package/caps/charts/option.js +28 -1
- package/caps/files/midi.js +1 -1
- package/caps/files/office.js +17 -10
- package/caps/files/pdf.js +3 -0
- package/caps/games/page.js +1 -1
- package/caps/games/shell.js +2 -2
- package/caps/interactive/apps.js +14 -7
- package/caps/interactive/diagram.js +97 -23
- package/caps/interactive/interactive.css +7 -1
- package/caps/interactive/interactive.js +58 -18
- package/caps/interactive/live.js +96 -0
- package/caps/interactive/map.js +30 -4
- package/caps/interactive/mode.js +9 -6
- package/caps/interactive/page-diagram.js +6 -2
- package/caps/interactive/parts.js +20 -12
- package/caps/interactive/starts.js +15 -0
- package/caps/interactive/test.js +76 -0
- package/caps/interactive/view-parts.js +54 -31
- package/caps/layouts/layouts.css +7 -8
- package/caps/layouts/layouts.js +49 -40
- package/caps/layouts/shapes.js +50 -34
- package/caps/layouts/types.d.ts +8 -0
- package/caps/made/formats.js +84 -46
- package/caps/made/paper.js +142 -0
- package/caps/math/math.js +2 -2
- package/caps/receipt/der.js +1 -1
- package/caps/scores/scores.css +7 -7
- package/caps/scores/scores.js +44 -52
- package/caps/share/view.js +3 -2
- package/caps/skills/directory.js +5 -1
- package/caps/slides/edit.js +14 -4
- package/caps/slides/kit-page.css +8 -2
- package/caps/slides/kit-page.js +49 -39
- package/caps/slides/kit-sample.js +36 -0
- package/caps/slides/kit-slot.js +10 -0
- package/caps/slides/kit.js +3 -0
- package/caps/slides/save.js +24 -58
- package/caps/slides/slides.css +12 -9
- package/caps/slides/slides.js +24 -24
- package/caps/tables/formula.js +133 -0
- package/core/anthropic.js +10 -10
- package/core/conversations.js +2 -4
- package/core/deferred.js +38 -17
- package/core/events.js +4 -4
- package/core/files.js +2 -2
- package/core/fs.js +23 -85
- package/core/hooks.js +5 -5
- package/core/i18n.js +23 -20
- package/core/llm.js +47 -55
- package/core/loop.js +24 -22
- package/core/oauth.js +31 -0
- package/core/rules.js +1 -1
- package/core/search.js +1 -1
- package/core/settings.js +7 -61
- package/core/skills.js +2 -2
- package/core/vertex.js +37 -0
- package/core/zip.js +1 -1
- package/locales/am.json +41 -21
- package/locales/approvals/am.json +2 -3
- package/locales/approvals/ar.json +2 -3
- package/locales/approvals/bg.json +2 -3
- package/locales/approvals/bn.json +2 -3
- package/locales/approvals/br.json +8 -9
- package/locales/approvals/co.json +19 -20
- package/locales/approvals/cs.json +2 -3
- package/locales/approvals/da.json +2 -3
- package/locales/approvals/de.json +7 -8
- package/locales/approvals/el.json +2 -3
- package/locales/approvals/en.json +4 -5
- package/locales/approvals/es.json +8 -9
- package/locales/approvals/fa.json +2 -3
- package/locales/approvals/fi.json +2 -3
- package/locales/approvals/fr-CA.json +8 -9
- package/locales/approvals/fr.json +8 -9
- package/locales/approvals/ha.json +2 -3
- package/locales/approvals/he.json +2 -3
- package/locales/approvals/hi.json +2 -3
- package/locales/approvals/hr.json +2 -3
- package/locales/approvals/hu.json +2 -3
- package/locales/approvals/id.json +2 -3
- package/locales/approvals/it.json +11 -12
- package/locales/approvals/ja.json +9 -10
- package/locales/approvals/ko.json +21 -22
- package/locales/approvals/mr.json +2 -3
- package/locales/approvals/ms.json +2 -3
- package/locales/approvals/nl.json +2 -3
- package/locales/approvals/pl.json +2 -3
- package/locales/approvals/pt.json +7 -8
- package/locales/approvals/ro.json +2 -3
- package/locales/approvals/ru.json +2 -3
- package/locales/approvals/sk.json +2 -3
- package/locales/approvals/sv.json +2 -3
- package/locales/approvals/sw.json +2 -3
- package/locales/approvals/ta.json +2 -3
- package/locales/approvals/te.json +2 -3
- package/locales/approvals/th.json +2 -3
- package/locales/approvals/tl.json +2 -3
- package/locales/approvals/tr.json +2 -3
- package/locales/approvals/uk.json +2 -3
- package/locales/approvals/ur.json +2 -3
- package/locales/approvals/vi.json +2 -3
- package/locales/approvals/yo.json +2 -3
- package/locales/approvals/zh-Hans.json +6 -7
- package/locales/approvals/zh-Hant.json +5 -6
- package/locales/ar.json +45 -21
- package/locales/backup/de.json +1 -1
- package/locales/backup/ko.json +1 -1
- package/locales/backup/pt.json +1 -1
- package/locales/backup/zh-Hans.json +1 -1
- package/locales/bg.json +41 -21
- package/locales/bn.json +40 -20
- package/locales/br.json +65 -42
- package/locales/brain-local/ja.json +1 -1
- package/locales/brain-local/pt.json +3 -3
- package/locales/brain-local/zh-Hans.json +1 -1
- package/locales/brain-local/zh-Hant.json +3 -3
- package/locales/brains/am.json +7 -4
- package/locales/brains/ar.json +7 -4
- package/locales/brains/bg.json +7 -4
- package/locales/brains/bn.json +7 -4
- package/locales/brains/br.json +16 -13
- package/locales/brains/co.json +18 -15
- package/locales/brains/cs.json +7 -4
- package/locales/brains/da.json +7 -4
- package/locales/brains/de.json +13 -10
- package/locales/brains/el.json +7 -4
- package/locales/brains/en.json +12 -9
- package/locales/brains/es.json +20 -17
- package/locales/brains/fa.json +7 -4
- package/locales/brains/fi.json +7 -4
- package/locales/brains/fr-CA.json +14 -11
- package/locales/brains/fr.json +14 -11
- package/locales/brains/ha.json +7 -4
- package/locales/brains/he.json +7 -4
- package/locales/brains/hi.json +7 -4
- package/locales/brains/hr.json +7 -4
- package/locales/brains/hu.json +7 -4
- package/locales/brains/id.json +7 -4
- package/locales/brains/it.json +14 -11
- package/locales/brains/ja.json +15 -12
- package/locales/brains/ko.json +16 -13
- package/locales/brains/mr.json +7 -4
- package/locales/brains/ms.json +7 -4
- package/locales/brains/nl.json +7 -4
- package/locales/brains/pl.json +7 -4
- package/locales/brains/pt.json +16 -13
- package/locales/brains/ro.json +7 -4
- package/locales/brains/ru.json +7 -4
- package/locales/brains/sk.json +7 -4
- package/locales/brains/sv.json +7 -4
- package/locales/brains/sw.json +7 -4
- package/locales/brains/ta.json +7 -4
- package/locales/brains/te.json +7 -4
- package/locales/brains/th.json +7 -4
- package/locales/brains/tl.json +7 -4
- package/locales/brains/tr.json +7 -4
- package/locales/brains/uk.json +7 -4
- package/locales/brains/ur.json +7 -4
- package/locales/brains/vi.json +7 -4
- package/locales/brains/yo.json +7 -4
- package/locales/brains/zh-Hans.json +13 -10
- package/locales/brains/zh-Hant.json +20 -17
- package/locales/browser/co.json +2 -2
- package/locales/browser/es.json +1 -1
- package/locales/browser/it.json +1 -1
- package/locales/browser/ja.json +2 -2
- package/locales/browser/ko.json +6 -6
- package/locales/browser/pt.json +2 -2
- package/locales/camera/br.json +1 -1
- package/locales/camera/co.json +1 -1
- package/locales/camera/de.json +1 -1
- package/locales/camera/it.json +1 -1
- package/locales/camera/ja.json +2 -2
- package/locales/camera/ko.json +2 -2
- package/locales/camera/zh-Hant.json +1 -1
- package/locales/case/br.json +1 -1
- package/locales/case/co.json +10 -10
- package/locales/case/de.json +1 -1
- package/locales/case/es.json +6 -6
- package/locales/case/fr-CA.json +9 -9
- package/locales/case/fr.json +9 -9
- package/locales/case/it.json +8 -8
- package/locales/case/ja.json +6 -6
- package/locales/case/ko.json +1 -1
- package/locales/case/pt.json +8 -8
- package/locales/case/zh-Hant.json +1 -1
- package/locales/certificates/co.json +7 -7
- package/locales/certificates/es.json +2 -2
- package/locales/certificates/fr-CA.json +7 -7
- package/locales/certificates/fr.json +7 -7
- package/locales/certificates/it.json +3 -3
- package/locales/certificates/ja.json +2 -2
- package/locales/certificates/ko.json +1 -1
- package/locales/certificates/pt.json +2 -2
- package/locales/certificates/zh-Hans.json +5 -5
- package/locales/certificates/zh-Hant.json +6 -6
- package/locales/charts/am.json +2 -0
- package/locales/charts/ar.json +2 -0
- package/locales/charts/bg.json +2 -0
- package/locales/charts/bn.json +2 -0
- package/locales/charts/br.json +2 -0
- package/locales/charts/co.json +2 -0
- package/locales/charts/cs.json +2 -0
- package/locales/charts/da.json +2 -0
- package/locales/charts/de.json +3 -1
- package/locales/charts/el.json +2 -0
- package/locales/charts/en.json +2 -0
- package/locales/charts/es.json +2 -0
- package/locales/charts/fa.json +2 -0
- package/locales/charts/fi.json +2 -0
- package/locales/charts/fr-CA.json +2 -0
- package/locales/charts/fr.json +2 -0
- package/locales/charts/ha.json +2 -0
- package/locales/charts/he.json +2 -0
- package/locales/charts/hi.json +2 -0
- package/locales/charts/hr.json +2 -0
- package/locales/charts/hu.json +2 -0
- package/locales/charts/id.json +2 -0
- package/locales/charts/it.json +2 -0
- package/locales/charts/ja.json +2 -0
- package/locales/charts/ko.json +3 -1
- package/locales/charts/mr.json +2 -0
- package/locales/charts/ms.json +2 -0
- package/locales/charts/nl.json +2 -0
- package/locales/charts/pl.json +2 -0
- package/locales/charts/pt.json +2 -0
- package/locales/charts/ro.json +2 -0
- package/locales/charts/ru.json +2 -0
- package/locales/charts/sk.json +2 -0
- package/locales/charts/sv.json +2 -0
- package/locales/charts/sw.json +2 -0
- package/locales/charts/ta.json +2 -0
- package/locales/charts/te.json +2 -0
- package/locales/charts/th.json +2 -0
- package/locales/charts/tl.json +2 -0
- package/locales/charts/tr.json +2 -0
- package/locales/charts/uk.json +2 -0
- package/locales/charts/ur.json +2 -0
- package/locales/charts/vi.json +2 -0
- package/locales/charts/yo.json +2 -0
- package/locales/charts/zh-Hans.json +2 -0
- package/locales/charts/zh-Hant.json +2 -0
- package/locales/co.json +55 -34
- package/locales/compact/es.json +1 -1
- package/locales/compact/fr-CA.json +1 -1
- package/locales/compact/fr.json +1 -1
- package/locales/compact/it.json +1 -1
- package/locales/compact/pt.json +2 -2
- package/locales/computer/br.json +8 -8
- package/locales/computer/co.json +14 -14
- package/locales/computer/de.json +4 -4
- package/locales/computer/en.json +6 -6
- package/locales/computer/es.json +10 -10
- package/locales/computer/fr-CA.json +17 -17
- package/locales/computer/fr.json +17 -17
- package/locales/computer/it.json +9 -9
- package/locales/computer/ja.json +8 -8
- package/locales/computer/ko.json +14 -14
- package/locales/computer/pt.json +10 -10
- package/locales/computer/zh-Hans.json +8 -8
- package/locales/computer/zh-Hant.json +9 -9
- package/locales/connections/am.json +4 -2
- package/locales/connections/ar.json +4 -2
- package/locales/connections/bg.json +4 -2
- package/locales/connections/bn.json +4 -2
- package/locales/connections/br.json +5 -3
- package/locales/connections/co.json +17 -15
- package/locales/connections/cs.json +4 -2
- package/locales/connections/da.json +4 -2
- package/locales/connections/de.json +4 -2
- package/locales/connections/el.json +4 -2
- package/locales/connections/en.json +5 -3
- package/locales/connections/es.json +7 -5
- package/locales/connections/fa.json +4 -2
- package/locales/connections/fi.json +4 -2
- package/locales/connections/fr-CA.json +5 -3
- package/locales/connections/fr.json +5 -3
- package/locales/connections/ha.json +4 -2
- package/locales/connections/he.json +4 -2
- package/locales/connections/hi.json +4 -2
- package/locales/connections/hr.json +4 -2
- package/locales/connections/hu.json +4 -2
- package/locales/connections/id.json +4 -2
- package/locales/connections/it.json +13 -11
- package/locales/connections/ja.json +28 -26
- package/locales/connections/ko.json +7 -5
- package/locales/connections/mr.json +4 -2
- package/locales/connections/ms.json +4 -2
- package/locales/connections/nl.json +4 -2
- package/locales/connections/pl.json +4 -2
- package/locales/connections/pt.json +10 -8
- package/locales/connections/ro.json +4 -2
- package/locales/connections/ru.json +4 -2
- package/locales/connections/sk.json +4 -2
- package/locales/connections/sv.json +4 -2
- package/locales/connections/sw.json +4 -2
- package/locales/connections/ta.json +4 -2
- package/locales/connections/te.json +4 -2
- package/locales/connections/th.json +4 -2
- package/locales/connections/tl.json +4 -2
- package/locales/connections/tr.json +4 -2
- package/locales/connections/uk.json +4 -2
- package/locales/connections/ur.json +4 -2
- package/locales/connections/vi.json +4 -2
- package/locales/connections/yo.json +4 -2
- package/locales/connections/zh-Hans.json +10 -8
- package/locales/connections/zh-Hant.json +23 -21
- package/locales/creations/am.json +4 -0
- package/locales/creations/ar.json +4 -0
- package/locales/creations/bg.json +4 -0
- package/locales/creations/bn.json +4 -0
- package/locales/creations/br.json +18 -14
- package/locales/creations/co.json +15 -11
- package/locales/creations/cs.json +4 -0
- package/locales/creations/da.json +4 -0
- package/locales/creations/de.json +5 -1
- package/locales/creations/el.json +4 -0
- package/locales/creations/en.json +5 -1
- package/locales/creations/es.json +13 -9
- package/locales/creations/fa.json +4 -0
- package/locales/creations/fi.json +4 -0
- package/locales/creations/fr-CA.json +5 -1
- package/locales/creations/fr.json +13 -9
- package/locales/creations/ha.json +4 -0
- package/locales/creations/he.json +4 -0
- package/locales/creations/hi.json +4 -0
- package/locales/creations/hr.json +4 -0
- package/locales/creations/hu.json +4 -0
- package/locales/creations/id.json +4 -0
- package/locales/creations/it.json +12 -8
- package/locales/creations/ja.json +5 -1
- package/locales/creations/ko.json +5 -1
- package/locales/creations/mr.json +4 -0
- package/locales/creations/ms.json +4 -0
- package/locales/creations/nl.json +4 -0
- package/locales/creations/pl.json +4 -0
- package/locales/creations/pt.json +12 -8
- package/locales/creations/ro.json +4 -0
- package/locales/creations/ru.json +4 -0
- package/locales/creations/sk.json +4 -0
- package/locales/creations/sv.json +4 -0
- package/locales/creations/sw.json +4 -0
- package/locales/creations/ta.json +4 -0
- package/locales/creations/te.json +4 -0
- package/locales/creations/th.json +4 -0
- package/locales/creations/tl.json +4 -0
- package/locales/creations/tr.json +4 -0
- package/locales/creations/uk.json +4 -0
- package/locales/creations/ur.json +4 -0
- package/locales/creations/vi.json +4 -0
- package/locales/creations/yo.json +4 -0
- package/locales/creations/zh-Hans.json +5 -1
- package/locales/creations/zh-Hant.json +5 -1
- package/locales/cs.json +43 -21
- package/locales/da.json +40 -20
- package/locales/data/am.json +5 -1
- package/locales/data/ar.json +5 -1
- package/locales/data/bg.json +5 -1
- package/locales/data/bn.json +5 -1
- package/locales/data/br.json +7 -3
- package/locales/data/co.json +8 -4
- package/locales/data/cs.json +5 -1
- package/locales/data/da.json +5 -1
- package/locales/data/de.json +5 -1
- package/locales/data/el.json +5 -1
- package/locales/data/en.json +5 -1
- package/locales/data/es.json +9 -5
- package/locales/data/fa.json +5 -1
- package/locales/data/fi.json +5 -1
- package/locales/data/fr-CA.json +5 -1
- package/locales/data/fr.json +5 -1
- package/locales/data/ha.json +5 -1
- package/locales/data/he.json +5 -1
- package/locales/data/hi.json +5 -1
- package/locales/data/hr.json +5 -1
- package/locales/data/hu.json +5 -1
- package/locales/data/id.json +5 -1
- package/locales/data/it.json +6 -2
- package/locales/data/ja.json +13 -9
- package/locales/data/ko.json +7 -3
- package/locales/data/mr.json +5 -1
- package/locales/data/ms.json +5 -1
- package/locales/data/nl.json +5 -1
- package/locales/data/pl.json +5 -1
- package/locales/data/pt.json +10 -6
- package/locales/data/ro.json +5 -1
- package/locales/data/ru.json +5 -1
- package/locales/data/sk.json +5 -1
- package/locales/data/sv.json +5 -1
- package/locales/data/sw.json +5 -1
- package/locales/data/ta.json +5 -1
- package/locales/data/te.json +5 -1
- package/locales/data/th.json +5 -1
- package/locales/data/tl.json +5 -1
- package/locales/data/tr.json +5 -1
- package/locales/data/uk.json +5 -1
- package/locales/data/ur.json +5 -1
- package/locales/data/vi.json +5 -1
- package/locales/data/yo.json +5 -1
- package/locales/data/zh-Hans.json +7 -3
- package/locales/data/zh-Hant.json +9 -5
- package/locales/de.json +56 -36
- package/locales/designs/am.json +0 -13
- package/locales/designs/ar.json +0 -13
- package/locales/designs/bg.json +0 -13
- package/locales/designs/bn.json +0 -13
- package/locales/designs/br.json +9 -22
- package/locales/designs/co.json +8 -21
- package/locales/designs/cs.json +0 -13
- package/locales/designs/da.json +0 -13
- package/locales/designs/de.json +1 -14
- package/locales/designs/el.json +0 -13
- package/locales/designs/en.json +3 -16
- package/locales/designs/es.json +0 -13
- package/locales/designs/fa.json +0 -13
- package/locales/designs/fi.json +0 -13
- package/locales/designs/fr-CA.json +4 -17
- package/locales/designs/fr.json +5 -18
- package/locales/designs/ha.json +0 -13
- package/locales/designs/he.json +0 -13
- package/locales/designs/hi.json +0 -13
- package/locales/designs/hr.json +0 -13
- package/locales/designs/hu.json +0 -13
- package/locales/designs/id.json +0 -13
- package/locales/designs/it.json +6 -19
- package/locales/designs/ja.json +10 -23
- package/locales/designs/ko.json +6 -19
- package/locales/designs/mr.json +0 -13
- package/locales/designs/ms.json +0 -13
- package/locales/designs/nl.json +0 -13
- package/locales/designs/pl.json +0 -13
- package/locales/designs/pt.json +3 -16
- package/locales/designs/ro.json +0 -13
- package/locales/designs/ru.json +0 -13
- package/locales/designs/sk.json +0 -13
- package/locales/designs/sv.json +0 -13
- package/locales/designs/sw.json +0 -13
- package/locales/designs/ta.json +0 -13
- package/locales/designs/te.json +0 -13
- package/locales/designs/th.json +0 -13
- package/locales/designs/tl.json +0 -13
- package/locales/designs/tr.json +0 -13
- package/locales/designs/uk.json +0 -13
- package/locales/designs/ur.json +0 -13
- package/locales/designs/vi.json +0 -13
- package/locales/designs/yo.json +0 -13
- package/locales/designs/zh-Hans.json +1 -14
- package/locales/designs/zh-Hant.json +1 -14
- package/locales/devices/am.json +79 -0
- package/locales/devices/ar.json +87 -0
- package/locales/devices/bg.json +79 -0
- package/locales/devices/bn.json +79 -0
- package/locales/devices/br.json +85 -0
- package/locales/devices/co.json +81 -0
- package/locales/devices/cs.json +83 -0
- package/locales/devices/da.json +79 -0
- package/locales/devices/de.json +79 -0
- package/locales/devices/el.json +79 -0
- package/locales/devices/en.json +79 -0
- package/locales/devices/es.json +81 -0
- package/locales/devices/fa.json +79 -0
- package/locales/devices/fi.json +79 -0
- package/locales/devices/fr-CA.json +81 -0
- package/locales/devices/fr.json +81 -0
- package/locales/devices/ha.json +79 -0
- package/locales/devices/he.json +81 -0
- package/locales/devices/hi.json +79 -0
- package/locales/devices/hr.json +81 -0
- package/locales/devices/hu.json +79 -0
- package/locales/devices/id.json +77 -0
- package/locales/devices/it.json +81 -0
- package/locales/devices/ja.json +77 -0
- package/locales/devices/ko.json +77 -0
- package/locales/devices/mr.json +79 -0
- package/locales/devices/ms.json +77 -0
- package/locales/devices/nl.json +79 -0
- package/locales/devices/pl.json +83 -0
- package/locales/devices/pt.json +81 -0
- package/locales/devices/ro.json +81 -0
- package/locales/devices/ru.json +83 -0
- package/locales/devices/sk.json +83 -0
- package/locales/devices/sv.json +79 -0
- package/locales/devices/sw.json +79 -0
- package/locales/devices/ta.json +79 -0
- package/locales/devices/te.json +79 -0
- package/locales/devices/th.json +77 -0
- package/locales/devices/tl.json +79 -0
- package/locales/devices/tr.json +79 -0
- package/locales/devices/uk.json +83 -0
- package/locales/devices/ur.json +79 -0
- package/locales/devices/vi.json +77 -0
- package/locales/devices/yo.json +77 -0
- package/locales/devices/zh-Hans.json +77 -0
- package/locales/devices/zh-Hant.json +77 -0
- package/locales/dialogs/am.json +20 -11
- package/locales/dialogs/ar.json +20 -11
- package/locales/dialogs/bg.json +20 -11
- package/locales/dialogs/bn.json +20 -11
- package/locales/dialogs/br.json +39 -30
- package/locales/dialogs/co.json +39 -30
- package/locales/dialogs/cs.json +20 -11
- package/locales/dialogs/da.json +20 -11
- package/locales/dialogs/de.json +33 -24
- package/locales/dialogs/el.json +20 -11
- package/locales/dialogs/en.json +28 -19
- package/locales/dialogs/es.json +48 -39
- package/locales/dialogs/fa.json +20 -11
- package/locales/dialogs/fi.json +20 -11
- package/locales/dialogs/fr-CA.json +37 -28
- package/locales/dialogs/fr.json +37 -28
- package/locales/dialogs/ha.json +20 -11
- package/locales/dialogs/he.json +20 -11
- package/locales/dialogs/hi.json +20 -11
- package/locales/dialogs/hr.json +20 -11
- package/locales/dialogs/hu.json +20 -11
- package/locales/dialogs/id.json +20 -11
- package/locales/dialogs/it.json +42 -33
- package/locales/dialogs/ja.json +72 -63
- package/locales/dialogs/ko.json +43 -34
- package/locales/dialogs/mr.json +20 -11
- package/locales/dialogs/ms.json +20 -11
- package/locales/dialogs/nl.json +20 -11
- package/locales/dialogs/pl.json +20 -11
- package/locales/dialogs/pt.json +46 -37
- package/locales/dialogs/ro.json +20 -11
- package/locales/dialogs/ru.json +20 -11
- package/locales/dialogs/sk.json +20 -11
- package/locales/dialogs/sv.json +20 -11
- package/locales/dialogs/sw.json +20 -11
- package/locales/dialogs/ta.json +20 -11
- package/locales/dialogs/te.json +20 -11
- package/locales/dialogs/th.json +20 -11
- package/locales/dialogs/tl.json +20 -11
- package/locales/dialogs/tr.json +20 -11
- package/locales/dialogs/uk.json +20 -11
- package/locales/dialogs/ur.json +20 -11
- package/locales/dialogs/vi.json +20 -11
- package/locales/dialogs/yo.json +20 -11
- package/locales/dialogs/zh-Hans.json +41 -32
- package/locales/dialogs/zh-Hant.json +49 -40
- package/locales/documents/am.json +16 -2
- package/locales/documents/ar.json +16 -2
- package/locales/documents/bg.json +16 -2
- package/locales/documents/bn.json +16 -2
- package/locales/documents/br.json +16 -2
- package/locales/documents/co.json +18 -4
- package/locales/documents/cs.json +16 -2
- package/locales/documents/da.json +16 -2
- package/locales/documents/de.json +18 -4
- package/locales/documents/el.json +16 -2
- package/locales/documents/en.json +17 -3
- package/locales/documents/es.json +17 -3
- package/locales/documents/fa.json +16 -2
- package/locales/documents/fi.json +16 -2
- package/locales/documents/fr-CA.json +17 -3
- package/locales/documents/fr.json +17 -3
- package/locales/documents/ha.json +16 -2
- package/locales/documents/he.json +16 -2
- package/locales/documents/hi.json +16 -2
- package/locales/documents/hr.json +16 -2
- package/locales/documents/hu.json +16 -2
- package/locales/documents/id.json +16 -2
- package/locales/documents/it.json +17 -3
- package/locales/documents/ja.json +30 -16
- package/locales/documents/ko.json +17 -3
- package/locales/documents/mr.json +16 -2
- package/locales/documents/ms.json +16 -2
- package/locales/documents/nl.json +16 -2
- package/locales/documents/pl.json +16 -2
- package/locales/documents/pt.json +20 -6
- package/locales/documents/ro.json +16 -2
- package/locales/documents/ru.json +16 -2
- package/locales/documents/sk.json +16 -2
- package/locales/documents/sv.json +16 -2
- package/locales/documents/sw.json +16 -2
- package/locales/documents/ta.json +16 -2
- package/locales/documents/te.json +16 -2
- package/locales/documents/th.json +16 -2
- package/locales/documents/tl.json +16 -2
- package/locales/documents/tr.json +16 -2
- package/locales/documents/uk.json +16 -2
- package/locales/documents/ur.json +16 -2
- package/locales/documents/vi.json +16 -2
- package/locales/documents/yo.json +16 -2
- package/locales/documents/zh-Hans.json +18 -4
- package/locales/documents/zh-Hant.json +18 -4
- package/locales/el.json +41 -21
- package/locales/en.json +47 -27
- package/locales/enterprise/am.json +29 -1
- package/locales/enterprise/ar.json +29 -1
- package/locales/enterprise/bg.json +29 -1
- package/locales/enterprise/bn.json +29 -1
- package/locales/enterprise/br.json +31 -3
- package/locales/enterprise/co.json +30 -2
- package/locales/enterprise/cs.json +29 -1
- package/locales/enterprise/da.json +29 -1
- package/locales/enterprise/de.json +30 -2
- package/locales/enterprise/el.json +29 -1
- package/locales/enterprise/en.json +30 -2
- package/locales/enterprise/es.json +30 -2
- package/locales/enterprise/fa.json +29 -1
- package/locales/enterprise/fi.json +29 -1
- package/locales/enterprise/fr-CA.json +31 -3
- package/locales/enterprise/fr.json +31 -3
- package/locales/enterprise/ha.json +29 -1
- package/locales/enterprise/he.json +29 -1
- package/locales/enterprise/hi.json +29 -1
- package/locales/enterprise/hr.json +29 -1
- package/locales/enterprise/hu.json +29 -1
- package/locales/enterprise/id.json +29 -1
- package/locales/enterprise/it.json +31 -3
- package/locales/enterprise/ja.json +37 -9
- package/locales/enterprise/ko.json +30 -2
- package/locales/enterprise/mr.json +29 -1
- package/locales/enterprise/ms.json +29 -1
- package/locales/enterprise/nl.json +29 -1
- package/locales/enterprise/pl.json +29 -1
- package/locales/enterprise/pt.json +30 -2
- package/locales/enterprise/ro.json +29 -1
- package/locales/enterprise/ru.json +29 -1
- package/locales/enterprise/sk.json +29 -1
- package/locales/enterprise/sv.json +29 -1
- package/locales/enterprise/sw.json +29 -1
- package/locales/enterprise/ta.json +29 -1
- package/locales/enterprise/te.json +29 -1
- package/locales/enterprise/th.json +29 -1
- package/locales/enterprise/tl.json +29 -1
- package/locales/enterprise/tr.json +29 -1
- package/locales/enterprise/uk.json +29 -1
- package/locales/enterprise/ur.json +29 -1
- package/locales/enterprise/vi.json +29 -1
- package/locales/enterprise/yo.json +29 -1
- package/locales/enterprise/zh-Hans.json +38 -10
- package/locales/enterprise/zh-Hant.json +38 -10
- package/locales/es.json +56 -35
- package/locales/extensions/am.json +2 -1
- package/locales/extensions/ar.json +2 -1
- package/locales/extensions/bg.json +2 -1
- package/locales/extensions/bn.json +2 -1
- package/locales/extensions/br.json +12 -11
- package/locales/extensions/co.json +8 -7
- package/locales/extensions/cs.json +2 -1
- package/locales/extensions/da.json +2 -1
- package/locales/extensions/de.json +3 -2
- package/locales/extensions/el.json +2 -1
- package/locales/extensions/en.json +3 -2
- package/locales/extensions/es.json +4 -3
- package/locales/extensions/fa.json +2 -1
- package/locales/extensions/fi.json +2 -1
- package/locales/extensions/fr-CA.json +7 -6
- package/locales/extensions/fr.json +7 -6
- package/locales/extensions/ha.json +2 -1
- package/locales/extensions/he.json +2 -1
- package/locales/extensions/hi.json +2 -1
- package/locales/extensions/hr.json +2 -1
- package/locales/extensions/hu.json +2 -1
- package/locales/extensions/id.json +2 -1
- package/locales/extensions/it.json +5 -4
- package/locales/extensions/ja.json +7 -6
- package/locales/extensions/ko.json +24 -23
- package/locales/extensions/mr.json +2 -1
- package/locales/extensions/ms.json +2 -1
- package/locales/extensions/nl.json +2 -1
- package/locales/extensions/pl.json +2 -1
- package/locales/extensions/pt.json +5 -4
- package/locales/extensions/ro.json +2 -1
- package/locales/extensions/ru.json +2 -1
- package/locales/extensions/sk.json +2 -1
- package/locales/extensions/sv.json +2 -1
- package/locales/extensions/sw.json +2 -1
- package/locales/extensions/ta.json +2 -1
- package/locales/extensions/te.json +2 -1
- package/locales/extensions/th.json +2 -1
- package/locales/extensions/tl.json +2 -1
- package/locales/extensions/tr.json +2 -1
- package/locales/extensions/uk.json +2 -1
- package/locales/extensions/ur.json +2 -1
- package/locales/extensions/vi.json +2 -1
- package/locales/extensions/yo.json +2 -1
- package/locales/extensions/zh-Hans.json +5 -4
- package/locales/extensions/zh-Hant.json +9 -8
- package/locales/fa.json +40 -20
- package/locales/feedback/am.json +7 -0
- package/locales/feedback/ar.json +7 -0
- package/locales/feedback/bg.json +7 -0
- package/locales/feedback/bn.json +7 -0
- package/locales/feedback/br.json +7 -0
- package/locales/feedback/co.json +7 -0
- package/locales/feedback/cs.json +7 -0
- package/locales/feedback/da.json +7 -0
- package/locales/feedback/de.json +7 -0
- package/locales/feedback/el.json +7 -0
- package/locales/feedback/en.json +7 -0
- package/locales/feedback/es.json +7 -0
- package/locales/feedback/fa.json +7 -0
- package/locales/feedback/fi.json +7 -0
- package/locales/feedback/fr-CA.json +7 -0
- package/locales/feedback/fr.json +7 -0
- package/locales/feedback/ha.json +7 -0
- package/locales/feedback/he.json +7 -0
- package/locales/feedback/hi.json +7 -0
- package/locales/feedback/hr.json +7 -0
- package/locales/feedback/hu.json +7 -0
- package/locales/feedback/id.json +7 -0
- package/locales/feedback/it.json +7 -0
- package/locales/feedback/ja.json +7 -0
- package/locales/feedback/ko.json +7 -0
- package/locales/feedback/mr.json +7 -0
- package/locales/feedback/ms.json +7 -0
- package/locales/feedback/nl.json +7 -0
- package/locales/feedback/pl.json +7 -0
- package/locales/feedback/pt.json +7 -0
- package/locales/feedback/ro.json +7 -0
- package/locales/feedback/ru.json +7 -0
- package/locales/feedback/sk.json +7 -0
- package/locales/feedback/sv.json +7 -0
- package/locales/feedback/sw.json +7 -0
- package/locales/feedback/ta.json +7 -0
- package/locales/feedback/te.json +7 -0
- package/locales/feedback/th.json +7 -0
- package/locales/feedback/tl.json +7 -0
- package/locales/feedback/tr.json +7 -0
- package/locales/feedback/uk.json +7 -0
- package/locales/feedback/ur.json +7 -0
- package/locales/feedback/vi.json +7 -0
- package/locales/feedback/yo.json +7 -0
- package/locales/feedback/zh-Hans.json +7 -0
- package/locales/feedback/zh-Hant.json +7 -0
- package/locales/fi.json +41 -21
- package/locales/files/am.json +10 -0
- package/locales/files/ar.json +10 -0
- package/locales/files/bg.json +10 -0
- package/locales/files/bn.json +10 -0
- package/locales/files/br.json +10 -0
- package/locales/files/co.json +10 -0
- package/locales/files/cs.json +10 -0
- package/locales/files/da.json +10 -0
- package/locales/files/de.json +10 -0
- package/locales/files/el.json +10 -0
- package/locales/files/en.json +10 -0
- package/locales/files/es.json +10 -0
- package/locales/files/fa.json +10 -0
- package/locales/files/fi.json +10 -0
- package/locales/files/fr-CA.json +10 -0
- package/locales/files/fr.json +10 -0
- package/locales/files/ha.json +10 -0
- package/locales/files/he.json +10 -0
- package/locales/files/hi.json +10 -0
- package/locales/files/hr.json +10 -0
- package/locales/files/hu.json +10 -0
- package/locales/files/id.json +10 -0
- package/locales/files/it.json +10 -0
- package/locales/files/ja.json +10 -0
- package/locales/files/ko.json +10 -0
- package/locales/files/mr.json +10 -0
- package/locales/files/ms.json +10 -0
- package/locales/files/nl.json +10 -0
- package/locales/files/pl.json +10 -0
- package/locales/files/pt.json +10 -0
- package/locales/files/ro.json +10 -0
- package/locales/files/ru.json +10 -0
- package/locales/files/sk.json +10 -0
- package/locales/files/sv.json +10 -0
- package/locales/files/sw.json +10 -0
- package/locales/files/ta.json +10 -0
- package/locales/files/te.json +10 -0
- package/locales/files/th.json +10 -0
- package/locales/files/tl.json +10 -0
- package/locales/files/tr.json +10 -0
- package/locales/files/uk.json +10 -0
- package/locales/files/ur.json +10 -0
- package/locales/files/vi.json +10 -0
- package/locales/files/yo.json +10 -0
- package/locales/files/zh-Hans.json +10 -0
- package/locales/files/zh-Hant.json +10 -0
- package/locales/first/br.json +5 -5
- package/locales/first/co.json +1 -1
- package/locales/first/es.json +4 -4
- package/locales/first/fr-CA.json +1 -1
- package/locales/first/fr.json +1 -1
- package/locales/first/it.json +1 -1
- package/locales/first/ja.json +7 -7
- package/locales/first/ko.json +3 -3
- package/locales/first/pt.json +3 -3
- package/locales/first/zh-Hans.json +2 -2
- package/locales/first/zh-Hant.json +3 -3
- package/locales/flows/am.json +3 -0
- package/locales/flows/ar.json +3 -0
- package/locales/flows/bg.json +3 -0
- package/locales/flows/bn.json +3 -0
- package/locales/flows/br.json +10 -7
- package/locales/flows/co.json +7 -4
- package/locales/flows/cs.json +3 -0
- package/locales/flows/da.json +3 -0
- package/locales/flows/de.json +5 -2
- package/locales/flows/el.json +3 -0
- package/locales/flows/en.json +3 -0
- package/locales/flows/es.json +5 -2
- package/locales/flows/fa.json +3 -0
- package/locales/flows/fi.json +3 -0
- package/locales/flows/fr-CA.json +6 -3
- package/locales/flows/fr.json +6 -3
- package/locales/flows/ha.json +3 -0
- package/locales/flows/he.json +3 -0
- package/locales/flows/hi.json +3 -0
- package/locales/flows/hr.json +3 -0
- package/locales/flows/hu.json +3 -0
- package/locales/flows/id.json +3 -0
- package/locales/flows/it.json +5 -2
- package/locales/flows/ja.json +7 -4
- package/locales/flows/ko.json +10 -7
- package/locales/flows/mr.json +3 -0
- package/locales/flows/ms.json +3 -0
- package/locales/flows/nl.json +3 -0
- package/locales/flows/pl.json +3 -0
- package/locales/flows/pt.json +9 -6
- package/locales/flows/ro.json +3 -0
- package/locales/flows/ru.json +3 -0
- package/locales/flows/sk.json +3 -0
- package/locales/flows/sv.json +3 -0
- package/locales/flows/sw.json +3 -0
- package/locales/flows/ta.json +3 -0
- package/locales/flows/te.json +3 -0
- package/locales/flows/th.json +3 -0
- package/locales/flows/tl.json +3 -0
- package/locales/flows/tr.json +3 -0
- package/locales/flows/uk.json +3 -0
- package/locales/flows/ur.json +3 -0
- package/locales/flows/vi.json +3 -0
- package/locales/flows/yo.json +3 -0
- package/locales/flows/zh-Hans.json +8 -5
- package/locales/flows/zh-Hant.json +11 -8
- package/locales/folders/br.json +4 -4
- package/locales/folders/de.json +1 -1
- package/locales/folders/es.json +2 -2
- package/locales/folders/ja.json +2 -2
- package/locales/folders/ko.json +3 -3
- package/locales/folders/pt.json +2 -2
- package/locales/folders/zh-Hans.json +2 -2
- package/locales/folders/zh-Hant.json +7 -7
- package/locales/fr-CA.json +75 -54
- package/locales/fr.json +72 -51
- package/locales/games/br.json +2 -2
- package/locales/ha.json +40 -20
- package/locales/he.json +41 -20
- package/locales/hi.json +40 -20
- package/locales/hr.json +42 -21
- package/locales/hu.json +40 -20
- package/locales/id.json +40 -21
- package/locales/interactive/am.json +8 -1
- package/locales/interactive/ar.json +8 -1
- package/locales/interactive/bg.json +8 -1
- package/locales/interactive/bn.json +8 -1
- package/locales/interactive/br.json +11 -4
- package/locales/interactive/co.json +11 -4
- package/locales/interactive/cs.json +8 -1
- package/locales/interactive/da.json +8 -1
- package/locales/interactive/de.json +8 -1
- package/locales/interactive/el.json +8 -1
- package/locales/interactive/en.json +8 -1
- package/locales/interactive/es.json +9 -2
- package/locales/interactive/fa.json +8 -1
- package/locales/interactive/fi.json +8 -1
- package/locales/interactive/fr-CA.json +8 -1
- package/locales/interactive/fr.json +8 -1
- package/locales/interactive/ha.json +8 -1
- package/locales/interactive/he.json +8 -1
- package/locales/interactive/hi.json +8 -1
- package/locales/interactive/hr.json +8 -1
- package/locales/interactive/hu.json +8 -1
- package/locales/interactive/id.json +8 -1
- package/locales/interactive/it.json +9 -2
- package/locales/interactive/ja.json +9 -2
- package/locales/interactive/ko.json +11 -4
- package/locales/interactive/mr.json +8 -1
- package/locales/interactive/ms.json +8 -1
- package/locales/interactive/nl.json +8 -1
- package/locales/interactive/pl.json +8 -1
- package/locales/interactive/pt.json +10 -3
- package/locales/interactive/ro.json +8 -1
- package/locales/interactive/ru.json +8 -1
- package/locales/interactive/sk.json +8 -1
- package/locales/interactive/sv.json +8 -1
- package/locales/interactive/sw.json +8 -1
- package/locales/interactive/ta.json +8 -1
- package/locales/interactive/te.json +8 -1
- package/locales/interactive/th.json +8 -1
- package/locales/interactive/tl.json +8 -1
- package/locales/interactive/tr.json +8 -1
- package/locales/interactive/uk.json +8 -1
- package/locales/interactive/ur.json +8 -1
- package/locales/interactive/vi.json +8 -1
- package/locales/interactive/yo.json +8 -1
- package/locales/interactive/zh-Hans.json +8 -1
- package/locales/interactive/zh-Hant.json +11 -4
- package/locales/it.json +79 -58
- package/locales/ja.json +68 -49
- package/locales/ko.json +62 -43
- package/locales/layouts/ja.json +1 -1
- package/locales/layouts/zh-Hans.json +1 -1
- package/locales/layouts/zh-Hant.json +1 -1
- package/locales/lock/am.json +6 -3
- package/locales/lock/ar.json +6 -3
- package/locales/lock/bg.json +6 -3
- package/locales/lock/bn.json +6 -3
- package/locales/lock/br.json +8 -5
- package/locales/lock/co.json +8 -5
- package/locales/lock/cs.json +6 -3
- package/locales/lock/da.json +6 -3
- package/locales/lock/de.json +8 -5
- package/locales/lock/el.json +6 -3
- package/locales/lock/en.json +7 -4
- package/locales/lock/es.json +7 -4
- package/locales/lock/fa.json +6 -3
- package/locales/lock/fi.json +6 -3
- package/locales/lock/fr-CA.json +7 -4
- package/locales/lock/fr.json +7 -4
- package/locales/lock/ha.json +6 -3
- package/locales/lock/he.json +6 -3
- package/locales/lock/hi.json +6 -3
- package/locales/lock/hr.json +6 -3
- package/locales/lock/hu.json +6 -3
- package/locales/lock/id.json +6 -3
- package/locales/lock/it.json +10 -7
- package/locales/lock/ja.json +10 -7
- package/locales/lock/ko.json +8 -5
- package/locales/lock/mr.json +6 -3
- package/locales/lock/ms.json +6 -3
- package/locales/lock/nl.json +6 -3
- package/locales/lock/pl.json +6 -3
- package/locales/lock/pt.json +7 -4
- package/locales/lock/ro.json +6 -3
- package/locales/lock/ru.json +6 -3
- package/locales/lock/sk.json +6 -3
- package/locales/lock/sv.json +6 -3
- package/locales/lock/sw.json +6 -3
- package/locales/lock/ta.json +6 -3
- package/locales/lock/te.json +6 -3
- package/locales/lock/th.json +6 -3
- package/locales/lock/tl.json +6 -3
- package/locales/lock/tr.json +6 -3
- package/locales/lock/uk.json +6 -3
- package/locales/lock/ur.json +6 -3
- package/locales/lock/vi.json +6 -3
- package/locales/lock/yo.json +6 -3
- package/locales/lock/zh-Hans.json +7 -4
- package/locales/lock/zh-Hant.json +7 -4
- package/locales/look/am.json +10 -1
- package/locales/look/ar.json +10 -1
- package/locales/look/bg.json +10 -1
- package/locales/look/bn.json +10 -1
- package/locales/look/br.json +17 -8
- package/locales/look/co.json +10 -1
- package/locales/look/cs.json +10 -1
- package/locales/look/da.json +10 -1
- package/locales/look/de.json +10 -1
- package/locales/look/el.json +10 -1
- package/locales/look/en.json +10 -1
- package/locales/look/es.json +12 -3
- package/locales/look/fa.json +10 -1
- package/locales/look/fi.json +10 -1
- package/locales/look/fr-CA.json +10 -1
- package/locales/look/fr.json +10 -1
- package/locales/look/ha.json +10 -1
- package/locales/look/he.json +10 -1
- package/locales/look/hi.json +10 -1
- package/locales/look/hr.json +10 -1
- package/locales/look/hu.json +10 -1
- package/locales/look/id.json +10 -1
- package/locales/look/it.json +10 -1
- package/locales/look/ja.json +14 -5
- package/locales/look/ko.json +11 -2
- package/locales/look/mr.json +10 -1
- package/locales/look/ms.json +10 -1
- package/locales/look/nl.json +10 -1
- package/locales/look/pl.json +10 -1
- package/locales/look/pt.json +12 -3
- package/locales/look/ro.json +10 -1
- package/locales/look/ru.json +10 -1
- package/locales/look/sk.json +10 -1
- package/locales/look/sv.json +10 -1
- package/locales/look/sw.json +10 -1
- package/locales/look/ta.json +10 -1
- package/locales/look/te.json +10 -1
- package/locales/look/th.json +10 -1
- package/locales/look/tl.json +10 -1
- package/locales/look/tr.json +10 -1
- package/locales/look/uk.json +10 -1
- package/locales/look/ur.json +10 -1
- package/locales/look/vi.json +10 -1
- package/locales/look/yo.json +10 -1
- package/locales/look/zh-Hans.json +15 -6
- package/locales/look/zh-Hant.json +18 -9
- package/locales/machine/br.json +5 -5
- package/locales/machine/co.json +4 -4
- package/locales/machine/de.json +2 -2
- package/locales/machine/en.json +2 -2
- package/locales/machine/es.json +8 -8
- package/locales/machine/fr-CA.json +4 -4
- package/locales/machine/fr.json +4 -4
- package/locales/machine/it.json +9 -9
- package/locales/machine/ja.json +4 -4
- package/locales/machine/ko.json +10 -10
- package/locales/machine/pt.json +4 -4
- package/locales/machine/zh-Hans.json +7 -7
- package/locales/machine/zh-Hant.json +10 -10
- package/locales/made/am.json +5 -1
- package/locales/made/ar.json +5 -1
- package/locales/made/bg.json +5 -1
- package/locales/made/bn.json +5 -1
- package/locales/made/br.json +7 -3
- package/locales/made/co.json +5 -1
- package/locales/made/cs.json +5 -1
- package/locales/made/da.json +5 -1
- package/locales/made/de.json +5 -1
- package/locales/made/el.json +5 -1
- package/locales/made/en.json +5 -1
- package/locales/made/es.json +5 -1
- package/locales/made/fa.json +5 -1
- package/locales/made/fi.json +5 -1
- package/locales/made/fr-CA.json +8 -4
- package/locales/made/fr.json +8 -4
- package/locales/made/ha.json +5 -1
- package/locales/made/he.json +5 -1
- package/locales/made/hi.json +5 -1
- package/locales/made/hr.json +5 -1
- package/locales/made/hu.json +5 -1
- package/locales/made/id.json +5 -1
- package/locales/made/it.json +5 -1
- package/locales/made/ja.json +5 -1
- package/locales/made/ko.json +6 -2
- package/locales/made/mr.json +5 -1
- package/locales/made/ms.json +5 -1
- package/locales/made/nl.json +5 -1
- package/locales/made/pl.json +5 -1
- package/locales/made/pt.json +8 -4
- package/locales/made/ro.json +5 -1
- package/locales/made/ru.json +5 -1
- package/locales/made/sk.json +5 -1
- package/locales/made/sv.json +5 -1
- package/locales/made/sw.json +5 -1
- package/locales/made/ta.json +5 -1
- package/locales/made/te.json +5 -1
- package/locales/made/th.json +5 -1
- package/locales/made/tl.json +5 -1
- package/locales/made/tr.json +5 -1
- package/locales/made/uk.json +5 -1
- package/locales/made/ur.json +5 -1
- package/locales/made/vi.json +5 -1
- package/locales/made/yo.json +5 -1
- package/locales/made/zh-Hans.json +7 -3
- package/locales/made/zh-Hant.json +6 -2
- package/locales/mr.json +40 -20
- package/locales/ms.json +40 -21
- package/locales/{reader → natural-voice}/es.json +1 -1
- package/locales/natural-voice/ja.json +9 -0
- package/locales/{reader → natural-voice}/zh-Hans.json +1 -1
- package/locales/{reader → natural-voice}/zh-Hant.json +2 -2
- package/locales/nl.json +41 -21
- package/locales/notifications/br.json +2 -2
- package/locales/notifications/es.json +4 -4
- package/locales/notifications/it.json +2 -2
- package/locales/notifications/pt.json +2 -2
- package/locales/notifications/zh-Hans.json +1 -1
- package/locales/notifications/zh-Hant.json +2 -2
- package/locales/out/am.json +13 -0
- package/locales/out/ar.json +13 -0
- package/locales/out/bg.json +13 -0
- package/locales/out/bn.json +13 -0
- package/locales/out/br.json +13 -0
- package/locales/out/co.json +13 -0
- package/locales/out/cs.json +13 -0
- package/locales/out/da.json +13 -0
- package/locales/out/de.json +13 -0
- package/locales/out/el.json +13 -0
- package/locales/out/en.json +13 -0
- package/locales/out/es.json +13 -0
- package/locales/out/fa.json +13 -0
- package/locales/out/fi.json +13 -0
- package/locales/out/fr-CA.json +13 -0
- package/locales/out/fr.json +13 -0
- package/locales/out/ha.json +13 -0
- package/locales/out/he.json +13 -0
- package/locales/out/hi.json +13 -0
- package/locales/out/hr.json +13 -0
- package/locales/out/hu.json +13 -0
- package/locales/out/id.json +13 -0
- package/locales/out/it.json +13 -0
- package/locales/out/ja.json +13 -0
- package/locales/out/ko.json +13 -0
- package/locales/out/mr.json +13 -0
- package/locales/out/ms.json +13 -0
- package/locales/out/nl.json +13 -0
- package/locales/out/pl.json +13 -0
- package/locales/out/pt.json +13 -0
- package/locales/out/ro.json +13 -0
- package/locales/out/ru.json +13 -0
- package/locales/out/sk.json +13 -0
- package/locales/out/sv.json +13 -0
- package/locales/out/sw.json +13 -0
- package/locales/out/ta.json +13 -0
- package/locales/out/te.json +13 -0
- package/locales/out/th.json +13 -0
- package/locales/out/tl.json +13 -0
- package/locales/out/tr.json +13 -0
- package/locales/out/uk.json +13 -0
- package/locales/out/ur.json +13 -0
- package/locales/out/vi.json +13 -0
- package/locales/out/yo.json +13 -0
- package/locales/out/zh-Hans.json +13 -0
- package/locales/out/zh-Hant.json +13 -0
- package/locales/pictures/br.json +5 -5
- package/locales/pictures/co.json +5 -5
- package/locales/pictures/de.json +3 -3
- package/locales/pictures/en.json +2 -2
- package/locales/pictures/es.json +4 -4
- package/locales/pictures/fr-CA.json +6 -6
- package/locales/pictures/fr.json +4 -4
- package/locales/pictures/it.json +7 -7
- package/locales/pictures/ja.json +8 -8
- package/locales/pictures/ko.json +8 -8
- package/locales/pictures/pt.json +5 -5
- package/locales/pictures/zh-Hans.json +5 -5
- package/locales/pictures/zh-Hant.json +6 -6
- package/locales/pl.json +42 -20
- package/locales/plan/fr-CA.json +1 -1
- package/locales/plan/fr.json +1 -1
- package/locales/plan/it.json +2 -2
- package/locales/plan/ja.json +3 -3
- package/locales/plan/zh-Hans.json +2 -2
- package/locales/plan/zh-Hant.json +1 -1
- package/locales/policy/am.json +1 -0
- package/locales/policy/ar.json +1 -0
- package/locales/policy/bg.json +1 -0
- package/locales/policy/bn.json +1 -0
- package/locales/policy/br.json +1 -0
- package/locales/policy/co.json +3 -2
- package/locales/policy/cs.json +1 -0
- package/locales/policy/da.json +1 -0
- package/locales/policy/de.json +1 -0
- package/locales/policy/el.json +1 -0
- package/locales/policy/en.json +1 -0
- package/locales/policy/es.json +4 -3
- package/locales/policy/fa.json +1 -0
- package/locales/policy/fi.json +1 -0
- package/locales/policy/fr-CA.json +2 -1
- package/locales/policy/fr.json +2 -1
- package/locales/policy/ha.json +1 -0
- package/locales/policy/he.json +1 -0
- package/locales/policy/hi.json +1 -0
- package/locales/policy/hr.json +1 -0
- package/locales/policy/hu.json +1 -0
- package/locales/policy/id.json +1 -0
- package/locales/policy/it.json +4 -3
- package/locales/policy/ja.json +3 -2
- package/locales/policy/ko.json +1 -0
- package/locales/policy/mr.json +1 -0
- package/locales/policy/ms.json +1 -0
- package/locales/policy/nl.json +1 -0
- package/locales/policy/pl.json +1 -0
- package/locales/policy/pt.json +4 -3
- package/locales/policy/ro.json +1 -0
- package/locales/policy/ru.json +1 -0
- package/locales/policy/sk.json +1 -0
- package/locales/policy/sv.json +1 -0
- package/locales/policy/sw.json +1 -0
- package/locales/policy/ta.json +1 -0
- package/locales/policy/te.json +1 -0
- package/locales/policy/th.json +1 -0
- package/locales/policy/tl.json +1 -0
- package/locales/policy/tr.json +1 -0
- package/locales/policy/uk.json +1 -0
- package/locales/policy/ur.json +1 -0
- package/locales/policy/vi.json +1 -0
- package/locales/policy/yo.json +1 -0
- package/locales/policy/zh-Hans.json +9 -8
- package/locales/policy/zh-Hant.json +17 -16
- package/locales/profiles/am.json +5 -0
- package/locales/profiles/ar.json +5 -0
- package/locales/profiles/bg.json +5 -0
- package/locales/profiles/bn.json +5 -0
- package/locales/profiles/br.json +14 -9
- package/locales/profiles/co.json +12 -7
- package/locales/profiles/cs.json +5 -0
- package/locales/profiles/da.json +5 -0
- package/locales/profiles/de.json +6 -1
- package/locales/profiles/el.json +5 -0
- package/locales/profiles/en.json +7 -2
- package/locales/profiles/es.json +7 -2
- package/locales/profiles/fa.json +5 -0
- package/locales/profiles/fi.json +5 -0
- package/locales/profiles/fr-CA.json +10 -5
- package/locales/profiles/fr.json +10 -5
- package/locales/profiles/ha.json +5 -0
- package/locales/profiles/he.json +5 -0
- package/locales/profiles/hi.json +5 -0
- package/locales/profiles/hr.json +5 -0
- package/locales/profiles/hu.json +5 -0
- package/locales/profiles/id.json +5 -0
- package/locales/profiles/it.json +11 -6
- package/locales/profiles/ja.json +13 -8
- package/locales/profiles/ko.json +25 -20
- package/locales/profiles/mr.json +5 -0
- package/locales/profiles/ms.json +5 -0
- package/locales/profiles/nl.json +5 -0
- package/locales/profiles/pl.json +5 -0
- package/locales/profiles/pt.json +10 -5
- package/locales/profiles/ro.json +5 -0
- package/locales/profiles/ru.json +5 -0
- package/locales/profiles/sk.json +5 -0
- package/locales/profiles/sv.json +5 -0
- package/locales/profiles/sw.json +5 -0
- package/locales/profiles/ta.json +5 -0
- package/locales/profiles/te.json +5 -0
- package/locales/profiles/th.json +5 -0
- package/locales/profiles/tl.json +5 -0
- package/locales/profiles/tr.json +5 -0
- package/locales/profiles/uk.json +5 -0
- package/locales/profiles/ur.json +5 -0
- package/locales/profiles/vi.json +5 -0
- package/locales/profiles/yo.json +5 -0
- package/locales/profiles/zh-Hans.json +18 -13
- package/locales/profiles/zh-Hant.json +13 -8
- package/locales/projects/am.json +4 -0
- package/locales/projects/ar.json +4 -0
- package/locales/projects/bg.json +4 -0
- package/locales/projects/bn.json +4 -0
- package/locales/projects/br.json +4 -0
- package/locales/projects/co.json +4 -0
- package/locales/projects/cs.json +4 -0
- package/locales/projects/da.json +4 -0
- package/locales/projects/de.json +4 -0
- package/locales/projects/el.json +4 -0
- package/locales/projects/en.json +4 -0
- package/locales/projects/es.json +4 -0
- package/locales/projects/fa.json +4 -0
- package/locales/projects/fi.json +4 -0
- package/locales/projects/fr-CA.json +4 -0
- package/locales/projects/fr.json +4 -0
- package/locales/projects/ha.json +4 -0
- package/locales/projects/he.json +4 -0
- package/locales/projects/hi.json +4 -0
- package/locales/projects/hr.json +4 -0
- package/locales/projects/hu.json +4 -0
- package/locales/projects/id.json +4 -0
- package/locales/projects/it.json +4 -0
- package/locales/projects/ja.json +4 -0
- package/locales/projects/ko.json +4 -0
- package/locales/projects/mr.json +4 -0
- package/locales/projects/ms.json +4 -0
- package/locales/projects/nl.json +4 -0
- package/locales/projects/pl.json +4 -0
- package/locales/projects/pt.json +4 -0
- package/locales/projects/ro.json +4 -0
- package/locales/projects/ru.json +4 -0
- package/locales/projects/sk.json +4 -0
- package/locales/projects/sv.json +4 -0
- package/locales/projects/sw.json +4 -0
- package/locales/projects/ta.json +4 -0
- package/locales/projects/te.json +4 -0
- package/locales/projects/th.json +4 -0
- package/locales/projects/tl.json +4 -0
- package/locales/projects/tr.json +4 -0
- package/locales/projects/uk.json +4 -0
- package/locales/projects/ur.json +4 -0
- package/locales/projects/vi.json +4 -0
- package/locales/projects/yo.json +4 -0
- package/locales/projects/zh-Hans.json +4 -0
- package/locales/projects/zh-Hant.json +4 -0
- package/locales/pt.json +65 -44
- package/locales/receipt/am.json +14 -1
- package/locales/receipt/ar.json +14 -1
- package/locales/receipt/bg.json +14 -1
- package/locales/receipt/bn.json +14 -1
- package/locales/receipt/br.json +16 -3
- package/locales/receipt/co.json +16 -3
- package/locales/receipt/cs.json +14 -1
- package/locales/receipt/da.json +14 -1
- package/locales/receipt/de.json +16 -3
- package/locales/receipt/el.json +14 -1
- package/locales/receipt/en.json +16 -3
- package/locales/receipt/es.json +19 -6
- package/locales/receipt/fa.json +14 -1
- package/locales/receipt/fi.json +14 -1
- package/locales/receipt/fr-CA.json +16 -3
- package/locales/receipt/fr.json +16 -3
- package/locales/receipt/ha.json +14 -1
- package/locales/receipt/he.json +14 -1
- package/locales/receipt/hi.json +14 -1
- package/locales/receipt/hr.json +14 -1
- package/locales/receipt/hu.json +14 -1
- package/locales/receipt/id.json +14 -1
- package/locales/receipt/it.json +21 -8
- package/locales/receipt/ja.json +19 -6
- package/locales/receipt/ko.json +15 -2
- package/locales/receipt/mr.json +14 -1
- package/locales/receipt/ms.json +14 -1
- package/locales/receipt/nl.json +14 -1
- package/locales/receipt/pl.json +14 -1
- package/locales/receipt/pt.json +18 -5
- package/locales/receipt/ro.json +14 -1
- package/locales/receipt/ru.json +14 -1
- package/locales/receipt/sk.json +14 -1
- package/locales/receipt/sv.json +14 -1
- package/locales/receipt/sw.json +14 -1
- package/locales/receipt/ta.json +14 -1
- package/locales/receipt/te.json +14 -1
- package/locales/receipt/th.json +14 -1
- package/locales/receipt/tl.json +14 -1
- package/locales/receipt/tr.json +14 -1
- package/locales/receipt/uk.json +14 -1
- package/locales/receipt/ur.json +14 -1
- package/locales/receipt/vi.json +14 -1
- package/locales/receipt/yo.json +14 -1
- package/locales/receipt/zh-Hans.json +17 -4
- package/locales/receipt/zh-Hant.json +25 -12
- package/locales/ro.json +42 -21
- package/locales/routines/am.json +2 -0
- package/locales/routines/ar.json +2 -0
- package/locales/routines/bg.json +2 -0
- package/locales/routines/bn.json +2 -0
- package/locales/routines/br.json +12 -10
- package/locales/routines/co.json +8 -6
- package/locales/routines/cs.json +2 -0
- package/locales/routines/da.json +2 -0
- package/locales/routines/de.json +2 -0
- package/locales/routines/el.json +2 -0
- package/locales/routines/en.json +2 -0
- package/locales/routines/es.json +6 -4
- package/locales/routines/fa.json +2 -0
- package/locales/routines/fi.json +2 -0
- package/locales/routines/fr-CA.json +4 -2
- package/locales/routines/fr.json +4 -2
- package/locales/routines/ha.json +2 -0
- package/locales/routines/he.json +2 -0
- package/locales/routines/hi.json +2 -0
- package/locales/routines/hr.json +2 -0
- package/locales/routines/hu.json +2 -0
- package/locales/routines/id.json +2 -0
- package/locales/routines/it.json +3 -1
- package/locales/routines/ja.json +14 -12
- package/locales/routines/ko.json +3 -1
- package/locales/routines/mr.json +2 -0
- package/locales/routines/ms.json +2 -0
- package/locales/routines/nl.json +2 -0
- package/locales/routines/pl.json +2 -0
- package/locales/routines/pt.json +7 -5
- package/locales/routines/ro.json +2 -0
- package/locales/routines/ru.json +2 -0
- package/locales/routines/sk.json +2 -0
- package/locales/routines/sv.json +2 -0
- package/locales/routines/sw.json +2 -0
- package/locales/routines/ta.json +2 -0
- package/locales/routines/te.json +2 -0
- package/locales/routines/th.json +2 -0
- package/locales/routines/tl.json +2 -0
- package/locales/routines/tr.json +2 -0
- package/locales/routines/uk.json +2 -0
- package/locales/routines/ur.json +2 -0
- package/locales/routines/vi.json +2 -0
- package/locales/routines/yo.json +2 -0
- package/locales/routines/zh-Hans.json +4 -2
- package/locales/routines/zh-Hant.json +5 -3
- package/locales/ru.json +42 -20
- package/locales/scores/am.json +3 -9
- package/locales/scores/ar.json +3 -9
- package/locales/scores/bg.json +3 -9
- package/locales/scores/bn.json +3 -9
- package/locales/scores/br.json +3 -9
- package/locales/scores/co.json +3 -9
- package/locales/scores/cs.json +3 -9
- package/locales/scores/da.json +3 -9
- package/locales/scores/de.json +4 -10
- package/locales/scores/el.json +3 -9
- package/locales/scores/en.json +3 -9
- package/locales/scores/es.json +3 -9
- package/locales/scores/fa.json +3 -9
- package/locales/scores/fi.json +3 -9
- package/locales/scores/fr-CA.json +3 -9
- package/locales/scores/fr.json +3 -9
- package/locales/scores/ha.json +3 -9
- package/locales/scores/he.json +3 -9
- package/locales/scores/hi.json +3 -9
- package/locales/scores/hr.json +3 -9
- package/locales/scores/hu.json +3 -9
- package/locales/scores/id.json +3 -9
- package/locales/scores/it.json +4 -10
- package/locales/scores/ja.json +4 -10
- package/locales/scores/ko.json +4 -10
- package/locales/scores/mr.json +3 -9
- package/locales/scores/ms.json +3 -9
- package/locales/scores/nl.json +3 -9
- package/locales/scores/pl.json +3 -9
- package/locales/scores/pt.json +3 -9
- package/locales/scores/ro.json +3 -9
- package/locales/scores/ru.json +3 -9
- package/locales/scores/sk.json +3 -9
- package/locales/scores/sv.json +3 -9
- package/locales/scores/sw.json +3 -9
- package/locales/scores/ta.json +3 -9
- package/locales/scores/te.json +3 -9
- package/locales/scores/th.json +3 -9
- package/locales/scores/tl.json +3 -9
- package/locales/scores/tr.json +3 -9
- package/locales/scores/uk.json +3 -9
- package/locales/scores/ur.json +3 -9
- package/locales/scores/vi.json +3 -9
- package/locales/scores/yo.json +3 -9
- package/locales/scores/zh-Hans.json +3 -9
- package/locales/scores/zh-Hant.json +3 -9
- package/locales/screen/am.json +11 -0
- package/locales/screen/ar.json +11 -0
- package/locales/screen/bg.json +11 -0
- package/locales/screen/bn.json +11 -0
- package/locales/screen/br.json +11 -0
- package/locales/screen/co.json +11 -0
- package/locales/screen/cs.json +11 -0
- package/locales/screen/da.json +11 -0
- package/locales/screen/de.json +11 -0
- package/locales/screen/el.json +11 -0
- package/locales/screen/en.json +11 -0
- package/locales/screen/es.json +11 -0
- package/locales/screen/fa.json +11 -0
- package/locales/screen/fi.json +11 -0
- package/locales/screen/fr-CA.json +11 -0
- package/locales/screen/fr.json +11 -0
- package/locales/screen/ha.json +11 -0
- package/locales/screen/he.json +11 -0
- package/locales/screen/hi.json +11 -0
- package/locales/screen/hr.json +11 -0
- package/locales/screen/hu.json +11 -0
- package/locales/screen/id.json +11 -0
- package/locales/screen/it.json +11 -0
- package/locales/screen/ja.json +11 -0
- package/locales/screen/ko.json +11 -0
- package/locales/screen/mr.json +11 -0
- package/locales/screen/ms.json +11 -0
- package/locales/screen/nl.json +11 -0
- package/locales/screen/pl.json +11 -0
- package/locales/screen/pt.json +11 -0
- package/locales/screen/ro.json +11 -0
- package/locales/screen/ru.json +11 -0
- package/locales/screen/sk.json +11 -0
- package/locales/screen/sv.json +11 -0
- package/locales/screen/sw.json +11 -0
- package/locales/screen/ta.json +11 -0
- package/locales/screen/te.json +11 -0
- package/locales/screen/th.json +11 -0
- package/locales/screen/tl.json +11 -0
- package/locales/screen/tr.json +11 -0
- package/locales/screen/uk.json +11 -0
- package/locales/screen/ur.json +11 -0
- package/locales/screen/vi.json +11 -0
- package/locales/screen/yo.json +11 -0
- package/locales/screen/zh-Hans.json +11 -0
- package/locales/screen/zh-Hant.json +11 -0
- package/locales/share/br.json +6 -6
- package/locales/share/co.json +4 -4
- package/locales/share/de.json +2 -2
- package/locales/share/es.json +1 -1
- package/locales/share/fr-CA.json +5 -5
- package/locales/share/fr.json +3 -3
- package/locales/share/it.json +4 -4
- package/locales/share/ja.json +15 -15
- package/locales/share/ko.json +4 -4
- package/locales/share/pt.json +2 -2
- package/locales/share/zh-Hans.json +8 -8
- package/locales/share/zh-Hant.json +14 -14
- package/locales/signin/am.json +3 -1
- package/locales/signin/ar.json +3 -1
- package/locales/signin/bg.json +3 -1
- package/locales/signin/bn.json +3 -1
- package/locales/signin/br.json +3 -1
- package/locales/signin/co.json +3 -1
- package/locales/signin/cs.json +3 -1
- package/locales/signin/da.json +3 -1
- package/locales/signin/de.json +3 -1
- package/locales/signin/el.json +3 -1
- package/locales/signin/en.json +3 -1
- package/locales/signin/es.json +4 -2
- package/locales/signin/fa.json +3 -1
- package/locales/signin/fi.json +3 -1
- package/locales/signin/fr-CA.json +3 -1
- package/locales/signin/fr.json +3 -1
- package/locales/signin/ha.json +3 -1
- package/locales/signin/he.json +3 -1
- package/locales/signin/hi.json +3 -1
- package/locales/signin/hr.json +3 -1
- package/locales/signin/hu.json +3 -1
- package/locales/signin/id.json +3 -1
- package/locales/signin/it.json +3 -1
- package/locales/signin/ja.json +3 -1
- package/locales/signin/ko.json +3 -1
- package/locales/signin/mr.json +3 -1
- package/locales/signin/ms.json +3 -1
- package/locales/signin/nl.json +3 -1
- package/locales/signin/pl.json +3 -1
- package/locales/signin/pt.json +3 -1
- package/locales/signin/ro.json +3 -1
- package/locales/signin/ru.json +3 -1
- package/locales/signin/sk.json +3 -1
- package/locales/signin/sv.json +3 -1
- package/locales/signin/sw.json +3 -1
- package/locales/signin/ta.json +3 -1
- package/locales/signin/te.json +3 -1
- package/locales/signin/th.json +3 -1
- package/locales/signin/tl.json +3 -1
- package/locales/signin/tr.json +3 -1
- package/locales/signin/uk.json +3 -1
- package/locales/signin/ur.json +3 -1
- package/locales/signin/vi.json +3 -1
- package/locales/signin/yo.json +3 -1
- package/locales/signin/zh-Hans.json +3 -1
- package/locales/signin/zh-Hant.json +3 -1
- package/locales/sites/am.json +48 -0
- package/locales/sites/ar.json +52 -0
- package/locales/sites/bg.json +48 -0
- package/locales/sites/bn.json +48 -0
- package/locales/sites/br.json +51 -0
- package/locales/sites/co.json +49 -0
- package/locales/sites/cs.json +50 -0
- package/locales/sites/da.json +48 -0
- package/locales/sites/de.json +48 -0
- package/locales/sites/el.json +48 -0
- package/locales/sites/en.json +48 -0
- package/locales/sites/es.json +49 -0
- package/locales/sites/fa.json +48 -0
- package/locales/sites/fi.json +48 -0
- package/locales/sites/fr-CA.json +49 -0
- package/locales/sites/fr.json +49 -0
- package/locales/sites/ha.json +48 -0
- package/locales/sites/he.json +49 -0
- package/locales/sites/hi.json +48 -0
- package/locales/sites/hr.json +49 -0
- package/locales/sites/hu.json +48 -0
- package/locales/sites/id.json +47 -0
- package/locales/sites/it.json +49 -0
- package/locales/sites/ja.json +47 -0
- package/locales/sites/ko.json +47 -0
- package/locales/sites/mr.json +48 -0
- package/locales/sites/ms.json +47 -0
- package/locales/sites/nl.json +48 -0
- package/locales/sites/pl.json +50 -0
- package/locales/sites/pt.json +49 -0
- package/locales/sites/ro.json +49 -0
- package/locales/sites/ru.json +50 -0
- package/locales/sites/sk.json +50 -0
- package/locales/sites/sv.json +48 -0
- package/locales/sites/sw.json +48 -0
- package/locales/sites/ta.json +48 -0
- package/locales/sites/te.json +48 -0
- package/locales/sites/th.json +47 -0
- package/locales/sites/tl.json +48 -0
- package/locales/sites/tr.json +48 -0
- package/locales/sites/uk.json +50 -0
- package/locales/sites/ur.json +48 -0
- package/locales/sites/vi.json +47 -0
- package/locales/sites/yo.json +47 -0
- package/locales/sites/zh-Hans.json +47 -0
- package/locales/sites/zh-Hant.json +47 -0
- package/locales/sk.json +43 -21
- package/locales/skills/am.json +1 -0
- package/locales/skills/ar.json +1 -0
- package/locales/skills/bg.json +1 -0
- package/locales/skills/bn.json +1 -0
- package/locales/skills/br.json +8 -7
- package/locales/skills/co.json +8 -7
- package/locales/skills/cs.json +1 -0
- package/locales/skills/da.json +1 -0
- package/locales/skills/de.json +6 -5
- package/locales/skills/el.json +1 -0
- package/locales/skills/en.json +1 -0
- package/locales/skills/es.json +5 -4
- package/locales/skills/fa.json +1 -0
- package/locales/skills/fi.json +1 -0
- package/locales/skills/fr-CA.json +4 -3
- package/locales/skills/fr.json +4 -3
- package/locales/skills/ha.json +1 -0
- package/locales/skills/he.json +1 -0
- package/locales/skills/hi.json +1 -0
- package/locales/skills/hr.json +1 -0
- package/locales/skills/hu.json +1 -0
- package/locales/skills/id.json +1 -0
- package/locales/skills/it.json +2 -1
- package/locales/skills/ja.json +17 -16
- package/locales/skills/ko.json +2 -1
- package/locales/skills/mr.json +1 -0
- package/locales/skills/ms.json +1 -0
- package/locales/skills/nl.json +1 -0
- package/locales/skills/pl.json +1 -0
- package/locales/skills/pt.json +6 -5
- package/locales/skills/ro.json +1 -0
- package/locales/skills/ru.json +1 -0
- package/locales/skills/sk.json +1 -0
- package/locales/skills/sv.json +1 -0
- package/locales/skills/sw.json +1 -0
- package/locales/skills/ta.json +1 -0
- package/locales/skills/te.json +1 -0
- package/locales/skills/th.json +1 -0
- package/locales/skills/tl.json +1 -0
- package/locales/skills/tr.json +1 -0
- package/locales/skills/uk.json +1 -0
- package/locales/skills/ur.json +1 -0
- package/locales/skills/vi.json +1 -0
- package/locales/skills/yo.json +1 -0
- package/locales/skills/zh-Hans.json +3 -2
- package/locales/skills/zh-Hant.json +5 -4
- package/locales/slides/am.json +16 -11
- package/locales/slides/ar.json +16 -11
- package/locales/slides/bg.json +16 -11
- package/locales/slides/bn.json +16 -11
- package/locales/slides/br.json +26 -21
- package/locales/slides/co.json +41 -36
- package/locales/slides/cs.json +16 -11
- package/locales/slides/da.json +16 -11
- package/locales/slides/de.json +16 -11
- package/locales/slides/el.json +16 -11
- package/locales/slides/en.json +20 -15
- package/locales/slides/es.json +21 -16
- package/locales/slides/fa.json +16 -11
- package/locales/slides/fi.json +16 -11
- package/locales/slides/fr-CA.json +16 -11
- package/locales/slides/fr.json +16 -11
- package/locales/slides/ha.json +16 -11
- package/locales/slides/he.json +16 -11
- package/locales/slides/hi.json +16 -11
- package/locales/slides/hr.json +16 -11
- package/locales/slides/hu.json +16 -11
- package/locales/slides/id.json +16 -11
- package/locales/slides/it.json +20 -15
- package/locales/slides/ja.json +21 -16
- package/locales/slides/ko.json +29 -24
- package/locales/slides/mr.json +16 -11
- package/locales/slides/ms.json +16 -11
- package/locales/slides/nl.json +16 -11
- package/locales/slides/pl.json +16 -11
- package/locales/slides/pt.json +23 -18
- package/locales/slides/ro.json +16 -11
- package/locales/slides/ru.json +16 -11
- package/locales/slides/sk.json +16 -11
- package/locales/slides/sv.json +16 -11
- package/locales/slides/sw.json +16 -11
- package/locales/slides/ta.json +16 -11
- package/locales/slides/te.json +16 -11
- package/locales/slides/th.json +16 -11
- package/locales/slides/tl.json +16 -11
- package/locales/slides/tr.json +16 -11
- package/locales/slides/uk.json +16 -11
- package/locales/slides/ur.json +16 -11
- package/locales/slides/vi.json +16 -11
- package/locales/slides/yo.json +16 -11
- package/locales/slides/zh-Hans.json +20 -15
- package/locales/slides/zh-Hant.json +19 -14
- package/locales/sv.json +40 -20
- package/locales/sw.json +40 -20
- package/locales/sync/br.json +2 -2
- package/locales/sync/de.json +2 -2
- package/locales/sync/es.json +6 -6
- package/locales/sync/it.json +1 -1
- package/locales/sync/ja.json +2 -2
- package/locales/sync/pt.json +1 -1
- package/locales/ta.json +40 -20
- package/locales/tables/am.json +20 -0
- package/locales/tables/ar.json +28 -0
- package/locales/tables/bg.json +20 -0
- package/locales/tables/bn.json +20 -0
- package/locales/tables/br.json +32 -6
- package/locales/tables/co.json +32 -10
- package/locales/tables/cs.json +24 -0
- package/locales/tables/da.json +20 -0
- package/locales/tables/de.json +22 -2
- package/locales/tables/el.json +20 -0
- package/locales/tables/en.json +20 -0
- package/locales/tables/es.json +22 -0
- package/locales/tables/fa.json +20 -0
- package/locales/tables/fi.json +20 -0
- package/locales/tables/fr-CA.json +24 -2
- package/locales/tables/fr.json +23 -1
- package/locales/tables/ha.json +20 -0
- package/locales/tables/he.json +22 -0
- package/locales/tables/hi.json +20 -0
- package/locales/tables/hr.json +22 -0
- package/locales/tables/hu.json +20 -0
- package/locales/tables/id.json +18 -0
- package/locales/tables/it.json +22 -0
- package/locales/tables/ja.json +19 -1
- package/locales/tables/ko.json +22 -4
- package/locales/tables/mr.json +20 -0
- package/locales/tables/ms.json +18 -0
- package/locales/tables/nl.json +20 -0
- package/locales/tables/pl.json +24 -0
- package/locales/tables/pt.json +26 -4
- package/locales/tables/ro.json +22 -0
- package/locales/tables/ru.json +24 -0
- package/locales/tables/sk.json +24 -0
- package/locales/tables/sv.json +20 -0
- package/locales/tables/sw.json +20 -0
- package/locales/tables/ta.json +20 -0
- package/locales/tables/te.json +20 -0
- package/locales/tables/th.json +18 -0
- package/locales/tables/tl.json +20 -0
- package/locales/tables/tr.json +20 -0
- package/locales/tables/uk.json +24 -0
- package/locales/tables/ur.json +20 -0
- package/locales/tables/vi.json +18 -0
- package/locales/tables/yo.json +18 -0
- package/locales/tables/zh-Hans.json +19 -1
- package/locales/tables/zh-Hant.json +19 -1
- package/locales/te.json +40 -20
- package/locales/th.json +39 -20
- package/locales/tl.json +40 -20
- package/locales/tr.json +40 -20
- package/locales/uk.json +42 -20
- package/locales/ur.json +40 -20
- package/locales/vi.json +39 -20
- package/locales/{search → web-search}/am.json +10 -1
- package/locales/{search → web-search}/ar.json +10 -1
- package/locales/{search → web-search}/bg.json +10 -1
- package/locales/{search → web-search}/bn.json +10 -1
- package/locales/{search → web-search}/br.json +14 -5
- package/locales/{search → web-search}/co.json +14 -5
- package/locales/{search → web-search}/cs.json +10 -1
- package/locales/{search → web-search}/da.json +10 -1
- package/locales/{search → web-search}/de.json +10 -1
- package/locales/{search → web-search}/el.json +10 -1
- package/locales/{search → web-search}/en.json +10 -1
- package/locales/{search → web-search}/es.json +13 -4
- package/locales/{search → web-search}/fa.json +10 -1
- package/locales/{search → web-search}/fi.json +10 -1
- package/locales/{search → web-search}/fr-CA.json +10 -1
- package/locales/{search → web-search}/fr.json +10 -1
- package/locales/{search → web-search}/ha.json +10 -1
- package/locales/{search → web-search}/he.json +10 -1
- package/locales/{search → web-search}/hi.json +10 -1
- package/locales/{search → web-search}/hr.json +10 -1
- package/locales/{search → web-search}/hu.json +10 -1
- package/locales/{search → web-search}/id.json +10 -1
- package/locales/{search → web-search}/it.json +10 -1
- package/locales/{search → web-search}/ja.json +15 -6
- package/locales/{search → web-search}/ko.json +10 -1
- package/locales/{search → web-search}/mr.json +10 -1
- package/locales/{search → web-search}/ms.json +10 -1
- package/locales/{search → web-search}/nl.json +10 -1
- package/locales/{search → web-search}/pl.json +10 -1
- package/locales/{search → web-search}/pt.json +10 -1
- package/locales/{search → web-search}/ro.json +10 -1
- package/locales/{search → web-search}/ru.json +10 -1
- package/locales/{search → web-search}/sk.json +10 -1
- package/locales/{search → web-search}/sv.json +10 -1
- package/locales/{search → web-search}/sw.json +10 -1
- package/locales/{search → web-search}/ta.json +10 -1
- package/locales/{search → web-search}/te.json +10 -1
- package/locales/{search → web-search}/th.json +10 -1
- package/locales/{search → web-search}/tl.json +10 -1
- package/locales/{search → web-search}/tr.json +10 -1
- package/locales/{search → web-search}/uk.json +10 -1
- package/locales/{search → web-search}/ur.json +10 -1
- package/locales/{search → web-search}/vi.json +10 -1
- package/locales/{search → web-search}/yo.json +10 -1
- package/locales/{search → web-search}/zh-Hans.json +12 -3
- package/locales/web-search/zh-Hant.json +55 -0
- package/locales/yo.json +39 -20
- package/locales/you/br.json +13 -13
- package/locales/you/co.json +2 -2
- package/locales/you/de.json +1 -1
- package/locales/you/en.json +1 -1
- package/locales/you/es.json +2 -2
- package/locales/you/fr-CA.json +3 -3
- package/locales/you/fr.json +3 -3
- package/locales/you/it.json +10 -10
- package/locales/you/ja.json +9 -9
- package/locales/you/pt.json +11 -11
- package/locales/you/zh-Hans.json +3 -3
- package/locales/you/zh-Hant.json +3 -3
- package/locales/zh-Hans.json +58 -39
- package/locales/zh-Hant.json +68 -49
- package/package.json +1 -1
- package/preview.html +8 -2
- package/ui/base.js +33 -0
- package/ui/caps.js +12 -5
- package/ui/csp.js +1 -1
- package/ui/export.js +2 -2
- package/ui/icons.js +4 -4
- package/ui/kit.js +49 -13
- package/ui/language.js +172 -0
- package/ui/looks/classic.css +3 -1
- package/ui/looks/human.css +6 -5
- package/ui/looks/mail.css +1 -1
- package/ui/looks.js +3 -6
- package/ui/markdown.js +36 -21
- package/ui/menu-icons.js +9 -5
- package/ui/model.js +4 -4
- package/ui/pointed.js +22 -0
- package/ui/reader-state.js +5 -4
- package/ui/reader.js +1 -1
- package/ui/review.js +1 -1
- package/ui/save.js +16 -0
- package/ui/seal.js +67 -6
- package/ui/sheet.js +21 -2
- package/ui/shown.js +53 -0
- package/ui/style.css +58 -39
- package/ui/touches.js +26 -1
- package/ui/view.css +27 -1
- package/ui/view.js +44 -21
- package/vendor/deck/deck.css +2 -2
- package/vendor/deck/deck.mjs +37 -37
- package/vendor/deck/pptx.mjs +1 -1
- package/vendor/pele/lazy.d.ts +1 -0
- package/locales/reader/ja.json +0 -9
- package/locales/search/zh-Hant.json +0 -46
- package/ui/acts.js +0 -12
- package/ui/looks/mondrian.css +0 -90
- package/ui/looks/paper.css +0 -51
- /package/locales/{reader → natural-voice}/am.json +0 -0
- /package/locales/{reader → natural-voice}/ar.json +0 -0
- /package/locales/{reader → natural-voice}/bg.json +0 -0
- /package/locales/{reader → natural-voice}/bn.json +0 -0
- /package/locales/{reader → natural-voice}/br.json +0 -0
- /package/locales/{reader → natural-voice}/co.json +0 -0
- /package/locales/{reader → natural-voice}/cs.json +0 -0
- /package/locales/{reader → natural-voice}/da.json +0 -0
- /package/locales/{reader → natural-voice}/de.json +0 -0
- /package/locales/{reader → natural-voice}/el.json +0 -0
- /package/locales/{reader → natural-voice}/en.json +0 -0
- /package/locales/{reader → natural-voice}/fa.json +0 -0
- /package/locales/{reader → natural-voice}/fi.json +0 -0
- /package/locales/{reader → natural-voice}/fr-CA.json +0 -0
- /package/locales/{reader → natural-voice}/fr.json +0 -0
- /package/locales/{reader → natural-voice}/ha.json +0 -0
- /package/locales/{reader → natural-voice}/he.json +0 -0
- /package/locales/{reader → natural-voice}/hi.json +0 -0
- /package/locales/{reader → natural-voice}/hr.json +0 -0
- /package/locales/{reader → natural-voice}/hu.json +0 -0
- /package/locales/{reader → natural-voice}/id.json +0 -0
- /package/locales/{reader → natural-voice}/it.json +0 -0
- /package/locales/{reader → natural-voice}/ko.json +0 -0
- /package/locales/{reader → natural-voice}/mr.json +0 -0
- /package/locales/{reader → natural-voice}/ms.json +0 -0
- /package/locales/{reader → natural-voice}/nl.json +0 -0
- /package/locales/{reader → natural-voice}/pl.json +0 -0
- /package/locales/{reader → natural-voice}/pt.json +0 -0
- /package/locales/{reader → natural-voice}/ro.json +0 -0
- /package/locales/{reader → natural-voice}/ru.json +0 -0
- /package/locales/{reader → natural-voice}/sk.json +0 -0
- /package/locales/{reader → natural-voice}/sv.json +0 -0
- /package/locales/{reader → natural-voice}/sw.json +0 -0
- /package/locales/{reader → natural-voice}/ta.json +0 -0
- /package/locales/{reader → natural-voice}/te.json +0 -0
- /package/locales/{reader → natural-voice}/th.json +0 -0
- /package/locales/{reader → natural-voice}/tl.json +0 -0
- /package/locales/{reader → natural-voice}/tr.json +0 -0
- /package/locales/{reader → natural-voice}/uk.json +0 -0
- /package/locales/{reader → natural-voice}/ur.json +0 -0
- /package/locales/{reader → natural-voice}/vi.json +0 -0
- /package/locales/{reader → natural-voice}/yo.json +0 -0
|
@@ -5,6 +5,7 @@
|
|
|
5
5
|
// in the room's colours (or a deck's) as Pele's own properties inside it, its words the picture's text. <app-diagram> draws
|
|
6
6
|
// one in an answer or a file, one Pele can't read once whole saying so (`unread`); a page holds its own (./page-diagram.js),
|
|
7
7
|
// which asks Jean for the picture. Mermaid itself is a 1.6 MB library that needs a DOM.
|
|
8
|
+
import { t } from '../../core/i18n.js'
|
|
8
9
|
import { pictureOf } from '../../ui/save.js'
|
|
9
10
|
import { scriptURL } from '../../ui/trusted.js'
|
|
10
11
|
|
|
@@ -38,7 +39,7 @@ function box(rest) {
|
|
|
38
39
|
return [id, after]
|
|
39
40
|
}
|
|
40
41
|
|
|
41
|
-
/** Boxes joined by &, at the start of `rest
|
|
42
|
+
/** Boxes joined by &, at the start of `rest`, and what follows them. @param {string} rest @returns {[string[], string] | null} */
|
|
42
43
|
function group(rest) {
|
|
43
44
|
const found = []
|
|
44
45
|
for (let left = rest.trimStart(); ;) {
|
|
@@ -46,11 +47,28 @@ function group(rest) {
|
|
|
46
47
|
if (!next) return null
|
|
47
48
|
const named = /^:::\w+/.exec(next[1])?.[0] ?? '', rest = next[1].slice(named.length), more = /^\s*&\s*/.exec(rest)
|
|
48
49
|
found.push(next[0] + named)
|
|
49
|
-
if (!more) return [found
|
|
50
|
+
if (!more) return [found, rest]
|
|
50
51
|
left = rest.slice(more[0].length)
|
|
51
52
|
}
|
|
52
53
|
}
|
|
53
54
|
|
|
55
|
+
/** A flowchart's statement as boxes and the arrows between them; null for what this can't read, and what holds no box. @param {string} text */
|
|
56
|
+
function chain(text) {
|
|
57
|
+
if (!text.trim() || /^\s*(%%|(classDef|class|style|linkStyle|click|subgraph|end|direction)\b)/.test(text)) return null
|
|
58
|
+
let read = group(text)
|
|
59
|
+
if (!read) return null
|
|
60
|
+
const groups = [read[0]], arrows = []
|
|
61
|
+
for (let rest = read[1]; rest.trim();) {
|
|
62
|
+
const arrow = ARROW.exec(rest)
|
|
63
|
+
read = arrow && /[-=.]/.test(arrow[3]) ? group(rest.slice(arrow[0].length)) : null
|
|
64
|
+
if (!arrow || !read) return null
|
|
65
|
+
groups.push(read[0])
|
|
66
|
+
arrows.push(arrow)
|
|
67
|
+
rest = read[1]
|
|
68
|
+
}
|
|
69
|
+
return { groups, arrows, indent: /^\s*/.exec(text)?.[0] ?? '' }
|
|
70
|
+
}
|
|
71
|
+
|
|
54
72
|
/**
|
|
55
73
|
* A flowchart with its boxes and the words on its arrows written as Mermaid reads them; a statement this can't read, and any
|
|
56
74
|
* other kind of diagram, as it was.
|
|
@@ -63,29 +81,84 @@ export function mended(source) {
|
|
|
63
81
|
const statement = (/** @type {string} */ text) => {
|
|
64
82
|
const titled = /^(\s*subgraph\s+[\p{L}\p{N}_]+\s*)\[(.*)\]\s*$/u.exec(text)
|
|
65
83
|
if (titled) return `${titled[1]}[${quoted(titled[2])}]`
|
|
66
|
-
|
|
67
|
-
let read = group(text)
|
|
84
|
+
const read = chain(text)
|
|
68
85
|
if (!read) return text
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
if (!arrow || !to) return text
|
|
74
|
-
const words = arrow[4] ?? arrow[2]
|
|
75
|
-
out += ` ${arrow[1] === '-.' ? `-${arrow[3]}` : arrow[3]}${words ? `|${quoted(words)}|` : ''} ${to[0]}`
|
|
76
|
-
read = to
|
|
77
|
-
rest = to[1]
|
|
78
|
-
}
|
|
79
|
-
return out
|
|
86
|
+
return read.indent + read.groups.map((boxes, i) => {
|
|
87
|
+
const arrow = read.arrows[i - 1], words = arrow && (arrow[4] ?? arrow[2])
|
|
88
|
+
return `${arrow ? ` ${arrow[1] === '-.' ? `-${arrow[3]}` : arrow[3]}${words ? `|${quoted(words)}|` : ''} ` : ''}${boxes.join(' & ')}`
|
|
89
|
+
}).join('')
|
|
80
90
|
}
|
|
81
91
|
// What follows its first word and direction, on its first line too (graph LR; A --> B).
|
|
82
92
|
const mend = (/** @type {string} */ line) => line.split(';').map(statement).join(';')
|
|
83
93
|
return [head + mend(first.slice(head.length)), ...lines.map(mend)].join('\n')
|
|
84
94
|
}
|
|
85
95
|
|
|
86
|
-
/** The words a diagram shows,
|
|
87
|
-
|
|
88
|
-
.replace(/&(amp|lt|gt|quot|apos|#39);/g, (_, name) => ({ amp: '&', lt: '<', gt: '>', quot: '"' })[/** @type {'amp'} */ (name)] ?? "'").replace(/\s+/g, ' ').trim()).filter(Boolean)
|
|
96
|
+
/** The words a diagram shows, each on its own, in the order drawn. @param {string} svg */
|
|
97
|
+
const textsOf = (svg) => [...svg.matchAll(/<text\b[^>]*>([\s\S]*?)<\/text>/g)].map(([, inner]) => inner.replace(/<[^>]+>/g, ' ')
|
|
98
|
+
.replace(/&(amp|lt|gt|quot|apos|#39);/g, (_, name) => ({ amp: '&', lt: '<', gt: '>', quot: '"' })[/** @type {'amp'} */ (name)] ?? "'").replace(/\s+/g, ' ').trim()).filter(Boolean)
|
|
99
|
+
/** @param {string} svg */
|
|
100
|
+
export const wordsOf = (svg) => textsOf(svg).join(', ')
|
|
101
|
+
|
|
102
|
+
// An arrow of a sequence or a state diagram (Alice->>Bob: Hello, Idle --> Busy: start); a sequence's note; a name it gives one of them.
|
|
103
|
+
const ACROSS = /^\s*([^\s:<>-][^:<>]*?)\s*<*-{1,2}(?:>>?|\)|x)\s*[+-]?\s*([^:]+?)\s*(?::\s*(.*))?$/
|
|
104
|
+
const NOTE = /^\s*note\b[^:]*:\s*(.+)$/i
|
|
105
|
+
const ALIAS = /^\s*(?:participant|actor)\s+(\S+)\s+as\s+(.+)$/
|
|
106
|
+
|
|
107
|
+
/**
|
|
108
|
+
* What a diagram's arrows say, for those who can't see them: its boxes in the order written, each with what it leads to, an arrow's
|
|
109
|
+
* words first ("Yes: Take an umbrella"); a sequence's in turn, as a box may speak more than once. None for another kind of diagram.
|
|
110
|
+
* @param {string} source @returns {{ box: string, next: string[] }[]}
|
|
111
|
+
*/
|
|
112
|
+
export function stepsOf(source) {
|
|
113
|
+
const [first = '', ...lines] = source.split('\n'), steps = /** @type {{ box: string, next: string[] }[]} */ ([])
|
|
114
|
+
/** The step of a box: in a flowchart its one, in a sequence the last said if it is its. @param {string} box @param {boolean} [any] */
|
|
115
|
+
const step = (box, any) => (any ? steps.find((one) => one.box === box) : steps.at(-1)?.box === box && steps.at(-1)) || steps[steps.push({ box, next: [] }) - 1]
|
|
116
|
+
const head = /^\s*(flowchart|graph)\b[^;]*/i.exec(first)?.[0]
|
|
117
|
+
if (head) {
|
|
118
|
+
const chains = [first.slice(head.length), ...lines].flatMap((line) => line.split(';')).map(chain).filter((one) => one !== null), names = new Map()
|
|
119
|
+
for (const entry of chains.flatMap(({ groups }) => groups.flat())) {
|
|
120
|
+
const id = ID.exec(entry)?.[0], words = /"(.*)"/s.exec(entry)?.[1]
|
|
121
|
+
if (words || !names.has(id)) names.set(id, words?.replace(/#quot;/g, '"').replace(/<br\s*\/?>|\\n/gi, ' ') ?? id)
|
|
122
|
+
}
|
|
123
|
+
const name = (/** @type {string} */ entry) => names.get(ID.exec(entry)?.[0])
|
|
124
|
+
for (const { groups, arrows } of chains) {
|
|
125
|
+
for (const entry of groups.flat()) step(name(entry), true)
|
|
126
|
+
arrows.forEach((arrow, i) => { for (const from of groups[i]) for (const to of groups[i + 1]) step(name(from), true).next.push(`${(arrow[4] ?? arrow[2]) ? `${(arrow[4] ?? arrow[2]).trim().replace(/^"(.*)"$/, '$1')}: ` : ''}${name(to)}`) })
|
|
127
|
+
}
|
|
128
|
+
} else if (/^\s*(sequenceDiagram|stateDiagram)/.test(first)) {
|
|
129
|
+
const names = new Map(lines.map((line) => ALIAS.exec(line)).filter((one) => one !== null).map(([, id, name]) => [id, name.trim()]))
|
|
130
|
+
for (const line of lines) {
|
|
131
|
+
const note = NOTE.exec(line)?.[1], [, from, to, words] = ACROSS.exec(line) ?? []
|
|
132
|
+
if (note) steps.push({ box: note, next: [] })
|
|
133
|
+
else if (from && !`${from}${to}`.includes('[*]')) step(names.get(from) ?? from).next.push(`${words ? `${words}: ` : ''}${names.get(to) ?? to}`)
|
|
134
|
+
}
|
|
135
|
+
}
|
|
136
|
+
return steps
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
/**
|
|
140
|
+
* A diagram told in words: its picture's short text, which says that the words follow; what opens them; and them, its steps or, for a
|
|
141
|
+
* kind whose arrows this can't read, what it shows. @param {string} source @param {string} svg
|
|
142
|
+
*/
|
|
143
|
+
export function told(source, svg) {
|
|
144
|
+
const steps = stepsOf(source), first = steps[0]?.box
|
|
145
|
+
return steps.length ? { alt: t('interactive.diagramFrom', { first: first.length > 40 ? `${first.slice(0, 39)}…` : first }), summary: t('interactive.diagramSteps'), steps }
|
|
146
|
+
: { alt: t('interactive.diagramWords'), summary: t('interactive.inWords'), steps: textsOf(svg).map((box) => ({ box, next: [] })) }
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
/**
|
|
150
|
+
* Those words under the picture, folded, the opening in the person's language though the diagram's are its own.
|
|
151
|
+
* @param {ReturnType<typeof told>} words @param {boolean} [open]
|
|
152
|
+
*/
|
|
153
|
+
export function wordsBelow({ summary, steps }, open = false) {
|
|
154
|
+
const made = (/** @type {string} */ tag, /** @type {string} */ text = '') => Object.assign(document.createElement(tag), { textContent: text })
|
|
155
|
+
const list = (/** @type {{ box: string, next?: string[] }[]} */ items) => { const all = made('ul'); all.append(...items.map(({ box, next = [] }) => { const item = made('li', box); if (next.length) item.append(list(next.map((one) => ({ box: one })))); return item })); return all }
|
|
156
|
+
const held = /** @type {HTMLDetailsElement} */ (made('details')), head = made('summary', summary)
|
|
157
|
+
Object.assign(head, { lang: document.documentElement.lang, dir: document.documentElement.dir || 'ltr' })
|
|
158
|
+
Object.assign(held, { className: 'drawn-words', open })
|
|
159
|
+
held.append(head, list(steps))
|
|
160
|
+
return held
|
|
161
|
+
}
|
|
89
162
|
|
|
90
163
|
/** Pele's SVG in the colours given as its own properties (`fg`, `accent`, `series-1`…). @param {string} svg @param {Record<string, string>} props */
|
|
91
164
|
export const coloured = (svg, props) => svg.replace(/^(<svg\b[^>]*>)/, `$1<style>svg{${Object.entries(props).map(([name, value]) => `--pele-${name}:${value.replace(/[<>;{}"]/g, '')}`).join(';')}}</style>`)
|
|
@@ -93,7 +166,7 @@ export const coloured = (svg, props) => svg.replace(/^(<svg\b[^>]*>)/, `$1<style
|
|
|
93
166
|
/** The room's colours, as Pele names them: its ink and lines, and each of a chart's or a mind map's series a hue of its accent. @param {CSSStyleDeclaration} style */
|
|
94
167
|
function tones(style) {
|
|
95
168
|
const own = (/** @type {string} */ name) => style.getPropertyValue(`--${name}`).trim()
|
|
96
|
-
return { bg: 'transparent', fg: own('ink'), muted: own('ink-soft'), line: own('ink-soft'), surface: own('glass'), 'surface-alt': own('line'), border: own('
|
|
169
|
+
return { bg: 'transparent', fg: own('ink'), muted: own('ink-soft'), line: own('ink-soft'), surface: own('glass'), 'surface-alt': own('line'), border: own('ink-soft'), accent: own('flame'),
|
|
97
170
|
font: style.fontFamily, ...Object.fromEntries([0, 1, 2, 3, 4, 5, 6, 7].map((n) => [`series-${n + 1}`, `oklch(from ${own('flame')} l max(c, 0.12) calc(h + ${n * 57}))`])) }
|
|
98
171
|
}
|
|
99
172
|
|
|
@@ -101,7 +174,7 @@ function tones(style) {
|
|
|
101
174
|
let worker
|
|
102
175
|
let count = 0
|
|
103
176
|
const asked = /** @type {Map<number, { source: string, options: object, resolve: (drawn: Drawn) => void, reject: (error: Error) => void }>} */ (new Map())
|
|
104
|
-
/** Pele beside the page. @type {Promise<
|
|
177
|
+
/** Pele beside the page. @type {Promise<typeof import('pele/lazy')> | undefined} */
|
|
105
178
|
let here
|
|
106
179
|
|
|
107
180
|
/** Mermaid as Pele draws it. @param {string} source @param {object} options @returns {Promise<Drawn>} */
|
|
@@ -135,14 +208,14 @@ export const drawing = (source, options, rtl = false) => {
|
|
|
135
208
|
}
|
|
136
209
|
|
|
137
210
|
/**
|
|
138
|
-
* A diagram as a picture in an element's colours, at most as wide as given: its SVG and size, its address and
|
|
211
|
+
* A diagram as a picture in an element's colours, at most as wide as given: its SVG and size, its address, and it told in words.
|
|
139
212
|
* @param {string} source @param {Element} element @param {number} width
|
|
140
213
|
*/
|
|
141
214
|
export async function picture(source, element, width) {
|
|
142
215
|
const style = getComputedStyle(element)
|
|
143
216
|
const drawn = await drawing(source, { fontFamily: style.fontFamily, links: false, images: false, autoDirection: true, maxWidth: Math.max(320, width) }, style.direction === 'rtl')
|
|
144
217
|
const svg = coloured(drawn.svg, tones(style))
|
|
145
|
-
return { ...drawn, svg, url: `data:image/svg+xml;charset=utf-8,${encodeURIComponent(svg)}`, words:
|
|
218
|
+
return { ...drawn, svg, url: `data:image/svg+xml;charset=utf-8,${encodeURIComponent(svg)}`, words: told(source, drawn.svg) }
|
|
146
219
|
}
|
|
147
220
|
|
|
148
221
|
const AppDiagram = typeof HTMLElement === 'undefined' ? null : class extends HTMLElement {
|
|
@@ -177,7 +250,8 @@ const AppDiagram = typeof HTMLElement === 'undefined' ? null : class extends HTM
|
|
|
177
250
|
this.drawn = key
|
|
178
251
|
try {
|
|
179
252
|
const drawn = (this.shown = await picture(source, this, this.clientWidth))
|
|
180
|
-
|
|
253
|
+
// Its words once it is whole, folded as they were if the room drew it again.
|
|
254
|
+
this.replaceChildren(Object.assign(document.createElement('img'), { src: drawn.url, alt: drawn.words.alt, lang: document.documentElement.lang }), ...(open ? [] : [wordsBelow(drawn.words, this.querySelector('details')?.open)]))
|
|
181
255
|
} catch {
|
|
182
256
|
// While it is written, a last line not whole yet can't be read: what was drawn stays.
|
|
183
257
|
if (!open) this.dispatchEvent(new Event('unread'))
|
|
@@ -11,17 +11,20 @@ app-page iframe { display: block; box-sizing: content-box; inline-size: 100%; bl
|
|
|
11
11
|
(ui/style.css's --column), centred on it and never narrower than it, as Layouts' wide tables do (--shell, D215). */
|
|
12
12
|
app-parts { position: relative; display: block; container-type: inline-size; padding: 0.75rem 0.85rem; border: 1px solid var(--line); border-radius: 0.9rem; margin-block: 0 0.85rem; } @media screen { main .prose > app-parts { --wide: max(100cqi, min(var(--shell) - 2.5rem, 64rem)); margin-inline: calc((100cqi - var(--wide)) / 2); } }
|
|
13
13
|
app-parts .part-cards { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-block-end: 0.85rem; } app-parts .part-cards > * { flex: 1 1 15rem; } app-parts .part-card.wide { flex-basis: 100%; }
|
|
14
|
-
app-parts .part-card { min-inline-size: 0; padding: 0.75rem 0.85rem; border: 1px solid var(--line); border-radius: calc(var(--radius) * 0.6); } app-parts .part-card > :last-child { margin-block-end: 0; } app-parts .part-card > h4 { margin-block: 0 0.5rem; } app-parts .part-card > :is(app-chart, .diagram, app-page) { padding: 0; border: 0; }
|
|
14
|
+
app-parts .part-card { min-inline-size: 0; padding: 0.75rem 0.85rem; border: 1px solid var(--line); border-radius: calc(var(--radius) * 0.6); } app-parts .part-card > :last-child { margin-block-end: 0; } app-parts .part-card > h4 { margin-block: 0 0.5rem; } app-parts :is(.parts, .part-card) > :is(app-chart, .diagram, app-page) { padding: 0; border: 0; }
|
|
15
15
|
@container (min-width: 36rem) { app-parts .parts:has(> aside) { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: 1rem; align-items: start; } }
|
|
16
16
|
app-parts th .sorts { padding: 0; border: 0; background: none; font-weight: inherit; text-align: inherit; }
|
|
17
17
|
app-parts .part-form { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 14rem), 1fr)); gap: 0.6rem 0.75rem; margin-block-end: 0.85rem; } app-parts .part-form :is(.button, label:has(textarea)) { grid-column: 1 / -1; } app-parts .part-form .button { justify-self: start; }
|
|
18
18
|
app-parts .part-form label { display: grid; gap: 0.25rem; } app-parts .part-form label.tick { display: flex; align-items: center; gap: 0.5rem; }
|
|
19
|
+
app-parts .part-form label.slides { grid-template-columns: minmax(0, 1fr) 6.5rem; align-items: center; column-gap: 0.5rem; } app-parts .part-form label.slides > span { grid-column: 1 / -1; } app-parts .part-form input[type=range] { padding: 0; border: 0; background: none; accent-color: var(--flame); }
|
|
19
20
|
app-parts .part-form textarea { box-sizing: border-box; inline-size: 100%; padding: 0.4em 0.8em; border: 1px solid var(--line-strong); border-radius: calc(var(--radius) * 0.4); background: var(--glass); }
|
|
20
21
|
@media (forced-colors: active) { app-parts .part-card { border-color: CanvasText; } }
|
|
21
22
|
/* A diagram (D291, D592): framed as the other widgets are, Pele's picture as wide as it needs up to the text's width, then scaled down. */
|
|
22
23
|
.prose .diagram { position: relative; margin: 0 0 0.85rem; padding: 1rem; border: 1px solid var(--line); border-radius: 0.9rem; }
|
|
23
24
|
.diagram app-diagram { display: block; }
|
|
24
25
|
.diagram app-diagram img { display: block; max-inline-size: 100%; block-size: auto; margin-inline: auto; }
|
|
26
|
+
.drawn-words { margin-block-start: 0.35rem; font-size: 0.875rem; } .drawn-words summary { color: var(--ink-soft); cursor: pointer; } .drawn-words ul { margin-block: 0.25rem 0; padding-inline-start: 1.25rem; }
|
|
27
|
+
@media print { .drawn-words { display: none; } }
|
|
25
28
|
/* An app on its Creations card, at half size and still, its Copy away; beside the task, the pane its frame (D553). */
|
|
26
29
|
.creation-preview :is(app-page, app-parts) { zoom: 0.5; padding: 0; border: 0; } .creation-preview :is(app-page, app-parts) .drawn-foot { display: none; }
|
|
27
30
|
:is(app-page, app-parts).beside { margin: 0; border: 0; border-radius: 0; }
|
|
@@ -36,3 +39,6 @@ app-page:has(> pre) { padding: 0; border: 0; }
|
|
|
36
39
|
.mode-chip:hover .icon:last-child { color: var(--ink); }
|
|
37
40
|
@media (forced-colors: active) { .mode-chip { border-color: Highlight; } }
|
|
38
41
|
@media (width < 30rem) { .mode-chip span { position: absolute; inline-size: 1px; block-size: 1px; overflow: hidden; clip-path: inset(50%); } }
|
|
42
|
+
/* An app played before the turn ends (D689): laid out as a page in an answer is, never seen. */
|
|
43
|
+
.page-test { position: fixed; inset-block-start: 0; inset-inline-start: 0; inline-size: 640px; block-size: 480px; clip-path: inset(50%); pointer-events: none; }
|
|
44
|
+
.page-test iframe { inline-size: 100%; block-size: 100%; border: 0; }
|
|
@@ -9,7 +9,8 @@
|
|
|
9
9
|
// charts take the room's light or dark. It is as tall as what it shows, or, made to fill a screen
|
|
10
10
|
// (its root or body as tall as its frame, 100% or 100vh), as tall as a page may be; it speaks to Jean on a click
|
|
11
11
|
// of the user's only: `sendPrompt(text)` sends the text as the user's next message, as a follow-up
|
|
12
|
-
// does,
|
|
12
|
+
// does, a link opens in a new tab, and a link that saves a file the page made saves it (D158). What it keeps in localStorage
|
|
13
|
+
// is kept for it, by its name, in its task's file of apps (D688), so an app is still as it was left. With Run its code off, it is code. Copy puts its source on the
|
|
13
14
|
// clipboard. Loaded with the first message, for its rule, then at each visit, so that pages written
|
|
14
15
|
// before show again, or by the first page a conversation holds. Written again under a new policy,
|
|
15
16
|
// which a page keeps from its start; a new theme, look or language is put on the page as it is
|
|
@@ -27,23 +28,37 @@ import { app, effective, theme, notify, send, updateSettings } from '../../ui/st
|
|
|
27
28
|
import { register, drawnActions } from '../../ui/caps.js'
|
|
28
29
|
import { declared, drawn, PAGES, blocks, lex } from '../../ui/markdown.js'
|
|
29
30
|
import { pageRights, pagePolicy, pageAllow, mapStyles, PAGE_SANDBOX } from '../../ui/csp.js'
|
|
30
|
-
import { copyDrawing } from '../../ui/save.js'
|
|
31
|
+
import { copyDrawing, savePage } from '../../ui/save.js'
|
|
31
32
|
import { icons } from '../../ui/icons.js'
|
|
32
33
|
import { styleSheet, still } from '../../ui/sheet.js'
|
|
33
34
|
import { t, locale, dir, useStrings } from '../../core/i18n.js'
|
|
34
35
|
import { row, chip, notes } from './mode.js'
|
|
35
36
|
import { parse } from './parts.js'
|
|
37
|
+
/** @import { Settings } from '../../core/settings.js' */
|
|
38
|
+
/** What goes on to the next hook, and what came of it (core/hooks.js). @typedef {(e?: unknown) => Promise<unknown>} Next */
|
|
36
39
|
|
|
37
40
|
await Promise.all([useStrings('interactive'), styleSheet(new URL('interactive.css', import.meta.url))])
|
|
38
41
|
|
|
39
42
|
/** What it brings, to which ./apps.js adds the apps in the room. */
|
|
40
43
|
export const capability = {
|
|
41
44
|
id: 'interactive',
|
|
42
|
-
rules: ["Bills, loans, recipes, timezones, quizzes, science: end with a working ```html tool, not code: offline, var(--color-*), import 'echarts', sendPrompt(text)."],
|
|
45
|
+
rules: ["Bills, loans, recipes, timezones, quizzes, science: end with a working ```html tool, not code: offline, var(--color-*), import 'echarts', sendPrompt(text); localStorage keeps, <a download> saves."],
|
|
43
46
|
// Visual answers as a mode of the box (./mode.js, D300): a row of +, then pressed at the box's foot while it is on.
|
|
44
|
-
slots: { add: { at:
|
|
47
|
+
slots: { add: { at: 3, draw: row }, modes: { at: 0, draw: chip, notes } },
|
|
48
|
+
// A task gone for good takes what its apps kept with it (D688).
|
|
49
|
+
hooks: [{ on: 'record', match: { type: 'removed' }, run: (/** @type {{ all: true, task: string } | { all?: false }} */ e, /** @type {Next} */ next) => { const at = e.all && keptAt(e.task); if (at) app.fs.remove(at).catch(() => {}); return next(e) } },
|
|
50
|
+
// A task duplicated (D230) keeps what its apps kept, as it keeps their answers (D688).
|
|
51
|
+
{ on: 'task.start', run: async (/** @type {{ task: string, from?: { path: string } }} */ e, /** @type {Next} */ next) => { const [was, now] = [keptAt(e.from?.path ?? ''), keptAt(e.task)], kept = was && now && (await app.fs.read(was).catch(() => null)); if (kept && now) await app.fs.write(now, kept); return next(e) } },
|
|
52
|
+
// An answer's pages with a script, played out of sight before the turn ends; what broke goes back to the brain (./test.js, D689).
|
|
53
|
+
{ on: 'turn.answer', run: async (/** @type {{ text: string, task?: string, signal?: AbortSignal }} */ e, /** @type {Next} */ next) => (rights.peek().allows.scripts && /```html/.test(e.text) && (await (await import('./test.js')).played(e))) || next(e) }],
|
|
45
54
|
}
|
|
46
55
|
register(capability)
|
|
56
|
+
|
|
57
|
+
/** What a page calls itself, as text: its title, else its first heading. @param {string} source */
|
|
58
|
+
export const named = (source) => ((/<title[^>]*>([^<]*)</i.exec(source) ?? /<h[12][^>]*>([\s\S]*?)<\/h[12]>/i.exec(source))?.[1] ?? '')
|
|
59
|
+
.replace(/<[^>]*>/g, '').replaceAll('&', '&').replace(/\s+/g, ' ').trim()
|
|
60
|
+
/** Where a task's apps keep what they keep, each by its name: `apps/<its ULID>.json` beside its project's conversations (D688). @param {string} task */
|
|
61
|
+
export const keptAt = (task) => (/\/conversations\/[^/]+\.jsonl$/.test(task) ? task.replace(/conversations\/([^/]+)\.jsonl$/, 'apps/$1.json') : null)
|
|
47
62
|
// A page, a diagram or a map needs no skill to declare it (D289, D291): they stay among the kinds drawn, however often the room's skills are read again.
|
|
48
63
|
effect(() => { if (PAGES.some((kind) => !declared.value.has(kind))) declared.value = new Set([...declared.value, ...PAGES]) })
|
|
49
64
|
|
|
@@ -77,7 +92,7 @@ const ALIASES = Object.entries({
|
|
|
77
92
|
* @type {Promise<{ text: string, url: string }> | undefined}
|
|
78
93
|
*/
|
|
79
94
|
let echarts
|
|
80
|
-
const library = () => (echarts ??= fetch(new URL('../../vendor/echarts/echarts.mjs', import.meta.url)).then((response) => response.text()).then((text) => {
|
|
95
|
+
export const library = () => (echarts ??= fetch(new URL('../../vendor/echarts/echarts.mjs', import.meta.url)).then((response) => response.text()).then((text) => {
|
|
81
96
|
const names = (/export\s*\{([^}]*)\}\s*;?\s*$/.exec(text)?.[1] ?? '').split(',').map((name) => name.trim().split(/\s+as\s+/).pop()).filter((name) => /^\w+$/.test(String(name)) && name !== 'init')
|
|
82
97
|
const stand = `const text = await new Promise((resolve) => { addEventListener('message', function got({ data, source }) { if (source === parent && typeof data?.echarts === 'string') removeEventListener('message', got), resolve(data.echarts) }); parent.postMessage({ need: 'echarts' }, '*') })
|
|
83
98
|
const m = await import(URL.createObjectURL(new Blob([text], { type: 'text/javascript' })))
|
|
@@ -111,11 +126,11 @@ export default { ...m, init }`
|
|
|
111
126
|
/** What a page is lent when it holds one, each read once: Jean's diagrams and maps, and MapLibre for the maps. @type {Map<string, Promise<string>>} */
|
|
112
127
|
const parts = new Map()
|
|
113
128
|
/** @param {string} path */
|
|
114
|
-
const part = (path) => parts.get(path) ?? /** @type {Promise<string>} */ (parts.set(path, fetch(new URL(path, import.meta.url)).then((response) => response.text())).get(path))
|
|
115
|
-
const LENT = /** @type {Record<string, string>} */ ({ diagram: './page-diagram.js', map: './map.js' })
|
|
129
|
+
export const part = (path) => parts.get(path) ?? /** @type {Promise<string>} */ (parts.set(path, fetch(new URL(path, import.meta.url)).then((response) => response.text())).get(path))
|
|
130
|
+
export const LENT = /** @type {Record<string, string>} */ ({ diagram: './page-diagram.js', map: './map.js' })
|
|
116
131
|
|
|
117
132
|
/** The map service's styles, light and dark, and the addresses that may be fetched for a map: theirs. */
|
|
118
|
-
const styles = () => mapStyles(
|
|
133
|
+
const styles = () => mapStyles(effective.peek().settings, app.policy)
|
|
119
134
|
const mapSites = () => Object.values(styles()).map((address) => new URL(address).origin)
|
|
120
135
|
|
|
121
136
|
// Each component a page holds is asked for as it appears, and lent then; the rest isn't.
|
|
@@ -147,7 +162,7 @@ function room(style) {
|
|
|
147
162
|
* its <main> and <aside> side by side on a wide screen.
|
|
148
163
|
* @param {CSSStyleDeclaration} style @param {string} charts the address of ECharts' stand-in
|
|
149
164
|
*/
|
|
150
|
-
function head(style, charts) {
|
|
165
|
+
export function head(style, charts) {
|
|
151
166
|
const { lang, dir, theme, look, motion, css } = room(style)
|
|
152
167
|
return /* html */ `<html lang="${lang}" dir="${dir}" data-theme="${theme}" data-look="${look}" data-motion="${motion}"><script type="importmap">${JSON.stringify({ imports: { echarts: charts } })}</script>${LOADER}<style>${css}</style>${ROOM}<style>
|
|
153
168
|
:root { --border-radius-md: calc(var(--border-radius-lg) / 2) !important; accent-color: var(--color-ring-primary); }
|
|
@@ -177,6 +192,10 @@ class AppPage extends HTMLElement {
|
|
|
177
192
|
whole = false
|
|
178
193
|
/** @type {(() => void) | undefined} */
|
|
179
194
|
unwatch
|
|
195
|
+
/** Where what it keeps is kept, and its name there; none in a saved copy, which holds no project. @type {[string, string] | null} */
|
|
196
|
+
kept = null
|
|
197
|
+
/** @type {ReturnType<typeof setTimeout> | undefined} */
|
|
198
|
+
keeping
|
|
180
199
|
|
|
181
200
|
connectedCallback() {
|
|
182
201
|
addEventListener('message', this.heard)
|
|
@@ -241,7 +260,10 @@ class AppPage extends HTMLElement {
|
|
|
241
260
|
const { url } = await library()
|
|
242
261
|
const now = this.text()
|
|
243
262
|
const open = this.hasAttribute('open')
|
|
244
|
-
|
|
263
|
+
const at = RELAY === null && app.projectDir && !this.hasAttribute('map') ? keptAt(this.getAttribute('task')?.replace(/#.*/, '') || app.current.peek()?.path || '') : null
|
|
264
|
+
this.kept = at ? [at, named(now)] : null
|
|
265
|
+
const storage = at ? JSON.parse((await app.fs.read(at).catch(() => null)) ?? '{}').apps?.[named(now)] ?? {} : {}
|
|
266
|
+
frame.contentWindow?.postMessage({ page: head(getComputedStyle(this), url) + now, policy, open, storage }, '*')
|
|
245
267
|
this.written = now
|
|
246
268
|
this.whole = !open
|
|
247
269
|
} }
|
|
@@ -253,10 +275,10 @@ class AppPage extends HTMLElement {
|
|
|
253
275
|
* @param {Record<import('../../ui/csp.js').PageRight, boolean>} allows
|
|
254
276
|
*/
|
|
255
277
|
shell(allows) {
|
|
256
|
-
render(html`<iframe sandbox=${PAGE_SANDBOX} allow=${pageAllow(allows)} loading="lazy" src=${RELAY === null ? FRAME : nothing} srcdoc=${RELAY ?? nothing} title=${t(this.hasAttribute('map') ? 'interactive.map' : 'interactive.page')} @load=${this.begin}></iframe>
|
|
257
|
-
<div class="drawn-foot">
|
|
278
|
+
render(html`<iframe sandbox=${PAGE_SANDBOX} allow=${pageAllow(allows)} loading="lazy" src=${RELAY === null ? FRAME : nothing} srcdoc=${RELAY ?? nothing} lang=${locale.value} title=${t(this.hasAttribute('map') ? 'interactive.map' : 'interactive.page')} @load=${this.begin}></iframe>
|
|
279
|
+
<div class="drawn-foot" lang=${locale.value}>
|
|
258
280
|
<button class="icon-button subtle" aria-label=${t('action.copy')}
|
|
259
|
-
@click=${() => navigator.clipboard.writeText(this.getAttribute('source') ?? '').then(() => notify(t('toast.copied')), () => notify(t('made.copyFailed')))}>${icons.copy}</button>
|
|
281
|
+
@click=${() => navigator.clipboard.writeText(this.getAttribute('source') ?? '').then(() => notify(t('toast.copied')), () => notify(t('made.copyFailed'), { alert: true }))}>${icons.copy}</button>
|
|
260
282
|
${this.hasAttribute('map') ? nothing : drawnActions('html', this.getAttribute('source') ?? '')}
|
|
261
283
|
</div>`, this)
|
|
262
284
|
}
|
|
@@ -290,23 +312,41 @@ class AppPage extends HTMLElement {
|
|
|
290
312
|
else if (typeof data?.diagram === 'string') void import('./diagram.js').then(({ picture }) => picture(data.diagram, this, Number(data.width) || this.clientWidth)).then(({ url, words }) => answer({ picture: url, words }), () => answer({}))
|
|
291
313
|
else if (data?.need === 'maplibre') void this.maps().then(answer)
|
|
292
314
|
else if (typeof data?.fetch === 'string') void this.fetched(data.fetch).then(({ bytes, error }) => answer({ bytes, error }, bytes ? [bytes.buffer] : []))
|
|
315
|
+
else if (data?.storage && typeof data.storage === 'object') this.keep(data.storage)
|
|
316
|
+
else if (data?.save instanceof Blob) savePage(data, rights.peek().allows.downloads)
|
|
293
317
|
else if (navigator.userActivation?.isActive === false) return
|
|
294
318
|
else if (data?.allow === 'maps') void this.allow().then((allowed) => answer({ allowed }))
|
|
295
319
|
else if (typeof data?.prompt === 'string' && data.prompt.trim() && !app.busy.peek()) send(data.prompt.trim().slice(0, 2000))
|
|
296
320
|
else if (typeof data?.open === 'string' && /^https:\/\//i.test(data.open)) window.open(data.open, '_blank', 'noopener')
|
|
297
321
|
}
|
|
298
322
|
|
|
323
|
+
/**
|
|
324
|
+
* What it keeps in localStorage, kept a moment after its last change, beside what its task's other apps keep;
|
|
325
|
+
* past 256 KB, nothing more is kept. @param {object} storage
|
|
326
|
+
*/
|
|
327
|
+
keep(storage) {
|
|
328
|
+
const kept = this.kept
|
|
329
|
+
clearTimeout(this.keeping)
|
|
330
|
+
if (kept) this.keeping = setTimeout(async () => {
|
|
331
|
+
const own = Object.fromEntries(Object.entries(storage).map(([key, value]) => [String(key), String(value)]))
|
|
332
|
+
if (JSON.stringify(own).length > 262144) return
|
|
333
|
+
const all = JSON.parse((await app.fs.read(kept[0]).catch(() => null)) ?? '{}')
|
|
334
|
+
await app.fs.write(kept[0], JSON.stringify({ format: 1, apps: { ...all.apps, [kept[1]]: own } }))
|
|
335
|
+
}, 300)
|
|
336
|
+
}
|
|
337
|
+
|
|
299
338
|
/** MapLibre, its worker and its style sheet, the styles for light and dark, and whether maps are allowed; the words its card asks with. */
|
|
300
339
|
async maps() {
|
|
301
340
|
const [library, worker, css] = await Promise.all(['maplibre-gl.mjs', 'maplibre-gl-worker.js', 'maplibre-gl.css'].map((file) => part(`../../vendor/maplibre/${file}`)))
|
|
302
341
|
const site = new URL(styles()[theme.peek() === 'dark' ? 'dark' : 'light']).hostname
|
|
303
|
-
return { library, worker, css, styles: styles(), allowed: rights.peek().allows.maps, strings: { show: t('interactive.mapShow'), from: t('interactive.mapFrom', { site }) } }
|
|
342
|
+
return { library, worker, css, styles: styles(), allowed: rights.peek().allows.maps, strings: { show: t('interactive.mapShow'), from: t('interactive.mapFrom', { site }), map: t('interactive.map'), named: t('interactive.mapNamed', { places: '{places}' }),
|
|
343
|
+
zoomIn: t('interactive.zoomIn'), zoomOut: t('interactive.zoomOut'), credits: t('interactive.mapCredits'), words: t('interactive.inWords') } }
|
|
304
344
|
}
|
|
305
345
|
|
|
306
346
|
/** Maps allowed, from now on, unless the organisation says otherwise. */
|
|
307
347
|
async allow() {
|
|
308
348
|
const { allows, locked } = rights.peek()
|
|
309
|
-
if (!allows.maps && !locked.has('maps')) await updateSettings({ pages:
|
|
349
|
+
if (!allows.maps && !locked.has('maps')) await updateSettings({ pages: { ...app.settings.peek().pages, maps: true } })
|
|
310
350
|
return rights.peek().allows.maps
|
|
311
351
|
}
|
|
312
352
|
|
|
@@ -336,10 +376,10 @@ function diagram(source, open) {
|
|
|
336
376
|
/** @param {Event} event */
|
|
337
377
|
const copy = (event) => {
|
|
338
378
|
const shown = /** @type {HTMLElement & { picture: () => Promise<Blob> }} */ (/** @type {HTMLElement} */ (event.currentTarget).closest('figure')?.querySelector('app-diagram'))
|
|
339
|
-
copyDrawing(source, shown.picture()).then(() => notify(t('toast.copied')), () => notify(t('made.copyFailed')))
|
|
379
|
+
copyDrawing(source, shown.picture()).then(() => notify(t('toast.copied')), () => notify(t('made.copyFailed'), { alert: true }))
|
|
340
380
|
}
|
|
341
|
-
return html`<figure class="diagram"
|
|
342
|
-
<div class="drawn-foot"><button class="icon-button subtle" aria-label=${t('action.copy')} @click=${copy}>${icons.copy}</button>${drawnActions('mermaid', source)}</div></figure>`
|
|
381
|
+
return html`<figure class="diagram"><app-diagram source=${source} ?open=${open} @unread=${() => { unread.value = new Set(unread.peek()).add(source) }}></app-diagram>
|
|
382
|
+
<div class="drawn-foot" lang=${locale.value}><button class="icon-button subtle" aria-label=${t('action.copy')} @click=${copy}>${icons.copy}</button>${drawnActions('mermaid', source)}</div></figure>`
|
|
343
383
|
}
|
|
344
384
|
|
|
345
385
|
/** Whether a whole block is GeoJSON. @param {string} source */
|
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
// What a page of parts shares (D670), so that what the user changes reaches all it touches at once, with nothing sent to a brain:
|
|
2
|
+
// its form's fields, by their labels; the values worked out from them (<app-values>, a line each, `Name = formula`), in Tables' formulas,
|
|
3
|
+
// which Jean reads itself, never with eval; `{formula}` in figures, a table's lines, a chart's, a card's heading and words, `{formula:2}`
|
|
4
|
+
// with that many decimals, said in the language; a table's `each="Year = 1..Years"`, which repeats the lines that hold one; `{sum Column}`
|
|
5
|
+
// and `{count}`, what a table of the page adds up to as it stands, the rows its forms added too; a chart's `from="its id"`, drawn from it by
|
|
6
|
+
// `by` and `sum`; a choice named as a table's column, which keeps the rows that hold it, one no row holds (All) keeping them all.
|
|
7
|
+
// What can't be worked out is a dash. A page with none of these stays as it was written. Pure, so Node's tests run it.
|
|
8
|
+
import { compile } from '../tables/formula.js'
|
|
9
|
+
import { all, form, lines, number, split, table } from './parts.js'
|
|
10
|
+
|
|
11
|
+
/** @import { Part } from './parts.js' */
|
|
12
|
+
/** What a form's fields, what they work out and a table's sums hold, by their names. @typedef {Record<string, unknown>} Cells */
|
|
13
|
+
|
|
14
|
+
const FORMULA = /\{([^{}]+)\}/g, HOLDS = /\{[^{}]+\}/, LIST = /\s*[,،、]\s*/
|
|
15
|
+
/** The parts whose lines may hold a formula: a diagram's braces are its own. */
|
|
16
|
+
const SPELLED = ['app-figures', 'app-table', 'app-chart', '#text']
|
|
17
|
+
/** The rows an `each` makes at most. */
|
|
18
|
+
const MOST = 600
|
|
19
|
+
/** A number as a chart's lines, and the brain, read one: a few decimals, whatever the language; none for what is no number. @param {number} value @param {string} [digits] */
|
|
20
|
+
const plain = (value, digits) => (Number.isFinite(value) ? String(Number(value.toFixed(digits ? Number(digits) : Math.abs(value) < 1 ? 4 : 2))) : '')
|
|
21
|
+
/** A line with what `say` makes of each formula's words and the decimals it asks for. @param {string} line @param {(text: string, digits?: string) => string} say */
|
|
22
|
+
const spelled = (line, say) => line.replace(FORMULA, (_, inner) => ((found) => say(found[1], found[2]))(/** @type {RegExpExecArray} */ (/^(.*?)(?::\s*(\d))?\s*$/s.exec(inner))))
|
|
23
|
+
/** @param {string} raw */
|
|
24
|
+
const read = (raw) => (raw.trim() !== '' && Number.isFinite(Number(raw)) ? Number(raw) : raw)
|
|
25
|
+
|
|
26
|
+
/**
|
|
27
|
+
* What a page's parts share now, from what the user set (`given`, by each field's label) and the rows its forms added (`added`, by each
|
|
28
|
+
* table's id): whether it shares anything, each part as it shows it, and what it now holds, in words for a brain.
|
|
29
|
+
* @param {Part[]} parts @param {{ given: Map<string, string | boolean>, added: Map<string, string[][]>, lang: string, locales: string[] }} how
|
|
30
|
+
* @returns {{ live: boolean, filled: (part: Part) => Part, now: () => string }}
|
|
31
|
+
*/
|
|
32
|
+
export function shared(parts, { given, added, lang, locales }) {
|
|
33
|
+
const list = all(parts), own = list.filter((part) => part.tag === 'app-table' && !part.attrs.from), fields = list.filter((part) => part.tag === 'app-form' && !part.attrs.to).flatMap(form)
|
|
34
|
+
const worked = list.filter((part) => part.tag === 'app-values').flatMap(lines).map((line) => split(line, '=')), heads = own.flatMap((part) => table(part).heads), counted = own.flatMap((part) => (part.attrs.each ? [split(part.attrs.each, '=')[0]] : []))
|
|
35
|
+
const source = (/** @type {Part} */ part) => own.find((one) => one.attrs.id && one.attrs.id === part.attrs.from), choice = (/** @type {string} */ head) => fields.some((field) => field.kind === 'choice' && field.label === head)
|
|
36
|
+
const live = worked.length > 0 || counted.length > 0 || list.some((part) => source(part)) || heads.some(choice) || (fields.length > 0 && list.some((part) => SPELLED.includes(part.tag) && HOLDS.test(part.text)))
|
|
37
|
+
// A field is read by its label or its first words, as brains shorten them (`Weight` for `Weight (kg)`).
|
|
38
|
+
const columns = /** @type {any[]} */ ([...fields.map(({ label }) => label), ...worked.map(([name]) => name), ...counted, ...heads.map((head) => `sum ${head}`), 'count'].map((name) => ({ id: name, name, type: 'live' }))
|
|
39
|
+
.concat(fields.flatMap(({ label }) => label.split(/\s+/).slice(0, -1).map((_, i, words) => ({ id: label, name: words.slice(0, i + 1).join(' '), type: 'live' })))))
|
|
40
|
+
const readers = /** @type {Map<string, (cells: Cells) => any>} */ (new Map()), formats = /** @type {Map<string, Intl.NumberFormat>} */ (new Map())
|
|
41
|
+
const reader = (/** @type {string} */ text) => { try { return compile(text.replace(/[{}]/g, ''), columns) } catch { return () => NaN } }
|
|
42
|
+
/** What a formula comes to; NaN where it can't be read or worked out. @param {string} text @param {Cells} cells */
|
|
43
|
+
const value = (text, cells) => /** @type {(cells: Cells) => any} */ (readers.get(text) ?? readers.set(text, reader(text)).get(text))(cells)
|
|
44
|
+
/** A result in the page's words. @param {unknown} got @param {string} [digits] @param {boolean} [bare] with no marks between thousands */
|
|
45
|
+
const said = (got, digits, bare) => (typeof got === 'boolean' ? (got ? '✓' : '') : typeof got !== 'number' ? String(got) : !Number.isFinite(got) ? '—' : /** @type {Intl.NumberFormat} */ (formats.get(`${digits}${bare}`)
|
|
46
|
+
?? formats.set(`${digits}${bare}`, new Intl.NumberFormat(locales, { maximumFractionDigits: digits ? Number(digits) : 2, minimumFractionDigits: digits ? Number(digits) : 0, useGrouping: !bare, signDisplay: 'negative' })).get(`${digits}${bare}`)).format(got))
|
|
47
|
+
/** A line with each formula worked out, an `each`'s own name as it is written. @param {string} line @param {Cells} cells @param {string} [name] */
|
|
48
|
+
const spell = (line, cells, name) => (live ? spelled(line, (text, digits) => said(value(text, cells), digits, text.trim() === name)) : line)
|
|
49
|
+
const base = /** @type {Cells} */ (Object.fromEntries(fields.map(({ label, kind, start, choices }) => ((raw) => [label, typeof raw === 'boolean' ? raw : /^(yes|no)$/.test(kind) ? (raw ? /^(yes|on|true|✓)$/i.test(raw) : kind === 'yes')
|
|
50
|
+
: /^(number|range)$/.test(kind) ? (raw === '' ? NaN : number(raw, lang, true)) : read(raw)])(given.get(label) ?? (start || choices?.[0] || '')))))
|
|
51
|
+
/** The fields, the tables' sums, and each value worked out, as often as there are values, so that one written before what it reads sees it. @param {Cells} [extra] */
|
|
52
|
+
const work = (extra) => { const cells = { ...base, ...extra }; for (const _ of worked) for (const [name, text] of worked) cells[name] = value(text, cells); return cells }
|
|
53
|
+
/** The name an `each` gives, and the values it goes over: `from..to..step`, or a list. @param {string} each @returns {[string, unknown[]]} */
|
|
54
|
+
const steps = (each) => {
|
|
55
|
+
const [name, over] = split(each, '='), cells = work(), [from, to, by = 1] = over.split('..').map((text) => value(text, cells))
|
|
56
|
+
return [name, !over.includes('..') ? over.split(LIST).map(read) : by > 0 ? Array.from({ length: Math.min(MOST, Math.max(0, Math.floor((to - from) / by + 1e-9) + 1 || 0)) }, (_, i) => from + i * by) : []]
|
|
57
|
+
}
|
|
58
|
+
/** A table of the page: its lines worked out, the rows its forms added, those a choice named as a column keeps. @param {Part} part */
|
|
59
|
+
const tabled = (part) => {
|
|
60
|
+
const [head = '', ...rest] = lines(part), [name, over] = part.attrs.each ? steps(part.attrs.each) : ['', []], cells = work()
|
|
61
|
+
const made = table({ ...part, text: [spell(head, cells), ...rest.flatMap((line) => (part.attrs.each && HOLDS.test(line) ? over.map((at) => spell(line, work({ [name]: at }), name)) : [spell(line, cells)]))].join('\n') })
|
|
62
|
+
return { name, over, heads: made.heads, rows: made.heads.reduce((kept, head, i) => ((now) => (kept.some((row) => row[i] === now) ? kept.filter((row) => row[i] === now) : kept))(choice(head) ? String(base[head]) : null),
|
|
63
|
+
[...made.rows, ...(added.get(part.attrs.id ?? '') ?? []).map((row) => row.map((cell) => cell.replaceAll('|', '¦')))]) }
|
|
64
|
+
}
|
|
65
|
+
const total = (/** @type {string[][]} */ rows, /** @type {number} */ column) => rows.reduce((sum, row) => sum + (number(row[column] ?? '', lang) || 0), 0)
|
|
66
|
+
// Those with no formula first, as those that have one may read what these add up to.
|
|
67
|
+
const shown = new Map([...own].sort((a, b) => Number(Boolean(a.attrs.each) || HOLDS.test(a.text)) - Number(Boolean(b.attrs.each) || HOLDS.test(b.text))).map((part) => {
|
|
68
|
+
const drawn = tabled(part)
|
|
69
|
+
drawn.heads.forEach((head, i) => { base[`sum ${head}`] ??= total(drawn.rows, i) })
|
|
70
|
+
base.count ??= drawn.rows.length
|
|
71
|
+
return [part, drawn]
|
|
72
|
+
}))
|
|
73
|
+
const cells = work()
|
|
74
|
+
/**
|
|
75
|
+
* A chart of a table of the page: for each value of its `by`, the first column unless it says, the sum of each column its `sum` names, or how
|
|
76
|
+
* many; a `sum` that names a value rather than a column, as brains write, that value at each of the table's `each`.
|
|
77
|
+
* @param {Part} part @param {ReturnType<typeof tabled>} of
|
|
78
|
+
*/
|
|
79
|
+
const tally = (part, { heads, rows, name: step, over }) => {
|
|
80
|
+
const column = (/** @type {string} */ name) => heads.findIndex((head) => head.toLocaleLowerCase() === name.toLocaleLowerCase()), at = Math.max(0, column(part.attrs.by ?? '')), labels = [...new Set(rows.map((row) => row[at]))]
|
|
81
|
+
const of = (/** @type {string} */ label) => rows.filter((row) => row[at] === label), sums = part.attrs.sum?.split(LIST) ?? []
|
|
82
|
+
return !labels.length ? '' : [labels.join(' | '), ...sums.map((name) => `${name}: ${labels.map((label, i) => plain(column(name) < 0 ? value(name, work({ [step]: over[i] })) : total(of(label), column(name)))).join(', ')}`), ...(sums.length ? [] : [`${heads[at]}: ${labels.map((label) => of(label).length).join(', ')}`])].join('\n')
|
|
83
|
+
}
|
|
84
|
+
/** @param {Part} part @returns {Part} */
|
|
85
|
+
const filled = (part) => {
|
|
86
|
+
const drawn = shown.get(part), from = source(part)
|
|
87
|
+
if (drawn) return { ...part, text: [drawn.heads, ...drawn.rows].map((row) => row.join(' | ')).join('\n') }
|
|
88
|
+
if (!live) return part
|
|
89
|
+
if (part.tag === 'app-card') return { ...part, attrs: { ...part.attrs, heading: spell(part.attrs.heading ?? '', cells) } }
|
|
90
|
+
if (part.tag === 'app-chart') return { ...part, text: from ? tally(part, /** @type {ReturnType<typeof tabled>} */ (shown.get(from))) : lines(part).map((line, i) => (i ? spelled(line, (text, digits) => plain(value(text, cells), digits)) : spell(line, cells))).join('\n') }
|
|
91
|
+
return SPELLED.includes(part.tag) ? { ...part, text: spell(part.text, cells) } : part
|
|
92
|
+
}
|
|
93
|
+
const now = () => [...fields.map(({ label }) => [label, base[label]]), ...worked.map(([name]) => [name, cells[name]])].map(([name, held]) => [name, typeof held === 'number' ? plain(held) : held]).filter(([, held]) => held !== '').map(([name, held]) => `${name}: ${held}`)
|
|
94
|
+
.concat([...added].map(([id, rows]) => `${id}, added: ${rows.map((row) => row.join(' | ')).join('; ')}`)).join('; ')
|
|
95
|
+
return { live, filled, now }
|
|
96
|
+
}
|
package/caps/interactive/map.js
CHANGED
|
@@ -4,7 +4,8 @@
|
|
|
4
4
|
// one. Drawn by MapLibre GL, which Jean lends too, once, its worker a classic one (scripts/vendor.js). Its style, tiles, fonts and icons come from the map
|
|
5
5
|
// service Settings name, through Jean, which fetches them once the user has said yes to maps: the
|
|
6
6
|
// page itself reaches nothing. Until then, the map says where it would come from and asks. Its places
|
|
7
|
-
// in the room's accent, each named, its routes and areas too, the whole framed to fit.
|
|
7
|
+
// in the room's accent, each named, its routes and areas too, the whole framed to fit. Their names are in words too, folded over the
|
|
8
|
+
// map, for those who can't see it.
|
|
8
9
|
// Self-contained, the DOM's own calls only: it runs in a page's frame.
|
|
9
10
|
|
|
10
11
|
/** Asks Jean, and waits for its answer. @param {Record<string, unknown>} message @returns {Promise<any>} */
|
|
@@ -21,7 +22,13 @@ const routed = (url) => url.replace(/^(https?):\/\//, 'jean://$1/')
|
|
|
21
22
|
/** @param {string} url */
|
|
22
23
|
const direct = (url) => url.replace(/^jean:\/\/(https?)\//, '$1://')
|
|
23
24
|
|
|
24
|
-
/**
|
|
25
|
+
/**
|
|
26
|
+
* What Jean lends a map (interactive.js): MapLibre and its worker as text, its style sheet, the map service's styles for light and dark,
|
|
27
|
+
* whether maps are allowed, and the words it says; with MapLibre made ready.
|
|
28
|
+
* @typedef {{ library: string, worker: string, css: string, styles: Record<'light' | 'dark', string>, allowed: boolean, strings: Record<string, string>, maplibregl: typeof import('maplibre-gl') }} Lent
|
|
29
|
+
*/
|
|
30
|
+
/** A place its fold names, and what it says of itself. @typedef {{ name: unknown, about: unknown }} Named */
|
|
31
|
+
/** MapLibre, made ready once: its worker classic, and every address it reaches fetched by Jean. @type {Promise<Lent> | undefined} */
|
|
25
32
|
let lent
|
|
26
33
|
const lend = () => (lent ??= ask({ need: 'maplibre' }).then(async (given) => {
|
|
27
34
|
const maplibregl = await import(URL.createObjectURL(new Blob([given.library], { type: 'text/javascript' })))
|
|
@@ -38,6 +45,7 @@ const lend = () => (lent ??= ask({ need: 'maplibre' }).then(async (given) => {
|
|
|
38
45
|
// The map in its box, its consent card over it until maps are allowed.
|
|
39
46
|
const OWN = `:host { position: relative; display: block; block-size: 22rem; overflow: hidden; border-radius: var(--border-radius-md, 0.6rem); }
|
|
40
47
|
.box { position: absolute; inset: 0; }
|
|
48
|
+
details { position: absolute; z-index: 3; inset-block-end: 0.5rem; inset-inline-start: 0.5rem; max-block-size: calc(100% - 1rem); max-inline-size: calc(100% - 1rem); overflow: auto; padding-inline: 0.6rem; border-radius: var(--border-radius-md, 0.6rem); background: Canvas; color: CanvasText; font: 0.8rem/1.4 var(--font-sans, system-ui, sans-serif); } :host(:dir(rtl)) details { inset-block-end: 2.5rem; } summary { padding-block: 0.25rem; cursor: pointer; } ul { margin-block: 0 0.4rem; padding-inline-start: 1.1rem; }
|
|
41
49
|
.ask { position: absolute; inset: 0; display: grid; place-content: center; gap: 0.6rem; padding: 1rem; text-align: center; background: var(--color-background-secondary); color: var(--color-text-secondary); font: 0.9rem/1.4 var(--font-sans); }
|
|
42
50
|
.ask button { justify-self: center; padding: 0.45em 1em; border: 0; border-radius: 99px; background: var(--color-primary, #2a6fdb); color: var(--color-on-primary, white); font: inherit; font-weight: 600; cursor: pointer; }`
|
|
43
51
|
|
|
@@ -53,7 +61,7 @@ function rgba(colour) {
|
|
|
53
61
|
/** Features of a kind, one or many (MultiPoint is points too). @param {string} type */
|
|
54
62
|
const kind = (type) => ['in', ['geometry-type'], ['literal', [type, `Multi${type}`]]]
|
|
55
63
|
|
|
56
|
-
/** Every position in some GeoJSON. @param {
|
|
64
|
+
/** Every position in some GeoJSON. @param {unknown} value @returns {number[][]} */
|
|
57
65
|
const positions = (value) => (Array.isArray(value) && typeof value[0] === 'number' ? [value] : Array.isArray(value) ? value.flatMap(positions)
|
|
58
66
|
: value && typeof value === 'object' ? Object.entries(value).flatMap(([key, inner]) => (key === 'properties' ? [] : positions(inner))) : [])
|
|
59
67
|
|
|
@@ -67,6 +75,8 @@ class AppMap extends HTMLElement {
|
|
|
67
75
|
given = null
|
|
68
76
|
/** The address of the style it shows. */
|
|
69
77
|
base = ''
|
|
78
|
+
/** What it shows in words, folded. */
|
|
79
|
+
words = document.createElement('details')
|
|
70
80
|
|
|
71
81
|
connectedCallback() {
|
|
72
82
|
this.changed.observe(this, { childList: true, characterData: true, subtree: true })
|
|
@@ -93,7 +103,8 @@ class AppMap extends HTMLElement {
|
|
|
93
103
|
async start() {
|
|
94
104
|
const given = this.given = await lend()
|
|
95
105
|
const box = Object.assign(document.createElement('div'), { className: 'box' })
|
|
96
|
-
this.shown.replaceChildren(Object.assign(document.createElement('style'), { textContent: given.css + OWN }), box)
|
|
106
|
+
this.shown.replaceChildren(Object.assign(document.createElement('style'), { textContent: given.css + OWN }), box, this.words)
|
|
107
|
+
this.tell()
|
|
97
108
|
if (!given.allowed) {
|
|
98
109
|
const button = Object.assign(document.createElement('button'), { type: 'button', textContent: given.strings.show })
|
|
99
110
|
const card = Object.assign(document.createElement('div'), { className: 'ask' })
|
|
@@ -103,6 +114,7 @@ class AppMap extends HTMLElement {
|
|
|
103
114
|
}
|
|
104
115
|
this.base = this.basemap()
|
|
105
116
|
const map = this.map = new given.maplibregl.Map({ container: box, style: routed(this.base), center: [0, 20], zoom: 1, attributionControl: { compact: true },
|
|
117
|
+
locale: { 'Map.Title': given.strings.map, 'NavigationControl.ZoomIn': given.strings.zoomIn, 'NavigationControl.ZoomOut': given.strings.zoomOut, 'AttributionControl.ToggleAttribution': given.strings.credits },
|
|
106
118
|
transformRequest: (/** @type {string} */ url) => ({ url: routed(url) }) })
|
|
107
119
|
map.addControl(new given.maplibregl.NavigationControl({ showCompass: false }))
|
|
108
120
|
// Its places, routes and areas on each style the map takes: the first, then the room's light or dark.
|
|
@@ -117,10 +129,23 @@ class AppMap extends HTMLElement {
|
|
|
117
129
|
}
|
|
118
130
|
this.update(true)
|
|
119
131
|
})
|
|
132
|
+
this.tell()
|
|
120
133
|
// The room's light or dark, or look, put on the page: the map service's other style, or its own colours.
|
|
121
134
|
this.room.observe(document.documentElement, { attributes: true, attributeFilter: ['data-theme', 'data-look'] })
|
|
122
135
|
}
|
|
123
136
|
|
|
137
|
+
/** What it shows, by name, for those who can't see it: in its fold, and as the map's own name. */
|
|
138
|
+
tell() {
|
|
139
|
+
const data = this.data, strings = this.given?.strings
|
|
140
|
+
if (!data || !strings) return
|
|
141
|
+
const named = (data.features ?? [data]).map((/** @type {{ properties?: Record<string, unknown> | null }} */ one) => ({ name: one?.properties?.name ?? one?.properties?.title ?? positions(one)[0]?.toReversed().join(', '), about: one?.properties?.description })).filter((/** @type {Named} */ { name }) => name)
|
|
142
|
+
const list = this.words.querySelector('ul') ?? this.words.appendChild(document.createElement('ul'))
|
|
143
|
+
list.replaceChildren(...named.map((/** @type {Named} */ { name, about }) => Object.assign(document.createElement('li'), { dir: 'auto', textContent: about ? `${name}: ${about}` : name })))
|
|
144
|
+
this.words.hidden = !named.length
|
|
145
|
+
if (!this.words.querySelector('summary')) this.words.prepend(Object.assign(document.createElement('summary'), { textContent: strings.words }))
|
|
146
|
+
this.map?.getCanvas().setAttribute('aria-label', named.length ? strings.named.replace('{places}', new Intl.ListFormat(document.documentElement.lang || undefined).format(named.map((/** @type {Named} */ { name }) => String(name)))) : strings.map)
|
|
147
|
+
}
|
|
148
|
+
|
|
124
149
|
/** The map service's style for the page's light or dark. */
|
|
125
150
|
basemap() {
|
|
126
151
|
return this.given.styles[getComputedStyle(this).colorScheme === 'dark' ? 'dark' : 'light']
|
|
@@ -168,6 +193,7 @@ class AppMap extends HTMLElement {
|
|
|
168
193
|
|
|
169
194
|
/** Its GeoJSON on the map, framed to fit, gently unless motion is better left out. @param {boolean} [first] */
|
|
170
195
|
update(first = false) {
|
|
196
|
+
this.tell()
|
|
171
197
|
const data = this.data
|
|
172
198
|
const source = this.map?.getSource('own')
|
|
173
199
|
if (!data || !source) return
|