Commit graph

1987 commits

Author SHA1 Message Date
Joshua Chen
fdf59f30f0
feat(content-pages): front matter validation, include front matter in metadata (#6400) 2022-01-19 13:44:58 +01:00
Joshua Chen
e5801e49f6
feat(mdx-loader): read image dimensions when processing Markdown (#6339) 2022-01-19 12:45:14 +01:00
Yaroslav Serhieiev
6f892e20b0
feat(core, theme-classic): allow overriding htmlLang (#6371) 2022-01-19 12:38:42 +01:00
Joshua Chen
6c0da3ee4b
refactor: clean up TODO comments (#6399) 2022-01-19 12:10:50 +08:00
Joshua Chen
1d7827d572
refactor(theme-classic): add comments to Prism setup; minor refactor (#6391) 2022-01-18 19:46:22 +08:00
Joshua Chen
7bab9ba46d
feat(content-blog): include tags in feed (#6388)
* feat(content-blog): include tags in feed

* fix
2022-01-18 17:20:37 +08:00
Joshua Chen
62223ee556
test: improve test coverage (#6387)
* test: improve test coverage

* fix

* use posixPath
2022-01-18 16:29:40 +08:00
Joshua Chen
a9810db1cc
fix(logger): properly stringify objects for logging (#6384)
* fix(logger): properly stringify objects for logging

* Add tests
2022-01-17 20:46:38 +08:00
Nick Schonning
16141fcd80
chore: enable a few fixable ESLint rules (#6380)
* chore: enable react/jsx-one-expression-per-line

* chore: enable import/first

* chore: enable lines-between-class-members

* revert class spacing

Co-authored-by: Joshua Chen <sidachen2003@gmail.com>
2022-01-17 14:25:50 +08:00
Joshua Chen
3cb0972b79
refactor: use findAsyncSequential in a few places (#6377)
* refactor: use findAsyncSequential in a few places

* fixes

* fix
2022-01-17 08:57:06 +08:00
Joshua Chen
ad16f4fdd9
fix(core): do not coerce webpack warning to string (#6378) 2022-01-16 19:47:22 +08:00
Joshua Chen
52db7320a6
chore: enable eslint-plugin-jest (#6375) 2022-01-16 15:53:23 +08:00
Tapan Chudasama
3e5944ef1f
fix: highlight appropriate navItem based on active sidebar item (#6310)
* fix: highlight appropriate navItem based on active sidebar item

* fix: try using location.pathname

* fix: remote console.log

* fix: include category generated indices in globalData

* Add test

* fix snap

Co-authored-by: Joshua Chen <sidachen2003@gmail.com>
2022-01-16 13:41:40 +08:00
Nick Schonning
6e75d035bb
chore: enable react/jsx-closing-bracket-location (#6373)
This no longer appears to conflict with prettier
2022-01-16 12:41:17 +08:00
Joshua Chen
14bec7cf11
feat(stylelint-copyright): autofix, stricter config (#6374)
* feat(stylelint-copyright): autofix, stricter config

* revert TS

* oops
2022-01-16 11:34:10 +08:00
Nick Schonning
284c6166e7
chore: add baseline stylelint rules (#6372)
* chore: add baseline stylelint rules

Use the Prettier config so not to conflict with rules.
Add the Stylelint baseline recommended rules to catch additional lissues

* enable those two rules

* ooops

* refactor scripts

* revert script changes

Co-authored-by: Joshua Chen <sidachen2003@gmail.com>
2022-01-16 09:42:58 +08:00
Nick Schonning
9f9a96dc80
chore: upgrade lint-staged and globs (#6369) 2022-01-15 16:33:09 +08:00
dependabot[bot]
051463fec9
chore(deps): bump querystring from 0.2.0 to 0.2.1 (#6355)
Bumps [querystring](https://github.com/Gozala/querystring) from 0.2.0 to 0.2.1.
- [Release notes](https://github.com/Gozala/querystring/releases)
- [Changelog](https://github.com/Gozala/querystring/blob/master/CHANGELOG.md)
- [Commits](https://github.com/Gozala/querystring/compare/v0.2.0...v0.2.1)

---
updated-dependencies:
- dependency-name: querystring
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-01-15 13:48:56 +08:00
dependabot[bot]
7512e4c0b3
chore(deps): bump copy-webpack-plugin from 9.1.0 to 10.2.0 (#6350)
* chore(deps): bump copy-webpack-plugin from 9.1.0 to 10.2.0

Bumps [copy-webpack-plugin](https://github.com/webpack-contrib/copy-webpack-plugin) from 9.1.0 to 10.2.0.
- [Release notes](https://github.com/webpack-contrib/copy-webpack-plugin/releases)
- [Changelog](https://github.com/webpack-contrib/copy-webpack-plugin/blob/master/CHANGELOG.md)
- [Commits](https://github.com/webpack-contrib/copy-webpack-plugin/compare/v9.1.0...v10.2.0)

---
updated-dependencies:
- dependency-name: copy-webpack-plugin
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* fix

* fix

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Joshua Chen <sidachen2003@gmail.com>
2022-01-15 13:47:39 +08:00
Filipe Guerra
dd63a72a71
fix(create-docusaurus): add useBaseUrl for image URLs (#6368)
This is already provided by the classic template and in TypeScript
template wasn't updated.
2022-01-15 12:57:59 +08:00
dependabot[bot]
95955ecfb0
chore(deps): bump css-loader from 5.2.7 to 6.5.1 (#6353)
Bumps [css-loader](https://github.com/webpack-contrib/css-loader) from 5.2.7 to 6.5.1.
- [Release notes](https://github.com/webpack-contrib/css-loader/releases)
- [Changelog](https://github.com/webpack-contrib/css-loader/blob/master/CHANGELOG.md)
- [Commits](https://github.com/webpack-contrib/css-loader/compare/v5.2.7...v6.5.1)

---
updated-dependencies:
- dependency-name: css-loader
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-01-15 10:30:47 +08:00
dependabot[bot]
f09196adaa
chore(deps): remove hast-util-to-text from dependencies (#6347)
* chore(deps): bump hast-util-to-text from 2.0.1 to 3.1.1

Bumps [hast-util-to-text](https://github.com/syntax-tree/hast-util-to-text) from 2.0.1 to 3.1.1.
- [Release notes](https://github.com/syntax-tree/hast-util-to-text/releases)
- [Commits](https://github.com/syntax-tree/hast-util-to-text/compare/2.0.1...3.1.1)

---
updated-dependencies:
- dependency-name: hast-util-to-text
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* remove dep

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Joshua Chen <sidachen2003@gmail.com>
2022-01-15 10:13:04 +08:00
Sébastien Lorber
4004f5b68b
chore: regenerate yarn.lock (#6341)
Co-authored-by: Joshua Chen <sidachen2003@gmail.com>
2022-01-14 15:52:12 +01:00
Sébastien Lorber
8b7ab21d38
fix(core): error boundary should allow no children (#6338) 2022-01-14 10:39:24 +01:00
Devtato
2f97a85406
feat(theme-classic): autoscroll TOC with active link (#6317)
* feat(theme-common): add smooth TOC scrolling to active link

* docs: change the link of repeated content category in lifecycle api

* Update lifecycle-apis.md

* fix page container scrolling

Co-authored-by: Joshua Chen <sidachen2003@gmail.com>
2022-01-13 15:04:57 +08:00
Nick Schonning
02a233a221
chore: minor typo cleanup (#6324)
* chore: minor typo cleanup

* fix tests

Co-authored-by: Joshua Chen <sidachen2003@gmail.com>
2022-01-13 14:36:53 +08:00
Joshua Chen
217b62682d
feat(mdx-loader): preserve hash in image src; support GH themed images (#6323)
* feat(mdx-loader): preserve hash in image src; support GH themed images

* more refactor
2022-01-13 10:22:48 +08:00
Joshua Chen
984c73be30
feat(core): improve error message for BrowserOnly; better docs (#6291)
* feat(core): improve error message for BrowserOnly; better docs

* oops

* oops

* docs
2022-01-12 20:06:33 +08:00
Joshua Chen
a2d2324ca7
fix(theme-classic): fix mobile version dropdown label with only one version (#6314)
* fix(theme-classic): fix mobile version dropdown label with only one version

* properly fix
2022-01-11 21:53:41 +08:00
Joshua Chen
a79c23bc45
test(utils, mdx-loader, core): improve coverage (#6303)
* test(utils, mdx-loader, core): improve coverage

* windows...

* fix
2022-01-10 15:00:51 +08:00
Joshua Chen
cf265c051e
refactor: move exported type definitions to declaration file (#6300)
* refactor: move exported type definitions to declaration file

* fix

* fix
2022-01-09 22:02:31 +08:00
Joshua Chen
4fad1ce0cd
misc: convert all internal scripts to ESM (#6286)
* misc: convert all internal scripts to ESM

* fixes

* fix

* fixes

* fix!

* complete eslint

* more move

* fix!

* This looks better?

* Final ones
2022-01-08 12:59:28 +08:00
Josh Goldberg
bcc05e243f
fix(theme-classic): add missing role=region to SkipToContent (#6288) 2022-01-07 19:31:05 +01:00
Sébastien Lorber
f87a3ead46
refactor: move @theme/hooks to @docusaurus/theme-common (#6289) 2022-01-07 19:19:35 +01:00
Sébastien Lorber
024f2bf49b
refactor: new @docusaurus/plugin-content-docs/client interface (#6287) 2022-01-07 17:04:21 +01:00
Sébastien Lorber
3bc63b2b09
refactor(theme-classic): apply import/no-named-export eslint rule (#6283) 2022-01-07 14:44:55 +01:00
Joshua Chen
37a84f86a5
fix(preset-classic): throw if preset finds GA options in theme config (#6284)
* fix(preset-classic): throw if preset finds GA options in theme config

* revert

* stricter
2022-01-07 12:50:45 +08:00
Reece Dunham
c08e247b56
refactor(core): use native types from webpack-dev-server (#6279)
Signed-off-by: Reece Dunham <me@rdil.rocks>
2022-01-06 23:05:03 +08:00
Joshua Chen
edab7e07ed
refactor(content-docs): make readVersionsMetadata async (#6277)
* refactor(content-docs): make readVersionsMetadata async

* fix tests
2022-01-06 21:46:08 +08:00
Joshua Chen
1d957d97e8
fix(migrate): migration CLI should correctly migrate gtag options (#6276)
* fix(migrate): migration CLI should correctly migrate gtag options

* fix
2022-01-06 20:39:23 +08:00
Minh Pham
eade41a702
feat(theme-classic): new navbar item linking to a sidebar (#6139)
Co-authored-by: Sébastien Lorber <slorber@users.noreply.github.com>
Co-authored-by: Joshua Chen <sidachen2003@gmail.com>
Co-authored-by: sebastienlorber <lorber.sebastien@gmail.com>
2022-01-06 11:52:25 +01:00
Joshua Chen
3cb99124de
feat(content-docs): allow SEO metadata for category index pages (#6239) 2022-01-06 11:31:01 +01:00
Joshua Chen
b0c23275f3
refactor(theme-classic): use front matter from metadata for BlogPostPage (#6240) 2022-01-05 18:55:04 +01:00
Joshua Chen
8fe1ddf46a
feat(sitemap): remove trailingSlash option; respect noIndex config (#6248) 2022-01-05 17:56:17 +01:00
Joshua Chen
37b70e3ab4
refactor(core): convert serverEntry.js to TS (#6237)
* refactor(core): convert serverEntry.js to TS

* fix

* migrate template to TS

* Move templates
2022-01-05 21:34:24 +08:00
Joshua Chen
9f0809ae28
fix(content-blog): always convert front matter date as UTC (#6244) 2022-01-02 12:47:23 +08:00
Joshua Chen
cb1aa30286
refactor: enforce type import specifiers (#6230)
* refactor: enforce type import specifiers

* fix

* Upgrade esbuild

* Fix (haha)
2021-12-31 21:17:09 +08:00
Joshua Chen
24d65d9bdd
refactor(utils): reorganize functions; move authors file resolution to utils (#6229)
* refactor(utils): reorganize functions; move authors file resolution to utils

* More refactor
2021-12-31 11:55:42 +08:00
Joshua Chen
218789f85e
refactor(theme-translations): improve typing for update script (#6225)
* refactor(theme-translations): improve typing for update script

* Remove
2021-12-30 17:28:57 +08:00
Joshua Chen
c45281a581
feat(theme-classic): usable CodeBlock outside markdown (#6216) 2021-12-29 17:17:09 +01:00