Commit graph

395 commits

Author SHA1 Message Date
David Goss
bb64f68acd
docs(v2): add npm2yarn to TypeScript install command (#3750) 2020-11-15 01:08:38 +03:00
Bartosz Kaszubowski
9d90e896f0
feat(v2): add ThemedImage component (#3730)
* feat(v2): add ThemedImage component

* add themed image problematic example

* refactor, SSR fix, openness about extending img tag, docs update

* refactor themed-image

* update themed image doc

Co-authored-by: slorber <lorber.sebastien@gmail.com>
Co-authored-by: Sébastien Lorber <slorber@users.noreply.github.com>
2020-11-13 14:29:45 +01:00
Bartosz Kaszubowski
74ee8f6150
docs(v2): add Inline SVG color override example (#3737) 2020-11-13 14:17:22 +01:00
Alexey Pyltsyn
487a9f98e4
feat(v2): introduce new minification of CSS bundle (#3716)
* feat(v2): optimize CSS bundle

* Move to separate preset

* Move custom scrollbar styles to separate class

* Cleanup styles

* Remove unactual styles

* Various CSS optimizations, cleanup styles for NProgress

* Add ability to back to old way of minifying CSS

* chore(v2): downgrade babel-plugin-dynamic-import-node to 2.3.0

* Use env var for back to simple CSS minifier

* remove unnecessary typing [skip-ci]

* Remove missing dep

* Update website/docs/cli.md

Co-authored-by: Sébastien Lorber <slorber@users.noreply.github.com>
2020-11-13 14:06:24 +01:00
Alexey Pyltsyn
8ef7c24583
fix(v2): use swizzled SearchPage component if any (#3721)
* fix(v2): use swizzled SearchPage component if any

* Fix dependency cycles warning
2020-11-12 17:01:46 +01:00
Alexey Pyltsyn
8c9f9487d6
refactor(v2): render all tab panels at once (#3706)
* refactor(v2): render all tab panels at once

* Add ability to choose way to load tabs
2020-11-09 17:06:07 +01:00
Alexey Pyltsyn
498f8a0f27
chore(v2): adjust website npm package (#3709) 2020-11-09 15:28:18 +01:00
Stephen McElhinney
9309594da9
feat(v2): Added the ability to specify GIT_PASS in deploy command (for CI purposes) (#3694)
* Added the ability to specify GIT_PASS (for CI purposes)

* Fixed variable copy issue

* Added documentation for GIT_PASS

Co-authored-by: Stephen McElhinney <stephen@appstruct.io>
2020-11-09 13:13:10 +01:00
Sébastien Lorber
c22c132fe0
docs(v2): deployment should use mdx extension (#3699)
* deployment: make it a mdx component because it contains <Tabs>

* fix deployment md links

* typo

* fix more links
2020-11-05 18:22:18 +01:00
iAmir
8f2d898f22
feat(v2): onBrokenMarkdownLinks config (#3658)
* refactor(v2): move `reportMessage` from `core/src/server/utils` to `utils` package

* feat(v2): handle broken markdown links by using onBrokenLinks prop from siteconfig

* feat(v2): add a new site config prop called `onBrokenMarkdownLinks`

works like onBrokenLinks, but only for markdown links

* feat(v2): add `onBrokenMarkdownLinks` to API docs

* some changes regarding test issues after adding `onBrokenMarkdownLink`

* Update website/versioned_docs/version-2.0.0-alpha.66/api/docusaurus.config.js.md

Co-authored-by: Sébastien Lorber <slorber@users.noreply.github.com>
2020-10-31 18:04:56 +01:00
kenve
4f64da8eda
docs(v2): update the link of Joi (#3644) 2020-10-27 15:03:17 +03:00
Thakur Karthik
92884431d1
feat(v2): add support for key,cert in https (#3594)
* fix: add support for key,cert in https

* docs: add steps for using https with docusaurus

* improve https certs docs

* typo

* local https: add mkcert -install step

Co-authored-by: slorber <lorber.sebastien@gmail.com>
2020-10-26 17:28:12 +01:00
Roman Bug
6c6200e473
docs(v2): fix some misspellings (#3636)
Some misspellings fixed.

Co-authored-by: Roman Zhukov <romanzhukov@yandex-team.ru>
2020-10-25 18:48:28 +03:00
Alexey Pyltsyn
14cdd72ae4
feat(v2): add ability to hide doc sidebar (#3615)
* feat(v2): add ability to hide doc sidebar

* Use relative imports
2020-10-22 11:23:15 +02:00
Sébastien Lorber
44535f7555
fix(v2): docusaurus start --poll 500 should work + better config load failure error (#3622)
* start --poll 500 should be accepted + better error message when siteDir is wrongly passed as a cli arg and lead to config loading failure

* docusaurus start --poll 500  option should also be used for chokidar

* config error message: relative path for reliable tests

* update snapshot

* document start --poll [interval]
2020-10-21 19:16:53 +02:00
Christian Bromann
7f6fba9d9e
docs(v2): removed obsolete "you" identifier (#3576) 2020-10-19 09:24:51 +03:00
Sébastien Lorber
e4c1626106
feat(v2): blog sidebar (#3593)
* blog sidebar POC

* polish blog post sidebar

* add doc for blogSidebarCount

* Update packages/docusaurus-theme-classic/src/theme/BlogSidebar/styles.module.css

Co-authored-by: Alexey Pyltsyn <lex61rus@gmail.com>

Co-authored-by: Alexey Pyltsyn <lex61rus@gmail.com>
2020-10-16 19:12:05 +02:00
Alexey Pyltsyn
bfefc46436
refactor(v2): various fixes (#3587)
* refactor(v2): various fixes

* Test
2020-10-16 10:54:23 +02:00
Sébastien Lorber
21264f5ed0
feat(v2): contextual search, dynamic Algolia facetFilters (#3550)
* POC of contextual search dynamic filters

* fix useSearchTags bugs

* contextual search should use preferred version  (persisted in storage)

* Contextual search: make system decoupled from algolia + wire proper meta tags and facet filters

* rework doc tag + minor refactorings

* update snapshots

* polish contextual search

* add Algolia validateThemeConfig tests
2020-10-15 12:16:30 +02:00
Bartosz Kaszubowski
b85e6e0205
feat(v2): allow to define custom CSS class for Tabs component (#3580)
* feat(v2): allow to define custom CSS class for Tabs component

* Update website/docs/markdown-features.mdx

Co-authored-by: Alexey Pyltsyn <lex61rus@gmail.com>

Co-authored-by: Alexey Pyltsyn <lex61rus@gmail.com>
2020-10-14 11:34:44 +02:00
Hamza Hamidi
e0c644e623
feat(v2): Add themeConfig.noIndex option #3528 (#3573)
* feat(v2): Add themeConfig.noIndex option #3528

* feat(v2): Add themeConfig.noIndex optionthrough ssrTemplate

* feat(v2): Include themeConfig.noIndex in CLI migration v1 to v2

* feat(v2): Remove themeConfig.noIndex from env dev
2020-10-14 11:14:16 +02:00
Sébastien Lorber
4130f1a195
feat(v2): persist docs preferred version (#3543)
* persist docs preferred version

* add proper implementation for useDocsPreferredVersion

* add proper implementation for useDocsPreferredVersion

* useDocsPreferredVersion => make localstorage read only after mount

* why @docusaurus/constants can't work?

* fix weird TS issue when not duplicating constants

* add basic @docusaurus/constants doc

* attempt to fix docs-only mode where we should not call useDocs hooks

* attempt to fix docs-only mode where we should not call useDocs hooks

* fix children

* encapsulate hacky isDocsPluginEnabled in docsUtils

* use same priority order for all navbar items: activeVersion ?? preferredVersion ?? latestVersion
2020-10-12 18:56:24 +02:00
DeadEnglish
d1510770f4
feat(v2): add option for blog meta title #3571
* feat(blog-meta-title): add support for additional meta title

* retrocompatible blog title

Co-authored-by: slorber <lorber.sebastien@gmail.com>
2020-10-12 13:23:54 +02:00
Russ Taylor
2e51034b0c
docs(v2): deployment, add required Github token scope infos (#3565) 2020-10-12 12:44:14 +02:00
Sébastien Lorber
649882d867
feat(v2): version dropdown before/after items + move site "All Versions" link (#3548)
* add dropdownItemsAfter option + reorg a bit docusaurus site navbar

* fix isActive  react warning

* Update theme-classic.md

Co-authored-by: Alexey Pyltsyn <lex61rus@gmail.com>
2020-10-07 19:58:00 +03:00
Sébastien Lorber
5b79f2ebc2
feat(v2): site client modules (#3545)
* site client modules

* Update website/docs/api/docusaurus.config.js.md

Co-authored-by: Alexey Pyltsyn <lex61rus@gmail.com>

Co-authored-by: Alexey Pyltsyn <lex61rus@gmail.com>
2020-10-07 14:44:14 +03:00
Sébastien Lorber
9ba28a378f
feat(v2): doc navbar item type (#3539)
* provide DocNavbarItem type

* update snapshots

* Fix Docusaurus tabs CSS

* revert navbar tabs css/style changes, instead apply simple navbar__link--active class + make it configurable

* Update website/docs/theme-classic.md

Co-authored-by: Alexey Pyltsyn <lex61rus@gmail.com>

* add dropdownActiveClassDisabled option

Co-authored-by: Alexey Pyltsyn <lex61rus@gmail.com>
2020-10-07 14:42:24 +03:00
Alexey Pyltsyn
9134b1396b
docs: various fixes and improvements (#3546) 2020-10-07 12:39:47 +02:00
SaintMalik
6dec70b69f
docs(v2): Fix url bugs in v2 docs (#3534)
* Fix broken link in the documentation

* Fix broken url caused by typo

* Fix broken link caused by typo
2020-10-04 19:46:48 +02:00
Sébastien Lorber
637fe0087d
feat(v2): add TOC to markdown pages #3529 2020-10-03 17:33:36 +02:00
Sébastien Lorber
dc31dad1de
docs(v2): add doc for wrapping theme components with @theme-original and @theme-init (#3502)
* add doc for wrapping theme components

* fix tests

* Minor improvements

Co-authored-by: Alexey Pyltsyn <lex61rus@gmail.com>
2020-09-30 18:15:47 +02:00
Rémi Doreau
d3a01458a3
feat(v2): add beforeDefaultRemarkPlugins/beforeDefaultRehypePlugins options to all md content plugins (#3467)
* fix(plugin-content-docs): add beforeDefaultRemarkPlugins + beforeDefaultRehypePlugins options

* fix(plugin-content-blog): add beforeDefaultRemarkPlugins + beforeDefaultRehypePlugins options

* fix(plugin-content-pages): add beforeDefaultRemarkPlugins + beforeDefaultRehypePlugins options

* feat(website-docs): overriding remark-rehype plugins

* fix(plugin-content): update beforeDefaultRehypePlugins/beforeDefaultRemarkPlugins types

* fix(plugin-content-docs): fix tests
2020-09-29 14:48:34 +02:00
Sébastien Lorber
6aeccc685e
docs(v2): grammar fix (#3493) 2020-09-28 19:29:51 +02:00
aakhtar3
a17693dd1b
docs(v2): Added drone.io publish docs #3491 (#3492) 2020-09-28 18:32:07 +02:00
Bartosz Kaszubowski
ae2c063929
feat(v2): allow to use array of files in customCss field (#3474)
* feat(v2): allow to use array of files in customCss field

* customCss array:
- fix bug (push instead of concat)
- update docs
- add theme config validation + tests

Co-authored-by: slorber <lorber.sebastien@gmail.com>
2020-09-28 18:15:41 +02:00
Henry Vélez
cc31567459
feat(v2): new docusaurus clear command (#3446)
* feat: new docusaurus clear command

* Update packages/docusaurus/bin/docusaurus.js

Co-authored-by: Alexey Pyltsyn <lex61rus@gmail.com>

* docs: new docusaurus clear command

* fix doc

* update monorepo clear cmd

* make clear async function wait for deletes to complete + factorize a bit

* prettier fix

* better clear docs

Co-authored-by: Alexey Pyltsyn <lex61rus@gmail.com>
Co-authored-by: slorber <lorber.sebastien@gmail.com>
Co-authored-by: Sébastien Lorber <slorber@users.noreply.github.com>
2020-09-28 16:33:35 +02:00
Bartosz Kaszubowski
c0d8238c49
feat(v2): add ability to set custom title delimiter in config (#3460)
* feat(v2): add custom title delimiter to the theme classic

* fix validation tests

* remove title delimiter fallback

* move titleDelimiter to main config, update theme-bootstrap

* remove test value from config

* update test snapshot

* Improve docs

Co-authored-by: Alexey Pyltsyn <lex61rus@gmail.com>
2020-09-26 00:25:19 +03:00
Tim Gates
8bed33b81f
docs(v2): fix simple typo, localy -> locally (#3480)
There is a small typo in website/docs/cli.md, website/docs/deployment.md, website/versioned_docs/version-2.0.0-alpha.60/cli.md, website/versioned_docs/version-2.0.0-alpha.60/deployment.md, website/versioned_docs/version-2.0.0-alpha.61/cli.md, website/versioned_docs/version-2.0.0-alpha.61/deployment.md, website/versioned_docs/version-2.0.0-alpha.62/cli.md, website/versioned_docs/version-2.0.0-alpha.62/deployment.md, website/versioned_docs/version-2.0.0-alpha.63/cli.md, website/versioned_docs/version-2.0.0-alpha.63/deployment.md, website/versioned_docs/version-2.0.0-alpha.64/cli.md, website/versioned_docs/version-2.0.0-alpha.64/deployment.md.

Should read `locally` rather than `localy`.
2020-09-23 22:50:06 +03:00
Alexey Pyltsyn
02f96286e5
docs(v2): remove redundant new line in code block (#3479) 2020-09-23 19:16:04 +03:00
Jeremy Hager
521ef59908
docs(v2): add deployment command for PowerShell (#3459)
* Added powershell command for deployment
- specified batch command is for cmd
- added powershell as an option for deployment, changed to single quotes

* - This affects the following versioned docs:
  - 2.0.0-alpha.63
  - 2.0.0-alpha.64
  - Next (Dev)

* Changed deploy commands to tabbed
- bash, windows, powershell, and cmd are now part of <tabs>
- default value is bash

* Changed deployment commands to tabs in v63 and 64
- Next (dev) now has better syntax
- 2.0.0-alpha-63 and 2.0.0-alpha-64 now include the tabs as well

* Updated lables in deploy and cmd to Windows
- Labels now are first-letter uppercase
  - eg. bash -> Bash
- cmd is now Windows to align with original docs

* Removed `<Tab>` spacing in deploy section
- Removed spacing at end of `values` statement
- Removed spacing between `<Tabs>` and `<TabItem>`
- build successful locally
2020-09-19 10:16:11 +03:00
Bartosz Kaszubowski
a0cac48cd4
chore(v2): fix theme classic navbar style docs (#3448) 2020-09-16 10:46:28 +03:00
Méril
77db144378
docs(v2): reference Eta's syntax in ssrTemplate section (#3425) 2020-09-09 15:49:11 +02:00
Méril
d844ff6107
feat(v2): add an option to toggle trailing slash for urls in sitemap (#3426) 2020-09-09 15:48:47 +02:00
Sébastien Lorber
21852948ce
feat(v2): ability to add/override theme html metadatas (#3406)
* ability to add/override theme html metadatas
see https://github.com/facebook/docusaurus/issues/3024

* refactor/fix validateThemeConfig tests
2020-09-04 16:36:56 +02:00
Méril
3ace60043b
feat(v2): allow users to specify a custom ssr HTML template (#3387)
* feat(v2): allow users to specify a custom ssr HTML template

* docs(v2): add ssrTemplate property to docusaurus.config.js page
2020-09-02 19:29:04 +02:00
Sébastien Lorber
9857f7b2b5
feat(v2): officially release @docusaurus/plugin-debug (#3392)
* Add json styling to config debug

* Style debug content page

* Add style and collapse depth to json viewer

* Add style to debug layout

* Add style to metadata debug

* Add style support to registry debugger

* Remove default content if other instances are present

* Change colors for more contrast

* Add debug routes styles

* Add active link style

* Fix container css issues

* Style registry debug page

* Remove unused style modules

* Add white space to style files

* Add font scaling

* Fix prettier errors

* Add child routes to route debug

* Readd default content plugin json

* Add empty home page to debug

* Prettier

* Revert "Add empty home page to debug"
This should be included in a separate PR
This reverts commit 9c43c9f7fb.

* Set colors to dark theme

* Add plugin debug doc + minor fixes + expose global data

* more debug plugin doc

Co-authored-by: Drewbi <drewalexander986@gmail.com>
2020-09-02 15:42:34 +02:00
Bartosz Kaszubowski
e8e16a45d3
feat(v2): add isCloseable property for theme-classic announcement bar (#3388)
* feat(v2): add `isCloseable` property for announcement bar

* correct styling for non-closeable announcement

* fix tests
2020-09-02 11:41:38 +02:00
Sam Ko
2a3fe86579
docs(v2): update Deploy to Vercel guide (#3344) 2020-09-01 12:14:39 +02:00
Sébastien Lorber
d8cfabb66a
feat(v2): docs options.onlyIncludeVersions (#3373)
* docs options.onlyIncludeVersions

* adapt docsVersionDropdown if we render a single version

* fix bad error message

* fix netlify deploy when versioning is disabled
2020-08-31 17:08:24 +02:00
Thad Guidry
149d82c730
docs(v2): fix grammar on introduction page (#3369) 2020-08-31 01:16:12 +08:00