Tim Small
7f59fdd9bd
Enhance text contrast of `light` theme to improve accessibility.
...
The existing light theme has relatively low contrast between the text
(and other UI elements) and background (especially within code blocks).
This presents difficulties for people with reduced visual contrast
perception (common in older adults).
This patch makes changes to the default `light` theme to meet the
minimum contrast requirement of the v2.1 W3C WCAG (Web Content
Accessibility Guidelines)
https://www.w3.org/WAI/WCAG21/quickref/#contrast-minimum
The small size, and slender font used for the title text makes it hard
to read, even with the increased contrast colour scheme, so this patch
also increases the size of the title text font by 20%.
Closes #1442
2021-02-21 14:35:10 +00:00
Eric Huss
1a0c296532
Merge pull request #1426 from ehuss/search-mark-words
...
Fix search highlighting with multiple words.
2021-01-14 17:01:52 -08:00
Eric Huss
9b4ab72a80
Merge pull request #1418 from ehuss/relative-renderer-command
...
Fix relative paths for renderer commands.
2021-01-14 17:01:41 -08:00
Eric Huss
cdea0f6b61
Add missing parenthesis in doc comment.
2021-01-13 14:26:14 -08:00
pierwill
e9b0be7090
Add intra-docs links to docs
...
Also fixes some punctuation and changes some wording.
2021-01-10 14:51:30 -08:00
Eric Huss
77e7cfd22b
Change `init --theme` to place theme in root. ( #1432 )
2021-01-07 01:29:38 +01:00
Eric Huss
09e7bb76dc
Remove mark from URL on escape. ( #1427 )
2021-01-05 19:31:16 +01:00
Eric Huss
28387130c0
Fix search highlighting with multiple words.
2021-01-04 14:20:36 -08:00
Eric Huss
33d3d9c3ec
Merge pull request #1389 from avitex/search-chapter-name
...
Add chapter name to search result breadcrumbs
2021-01-04 14:01:30 -08:00
Eric Huss
e651f4d734
Merge pull request #1420 from apatniv/clippy_remove_clone
...
Clippy lint: Remove unnecessary clone
2021-01-04 11:33:37 -08:00
Eric Huss
87d2cd9845
Merge pull request #1421 from apatniv/clippy_use_single_char
...
clippy: use char instead of str
2021-01-04 11:31:06 -08:00
Pietro Albini
32abeef088
fix xss in the search page
...
Thanks to Kamil Vavra for responsibly disclosing the vulnerability
according to Rust's Security Policy.
2021-01-04 07:14:57 -08:00
apatniv
95e0743bc0
clippy: use char instead of str
2020-12-31 15:37:34 -05:00
apatniv
3c97525743
Clippy lint: Remove unnecessary clone
2020-12-31 15:18:37 -05:00
Eric Huss
9a65c8ab92
Fix relative paths for renderer commands.
2020-12-30 17:46:29 -08:00
francis-du
fd4137a9ea
fix: readerer get theme dir path bug
2020-12-28 09:20:23 -08:00
Vivek Bharath Akupatni
a3d4febe3e
Provide useful feedback if user executes command in different folder ( #1407 )
...
Provides better feedback if user executes in a different folder than what is expected by mdbook
After the changes `mdbook build`
```
2020-12-19 14:27:35 [ERROR] (mdbook::utils): Error: Couldn't open SUMMARY.md in "/Users/vicky/rust/source_codes/mdbook_testing/src/src" directory
2020-12-19 14:27:35 [ERROR] (mdbook::utils): Caused By: No such file or directory (os error 2)
```
Previously: `mdbook build`
```
2020-12-19 14:28:46 [ERROR] (mdbook::utils): Error: Couldn't open SUMMARY.md
2020-12-19 14:28:46 [ERROR] (mdbook::utils): Caused By: No such file or directory (os error 2)
```
2020-12-27 12:45:11 -08:00
Eric Huss
cf2459f730
Merge pull request #1393 from apatniv/fixing_error
...
Missing chapters Error Reporting: Add file name
2020-12-14 08:33:36 -08:00
Kousuke Takaki
6bcabcbb6b
Improve error message
2020-12-14 16:11:01 +09:00
apatniv
ef993e8cc2
Run rust formmater
2020-12-05 20:27:03 -05:00
apatniv
a3a5386da0
Add more context regarding which missing file creation failed
2020-12-05 20:17:45 -05:00
avitex
942cc12a74
Add chapter name to search result breadcrumbs
2020-11-25 14:46:49 +11:00
Eric Huss
552e3378cf
Merge pull request #1378 from daynin/serialize-build-section
...
allow to serialize the "build" section
2020-11-12 10:41:12 -08:00
Sergey Golovin
7c0ddff96a
allow to serialize the "build" section
2020-11-12 19:32:32 +03:00
Eric Huss
07e72757d3
Merge pull request #1376 from dtolnay/html
...
Escape `<` and `>` in rendered toc to match handlebars' escaping in <title>
2020-11-10 14:46:24 -08:00
Eric Huss
58f66a146d
Merge pull request #1375 from dtolnay/playground
...
Fix stray spacing after #playground code
2020-11-10 14:06:09 -08:00
Eric Huss
643d5ecc5c
Merge pull request #1285 from FrankHB/patch-1
...
Handled UTF-8 BOM
2020-11-10 14:02:01 -08:00
David Tolnay
c712ba7aab
Escape <> in rendered toc
2020-11-08 22:26:30 -08:00
David Tolnay
1450070f73
Fix stray spacing after #playground code
2020-11-05 21:43:04 -08:00
FrankHB
9e9cf49c50
Added a test.
...
Signed-off-by: FrankHB <frankhb1989@gmail.com>
2020-10-07 22:50:25 +08:00
FrankHB
780fb979a0
Avoided the redundant allocation.
...
Signed-off-by: FrankHB <frankhb1989@gmail.com>
2020-09-29 18:01:06 +08:00
Camelid
b77942d3c8
Rename `book-example` to `guide` ( #1336 )
...
`book-example` is a bit of a strange name given that it's not just an
example.
2020-09-23 03:16:09 +02:00
Eric Huss
e6ac8ecdd9
Fix print icon.
2020-09-22 13:24:13 -07:00
Ross MacArthur
e0b247e9d6
Add config option to disable print html, css, and icon
2020-09-22 11:40:02 -07:00
ifeanyi
b349e8abc9
Fix windows typo
2020-09-09 17:57:45 +02:00
ifeanyi
e225586953
Resolve full file paths when copying files
...
Currently, the `copy_files` function doesn't support symlink files due to
its use of `DirEntry::metadata` - To avoid this issue, this patch
resolves the file path first before checking for metadata.
Fixes #1157
2020-09-09 17:42:14 +02:00
Eric Huss
4df9ec90af
Merge pull request #1307 from camelid/prefer-bundled-scp
...
Prefer bundled version of Source Code Pro
2020-09-06 10:58:23 -07:00
Camelid
73cabeb904
Remove local version from `@font-face`
...
It's unlikely that the bundled version wouldn't load, and it's
especially unlikely that the page would load but the bundled version
would not.
Also, if it doesn't load, it should fall back to another monospace font,
which is fine.
2020-09-06 10:34:11 -07:00
Eric Huss
4b773024ae
Merge pull request #1309 from nerosnm/add-missing-space
...
Fix missing space before draft chapter titles
2020-09-06 09:40:55 -07:00
Eric Huss
33ea661350
Merge pull request #1310 from dtolnay/nojekyll
...
End .nojekyll file with newline
2020-09-06 09:21:59 -07:00
Eric Huss
1b18740b56
Merge pull request #1311 from dtolnay/cname
...
Support emitting CNAME file for publishing at a custom domain
2020-09-06 09:21:29 -07:00
Eric Huss
fd59dc73e5
Adjust wording
2020-09-06 09:11:53 -07:00
Gus Wynn
5ea8e55aea
collect all test failures before failing
2020-09-03 18:36:51 -07:00
David Tolnay
1acf23ff73
Support emitting CNAME file for publishing at a custom domain
2020-09-02 11:24:48 -07:00
David Tolnay
69cc1fa005
End .nojekyll file with newline
...
Before:
/path/to$ cat book/.nojekyll
This file makes sure that Github Pages doesn't process mdBook's output./path/to$ ▎
After:
/path/to$ cat book/.nojekyll
This file makes sure that Github Pages doesn't process mdBook's output.
/path/to$ ▎
2020-09-02 11:06:19 -07:00
Søren Mortensen
2fb489137b
Wrap draft chapter titles in a <div>
...
Fixes the problem of a missing space before the title of draft chapters,
due to the title not being wrapped in an `<a></a>`.
2020-08-31 10:00:03 +01:00
Camelid
4d9eb9b4b4
Prefer bundled version of Source Code Pro
...
This prevents an issue with Firefox 80 on macOS that prevents syntax
highlighting from working.
2020-08-29 13:22:51 -07:00
Eric Huss
3d44553671
Merge pull request #1293 from Evian-Zhang/master
...
allow space in SUMMARY.md's link destination
2020-08-08 08:19:06 -07:00
Evian-Zhang
9d5c454e47
delete '+' replacement and use cargo fmt to format
2020-08-08 15:13:22 +08:00
Eric Huss
a00e7d1769
Merge pull request #1272 from ehuss/fix-favicon-link
...
Fix favicon when only one is overridden.
2020-08-07 08:34:46 -07:00