@simple-reporting/base 0.1.111 → 1.0.0
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/.github/workflows/npm-publish.yml +24 -25
- package/.nvmrc +1 -1
- package/README.md +23 -23
- package/cli.js +121 -114
- package/dev/.ddev/nginx_full/custom.conf +12 -12
- package/dev/index.html +18 -17
- package/dev/livingdocs.config.json +154 -376
- package/dev/package.json +64 -60
- package/dev/pdf/pdf-configuration-debug.xml +8 -5
- package/dev/pdf/pdf-configuration.xml +2 -2
- package/dev/public/downloads/downloads_de.json +1 -0
- package/dev/public/downloads/downloads_en.json +1 -0
- package/dev/public/favicon.png +0 -0
- package/dev/public/html/de/Downloads.html +3 -0
- package/dev/public/html/de/Home.html +3 -0
- package/dev/public/html/de/Suche.html +3 -0
- package/dev/public/html/en/Downloads.html +3 -0
- package/dev/public/html/en/Home.html +3 -0
- package/dev/public/html/en/Suche.html +3 -0
- package/dev/public/json/routing_de.json +86 -0
- package/dev/public/json/routing_en.json +86 -0
- package/dev/public/json/settings.json +8 -0
- package/dev/public/json/translations_hosting.json +1 -0
- package/dev/src/App.vue +33 -44
- package/dev/src/Autoload.ts +6 -6
- package/dev/src/Dialog.vue +99 -0
- package/dev/src/assets/fonts/Inter/Inter-Regular.ttf +0 -0
- package/dev/src/assets/fonts/Inter/Inter-Regular.woff2 +0 -0
- package/dev/src/assets/fonts/Inter/Inter-SemiBold.ttf +0 -0
- package/dev/src/assets/fonts/Inter/Inter-SemiBold.woff2 +0 -0
- package/dev/src/assets/fonts/Inter/inter.scss +17 -0
- package/dev/src/assets/images/mms-logo-black.svg +91 -91
- package/dev/src/assets/images/mms-logo-white.svg +105 -105
- package/dev/src/assets/images/next.svg +12 -0
- package/dev/src/assets/images/prev.svg +12 -0
- package/dev/src/assets/images/toTop.svg +12 -0
- package/dev/src/assets/scss/app.scss +39 -39
- package/dev/src/assets/scss/{ldd.scss → editor.scss} +27 -27
- package/dev/src/assets/scss/general.scss +59 -17
- package/dev/src/assets/scss/pdf.scss +138 -2
- package/dev/src/assets/scss/placeholders.scss +226 -0
- package/dev/src/assets/scss/print.scss +1 -1
- package/dev/src/assets/scss/web.scss +32 -1
- package/dev/src/assets/scss/word.scss +2 -2
- package/dev/src/components/BypassLinks.vue +90 -0
- package/dev/src/components/MainNavigation.vue +15 -209
- package/dev/src/components/NavLanguages.vue +57 -0
- package/dev/src/components/PageFooter.vue +45 -86
- package/dev/src/components/PageHeader.vue +41 -149
- package/dev/src/components/PageMain.vue +13 -0
- package/dev/src/components/PrevNext.vue +168 -144
- package/dev/src/components/SrlPage/KFCApplication/hooks/kfcData.ts +9 -9
- package/dev/src/components/SrlPage/KFCApplication/scss/_iz-keyfigure-comparison.scss +151 -151
- package/dev/src/components/SrlPage/KFCApplication/scss/_kfc-loading.scss +40 -40
- package/dev/src/components/SrlPage/KFCApplication/scss/_srl-button-kfc.scss +21 -21
- package/dev/src/components/Svg/Close.vue +14 -0
- package/dev/src/entries/main.ts +4 -0
- package/dev/src/entries/pdf.ts +2 -0
- package/dev/src/i18n/index.ts +21 -51
- package/dev/src/i18n/translation.ts +85 -85
- package/dev/src/locales/de.json +9 -15
- package/dev/src/locales/en.json +9 -15
- package/dev/src/router/index.ts +44 -47
- package/dev/src/views/ArticleView.vue +12 -77
- package/dev/src/views/DevView.vue +861 -0
- package/dev/src/views/HomeView.vue +5 -35
- package/dev/src/views/PageNotFound.vue +77 -73
- package/dev/srl.config.json +754 -0
- package/dev/tsconfig.app.json +13 -16
- package/dev/tsconfig.node.json +20 -19
- package/dev/vite.config.ts +18 -27
- package/initTestProject.js +91 -0
- package/jest.config.mjs +200 -0
- package/livingdocs/010.Titles/010.title-h1/ld-conf.json +5 -0
- package/livingdocs/010.Titles/010.title-h1/scss/app.scss +1 -0
- package/livingdocs/010.Titles/010.title-h1/scss/editor.scss +1 -0
- package/livingdocs/010.Titles/010.title-h1/scss/general.scss +5 -0
- package/livingdocs/010.Titles/010.title-h1/scss/xbrl.scss +1 -0
- package/livingdocs/010.Titles/010.title-h1/title-h1.html +5 -0
- package/livingdocs/010.Titles/020.title-h2/ld-conf.json +10 -0
- package/livingdocs/010.Titles/020.title-h2/properties.json +27 -0
- package/livingdocs/010.Titles/020.title-h2/scss/app.scss +1 -0
- package/livingdocs/010.Titles/020.title-h2/scss/editor.scss +1 -0
- package/livingdocs/010.Titles/020.title-h2/scss/general.scss +21 -0
- package/livingdocs/010.Titles/020.title-h2/scss/xbrl.scss +1 -0
- package/livingdocs/010.Titles/020.title-h2/title-h2.html +22 -0
- package/livingdocs/010.Titles/030.title-h3/ld-conf.json +10 -0
- package/livingdocs/010.Titles/030.title-h3/properties.json +23 -0
- package/livingdocs/010.Titles/030.title-h3/scss/app.scss +1 -0
- package/livingdocs/010.Titles/030.title-h3/scss/editor.scss +1 -0
- package/livingdocs/010.Titles/030.title-h3/scss/general.scss +21 -0
- package/livingdocs/010.Titles/030.title-h3/scss/xbrl.scss +1 -0
- package/livingdocs/010.Titles/030.title-h3/title-h3.html +22 -0
- package/livingdocs/010.Titles/040.title-h4/ld-conf.json +10 -0
- package/livingdocs/010.Titles/040.title-h4/properties.json +19 -0
- package/livingdocs/010.Titles/040.title-h4/scss/app.scss +1 -0
- package/livingdocs/010.Titles/040.title-h4/scss/editor.scss +1 -0
- package/livingdocs/010.Titles/040.title-h4/scss/general.scss +21 -0
- package/livingdocs/010.Titles/040.title-h4/scss/xbrl.scss +1 -0
- package/livingdocs/010.Titles/040.title-h4/title-h4.html +22 -0
- package/livingdocs/010.Titles/050.title-h5/ld-conf.json +5 -0
- package/livingdocs/010.Titles/050.title-h5/properties.json +15 -0
- package/livingdocs/010.Titles/050.title-h5/scss/app.scss +1 -0
- package/livingdocs/010.Titles/050.title-h5/scss/editor.scss +1 -0
- package/livingdocs/010.Titles/050.title-h5/scss/general.scss +6 -0
- package/livingdocs/010.Titles/050.title-h5/scss/xbrl.scss +1 -0
- package/livingdocs/010.Titles/050.title-h5/title-h5.html +5 -0
- package/livingdocs/010.Titles/060.title-h6/ld-conf.json +5 -0
- package/livingdocs/010.Titles/060.title-h6/scss/app.scss +1 -0
- package/livingdocs/010.Titles/060.title-h6/scss/editor.scss +1 -0
- package/livingdocs/010.Titles/060.title-h6/scss/general.scss +6 -0
- package/livingdocs/010.Titles/060.title-h6/scss/xbrl.scss +1 -0
- package/livingdocs/010.Titles/060.title-h6/title-h6.html +5 -0
- package/livingdocs/020.Text/010.lead/ld-conf.json +10 -0
- package/livingdocs/020.Text/010.lead/lead.html +7 -0
- package/livingdocs/020.Text/010.lead/scss/app.scss +1 -0
- package/livingdocs/020.Text/010.lead/scss/editor.scss +1 -0
- package/livingdocs/020.Text/010.lead/scss/general.scss +6 -0
- package/livingdocs/020.Text/010.lead/scss/xbrl.scss +1 -0
- package/livingdocs/020.Text/020.paragraph/ld-conf.json +5 -0
- package/livingdocs/{Text/paragraph → 020.Text/020.paragraph}/paragraph.html +13 -24
- package/livingdocs/020.Text/020.paragraph/scss/app.scss +1 -0
- package/livingdocs/020.Text/020.paragraph/scss/editor.scss +1 -0
- package/livingdocs/020.Text/020.paragraph/scss/general.scss +6 -0
- package/livingdocs/020.Text/020.paragraph/scss/web.scss +0 -0
- package/livingdocs/020.Text/020.paragraph/scss/word.scss +0 -0
- package/livingdocs/020.Text/020.paragraph/scss/xbrl.scss +1 -0
- package/livingdocs/020.Text/030.paragraph-strong/ld-conf.json +5 -0
- package/livingdocs/020.Text/030.paragraph-strong/paragraph.html +16 -0
- package/livingdocs/020.Text/030.paragraph-strong/scss/app.scss +1 -0
- package/livingdocs/020.Text/030.paragraph-strong/scss/editor.scss +0 -0
- package/livingdocs/020.Text/030.paragraph-strong/scss/general.scss +5 -0
- package/livingdocs/020.Text/030.paragraph-strong/scss/pdf.scss +1 -0
- package/livingdocs/020.Text/030.paragraph-strong/scss/web.scss +0 -0
- package/livingdocs/020.Text/030.paragraph-strong/scss/word.scss +0 -0
- package/livingdocs/020.Text/030.paragraph-strong/scss/xbrl.scss +1 -0
- package/livingdocs/020.Text/040.link/ld-conf.json +15 -0
- package/livingdocs/020.Text/040.link/link.html +12 -0
- package/livingdocs/020.Text/040.link/scss/app.scss +1 -0
- package/livingdocs/020.Text/040.link/scss/editor.scss +1 -0
- package/livingdocs/020.Text/040.link/scss/general.scss +6 -0
- package/livingdocs/020.Text/040.link/scss/pdf.scss +0 -0
- package/livingdocs/020.Text/040.link/scss/web.scss +0 -0
- package/livingdocs/020.Text/040.link/scss/word.scss +0 -0
- package/livingdocs/020.Text/040.link/scss/xbrl.scss +1 -0
- package/livingdocs/020.Text/050.quote/ld-conf.json +5 -0
- package/livingdocs/{Text/quote → 020.Text/050.quote}/properties.json +7 -7
- package/livingdocs/020.Text/050.quote/quote.html +15 -0
- package/livingdocs/020.Text/050.quote/scss/app.scss +1 -0
- package/livingdocs/020.Text/050.quote/scss/editor.scss +1 -0
- package/livingdocs/020.Text/050.quote/scss/general.scss +17 -0
- package/livingdocs/020.Text/050.quote/scss/pdf.scss +0 -0
- package/livingdocs/020.Text/050.quote/scss/web.scss +0 -0
- package/livingdocs/020.Text/050.quote/scss/word.scss +0 -0
- package/livingdocs/020.Text/050.quote/scss/xbrl.scss +1 -0
- package/livingdocs/020.Text/060.quote-with-portrait/ld-conf.json +11 -0
- package/livingdocs/020.Text/060.quote-with-portrait/quote-with-portrait.html +18 -0
- package/livingdocs/020.Text/060.quote-with-portrait/scss/app.scss +1 -0
- package/livingdocs/020.Text/060.quote-with-portrait/scss/editor.scss +1 -0
- package/livingdocs/020.Text/060.quote-with-portrait/scss/general.scss +17 -0
- package/livingdocs/020.Text/060.quote-with-portrait/scss/pdf.scss +29 -0
- package/livingdocs/020.Text/060.quote-with-portrait/scss/web.scss +24 -0
- package/livingdocs/020.Text/060.quote-with-portrait/scss/word.scss +0 -0
- package/livingdocs/020.Text/060.quote-with-portrait/scss/xbrl.scss +1 -0
- package/livingdocs/020.Text/070.footnote-container/footnote-container.html +6 -0
- package/livingdocs/020.Text/070.footnote-container/ld-conf.json +18 -0
- package/livingdocs/020.Text/070.footnote-container/scss/app.scss +1 -0
- package/livingdocs/020.Text/070.footnote-container/scss/editor.scss +1 -0
- package/livingdocs/020.Text/070.footnote-container/scss/general.scss +5 -0
- package/livingdocs/020.Text/070.footnote-container/scss/pdf.scss +0 -0
- package/livingdocs/020.Text/070.footnote-container/scss/web.scss +6 -0
- package/livingdocs/020.Text/070.footnote-container/scss/word.scss +0 -0
- package/livingdocs/020.Text/070.footnote-container/scss/xbrl.scss +1 -0
- package/livingdocs/020.Text/080.footnote-item/footnote-item.html +6 -0
- package/livingdocs/020.Text/080.footnote-item/ld-conf.json +5 -0
- package/livingdocs/020.Text/080.footnote-item/scss/app.scss +1 -0
- package/livingdocs/020.Text/080.footnote-item/scss/editor.scss +1 -0
- package/livingdocs/020.Text/080.footnote-item/scss/general.scss +28 -0
- package/livingdocs/020.Text/080.footnote-item/scss/pdf.scss +0 -0
- package/livingdocs/020.Text/080.footnote-item/scss/web.scss +0 -0
- package/livingdocs/020.Text/080.footnote-item/scss/word.scss +0 -0
- package/livingdocs/020.Text/080.footnote-item/scss/xbrl.scss +1 -0
- package/livingdocs/030.Lists/010.unordered-list/ld-conf.json +18 -0
- package/livingdocs/030.Lists/010.unordered-list/scss/app.scss +1 -0
- package/livingdocs/030.Lists/010.unordered-list/scss/editor.scss +1 -0
- package/livingdocs/030.Lists/010.unordered-list/scss/general.scss +12 -0
- package/livingdocs/030.Lists/010.unordered-list/scss/pdf.scss +0 -0
- package/livingdocs/030.Lists/010.unordered-list/scss/web.scss +0 -0
- package/livingdocs/030.Lists/010.unordered-list/scss/word.scss +0 -0
- package/livingdocs/030.Lists/010.unordered-list/scss/xbrl.scss +1 -0
- package/livingdocs/030.Lists/010.unordered-list/unordered-list.html +6 -0
- package/livingdocs/030.Lists/020.ordered-list/ld-conf.json +18 -0
- package/livingdocs/030.Lists/020.ordered-list/ordered-list.html +6 -0
- package/livingdocs/030.Lists/020.ordered-list/scss/app.scss +1 -0
- package/livingdocs/030.Lists/020.ordered-list/scss/editor.scss +1 -0
- package/livingdocs/030.Lists/020.ordered-list/scss/general.scss +9 -0
- package/livingdocs/030.Lists/020.ordered-list/scss/pdf.scss +0 -0
- package/livingdocs/030.Lists/020.ordered-list/scss/web.scss +0 -0
- package/livingdocs/030.Lists/020.ordered-list/scss/word.scss +0 -0
- package/livingdocs/030.Lists/020.ordered-list/scss/xbrl.scss +1 -0
- package/livingdocs/030.Lists/030.alphanumeric-list/alphanumeric-list.html +6 -0
- package/livingdocs/030.Lists/030.alphanumeric-list/ld-conf.json +18 -0
- package/livingdocs/030.Lists/030.alphanumeric-list/scss/app.scss +1 -0
- package/livingdocs/030.Lists/030.alphanumeric-list/scss/editor.scss +1 -0
- package/livingdocs/030.Lists/030.alphanumeric-list/scss/general.scss +9 -0
- package/livingdocs/030.Lists/030.alphanumeric-list/scss/pdf.scss +0 -0
- package/livingdocs/030.Lists/030.alphanumeric-list/scss/web.scss +0 -0
- package/livingdocs/030.Lists/030.alphanumeric-list/scss/word.scss +0 -0
- package/livingdocs/030.Lists/030.alphanumeric-list/scss/xbrl.scss +1 -0
- package/livingdocs/030.Lists/040.list-item/ld-conf.json +5 -0
- package/livingdocs/030.Lists/040.list-item/list-item.html +5 -0
- package/livingdocs/030.Lists/040.list-item/scss/app.scss +1 -0
- package/livingdocs/030.Lists/040.list-item/scss/editor.scss +1 -0
- package/livingdocs/030.Lists/040.list-item/scss/general.scss +35 -0
- package/livingdocs/030.Lists/040.list-item/scss/pdf.scss +0 -0
- package/livingdocs/030.Lists/040.list-item/scss/web.scss +0 -0
- package/livingdocs/030.Lists/040.list-item/scss/word.scss +0 -0
- package/livingdocs/030.Lists/040.list-item/scss/xbrl.scss +1 -0
- package/livingdocs/040.Media/010.table/ld-conf.json +15 -0
- package/livingdocs/040.Media/010.table/properties.json +32 -0
- package/livingdocs/040.Media/010.table/scss/app.scss +1 -0
- package/livingdocs/040.Media/010.table/scss/editor.scss +1 -0
- package/livingdocs/040.Media/010.table/scss/general.scss +328 -0
- package/livingdocs/040.Media/010.table/scss/pdf.scss +34 -0
- package/livingdocs/040.Media/010.table/scss/web.scss +14 -0
- package/livingdocs/040.Media/010.table/scss/word.scss +0 -0
- package/livingdocs/040.Media/010.table/scss/xbrl.scss +1 -0
- package/livingdocs/040.Media/010.table/table.html +9 -0
- package/livingdocs/040.Media/020.image/image.html +40 -0
- package/livingdocs/040.Media/020.image/ld-conf.json +25 -0
- package/livingdocs/040.Media/020.image/scss/app.scss +1 -0
- package/livingdocs/040.Media/020.image/scss/editor.scss +1 -0
- package/livingdocs/040.Media/020.image/scss/general.scss +17 -0
- package/livingdocs/040.Media/020.image/scss/pdf.scss +26 -0
- package/livingdocs/040.Media/020.image/scss/web.scss +1 -0
- package/livingdocs/040.Media/020.image/scss/word.scss +0 -0
- package/livingdocs/040.Media/020.image/scss/xbrl.scss +5 -0
- package/livingdocs/040.Media/030.video/ld-conf.json +19 -0
- package/livingdocs/040.Media/030.video/scss/app.scss +1 -0
- package/livingdocs/040.Media/030.video/scss/editor.scss +1 -0
- package/livingdocs/040.Media/030.video/scss/general.scss +5 -0
- package/livingdocs/040.Media/030.video/scss/pdf.scss +0 -0
- package/livingdocs/040.Media/030.video/scss/web.scss +12 -0
- package/livingdocs/040.Media/030.video/scss/word.scss +0 -0
- package/livingdocs/040.Media/030.video/scss/xbrl.scss +5 -0
- package/livingdocs/040.Media/030.video/video.html +59 -0
- package/livingdocs/040.Media/040.interactive-element/interactive-element.html +27 -0
- package/livingdocs/040.Media/040.interactive-element/ld-conf.json +6 -0
- package/livingdocs/050.Hero-and-Slider/.gitkeep +0 -0
- package/livingdocs/060.Buttons/.gitkeep +0 -0
- package/livingdocs/070.Container/010.aside-content-container/aside-content-container.html +10 -0
- package/livingdocs/070.Container/010.aside-content-container/ld-conf.json +20 -0
- package/livingdocs/070.Container/010.aside-content-container/properties.json +7 -0
- package/livingdocs/070.Container/010.aside-content-container/scss/app.scss +1 -0
- package/livingdocs/070.Container/010.aside-content-container/scss/editor.scss +1 -0
- package/livingdocs/070.Container/010.aside-content-container/scss/general.scss +1 -0
- package/livingdocs/070.Container/010.aside-content-container/scss/pdf.scss +3 -0
- package/livingdocs/070.Container/010.aside-content-container/scss/web.scss +1 -0
- package/livingdocs/070.Container/010.aside-content-container/scss/word.scss +0 -0
- package/livingdocs/070.Container/010.aside-content-container/scss/xbrl.scss +1 -0
- package/livingdocs/070.Container/020.columns-container/columns-container.html +22 -0
- package/livingdocs/070.Container/020.columns-container/ld-conf.json +17 -0
- package/livingdocs/080.CV/010.cv/cv.html +40 -0
- package/livingdocs/080.CV/010.cv/ld-conf.json +11 -0
- package/livingdocs/080.CV/020.cv-time-span/cv-time-span.html +13 -0
- package/livingdocs/080.CV/020.cv-time-span/ld-conf.json +4 -0
- package/livingdocs/090.Signatures/010.signature-container/ld-conf.json +18 -0
- package/livingdocs/090.Signatures/010.signature-container/scss/app.scss +1 -0
- package/livingdocs/090.Signatures/010.signature-container/scss/editor.scss +1 -0
- package/livingdocs/090.Signatures/010.signature-container/scss/general.scss +5 -0
- package/livingdocs/090.Signatures/010.signature-container/scss/pdf.scss +0 -0
- package/livingdocs/090.Signatures/010.signature-container/scss/web.scss +6 -0
- package/livingdocs/090.Signatures/010.signature-container/scss/word.scss +0 -0
- package/livingdocs/090.Signatures/010.signature-container/scss/xbrl.scss +1 -0
- package/livingdocs/090.Signatures/010.signature-container/signature-container.html +6 -0
- package/livingdocs/090.Signatures/020.signature-item/ld-conf.json +11 -0
- package/livingdocs/090.Signatures/020.signature-item/scss/app.scss +1 -0
- package/livingdocs/090.Signatures/020.signature-item/scss/editor.scss +1 -0
- package/livingdocs/090.Signatures/020.signature-item/scss/general.scss +9 -0
- package/livingdocs/090.Signatures/020.signature-item/scss/pdf.scss +0 -0
- package/livingdocs/090.Signatures/020.signature-item/scss/web.scss +5 -0
- package/livingdocs/090.Signatures/020.signature-item/scss/word.scss +0 -0
- package/livingdocs/090.Signatures/020.signature-item/scss/xbrl.scss +1 -0
- package/livingdocs/090.Signatures/020.signature-item/signature-item.html +9 -0
- package/livingdocs/100.Misc/010.anchor/anchor.html +8 -0
- package/livingdocs/100.Misc/010.anchor/ld-conf.json +4 -0
- package/livingdocs/100.Misc/020.accordion/accordion.html +8 -0
- package/livingdocs/100.Misc/020.accordion/ld-conf.json +26 -0
- package/livingdocs/110.PDF/010.pdf-pagebreak/ld-conf.json +4 -0
- package/livingdocs/110.PDF/010.pdf-pagebreak/pdf-pagebreak.html +1 -0
- package/livingdocs/110.PDF/020.pdf-column-container/ld-conf.json +4 -0
- package/livingdocs/110.PDF/020.pdf-column-container/pdf-column-container.html +5 -0
- package/livingdocs/110.PDF/030.pdf-publication-title/ld-conf.json +4 -0
- package/livingdocs/110.PDF/030.pdf-publication-title/pdf-publication-title.html +7 -0
- package/livingdocs/110.PDF/040.pdf-chapter-title/ld-conf.json +4 -0
- package/livingdocs/110.PDF/040.pdf-chapter-title/pdf-chapter-title.html +7 -0
- package/livingdocs/110.PDF/050.pdf-chapter-navigation-container/ld-conf.json +17 -0
- package/livingdocs/110.PDF/050.pdf-chapter-navigation-container/pdf-chapter-navigation.html +10 -0
- package/livingdocs/110.PDF/060.pdf-chapter-navigation-item/ld-conf.json +6 -0
- package/livingdocs/110.PDF/060.pdf-chapter-navigation-item/pdf-chapter-navigation-item.html +7 -0
- package/livingdocs/110.PDF/060.pdf-chapter-navigation-item/properties.json +7 -0
- package/livingdocs/110.PDF/070.pdf-cover/ld-conf.json +25 -0
- package/livingdocs/110.PDF/070.pdf-cover/pdf-cover.html +26 -0
- package/livingdocs/110.PDF/080.pdf-toc-page/ld-conf.json +15 -0
- package/livingdocs/110.PDF/080.pdf-toc-page/pdf-toc-page.html +8 -0
- package/livingdocs/{PDF_only/pdf-toc-page → 110.PDF/080.pdf-toc-page}/properties.json +20 -12
- package/livingdocs/110.PDF/090.pdf-toc-item-title/ld-conf.json +5 -0
- package/livingdocs/110.PDF/090.pdf-toc-item-title/pdf-toc-item-title.html +3 -0
- package/livingdocs/110.PDF/100.pdf-toc-item/ld-conf.json +14 -0
- package/livingdocs/110.PDF/100.pdf-toc-item/pdf-toc-item.html +6 -0
- package/livingdocs/{PDF_only/pdf-toc-item → 110.PDF/100.pdf-toc-item}/properties.json +7 -7
- package/livingdocs/110.PDF/110.pdf-toc-item-blank/ld-conf.json +5 -0
- package/livingdocs/110.PDF/110.pdf-toc-item-blank/pdf-toc-item-blank.html +4 -0
- package/livingdocs/120.Startpage/.gitkeep +0 -0
- package/livingdocs/999.Properties/alignment/properties.json +36 -0
- package/livingdocs/{Text/quote-with-portrait → 999.Properties/hide-quote-characters}/properties.json +7 -12
- package/livingdocs/999.Properties/pdf-spacer/properties.json +43 -0
- package/livingdocs/999.Properties/width/properties.json +32 -0
- package/package.json +48 -50
- package/scripts/beaver.js +317 -316
- package/scripts/build.d.ts +4 -7
- package/scripts/build.js +837 -812
- package/scripts/components.js +564 -566
- package/scripts/config.d.ts +8 -0
- package/scripts/config.js +52 -1
- package/scripts/doPublish.js +55 -43
- package/scripts/folders.d.ts +43 -0
- package/scripts/folders.js +46 -0
- package/scripts/init.js +65 -45
- package/scripts/ldd/LivingdocsDesignValidator.d.ts +61 -0
- package/scripts/ldd/LivingdocsDesignValidator.js +296 -0
- package/scripts/ldd/__tests__/LivingdocsDesignValidation.test.mjs +273 -0
- package/scripts/ldd/mapLdd.d.ts +1 -0
- package/scripts/ldd/mapLdd.js +204 -0
- package/scripts/prepare.d.ts +2 -0
- package/scripts/prepare.js +66 -0
- package/scripts/preparePublish.d.ts +1 -1
- package/scripts/preparePublish.js +121 -88
- package/scripts/renamePackage.js +48 -48
- package/scripts/utils.d.ts +45 -30
- package/scripts/utils.js +163 -106
- package/srl/components/Srl/Aria/TabChain.vue +100 -0
- package/srl/components/Srl/Article/Autoload.vue +41 -0
- package/srl/components/Srl/Article/DialogButton.vue +55 -0
- package/srl/components/Srl/Article/Root.vue +76 -0
- package/srl/components/Srl/Menu/Item/Content/Image.vue +12 -0
- package/srl/components/Srl/Menu/Item/Content/ImageAfter.vue +13 -0
- package/srl/components/Srl/Menu/Item/Content/ImageBefore.vue +13 -0
- package/srl/components/Srl/Menu/Item/Content/Text.vue +9 -0
- package/srl/components/Srl/Menu/Item/Content.vue +23 -0
- package/srl/components/Srl/Menu/Item.vue +208 -0
- package/srl/components/Srl/Menu/List.vue +184 -0
- package/srl/components/Srl/Page/App.vue +65 -0
- package/srl/components/Srl/Page/Dialog.vue +71 -0
- package/srl/composables/article.ts +24 -0
- package/srl/composables/articles.ts +41 -0
- package/srl/composables/config.ts +165 -0
- package/srl/composables/downloads.ts +46 -0
- package/srl/composables/index.ts +34 -0
- package/srl/composables/locale.ts +8 -0
- package/srl/composables/menu.ts +101 -0
- package/srl/composables/root.ts +5 -0
- package/srl/composables/search.ts +108 -0
- package/srl/composables/settings.ts +9 -0
- package/srl/composables/viewPort.ts +78 -0
- package/srl/imports/app.scss +0 -0
- package/srl/imports/ldd.scss +0 -0
- package/srl/imports/pdf.scss +0 -0
- package/srl/imports/word.scss +0 -0
- package/srl/imports/xbrl.scss +0 -0
- package/srl/plugins/asyncLdComponent.ts +2 -0
- package/srl/plugins/initProject.ts +19 -0
- package/srl/plugins/viteSrlPlugin.ts +214 -0
- package/srl/plugins/vueSrlPlugin.ts +23 -0
- package/{scss → srl/scss}/colors/functions.scss +18 -18
- package/{scss/helpers → srl/scss/colors}/index.scss +3 -3
- package/{scss → srl/scss}/colors/mixins.scss +45 -45
- package/{scss → srl/scss}/colors/variables.scss +6 -6
- package/srl/scss/config.scss +7 -0
- package/{scss → srl/scss}/core-styles.scss +23 -22
- package/{scss → srl/scss}/fonts/functions.scss +21 -21
- package/{scss/colors → srl/scss/fonts}/index.scss +3 -3
- package/{scss → srl/scss}/fonts/mixins.scss +31 -31
- package/{scss → srl/scss}/fonts/variables.scss +8 -8
- package/{scss → srl/scss}/grid/functions.scss +49 -29
- package/{scss/fonts → srl/scss/grid}/index.scss +3 -3
- package/{scss → srl/scss}/grid/mixins.scss +246 -388
- package/{scss → srl/scss}/grid/variables.scss +11 -10
- package/srl/scss/helpers/functions.scss +0 -0
- package/{scss/grid → srl/scss/helpers}/index.scss +3 -3
- package/{scss → srl/scss}/helpers/mixins.scss +54 -87
- package/{scss → srl/scss}/helpers/variables.scss +7 -7
- package/{scss → srl/scss}/index.scss +8 -8
- package/{scss → srl/scss}/meta/functions.scss +64 -64
- package/srl/scss/meta/index.scss +3 -0
- package/{scss → srl/scss}/meta/mixins.scss +6 -6
- package/{scss → srl/scss}/meta/variables.scss +8 -8
- package/{scss → srl/scss}/spacer/functions.scss +9 -9
- package/srl/scss/spacer/index.scss +3 -0
- package/{scss → srl/scss}/spacer/mixins.scss +236 -236
- package/{scss → srl/scss}/spacer/variables.scss +6 -6
- package/{scss → srl/scss}/system/functions.scss +77 -77
- package/srl/scss/system/index.scss +3 -0
- package/{scss → srl/scss}/system/mixins.scss +27 -27
- package/{scss → srl/scss}/system/root.scss +39 -39
- package/{scss → srl/scss}/system/variables.scss +13 -13
- package/{scss → srl/scss}/typography/functions.scss +63 -63
- package/srl/scss/typography/index.scss +3 -0
- package/{scss → srl/scss}/typography/mixins.scss +302 -262
- package/{scss → srl/scss}/typography/variables.scss +11 -11
- package/srl/scss/xbrl-core-styles.scss +47 -0
- package/{dev/nswow → srl/srl}/ArticleAutoloader.ts +100 -100
- package/{dev/nswow → srl/srl}/ArticleLoader.ts +98 -91
- package/srl/srl/Awesomizr.js +682 -0
- package/srl/srl/colors.scss +3 -0
- package/srl/srl/config.scss +7 -0
- package/srl/srl/core-styles.scss +2 -0
- package/srl/srl/fonts.scss +2 -0
- package/srl/srl/grid.scss +2 -0
- package/srl/srl/helpers.scss +2 -0
- package/{dev/nswow → srl/srl}/index.scss +9 -9
- package/srl/srl/meta.scss +2 -0
- package/srl/srl/pdf.scss +2 -0
- package/srl/srl/spacer.scss +2 -0
- package/srl/srl/system.scss +2 -0
- package/srl/srl/typography.scss +3 -0
- package/srl/types/components.d.ts +17 -0
- package/srl/types/nswow.d.ts +121 -0
- package/srl/utils/camelCase.ts +11 -0
- package/srl/utils/html.ts +82 -0
- package/srl/utils/index.ts +5 -0
- package/srl/utils/uri.ts +52 -0
- package/dev/ldd.html +0 -7
- package/dev/livingdocs/Media/image/app.scss +0 -25
- package/dev/livingdocs/Media/image/general.scss +0 -11
- package/dev/livingdocs/Media/image/image.html +0 -46
- package/dev/livingdocs/Media/image/ldd.scss +0 -1
- package/dev/livingdocs/Media/image/pdf.scss +0 -1
- package/dev/livingdocs/Media/image/print.scss +0 -7
- package/dev/livingdocs/Media/image/properties.json +0 -41
- package/dev/livingdocs/Media/image/word.scss +0 -1
- package/dev/livingdocs/Properties/grid/app.scss +0 -1
- package/dev/livingdocs/Properties/grid/general.scss +0 -95
- package/dev/livingdocs/Properties/grid/ldd.scss +0 -1
- package/dev/livingdocs/Properties/grid/pdf.scss +0 -1
- package/dev/livingdocs/Properties/grid/print.scss +0 -94
- package/dev/livingdocs/Properties/grid/properties.json +0 -68
- package/dev/livingdocs/Properties/grid/web.scss +0 -98
- package/dev/livingdocs/Properties/grid/word.scss +0 -1
- package/dev/livingdocs/Text/paragraph/general.scss +0 -9
- package/dev/livingdocs/Text/paragraph/paragraph.html +0 -22
- package/dev/livingdocs/Titles/title-h1/general.scss +0 -10
- package/dev/livingdocs/Titles/title-h1/title-h1.html +0 -16
- package/dev/livingdocs/Titles/title-h2/app.scss +0 -1
- package/dev/livingdocs/Titles/title-h2/general.scss +0 -13
- package/dev/livingdocs/Titles/title-h2/ldd.scss +0 -1
- package/dev/livingdocs/Titles/title-h2/pdf.scss +0 -1
- package/dev/livingdocs/Titles/title-h2/print.scss +0 -36
- package/dev/livingdocs/Titles/title-h2/title-h2.html +0 -24
- package/dev/livingdocs/Titles/title-h2/web.scss +0 -27
- package/dev/livingdocs/Titles/title-h2/word.scss +0 -1
- package/dev/livingdocs/Titles/title-h3/app.scss +0 -1
- package/dev/livingdocs/Titles/title-h3/general.scss +0 -13
- package/dev/livingdocs/Titles/title-h3/ldd.scss +0 -1
- package/dev/livingdocs/Titles/title-h3/pdf.scss +0 -1
- package/dev/livingdocs/Titles/title-h3/print.scss +0 -34
- package/dev/livingdocs/Titles/title-h3/title-h3.html +0 -24
- package/dev/livingdocs/Titles/title-h3/web.scss +0 -27
- package/dev/livingdocs/Titles/title-h3/word.scss +0 -1
- package/dev/livingdocs/Titles/title-h4/app.scss +0 -1
- package/dev/livingdocs/Titles/title-h4/general.scss +0 -13
- package/dev/livingdocs/Titles/title-h4/ldd.scss +0 -1
- package/dev/livingdocs/Titles/title-h4/pdf.scss +0 -1
- package/dev/livingdocs/Titles/title-h4/print.scss +0 -34
- package/dev/livingdocs/Titles/title-h4/title-h4.html +0 -24
- package/dev/livingdocs/Titles/title-h4/web.scss +0 -27
- package/dev/livingdocs/Titles/title-h4/word.scss +0 -1
- package/dev/livingdocs/Titles/title-h5/general.scss +0 -10
- package/dev/livingdocs/Titles/title-h5/title-h5.html +0 -16
- package/dev/livingdocs/Titles/title-h6/general.scss +0 -10
- package/dev/livingdocs/Titles/title-h6/title-h6.html +0 -16
- package/dev/nswow/colors.scss +0 -3
- package/dev/nswow/config.scss +0 -13
- package/dev/nswow/core-styles.scss +0 -2
- package/dev/nswow/fonts.scss +0 -2
- package/dev/nswow/grid.scss +0 -2
- package/dev/nswow/helpers.scss +0 -2
- package/dev/nswow/meta.scss +0 -2
- package/dev/nswow/spacer.scss +0 -2
- package/dev/nswow/system.scss +0 -2
- package/dev/nswow/typography.scss +0 -3
- package/dev/nswow.config.json +0 -293
- package/dev/pdf.ts +0 -1
- package/dev/src/components/LanguageSwitch.vue +0 -100
- package/dev/src/components/MenuItem/MenuArticle.vue +0 -15
- package/dev/src/components/MenuItem/MenuEntry.vue +0 -26
- package/dev/src/components/MenuItem/MenuExternal.vue +0 -28
- package/dev/src/components/MenuItem/index.ts +0 -5
- package/dev/src/components/PageModal.vue +0 -95
- package/dev/src/components/ScrollToTop.vue +0 -63
- package/dev/src/composables/config.ts +0 -48
- package/dev/src/main.ts +0 -16
- package/dev/src/types/nswow.d.ts +0 -73
- package/dev/src/views/DownloadsView.vue +0 -88
- package/dev/src/views/SearchView.vue +0 -126
- package/dev/word.ts +0 -1
- package/livingdocs/Buttons/button/app.scss +0 -1
- package/livingdocs/Buttons/button/button.html +0 -18
- package/livingdocs/Buttons/button/general.scss +0 -33
- package/livingdocs/Buttons/button/ldd.scss +0 -1
- package/livingdocs/Buttons/button/pdf.scss +0 -1
- package/livingdocs/Buttons/button/word.scss +0 -1
- package/livingdocs/Buttons/button-container/app.scss +0 -1
- package/livingdocs/Buttons/button-container/button-container.html +0 -31
- package/livingdocs/Buttons/button-container/general.scss +0 -12
- package/livingdocs/Buttons/button-container/ldd.scss +0 -1
- package/livingdocs/Buttons/button-container/pdf.scss +0 -3
- package/livingdocs/Buttons/button-container/properties.json +0 -19
- package/livingdocs/Buttons/button-container/word.scss +0 -3
- package/livingdocs/CV/cv-timeline/app.scss +0 -1
- package/livingdocs/CV/cv-timeline/cv-timeline.html +0 -19
- package/livingdocs/CV/cv-timeline/general.scss +0 -1
- package/livingdocs/CV/cv-timeline/ldd.scss +0 -1
- package/livingdocs/CV/cv-timeline/pdf.scss +0 -1
- package/livingdocs/CV/cv-timeline/print.scss +0 -35
- package/livingdocs/CV/cv-timeline/web.scss +0 -27
- package/livingdocs/CV/cv-timeline/word.scss +0 -1
- package/livingdocs/Container/column-container/column-container.html +0 -44
- package/livingdocs/Container/column-container/general.scss +0 -105
- package/livingdocs/Container/column-container/properties.json +0 -83
- package/livingdocs/Lists/alphanumeric-list-group/alphanumeric-list-group.html +0 -25
- package/livingdocs/Lists/alphanumeric-list-group/app.scss +0 -1
- package/livingdocs/Lists/alphanumeric-list-group/general.scss +0 -5
- package/livingdocs/Lists/alphanumeric-list-group/ldd.scss +0 -1
- package/livingdocs/Lists/alphanumeric-list-group/pdf.scss +0 -1
- package/livingdocs/Lists/alphanumeric-list-group/word.scss +0 -1
- package/livingdocs/Lists/list-item/app.scss +0 -1
- package/livingdocs/Lists/list-item/general.scss +0 -4
- package/livingdocs/Lists/list-item/ldd.scss +0 -1
- package/livingdocs/Lists/list-item/list-item.html +0 -17
- package/livingdocs/Lists/list-item/pdf.scss +0 -1
- package/livingdocs/Lists/list-item/word.scss +0 -1
- package/livingdocs/Lists/ordered-list-group/app.scss +0 -1
- package/livingdocs/Lists/ordered-list-group/general.scss +0 -5
- package/livingdocs/Lists/ordered-list-group/ldd.scss +0 -1
- package/livingdocs/Lists/ordered-list-group/ordered-list-group.html +0 -25
- package/livingdocs/Lists/ordered-list-group/pdf.scss +0 -1
- package/livingdocs/Lists/ordered-list-group/word.scss +0 -1
- package/livingdocs/Lists/unordered-list-group/app.scss +0 -1
- package/livingdocs/Lists/unordered-list-group/general.scss +0 -5
- package/livingdocs/Lists/unordered-list-group/ldd.scss +0 -1
- package/livingdocs/Lists/unordered-list-group/pdf.scss +0 -1
- package/livingdocs/Lists/unordered-list-group/unordered-list-group.html +0 -25
- package/livingdocs/Lists/unordered-list-group/word.scss +0 -1
- package/livingdocs/Media/chart/app.scss +0 -19
- package/livingdocs/Media/chart/chart.html +0 -29
- package/livingdocs/Media/chart/general.scss +0 -11
- package/livingdocs/Media/chart/ldd.scss +0 -1
- package/livingdocs/Media/chart/pdf.scss +0 -9
- package/livingdocs/Media/chart/properties.json +0 -41
- package/livingdocs/Media/chart/word.scss +0 -1
- package/livingdocs/Media/graphic/app.scss +0 -1
- package/livingdocs/Media/graphic/general.scss +0 -18
- package/livingdocs/Media/graphic/graphic.html +0 -29
- package/livingdocs/Media/graphic/ldd.scss +0 -1
- package/livingdocs/Media/graphic/pdf.scss +0 -1
- package/livingdocs/Media/graphic/properties.json +0 -36
- package/livingdocs/Media/graphic/word.scss +0 -1
- package/livingdocs/Media/image/app.scss +0 -25
- package/livingdocs/Media/image/general.scss +0 -11
- package/livingdocs/Media/image/image.html +0 -55
- package/livingdocs/Media/image/ldd.scss +0 -1
- package/livingdocs/Media/image/pdf.scss +0 -1
- package/livingdocs/Media/image/print.scss +0 -7
- package/livingdocs/Media/image/properties.json +0 -41
- package/livingdocs/Media/image/word.scss +0 -1
- package/livingdocs/Media/nswow-table/app.scss +0 -2
- package/livingdocs/Media/nswow-table/app.ts +0 -35
- package/livingdocs/Media/nswow-table/general.scss +0 -281
- package/livingdocs/Media/nswow-table/ldd.scss +0 -2
- package/livingdocs/Media/nswow-table/nswow-table.html +0 -30
- package/livingdocs/Media/nswow-table/pdf.scss +0 -8
- package/livingdocs/Media/nswow-table/properties.json +0 -66
- package/livingdocs/Media/nswow-table/web.scss +0 -23
- package/livingdocs/Media/nswow-table/word.scss +0 -2
- package/livingdocs/Media/video/app.scss +0 -1
- package/livingdocs/Media/video/general.scss +0 -7
- package/livingdocs/Media/video/ldd.scss +0 -1
- package/livingdocs/Media/video/pdf.scss +0 -1
- package/livingdocs/Media/video/print.scss +0 -5
- package/livingdocs/Media/video/properties.json +0 -41
- package/livingdocs/Media/video/video.html +0 -26
- package/livingdocs/Media/video/word.scss +0 -1
- package/livingdocs/Misc/accordion/accordion.html +0 -56
- package/livingdocs/Misc/accordion/app.scss +0 -63
- package/livingdocs/Misc/accordion/app.ts +0 -10
- package/livingdocs/Misc/accordion/general.scss +0 -44
- package/livingdocs/Misc/accordion/ldd.scss +0 -36
- package/livingdocs/Misc/accordion/pdf.scss +0 -39
- package/livingdocs/Misc/accordion/word.scss +0 -39
- package/livingdocs/Misc/anchor/anchor.html +0 -15
- package/livingdocs/Misc/anchor/app.scss +0 -10
- package/livingdocs/Misc/anchor/app.ts +0 -11
- package/livingdocs/Misc/anchor/general.scss +0 -1
- package/livingdocs/Misc/anchor/pdf.scss +0 -1
- package/livingdocs/Misc/anchor/print.scss +0 -3
- package/livingdocs/Misc/anchor/word.scss +0 -1
- package/livingdocs/Misc/spacer/app.scss +0 -1
- package/livingdocs/Misc/spacer/general.scss +0 -8
- package/livingdocs/Misc/spacer/ldd.scss +0 -1
- package/livingdocs/Misc/spacer/pdf.scss +0 -1
- package/livingdocs/Misc/spacer/print.scss +0 -18
- package/livingdocs/Misc/spacer/properties.json +0 -52
- package/livingdocs/Misc/spacer/spacer.html +0 -12
- package/livingdocs/Misc/spacer/web.scss +0 -18
- package/livingdocs/Misc/spacer/word.scss +0 -1
- package/livingdocs/PDF_only/pdf-cover/ldd.scss +0 -42
- package/livingdocs/PDF_only/pdf-cover/pdf-cover.html +0 -29
- package/livingdocs/PDF_only/pdf-cover/pdf.scss +0 -1
- package/livingdocs/PDF_only/pdf-cover/word.scss +0 -1
- package/livingdocs/PDF_only/pdf-cover-chapter/ldd.scss +0 -19
- package/livingdocs/PDF_only/pdf-cover-chapter/pdf-chapter-cover.html +0 -18
- package/livingdocs/PDF_only/pdf-cover-chapter/pdf.scss +0 -1
- package/livingdocs/PDF_only/pdf-cover-chapter/print.scss +0 -19
- package/livingdocs/PDF_only/pdf-cover-chapter/word.scss +0 -1
- package/livingdocs/PDF_only/pdf-pagebreak/general.scss +0 -4
- package/livingdocs/PDF_only/pdf-pagebreak/ldd.scss +0 -5
- package/livingdocs/PDF_only/pdf-pagebreak/pdf-pagebreak.html +0 -8
- package/livingdocs/PDF_only/pdf-publication-title/general.scss +0 -5
- package/livingdocs/PDF_only/pdf-publication-title/pdf-publication-title.html +0 -15
- package/livingdocs/PDF_only/pdf-toc-item/general.scss +0 -41
- package/livingdocs/PDF_only/pdf-toc-item/pdf-toc-item.html +0 -33
- package/livingdocs/PDF_only/pdf-toc-item-blank/general.scss +0 -5
- package/livingdocs/PDF_only/pdf-toc-item-blank/pdf-toc-item-blank.html +0 -11
- package/livingdocs/PDF_only/pdf-toc-item-title/general.scss +0 -5
- package/livingdocs/PDF_only/pdf-toc-item-title/pdf-toc-item-title.html +0 -11
- package/livingdocs/PDF_only/pdf-toc-page/app.scss +0 -1
- package/livingdocs/PDF_only/pdf-toc-page/general.scss +0 -1
- package/livingdocs/PDF_only/pdf-toc-page/ldd.scss +0 -1
- package/livingdocs/PDF_only/pdf-toc-page/pdf-toc-page.html +0 -33
- package/livingdocs/PDF_only/pdf-toc-page/pdf.scss +0 -1
- package/livingdocs/PDF_only/pdf-toc-page/word.scss +0 -1
- package/livingdocs/PDF_only/pdf-video-link/ldd.scss +0 -16
- package/livingdocs/PDF_only/pdf-video-link/pdf-video-link.html +0 -41
- package/livingdocs/PDF_only/pdf-video-link/pdf.scss +0 -1
- package/livingdocs/PDF_only/pdf-video-link/print.scss +0 -12
- package/livingdocs/PDF_only/pdf-video-link/word.scss +0 -1
- package/livingdocs/Properties/grid/app.scss +0 -1
- package/livingdocs/Properties/grid/general.scss +0 -95
- package/livingdocs/Properties/grid/ldd.scss +0 -1
- package/livingdocs/Properties/grid/pdf.scss +0 -1
- package/livingdocs/Properties/grid/print.scss +0 -94
- package/livingdocs/Properties/grid/properties.json +0 -68
- package/livingdocs/Properties/grid/web.scss +0 -98
- package/livingdocs/Properties/grid/word.scss +0 -1
- package/livingdocs/Signatures/signature-container/app.scss +0 -1
- package/livingdocs/Signatures/signature-container/general.scss +0 -7
- package/livingdocs/Signatures/signature-container/ldd.scss +0 -1
- package/livingdocs/Signatures/signature-container/pdf.scss +0 -1
- package/livingdocs/Signatures/signature-container/signature-container.html +0 -30
- package/livingdocs/Signatures/signature-container/word.scss +0 -1
- package/livingdocs/Signatures/signature-item/app.scss +0 -1
- package/livingdocs/Signatures/signature-item/general.scss +0 -53
- package/livingdocs/Signatures/signature-item/ldd.scss +0 -1
- package/livingdocs/Signatures/signature-item/pdf.scss +0 -1
- package/livingdocs/Signatures/signature-item/signature-item.html +0 -23
- package/livingdocs/Signatures/signature-item/word.scss +0 -1
- package/livingdocs/Text/footnote/app.scss +0 -1
- package/livingdocs/Text/footnote/footnote.html +0 -14
- package/livingdocs/Text/footnote/general.scss +0 -12
- package/livingdocs/Text/footnote/ldd.scss +0 -1
- package/livingdocs/Text/footnote/pdf.scss +0 -1
- package/livingdocs/Text/footnote/print.scss +0 -36
- package/livingdocs/Text/footnote/web.scss +0 -27
- package/livingdocs/Text/footnote/word.scss +0 -1
- package/livingdocs/Text/lead/general.scss +0 -9
- package/livingdocs/Text/lead/lead.html +0 -23
- package/livingdocs/Text/paragraph/general.scss +0 -9
- package/livingdocs/Text/quote/general.scss +0 -43
- package/livingdocs/Text/quote/quote.html +0 -29
- package/livingdocs/Text/quote-with-portrait/general.scss +0 -81
- package/livingdocs/Text/quote-with-portrait/quote-with-portrait.html +0 -49
- package/livingdocs/Titles/title-h1/general.scss +0 -10
- package/livingdocs/Titles/title-h1/title-h1.html +0 -16
- package/livingdocs/Titles/title-h2/app.scss +0 -1
- package/livingdocs/Titles/title-h2/general.scss +0 -13
- package/livingdocs/Titles/title-h2/ldd.scss +0 -1
- package/livingdocs/Titles/title-h2/pdf.scss +0 -1
- package/livingdocs/Titles/title-h2/print.scss +0 -36
- package/livingdocs/Titles/title-h2/title-h2.html +0 -26
- package/livingdocs/Titles/title-h2/web.scss +0 -27
- package/livingdocs/Titles/title-h2/word.scss +0 -1
- package/livingdocs/Titles/title-h3/app.scss +0 -1
- package/livingdocs/Titles/title-h3/general.scss +0 -13
- package/livingdocs/Titles/title-h3/ldd.scss +0 -1
- package/livingdocs/Titles/title-h3/pdf.scss +0 -1
- package/livingdocs/Titles/title-h3/print.scss +0 -34
- package/livingdocs/Titles/title-h3/title-h3.html +0 -26
- package/livingdocs/Titles/title-h3/web.scss +0 -27
- package/livingdocs/Titles/title-h3/word.scss +0 -1
- package/livingdocs/Titles/title-h4/app.scss +0 -1
- package/livingdocs/Titles/title-h4/general.scss +0 -13
- package/livingdocs/Titles/title-h4/ldd.scss +0 -1
- package/livingdocs/Titles/title-h4/pdf.scss +0 -1
- package/livingdocs/Titles/title-h4/print.scss +0 -34
- package/livingdocs/Titles/title-h4/title-h4.html +0 -26
- package/livingdocs/Titles/title-h4/web.scss +0 -27
- package/livingdocs/Titles/title-h4/word.scss +0 -1
- package/livingdocs/Titles/title-h5/general.scss +0 -10
- package/livingdocs/Titles/title-h5/title-h5.html +0 -16
- package/livingdocs/Titles/title-h6/general.scss +0 -10
- package/livingdocs/Titles/title-h6/title-h6.html +0 -16
- package/preparePublish.cjs +0 -95
- package/scripts/migrate-livingdocs-build/LICENSE +0 -21
- package/scripts/migrate-livingdocs-build/bin/build.d.ts +0 -8
- package/scripts/migrate-livingdocs-build/bin/build.js +0 -53
- package/scripts/migrate-livingdocs-build/bin/migrate.d.ts +0 -2
- package/scripts/migrate-livingdocs-build/bin/migrate.js +0 -43
- package/scripts/migrate-livingdocs-build/dev/build/v1.d.ts +0 -9
- package/scripts/migrate-livingdocs-build/dev/build/v1.d.ts.map +0 -1
- package/scripts/migrate-livingdocs-build/dev/build/v1.js +0 -51
- package/scripts/migrate-livingdocs-build/dev/build/v2.d.ts +0 -2
- package/scripts/migrate-livingdocs-build/dev/build/v2.d.ts.map +0 -1
- package/scripts/migrate-livingdocs-build/dev/build/v2.js +0 -44
- package/scripts/migrate-livingdocs-build/dev/build/zip-archive.d.ts +0 -2
- package/scripts/migrate-livingdocs-build/dev/build/zip-archive.d.ts.map +0 -1
- package/scripts/migrate-livingdocs-build/dev/build/zip-archive.js +0 -39
- package/scripts/migrate-livingdocs-build/dev/build.d.ts +0 -9
- package/scripts/migrate-livingdocs-build/dev/build.js +0 -7
- package/scripts/migrate-livingdocs-build/dev/configuration-defaults.d.ts +0 -20
- package/scripts/migrate-livingdocs-build/dev/configuration-defaults.js +0 -18
- package/scripts/migrate-livingdocs-build/dev/configuration.d.ts +0 -2
- package/scripts/migrate-livingdocs-build/dev/configuration.js +0 -34
- package/scripts/migrate-livingdocs-build/dev/lib.d.ts +0 -33
- package/scripts/migrate-livingdocs-build/dev/lib.js +0 -251
- package/scripts/migrate-livingdocs-build/dev/livingdocs-design.d.ts +0 -9
- package/scripts/migrate-livingdocs-build/dev/livingdocs-design.js +0 -80
- package/scripts/migrate-livingdocs-build/dev/logger.d.ts +0 -2
- package/scripts/migrate-livingdocs-build/dev/logger.js +0 -16
- package/scripts/migrate-livingdocs-build/dev/migrate.d.ts +0 -22
- package/scripts/migrate-livingdocs-build/dev/migrate.js +0 -241
- package/scripts/migrate-livingdocs-build/readme.md +0 -62
- package/scripts/vite.d.ts +0 -10
- package/scripts/vite.js +0 -58
- package/scss/config.scss +0 -7
- package/scss/meta/index.scss +0 -3
- package/scss/spacer/index.scss +0 -3
- package/scss/system/index.scss +0 -3
- package/scss/typography/index.scss +0 -3
- package/tags.txt +0 -1
- /package/dev/livingdocs/{Media/image/web.scss → .gitkeep} +0 -0
- /package/{dev/public/.keep → livingdocs/010.Titles/010.title-h1/scss/pdf.scss} +0 -0
- /package/livingdocs/{Lists/alphanumeric-list-group → 010.Titles/010.title-h1/scss}/web.scss +0 -0
- /package/livingdocs/{Lists/alphanumeric-list-group/print.scss → 010.Titles/010.title-h1/scss/word.scss} +0 -0
- /package/livingdocs/{Lists/list-item/print.scss → 010.Titles/020.title-h2/scss/pdf.scss} +0 -0
- /package/livingdocs/{Lists/list-item → 010.Titles/020.title-h2/scss}/web.scss +0 -0
- /package/livingdocs/{Lists/ordered-list-group/print.scss → 010.Titles/020.title-h2/scss/word.scss} +0 -0
- /package/livingdocs/{Lists/ordered-list-group/web.scss → 010.Titles/030.title-h3/scss/pdf.scss} +0 -0
- /package/livingdocs/{Lists/unordered-list-group → 010.Titles/030.title-h3/scss}/web.scss +0 -0
- /package/livingdocs/{Lists/unordered-list-group/print.scss → 010.Titles/030.title-h3/scss/word.scss} +0 -0
- /package/livingdocs/{Media/chart/print.scss → 010.Titles/040.title-h4/scss/pdf.scss} +0 -0
- /package/livingdocs/{Media/chart → 010.Titles/040.title-h4/scss}/web.scss +0 -0
- /package/livingdocs/{Media/graphic/print.scss → 010.Titles/040.title-h4/scss/word.scss} +0 -0
- /package/livingdocs/{Media/graphic/web.scss → 010.Titles/050.title-h5/scss/pdf.scss} +0 -0
- /package/livingdocs/{Media/image → 010.Titles/050.title-h5/scss}/web.scss +0 -0
- /package/livingdocs/{Media/nswow-table/print.scss → 010.Titles/050.title-h5/scss/word.scss} +0 -0
- /package/livingdocs/{Media/video/web.scss → 010.Titles/060.title-h6/scss/pdf.scss} +0 -0
- /package/livingdocs/{Signatures/signature-container → 010.Titles/060.title-h6/scss}/web.scss +0 -0
- /package/livingdocs/{PDF_only/pdf-cover/print.scss → 010.Titles/060.title-h6/scss/word.scss} +0 -0
- /package/livingdocs/{Signatures/signature-container/print.scss → 020.Text/010.lead/scss/pdf.scss} +0 -0
- /package/livingdocs/{Signatures/signature-item → 020.Text/010.lead/scss}/web.scss +0 -0
- /package/livingdocs/{Signatures/signature-item/print.scss → 020.Text/010.lead/scss/word.scss} +0 -0
- /package/{scss/helpers/functions.scss → livingdocs/020.Text/020.paragraph/scss/pdf.scss} +0 -0
|
@@ -0,0 +1,682 @@
|
|
|
1
|
+
const Awesomizr = {};
|
|
2
|
+
|
|
3
|
+
// Data types
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* @typedef {Object} IdValue
|
|
7
|
+
* @property {number} index - The the index.
|
|
8
|
+
* @property {string} prefix - The prefix.
|
|
9
|
+
* @property {string} value - The ID's content.
|
|
10
|
+
*
|
|
11
|
+
* @memberof Awesomizr
|
|
12
|
+
*/
|
|
13
|
+
|
|
14
|
+
// Methods
|
|
15
|
+
|
|
16
|
+
/**
|
|
17
|
+
* Checks if the element matches a particular selector. This is useful when used in browsers that don't support the standard "matches" function.
|
|
18
|
+
*
|
|
19
|
+
* @param {HTMLElement} ele The element.
|
|
20
|
+
* @param {string} selector The selector.
|
|
21
|
+
* @returns True, if the element matches the given selector, false otherwise.
|
|
22
|
+
*/
|
|
23
|
+
export function matchesSelector(ele, selector) {
|
|
24
|
+
if (!ele || !(ele instanceof HTMLElement)) {
|
|
25
|
+
throw 'The first parameter must indicate an HTML element';
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
if (selector) {
|
|
29
|
+
const matchesList = [
|
|
30
|
+
'matches',
|
|
31
|
+
'webkitMatches',
|
|
32
|
+
'mozMatches',
|
|
33
|
+
'msMatches',
|
|
34
|
+
'oMatches',
|
|
35
|
+
'matchesSelector',
|
|
36
|
+
'webkitMatchesSelector',
|
|
37
|
+
'mozMatchesSelector',
|
|
38
|
+
'msMatchesSelector',
|
|
39
|
+
'oMatchesSelector',
|
|
40
|
+
];
|
|
41
|
+
|
|
42
|
+
for (let i = 0; i < matchesList.length; i++) {
|
|
43
|
+
if (typeof ele[matchesList[i]] == 'function') {
|
|
44
|
+
matchesSelector = function (e, s) {
|
|
45
|
+
return e[matchesList[i]](s);
|
|
46
|
+
};
|
|
47
|
+
|
|
48
|
+
return matchesSelector(ele, selector);
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
return false;
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
/**
|
|
57
|
+
* Generates the next unused ID by incrementing the start value. If the ID is already in use in the document,
|
|
58
|
+
* The start value is incremented again until an unused ID is found.
|
|
59
|
+
*
|
|
60
|
+
* @param {number} startValue The start value.
|
|
61
|
+
* @param {string} prefix A prefix to use for the ID since IDs starting with numbers are disallowed.
|
|
62
|
+
* @param {string} [suffix] An optional suffix.
|
|
63
|
+
* @returns {IdValue} A currently unused ID value.
|
|
64
|
+
*/
|
|
65
|
+
export function getNextId(startValue, prefix, suffix) {
|
|
66
|
+
if (
|
|
67
|
+
startValue === undefined ||
|
|
68
|
+
(typeof startValue).toLowerCase() != 'number'
|
|
69
|
+
) {
|
|
70
|
+
startValue = 0;
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
if (
|
|
74
|
+
prefix === undefined ||
|
|
75
|
+
(typeof prefix).toLowerCase() != 'string' ||
|
|
76
|
+
!prefix
|
|
77
|
+
) {
|
|
78
|
+
prefix = 'ro-id';
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
if (suffix === undefined || (typeof suffix).toLowerCase() != 'string') {
|
|
82
|
+
suffix = '';
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
let index = startValue;
|
|
86
|
+
|
|
87
|
+
while (document.getElementById(prefix + index + suffix)) {
|
|
88
|
+
index++;
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
return { index: index, prefix: prefix, value: prefix + index + suffix };
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
/**
|
|
95
|
+
* This function transforms and rotates a table header, in order to reduce its width. If there is no table header, the first line is converted to one.
|
|
96
|
+
*
|
|
97
|
+
* @param {HTMLTableElement} table The HTML node of the table.
|
|
98
|
+
* @param {object} [params] An object of optional parameters.
|
|
99
|
+
* @param {number} [params.angle=45] The angle in degrees at which the header will be rotated. Must be between -90 and 90 (exclusive).
|
|
100
|
+
* @param {string} [params.width="auto"] The width that the header cells should have after the transformation, e.g. "20pt".
|
|
101
|
+
* @param {boolean} [params.firstCol=false] Whether to prevent the first column from being transformed.
|
|
102
|
+
* @param {boolean} [params.lastCol=false] Whether to prevent the last column from being transformed.
|
|
103
|
+
* @param {boolean} [params.footer=false] Whether to create a "tfoot" element from the last row in the table. Has no effect if the table already contains a "tfoot".
|
|
104
|
+
*/
|
|
105
|
+
export function rotateTableHeader(
|
|
106
|
+
table,
|
|
107
|
+
{
|
|
108
|
+
angle = 45,
|
|
109
|
+
width = 'auto',
|
|
110
|
+
firstCol = false,
|
|
111
|
+
lastCol = false,
|
|
112
|
+
footer = false,
|
|
113
|
+
} = {},
|
|
114
|
+
) {
|
|
115
|
+
if (!table) {
|
|
116
|
+
throw 'An HTML table element must be specified.';
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
// normalize the angle
|
|
120
|
+
while (angle > 90) {
|
|
121
|
+
angle = angle - 180;
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
while (angle < -90) {
|
|
125
|
+
angle = 180 + angle;
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
// if the angle is exactly -90 or 90, we do nothing since that can't be displayed properly
|
|
129
|
+
if (angle == 90 || angle == -90) {
|
|
130
|
+
return;
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
let elems,
|
|
134
|
+
maxWidth = 0,
|
|
135
|
+
startCol = 0,
|
|
136
|
+
endCol = 0;
|
|
137
|
+
|
|
138
|
+
if (firstCol) {
|
|
139
|
+
startCol = 1;
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
if (lastCol) {
|
|
143
|
+
endCol = -1;
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
table.classList.add('awesomizr-table-table');
|
|
147
|
+
|
|
148
|
+
elems = table.querySelectorAll('thead td, thead th');
|
|
149
|
+
|
|
150
|
+
let hasNoTHead = elems.length == 0;
|
|
151
|
+
let needsTFoot = footer;
|
|
152
|
+
|
|
153
|
+
// if we dont have a thead then create one from the first row
|
|
154
|
+
// also create a tfoot when necessary from the last row
|
|
155
|
+
if (
|
|
156
|
+
hasNoTHead ||
|
|
157
|
+
(needsTFoot = footer && table.querySelectorAll('tfoot td').length == 0)
|
|
158
|
+
) {
|
|
159
|
+
let firstRow = table.querySelector('tr');
|
|
160
|
+
|
|
161
|
+
if (!firstRow) {
|
|
162
|
+
return;
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
// Build a new valid table with thead, tbody and optional tfoot
|
|
166
|
+
let thead = document.createElement('thead'),
|
|
167
|
+
tbody = document.createElement('tbody'),
|
|
168
|
+
tfoot = document.createElement('tfoot');
|
|
169
|
+
|
|
170
|
+
let rows;
|
|
171
|
+
|
|
172
|
+
// get the rows of the body
|
|
173
|
+
if (hasNoTHead) {
|
|
174
|
+
rows = firstRow.parentNode.children;
|
|
175
|
+
} else {
|
|
176
|
+
// rows inside tbody
|
|
177
|
+
rows = table.querySelectorAll('tbody > tr');
|
|
178
|
+
if (rows.lenght == 0) {
|
|
179
|
+
// rows might be direct children of table
|
|
180
|
+
let hadId = true;
|
|
181
|
+
if (!table.id) {
|
|
182
|
+
hadID = false;
|
|
183
|
+
table.id = 'awesomizr-table-no-tbody-helper-id';
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
rows = table.parentNode.querySelectorAll('#' + table.id + ' > tr');
|
|
187
|
+
|
|
188
|
+
if (!hadId) {
|
|
189
|
+
table.id = '';
|
|
190
|
+
}
|
|
191
|
+
}
|
|
192
|
+
}
|
|
193
|
+
|
|
194
|
+
let length = rows.length;
|
|
195
|
+
|
|
196
|
+
if (hasNoTHead) {
|
|
197
|
+
// use first row as head
|
|
198
|
+
thead.appendChild(firstRow.cloneNode(true));
|
|
199
|
+
} else {
|
|
200
|
+
// continue to use thead
|
|
201
|
+
thead = table.querySelector('thead').cloneNode(true);
|
|
202
|
+
}
|
|
203
|
+
if (footer && needsTFoot && length > 0) {
|
|
204
|
+
// use the last row as tfoot
|
|
205
|
+
tfoot.appendChild(rows[--length].cloneNode(true));
|
|
206
|
+
}
|
|
207
|
+
|
|
208
|
+
// use the remaining rows for tbody
|
|
209
|
+
for (let i = hasNoTHead ? 1 : 0; i < length; i++) {
|
|
210
|
+
tbody.appendChild(rows[i].cloneNode(true));
|
|
211
|
+
}
|
|
212
|
+
table.innerHTML = '';
|
|
213
|
+
|
|
214
|
+
table.appendChild(thead);
|
|
215
|
+
table.appendChild(tbody);
|
|
216
|
+
table.appendChild(tfoot);
|
|
217
|
+
elems = table.querySelectorAll('thead td, thead th');
|
|
218
|
+
}
|
|
219
|
+
|
|
220
|
+
for (let i = 0; i < elems.length; i++) {
|
|
221
|
+
elems[i].innerHTML = '<div>' + elems[i].innerHTML + '</div>';
|
|
222
|
+
elems[i].firstElementChild.style.overflow = 'visible';
|
|
223
|
+
elems[i].firstElementChild.style.whiteSpace = 'nowrap';
|
|
224
|
+
elems[i].style.verticalAlign = 'bottom';
|
|
225
|
+
elems[i].style.transformOrigin = '50% 100%';
|
|
226
|
+
|
|
227
|
+
if (i >= startCol && i < elems.length + endCol) {
|
|
228
|
+
elems[i].style.textAlign = 'center';
|
|
229
|
+
elems[i].style.width = width;
|
|
230
|
+
|
|
231
|
+
// some styles to extract the width
|
|
232
|
+
elems[i].firstElementChild.style.position = 'absolute';
|
|
233
|
+
elems[i].firstElementChild.style['float'] = 'left';
|
|
234
|
+
elems[i].firstElementChild.style.maxWidth = 'none';
|
|
235
|
+
|
|
236
|
+
let curWidth = elems[i].firstElementChild.clientWidth;
|
|
237
|
+
maxWidth = Math.max(maxWidth, curWidth);
|
|
238
|
+
|
|
239
|
+
// style back
|
|
240
|
+
elems[i].firstElementChild.style.maxWidth = '0pt';
|
|
241
|
+
elems[i].firstElementChild.style.position = 'static';
|
|
242
|
+
elems[i].firstElementChild.style['float'] = 'none';
|
|
243
|
+
elems[i].firstElementChild.style.marginLeft = '50%';
|
|
244
|
+
|
|
245
|
+
// flip the direction of the text if the angle is less than 0
|
|
246
|
+
if (angle < 0 || angle >= 180) {
|
|
247
|
+
elems[i].firstElementChild.style.transform =
|
|
248
|
+
'translateX(' + -curWidth + 'px)';
|
|
249
|
+
}
|
|
250
|
+
|
|
251
|
+
elems[i].style.transform = 'skewX(' + -angle + 'deg)';
|
|
252
|
+
}
|
|
253
|
+
}
|
|
254
|
+
|
|
255
|
+
maxWidth = maxWidth * 1.5;
|
|
256
|
+
table.querySelector('thead tr').style.height =
|
|
257
|
+
maxWidth * Math.abs(Math.cos((angle / 180) * Math.PI)) + 'px';
|
|
258
|
+
elems = table.querySelectorAll('thead td > div, thead th > div');
|
|
259
|
+
|
|
260
|
+
for (let i = startCol; i < elems.length + endCol; i++) {
|
|
261
|
+
let rotation = angle - 90;
|
|
262
|
+
|
|
263
|
+
if (angle < 0 || angle > 180) {
|
|
264
|
+
rotation = angle - 270;
|
|
265
|
+
}
|
|
266
|
+
|
|
267
|
+
elems[i].style.transform =
|
|
268
|
+
'skewX(' + angle + 'deg) rotate(' + rotation + 'deg)';
|
|
269
|
+
}
|
|
270
|
+
|
|
271
|
+
// if we have a special first column and/or last column
|
|
272
|
+
let specialCols = [];
|
|
273
|
+
|
|
274
|
+
if (startCol > 0) specialCols.push(0);
|
|
275
|
+
if (endCol < 0) specialCols.push(elems.length - 1);
|
|
276
|
+
|
|
277
|
+
if (specialCols.length > 0) {
|
|
278
|
+
for (let i = 0; i < specialCols.length; i++) {
|
|
279
|
+
elems[specialCols[i]].parentNode.className =
|
|
280
|
+
specialCols[i] === 0
|
|
281
|
+
? 'awesomizr-table-first-column'
|
|
282
|
+
: 'awesomizr-table-last-column';
|
|
283
|
+
elems[specialCols[i]].style.width = 'auto';
|
|
284
|
+
}
|
|
285
|
+
}
|
|
286
|
+
}
|
|
287
|
+
|
|
288
|
+
/**
|
|
289
|
+
* This function allows to insert a table of contents that is generated from given elements.
|
|
290
|
+
* The table of contents requires certain styles to work properly. These styles are included in the awesomizr.css
|
|
291
|
+
* and should be added either to the document or by using the userStyleSheets configuration property of the PDFreactor API.
|
|
292
|
+
* The table of contents is inserted as an HTML div element with the class "ro-toc". Inside this div can be two headings
|
|
293
|
+
* (document title and a heading for the table of contents with the class "ro-toc-heading") and the div elements with links to the pages and a class depending on the level of the referenced element ("ro-toc-heading1", "ro-toc-heading2", ...)
|
|
294
|
+
* The level of a TOC entry is determined by the position of its selector in the elements array.
|
|
295
|
+
*
|
|
296
|
+
* @param {object} [params] The function's optional parameter is an object with several options.
|
|
297
|
+
* @param {string} [params.insertiontarget="body"] CSS selector string of the element where the table of contents should be inserted.
|
|
298
|
+
* @param { "afterbegin" | "afterend" | "beforebegin" | "beforeend" } [params.insertiontype="afterbegin"] Specifies where exactly the table of contents should be inserted:
|
|
299
|
+
* * "beforebegin": Before the element
|
|
300
|
+
* * "afterbegin": As new first-child
|
|
301
|
+
* * "beforeend": As new last-child
|
|
302
|
+
* * "afterend": After the element
|
|
303
|
+
* @param {string[]} [params.elements=["h1", "h2"]] An array of the CSS selector strings of elements that should be added to the table of contents.
|
|
304
|
+
* The index in the array represents the level, i.e index 0 represents level 1, index 1 represents level 2, etc.
|
|
305
|
+
* Each TOC entry gets a class name based on the level, e.g. by default the "h2" entries have the class "ro-toc-level-2".
|
|
306
|
+
* @param {string} [params.toctitle="Table of Contents"] The title of the table of contents. If an empty string is set, no title is inserted.
|
|
307
|
+
* @param {boolean} [params.disabledocumenttitle=false] Whether the document title should NOT be inserted before the table of contents.
|
|
308
|
+
* @param {function} [params.text] By default, the text for the entries of the TOC is the text content of the element matching the specified selector.
|
|
309
|
+
* Alternatively, you can specify a function, the return value of which will be used as text for the respective entry.
|
|
310
|
+
* The element representing the entry is passed as an argument to the function. Returning "false" will skip the entry entirely and not include it in the TOC.
|
|
311
|
+
*/
|
|
312
|
+
export function createTableOfContents({
|
|
313
|
+
insertiontarget = 'body',
|
|
314
|
+
insertiontype = 'afterbegin',
|
|
315
|
+
elements = ['h1', 'h2'],
|
|
316
|
+
toctitle = 'Table of Contents',
|
|
317
|
+
disabledocumenttitle = false,
|
|
318
|
+
text = null,
|
|
319
|
+
accessible = false,
|
|
320
|
+
} = {}) {
|
|
321
|
+
let toc = '';
|
|
322
|
+
|
|
323
|
+
const tocHeadingClass = 'ro-toc-heading';
|
|
324
|
+
const tocClass = 'ro-toc';
|
|
325
|
+
const tocAccClass = 'ro-toc-acc';
|
|
326
|
+
|
|
327
|
+
// Check whether the elements parameter is a string instead of an array
|
|
328
|
+
if ((typeof elements).toLowerCase() == 'string') {
|
|
329
|
+
elements = [elements];
|
|
330
|
+
}
|
|
331
|
+
|
|
332
|
+
// Get an selector for all heading elements that should be added to the toc
|
|
333
|
+
let selector = elements[0];
|
|
334
|
+
for (let i = 1; i < elements.length; i++) {
|
|
335
|
+
selector += ', ' + elements[i];
|
|
336
|
+
}
|
|
337
|
+
|
|
338
|
+
// Create the TOC HTML
|
|
339
|
+
let elementNodes = document.querySelectorAll(selector);
|
|
340
|
+
let idNumber = 0;
|
|
341
|
+
for (let i = 0; i < elementNodes.length; i++) {
|
|
342
|
+
let ele = elementNodes[i];
|
|
343
|
+
let id = ele.id;
|
|
344
|
+
let textContent = null;
|
|
345
|
+
|
|
346
|
+
if ((typeof text).toLowerCase() === 'function') {
|
|
347
|
+
textContent = text(ele);
|
|
348
|
+
|
|
349
|
+
if (textContent === false) {
|
|
350
|
+
continue;
|
|
351
|
+
} else if (textContent === true) {
|
|
352
|
+
textContent = null;
|
|
353
|
+
} else {
|
|
354
|
+
textContent += '';
|
|
355
|
+
}
|
|
356
|
+
}
|
|
357
|
+
|
|
358
|
+
if (textContent === null) {
|
|
359
|
+
textContent = ele.textContent;
|
|
360
|
+
}
|
|
361
|
+
|
|
362
|
+
if (!id) {
|
|
363
|
+
let nextId = getNextId(idNumber, 'ro-toc-heading');
|
|
364
|
+
|
|
365
|
+
idNumber = nextId.index;
|
|
366
|
+
id = nextId.value;
|
|
367
|
+
|
|
368
|
+
ele.id = id;
|
|
369
|
+
}
|
|
370
|
+
let tocLevel = 0;
|
|
371
|
+
for (let k = 0; k < elements.length; k++) {
|
|
372
|
+
if (matchesSelector(ele, elements[k])) {
|
|
373
|
+
tocLevel = k + 1;
|
|
374
|
+
break;
|
|
375
|
+
}
|
|
376
|
+
}
|
|
377
|
+
|
|
378
|
+
// Add line to TOC HTML
|
|
379
|
+
toc += '<div class="ro-toc-level-' + tocLevel + '">';
|
|
380
|
+
if (accessible) {
|
|
381
|
+
toc += '<div>';
|
|
382
|
+
}
|
|
383
|
+
toc +=
|
|
384
|
+
'<a href="#' +
|
|
385
|
+
id +
|
|
386
|
+
'">' +
|
|
387
|
+
textContent.replace('&', '&').replace('<', '<') +
|
|
388
|
+
'</a></div>';
|
|
389
|
+
if (accessible) {
|
|
390
|
+
toc += '</div>';
|
|
391
|
+
}
|
|
392
|
+
}
|
|
393
|
+
|
|
394
|
+
// Prepare to wrap TOC HTML into container
|
|
395
|
+
let tocContainer =
|
|
396
|
+
'<div class="' + tocClass + (accessible ? ' ' + tocAccClass : '') + '">';
|
|
397
|
+
|
|
398
|
+
if (!disabledocumenttitle) {
|
|
399
|
+
// Add the document title as a heading
|
|
400
|
+
tocContainer += '<h1>' + document.title + '</h1>';
|
|
401
|
+
}
|
|
402
|
+
|
|
403
|
+
// Only insert a heading for the toc if it has not been set to empty string
|
|
404
|
+
if (toctitle.length > 0) {
|
|
405
|
+
tocContainer += '<h2 class="' + tocHeadingClass + '">' + toctitle + '</h2>';
|
|
406
|
+
}
|
|
407
|
+
|
|
408
|
+
if (accessible) {
|
|
409
|
+
tocContainer += '<div>';
|
|
410
|
+
}
|
|
411
|
+
tocContainer += toc + '</div>';
|
|
412
|
+
if (accessible) {
|
|
413
|
+
tocContainer += '</div>';
|
|
414
|
+
}
|
|
415
|
+
|
|
416
|
+
// Insert TOC HTML before the content of target (body by default)
|
|
417
|
+
document
|
|
418
|
+
.querySelector(insertiontarget)
|
|
419
|
+
.insertAdjacentHTML(insertiontype, tocContainer);
|
|
420
|
+
}
|
|
421
|
+
|
|
422
|
+
/**
|
|
423
|
+
* Automatically adds page breaks depending on the amount of space left below an element.
|
|
424
|
+
* A possible use case is to prevent a new section from beginning at the bottom of a page.
|
|
425
|
+
* The function also prevents large whitespaces that occur when in situations where only a couple of sentences from a previous section are followed by a page break as the next section begins.
|
|
426
|
+
*
|
|
427
|
+
* @param {string} [selector="h1, h2"] The CSS selector for the elements that may require a new page break.
|
|
428
|
+
* @param {number} [threshold=67] If an element is below this percentage of the page height, a page break is inserted.
|
|
429
|
+
*/
|
|
430
|
+
export function applyAdaptivePageBreaks(selector = 'h1, h2', threshold = 67) {
|
|
431
|
+
// Check whether the required JS API exists
|
|
432
|
+
if (window.ro === undefined || window.ro.layout === undefined) {
|
|
433
|
+
return;
|
|
434
|
+
}
|
|
435
|
+
|
|
436
|
+
// If the threshold is a string (e.g. "50%") convert it to a 0-100 value.
|
|
437
|
+
if ((typeof threshold).toLowerCase() == 'string') {
|
|
438
|
+
threshold = Math.max(Math.min(parseInt(threshold), 100), 0);
|
|
439
|
+
}
|
|
440
|
+
|
|
441
|
+
// 50% -> 0.5
|
|
442
|
+
threshold = threshold / 100;
|
|
443
|
+
|
|
444
|
+
// Iterate over the selected elements
|
|
445
|
+
let elements = document.querySelectorAll(selector);
|
|
446
|
+
for (let i = 0; i < elements.length; i++) {
|
|
447
|
+
let element = elements[i];
|
|
448
|
+
let boxDescList;
|
|
449
|
+
let compStyle;
|
|
450
|
+
let compDisplayStyle;
|
|
451
|
+
// if necessary move up until we find an element that is not inline, has at least one box and is not the body or root element
|
|
452
|
+
while (
|
|
453
|
+
element &&
|
|
454
|
+
(element == document ||
|
|
455
|
+
element == document.documentElement ||
|
|
456
|
+
element == document.body ||
|
|
457
|
+
!(compStyle = window.getComputedStyle(element)) ||
|
|
458
|
+
!(compDisplayStyle = compStyle.display) ||
|
|
459
|
+
compDisplayStyle == 'inline' ||
|
|
460
|
+
compDisplayStyle == 'none' ||
|
|
461
|
+
compDisplayStyle == 'table-cell' ||
|
|
462
|
+
!(boxDescList = ro.layout.getBoxDescriptions(element)) ||
|
|
463
|
+
boxDescList.length == 0)
|
|
464
|
+
) {
|
|
465
|
+
element = element.parentNode;
|
|
466
|
+
}
|
|
467
|
+
if (element) {
|
|
468
|
+
let boxDesc = boxDescList[0];
|
|
469
|
+
let boxRect = boxDesc.borderRectInPage;
|
|
470
|
+
let pageMarginRect = boxDesc.pageDescription.marginRect;
|
|
471
|
+
// Check whether the box starts below the threshold value
|
|
472
|
+
if (boxRect.top > pageMarginRect.height * threshold) {
|
|
473
|
+
// Add a page break
|
|
474
|
+
element.style.breakBefore = 'page';
|
|
475
|
+
}
|
|
476
|
+
}
|
|
477
|
+
}
|
|
478
|
+
}
|
|
479
|
+
|
|
480
|
+
/**
|
|
481
|
+
* Automatically fills up the document with empty pages until
|
|
482
|
+
* the total page count is a multiple of the specified value.
|
|
483
|
+
* The filler Pages have the name "roFillerPage" and the elements have the class "roFillerPage".
|
|
484
|
+
*
|
|
485
|
+
* @param {object} [params] An object containing various configuration properties.
|
|
486
|
+
* @param {number} [params.multiple=2] A positive integer. Pages will be filled up until the page count is a multiple of this property.
|
|
487
|
+
* @param {string} [params.target="body"] A selector. The filler page objects will be inserted as new children of the element matching this selector.
|
|
488
|
+
* @param {function} [params.template] A function that must return an HTMLElement which will be used as the filler pages. Returning null or undefined skips the page.
|
|
489
|
+
* If no function is specified, a custom element is inserted. The function receives the following three arguments: The current index of the inserted filler page (starting at 0),
|
|
490
|
+
* the total number of filler pages to be inserted, the total (original) page count of the document.
|
|
491
|
+
*/
|
|
492
|
+
export function autoFillPages({
|
|
493
|
+
multiple = 2,
|
|
494
|
+
target = 'body',
|
|
495
|
+
template = null,
|
|
496
|
+
} = {}) {
|
|
497
|
+
// Check whether the required JS API exists
|
|
498
|
+
if (window.ro === undefined || window.ro.layout === undefined) {
|
|
499
|
+
return;
|
|
500
|
+
}
|
|
501
|
+
|
|
502
|
+
const roFillerPage = 'roFillerPage';
|
|
503
|
+
|
|
504
|
+
const currentPageCount = ro.layout.numberOfPages;
|
|
505
|
+
let pagesToInsert = 0;
|
|
506
|
+
|
|
507
|
+
// How many pages do we need?
|
|
508
|
+
const pageMod = parseInt(multiple);
|
|
509
|
+
|
|
510
|
+
if (!Number.isNaN(pageMod) && pageMod > 0) {
|
|
511
|
+
const currentPageMod = currentPageCount % pageMod;
|
|
512
|
+
|
|
513
|
+
if (currentPageMod) {
|
|
514
|
+
pagesToInsert = pageMod - (currentPageCount % pageMod);
|
|
515
|
+
}
|
|
516
|
+
} else {
|
|
517
|
+
throw "Param 'multiple' must be positive integer.";
|
|
518
|
+
}
|
|
519
|
+
|
|
520
|
+
console.debug('[Awesomizr] Inserting ' + pagesToInsert + ' pages');
|
|
521
|
+
|
|
522
|
+
// Begin inserting pages
|
|
523
|
+
if (pagesToInsert > 0) {
|
|
524
|
+
const targetElement = document.querySelector(target);
|
|
525
|
+
|
|
526
|
+
if (!targetElement) {
|
|
527
|
+
throw "Insertion target not found from param 'target'.";
|
|
528
|
+
}
|
|
529
|
+
|
|
530
|
+
for (let i = 0; i < pagesToInsert; i++) {
|
|
531
|
+
let fillerPage = null;
|
|
532
|
+
|
|
533
|
+
if (template) {
|
|
534
|
+
if (template instanceof Function) {
|
|
535
|
+
fillerPage = template(i, pagesToInsert, currentPageCount);
|
|
536
|
+
|
|
537
|
+
if (fillerPage === null || fillerPage === undefined) {
|
|
538
|
+
continue;
|
|
539
|
+
}
|
|
540
|
+
|
|
541
|
+
if (!(fillerPage instanceof HTMLElement)) {
|
|
542
|
+
throw "Param function 'template' must return an HTMLElement.";
|
|
543
|
+
}
|
|
544
|
+
} else {
|
|
545
|
+
throw "Param 'template' must be a function.";
|
|
546
|
+
}
|
|
547
|
+
} else {
|
|
548
|
+
fillerPage = document.createElement(roFillerPage);
|
|
549
|
+
}
|
|
550
|
+
|
|
551
|
+
// Always add class and some basic styles
|
|
552
|
+
fillerPage.className = roFillerPage;
|
|
553
|
+
fillerPage.style.page = roFillerPage;
|
|
554
|
+
fillerPage.style.display = 'block';
|
|
555
|
+
fillerPage.style.breakBefore = 'page';
|
|
556
|
+
|
|
557
|
+
targetElement.appendChild(fillerPage);
|
|
558
|
+
}
|
|
559
|
+
}
|
|
560
|
+
}
|
|
561
|
+
|
|
562
|
+
/**
|
|
563
|
+
* Converts a wide data table into a compact, vertical layout that displays each cell below the previous one.
|
|
564
|
+
* Column headers are automatically repeated for each data set and are displayed on the left side next to the data.
|
|
565
|
+
* Note that this only works for uniform data tables without any colspan, rowspan, or special row groups.
|
|
566
|
+
*
|
|
567
|
+
* The compactified table element will receive the class "awesomizr-compact-table", and the repeated column headers
|
|
568
|
+
* will recieve the class "awesomizr-compact-table-header-cell".
|
|
569
|
+
*
|
|
570
|
+
* @param {HTMLTableElement} table The HTML table element to convert.
|
|
571
|
+
* @param {object} [params] An object containing various configuration properties.
|
|
572
|
+
* @param {string[]} [params.widths=["fit-content(50%)", "auto"]] An array with two entries, each specifying the width of one of the two display columns. The values must be a CSS length.
|
|
573
|
+
* @param {boolean} [params.autoDetectOverflow=false] Whether to automatically detect if a table's width overflows the page. If not, the table is not converted.
|
|
574
|
+
*/
|
|
575
|
+
export function compactifyTable(
|
|
576
|
+
table,
|
|
577
|
+
{ widths = ['fit-content(50%)', 'auto'], autoDetectOverflow = false } = {},
|
|
578
|
+
) {
|
|
579
|
+
if (!Array.isArray(widths) || widths.length != 2) {
|
|
580
|
+
throw "Param 'widths' must be an array with length 2.";
|
|
581
|
+
}
|
|
582
|
+
|
|
583
|
+
const thead = table.querySelector('thead');
|
|
584
|
+
|
|
585
|
+
if (thead == null) {
|
|
586
|
+
throw 'Table must have a thead element.';
|
|
587
|
+
}
|
|
588
|
+
|
|
589
|
+
if (autoDetectOverflow && window.ro && window.ro.layout) {
|
|
590
|
+
// Get width of table
|
|
591
|
+
const boxDescriptions = ro.layout.getBoxDescriptions(table);
|
|
592
|
+
|
|
593
|
+
for (const boxDescription of boxDescriptions) {
|
|
594
|
+
const pageDescription = boxDescription.pageDescription;
|
|
595
|
+
const pageContentWidth = pageDescription.getContentRect().width;
|
|
596
|
+
const tableWidth = boxDescription.getMarginRect().width;
|
|
597
|
+
|
|
598
|
+
if (tableWidth <= pageContentWidth) {
|
|
599
|
+
return;
|
|
600
|
+
}
|
|
601
|
+
}
|
|
602
|
+
}
|
|
603
|
+
|
|
604
|
+
const columnHeaders = thead.querySelectorAll(
|
|
605
|
+
'thead > tr:first-child > :is(td, th)',
|
|
606
|
+
);
|
|
607
|
+
const rows = table.querySelectorAll('tbody tr');
|
|
608
|
+
|
|
609
|
+
const classTable = 'awesomizr-compact-table';
|
|
610
|
+
const classHeaderCell = 'awesomizr-compact-table-header-cell';
|
|
611
|
+
|
|
612
|
+
table.classList.add(classTable);
|
|
613
|
+
|
|
614
|
+
for (const cell of [
|
|
615
|
+
...columnHeaders,
|
|
616
|
+
...thead.querySelectorAll('tfoot > tr:first-child > :is(td, th)'),
|
|
617
|
+
]) {
|
|
618
|
+
cell.setAttribute('data-awesomizr-content', cell.textContent);
|
|
619
|
+
}
|
|
620
|
+
|
|
621
|
+
for (const row of rows) {
|
|
622
|
+
const cells = row.querySelectorAll(':scope > :is(td, th)');
|
|
623
|
+
|
|
624
|
+
row.style.display = 'grid';
|
|
625
|
+
row.style.gridTemplateColumns = widths.join(' ');
|
|
626
|
+
|
|
627
|
+
let index = 0;
|
|
628
|
+
for (const cell of cells) {
|
|
629
|
+
const columnHeader = columnHeaders[index];
|
|
630
|
+
const headerCell = document.createElement(columnHeader.nodeName);
|
|
631
|
+
|
|
632
|
+
headerCell.classList.add(classHeaderCell);
|
|
633
|
+
headerCell.innerHTML = columnHeader.innerHTML;
|
|
634
|
+
|
|
635
|
+
row.insertBefore(headerCell, cell);
|
|
636
|
+
|
|
637
|
+
index++;
|
|
638
|
+
}
|
|
639
|
+
}
|
|
640
|
+
}
|
|
641
|
+
|
|
642
|
+
/**
|
|
643
|
+
* This is a helper function to dynamically load MathJax with a configuration. If the configuration
|
|
644
|
+
* parameter is omitted, a default configuration is used which is optimized for PDFreactor.
|
|
645
|
+
*
|
|
646
|
+
* @param {string} url The url to the MaxJax library. If the URL is relative, it is resolved against the document URL.
|
|
647
|
+
* @param {object|string} [configuration] A MathJax configuration. Can be an object or a string. As string,
|
|
648
|
+
* it represents one of the combined configurations offered by MathJax.
|
|
649
|
+
*/
|
|
650
|
+
export function loadMathJax(url, configuration) {
|
|
651
|
+
if (!configuration) {
|
|
652
|
+
/* This configuration is optimized for PDFreactor and omits certain
|
|
653
|
+
* extensions and features typically used in browsers that rely
|
|
654
|
+
* on animations or user interactivity.
|
|
655
|
+
*/
|
|
656
|
+
configuration = {
|
|
657
|
+
showMathMenu: false,
|
|
658
|
+
jax: ['input/MathML', 'output/SVG'],
|
|
659
|
+
extensions: ['mml2jax.js'],
|
|
660
|
+
MathML: { extensions: ['content-mathml.js'] },
|
|
661
|
+
SVG: { blacker: 0 },
|
|
662
|
+
};
|
|
663
|
+
}
|
|
664
|
+
|
|
665
|
+
const script = document.createElement('script');
|
|
666
|
+
const scriptUrl = new URL(url, window.location.href);
|
|
667
|
+
|
|
668
|
+
if (typeof configuration === 'object') {
|
|
669
|
+
// For configuration objects, use a script
|
|
670
|
+
const configScript = document.createElement('script');
|
|
671
|
+
configScript.type = 'text/x-mathjax-config';
|
|
672
|
+
configScript.textContent = `MathJax.Hub.Config(${JSON.stringify(configuration)});`;
|
|
673
|
+
|
|
674
|
+
document.head.appendChild(configScript);
|
|
675
|
+
} else {
|
|
676
|
+
scriptUrl.searchParams.set('config', configuration);
|
|
677
|
+
}
|
|
678
|
+
|
|
679
|
+
script.src = scriptUrl.href;
|
|
680
|
+
|
|
681
|
+
document.head.appendChild(script);
|
|
682
|
+
}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
@use '../scss/system/variables' as systemVariables;
|
|
2
|
+
@use '../scss/meta/variables' as metaVariables;
|
|
3
|
+
@use '../scss/grid/variables' as gridVariables;
|
|
4
|
+
@use '../scss/colors/variables' as colorsVariables;
|
|
5
|
+
@use '../scss/typography/variables' as typographyVariables;
|
|
6
|
+
@use '../scss/spacer/variables' as spacerVariables;
|
|
7
|
+
@use '../scss/helpers/variables' as helpersVariables;
|