Skip to content

Commit abf672b

Browse files
authored
Add modals z-index (#876)
* Add modals z-index * Fix typo in docs
1 parent fd032ee commit abf672b

File tree

4 files changed

+6
-2
lines changed

4 files changed

+6
-2
lines changed

packages/core/README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -414,6 +414,8 @@ The Onboard styles can customized via [CSS variables](https://developer.mozilla.
414414
/* SHADOWS */
415415
--onboard-shadow-1: 0px 4px 12px rgba(0, 0, 0, 0.1);
416416
--onboard-shadow-2: inset 0px -1px 0px rgba(0, 0, 0, 0.1);
417+
418+
--onboard-modal-z-index
417419
}
418420
```
419421

packages/core/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@web3-onboard/core",
3-
"version": "2.0.9",
3+
"version": "2.0.10",
44
"scripts": {
55
"build": "rollup -c",
66
"dev": "rollup -c -w",

packages/core/src/index.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -174,6 +174,8 @@ function mountApp() {
174174
/* SHADOWS */
175175
--shadow-1: 0px 4px 12px rgba(0, 0, 0, 0.1);
176176
--shadow-2: inset 0px -1px 0px rgba(0, 0, 0, 0.1);
177+
178+
--modal-z-index: 10;
177179
}
178180
</style>
179181
`

packages/core/src/views/shared/Modal.svelte

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
top: 0;
2626
left: 0;
2727
pointer-events: none;
28-
z-index: 10;
28+
z-index: var(--onboard-modal-z-index, var(--modal-z-index));
2929
}
3030
3131
.background {

0 commit comments

Comments
 (0)