Skip to content

Commit ccba267

Browse files
authored
Upgraded docusaurus to latest version and updated custom overlay doc (#554)
1 parent 195942e commit ccba267

File tree

5 files changed

+14297
-10811
lines changed

5 files changed

+14297
-10811
lines changed

docs/docs/styling/custom-overlay.md

+4-4
Original file line numberDiff line numberDiff line change
@@ -3,17 +3,17 @@ sidebar_position: 4
33
---
44

55
# Custom Overlay
6-
The overlay can be customised by providing one or more custom CSS classes to augment or overwrite the default style.
6+
The overlay can be customised by providing one or more custom CSS classes to augment or overwrite the default style. Note that you may need to add the `!important` keyword to some properties due the the use of scoped CSS, which can create a higher specificity for the default styles.
77

8-
If you wanted the overlay to be a transparent red you could define the following CSS class.
8+
The following example shows how to define a CSS class that overrides the default overlay background colour.
99

1010
```css title="my-app.css"
1111
.custom-modal-overlay {
12-
background-color: rgba(255, 0, 0, 0.5);
12+
background-color: rgba(255, 0, 0, 0.5) !important;
1313
}
1414
```
1515

16-
Then apply that to your modal with either of the following options.
16+
This can then be applied to your modal with either of the following options.
1717

1818
#### Configuring for all modals
1919
```razor

docs/docusaurus.config.js

+3-4
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
11
// @ts-check
22
// Note: type annotations allow type checking and IDEs autocompletion
33

4-
const lightCodeTheme = require('prism-react-renderer/themes/github');
5-
const darkCodeTheme = require('prism-react-renderer/themes/dracula');
4+
import {themes as prismThemes} from 'prism-react-renderer';
65

76
/** @type {import('@docusaurus/types').Config} */
87
const config = {
@@ -90,8 +89,8 @@ const config = {
9089
copyright: `Copyright © ${new Date().getFullYear()} Blazored`,
9190
},
9291
prism: {
93-
theme: require('prism-react-renderer/themes/github'),
94-
darkTheme: require('prism-react-renderer/themes/vsDark'),
92+
theme: prismThemes.github,
93+
darkTheme: prismThemes.vsDark,
9594
additionalLanguages: ['csharp', 'cshtml']
9695
},
9796
}),

0 commit comments

Comments
 (0)