-
-
Notifications
You must be signed in to change notification settings - Fork 292
Introduce overlayStyleMode option to manage overlay styling behavior
#470
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
ertgl
wants to merge
5
commits into
webpack:main
Choose a base branch
from
ertgl:overlay-styling-mode
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
5 commits
Select commit
Hold shift + click to select a range
a4e0963
feat: add `overlayStyleMode` option to control style injection behavior
ertgl 2c3adfa
docs: add examples for `overlayStyleMode` usage
ertgl 046eec0
style: format code
ertgl fee93b3
chore(examples): include `csp` and `headless-styling` scripts in `exa…
ertgl e45605b
docs(example): update `README.md` with CSP and headless-styling examples
ertgl File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -15,7 +15,6 @@ workflows: | |
| tags: | ||
| only: /.*/ | ||
|
|
||
|
|
||
| commands: | ||
| setup: | ||
| steps: | ||
|
|
||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,36 @@ | ||
| .webpack-hot-middleware-clientOverlay { | ||
| background: rgba(0, 0, 0, 0.85); | ||
| color: #e8e8e8; | ||
| line-height: 1.6; | ||
| white-space: pre; | ||
| font-family: Menlo, Consolas, monospace; | ||
| font-size: 13px; | ||
| position: fixed; | ||
| z-index: 9999; | ||
| padding: 10px; | ||
| left: 0; | ||
| right: 0; | ||
| top: 0; | ||
| bottom: 0; | ||
| overflow: auto; | ||
| dir: ltr; | ||
| text-align: left; | ||
| } | ||
|
|
||
| .webpack-hot-middleware-clientOverlay__problem-group { | ||
| margin-bottom: 26px; | ||
| } | ||
|
|
||
| .webpack-hot-middleware-clientOverlay__problem { | ||
| color: #000000; | ||
| padding: 3px 6px; | ||
| border-radius: 4px; | ||
| } | ||
|
|
||
| .webpack-hot-middleware-clientOverlay__problem--error { | ||
| background-color: #ff3348; | ||
| } | ||
|
|
||
| .webpack-hot-middleware-clientOverlay__problem--warning { | ||
| background-color: #ffd30e; | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,5 @@ | ||
| console.log('Testing CSP...'); | ||
|
|
||
| if (module.hot) { | ||
| module.hot.accept(); | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,5 @@ | ||
| console.log('Testing headless styling...'); | ||
|
|
||
| if (module.hot) { | ||
| module.hot.accept(); | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,20 @@ | ||
| <!DOCTYPE html> | ||
| <html> | ||
| <head> | ||
| <meta charset="utf-8" /> | ||
| <meta name="viewport" content="width=device-width, initial-scale=1" /> | ||
| <title>Webpack Hot Middleware CSP Example</title> | ||
| </head> | ||
| <body> | ||
| <div id="app" data-overlay-style-mode="headless"> | ||
| <p id="time">Date</p> | ||
| <input | ||
| type="text" | ||
| size="40" | ||
| placeholder="Type something in here to prove state isn't lost" | ||
| /> | ||
| </div> | ||
| <script src="/client.js"></script> | ||
| <script src="/csp.js"></script> | ||
| </body> | ||
| </html> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,39 @@ | ||
| <!DOCTYPE html> | ||
| <html> | ||
| <head> | ||
| <meta charset="utf-8" /> | ||
| <meta name="viewport" content="width=device-width, initial-scale=1" /> | ||
| <title>Webpack Hot Middleware Headless Styling Example</title> | ||
| <style> | ||
| .webpack-hot-middleware-clientOverlay__problem-group { | ||
| margin-bottom: 26px; | ||
| } | ||
|
|
||
| .webpack-hot-middleware-clientOverlay__problem { | ||
| color: #ffffff; | ||
| padding: 3px 6px; | ||
| border-radius: 4px; | ||
| } | ||
|
|
||
| .webpack-hot-middleware-clientOverlay__problem--error { | ||
| background-color: #000000; | ||
| } | ||
|
|
||
| .webpack-hot-middleware-clientOverlay__problem--warning { | ||
| background-color: #000000; | ||
| } | ||
| </style> | ||
| </head> | ||
| <body> | ||
| <div id="app" data-overlay-style-mode="headless"> | ||
| <p id="time">Date</p> | ||
| <input | ||
| type="text" | ||
| size="40" | ||
| placeholder="Type something in here to prove state isn't lost" | ||
| /> | ||
| </div> | ||
| <script src="/client.js"></script> | ||
| <script src="/headless-styling.js"></script> | ||
| </body> | ||
| </html> |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've added a description of why we install
file-loaderandstyle-loaderin the example package.