Skip to content

Commit 922d6c0

Browse files
authored
chore(docs): change color palette in code snippets for darmode in documentation (#1029)
## Description This PR changes color palette to the brighter one for dark-mode documentation. ### Introduces a breaking change? - [ ] Yes - [x] No ### Type of change - [ ] Bug fix (change which fixes an issue) - [ ] New feature (change which adds functionality) - [x] Documentation update (improves or adds clarity to existing documentation) - [ ] Other (chores, tests, code style improvements etc.) ### Tested on - [ ] iOS - [ ] Android ### Testing instructions Build documentation locally, and check that is more contrast and easy-to-read ### Screenshots Before: <img width="585" height="516" alt="image" src="https://github.com/user-attachments/assets/0460ff3f-8a58-4888-bbcc-26c5135bcf06" /> After: <img width="585" height="516" alt="image" src="https://github.com/user-attachments/assets/1dff695c-16e1-4b19-824e-7f2a639b094d" /> ### Related issues Closes #979 ### Checklist - [x] I have performed a self-review of my code - [ ] I have commented my code, particularly in hard-to-understand areas - [x] I have updated the documentation accordingly - [x] My changes generate no new warnings ### Additional notes <!-- Include any additional information, assumptions, or context that reviewers might need to understand this PR. -->
1 parent 96ec22c commit 922d6c0

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

docs/src/theme/CodeBlock/highlighting-dark.js

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,14 +3,14 @@ const darkTheme = require('prism-react-renderer').themes.github;
33
module.exports = {
44
...darkTheme,
55
plain: {
6-
color: 'var(--swm-navy-light-40)',
6+
color: 'var(--swm-navy-light-10)',
77
},
88
styles: [
99
...darkTheme.styles,
1010
{
1111
types: ['comment', 'prolog', 'doctype', 'cdata'],
1212
style: {
13-
color: 'var(--swm-navy-light-60)',
13+
color: 'var(--swm-navy-light-40)',
1414
fontStyle: 'italic',
1515
},
1616
},
@@ -24,13 +24,13 @@ module.exports = {
2424
// eslint-disable-next-line @cspell/spellchecker
2525
types: ['string', 'property', 'atrule', 'selector', 'tag'],
2626
style: {
27-
color: 'var(--swm-navy-light-40)',
27+
color: 'var(--swm-green-dark-80)',
2828
},
2929
},
3030
{
3131
types: ['punctuation'],
3232
style: {
33-
color: 'var(--swm-green-light-80)',
33+
color: 'var(--swm-navy-light-20)',
3434
},
3535
},
3636
{
@@ -48,19 +48,19 @@ module.exports = {
4848
'attr-value',
4949
],
5050
style: {
51-
color: 'var(--swm-red-light-80)',
51+
color: 'var(--swm-red-dark-80)',
5252
},
5353
},
5454
{
5555
types: ['function', 'function-variable', 'deleted'],
5656
style: {
57-
color: 'var(--swm-purple-light-80)',
57+
color: 'var(--swm-purple-dark-80)',
5858
},
5959
},
6060
{
6161
types: ['property', 'module', 'attr-name', 'keyword'],
6262
style: {
63-
color: 'var(--swm-blue-light-80)',
63+
color: 'var(--swm-blue-dark-80)',
6464
},
6565
},
6666
],

0 commit comments

Comments
 (0)