honkit 4.0.8 → 5.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/lib/BuildGenerator.d.ts +13 -0
- package/lib/BuildGenerator.d.ts.map +1 -0
- package/lib/__tests__/__fixtures__/honkit/book.d.ts +7 -0
- package/lib/__tests__/__fixtures__/honkit/book.d.ts.map +1 -0
- package/lib/__tests__/e2e.test.d.ts +2 -0
- package/lib/__tests__/e2e.test.d.ts.map +1 -0
- package/lib/__tests__/init.d.ts +2 -0
- package/lib/__tests__/init.d.ts.map +1 -0
- package/lib/__tests__/satisfies.d.ts +2 -0
- package/lib/__tests__/satisfies.d.ts.map +1 -0
- package/lib/__tests__/snapshot-asciidoc.d.ts +2 -0
- package/lib/__tests__/snapshot-asciidoc.d.ts.map +1 -0
- package/lib/__tests__/snapshot-asciidoc.js +48 -0
- package/lib/__tests__/snapshot-honkit.d.ts +2 -0
- package/lib/__tests__/snapshot-honkit.d.ts.map +1 -0
- package/lib/api/decodeConfig.d.ts +10 -0
- package/lib/api/decodeConfig.d.ts.map +1 -0
- package/lib/api/decodeGlobal.d.ts +11 -0
- package/lib/api/decodeGlobal.d.ts.map +1 -0
- package/lib/api/decodePage.d.ts +12 -0
- package/lib/api/decodePage.d.ts.map +1 -0
- package/lib/api/deprecate.d.ts +52 -0
- package/lib/api/deprecate.d.ts.map +1 -0
- package/lib/api/encodeConfig.d.ts +12 -0
- package/lib/api/encodeConfig.d.ts.map +1 -0
- package/lib/api/encodeGlobal.d.ts +165 -0
- package/lib/api/encodeGlobal.d.ts.map +1 -0
- package/lib/api/encodeGlobal.js +11 -9
- package/lib/api/encodeNavigation.d.ts +19 -0
- package/lib/api/encodeNavigation.d.ts.map +1 -0
- package/lib/api/encodePage.d.ts +16 -0
- package/lib/api/encodePage.d.ts.map +1 -0
- package/lib/api/encodeProgress.d.ts +25 -0
- package/lib/api/encodeProgress.d.ts.map +1 -0
- package/lib/api/encodeSummary.d.ts +49 -0
- package/lib/api/encodeSummary.d.ts.map +1 -0
- package/lib/api/index.d.ts +12 -0
- package/lib/api/index.d.ts.map +1 -0
- package/lib/bin.d.ts +2 -0
- package/lib/bin.d.ts.map +1 -0
- package/lib/browser.d.ts +60 -0
- package/lib/browser.d.ts.map +1 -0
- package/lib/cli/build.d.ts +17 -0
- package/lib/cli/build.d.ts.map +1 -0
- package/lib/cli/buildEbook.d.ts +12 -0
- package/lib/cli/buildEbook.d.ts.map +1 -0
- package/lib/cli/getBook.d.ts +12 -0
- package/lib/cli/getBook.d.ts.map +1 -0
- package/lib/cli/getOutputFolder.d.ts +9 -0
- package/lib/cli/getOutputFolder.d.ts.map +1 -0
- package/lib/cli/index.d.ts +25 -0
- package/lib/cli/index.d.ts.map +1 -0
- package/lib/cli/init.d.ts +13 -0
- package/lib/cli/init.d.ts.map +1 -0
- package/lib/cli/options.d.ts +26 -0
- package/lib/cli/options.d.ts.map +1 -0
- package/lib/cli/parse.d.ts +13 -0
- package/lib/cli/parse.d.ts.map +1 -0
- package/lib/cli/serve.d.ts +25 -0
- package/lib/cli/serve.d.ts.map +1 -0
- package/lib/cli/server.d.ts +29 -0
- package/lib/cli/server.d.ts.map +1 -0
- package/lib/cli/watch.d.ts +10 -0
- package/lib/cli/watch.d.ts.map +1 -0
- package/lib/constants/__tests__/configSchema.d.ts +2 -0
- package/lib/constants/__tests__/configSchema.d.ts.map +1 -0
- package/lib/constants/configDefault.d.ts +3 -0
- package/lib/constants/configDefault.d.ts.map +1 -0
- package/lib/constants/configFiles.d.ts +3 -0
- package/lib/constants/configFiles.d.ts.map +1 -0
- package/lib/constants/configSchema.d.ts +221 -0
- package/lib/constants/configSchema.d.ts.map +1 -0
- package/lib/constants/defaultBlocks.d.ts +5 -0
- package/lib/constants/defaultBlocks.d.ts.map +1 -0
- package/lib/constants/defaultBlocks.js +8 -7
- package/lib/constants/defaultFilters.d.ts +4 -0
- package/lib/constants/defaultFilters.d.ts.map +1 -0
- package/lib/constants/defaultPlugins.d.ts +5 -0
- package/lib/constants/defaultPlugins.d.ts.map +1 -0
- package/lib/constants/extsAsciidoc.d.ts +3 -0
- package/lib/constants/extsAsciidoc.d.ts.map +1 -0
- package/lib/constants/extsMarkdown.d.ts +3 -0
- package/lib/constants/extsMarkdown.d.ts.map +1 -0
- package/lib/constants/ignoreFiles.d.ts +3 -0
- package/lib/constants/ignoreFiles.d.ts.map +1 -0
- package/lib/constants/pluginAssetsFolder.d.ts +3 -0
- package/lib/constants/pluginAssetsFolder.d.ts.map +1 -0
- package/lib/constants/pluginHooks.d.ts +3 -0
- package/lib/constants/pluginHooks.d.ts.map +1 -0
- package/lib/constants/pluginPrefix.d.ts +3 -0
- package/lib/constants/pluginPrefix.d.ts.map +1 -0
- package/lib/constants/pluginResources.d.ts +4 -0
- package/lib/constants/pluginResources.d.ts.map +1 -0
- package/lib/constants/templatesFolder.d.ts +3 -0
- package/lib/constants/templatesFolder.d.ts.map +1 -0
- package/lib/constants/themePrefix.d.ts +3 -0
- package/lib/constants/themePrefix.d.ts.map +1 -0
- package/lib/fs/__tests__/mock.d.ts +2 -0
- package/lib/fs/__tests__/mock.d.ts.map +1 -0
- package/lib/fs/mock.d.ts +9 -0
- package/lib/fs/mock.d.ts.map +1 -0
- package/lib/fs/node.d.ts +3 -0
- package/lib/fs/node.d.ts.map +1 -0
- package/lib/honkit.d.ts +15 -0
- package/lib/honkit.d.ts.map +1 -0
- package/lib/index.d.ts +3 -0
- package/lib/index.d.ts.map +1 -0
- package/lib/init.d.ts +11 -0
- package/lib/init.d.ts.map +1 -0
- package/lib/json/encodeBook.d.ts +51 -0
- package/lib/json/encodeBook.d.ts.map +1 -0
- package/lib/json/encodeBookWithPage.d.ts +52 -0
- package/lib/json/encodeBookWithPage.d.ts.map +1 -0
- package/lib/json/encodeFile.d.ts +13 -0
- package/lib/json/encodeFile.d.ts.map +1 -0
- package/lib/json/encodeGlossary.d.ts +16 -0
- package/lib/json/encodeGlossary.d.ts.map +1 -0
- package/lib/json/encodeGlossaryEntry.d.ts +13 -0
- package/lib/json/encodeGlossaryEntry.d.ts.map +1 -0
- package/lib/json/encodeLanguages.d.ts +16 -0
- package/lib/json/encodeLanguages.d.ts.map +1 -0
- package/lib/json/encodeOutput.d.ts +51 -0
- package/lib/json/encodeOutput.d.ts.map +1 -0
- package/lib/json/encodeOutputWithPage.d.ts +52 -0
- package/lib/json/encodeOutputWithPage.d.ts.map +1 -0
- package/lib/json/encodePage.d.ts +19 -0
- package/lib/json/encodePage.d.ts.map +1 -0
- package/lib/json/encodeReadme.d.ts +15 -0
- package/lib/json/encodeReadme.d.ts.map +1 -0
- package/lib/json/encodeSummary.d.ts +16 -0
- package/lib/json/encodeSummary.d.ts.map +1 -0
- package/lib/json/encodeSummaryArticle.d.ts +19 -0
- package/lib/json/encodeSummaryArticle.d.ts.map +1 -0
- package/lib/json/encodeSummaryArticleWithCache.d.ts +20 -0
- package/lib/json/encodeSummaryArticleWithCache.d.ts.map +1 -0
- package/lib/json/encodeSummaryPart.d.ts +12 -0
- package/lib/json/encodeSummaryPart.d.ts.map +1 -0
- package/lib/json/index.d.ts +24 -0
- package/lib/json/index.d.ts.map +1 -0
- package/lib/models/__tests__/config.d.ts +2 -0
- package/lib/models/__tests__/config.d.ts.map +1 -0
- package/lib/models/__tests__/glossary.d.ts +2 -0
- package/lib/models/__tests__/glossary.d.ts.map +1 -0
- package/lib/models/__tests__/glossaryEntry.d.ts +2 -0
- package/lib/models/__tests__/glossaryEntry.d.ts.map +1 -0
- package/lib/models/__tests__/page.d.ts +2 -0
- package/lib/models/__tests__/page.d.ts.map +1 -0
- package/lib/models/__tests__/plugin.d.ts +2 -0
- package/lib/models/__tests__/plugin.d.ts.map +1 -0
- package/lib/models/__tests__/pluginDependency.d.ts +2 -0
- package/lib/models/__tests__/pluginDependency.d.ts.map +1 -0
- package/lib/models/__tests__/summary.d.ts +2 -0
- package/lib/models/__tests__/summary.d.ts.map +1 -0
- package/lib/models/__tests__/summaryArticle.d.ts +2 -0
- package/lib/models/__tests__/summaryArticle.d.ts.map +1 -0
- package/lib/models/__tests__/summaryPart.d.ts +2 -0
- package/lib/models/__tests__/summaryPart.d.ts.map +1 -0
- package/lib/models/__tests__/templateBlock.d.ts +2 -0
- package/lib/models/__tests__/templateBlock.d.ts.map +1 -0
- package/lib/models/__tests__/templateEngine.d.ts +2 -0
- package/lib/models/__tests__/templateEngine.d.ts.map +1 -0
- package/lib/models/book.d.ts +158 -0
- package/lib/models/book.d.ts.map +1 -0
- package/lib/models/config.d.ts +82 -0
- package/lib/models/config.d.ts.map +1 -0
- package/lib/models/file.d.ts +54 -0
- package/lib/models/file.d.ts.map +1 -0
- package/lib/models/file.js +11 -4
- package/lib/models/fs.d.ts +116 -0
- package/lib/models/fs.d.ts.map +1 -0
- package/lib/models/glossary.d.ts +42 -0
- package/lib/models/glossary.d.ts.map +1 -0
- package/lib/models/glossary.js +4 -4
- package/lib/models/glossaryEntry.d.ts +16 -0
- package/lib/models/glossaryEntry.d.ts.map +1 -0
- package/lib/models/hash.d.ts +4 -0
- package/lib/models/hash.d.ts.map +1 -0
- package/lib/models/ignore.d.ts +20 -0
- package/lib/models/ignore.d.ts.map +1 -0
- package/lib/models/language.d.ts +9 -0
- package/lib/models/language.d.ts.map +1 -0
- package/lib/models/languages.d.ts +35 -0
- package/lib/models/languages.d.ts.map +1 -0
- package/lib/models/output.d.ts +53 -0
- package/lib/models/output.d.ts.map +1 -0
- package/lib/models/page.d.ts +44 -0
- package/lib/models/page.d.ts.map +1 -0
- package/lib/models/parser.d.ts +44 -0
- package/lib/models/parser.d.ts.map +1 -0
- package/lib/models/parser.js +14 -14
- package/lib/models/plugin.d.ts +69 -0
- package/lib/models/plugin.d.ts.map +1 -0
- package/lib/models/pluginDependency.d.ts +47 -0
- package/lib/models/pluginDependency.d.ts.map +1 -0
- package/lib/models/readme.d.ts +21 -0
- package/lib/models/readme.d.ts.map +1 -0
- package/lib/models/summary.d.ts +83 -0
- package/lib/models/summary.d.ts.map +1 -0
- package/lib/models/summaryArticle.d.ts +93 -0
- package/lib/models/summaryArticle.d.ts.map +1 -0
- package/lib/models/summaryPart.d.ts +23 -0
- package/lib/models/summaryPart.d.ts.map +1 -0
- package/lib/models/templateBlock.d.ts +54 -0
- package/lib/models/templateBlock.d.ts.map +1 -0
- package/lib/models/templateEngine.d.ts +35 -0
- package/lib/models/templateEngine.d.ts.map +1 -0
- package/lib/models/templateOutput.d.ts +18 -0
- package/lib/models/templateOutput.d.ts.map +1 -0
- package/lib/models/templateShortcut.d.ts +28 -0
- package/lib/models/templateShortcut.d.ts.map +1 -0
- package/lib/models/templateShortcut.js +3 -3
- package/lib/modifiers/config/__tests__/addPlugin.d.ts +2 -0
- package/lib/modifiers/config/__tests__/addPlugin.d.ts.map +1 -0
- package/lib/modifiers/config/__tests__/removePlugin.d.ts +2 -0
- package/lib/modifiers/config/__tests__/removePlugin.d.ts.map +1 -0
- package/lib/modifiers/config/__tests__/togglePlugin.d.ts +2 -0
- package/lib/modifiers/config/__tests__/togglePlugin.d.ts.map +1 -0
- package/lib/modifiers/config/addPlugin.d.ts +10 -0
- package/lib/modifiers/config/addPlugin.d.ts.map +1 -0
- package/lib/modifiers/config/editPlugin.d.ts +10 -0
- package/lib/modifiers/config/editPlugin.d.ts.map +1 -0
- package/lib/modifiers/config/getPluginConfig.d.ts +9 -0
- package/lib/modifiers/config/getPluginConfig.d.ts.map +1 -0
- package/lib/modifiers/config/hasPlugin.d.ts +10 -0
- package/lib/modifiers/config/hasPlugin.d.ts.map +1 -0
- package/lib/modifiers/config/index.d.ts +18 -0
- package/lib/modifiers/config/index.d.ts.map +1 -0
- package/lib/modifiers/config/isDefaultPlugin.d.ts +9 -0
- package/lib/modifiers/config/isDefaultPlugin.d.ts.map +1 -0
- package/lib/modifiers/config/removePlugin.d.ts +9 -0
- package/lib/modifiers/config/removePlugin.d.ts.map +1 -0
- package/lib/modifiers/config/togglePlugin.d.ts +10 -0
- package/lib/modifiers/config/togglePlugin.d.ts.map +1 -0
- package/lib/modifiers/index.d.ts +25 -0
- package/lib/modifiers/index.d.ts.map +1 -0
- package/lib/modifiers/summary/__tests__/editPartTitle.d.ts +2 -0
- package/lib/modifiers/summary/__tests__/editPartTitle.d.ts.map +1 -0
- package/lib/modifiers/summary/__tests__/insertArticle.d.ts +2 -0
- package/lib/modifiers/summary/__tests__/insertArticle.d.ts.map +1 -0
- package/lib/modifiers/summary/__tests__/insertPart.d.ts +2 -0
- package/lib/modifiers/summary/__tests__/insertPart.d.ts.map +1 -0
- package/lib/modifiers/summary/__tests__/mergeAtLevel.d.ts +2 -0
- package/lib/modifiers/summary/__tests__/mergeAtLevel.d.ts.map +1 -0
- package/lib/modifiers/summary/__tests__/moveArticle.d.ts +2 -0
- package/lib/modifiers/summary/__tests__/moveArticle.d.ts.map +1 -0
- package/lib/modifiers/summary/__tests__/moveArticleAfter.d.ts +2 -0
- package/lib/modifiers/summary/__tests__/moveArticleAfter.d.ts.map +1 -0
- package/lib/modifiers/summary/__tests__/removeArticle.d.ts +2 -0
- package/lib/modifiers/summary/__tests__/removeArticle.d.ts.map +1 -0
- package/lib/modifiers/summary/editArticleRef.d.ts +11 -0
- package/lib/modifiers/summary/editArticleRef.d.ts.map +1 -0
- package/lib/modifiers/summary/editArticleTitle.d.ts +11 -0
- package/lib/modifiers/summary/editArticleTitle.d.ts.map +1 -0
- package/lib/modifiers/summary/editPartTitle.d.ts +11 -0
- package/lib/modifiers/summary/editPartTitle.d.ts.map +1 -0
- package/lib/modifiers/summary/index.d.ts +24 -0
- package/lib/modifiers/summary/index.d.ts.map +1 -0
- package/lib/modifiers/summary/indexArticleLevels.d.ts +10 -0
- package/lib/modifiers/summary/indexArticleLevels.d.ts.map +1 -0
- package/lib/modifiers/summary/indexLevels.d.ts +9 -0
- package/lib/modifiers/summary/indexLevels.d.ts.map +1 -0
- package/lib/modifiers/summary/indexPartLevels.d.ts +10 -0
- package/lib/modifiers/summary/indexPartLevels.d.ts.map +1 -0
- package/lib/modifiers/summary/insertArticle.d.ts +12 -0
- package/lib/modifiers/summary/insertArticle.d.ts.map +1 -0
- package/lib/modifiers/summary/insertPart.d.ts +13 -0
- package/lib/modifiers/summary/insertPart.d.ts.map +1 -0
- package/lib/modifiers/summary/mergeAtLevel.d.ts +11 -0
- package/lib/modifiers/summary/mergeAtLevel.d.ts.map +1 -0
- package/lib/modifiers/summary/moveArticle.d.ts +12 -0
- package/lib/modifiers/summary/moveArticle.d.ts.map +1 -0
- package/lib/modifiers/summary/moveArticleAfter.d.ts +13 -0
- package/lib/modifiers/summary/moveArticleAfter.d.ts.map +1 -0
- package/lib/modifiers/summary/removeArticle.d.ts +10 -0
- package/lib/modifiers/summary/removeArticle.d.ts.map +1 -0
- package/lib/modifiers/summary/removePart.d.ts +10 -0
- package/lib/modifiers/summary/removePart.d.ts.map +1 -0
- package/lib/modifiers/summary/unshiftArticle.d.ts +10 -0
- package/lib/modifiers/summary/unshiftArticle.d.ts.map +1 -0
- package/lib/output/Generator.d.ts +14 -0
- package/lib/output/Generator.d.ts.map +1 -0
- package/lib/output/__tests__/ebook.d.ts +2 -0
- package/lib/output/__tests__/ebook.d.ts.map +1 -0
- package/lib/output/__tests__/json.d.ts +2 -0
- package/lib/output/__tests__/json.d.ts.map +1 -0
- package/lib/output/__tests__/plugin-hooks.d.ts +2 -0
- package/lib/output/__tests__/plugin-hooks.d.ts.map +1 -0
- package/lib/output/__tests__/website.d.ts +2 -0
- package/lib/output/__tests__/website.d.ts.map +1 -0
- package/lib/output/callHook.d.ts +12 -0
- package/lib/output/callHook.d.ts.map +1 -0
- package/lib/output/callPageHook.d.ts +11 -0
- package/lib/output/callPageHook.d.ts.map +1 -0
- package/lib/output/createTemplateEngine.d.ts +11 -0
- package/lib/output/createTemplateEngine.d.ts.map +1 -0
- package/lib/output/ebook/getConvertOptions.d.ts +9 -0
- package/lib/output/ebook/getConvertOptions.d.ts.map +1 -0
- package/lib/output/ebook/getCoverPath.d.ts +9 -0
- package/lib/output/ebook/getCoverPath.d.ts.map +1 -0
- package/lib/output/ebook/getPDFTemplate.d.ts +10 -0
- package/lib/output/ebook/getPDFTemplate.d.ts.map +1 -0
- package/lib/output/ebook/index.d.ts +3 -0
- package/lib/output/ebook/index.d.ts.map +1 -0
- package/lib/output/ebook/onFinish.d.ts +9 -0
- package/lib/output/ebook/onFinish.d.ts.map +1 -0
- package/lib/output/ebook/onPage.d.ts +9 -0
- package/lib/output/ebook/onPage.d.ts.map +1 -0
- package/lib/output/ebook/options.d.ts +4 -0
- package/lib/output/ebook/options.d.ts.map +1 -0
- package/lib/output/generateAssets.d.ts +10 -0
- package/lib/output/generateAssets.d.ts.map +1 -0
- package/lib/output/generateBook.d.ts +32 -0
- package/lib/output/generateBook.d.ts.map +1 -0
- package/lib/output/generatePage.d.ts +10 -0
- package/lib/output/generatePage.d.ts.map +1 -0
- package/lib/output/generatePage.js +12 -5
- package/lib/output/generatePages.d.ts +10 -0
- package/lib/output/generatePages.d.ts.map +1 -0
- package/lib/output/getModifiers.d.ts +9 -0
- package/lib/output/getModifiers.d.ts.map +1 -0
- package/lib/output/helper/fileToOutput.d.ts +10 -0
- package/lib/output/helper/fileToOutput.d.ts.map +1 -0
- package/lib/output/helper/fileToURL.d.ts +15 -0
- package/lib/output/helper/fileToURL.d.ts.map +1 -0
- package/lib/output/helper/index.d.ts +3 -0
- package/lib/output/helper/index.d.ts.map +1 -0
- package/lib/output/helper/resolveFileToURL.d.ts +10 -0
- package/lib/output/helper/resolveFileToURL.d.ts.map +1 -0
- package/lib/output/helper/writeFile.d.ts +11 -0
- package/lib/output/helper/writeFile.d.ts.map +1 -0
- package/lib/output/index.d.ts +13 -0
- package/lib/output/index.d.ts.map +1 -0
- package/lib/output/json/index.d.ts +10 -0
- package/lib/output/json/index.d.ts.map +1 -0
- package/lib/output/json/onFinish.d.ts +8 -0
- package/lib/output/json/onFinish.d.ts.map +1 -0
- package/lib/output/json/onPage.d.ts +9 -0
- package/lib/output/json/onPage.d.ts.map +1 -0
- package/lib/output/json/options.d.ts +4 -0
- package/lib/output/json/options.d.ts.map +1 -0
- package/lib/output/modifiers/__tests__/addHeadingId.d.ts +2 -0
- package/lib/output/modifiers/__tests__/addHeadingId.d.ts.map +1 -0
- package/lib/output/modifiers/__tests__/annotateText.d.ts +2 -0
- package/lib/output/modifiers/__tests__/annotateText.d.ts.map +1 -0
- package/lib/output/modifiers/__tests__/fetchRemoteImages.d.ts +2 -0
- package/lib/output/modifiers/__tests__/fetchRemoteImages.d.ts.map +1 -0
- package/lib/output/modifiers/__tests__/fetchRemoteImages.js +4 -2
- package/lib/output/modifiers/__tests__/highlightCode.d.ts +2 -0
- package/lib/output/modifiers/__tests__/highlightCode.d.ts.map +1 -0
- package/lib/output/modifiers/__tests__/inlinePng.d.ts +2 -0
- package/lib/output/modifiers/__tests__/inlinePng.d.ts.map +1 -0
- package/lib/output/modifiers/__tests__/inlineSvg.d.ts +2 -0
- package/lib/output/modifiers/__tests__/inlineSvg.d.ts.map +1 -0
- package/lib/output/modifiers/__tests__/resolveImages.d.ts +2 -0
- package/lib/output/modifiers/__tests__/resolveImages.d.ts.map +1 -0
- package/lib/output/modifiers/__tests__/resolveLinks.d.ts +2 -0
- package/lib/output/modifiers/__tests__/resolveLinks.d.ts.map +1 -0
- package/lib/output/modifiers/__tests__/svgToImg.d.ts +2 -0
- package/lib/output/modifiers/__tests__/svgToImg.d.ts.map +1 -0
- package/lib/output/modifiers/addHeadingId.d.ts +8 -0
- package/lib/output/modifiers/addHeadingId.d.ts.map +1 -0
- package/lib/output/modifiers/annotateText.d.ts +10 -0
- package/lib/output/modifiers/annotateText.d.ts.map +1 -0
- package/lib/output/modifiers/editHTMLElement.d.ts +6 -0
- package/lib/output/modifiers/editHTMLElement.d.ts.map +1 -0
- package/lib/output/modifiers/fetchRemoteImages.d.ts +7 -0
- package/lib/output/modifiers/fetchRemoteImages.d.ts.map +1 -0
- package/lib/output/modifiers/highlightCode.d.ts +10 -0
- package/lib/output/modifiers/highlightCode.d.ts.map +1 -0
- package/lib/output/modifiers/index.d.ts +22 -0
- package/lib/output/modifiers/index.d.ts.map +1 -0
- package/lib/output/modifiers/inlineAssets.d.ts +8 -0
- package/lib/output/modifiers/inlineAssets.d.ts.map +1 -0
- package/lib/output/modifiers/inlinePng.d.ts +10 -0
- package/lib/output/modifiers/inlinePng.d.ts.map +1 -0
- package/lib/output/modifiers/inlineSvg.d.ts +10 -0
- package/lib/output/modifiers/inlineSvg.d.ts.map +1 -0
- package/lib/output/modifiers/modifyHTML.d.ts +11 -0
- package/lib/output/modifiers/modifyHTML.d.ts.map +1 -0
- package/lib/output/modifiers/resolveImages.d.ts +10 -0
- package/lib/output/modifiers/resolveImages.d.ts.map +1 -0
- package/lib/output/modifiers/resolveLinks.d.ts +11 -0
- package/lib/output/modifiers/resolveLinks.d.ts.map +1 -0
- package/lib/output/modifiers/svgToImg.d.ts +9 -0
- package/lib/output/modifiers/svgToImg.d.ts.map +1 -0
- package/lib/output/page-cache.d.ts +3 -0
- package/lib/output/page-cache.d.ts.map +1 -0
- package/lib/output/prepareAssets.d.ts +9 -0
- package/lib/output/prepareAssets.d.ts.map +1 -0
- package/lib/output/preparePages.d.ts +9 -0
- package/lib/output/preparePages.d.ts.map +1 -0
- package/lib/output/preparePlugins.d.ts +9 -0
- package/lib/output/preparePlugins.d.ts.map +1 -0
- package/lib/output/testing/createMock.d.ts +13 -0
- package/lib/output/testing/createMock.d.ts.map +1 -0
- package/lib/output/testing/generateMock.d.ts +24 -0
- package/lib/output/testing/generateMock.d.ts.map +1 -0
- package/lib/output/website/__tests__/i18n.d.ts +2 -0
- package/lib/output/website/__tests__/i18n.d.ts.map +1 -0
- package/lib/output/website/copyPluginAssets.d.ts +11 -0
- package/lib/output/website/copyPluginAssets.d.ts.map +1 -0
- package/lib/output/website/createTemplateEngine.d.ts +12 -0
- package/lib/output/website/createTemplateEngine.d.ts.map +1 -0
- package/lib/output/website/index.d.ts +18 -0
- package/lib/output/website/index.d.ts.map +1 -0
- package/lib/output/website/listSearchPaths.d.ts +9 -0
- package/lib/output/website/listSearchPaths.d.ts.map +1 -0
- package/lib/output/website/onAsset.d.ts +9 -0
- package/lib/output/website/onAsset.d.ts.map +1 -0
- package/lib/output/website/onFinish.d.ts +9 -0
- package/lib/output/website/onFinish.d.ts.map +1 -0
- package/lib/output/website/onInit.d.ts +9 -0
- package/lib/output/website/onInit.d.ts.map +1 -0
- package/lib/output/website/onPage.d.ts +9 -0
- package/lib/output/website/onPage.d.ts.map +1 -0
- package/lib/output/website/options.d.ts +4 -0
- package/lib/output/website/options.d.ts.map +1 -0
- package/lib/output/website/prepareI18n.d.ts +9 -0
- package/lib/output/website/prepareI18n.d.ts.map +1 -0
- package/lib/output/website/prepareResources.d.ts +9 -0
- package/lib/output/website/prepareResources.d.ts.map +1 -0
- package/lib/output/website/state.d.ts +10 -0
- package/lib/output/website/state.d.ts.map +1 -0
- package/lib/parse/__tests__/listAssets.d.ts +2 -0
- package/lib/parse/__tests__/listAssets.d.ts.map +1 -0
- package/lib/parse/__tests__/parseBook.d.ts +2 -0
- package/lib/parse/__tests__/parseBook.d.ts.map +1 -0
- package/lib/parse/__tests__/parseGlossary.d.ts +2 -0
- package/lib/parse/__tests__/parseGlossary.d.ts.map +1 -0
- package/lib/parse/__tests__/parseIgnore.d.ts +2 -0
- package/lib/parse/__tests__/parseIgnore.d.ts.map +1 -0
- package/lib/parse/__tests__/parsePageFromString.d.ts +2 -0
- package/lib/parse/__tests__/parsePageFromString.d.ts.map +1 -0
- package/lib/parse/__tests__/parseReadme.d.ts +2 -0
- package/lib/parse/__tests__/parseReadme.d.ts.map +1 -0
- package/lib/parse/__tests__/parseSummary.d.ts +2 -0
- package/lib/parse/__tests__/parseSummary.d.ts.map +1 -0
- package/lib/parse/findParsableFile.d.ts +10 -0
- package/lib/parse/findParsableFile.d.ts.map +1 -0
- package/lib/parse/index.d.ts +28 -0
- package/lib/parse/index.d.ts.map +1 -0
- package/lib/parse/listAssets.d.ts +11 -0
- package/lib/parse/listAssets.d.ts.map +1 -0
- package/lib/parse/lookupStructureFile.d.ts +12 -0
- package/lib/parse/lookupStructureFile.d.ts.map +1 -0
- package/lib/parse/parseBook.d.ts +9 -0
- package/lib/parse/parseBook.d.ts.map +1 -0
- package/lib/parse/parseConfig.d.ts +9 -0
- package/lib/parse/parseConfig.d.ts.map +1 -0
- package/lib/parse/parseGlossary.d.ts +9 -0
- package/lib/parse/parseGlossary.d.ts.map +1 -0
- package/lib/parse/parseIgnore.d.ts +9 -0
- package/lib/parse/parseIgnore.d.ts.map +1 -0
- package/lib/parse/parseLanguages.d.ts +9 -0
- package/lib/parse/parseLanguages.d.ts.map +1 -0
- package/lib/parse/parsePage.d.ts +10 -0
- package/lib/parse/parsePage.d.ts.map +1 -0
- package/lib/parse/parsePageFromString.d.ts +10 -0
- package/lib/parse/parsePageFromString.d.ts.map +1 -0
- package/lib/parse/parsePagesList.d.ts +9 -0
- package/lib/parse/parsePagesList.d.ts.map +1 -0
- package/lib/parse/parseReadme.d.ts +9 -0
- package/lib/parse/parseReadme.d.ts.map +1 -0
- package/lib/parse/parseStructureFile.d.ts +11 -0
- package/lib/parse/parseStructureFile.d.ts.map +1 -0
- package/lib/parse/parseStructureFile.js +7 -5
- package/lib/parse/parseSummary.d.ts +10 -0
- package/lib/parse/parseSummary.d.ts.map +1 -0
- package/lib/parse/validateConfig.d.ts +10 -0
- package/lib/parse/validateConfig.d.ts.map +1 -0
- package/lib/parse/walkSummary.d.ts +10 -0
- package/lib/parse/walkSummary.d.ts.map +1 -0
- package/lib/parsers.d.ts +31 -0
- package/lib/parsers.d.ts.map +1 -0
- package/lib/parsers.js +5 -5
- package/lib/plugins/PluginResolver.d.ts +26 -0
- package/lib/plugins/PluginResolver.d.ts.map +1 -0
- package/lib/plugins/__tests__/listDependencies.d.ts +2 -0
- package/lib/plugins/__tests__/listDependencies.d.ts.map +1 -0
- package/lib/plugins/__tests__/sortDependencies.d.ts +2 -0
- package/lib/plugins/__tests__/sortDependencies.d.ts.map +1 -0
- package/lib/plugins/__tests__/validatePlugin.d.ts +2 -0
- package/lib/plugins/__tests__/validatePlugin.d.ts.map +1 -0
- package/lib/plugins/index.d.ts +14 -0
- package/lib/plugins/index.d.ts.map +1 -0
- package/lib/plugins/listBlocks.d.ts +9 -0
- package/lib/plugins/listBlocks.d.ts.map +1 -0
- package/lib/plugins/listDependencies.d.ts +10 -0
- package/lib/plugins/listDependencies.d.ts.map +1 -0
- package/lib/plugins/listDepsForBook.d.ts +11 -0
- package/lib/plugins/listDepsForBook.d.ts.map +1 -0
- package/lib/plugins/listFilters.d.ts +9 -0
- package/lib/plugins/listFilters.d.ts.map +1 -0
- package/lib/plugins/listResources.d.ts +9 -0
- package/lib/plugins/listResources.d.ts.map +1 -0
- package/lib/plugins/loadForBook.d.ts +9 -0
- package/lib/plugins/loadForBook.d.ts.map +1 -0
- package/lib/plugins/loadPlugin.d.ts +11 -0
- package/lib/plugins/loadPlugin.d.ts.map +1 -0
- package/lib/plugins/package-name-util.d.ts +13 -0
- package/lib/plugins/package-name-util.d.ts.map +1 -0
- package/lib/plugins/sortDependencies.d.ts +10 -0
- package/lib/plugins/sortDependencies.d.ts.map +1 -0
- package/lib/plugins/toNames.d.ts +9 -0
- package/lib/plugins/toNames.d.ts.map +1 -0
- package/lib/plugins/validateConfig.d.ts +11 -0
- package/lib/plugins/validateConfig.d.ts.map +1 -0
- package/lib/plugins/validatePlugin.d.ts +9 -0
- package/lib/plugins/validatePlugin.d.ts.map +1 -0
- package/lib/templating/__tests__/conrefsLoader.d.ts +2 -0
- package/lib/templating/__tests__/conrefsLoader.d.ts.map +1 -0
- package/lib/templating/__tests__/postRender.d.ts +2 -0
- package/lib/templating/__tests__/postRender.d.ts.map +1 -0
- package/lib/templating/__tests__/replaceShortcuts.d.ts +2 -0
- package/lib/templating/__tests__/replaceShortcuts.d.ts.map +1 -0
- package/lib/templating/conrefsLoader.d.ts +14 -0
- package/lib/templating/conrefsLoader.d.ts.map +1 -0
- package/lib/templating/conrefsLoader.js +3 -3
- package/lib/templating/index.d.ts +14 -0
- package/lib/templating/index.d.ts.map +1 -0
- package/lib/templating/listShortcuts.d.ts +11 -0
- package/lib/templating/listShortcuts.d.ts.map +1 -0
- package/lib/templating/postRender.d.ts +12 -0
- package/lib/templating/postRender.d.ts.map +1 -0
- package/lib/templating/render.d.ts +12 -0
- package/lib/templating/render.d.ts.map +1 -0
- package/lib/templating/renderFile.d.ts +11 -0
- package/lib/templating/renderFile.d.ts.map +1 -0
- package/lib/templating/replaceShortcuts.d.ts +11 -0
- package/lib/templating/replaceShortcuts.d.ts.map +1 -0
- package/lib/templating/themesLoader.d.ts +4 -0
- package/lib/templating/themesLoader.d.ts.map +1 -0
- package/lib/utils/__tests__/git.d.ts +2 -0
- package/lib/utils/__tests__/git.d.ts.map +1 -0
- package/lib/utils/__tests__/location.d.ts +2 -0
- package/lib/utils/__tests__/location.d.ts.map +1 -0
- package/lib/utils/__tests__/path.d.ts +2 -0
- package/lib/utils/__tests__/path.d.ts.map +1 -0
- package/lib/utils/command.d.ts +25 -0
- package/lib/utils/command.d.ts.map +1 -0
- package/lib/utils/error.d.ts +16 -0
- package/lib/utils/error.d.ts.map +1 -0
- package/lib/utils/fs.d.ts +58 -0
- package/lib/utils/fs.d.ts.map +1 -0
- package/lib/utils/genKey.d.ts +3 -0
- package/lib/utils/genKey.d.ts.map +1 -0
- package/lib/utils/git.d.ts +11 -0
- package/lib/utils/git.d.ts.map +1 -0
- package/lib/utils/images.d.ts +6 -0
- package/lib/utils/images.d.ts.map +1 -0
- package/lib/utils/location.d.ts +62 -0
- package/lib/utils/location.d.ts.map +1 -0
- package/lib/utils/logger.d.ts +7 -0
- package/lib/utils/logger.d.ts.map +1 -0
- package/lib/utils/mergeDefaults.d.ts +9 -0
- package/lib/utils/mergeDefaults.d.ts.map +1 -0
- package/lib/utils/path.d.ts +14 -0
- package/lib/utils/path.d.ts.map +1 -0
- package/lib/utils/promise.d.ts +52 -0
- package/lib/utils/promise.d.ts.map +1 -0
- package/lib/utils/reducedObject.d.ts +9 -0
- package/lib/utils/reducedObject.d.ts.map +1 -0
- package/lib/utils/timing.d.ts +20 -0
- package/lib/utils/timing.d.ts.map +1 -0
- package/package.json +9 -8
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import Immutable from "immutable";
|
|
2
|
+
import File from "./file";
|
|
3
|
+
import Language from "./language";
|
|
4
|
+
declare const Languages_base: Immutable.Record.Class;
|
|
5
|
+
declare class Languages extends Languages_base {
|
|
6
|
+
getFile(): any;
|
|
7
|
+
getList(): any;
|
|
8
|
+
/**
|
|
9
|
+
Get default languages
|
|
10
|
+
|
|
11
|
+
@return {Language}
|
|
12
|
+
*/
|
|
13
|
+
getDefaultLanguage(): Language;
|
|
14
|
+
/**
|
|
15
|
+
Get a language by its ID
|
|
16
|
+
|
|
17
|
+
@param {string} lang
|
|
18
|
+
@return {Language}
|
|
19
|
+
*/
|
|
20
|
+
getLanguage(lang: string): Language;
|
|
21
|
+
/**
|
|
22
|
+
Return count of langs
|
|
23
|
+
|
|
24
|
+
@return {number}
|
|
25
|
+
*/
|
|
26
|
+
getCount(): any;
|
|
27
|
+
/**
|
|
28
|
+
Create a languages list from a JS object
|
|
29
|
+
|
|
30
|
+
@return {Language}
|
|
31
|
+
*/
|
|
32
|
+
static createFromList(file: File, langs: Languages): Languages;
|
|
33
|
+
}
|
|
34
|
+
export default Languages;
|
|
35
|
+
//# sourceMappingURL=languages.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"languages.d.ts","sourceRoot":"","sources":["../../src/models/languages.ts"],"names":[],"mappings":"AAAA,OAAO,SAAS,MAAM,WAAW,CAAC;AAClC,OAAO,IAAI,MAAM,QAAQ,CAAC;AAC1B,OAAO,QAAQ,MAAM,YAAY,CAAC;;AAElC,cAAM,SAAU,SAAQ,cAGtB;IACE,OAAO;IAIP,OAAO;IAIP;;;;OAIG;IACH,kBAAkB,IAAI,QAAQ;IAI9B;;;;;OAKG;IACH,WAAW,CAAC,IAAI,EAAE,MAAM,GAAG,QAAQ;IAInC;;;;OAIG;IACH,QAAQ;IAIR;;;;OAIG;IAEH,MAAM,CAAC,cAAc,CAAC,IAAI,EAAE,IAAI,EAAE,KAAK,EAAE,SAAS,GAAG,SAAS;CAgBjE;AAED,eAAe,SAAS,CAAC"}
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
import Immutable from "immutable";
|
|
2
|
+
import Book from "./book";
|
|
3
|
+
import Page from "./page";
|
|
4
|
+
import type GeneratorState from "../output/website/state";
|
|
5
|
+
type Assets = Immutable.List<string>;
|
|
6
|
+
type State = GeneratorState;
|
|
7
|
+
type Options = Immutable.Map<any, any>;
|
|
8
|
+
declare const Output_base: Immutable.Record.Class;
|
|
9
|
+
declare class Output extends Output_base {
|
|
10
|
+
getBook(): Book;
|
|
11
|
+
getGenerator(): string;
|
|
12
|
+
getPlugins(): Immutable.OrderedMap<string, Plugin>;
|
|
13
|
+
getPages(): Immutable.OrderedMap<string, Page>;
|
|
14
|
+
getOptions(): Options;
|
|
15
|
+
getAssets(): Assets;
|
|
16
|
+
getState(): State;
|
|
17
|
+
/**
|
|
18
|
+
Return a page byt its file path
|
|
19
|
+
|
|
20
|
+
@param {string} filePath
|
|
21
|
+
@return {Page|undefined}
|
|
22
|
+
*/
|
|
23
|
+
getPage(filePath: string): Page | undefined;
|
|
24
|
+
reloadPage(contentRootDir: string, filePath: string): Immutable.Map<string, any>;
|
|
25
|
+
/**
|
|
26
|
+
Get root folder for output
|
|
27
|
+
|
|
28
|
+
@return {string}
|
|
29
|
+
*/
|
|
30
|
+
getRoot(): string;
|
|
31
|
+
/**
|
|
32
|
+
Update state of output
|
|
33
|
+
|
|
34
|
+
@param {Map} newState
|
|
35
|
+
@return {Output}
|
|
36
|
+
*/
|
|
37
|
+
setState(newState: State): Output;
|
|
38
|
+
/**
|
|
39
|
+
Update options
|
|
40
|
+
|
|
41
|
+
@param {Map} newOptions
|
|
42
|
+
@return {Output}
|
|
43
|
+
*/
|
|
44
|
+
setOptions(newOptions: Options): Output;
|
|
45
|
+
/**
|
|
46
|
+
Return logegr for this output (same as book)
|
|
47
|
+
|
|
48
|
+
@return {Logger}
|
|
49
|
+
*/
|
|
50
|
+
getLogger(): any;
|
|
51
|
+
}
|
|
52
|
+
export default Output;
|
|
53
|
+
//# sourceMappingURL=output.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"output.d.ts","sourceRoot":"","sources":["../../src/models/output.ts"],"names":[],"mappings":"AAEA,OAAO,SAAS,MAAM,WAAW,CAAC;AAElC,OAAO,IAAI,MAAM,QAAQ,CAAC;AAE1B,OAAO,IAAI,MAAM,QAAQ,CAAC;AAC1B,OAAO,KAAK,cAAc,MAAM,yBAAyB,CAAC;AAE1D,KAAK,MAAM,GAAG,SAAS,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;AACrC,KAAK,KAAK,GAAG,cAAc,CAAC;AAC5B,KAAK,OAAO,GAAG,SAAS,CAAC,GAAG,CAAC,GAAG,EAAE,GAAG,CAAC,CAAC;;AACvC,cAAM,MAAO,SAAQ,WAwBnB;IACE,OAAO,IAAI,IAAI;IAIf,YAAY,IAAI,MAAM;IAItB,UAAU,IAAI,SAAS,CAAC,UAAU,CAAC,MAAM,EAAE,MAAM,CAAC;IAIlD,QAAQ,IAAI,SAAS,CAAC,UAAU,CAAC,MAAM,EAAE,IAAI,CAAC;IAI9C,UAAU,IAAI,OAAO;IAIrB,SAAS,IAAI,MAAM;IAInB,QAAQ,IAAI,KAAK;IAIjB;;;;;OAKG;IACH,OAAO,CAAC,QAAQ,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS;IAO3C,UAAU,CAAC,cAAc,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM;IAanD;;;;OAIG;IACH,OAAO,IAAI,MAAM;IAIjB;;;;;OAKG;IACH,QAAQ,CAAC,QAAQ,EAAE,KAAK,GAAG,MAAM;IAIjC;;;;;OAKG;IACH,UAAU,CAAC,UAAU,EAAE,OAAO,GAAG,MAAM;IAIvC;;;;OAIG;IACH,SAAS;CAGZ;AAED,eAAe,MAAM,CAAC"}
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import Immutable from "immutable";
|
|
2
|
+
import File from "./file";
|
|
3
|
+
declare const Page_base: Immutable.Record.Class;
|
|
4
|
+
declare class Page extends Page_base {
|
|
5
|
+
getFile(): File;
|
|
6
|
+
getAttributes(): any;
|
|
7
|
+
getContent(): string;
|
|
8
|
+
getDir(): string;
|
|
9
|
+
/**
|
|
10
|
+
* Return page as text
|
|
11
|
+
* @return {string}
|
|
12
|
+
*/
|
|
13
|
+
toText(): string;
|
|
14
|
+
/**
|
|
15
|
+
* Return path of the page
|
|
16
|
+
* @return {string}
|
|
17
|
+
*/
|
|
18
|
+
getPath(): string;
|
|
19
|
+
/**
|
|
20
|
+
* Create a page for a file
|
|
21
|
+
* @param {File} file
|
|
22
|
+
* @return {Page}
|
|
23
|
+
*/
|
|
24
|
+
static createForFile(file: File): Page;
|
|
25
|
+
/**
|
|
26
|
+
* Load a page for a file
|
|
27
|
+
* @param {File} file
|
|
28
|
+
* @param {string} content
|
|
29
|
+
* @return {Page}
|
|
30
|
+
*/
|
|
31
|
+
static loadFile(file: File, content: string): Page;
|
|
32
|
+
static fromJSON(json: {
|
|
33
|
+
file: {
|
|
34
|
+
[key: string]: any;
|
|
35
|
+
};
|
|
36
|
+
atributes: Immutable.Iterable.Keyed<unknown, unknown>;
|
|
37
|
+
content: any;
|
|
38
|
+
dir: any;
|
|
39
|
+
}): Page;
|
|
40
|
+
static toJSON(page: Page): any;
|
|
41
|
+
hash(): number;
|
|
42
|
+
}
|
|
43
|
+
export default Page;
|
|
44
|
+
//# sourceMappingURL=page.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"page.d.ts","sourceRoot":"","sources":["../../src/models/page.ts"],"names":[],"mappings":"AAAA,OAAO,SAAS,MAAM,WAAW,CAAC;AAElC,OAAO,IAAI,MAAM,QAAQ,CAAC;;AAG1B,cAAM,IAAK,SAAQ,SAWjB;IACE,OAAO,IAAI,IAAI;IAIf,aAAa;IAIb,UAAU,IAAI,MAAM;IAIpB,MAAM,IAAI,MAAM;IAIhB;;;OAGG;IACH,MAAM,IAAI,MAAM;IAYhB;;;OAGG;IACH,OAAO,IAAI,MAAM;IAIjB;;;;OAIG;IACH,MAAM,CAAC,aAAa,CAAC,IAAI,EAAE,IAAI,GAAG,IAAI;IAMtC;;;;;OAKG;IACH,MAAM,CAAC,QAAQ,CAAC,IAAI,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,GAAG,IAAI;IAOlD,MAAM,CAAC,QAAQ,CAAC,IAAI,EAAE;QAClB,IAAI,EAAE;YAAE,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAA;SAAE,CAAC;QAC7B,SAAS,EAAE,SAAS,CAAC,QAAQ,CAAC,KAAK,CAAC,OAAO,EAAE,OAAO,CAAC,CAAC;QACtD,OAAO,EAAE,GAAG,CAAC;QACb,GAAG,EAAE,GAAG,CAAC;KACZ;IAYD,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,IAAI;IAIxB,IAAI;CAGP;AAED,eAAe,IAAI,CAAC"}
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import Immutable from "immutable";
|
|
2
|
+
export type ParserOptions = {
|
|
3
|
+
baseDirectory: string;
|
|
4
|
+
};
|
|
5
|
+
declare const Parser_base: Immutable.Record.Class;
|
|
6
|
+
declare class Parser extends Parser_base {
|
|
7
|
+
getName(): string;
|
|
8
|
+
getExtensions(): Immutable.List<string>;
|
|
9
|
+
parseReadme(content: string, options: ParserOptions): any;
|
|
10
|
+
parseSummary(content: string, options: ParserOptions): any;
|
|
11
|
+
parseGlossary(content: string, options: ParserOptions): any;
|
|
12
|
+
preparePage(content: string): any;
|
|
13
|
+
parsePage(content: string, options: ParserOptions): any;
|
|
14
|
+
parseInline(content: string, options: ParserOptions): any;
|
|
15
|
+
parseLanguages(content: string, options: ParserOptions): any;
|
|
16
|
+
renderLanguages(content: any): any;
|
|
17
|
+
renderSummary(content: any): any;
|
|
18
|
+
renderGlossary(content: any): any;
|
|
19
|
+
/**
|
|
20
|
+
Test if this parser matches an extension
|
|
21
|
+
|
|
22
|
+
@param {string} ext
|
|
23
|
+
@return {boolean}
|
|
24
|
+
*/
|
|
25
|
+
matchExtension(ext: string): boolean;
|
|
26
|
+
/**
|
|
27
|
+
Create a new parser using a module (gitbook-markdown, etc)
|
|
28
|
+
|
|
29
|
+
@param {string} name
|
|
30
|
+
@param {Array<String>} extensions
|
|
31
|
+
@param {Object} module
|
|
32
|
+
@return {Parsers}
|
|
33
|
+
*/
|
|
34
|
+
static create(name: string, extensions: string[] | Immutable.Iterable.Indexed<unknown>, module: {
|
|
35
|
+
readme: any;
|
|
36
|
+
langs: any;
|
|
37
|
+
summary: any;
|
|
38
|
+
glossary: any;
|
|
39
|
+
page: any;
|
|
40
|
+
inline: any;
|
|
41
|
+
}): Parser;
|
|
42
|
+
}
|
|
43
|
+
export default Parser;
|
|
44
|
+
//# sourceMappingURL=parser.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"parser.d.ts","sourceRoot":"","sources":["../../src/models/parser.ts"],"names":[],"mappings":"AAAA,OAAO,SAAS,MAAM,WAAW,CAAC;AAGlC,MAAM,MAAM,aAAa,GAAG;IACxB,aAAa,EAAE,MAAM,CAAC;CACzB,CAAC;;AACF,cAAM,MAAO,SAAQ,WAanB;IACE,OAAO,IAAI,MAAM;IAIjB,aAAa,IAAI,SAAS,CAAC,IAAI,CAAC,MAAM,CAAC;IAMvC,WAAW,CAAC,OAAO,EAAE,MAAM,EAAE,OAAO,EAAE,aAAa;IAMnD,YAAY,CAAC,OAAO,EAAE,MAAM,EAAE,OAAO,EAAE,aAAa;IAMpD,aAAa,CAAC,OAAO,EAAE,MAAM,EAAE,OAAO,EAAE,aAAa;IAMrD,WAAW,CAAC,OAAO,EAAE,MAAM;IAS3B,SAAS,CAAC,OAAO,EAAE,MAAM,EAAE,OAAO,EAAE,aAAa;IAMjD,WAAW,CAAC,OAAO,EAAE,MAAM,EAAE,OAAO,EAAE,aAAa;IAMnD,cAAc,CAAC,OAAO,EAAE,MAAM,EAAE,OAAO,EAAE,aAAa;IAQtD,eAAe,CAAC,OAAO,EAAE,GAAG;IAM5B,aAAa,CAAC,OAAO,EAAE,GAAG;IAM1B,cAAc,CAAC,OAAO,EAAE,GAAG;IAM3B;;;;;OAKG;IACH,cAAc,CAAC,GAAG,EAAE,MAAM;IAK1B;;;;;;;OAOG;IACH,MAAM,CAAC,MAAM,CACT,IAAI,EAAE,MAAM,EACZ,UAAU,EAAE,MAAM,EAAE,GAAG,SAAS,CAAC,QAAQ,CAAC,OAAO,CAAC,OAAO,CAAC,EAC1D,MAAM,EAAE;QAAE,MAAM,EAAE,GAAG,CAAC;QAAC,KAAK,EAAE,GAAG,CAAC;QAAC,OAAO,EAAE,GAAG,CAAC;QAAC,QAAQ,EAAE,GAAG,CAAC;QAAC,IAAI,EAAE,GAAG,CAAC;QAAC,MAAM,EAAE,GAAG,CAAA;KAAE;CAa/F;AAED,eAAe,MAAM,CAAC"}
|
package/lib/models/parser.js
CHANGED
|
@@ -15,7 +15,7 @@ class Parser extends immutable_1.default.Record({
|
|
|
15
15
|
summary: Function(),
|
|
16
16
|
glossary: Function(),
|
|
17
17
|
page: Function(),
|
|
18
|
-
inline: Function()
|
|
18
|
+
inline: Function()
|
|
19
19
|
}) {
|
|
20
20
|
getName() {
|
|
21
21
|
return this.get("name");
|
|
@@ -24,17 +24,17 @@ class Parser extends immutable_1.default.Record({
|
|
|
24
24
|
return this.get("extensions");
|
|
25
25
|
}
|
|
26
26
|
// PARSE
|
|
27
|
-
parseReadme(content) {
|
|
27
|
+
parseReadme(content, options) {
|
|
28
28
|
const readme = this.get("readme");
|
|
29
|
-
return (0, promise_1.default)(readme(content));
|
|
29
|
+
return (0, promise_1.default)(readme(content, options));
|
|
30
30
|
}
|
|
31
|
-
parseSummary(content) {
|
|
31
|
+
parseSummary(content, options) {
|
|
32
32
|
const summary = this.get("summary");
|
|
33
33
|
return (0, promise_1.default)(summary(content));
|
|
34
34
|
}
|
|
35
|
-
parseGlossary(content) {
|
|
35
|
+
parseGlossary(content, options) {
|
|
36
36
|
const glossary = this.get("glossary");
|
|
37
|
-
return (0, promise_1.default)(glossary(content));
|
|
37
|
+
return (0, promise_1.default)(glossary(content, options));
|
|
38
38
|
}
|
|
39
39
|
preparePage(content) {
|
|
40
40
|
const page = this.get("page");
|
|
@@ -43,17 +43,17 @@ class Parser extends immutable_1.default.Record({
|
|
|
43
43
|
}
|
|
44
44
|
return (0, promise_1.default)(page.prepare(content));
|
|
45
45
|
}
|
|
46
|
-
parsePage(content) {
|
|
46
|
+
parsePage(content, options) {
|
|
47
47
|
const page = this.get("page");
|
|
48
|
-
return (0, promise_1.default)(page(content));
|
|
48
|
+
return (0, promise_1.default)(page(content, options));
|
|
49
49
|
}
|
|
50
|
-
parseInline(content) {
|
|
50
|
+
parseInline(content, options) {
|
|
51
51
|
const inline = this.get("inline");
|
|
52
|
-
return (0, promise_1.default)(inline(content));
|
|
52
|
+
return (0, promise_1.default)(inline(content, options));
|
|
53
53
|
}
|
|
54
|
-
parseLanguages(content) {
|
|
54
|
+
parseLanguages(content, options) {
|
|
55
55
|
const langs = this.get("langs");
|
|
56
|
-
return (0, promise_1.default)(langs(content));
|
|
56
|
+
return (0, promise_1.default)(langs(content, options));
|
|
57
57
|
}
|
|
58
58
|
// TO TEXT
|
|
59
59
|
renderLanguages(content) {
|
|
@@ -84,7 +84,7 @@ class Parser extends immutable_1.default.Record({
|
|
|
84
84
|
@param {string} name
|
|
85
85
|
@param {Array<String>} extensions
|
|
86
86
|
@param {Object} module
|
|
87
|
-
@return {
|
|
87
|
+
@return {Parsers}
|
|
88
88
|
*/
|
|
89
89
|
static create(name, extensions, module) {
|
|
90
90
|
return new Parser({
|
|
@@ -95,7 +95,7 @@ class Parser extends immutable_1.default.Record({
|
|
|
95
95
|
summary: module.summary,
|
|
96
96
|
glossary: module.glossary,
|
|
97
97
|
page: module.page,
|
|
98
|
-
inline: module.inline
|
|
98
|
+
inline: module.inline
|
|
99
99
|
});
|
|
100
100
|
}
|
|
101
101
|
}
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
import Immutable from "immutable";
|
|
2
|
+
import PluginDependency from "./pluginDependency";
|
|
3
|
+
type Content = Immutable.Map<any, any>;
|
|
4
|
+
type Package = Immutable.Map<any, any>;
|
|
5
|
+
declare const Plugin_base: Immutable.Record.Class;
|
|
6
|
+
declare class Plugin extends Plugin_base {
|
|
7
|
+
getName(): string;
|
|
8
|
+
getPath(): string;
|
|
9
|
+
getVersion(): string;
|
|
10
|
+
getPackage(): Package;
|
|
11
|
+
getContent(): Content;
|
|
12
|
+
getDepth(): number;
|
|
13
|
+
getParent(): string;
|
|
14
|
+
/**
|
|
15
|
+
* Return the ID on NPM for this plugin
|
|
16
|
+
* return package.json's name
|
|
17
|
+
* @return {string}
|
|
18
|
+
*/
|
|
19
|
+
getNpmID(): string;
|
|
20
|
+
/**
|
|
21
|
+
* Check if a plugin is loaded
|
|
22
|
+
* @return {boolean}
|
|
23
|
+
*/
|
|
24
|
+
isLoaded(): boolean;
|
|
25
|
+
/**
|
|
26
|
+
* Check if a plugin is a theme given its name
|
|
27
|
+
* @return {boolean}
|
|
28
|
+
*/
|
|
29
|
+
isTheme(): boolean;
|
|
30
|
+
/**
|
|
31
|
+
* Return map of hooks
|
|
32
|
+
*/
|
|
33
|
+
getHooks(): Immutable.Map<string, Function>;
|
|
34
|
+
/**
|
|
35
|
+
* Return infos about resources for a specific type
|
|
36
|
+
* @param {string} type
|
|
37
|
+
* @return {Map<String:Mixed>}
|
|
38
|
+
*/
|
|
39
|
+
getResources(type: string): any;
|
|
40
|
+
/**
|
|
41
|
+
* Return map of filters
|
|
42
|
+
* @return {Map<String:Function>}
|
|
43
|
+
*/
|
|
44
|
+
getFilters(): any;
|
|
45
|
+
/**
|
|
46
|
+
* Return map of blocks
|
|
47
|
+
* @return {Map<String:TemplateBlock>}
|
|
48
|
+
*/
|
|
49
|
+
getBlocks(): any;
|
|
50
|
+
/**
|
|
51
|
+
* Return a specific hook
|
|
52
|
+
* @param {string} name
|
|
53
|
+
* @return {Function|undefined}
|
|
54
|
+
*/
|
|
55
|
+
getHook(name: string): Function;
|
|
56
|
+
/**
|
|
57
|
+
* Create a plugin from a string
|
|
58
|
+
* @return {Plugin}
|
|
59
|
+
* @param s
|
|
60
|
+
*/
|
|
61
|
+
static createFromString(s: string): Plugin;
|
|
62
|
+
/**
|
|
63
|
+
* Create a plugin from a dependency
|
|
64
|
+
* @return {Plugin}
|
|
65
|
+
*/
|
|
66
|
+
static createFromDep(dep: PluginDependency): Plugin;
|
|
67
|
+
}
|
|
68
|
+
export default Plugin;
|
|
69
|
+
//# sourceMappingURL=plugin.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"plugin.d.ts","sourceRoot":"","sources":["../../src/models/plugin.ts"],"names":[],"mappings":"AAAA,OAAO,SAAS,MAAM,WAAW,CAAC;AAElC,OAAO,gBAAgB,MAAM,oBAAoB,CAAC;AAKlD,KAAK,OAAO,GAAG,SAAS,CAAC,GAAG,CAAC,GAAG,EAAE,GAAG,CAAC,CAAC;AACvC,KAAK,OAAO,GAAG,SAAS,CAAC,GAAG,CAAC,GAAG,EAAE,GAAG,CAAC,CAAC;;AAEvC,cAAM,MAAO,SAAQ,WAuBpB;IACG,OAAO,IAAI,MAAM;IAIjB,OAAO,IAAI,MAAM;IAIjB,UAAU,IAAI,MAAM;IAIpB,UAAU,IAAI,OAAO;IAIrB,UAAU,IAAI,OAAO;IAIrB,QAAQ,IAAI,MAAM;IAIlB,SAAS,IAAI,MAAM;IAInB;;;;OAIG;IAEH,QAAQ,IAAI,MAAM;IAQlB;;;OAGG;IAEH,QAAQ,IAAI,OAAO;IAInB;;;OAGG;IAEH,OAAO,IAAI,OAAO;IAKlB;;OAEG;IACH,QAAQ,IAAI,SAAS,CAAC,GAAG,CAAC,MAAM,EAAE,QAAQ,CAAC;IAI3C;;;;OAIG;IAEH,YAAY,CAAC,IAAI,EAAE,MAAM;IASzB;;;OAGG;IAEH,UAAU;IAIV;;;OAGG;IAEH,SAAS;IAST;;;;OAIG;IAEH,OAAO,CAAC,IAAI,EAAE,MAAM;IAIpB;;;;OAIG;IAEH,MAAM,CAAC,gBAAgB,CAAC,CAAC,EAAE,MAAM;IAWjC;;;OAGG;IAEH,MAAM,CAAC,aAAa,CAAC,GAAG,EAAE,gBAAgB;CAM7C;AAED,eAAe,MAAM,CAAC"}
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import Immutable from "immutable";
|
|
2
|
+
declare const PluginDependency_base: Immutable.Record.Class;
|
|
3
|
+
declare class PluginDependency extends PluginDependency_base {
|
|
4
|
+
getName(): any;
|
|
5
|
+
getVersion(): any;
|
|
6
|
+
getPath(): any;
|
|
7
|
+
isEnabled(): any;
|
|
8
|
+
/**
|
|
9
|
+
* Toggle this plugin state
|
|
10
|
+
* @return {PluginDependency}
|
|
11
|
+
*/
|
|
12
|
+
toggle(state?: boolean): Immutable.Map<string, any>;
|
|
13
|
+
/**
|
|
14
|
+
* Is the plugin using a git dependency
|
|
15
|
+
* @return {boolean}
|
|
16
|
+
*/
|
|
17
|
+
isGitDependency(): boolean;
|
|
18
|
+
/**
|
|
19
|
+
* Create a plugin with a name and a plugin
|
|
20
|
+
* @return {Plugin|undefined}
|
|
21
|
+
*/
|
|
22
|
+
static create(name: string, version: string, enabled?: boolean): PluginDependency;
|
|
23
|
+
/**
|
|
24
|
+
* Create a plugin from a string
|
|
25
|
+
* @param {string} s
|
|
26
|
+
* @return {Plugin|undefined}
|
|
27
|
+
*/
|
|
28
|
+
static createFromString(s: any): PluginDependency;
|
|
29
|
+
/**
|
|
30
|
+
* Create a PluginDependency from a string
|
|
31
|
+
* @param {string}
|
|
32
|
+
* @return {List<PluginDependency>}
|
|
33
|
+
*/
|
|
34
|
+
static listFromString(s: any): Immutable.Iterable<number, PluginDependency>;
|
|
35
|
+
/**
|
|
36
|
+
* Create a PluginDependency from an array
|
|
37
|
+
*/
|
|
38
|
+
static listFromArray(arr: (PluginDependency | string)[]): Immutable.Iterable<number, PluginDependency>;
|
|
39
|
+
/**
|
|
40
|
+
* Export plugin dependencies as an array
|
|
41
|
+
* @param {List<PluginDependency>} list
|
|
42
|
+
* @return {Array<String>}
|
|
43
|
+
*/
|
|
44
|
+
static listToArray(list: any): any;
|
|
45
|
+
}
|
|
46
|
+
export default PluginDependency;
|
|
47
|
+
//# sourceMappingURL=pluginDependency.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pluginDependency.d.ts","sourceRoot":"","sources":["../../src/models/pluginDependency.ts"],"names":[],"mappings":"AAEA,OAAO,SAAS,MAAM,WAAW,CAAC;;AASlC,cAAM,gBAAiB,SAAQ,qBAc9B;IACG,OAAO;IAIP,UAAU;IAIV,OAAO;IAIP,SAAS;IAIT;;;OAGG;IACH,MAAM,CAAC,KAAK,CAAC,EAAE,OAAO;IAQtB;;;OAGG;IACH,eAAe;IAIf;;;OAGG;IACH,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,OAAO;IAY9D;;;;OAIG;IACH,MAAM,CAAC,gBAAgB,CAAC,CAAC,KAAA;IAqDzB;;;;OAIG;IACH,MAAM,CAAC,cAAc,CAAC,CAAC,KAAA;IAKvB;;OAEG;IACH,MAAM,CAAC,aAAa,CAAC,GAAG,EAAE,CAAC,gBAAgB,GAAG,MAAM,CAAC,EAAE;IAiBvD;;;;OAIG;IACH,MAAM,CAAC,WAAW,CAAC,IAAI,KAAA;CAkB1B;AAED,eAAe,gBAAgB,CAAC"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import Immutable from "immutable";
|
|
2
|
+
import File from "./file";
|
|
3
|
+
declare const Readme_base: Immutable.Record.Class;
|
|
4
|
+
declare class Readme extends Readme_base {
|
|
5
|
+
getFile(): File;
|
|
6
|
+
getTitle(): string;
|
|
7
|
+
getDescription(): string;
|
|
8
|
+
/**
|
|
9
|
+
Create a new readme
|
|
10
|
+
|
|
11
|
+
@param {File} file
|
|
12
|
+
@param {Object} def
|
|
13
|
+
@return {Readme}
|
|
14
|
+
*/
|
|
15
|
+
static create(file: File, def: {
|
|
16
|
+
title?: any;
|
|
17
|
+
description?: any;
|
|
18
|
+
}): Readme;
|
|
19
|
+
}
|
|
20
|
+
export default Readme;
|
|
21
|
+
//# sourceMappingURL=readme.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"readme.d.ts","sourceRoot":"","sources":["../../src/models/readme.ts"],"names":[],"mappings":"AAAA,OAAO,SAAS,MAAM,WAAW,CAAC;AAClC,OAAO,IAAI,MAAM,QAAQ,CAAC;;AAE1B,cAAM,MAAO,SAAQ,WAInB;IACE,OAAO,IAAI,IAAI;IAIf,QAAQ,IAAI,MAAM;IAIlB,cAAc,IAAI,MAAM;IAIxB;;;;;;OAMG;IACH,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,IAAI,EAAE,GAAG,EAAE;QAAE,KAAK,CAAC,EAAE,GAAG,CAAC;QAAC,WAAW,CAAC,EAAE,GAAG,CAAA;KAAE;CASpE;AAED,eAAe,MAAM,CAAC"}
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
import Immutable from "immutable";
|
|
2
|
+
import File from "./file";
|
|
3
|
+
import SummaryArticle from "./summaryArticle";
|
|
4
|
+
type Parts = Immutable.List<any>;
|
|
5
|
+
declare const Summary_base: Immutable.Record.Class;
|
|
6
|
+
declare class Summary extends Summary_base {
|
|
7
|
+
getFile(): File;
|
|
8
|
+
getParts(): Parts;
|
|
9
|
+
/**
|
|
10
|
+
Return a part by its index
|
|
11
|
+
*/
|
|
12
|
+
getPart(i: number): any;
|
|
13
|
+
/**
|
|
14
|
+
Return an article using an iterator to find it.
|
|
15
|
+
if "partIter" is set, it can also return a Part.
|
|
16
|
+
|
|
17
|
+
@param {Function} iter
|
|
18
|
+
@param {Function} [partIter]
|
|
19
|
+
@return {Article|Part}
|
|
20
|
+
*/
|
|
21
|
+
getArticle(iter: any, partIter?: any): SummaryArticle | null;
|
|
22
|
+
/**
|
|
23
|
+
Return a part/article by its level
|
|
24
|
+
|
|
25
|
+
@param {string} level
|
|
26
|
+
@return {Article|Part}
|
|
27
|
+
*/
|
|
28
|
+
getByLevel(level: string): SummaryArticle;
|
|
29
|
+
/**
|
|
30
|
+
Return an article by its path
|
|
31
|
+
|
|
32
|
+
@param {string} filePath
|
|
33
|
+
@return {Article}
|
|
34
|
+
*/
|
|
35
|
+
getByPath(filePath: string): SummaryArticle;
|
|
36
|
+
/**
|
|
37
|
+
Return the first article
|
|
38
|
+
|
|
39
|
+
@return {Article}
|
|
40
|
+
*/
|
|
41
|
+
getFirstArticle(): SummaryArticle;
|
|
42
|
+
/**
|
|
43
|
+
Return next article of an article
|
|
44
|
+
|
|
45
|
+
*/
|
|
46
|
+
getNextArticle(current: SummaryArticle | string): SummaryArticle;
|
|
47
|
+
/**
|
|
48
|
+
Return previous article of an article
|
|
49
|
+
|
|
50
|
+
@param {Article} current
|
|
51
|
+
@return {Article}
|
|
52
|
+
*/
|
|
53
|
+
getPrevArticle(current: any): any;
|
|
54
|
+
/**
|
|
55
|
+
Return the parent article, or parent part of an article
|
|
56
|
+
|
|
57
|
+
@param {String|Article} current
|
|
58
|
+
@return {Article|Part|Null}
|
|
59
|
+
*/
|
|
60
|
+
getParent(level: any): SummaryArticle;
|
|
61
|
+
/**
|
|
62
|
+
Render summary as text
|
|
63
|
+
|
|
64
|
+
@param {string} parseExt Extension of the parser to use
|
|
65
|
+
@return {Promise<String>}
|
|
66
|
+
*/
|
|
67
|
+
toText(parseExt: any): any;
|
|
68
|
+
/**
|
|
69
|
+
Return all articles as a list
|
|
70
|
+
|
|
71
|
+
@return {List<Article>}
|
|
72
|
+
*/
|
|
73
|
+
getArticlesAsList(): Immutable.List<any>;
|
|
74
|
+
/**
|
|
75
|
+
Create a new summary for a list of parts
|
|
76
|
+
|
|
77
|
+
@param {Lust|Array} parts
|
|
78
|
+
@return {Summary}
|
|
79
|
+
*/
|
|
80
|
+
static createFromParts(file: any, parts: any): Summary;
|
|
81
|
+
}
|
|
82
|
+
export default Summary;
|
|
83
|
+
//# sourceMappingURL=summary.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"summary.d.ts","sourceRoot":"","sources":["../../src/models/summary.ts"],"names":[],"mappings":"AACA,OAAO,SAAS,MAAM,WAAW,CAAC;AAGlC,OAAO,IAAI,MAAM,QAAQ,CAAC;AAE1B,OAAO,cAAc,MAAM,kBAAkB,CAAC;AAG9C,KAAK,KAAK,GAAG,SAAS,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;;AAEjC,cAAM,OAAQ,SAAQ,YAMrB;IACG,OAAO,IAAI,IAAI;IAIf,QAAQ,IAAI,KAAK;IAIjB;;OAEG;IACH,OAAO,CAAC,CAAC,EAAE,MAAM;IAKjB;;;;;;;OAOG;IACH,UAAU,CAAC,IAAI,KAAA,EAAE,QAAQ,CAAC,KAAA,GAAG,cAAc,GAAG,IAAI;IAWlD;;;;;OAKG;IACH,UAAU,CAAC,KAAK,EAAE,MAAM;IAQxB;;;;;OAKG;IACH,SAAS,CAAC,QAAQ,EAAE,MAAM,GAAG,cAAc;IAQ3C;;;;OAIG;IACH,eAAe;IAMf;;;OAGG;IACH,cAAc,CAAC,OAAO,EAAE,cAAc,GAAG,MAAM,GAAG,cAAc;IAgBhE;;;;;OAKG;IACH,cAAc,CAAC,OAAO,KAAA;IAiBtB;;;;;OAKG;IACH,SAAS,CAAC,KAAK,KAAA;IAef;;;;;OAKG;IACH,MAAM,CAAC,QAAQ,KAAA;IAiBf;;;;OAIG;IACH,iBAAiB;IAUjB;;;;;OAKG;IACH,MAAM,CAAC,eAAe,CAAC,IAAI,KAAA,EAAE,KAAK,KAAA;CAerC;AAaD,eAAe,OAAO,CAAC"}
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
import Immutable from "immutable";
|
|
2
|
+
import File from "./file";
|
|
3
|
+
import Book from "./book";
|
|
4
|
+
import Readme from "./readme";
|
|
5
|
+
type Articles = Immutable.List<SummaryArticle>;
|
|
6
|
+
declare const SummaryArticle_base: Immutable.Record.Class;
|
|
7
|
+
declare class SummaryArticle extends SummaryArticle_base {
|
|
8
|
+
getLevel(): string;
|
|
9
|
+
getTitle(): string;
|
|
10
|
+
getRef(): string;
|
|
11
|
+
getArticles(): Articles;
|
|
12
|
+
/**
|
|
13
|
+
* Return how deep the article is.
|
|
14
|
+
* The README has a depth of 1
|
|
15
|
+
*
|
|
16
|
+
* @return {number}
|
|
17
|
+
*/
|
|
18
|
+
getDepth(): number;
|
|
19
|
+
/**
|
|
20
|
+
* Get path (without anchor) to the pointing file.
|
|
21
|
+
* It also normalizes the file path.
|
|
22
|
+
*
|
|
23
|
+
* @return {string}
|
|
24
|
+
*/
|
|
25
|
+
getPath(): string;
|
|
26
|
+
/**
|
|
27
|
+
* Return url if article is external
|
|
28
|
+
*
|
|
29
|
+
* @return {string}
|
|
30
|
+
*/
|
|
31
|
+
getUrl(): string;
|
|
32
|
+
/**
|
|
33
|
+
* Get anchor for this article (or undefined)
|
|
34
|
+
*
|
|
35
|
+
* @return {string}
|
|
36
|
+
*/
|
|
37
|
+
getAnchor(): string;
|
|
38
|
+
/**
|
|
39
|
+
* Create a new level for a new child article
|
|
40
|
+
*
|
|
41
|
+
* @return {string}
|
|
42
|
+
*/
|
|
43
|
+
createChildLevel(): string;
|
|
44
|
+
/**
|
|
45
|
+
* Is article pointing to a page of an absolute url
|
|
46
|
+
*
|
|
47
|
+
* @return {boolean}
|
|
48
|
+
*/
|
|
49
|
+
isPage(): boolean;
|
|
50
|
+
/**
|
|
51
|
+
* Check if this article is a file (exatcly)
|
|
52
|
+
*
|
|
53
|
+
* @param {File} file
|
|
54
|
+
* @return {boolean}
|
|
55
|
+
*/
|
|
56
|
+
isFile(file: File): boolean;
|
|
57
|
+
/**
|
|
58
|
+
* Check if this article is the introduction of the book
|
|
59
|
+
*
|
|
60
|
+
* @param {Book|Readme} book
|
|
61
|
+
* @return {boolean}
|
|
62
|
+
*/
|
|
63
|
+
isReadme(book: Book | Readme): boolean;
|
|
64
|
+
/**
|
|
65
|
+
* Is article pointing to aan absolute url
|
|
66
|
+
*
|
|
67
|
+
* @return {boolean}
|
|
68
|
+
*/
|
|
69
|
+
isExternal(): boolean;
|
|
70
|
+
/**
|
|
71
|
+
* Create a SummaryArticle
|
|
72
|
+
*
|
|
73
|
+
* @param {Object} def
|
|
74
|
+
* @return {SummaryArticle}
|
|
75
|
+
*/
|
|
76
|
+
static create(def: any, level: any): SummaryArticle;
|
|
77
|
+
/**
|
|
78
|
+
* Has anchor for this article
|
|
79
|
+
*
|
|
80
|
+
* @return {boolean}
|
|
81
|
+
*/
|
|
82
|
+
hasAnchor(): boolean;
|
|
83
|
+
/**
|
|
84
|
+
* Find an article from a base one
|
|
85
|
+
*
|
|
86
|
+
* @param {Article|Part} base
|
|
87
|
+
* @param {Function(article)} iter
|
|
88
|
+
* @return {Article}
|
|
89
|
+
*/
|
|
90
|
+
static findArticle(base: any, iter: any): SummaryArticle | null;
|
|
91
|
+
}
|
|
92
|
+
export default SummaryArticle;
|
|
93
|
+
//# sourceMappingURL=summaryArticle.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"summaryArticle.d.ts","sourceRoot":"","sources":["../../src/models/summaryArticle.ts"],"names":[],"mappings":"AAAA,OAAO,SAAS,MAAM,WAAW,CAAC;AAElC,OAAO,IAAI,MAAM,QAAQ,CAAC;AAC1B,OAAO,IAAI,MAAM,QAAQ,CAAC;AAC1B,OAAO,MAAM,MAAM,UAAU,CAAC;AAM9B,KAAK,QAAQ,GAAG,SAAS,CAAC,IAAI,CAAC,cAAc,CAAC,CAAC;;AAE/C,cAAM,cAAe,SAAQ,mBAQ5B;IACG,QAAQ,IAAI,MAAM;IAIlB,QAAQ,IAAI,MAAM;IAIlB,MAAM,IAAI,MAAM;IAIhB,WAAW,IAAI,QAAQ;IAIvB;;;;;OAKG;IACH,QAAQ,IAAI,MAAM;IAIlB;;;;;OAKG;IACH,OAAO,IAAI,MAAM;IAmBjB;;;;OAIG;IACH,MAAM,IAAI,MAAM;IAIhB;;;;OAIG;IACH,SAAS,IAAI,MAAM;IAQnB;;;;OAIG;IACH,gBAAgB,IAAI,MAAM;IAQ1B;;;;OAIG;IACH,MAAM,IAAI,OAAO;IAIjB;;;;;OAKG;IACH,MAAM,CAAC,IAAI,EAAE,IAAI,GAAG,OAAO;IAI3B;;;;;OAKG;IACH,QAAQ,CAAC,IAAI,EAAE,IAAI,GAAG,MAAM;IAQ5B;;;;OAIG;IACH,UAAU;IAIV;;;;;OAKG;IACH,MAAM,CAAC,MAAM,CAAC,GAAG,KAAA,EAAE,KAAK,KAAA;IAgBxB;;;;OAIG;IACH,SAAS,IAAI,OAAO;IAKpB;;;;;;OAMG;IAEH,MAAM,CAAC,WAAW,CAAC,IAAI,KAAA,EAAE,IAAI,KAAA,GAAG,cAAc,GAAG,IAAI;CAYxD;AAED,eAAe,cAAc,CAAC"}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import Immutable from "immutable";
|
|
2
|
+
type Articles = Immutable.List<any>;
|
|
3
|
+
declare const SummaryPart_base: Immutable.Record.Class;
|
|
4
|
+
declare class SummaryPart extends SummaryPart_base {
|
|
5
|
+
getLevel(): string;
|
|
6
|
+
getTitle(): string;
|
|
7
|
+
getArticles(): Articles;
|
|
8
|
+
/**
|
|
9
|
+
* Create a new level for a new child article
|
|
10
|
+
*
|
|
11
|
+
* @return {string}
|
|
12
|
+
*/
|
|
13
|
+
createChildLevel(): string;
|
|
14
|
+
/**
|
|
15
|
+
* Create a SummaryPart
|
|
16
|
+
*
|
|
17
|
+
* @param {Object} def
|
|
18
|
+
* @return {SummaryPart}
|
|
19
|
+
*/
|
|
20
|
+
static create(def: any, level: any): SummaryPart;
|
|
21
|
+
}
|
|
22
|
+
export default SummaryPart;
|
|
23
|
+
//# sourceMappingURL=summaryPart.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"summaryPart.d.ts","sourceRoot":"","sources":["../../src/models/summaryPart.ts"],"names":[],"mappings":"AAAA,OAAO,SAAS,MAAM,WAAW,CAAC;AAOlC,KAAK,QAAQ,GAAG,SAAS,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;;AAEpC,cAAM,WAAY,SAAQ,gBAIxB;IACE,QAAQ,IAAI,MAAM;IAIlB,QAAQ,IAAI,MAAM;IAIlB,WAAW,IAAI,QAAQ;IAIvB;;;;OAIG;IACH,gBAAgB,IAAI,MAAM;IAQ1B;;;;;OAKG;IACH,MAAM,CAAC,MAAM,CAAC,GAAG,KAAA,EAAE,KAAK,KAAA,GAAG,WAAW;CAezC;AAED,eAAe,WAAW,CAAC"}
|