Commit graph

2959 commits

Author SHA1 Message Date
Sébastien Lorber
9c34f68a7a
fix(v2): DocSearch should keep working after a new release (#3393)
* We should create an alias for searching last version of docs on DocSearch/Algolia, so that on new version publish, search still works even if new version is not already indexed (https://github.com/facebook/docusaurus/issues/3391)

* commit missing snapshot

* update after algolia changes

* put back facetFilters: [`version:${versions[0]}`] until latest facet is indexed
2020-09-03 14:35:46 +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
Sam Ko
8f24a0a149
docs(v1, v2): Update Deploy to Vercel guide (#3390)
* Update Vercel guide for version-2.0.0-alpha.62

* Update Vercel guides for Docusaurus v1
2020-09-02 12:19:54 +02:00
Sébastien Lorber
ab3ebdad39
chore(v2): pin exact dependency versions (#3386)
* Attempt to pin all dependency versions exactly for https://github.com/facebook/docusaurus/issues/3371

* warn if @docusaurus package versions mismatch

* fix yarn lock
2020-09-02 11:42:17 +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
Sébastien Lorber
0d018a88c5
fix(v2): script tags should allow unknown values (#3385)
https://github.com/facebook/docusaurus/issues/3378
2020-09-01 19:40:37 +02:00
Sébastien Lorber
5359d61d9e
fix(v2): allow using classic theme/preset without the docs plugin (#3382)
* deprecated nextVersionLabel option

* useActivePlugin failfast option

* remove deprecated option nextVersionLabel

* routeBasePath: '' should be forbidden

* routeBasePath: '' should be forbidden

* Docs: do not show version badge if there is only 1 version: https://github.com/facebook/docusaurus/issues/3362

* allow sidebars file to not exist: fallback to empty sidebars
https://githu.com/facebook/docusaurus/issues/3366

* Ability to use classic theme/preset while not using docs/pages without trouble.
https://github.com/facebook/docusaurus/issues/3360

* fix netlify redirects

* do not throw if useDocs do not load?

* netlify deploy typo

* try to fix useDocs

* docs(v2): update Deploy to Vercel guide (#3344)

* filter annoying useDocs conditional require warning

* netlify deploy preview homepage

* typo

* try to trigger again CLA bot

Co-authored-by: Sam Ko <sam@vercel.com>
2020-09-01 19:38:11 +02:00
Sébastien Lorber
a4769e3f30
fix(v2): alpha 62 doc fixes (#3381)
* deprecated nextVersionLabel option

* useActivePlugin failfast option

* remove deprecated option nextVersionLabel

* routeBasePath: '' should be forbidden

* routeBasePath: '' should be forbidden

* Docs: do not show version badge if there is only 1 version: https://github.com/facebook/docusaurus/issues/3362

* allow sidebars file to not exist: fallback to empty sidebars
https://githu.com/facebook/docusaurus/issues/3366
2020-09-01 16:31:33 +02:00
Sam Ko
2a3fe86579
docs(v2): update Deploy to Vercel guide (#3344) 2020-09-01 12:14:39 +02:00
Sébastien Lorber
1eb6e13fb7
fix(v2): reject routeBasePath: '' (#3377)
* routeBasePath: '' should be forbidden

* routeBasePath: '' should be forbidden

* commit

* try to trigger cla bot
2020-08-31 19:59:27 +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
Sébastien Lorber
4f448bd54b
chore(v2): prepare v2.0.0.alpha-62 release (#3359)
* Add alpha 62

* v2.0.0-alpha.62
2020-08-28 19:17:56 +02:00
Sébastien Lorber
ae877f2990
feat(v2): docs version configuration: lastVersion, version.{path,label} (#3357)
* add new docs versioning options

* Add some tests for new versioning options

* Add some docs for version configurations

* try to fix broken link detection after /docs/ root paths have been removed on deploy previews

* improve dev/deploypreview versioning configurations

* disable custom current version path, as it produces broken links

* readVersionDocs should not be order sensitive

* fix versions page according to versioning config

* fix versions page according to versioning config
2020-08-28 18:37:49 +02:00
Sébastien Lorber
4bfc3bbbe7
fix(v2): fix migrate cli paths (sidebars/customcss) (#3358)
* fix: Allow docusaurus-migrate to create relative paths #3239

* fix migration cli sidebars/customcss paths

* fix migration cli sidebars paths

Co-authored-by: PalAditya <adityapal.nghss@gmail.com>
2020-08-28 18:05:43 +02:00
Archit
a999928ad8
fix(v2): add https support in webpack devserver (#3311) 2020-08-28 18:05:18 +02:00
Sam Zhou
aa9212cb45
feat(v2): Provide type definitions for remaining theme-classic components (#3356) 2020-08-28 17:45:51 +02:00
Sam Zhou
16ae3bf462
fix(v2): Add missing dependencies to packages (#3355) 2020-08-28 15:04:44 +02:00
Sam Zhou
c8d6e418ff
feat(v2): Provide type definitions for MDXPage from page plugin (#3354) 2020-08-28 14:58:32 +02:00
Vincent
56c04c7834
fix(v2): Allow the alt for the logo to be empty (#3352)
See
https://developer.mozilla.org/en-US/docs/Web/HTML/Element/Img#Attributes

> Setting this attribute to an empty string (alt="") indicates that
> this image is not a key part of the content (it’s decoration or a
> tracking pixel), and that non-visual browsers may omit it from
> rendering.

Since the logo is indeed decorative and redundant with the actual
project name, an empty alt is fine.
2020-08-28 12:50:42 +02:00
Sébastien Lorber
c7fc781ce0
fix(v2): linking to asset or external html page -> don't use history.push() (#3347)
* Rework markdown links to asset require processing + add test page

* implement pathname:// protocol / escape hatch at the Link level

* linking to assets: fix tests + avoid creating an useless nested paragraph

* fix assets linking doc

* attempt to fix windows e2e test

* try to fix windows errors
2020-08-28 12:47:03 +02:00
Sam Zhou
bd9b6618c1
feat(v2): Provide typing to most of the theme-classic components (#3348)
* feat(v2): Provide typing to most of the theme-classic components

* Expose type to the end users and dogfood it in v2 website
2020-08-28 12:06:37 +02:00
Shubham Kumar
658dac7d42
docs(v2): add draft doc (#3346)
* docs(v2): add draft doc

* Update docs/guides-blog.md

Co-authored-by: Sébastien Lorber <slorber@users.noreply.github.com>
2020-08-27 19:59:58 +02:00
Bogdan Doroschenko
a72ac91e3e
test(v2): add unit test for migration of config file (#3323) 2020-08-27 12:03:51 +02:00
Sam Zhou
d299b99631
feat(v2): Provide docs plugin typing (#3328) 2020-08-27 11:40:14 +02:00
Sébastien Lorber
b86806460c
refactor(v2): announcement bar bad spelling + minor refactors (#3343) 2020-08-27 10:55:45 +02:00
Bogdan Doroschenko
3ccca399f1
test(v2): make blog posts unit test ordering determinate (#3339) 2020-08-27 10:09:43 +02:00
adinaja
8fd5375b26
fix(v1): fenced block detection (#3340) 2020-08-27 10:06:10 +02:00
Nisarag
306d3afc0a
adding team profile card about myself (#3336) 2020-08-26 11:38:12 +08:00
Yangshun Tay
d04a30cc93
docs(v2): update team profile (#3335)
* docs(v2): update team profile

* misc: add Sam intro
2020-08-25 20:42:46 +02:00
Drew Alexander
c7daf32642
docs(v2): add Drew to Fellows section (#3334)
* Add me to Fellows section

* Update team.md

Co-authored-by: Yangshun Tay <tay.yang.shun@gmail.com>
2020-08-25 22:10:18 +08:00
Teik Jun
878ce3132b
docs(v2): add anshul and tj to fellows team (#3333) 2020-08-25 20:54:23 +08:00
Yang Luo
661eac4fe9
docs(v1): showcase user Casbin (#3326)
* Add Casbin to users

* Update users.js

Co-authored-by: Yangshun Tay <tay.yang.shun@gmail.com>
2020-08-23 17:14:51 +08:00
Sam Zhou
b38f562322
chore(v2): Define type for markdown right table of contents (#3306) 2020-08-20 17:57:19 +02:00
Mirzayev Farid
fb49a7fc89
docs(v1): add Global CTO Forum to users (#3316) 2020-08-20 17:54:10 +02:00
Anshul Goyal
ef5f6fb852
fix(v2): fix url-loader not found (#3313) 2020-08-20 15:27:13 +02:00
Jean-Marc Saad
3ea2f8cfde
feat(v2): blog slug frontmatter (#3284) 2020-08-20 14:59:54 +02:00
Daniel Wilkowski
0f357606cd
docs(v2): add "T-Regx" website to showcase (#3310)
* Add "T-Regx" docusaurs website to showcase

* Update users.js

* Update users.js

Co-authored-by: Sébastien Lorber <slorber@users.noreply.github.com>
2020-08-20 14:49:32 +02:00
Sébastien Lorber
f4ca61be81
fix(v2): brokenLinks should not report links that belong to an existing folder if folder/index.html exists (#3308)
* move pluginIds.test.ts

* improve brokenLinks checker and add tests for filterExistingFileLinks
2020-08-19 18:45:42 +02:00
Jonas Dellinger
c97dd656a9
docs(v2): showcase SpotifyAPI-NET (#3307) 2020-08-19 16:01:46 +02:00
Ben Gubler
a94d14b9c7
fix(v1,v2): add initial-scale=1.0 to all meta name='viewport' (#3290) 2020-08-18 12:59:58 +02:00
Fanny
8c05aa8e94
feat(v2): bootstrap theme, preset, template, CI previews (#2981)
* fix(v2): doc sidebar

* chore(v2): prettier

* fix(v2): docs navbar path

* fix(v2): fix error about activepath

* chore(v2): prettier

* feat(v2): change active color

* feat(v2): Add bootstrap doc

* docs(v2): Update preset

* doc(v2): finish bootstrap documentation

* chore(v2): run lint

* doc(v2): update hook

* fix theme bootstrap layout (far from perfect)

* Try to fix bootstrap theme and deploy it!

* fix netlify error

Co-authored-by: slorber <lorber.sebastien@gmail.com>
2020-08-17 20:18:37 +02:00
Sam Zhou
5fdf96c552
feat(v2): Provide blog plugin theme typing (#3267)
* feat(v2): Provide blog plugin theme typing

* Update packages/docusaurus-plugin-content-blog/index.d.ts

* Update packages/docusaurus-plugin-content-blog/index.d.ts

* Update packages/docusaurus-plugin-content-blog/index.d.ts

* Update packages/docusaurus-plugin-content-blog/index.d.ts

Co-authored-by: Sébastien Lorber <slorber@users.noreply.github.com>
2020-08-17 18:25:02 +02:00
Orta Therox
33ecc4bb17
chore(v2): tighten up the TypeScript onboarding (#3244)
* Tighten up the TypeScript onboarding

* Extend the API to cover everything used in the classic theme

* Wrap up internal TS support
2020-08-17 18:03:21 +02:00
Sébastien Lorber
a4c8a7f55b
refactor(v2): docs plugin refactor (#3245)
* safe refactorings

* safe refactors

* add code to read versions more generically

* refactor docs plugin

* refactors

* stable docs refactor

* progress on refactor

* stable docs refactor

* stable docs refactor

* stable docs refactor

* attempt to fix admonition :(

* configureWebpack docs: better typing

* more refactors

* rename cli

* refactor docs metadata processing => move to pure function

* stable docs refactor

* stable docs refactor

* named exports

* basic sidebars refactor

* add getElementsAround utils

* refactor sidebar + ordering/navigation logic

* stable retrocompatible refactor

* add proper versions metadata tests

* fix docs metadata tests

* fix docs tests

* fix test due to absolute path

* fix webpack tests

* refactor linkify + add broken markdown links warning

* fix DOM warning due to forwarding legacy prop to div element

* add todo
2020-08-17 17:50:22 +02:00
Sébastien Lorber
d17df954b5
refactor(v2): precompile ETA templates (#3238)
* compile ETA templates ahead of time

* handle PR review
2020-08-17 15:43:17 +02:00
François Chalifour
51f07608fa
fix(v2): keep DocSearch state on remounts (#3297)
* fix(v2): keep DocSearch state on remounts

* fix: memoize `transformSearchClient`
2020-08-17 14:58:02 +02:00
Amy Lei
473d263469
feat(v2): add toc to blog posts (#3274)
* refactor TOC into own component

* make layout consistent across blog pages
2020-08-17 14:47:19 +02:00
Vandré Leal
3ef965bae6
docs(v2): showcase Oxidizer (#3295) 2020-08-17 12:36:58 +02:00