Skip to content

Commit 0cb1486

Browse files
committed
Remove critical CSS, update package.json
1 parent 035c415 commit 0cb1486

File tree

10 files changed

+11
-12
lines changed

10 files changed

+11
-12
lines changed

README.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@ I didn't like sending 100KB+ for a simple cookie consent solution so I wrote thi
1414
- Simple flat configuration object
1515
- Injects scripts when granular consent is granted (`<script data-consent="analytics" type="text/plain" src="..."></script>`)
1616
- Injects embedded `<script>` from script tags with `src` properties on onload (tidier markup)
17-
- Works without CSS (thanks to `<dialog>` and `<details>`)
1817
- Mobile-first
1918
- Browser support: >= 2% browserlist (No IE support, but its not impossible)
2019
- Written with latest CSS / JS features and targetted to >= 2% using browserlist

biscuitman.css

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,14 @@
33
https://github.com/replete/biscuitman
44
55
This stylesheet is the source stylesheet
6-
and is processed to un-nested native CSS nesting
7-
and include vendor
6+
Use a version in /dist/ for improved compatibility
87
*/.biscuitman {
98
--t: #444;
109
--b: #fff;
1110
--c: #105d89;
1211

12+
position:fixed;
13+
bottom:0;
1314
width:100%;
1415
padding:20px;
1516
background:var(--b);

biscuitman.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,6 @@
4949

5050
function render() {
5151
ui.classList.add(bm)
52-
ui.style = 'position:fixed;background:#fff;bottom:0' // critical CSS
5352
ui.innerHTML = `
5453
<article>
5554
<b>${o.title}</b>

dist/biscuitman.css

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@
88
width: 100%;
99
padding: 20px;
1010
font-family: -apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Helvetica, Arial, sans-serif;
11+
position: fixed;
12+
bottom: 0;
1113
box-shadow: 0 -2px 10px #00000029;
1214
}
1315

dist/biscuitman.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,6 @@
2929
let dialog;
3030
function render() {
3131
ui.classList.add(bm);
32-
ui.style = 'position:fixed;background:#fff;bottom:0' // critical CSS
33-
;
3432
ui.innerHTML = `
3533
<article>
3634
<b>${o.title}</b>

dist/biscuitman.min.css

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)