umberto 6.0.0 → 6.1.1
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/CHANGELOG.md +16 -0
- package/README.md +3 -0
- package/package.json +1 -1
- package/scripts/filter/before-post-render/set-layout.js +9 -11
- package/src/api-builder/classes/doc-data-factory.js +1 -1
- package/src/data-converter/converters/typedoc/typedocconverter.js +6 -3
- package/src/index.js +108 -146
- package/src/tasks/build-api-docs.js +4 -4
- package/src/tasks/build-documentation.js +9 -3
- package/src/tasks/build-sdk.js +25 -9
- package/src/tasks/copy-assets.js +9 -9
- package/src/tasks/create-sym-links.js +2 -3
- package/themes/umberto/layout/{404.pug → gloria/404.pug} +1 -1
- package/themes/umberto/layout/gloria/_api-docs/_mixin/_type.pug +187 -0
- package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/class.pug +1 -1
- package/themes/umberto/layout/gloria/_api-docs/interface.pug +10 -0
- package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/mixin.pug +1 -1
- package/themes/umberto/layout/gloria/_api-docs/module.pug +10 -0
- package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/namespace.pug +1 -1
- package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/typedef.pug +1 -1
- package/themes/umberto/layout/{_partial → gloria/_partial}/gh-contribute.pug +2 -2
- package/themes/umberto/layout/{_partial → gloria/_partial}/head.pug +2 -2
- package/themes/umberto/layout/{_partial → gloria/_partial}/search-box.pug +1 -1
- package/themes/umberto/layout/{api.pug → gloria/api.pug} +1 -1
- package/themes/umberto/layout/{base.pug → gloria/base.pug} +1 -1
- package/themes/umberto/layout/{sdk.pug → gloria/sdk.pug} +1 -1
- package/themes/umberto/layout/umberto/404.pug +22 -0
- package/themes/umberto/layout/umberto/_api-docs/_mixin/_api-see-source.pug +11 -0
- package/themes/umberto/layout/umberto/_api-docs/_mixin/_api-title.pug +17 -0
- package/themes/umberto/layout/umberto/_api-docs/_mixin/_api-tree-item.pug +30 -0
- package/themes/umberto/layout/umberto/_api-docs/_mixin/_badge.pug +17 -0
- package/themes/umberto/layout/umberto/_api-docs/_mixin/_class-item.pug +29 -0
- package/themes/umberto/layout/umberto/_api-docs/_mixin/_dev-names.pug +9 -0
- package/themes/umberto/layout/umberto/_api-docs/_mixin/_error.pug +23 -0
- package/themes/umberto/layout/umberto/_api-docs/_mixin/_fires-item.pug +7 -0
- package/themes/umberto/layout/umberto/_api-docs/_mixin/_hierarchy-item.pug +14 -0
- package/themes/umberto/layout/umberto/_api-docs/_mixin/_hierarchy-list.pug +7 -0
- package/themes/umberto/layout/umberto/_api-docs/_mixin/_link-or-text.pug +43 -0
- package/themes/umberto/layout/umberto/_api-docs/_mixin/_method.pug +89 -0
- package/themes/umberto/layout/umberto/_api-docs/_mixin/_params.pug +44 -0
- package/themes/umberto/layout/umberto/_api-docs/_mixin/_property.pug +51 -0
- package/themes/umberto/layout/umberto/_api-docs/_mixin/_related.pug +8 -0
- package/themes/umberto/layout/umberto/_api-docs/_mixin/_return.pug +14 -0
- package/themes/umberto/layout/umberto/_api-docs/_mixin/_sidebox-list-item.pug +8 -0
- package/themes/umberto/layout/umberto/_api-docs/_mixin/_sidebox-list.pug +8 -0
- package/themes/umberto/layout/umberto/_api-docs/_mixin/type-parameter.pug +18 -0
- package/themes/umberto/layout/umberto/_api-docs/_partial/api-info-box.pug +30 -0
- package/themes/umberto/layout/umberto/_api-docs/_partial/api-subheader.pug +22 -0
- package/themes/umberto/layout/umberto/_api-docs/_partial/classes.pug +7 -0
- package/themes/umberto/layout/umberto/_api-docs/_partial/config-options.pug +7 -0
- package/themes/umberto/layout/umberto/_api-docs/_partial/constants.pug +7 -0
- package/themes/umberto/layout/umberto/_api-docs/_partial/description.pug +9 -0
- package/themes/umberto/layout/umberto/_api-docs/_partial/events.pug +7 -0
- package/themes/umberto/layout/umberto/_api-docs/_partial/filter.pug +40 -0
- package/themes/umberto/layout/umberto/_api-docs/_partial/functions.pug +7 -0
- package/themes/umberto/layout/umberto/_api-docs/_partial/interfaces.pug +7 -0
- package/themes/umberto/layout/umberto/_api-docs/_partial/loading-spinner.pug +2 -0
- package/themes/umberto/layout/umberto/_api-docs/_partial/methods.pug +19 -0
- package/themes/umberto/layout/umberto/_api-docs/_partial/namespaces.pug +7 -0
- package/themes/umberto/layout/umberto/_api-docs/_partial/navtree.pug +13 -0
- package/themes/umberto/layout/umberto/_api-docs/_partial/properties.pug +19 -0
- package/themes/umberto/layout/umberto/_api-docs/_partial/type-parameters.pug +26 -0
- package/themes/umberto/layout/umberto/_api-docs/_partial/typedefs.pug +7 -0
- package/themes/umberto/layout/umberto/_api-docs/api-base.pug +45 -0
- package/themes/umberto/layout/{_api-docs/interface.pug → umberto/_api-docs/class.pug} +1 -1
- package/themes/umberto/layout/umberto/_api-docs/errors.pug +6 -0
- package/themes/umberto/layout/umberto/_api-docs/interface.pug +10 -0
- package/themes/umberto/layout/{_api-docs/module.pug → umberto/_api-docs/mixin.pug} +1 -1
- package/themes/umberto/layout/umberto/_api-docs/module.pug +10 -0
- package/themes/umberto/layout/umberto/_api-docs/namespace.pug +10 -0
- package/themes/umberto/layout/umberto/_api-docs/typedef.pug +37 -0
- package/themes/umberto/layout/umberto/_mixin/nav-tree-item.pug +13 -0
- package/themes/umberto/layout/umberto/_mixin/nav-tree-level.pug +38 -0
- package/themes/umberto/layout/umberto/_partial/docsearch.pug +21 -0
- package/themes/umberto/layout/umberto/_partial/dropdown.pug +12 -0
- package/themes/umberto/layout/umberto/_partial/feedback-widget.pug +20 -0
- package/themes/umberto/layout/umberto/_partial/footer.pug +6 -0
- package/themes/umberto/layout/umberto/_partial/gh-contribute.pug +8 -0
- package/themes/umberto/layout/umberto/_partial/google-analytics.pug +19 -0
- package/themes/umberto/layout/umberto/_partial/google-tag-manager.pug +18 -0
- package/themes/umberto/layout/umberto/_partial/head.pug +67 -0
- package/themes/umberto/layout/umberto/_partial/header.pug +64 -0
- package/themes/umberto/layout/umberto/_partial/nav-tree.pug +9 -0
- package/themes/umberto/layout/umberto/_partial/report-issue-widget.pug +26 -0
- package/themes/umberto/layout/umberto/_partial/rwd-breadcrumbs.pug +13 -0
- package/themes/umberto/layout/umberto/_partial/search-box.pug +6 -0
- package/themes/umberto/layout/umberto/_partial/vwo.pug +11 -0
- package/themes/umberto/layout/umberto/_sdk/_mixin/_sdk-sample-item.pug +5 -0
- package/themes/umberto/layout/umberto/_sdk/_mixin/_sdk-samples.pug +7 -0
- package/themes/umberto/layout/umberto/_sdk/_mixin/_sdk-tree-item.pug +7 -0
- package/themes/umberto/layout/umberto/_sdk/_mixin/_sdk-tree-level.pug +29 -0
- package/themes/umberto/layout/umberto/_sdk/_partial/navtree.pug +4 -0
- package/themes/umberto/layout/umberto/_sdk/page.pug +23 -0
- package/themes/umberto/layout/umberto/api.pug +27 -0
- package/themes/umberto/layout/umberto/base.pug +42 -0
- package/themes/umberto/layout/umberto/index.pug +17 -0
- package/themes/umberto/layout/umberto/page.pug +28 -0
- package/themes/umberto/layout/umberto/sdk.pug +29 -0
- package/themes/umberto/source/umberto/assets/_img/info-circle.svg +4 -0
- package/themes/umberto/source/umberto/assets/_img/triangle-right.svg +1 -0
- package/themes/umberto/src/umberto/css/_api-content.scss +32 -0
- package/themes/umberto/src/umberto/css/_api-info-box.scss +86 -0
- package/themes/umberto/src/umberto/css/_api-props-filter.scss +106 -0
- package/themes/umberto/src/umberto/css/_api-see-source.scss +35 -0
- package/themes/umberto/src/umberto/css/_api-subheader.scss +167 -0
- package/themes/umberto/src/umberto/css/_api-tree.scss +121 -0
- package/themes/umberto/src/umberto/css/_badge.scss +74 -0
- package/themes/umberto/src/umberto/css/_code-switcher.scss +61 -0
- package/themes/umberto/src/umberto/css/_collapsinglist.scss +262 -0
- package/themes/umberto/src/umberto/css/_content.scss +236 -0
- package/themes/umberto/src/umberto/css/_docsearch.scss +109 -0
- package/themes/umberto/src/umberto/css/_dropdown.scss +63 -0
- package/themes/umberto/src/umberto/css/_editor-icon.scss +26 -0
- package/themes/umberto/src/umberto/css/_feedback-widget.scss +11 -0
- package/themes/umberto/src/umberto/css/_font-external.scss +8 -0
- package/themes/umberto/src/umberto/css/_footer.scss +40 -0
- package/themes/umberto/src/umberto/css/_formatted.scss +285 -0
- package/themes/umberto/src/umberto/css/_guide-content.scss +37 -0
- package/themes/umberto/src/umberto/css/_guide-sdk-tree.scss +14 -0
- package/themes/umberto/src/umberto/css/_loading-spinner.scss +33 -0
- package/themes/umberto/src/umberto/css/_main.scss +59 -0
- package/themes/umberto/src/umberto/css/_navigation.scss +35 -0
- package/themes/umberto/src/umberto/css/_notice.scss +116 -0
- package/themes/umberto/src/umberto/css/_print.scss +20 -0
- package/themes/umberto/src/umberto/css/_prism.scss +223 -0
- package/themes/umberto/src/umberto/css/_rwd-breadcrumbs.scss +28 -0
- package/themes/umberto/src/umberto/css/_rwd-menu.scss +89 -0
- package/themes/umberto/src/umberto/css/_secondary-navigation.scss +152 -0
- package/themes/umberto/src/umberto/css/_theme-dark.scss +175 -0
- package/themes/umberto/src/umberto/css/_toggler.scss +46 -0
- package/themes/umberto/src/umberto/css/_top.scss +350 -0
- package/themes/umberto/src/umberto/css/_tree.scss +218 -0
- package/themes/umberto/src/umberto/css/_warning-banner.scss +46 -0
- package/themes/umberto/src/umberto/css/components/_lightbox.scss +12 -0
- package/themes/umberto/src/umberto/css/helpers/_color.scss +49 -0
- package/themes/umberto/src/umberto/css/helpers/_font.scss +60 -0
- package/themes/umberto/src/umberto/css/helpers/_globals.scss +129 -0
- package/themes/umberto/src/umberto/css/helpers/_reset.scss +52 -0
- package/themes/umberto/src/umberto/css/helpers/_spacing.scss +21 -0
- package/themes/umberto/src/umberto/css/pages/_sdk.scss +111 -0
- package/themes/umberto/src/umberto/css/styles.scss +117 -0
- package/themes/umberto/src/umberto/js/_anchors.js +57 -0
- package/themes/umberto/src/umberto/js/_apisearch.js +126 -0
- package/themes/umberto/src/umberto/js/_apitree.js +67 -0
- package/themes/umberto/src/umberto/js/_attachpermalinklistener.js +50 -0
- package/themes/umberto/src/umberto/js/_codeswitcherbuttons.js +146 -0
- package/themes/umberto/src/umberto/js/_collapsables.js +135 -0
- package/themes/umberto/src/umberto/js/_copymobileapinavigation.js +26 -0
- package/themes/umberto/src/umberto/js/_devnames.js +37 -0
- package/themes/umberto/src/umberto/js/_dropdowns.js +55 -0
- package/themes/umberto/src/umberto/js/_filtering.js +139 -0
- package/themes/umberto/src/umberto/js/_imageModal.js +16 -0
- package/themes/umberto/src/umberto/js/_pagenavigation.js +93 -0
- package/themes/umberto/src/umberto/js/_prism.js +104 -0
- package/themes/umberto/src/umberto/js/_rwdmenu.js +15 -0
- package/themes/umberto/src/umberto/js/_samplecode.js +23 -0
- package/themes/umberto/src/umberto/js/_sidenavigation.js +59 -0
- package/themes/umberto/src/umberto/js/_toc.js +93 -0
- package/themes/umberto/src/umberto/js/_tooltips.js +39 -0
- package/themes/umberto/src/umberto/js/_warningbanner.js +18 -0
- package/themes/umberto/src/umberto/js/app.js +70 -0
- package/themes/umberto/src/umberto/js/vendor/prism.js +45 -0
- /package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/_mixin/_api-see-source.pug +0 -0
- /package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/_mixin/_api-title.pug +0 -0
- /package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/_mixin/_api-tree-item.pug +0 -0
- /package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/_mixin/_badge.pug +0 -0
- /package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/_mixin/_class-item.pug +0 -0
- /package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/_mixin/_dev-names.pug +0 -0
- /package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/_mixin/_error.pug +0 -0
- /package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/_mixin/_fires-item.pug +0 -0
- /package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/_mixin/_hierarchy-item.pug +0 -0
- /package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/_mixin/_hierarchy-list.pug +0 -0
- /package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/_mixin/_link-or-text.pug +0 -0
- /package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/_mixin/_method.pug +0 -0
- /package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/_mixin/_params.pug +0 -0
- /package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/_mixin/_property.pug +0 -0
- /package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/_mixin/_related.pug +0 -0
- /package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/_mixin/_return.pug +0 -0
- /package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/_mixin/_sidebox-list-item.pug +0 -0
- /package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/_mixin/_sidebox-list.pug +0 -0
- /package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/_mixin/type-parameter.pug +0 -0
- /package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/_partial/api-info-box.pug +0 -0
- /package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/_partial/api-subheader.pug +0 -0
- /package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/_partial/classes.pug +0 -0
- /package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/_partial/config-options.pug +0 -0
- /package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/_partial/constants.pug +0 -0
- /package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/_partial/description.pug +0 -0
- /package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/_partial/events.pug +0 -0
- /package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/_partial/filter.pug +0 -0
- /package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/_partial/functions.pug +0 -0
- /package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/_partial/interfaces.pug +0 -0
- /package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/_partial/loading-spinner.pug +0 -0
- /package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/_partial/methods.pug +0 -0
- /package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/_partial/namespaces.pug +0 -0
- /package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/_partial/navtree.pug +0 -0
- /package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/_partial/properties.pug +0 -0
- /package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/_partial/type-parameters.pug +0 -0
- /package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/_partial/typedefs.pug +0 -0
- /package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/api-base.pug +0 -0
- /package/themes/umberto/layout/{_api-docs → gloria/_api-docs}/errors.pug +0 -0
- /package/themes/umberto/layout/{_mixin → gloria/_mixin}/nav-tree-item.pug +0 -0
- /package/themes/umberto/layout/{_mixin → gloria/_mixin}/nav-tree-level.pug +0 -0
- /package/themes/umberto/layout/{_partial → gloria/_partial}/docsearch.pug +0 -0
- /package/themes/umberto/layout/{_partial → gloria/_partial}/dropdown.pug +0 -0
- /package/themes/umberto/layout/{_partial → gloria/_partial}/feedback-widget.pug +0 -0
- /package/themes/umberto/layout/{_partial → gloria/_partial}/footer.pug +0 -0
- /package/themes/umberto/layout/{_partial → gloria/_partial}/google-analytics.pug +0 -0
- /package/themes/umberto/layout/{_partial → gloria/_partial}/google-tag-manager.pug +0 -0
- /package/themes/umberto/layout/{_partial → gloria/_partial}/header.pug +0 -0
- /package/themes/umberto/layout/{_partial → gloria/_partial}/nav-tree.pug +0 -0
- /package/themes/umberto/layout/{_partial → gloria/_partial}/report-issue-widget.pug +0 -0
- /package/themes/umberto/layout/{_partial → gloria/_partial}/rwd-breadcrumbs.pug +0 -0
- /package/themes/umberto/layout/{_partial → gloria/_partial}/vwo.pug +0 -0
- /package/themes/umberto/layout/{_sdk → gloria/_sdk}/_mixin/_sdk-sample-item.pug +0 -0
- /package/themes/umberto/layout/{_sdk → gloria/_sdk}/_mixin/_sdk-samples.pug +0 -0
- /package/themes/umberto/layout/{_sdk → gloria/_sdk}/_mixin/_sdk-tree-item.pug +0 -0
- /package/themes/umberto/layout/{_sdk → gloria/_sdk}/_mixin/_sdk-tree-level.pug +0 -0
- /package/themes/umberto/layout/{_sdk → gloria/_sdk}/_partial/navtree.pug +0 -0
- /package/themes/umberto/layout/{_sdk → gloria/_sdk}/page.pug +0 -0
- /package/themes/umberto/layout/{index.pug → gloria/index.pug} +0 -0
- /package/themes/umberto/layout/{page.pug → gloria/page.pug} +0 -0
- /package/themes/umberto/layout/{_api-docs → umberto/_api-docs}/_mixin/_type.pug +0 -0
- /package/themes/{nova/source → umberto/source/gloria}/assets/_img/arrows.svg +0 -0
- /package/themes/{nova/source → umberto/source/gloria}/assets/_img/book.svg +0 -0
- /package/themes/{nova/source → umberto/source/gloria}/assets/_img/box-brown.svg +0 -0
- /package/themes/{nova/source → umberto/source/gloria}/assets/_img/box-orange.svg +0 -0
- /package/themes/{nova/source → umberto/source/gloria}/assets/_img/box-red.svg +0 -0
- /package/themes/{nova/source → umberto/source/gloria}/assets/_img/bulb.svg +0 -0
- /package/themes/{nova/source → umberto/source/gloria}/assets/_img/clipboard.svg +0 -0
- /package/themes/{nova/source → umberto/source/gloria}/assets/_img/cog.svg +0 -0
- /package/themes/{nova/source → umberto/source/gloria}/assets/_img/data.svg +0 -0
- /package/themes/{nova/source → umberto/source/gloria}/assets/_img/documentation.svg +0 -0
- /package/themes/{nova/source → umberto/source/gloria}/assets/_img/download.svg +0 -0
- /package/themes/{nova/source → umberto/source/gloria}/assets/_img/edit.svg +0 -0
- /package/themes/{nova/source → umberto/source/gloria}/assets/_img/exclamation-circle.svg +0 -0
- /package/themes/{nova/source → umberto/source/gloria}/assets/_img/eye.svg +0 -0
- /package/themes/{nova/source → umberto/source/gloria}/assets/_img/filter.svg +0 -0
- /package/themes/{nova/source → umberto/source/gloria}/assets/_img/filtering.svg +0 -0
- /package/themes/{nova/source → umberto/source/gloria}/assets/_img/folder.svg +0 -0
- /package/themes/{nova/source → umberto/source/gloria}/assets/_img/github.svg +0 -0
- /package/themes/{nova/source → umberto/source/gloria}/assets/_img/header-info-configs.svg +0 -0
- /package/themes/{nova/source → umberto/source/gloria}/assets/_img/header-info-events.svg +0 -0
- /package/themes/{nova/source → umberto/source/gloria}/assets/_img/header-info-methods.svg +0 -0
- /package/themes/{nova/source → umberto/source/gloria}/assets/_img/header-info-properties.svg +0 -0
- /package/themes/{nova/source → umberto/source/gloria}/assets/_img/heart.svg +0 -0
- /package/themes/umberto/source/{assets → gloria/assets}/_img/info-circle.svg +0 -0
- /package/themes/{nova/source → umberto/source/gloria}/assets/_img/info.svg +0 -0
- /package/themes/{nova/source → umberto/source/gloria}/assets/_img/list-nest.svg +0 -0
- /package/themes/{nova/source → umberto/source/gloria}/assets/_img/loupe.svg +0 -0
- /package/themes/{nova/source → umberto/source/gloria}/assets/_img/menu.svg +0 -0
- /package/themes/{nova/source → umberto/source/gloria}/assets/_img/plug.svg +0 -0
- /package/themes/{nova/source → umberto/source/gloria}/assets/_img/star-in-circle.svg +0 -0
- /package/themes/{nova/source → umberto/source/gloria}/assets/_img/tick.svg +0 -0
- /package/themes/{nova/source → umberto/source/gloria}/assets/_img/triangle-down.svg +0 -0
- /package/themes/umberto/source/{assets → gloria/assets}/_img/triangle-right.svg +0 -0
- /package/themes/umberto/source/{assets → umberto/assets}/_img/arrows.svg +0 -0
- /package/themes/umberto/source/{assets → umberto/assets}/_img/book.svg +0 -0
- /package/themes/umberto/source/{assets → umberto/assets}/_img/box-brown.svg +0 -0
- /package/themes/umberto/source/{assets → umberto/assets}/_img/box-orange.svg +0 -0
- /package/themes/umberto/source/{assets → umberto/assets}/_img/box-red.svg +0 -0
- /package/themes/umberto/source/{assets → umberto/assets}/_img/bulb.svg +0 -0
- /package/themes/umberto/source/{assets → umberto/assets}/_img/clipboard.svg +0 -0
- /package/themes/umberto/source/{assets → umberto/assets}/_img/cog.svg +0 -0
- /package/themes/umberto/source/{assets → umberto/assets}/_img/data.svg +0 -0
- /package/themes/umberto/source/{assets → umberto/assets}/_img/documentation.svg +0 -0
- /package/themes/umberto/source/{assets → umberto/assets}/_img/download.svg +0 -0
- /package/themes/umberto/source/{assets → umberto/assets}/_img/edit.svg +0 -0
- /package/themes/umberto/source/{assets → umberto/assets}/_img/exclamation-circle.svg +0 -0
- /package/themes/umberto/source/{assets → umberto/assets}/_img/eye.svg +0 -0
- /package/themes/umberto/source/{assets → umberto/assets}/_img/filter.svg +0 -0
- /package/themes/umberto/source/{assets → umberto/assets}/_img/filtering.svg +0 -0
- /package/themes/umberto/source/{assets → umberto/assets}/_img/folder.svg +0 -0
- /package/themes/umberto/source/{assets → umberto/assets}/_img/github.svg +0 -0
- /package/themes/umberto/source/{assets → umberto/assets}/_img/header-info-configs.svg +0 -0
- /package/themes/umberto/source/{assets → umberto/assets}/_img/header-info-events.svg +0 -0
- /package/themes/umberto/source/{assets → umberto/assets}/_img/header-info-methods.svg +0 -0
- /package/themes/umberto/source/{assets → umberto/assets}/_img/header-info-properties.svg +0 -0
- /package/themes/umberto/source/{assets → umberto/assets}/_img/heart.svg +0 -0
- /package/themes/umberto/source/{assets → umberto/assets}/_img/info.svg +0 -0
- /package/themes/umberto/source/{assets → umberto/assets}/_img/list-nest.svg +0 -0
- /package/themes/umberto/source/{assets → umberto/assets}/_img/loupe.svg +0 -0
- /package/themes/umberto/source/{assets → umberto/assets}/_img/menu.svg +0 -0
- /package/themes/umberto/source/{assets → umberto/assets}/_img/plug.svg +0 -0
- /package/themes/umberto/source/{assets → umberto/assets}/_img/star-in-circle.svg +0 -0
- /package/themes/umberto/source/{assets → umberto/assets}/_img/tick.svg +0 -0
- /package/themes/umberto/source/{assets → umberto/assets}/_img/triangle-down.svg +0 -0
- /package/themes/umberto/src/{css → gloria/css}/_api-content.scss +0 -0
- /package/themes/umberto/src/{css → gloria/css}/_api-info-box.scss +0 -0
- /package/themes/umberto/src/{css → gloria/css}/_api-props-filter.scss +0 -0
- /package/themes/umberto/src/{css → gloria/css}/_api-see-source.scss +0 -0
- /package/themes/umberto/src/{css → gloria/css}/_api-subheader.scss +0 -0
- /package/themes/umberto/src/{css → gloria/css}/_api-tree.scss +0 -0
- /package/themes/umberto/src/{css → gloria/css}/_badge.scss +0 -0
- /package/themes/umberto/src/{css → gloria/css}/_code-switcher.scss +0 -0
- /package/themes/umberto/src/{css → gloria/css}/_collapsinglist.scss +0 -0
- /package/themes/umberto/src/{css → gloria/css}/_content.scss +0 -0
- /package/themes/umberto/src/{css → gloria/css}/_docsearch.scss +0 -0
- /package/themes/umberto/src/{css → gloria/css}/_dropdown.scss +0 -0
- /package/themes/umberto/src/{css → gloria/css}/_editor-icon.scss +0 -0
- /package/themes/umberto/src/{css → gloria/css}/_feedback-widget.scss +0 -0
- /package/themes/umberto/src/{css → gloria/css}/_font-external.scss +0 -0
- /package/themes/umberto/src/{css → gloria/css}/_footer.scss +0 -0
- /package/themes/umberto/src/{css → gloria/css}/_formatted.scss +0 -0
- /package/themes/umberto/src/{css → gloria/css}/_guide-content.scss +0 -0
- /package/themes/umberto/src/{css → gloria/css}/_guide-sdk-tree.scss +0 -0
- /package/themes/umberto/src/{css → gloria/css}/_loading-spinner.scss +0 -0
- /package/themes/umberto/src/{css → gloria/css}/_main.scss +0 -0
- /package/themes/umberto/src/{css → gloria/css}/_navigation.scss +0 -0
- /package/themes/umberto/src/{css → gloria/css}/_notice.scss +0 -0
- /package/themes/umberto/src/{css → gloria/css}/_print.scss +0 -0
- /package/themes/umberto/src/{css → gloria/css}/_prism.scss +0 -0
- /package/themes/umberto/src/{css → gloria/css}/_rwd-breadcrumbs.scss +0 -0
- /package/themes/umberto/src/{css → gloria/css}/_rwd-menu.scss +0 -0
- /package/themes/umberto/src/{css → gloria/css}/_secondary-navigation.scss +0 -0
- /package/themes/umberto/src/{css → gloria/css}/_theme-dark.scss +0 -0
- /package/themes/umberto/src/{css → gloria/css}/_toggler.scss +0 -0
- /package/themes/umberto/src/{css → gloria/css}/_top.scss +0 -0
- /package/themes/umberto/src/{css → gloria/css}/_tree.scss +0 -0
- /package/themes/umberto/src/{css → gloria/css}/_warning-banner.scss +0 -0
- /package/themes/umberto/src/{css → gloria/css}/components/_lightbox.scss +0 -0
- /package/themes/umberto/src/{css → gloria/css}/helpers/_color.scss +0 -0
- /package/themes/umberto/src/{css → gloria/css}/helpers/_font.scss +0 -0
- /package/themes/umberto/src/{css → gloria/css}/helpers/_globals.scss +0 -0
- /package/themes/umberto/src/{css → gloria/css}/helpers/_reset.scss +0 -0
- /package/themes/umberto/src/{css → gloria/css}/helpers/_spacing.scss +0 -0
- /package/themes/umberto/src/{css → gloria/css}/pages/_sdk.scss +0 -0
- /package/themes/umberto/src/{css → gloria/css}/styles.scss +0 -0
- /package/themes/umberto/src/{js → gloria/js}/_anchors.js +0 -0
- /package/themes/umberto/src/{js → gloria/js}/_apisearch.js +0 -0
- /package/themes/umberto/src/{js → gloria/js}/_apitree.js +0 -0
- /package/themes/umberto/src/{js → gloria/js}/_attachpermalinklistener.js +0 -0
- /package/themes/umberto/src/{js → gloria/js}/_codeswitcherbuttons.js +0 -0
- /package/themes/umberto/src/{js → gloria/js}/_collapsables.js +0 -0
- /package/themes/umberto/src/{js → gloria/js}/_copymobileapinavigation.js +0 -0
- /package/themes/umberto/src/{js → gloria/js}/_devnames.js +0 -0
- /package/themes/umberto/src/{js → gloria/js}/_dropdowns.js +0 -0
- /package/themes/umberto/src/{js → gloria/js}/_filtering.js +0 -0
- /package/themes/umberto/src/{js → gloria/js}/_imageModal.js +0 -0
- /package/themes/umberto/src/{js → gloria/js}/_pagenavigation.js +0 -0
- /package/themes/umberto/src/{js → gloria/js}/_prism.js +0 -0
- /package/themes/umberto/src/{js → gloria/js}/_rwdmenu.js +0 -0
- /package/themes/umberto/src/{js → gloria/js}/_samplecode.js +0 -0
- /package/themes/umberto/src/{js → gloria/js}/_sidenavigation.js +0 -0
- /package/themes/umberto/src/{js → gloria/js}/_toc.js +0 -0
- /package/themes/umberto/src/{js → gloria/js}/_tooltips.js +0 -0
- /package/themes/umberto/src/{js → gloria/js}/_warningbanner.js +0 -0
- /package/themes/umberto/src/{js → gloria/js}/app.js +0 -0
- /package/themes/umberto/src/{js → gloria/js}/vendor/prism.js +0 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,6 +1,22 @@
|
|
|
1
1
|
Changelog
|
|
2
2
|
=========
|
|
3
3
|
|
|
4
|
+
## [6.1.1](https://github.com/cksource/umberto/compare/v6.1.0...v6.1.1) (2025-04-17)
|
|
5
|
+
|
|
6
|
+
### Bug fixes
|
|
7
|
+
|
|
8
|
+
* Displaying arguments names in callbacks before the types in API docs. ([commit](https://github.com/cksource/umberto/commit/2974f7f34b4549907d233b35bd3b0756d0d1177e))
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
## [6.1.0](https://github.com/cksource/umberto/compare/v6.0.0...v6.1.0) (2025-04-15)
|
|
12
|
+
|
|
13
|
+
### Features
|
|
14
|
+
|
|
15
|
+
* Added the `skipSitemap` (for ignoring generating the sitemap) and `skipThemes` (for skipping preparing assets) flags. ([commit](https://github.com/cksource/umberto/commit/8ec19222e970d2f68ace87a108ead619827124f0))
|
|
16
|
+
* Ability to define a theme per project. Closes [#1242](https://github.com/cksource/umberto/issues/1242). ([commit](https://github.com/cksource/umberto/commit/3bec129a57e224f574674543d9224bda55d1e081))
|
|
17
|
+
* Use the provided `mainConfig` if available when creating symlinks. ([commit](https://github.com/cksource/umberto/commit/5b61d25ff96cbc0cdce7dc5a218e1ab6ca544189))
|
|
18
|
+
|
|
19
|
+
|
|
4
20
|
## [6.0.0](https://github.com/cksource/umberto/compare/v5.0.2...v6.0.0) (2025-04-01)
|
|
5
21
|
|
|
6
22
|
### BREAKING CHANGES
|
package/README.md
CHANGED
|
@@ -163,6 +163,8 @@ Sample documentation setup for the example above:
|
|
|
163
163
|
`require ( 'umberto' ).buildSingleProject( options )`
|
|
164
164
|
|
|
165
165
|
* `skipApi` - skip building API docs,
|
|
166
|
+
* `skipSitemap` - skip building sitemap file,
|
|
167
|
+
* `skipThemes` - skip building themes,
|
|
166
168
|
* `skipValidation` - skip links validation,
|
|
167
169
|
* `skipLivesSnippets` - skip building live code samples,
|
|
168
170
|
* `snippetOptions` - options object passed to snippetAdapter building live code samples,
|
|
@@ -254,6 +256,7 @@ Every guide should have a front-matter at the top, which looks like this:
|
|
|
254
256
|
|
|
255
257
|
```
|
|
256
258
|
---
|
|
259
|
+
layout: page [optional]
|
|
257
260
|
category: builds-guides
|
|
258
261
|
title: Overview [optional]
|
|
259
262
|
slug: overview [optional]
|
package/package.json
CHANGED
|
@@ -10,19 +10,17 @@
|
|
|
10
10
|
* page.layout indicates the template which should be used to render the page.
|
|
11
11
|
*/
|
|
12
12
|
hexo.extend.filter.register( 'before_post_render', page => {
|
|
13
|
-
|
|
13
|
+
const theme = page.projectName === 'ckeditor4' ? 'umberto' : 'gloria';
|
|
14
|
+
|
|
14
15
|
if ( page.category === 'api-reference' ) {
|
|
15
|
-
page.layout = 'api';
|
|
16
|
+
page.layout = theme + '/api';
|
|
16
17
|
page.isApi = true;
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
if ( page.category === 'sdk' ) {
|
|
20
|
-
page.layout = 'sdk';
|
|
18
|
+
} else if ( page.category === 'sdk' ) {
|
|
19
|
+
page.layout = theme + '/sdk';
|
|
21
20
|
page.isSdk = true;
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
page.layout = 'index';
|
|
21
|
+
} else if ( page.path === 'index.html' ) {
|
|
22
|
+
page.layout = theme + '/index';
|
|
23
|
+
} else {
|
|
24
|
+
page.layout = theme + '/' + page.layout;
|
|
27
25
|
}
|
|
28
26
|
} );
|
|
@@ -784,7 +784,7 @@ function sorter( a, b ) {
|
|
|
784
784
|
/**
|
|
785
785
|
* This is a JavaScript version of the `renderInlineFunction()` pug mixin.
|
|
786
786
|
*
|
|
787
|
-
* See: themes/umberto
|
|
787
|
+
* See: `themes/umberto/<theme name>/layout/_api-docs/_mixin/_type.pug`.
|
|
788
788
|
*
|
|
789
789
|
* The goal is to render an inline object describing a callable type.
|
|
790
790
|
*
|
|
@@ -462,7 +462,7 @@ class TypeConverter {
|
|
|
462
462
|
* The returned object contains a `value` property which must be an array.
|
|
463
463
|
* Thanks to that, it can be pass through the `type()` mixin.
|
|
464
464
|
*
|
|
465
|
-
* See: `themes/umberto
|
|
465
|
+
* See: `themes/umberto/<theme name>/layout/_api-docs/_mixin/_type.pug`.
|
|
466
466
|
*
|
|
467
467
|
* @param {Array.<TypedocReflectionTypeParameter>|null} parameters
|
|
468
468
|
* @returns {Array.<Object>|null}
|
|
@@ -641,7 +641,7 @@ class TypeConverter {
|
|
|
641
641
|
// See the `TypedocTypeDetails` type in the `typedoc.ts` file for checking the supported types.
|
|
642
642
|
//
|
|
643
643
|
// Results of this function is processed by Pug.
|
|
644
|
-
// See: `themes/umberto
|
|
644
|
+
// See: `themes/umberto/<theme name>/layout/_api-docs/_mixin/_type.pug`.
|
|
645
645
|
//
|
|
646
646
|
// When introducing support for more TypeScript constructions,
|
|
647
647
|
// consider introducing a new structure that contains an opening symbol,
|
|
@@ -694,7 +694,10 @@ class TypeConverter {
|
|
|
694
694
|
const isClass = signature.kindString === 'Constructor signature';
|
|
695
695
|
|
|
696
696
|
const params = ( signature.parameters || [] )
|
|
697
|
-
.map( singleType =>
|
|
697
|
+
.map( singleType => ( {
|
|
698
|
+
name: singleType.name,
|
|
699
|
+
type: this.convert( singleType.type )
|
|
700
|
+
} ) )
|
|
698
701
|
.filter( Boolean );
|
|
699
702
|
|
|
700
703
|
const returns = signature.type ? this.convert( signature.type ) : null;
|
package/src/index.js
CHANGED
|
@@ -6,178 +6,140 @@
|
|
|
6
6
|
'use strict';
|
|
7
7
|
|
|
8
8
|
const path = require( 'path' );
|
|
9
|
-
const fs = require( 'fs' );
|
|
10
9
|
const chalk = require( 'chalk' );
|
|
11
10
|
const compileSass = require( './tasks/compile-sass' );
|
|
12
11
|
const runWebpack = require( './tasks/run-webpack' );
|
|
13
12
|
const copyAssets = require( './tasks/copy-assets' );
|
|
13
|
+
const getMainConfig = require( './tasks/get-main-config' );
|
|
14
14
|
const createSymLinks = require( './tasks/create-sym-links' );
|
|
15
15
|
const buildDocumentation = require( './tasks/build-documentation' );
|
|
16
16
|
const getProjectConfig = require( './tasks/get-project-config' );
|
|
17
|
-
const cacheFiles = require( './tasks/cache-files' );
|
|
18
17
|
const watcher = require( './tasks/watcher' );
|
|
19
18
|
const validateHtml = require( './tasks/validate-html-w3c' );
|
|
20
|
-
const
|
|
21
|
-
const umbertoDir = path.join( __dirname, '..' );
|
|
22
|
-
const themeDir = path.join( __dirname, '../themes/umberto' );
|
|
23
|
-
// Theme's styles and scripts path.
|
|
24
|
-
const sourceDir = path.join( themeDir, 'src' );
|
|
25
|
-
const outputDir = path.join( process.cwd(), 'build/docs' );
|
|
26
|
-
const cacheDir = path.join( __dirname, '../temp/cache' );
|
|
27
|
-
const stylesSource = path.join( sourceDir, 'css', 'styles.scss' );
|
|
28
|
-
const stylesDestination = path.join( outputDir, 'assets', umbertoVersion, 'css', 'styles.css' );
|
|
19
|
+
const { version } = require( '../package.json' );
|
|
29
20
|
|
|
30
21
|
module.exports = {
|
|
31
22
|
/**
|
|
32
23
|
* Builds documentation for a single project.
|
|
33
24
|
* Intended to use within project's task runner or along other build scripts.
|
|
34
25
|
*
|
|
35
|
-
* @param {
|
|
36
|
-
* @param {Boolean} [options.skipApi=false] Skips rendering API docs.
|
|
37
|
-
* @param {Boolean} [options.skipValidation=false] Skips validating links.
|
|
38
|
-
* @param {Boolean} [options.skipLiveSnippets=false] Skips building live code snippets. Live code snippets is an
|
|
39
|
-
* extra feature and is usually not used.
|
|
40
|
-
* @param {Object} [options.snippetOptions={}] Additional options passed to snippetAdapter.
|
|
41
|
-
* @param {Boolean} [options.dev=false] Skip js minification, don't clear build directory when rebuilding docs,
|
|
42
|
-
* reuse unchanged files.
|
|
43
|
-
* @param {Boolean} [options.verbose=false] Adds more information to console during documentation building.
|
|
44
|
-
* @param {Boolean} [options.createSymLinks=true] Add symbolic links with 'latest' to output folder.
|
|
45
|
-
* @param {Boolean} [options.watch=false] Run Umberto with watch mode, which track changes in dm files and rebuild docs with it.
|
|
46
|
-
* @param {Boolean} [options.validateW3C=false] Use vnu java validator to check every single output page for html syntax errors.
|
|
26
|
+
* @param {Options} [options={}]
|
|
47
27
|
* @returns {Promise}
|
|
48
28
|
*/
|
|
49
|
-
buildSingleProject( options ) {
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
.
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
vwo: pConfig.vwo
|
|
67
|
-
}
|
|
68
|
-
}
|
|
69
|
-
) );
|
|
70
|
-
} )
|
|
71
|
-
.then( hexoManager => postBuild( options, hexoManager ) )
|
|
72
|
-
.then( hexoManager => {
|
|
73
|
-
const time = process.hrtime( timer );
|
|
74
|
-
|
|
75
|
-
console.log( `Building documentation complete in ${ Math.floor( time[ 0 ] / 60 ) }m ${ time[ 0 ] % 60 }.${ time[ 1 ] }s.` );
|
|
76
|
-
|
|
77
|
-
return hexoManager;
|
|
78
|
-
} )
|
|
79
|
-
.then( hexoManager => {
|
|
80
|
-
if ( options.watch ) {
|
|
81
|
-
return watcher( hexoManager );
|
|
82
|
-
} else {
|
|
83
|
-
return Promise.resolve();
|
|
84
|
-
}
|
|
85
|
-
} )
|
|
86
|
-
.catch( err => {
|
|
87
|
-
console.error( `Building documentation failed: ${ err.stack }` );
|
|
88
|
-
process.exitCode = 1;
|
|
89
|
-
|
|
90
|
-
throw err;
|
|
91
|
-
} );
|
|
29
|
+
async buildSingleProject( options = {} ) {
|
|
30
|
+
try {
|
|
31
|
+
const config = await getProjectConfig( process.cwd(), options );
|
|
32
|
+
|
|
33
|
+
options.mainConfig = {
|
|
34
|
+
...config,
|
|
35
|
+
projects: [ '.' ],
|
|
36
|
+
isSingleProject: true
|
|
37
|
+
};
|
|
38
|
+
|
|
39
|
+
await buildAndWatch( options );
|
|
40
|
+
} catch ( err ) {
|
|
41
|
+
console.error( chalk.redBright( `Building documentation failed: ${ err.stack }` ) );
|
|
42
|
+
process.exitCode = 1;
|
|
43
|
+
|
|
44
|
+
throw err;
|
|
45
|
+
}
|
|
92
46
|
},
|
|
93
47
|
|
|
94
48
|
/**
|
|
95
49
|
* Builds documentation for multiple projects at once.
|
|
96
50
|
*
|
|
97
|
-
* @param {
|
|
98
|
-
* @param {Boolean} [options.skipApi=false] Skips rendering API docs.
|
|
99
|
-
* @param {Boolean} [options.skipValidation=false] Skips validating links.
|
|
100
|
-
* @param {Boolean} [options.skipLiveSnippets=false] Skips building live code snippets. Live code snippets is an
|
|
101
|
-
* extra feature and is usually not used.
|
|
102
|
-
* @param {Object} [options.snippetOptions={}] Additional options passed to snippetAdapter.
|
|
103
|
-
* @param {Boolean} [options.dev=false] Skip js minification, don't clear build directory when rebuilding docs,
|
|
104
|
-
* reuse unchanged files.
|
|
105
|
-
* @param {Boolean} [options.verbose=false] Adds more information to console during documentation building.
|
|
106
|
-
* @param {Boolean} [options.createSymLinks=true] Add symbolic links with 'latest' to output folder.
|
|
107
|
-
* @param {Boolean} [options.watch=false] Run Umberto with watch mode, which track changes in dm files and rebuild docs with it.
|
|
108
|
-
* @param {Boolean} [options.validateW3C=false] Use vnu java validator to check every single output page for html syntax errors.
|
|
51
|
+
* @param {Options} [options={}]
|
|
109
52
|
* @returns {Promise}
|
|
110
53
|
*/
|
|
111
|
-
buildMultiProjects( options ) {
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
.
|
|
116
|
-
.
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
`Building documentation complete in ${ Math.floor( time[ 0 ] / 60 ) }m ${ time[ 0 ] % 60 }.${ time[ 1 ] }s.`
|
|
121
|
-
) );
|
|
122
|
-
|
|
123
|
-
return hexoManager;
|
|
124
|
-
} )
|
|
125
|
-
.then( hexoManager => {
|
|
126
|
-
if ( options.watch ) {
|
|
127
|
-
return watcher( hexoManager );
|
|
128
|
-
} else {
|
|
129
|
-
return Promise.resolve();
|
|
130
|
-
}
|
|
131
|
-
} )
|
|
132
|
-
.catch( err => {
|
|
133
|
-
console.error( `Building documentation failed: ${ err.stack }` );
|
|
134
|
-
process.exitCode = 1;
|
|
135
|
-
|
|
136
|
-
throw err;
|
|
137
|
-
} );
|
|
54
|
+
async buildMultiProjects( options = {} ) {
|
|
55
|
+
try {
|
|
56
|
+
await buildAndWatch( options );
|
|
57
|
+
} catch ( err ) {
|
|
58
|
+
console.error( chalk.redBright( `Building documentation failed: ${ err.stack }` ) );
|
|
59
|
+
process.exitCode = 1;
|
|
60
|
+
|
|
61
|
+
throw err;
|
|
62
|
+
}
|
|
138
63
|
}
|
|
139
64
|
};
|
|
140
65
|
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
66
|
+
/**
|
|
67
|
+
* @param {Options} options
|
|
68
|
+
* @returns {Promise}
|
|
69
|
+
*/
|
|
70
|
+
async function buildAndWatch( options ) {
|
|
71
|
+
const timer = process.hrtime();
|
|
72
|
+
const outputDir = path.join( process.cwd(), 'build', 'docs' );
|
|
73
|
+
|
|
74
|
+
const hexoManager = await buildDocumentation( options );
|
|
75
|
+
|
|
76
|
+
if ( !options.skipThemes ) {
|
|
77
|
+
await buildThemes( outputDir, options );
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
if ( options.validateW3C ) {
|
|
81
|
+
await validateHtml( outputDir, options );
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
if ( options.createSymLinks !== false ) {
|
|
85
|
+
const rootPath = process.cwd();
|
|
86
|
+
|
|
87
|
+
await createSymLinks( {
|
|
88
|
+
rootPath,
|
|
89
|
+
mainConfig: options.mainConfig || getMainConfig( rootPath ),
|
|
90
|
+
isSingleProject: options.mainConfig ? options.mainConfig.isSingleProject : false
|
|
91
|
+
} );
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
const [ time ] = process.hrtime( timer );
|
|
95
|
+
|
|
96
|
+
console.log( chalk.greenBright( `Building documentation complete in ${ Math.floor( time / 60 ) }m ${ time % 60 }s.` ) );
|
|
97
|
+
|
|
98
|
+
if ( options.watch ) {
|
|
99
|
+
return watcher( hexoManager );
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
return null;
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
async function buildThemes( outputDir, options ) {
|
|
106
|
+
const themesDir = path.join( __dirname, '../themes/umberto' );
|
|
107
|
+
const sourceDir = path.join( themesDir, 'src' );
|
|
108
|
+
const outputAssetsPath = path.join( outputDir, 'assets', version );
|
|
109
|
+
const layoutThemes = [ 'umberto', 'gloria' ];
|
|
110
|
+
|
|
111
|
+
for ( const theme of layoutThemes ) {
|
|
112
|
+
await runWebpack(
|
|
113
|
+
path.join( sourceDir, theme, 'js/app.js' ),
|
|
114
|
+
path.join( outputAssetsPath, theme, 'scripts' ),
|
|
115
|
+
{
|
|
116
|
+
minify: !options.dev,
|
|
117
|
+
umbertoDir: themesDir,
|
|
118
|
+
version
|
|
180
119
|
}
|
|
181
|
-
|
|
182
|
-
|
|
120
|
+
);
|
|
121
|
+
|
|
122
|
+
await copyAssets(
|
|
123
|
+
path.join( themesDir, 'source', theme ),
|
|
124
|
+
path.join( outputAssetsPath, theme )
|
|
125
|
+
);
|
|
126
|
+
|
|
127
|
+
await compileSass(
|
|
128
|
+
path.join( sourceDir, theme, 'css/styles.scss' ),
|
|
129
|
+
path.join( outputAssetsPath, theme, 'css/styles.css' )
|
|
130
|
+
);
|
|
131
|
+
}
|
|
183
132
|
}
|
|
133
|
+
|
|
134
|
+
/**
|
|
135
|
+
* @typedef {Object} Options
|
|
136
|
+
* @property {boolean} [skipApi=false] Skips rendering API docs.
|
|
137
|
+
* @property {boolean} [skipValidation=false] Skips validating links.
|
|
138
|
+
* @property {boolean} [skipLiveSnippets=false] Skips building live code snippets.
|
|
139
|
+
* @property {Object} [snippetOptions={}] Additional options passed to snippetAdapter.
|
|
140
|
+
* @property {boolean} [dev=false] Skip JS minification, don't clear build directory when rebuilding docs, reuse unchanged files.
|
|
141
|
+
* @property {boolean} [verbose=false] Adds more information to console during documentation building.
|
|
142
|
+
* @property {boolean} [createSymLinks=true] Add symbolic links with 'latest' to output folder.
|
|
143
|
+
* @property {boolean} [watch=false] Run Umberto with watch mode, which track changes in dm files and rebuild docs with it.
|
|
144
|
+
* @property {boolean} [validateW3C=false] Use vnu java validator to check every single output page for html syntax errors.
|
|
145
|
+
*/
|
|
@@ -40,15 +40,15 @@ module.exports = config => {
|
|
|
40
40
|
const docSources = readDocSources( src, apiType );
|
|
41
41
|
const dataProvider = new DataProvider();
|
|
42
42
|
const dataCollection = dataProvider.convert( apiType, docSources, { middlewares } );
|
|
43
|
-
const
|
|
43
|
+
const theme = projectConfig.slug === 'ckeditor5' ? 'gloria' : 'umberto';
|
|
44
44
|
|
|
45
45
|
if ( !dataCollection ) {
|
|
46
|
-
console.error( `Could not convert docs data for: ${
|
|
46
|
+
console.error( `Could not convert docs data for: ${ projectConfig.name }.` );
|
|
47
47
|
|
|
48
48
|
return;
|
|
49
49
|
}
|
|
50
50
|
|
|
51
|
-
const templateCol = new TemplateCollection( upath.join( themePath, 'layout
|
|
51
|
+
const templateCol = new TemplateCollection( upath.join( themePath, 'layout', theme, '_api-docs' ), {
|
|
52
52
|
locals: templateLocals
|
|
53
53
|
} );
|
|
54
54
|
const apiBuilder = new ApiBuilder(
|
|
@@ -64,7 +64,7 @@ module.exports = config => {
|
|
|
64
64
|
}
|
|
65
65
|
);
|
|
66
66
|
|
|
67
|
-
console.log( `Building API docs of ${
|
|
67
|
+
console.log( `Building API docs of ${ projectConfig.name }...` );
|
|
68
68
|
console.time( 'Built API docs in' );
|
|
69
69
|
const buildInfo = apiBuilder.buildApi();
|
|
70
70
|
console.timeEnd( 'Built API docs in' );
|
|
@@ -56,6 +56,7 @@ const getFilePatternsToProcess = require( '../helpers/get-file-patterns-to-proce
|
|
|
56
56
|
* @param {Object} options.snippetOptions Additional options passed to snippetAdapter.
|
|
57
57
|
* @param {Boolean} options.skipValidation Skip validating links.
|
|
58
58
|
* @param {Boolean} options.skipGuides Skip processing guides. Useful for checking the layout changes.
|
|
59
|
+
* @param {Boolean} options.skipSitemap Skip generating sitemap file. Useful when doing partial build.
|
|
59
60
|
* @param {Boolean} options.verbose Provide more details during building documentation.
|
|
60
61
|
* @param {Boolean} [options.watch] Flag which indicates that hexo should watch files.
|
|
61
62
|
* @param {Array.<String>} [options.guides] An array containing names of guides that will be processed by Umberto. Useful when building
|
|
@@ -67,7 +68,7 @@ module.exports = options => {
|
|
|
67
68
|
const {
|
|
68
69
|
mainConfig = getMainConfig( process.cwd() ),
|
|
69
70
|
rootPath = process.cwd(),
|
|
70
|
-
clean =
|
|
71
|
+
clean = !options.dev,
|
|
71
72
|
dev = false,
|
|
72
73
|
skipApi = false,
|
|
73
74
|
skipLiveSnippets = false,
|
|
@@ -76,6 +77,7 @@ module.exports = options => {
|
|
|
76
77
|
snippetOptions = {},
|
|
77
78
|
skipValidation = false,
|
|
78
79
|
skipGuides = false,
|
|
80
|
+
skipSitemap = false,
|
|
79
81
|
watch = false,
|
|
80
82
|
verbose = false,
|
|
81
83
|
guides = []
|
|
@@ -87,11 +89,11 @@ module.exports = options => {
|
|
|
87
89
|
|
|
88
90
|
return hexoManager.hexoInit()
|
|
89
91
|
// Clear build directory if it's not a local build (dev==true) or it is a local build and clean==true.
|
|
90
|
-
.then( () =>
|
|
92
|
+
.then( () => clean ? hexoManager.clean() : Promise.resolve() )
|
|
91
93
|
// Clear hexo source directory.
|
|
92
94
|
// Hexo source directory is where all markdown files and assets land and are used by hexo to render pages.
|
|
93
95
|
// It's possible to not delete them with every build to reuse files from previous builds.
|
|
94
|
-
.then( () =>
|
|
96
|
+
.then( () => clean || !skipLiveSnippets ? hexoManager.emptySourceDir() : Promise.resolve() )
|
|
95
97
|
// Copies common files for multiple projects scenario, e.g.: robots.txt,
|
|
96
98
|
// landing page (written in markdown like other guides), assets common for all projects etc.
|
|
97
99
|
.then( () => {
|
|
@@ -274,6 +276,10 @@ module.exports = options => {
|
|
|
274
276
|
}
|
|
275
277
|
}
|
|
276
278
|
|
|
279
|
+
if ( skipSitemap ) {
|
|
280
|
+
return Promise.resolve();
|
|
281
|
+
}
|
|
282
|
+
|
|
277
283
|
return createSitemap( 'build/docs', hostname, dst, {
|
|
278
284
|
excluded: excludedUrls,
|
|
279
285
|
extraUrlSettings
|
package/src/tasks/build-sdk.js
CHANGED
|
@@ -9,19 +9,35 @@ const TemplateCollection = require( '../template/template-collection' );
|
|
|
9
9
|
const SdkBuilder = require( '../sdk-builder/sdk-builder' );
|
|
10
10
|
|
|
11
11
|
module.exports = config => {
|
|
12
|
-
const
|
|
13
|
-
|
|
12
|
+
const {
|
|
13
|
+
outputDir, // build/docs
|
|
14
|
+
themePath, // Umberto theme path
|
|
15
|
+
BASE_PATH, // e.g.: ckeditor5/latest
|
|
16
|
+
docSearch, // Algolia's docsearch config
|
|
17
|
+
templateLocals, // Various data required by templates
|
|
18
|
+
projectConfig, // umberto.json config
|
|
19
|
+
canonicalUrlBeginning,
|
|
20
|
+
projectRootPath,
|
|
21
|
+
projectPath,
|
|
22
|
+
srcPath,
|
|
23
|
+
macrosVariables
|
|
24
|
+
} = config;
|
|
25
|
+
|
|
26
|
+
const theme = projectConfig.slug === 'ckeditor5' ? 'gloria' : 'umberto';
|
|
27
|
+
|
|
28
|
+
const templateCollection = new TemplateCollection( upath.join( themePath, 'layout', theme, '_sdk' ), {
|
|
29
|
+
locals: templateLocals
|
|
14
30
|
} );
|
|
15
31
|
const sdkBuilder = new SdkBuilder( {
|
|
16
|
-
BASE_PATH
|
|
32
|
+
BASE_PATH,
|
|
17
33
|
startPage: '/index.html',
|
|
18
|
-
sdkCollection: getSdkSources( upath.join(
|
|
34
|
+
sdkCollection: getSdkSources( upath.join( projectRootPath, projectPath, srcPath ) ),
|
|
19
35
|
template: templateCollection,
|
|
20
|
-
config:
|
|
21
|
-
destinationPath: upath.join(
|
|
22
|
-
canonicalUrlBeginning
|
|
23
|
-
macrosVariables
|
|
24
|
-
docSearch
|
|
36
|
+
config: projectConfig,
|
|
37
|
+
destinationPath: upath.join( outputDir, BASE_PATH ),
|
|
38
|
+
canonicalUrlBeginning,
|
|
39
|
+
macrosVariables,
|
|
40
|
+
docSearch
|
|
25
41
|
} );
|
|
26
42
|
|
|
27
43
|
sdkBuilder.buildSdk();
|
package/src/tasks/copy-assets.js
CHANGED
|
@@ -7,27 +7,27 @@
|
|
|
7
7
|
|
|
8
8
|
const upath = require( 'upath' );
|
|
9
9
|
const copyFiles = require( './copy-files' );
|
|
10
|
-
const themeDir = upath.join( __dirname, '../../themes/umberto' );
|
|
11
|
-
const umbertoVersion = require( '../../package.json' ).version;
|
|
12
10
|
|
|
13
11
|
/**
|
|
14
12
|
* Copies umberto images to build directory.
|
|
15
13
|
*
|
|
14
|
+
* @param {string} themeDir
|
|
15
|
+
* @param {string} outputPath
|
|
16
16
|
* @returns {Promise}
|
|
17
17
|
*/
|
|
18
|
-
module.exports = () => {
|
|
18
|
+
module.exports = ( themeDir, outputPath ) => {
|
|
19
19
|
return Promise.all( [
|
|
20
20
|
copyFiles(
|
|
21
|
-
upath.join( themeDir, '
|
|
22
|
-
upath.join(
|
|
21
|
+
upath.join( themeDir, 'assets', '_img' ),
|
|
22
|
+
upath.join( outputPath, 'img' )
|
|
23
23
|
),
|
|
24
24
|
copyFiles(
|
|
25
|
-
upath.join( themeDir, '
|
|
26
|
-
upath.join(
|
|
25
|
+
upath.join( themeDir, 'assets', '_scripts' ),
|
|
26
|
+
upath.join( outputPath, 'scripts' )
|
|
27
27
|
),
|
|
28
28
|
copyFiles(
|
|
29
|
-
upath.join( themeDir, '
|
|
30
|
-
upath.join(
|
|
29
|
+
upath.join( themeDir, 'assets', '_css' ),
|
|
30
|
+
upath.join( outputPath, 'css' )
|
|
31
31
|
)
|
|
32
32
|
] );
|
|
33
33
|
};
|
|
@@ -6,12 +6,12 @@
|
|
|
6
6
|
'use strict';
|
|
7
7
|
|
|
8
8
|
const getProjectConfig = require( './get-project-config' );
|
|
9
|
-
const getMainConfig = require( './get-main-config' );
|
|
10
9
|
const upath = require( 'upath' );
|
|
11
10
|
const fs = require( 'fs' );
|
|
12
11
|
const chalk = require( 'chalk' );
|
|
13
12
|
|
|
14
13
|
module.exports = async ( {
|
|
14
|
+
mainConfig,
|
|
15
15
|
rootPath,
|
|
16
16
|
isSingleProject = false
|
|
17
17
|
} ) => {
|
|
@@ -20,8 +20,7 @@ module.exports = async ( {
|
|
|
20
20
|
if ( isSingleProject ) {
|
|
21
21
|
configs.push( await getProjectConfig( rootPath, { skipLiveSnippets: true } ) );
|
|
22
22
|
} else {
|
|
23
|
-
const
|
|
24
|
-
const promises = projectPaths.map( projectPath => {
|
|
23
|
+
const promises = mainConfig.projects.map( projectPath => {
|
|
25
24
|
return getProjectConfig( upath.join( rootPath, projectPath ), { skipLiveSnippets: true } );
|
|
26
25
|
} );
|
|
27
26
|
configs.push( ...await Promise.all( promises ) );
|
|
@@ -4,7 +4,7 @@ html( lang='en' )
|
|
|
4
4
|
meta( charset='utf-8' )
|
|
5
5
|
meta( name="viewport" content="width=device-width, initial-scale=1")
|
|
6
6
|
title= page[ 'meta-title' ] ? page[ 'meta-title' ] : page.title
|
|
7
|
-
link( rel = 'stylesheet', href = '/assets/' + umbertoVersion + '/css/styles.css', type='text/css' media='screen' )
|
|
7
|
+
link( rel = 'stylesheet', href = '/assets/' + umbertoVersion + '/gloria/css/styles.css', type='text/css' media='screen' )
|
|
8
8
|
body
|
|
9
9
|
header.top
|
|
10
10
|
|