Skip to content

Commit c32b642

Browse files
committed
wip - crpa link
1 parent a16410b commit c32b642

File tree

4 files changed

+63
-4
lines changed

4 files changed

+63
-4
lines changed

src/website/ccpa-modal.js

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
export function CCPAModal() {
2+
document.addEventListener("DOMContentLoaded", function () {
3+
document.querySelector("#open-ccpa").addEventListener("click", () => {
4+
document.querySelector("#ccpa-modal").style.display = "block";
5+
});
6+
7+
document.querySelector("#close-ccpa").addEventListener("click", () => {
8+
document.querySelector("#ccpa-modal").style.display = "none";
9+
});
10+
});
11+
}

src/website/index.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ import {
1010
shareJwtButton,
1111
shareJwtTextElement,
1212
} from "./dom-elements.js";
13+
import { CCPAModal } from "./ccpa-modal.js";
1314

1415
import queryString from "querystring";
1516

@@ -52,4 +53,5 @@ setupTokenEditor();
5253
parseLocationQuery();
5354
setupHighlighting();
5455
setupJwtCounter();
55-
setupShareJwtButton(shareJwtButton, shareJwtTextElement);
56+
setupShareJwtButton(shareJwtButton, shareJwtTextElement);
57+
CCPAModal();

stylus/website/index.styl

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1240,6 +1240,11 @@ footer
12401240
color white
12411241
img
12421242
margin-left 5px
1243+
.as-anchor
1244+
color: white
1245+
background: none
1246+
padding: 0
1247+
border: none
12431248

12441249
.logo
12451250
height 18px
@@ -1265,6 +1270,38 @@ footer
12651270
+breakpoint("tablet")
12661271
text-align right
12671272

1273+
#ccpa-modal
1274+
display: none
1275+
position: fixed
1276+
top: 50%
1277+
left: 50%
1278+
transform: translate(-50%, -50%)
1279+
width: 90%
1280+
height: auto
1281+
background: white
1282+
z-index: 10000
1283+
color: black
1284+
border-radius: 16px
1285+
padding: 24px
1286+
text-align: left
1287+
+breakpoint("tablet")
1288+
width: 50%
1289+
#close-ccpa
1290+
background: none
1291+
border: none
1292+
padding: 0
1293+
position: absolute
1294+
top: 20px
1295+
right: 30px
1296+
font-size: 24px
1297+
line-height: 24px
1298+
.settings
1299+
color: #635dff
1300+
appearance: none
1301+
border: none
1302+
background: none
1303+
padding: 0
1304+
12681305
.warning
12691306
display block
12701307
width 100%

views/website/layout.pug

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -37,14 +37,14 @@ html(lang='en')
3737

3838
// Chrome extension link, required for inline installs
3939
link(rel="chrome-webstore-item", href="https://chrome.google.com/webstore/detail/ppmmlchacdbknfphdeafcbmklcghghmd")
40-
40+
4141
body
4242
// Google Tag Manager (noscript)
4343
noscript
4444
iframe(src='https://www.googletagmanager.com/ns.html?id=GTM-W7FRLJ', height='0', width='0', style='display:none;visibility:hidden')
45-
45+
4646
include ./navigation.pug
47-
47+
4848
block content
4949

5050
footer
@@ -60,6 +60,15 @@ html(lang='en')
6060
a(href='https://auth0.com/developers/', target="_blank")
6161
| Supported by
6262
img(src='/img/ico_logo.svg' alt='Supported by Auth0 - JWT.io Token Based Authentication').logo
63+
#ccpa-modal
64+
button#close-ccpa x
65+
h3 Your Privacy Choices
66+
p Under the California Consumer Privacy Act (CCPA), California residents have the right to opt out of certain sharing of their personal information with third-party ad partners. We may share personal information with third-party ad partners, such as through cookies or by providing lists of email addresses for potential customers, so that we can reach them across the web with relevant ads.
67+
p If you wish to opt out of this sharing of your personal data in connection with cookies, please update your
68+
button.settings(onClick="window.OneTrust.ToggleInfoDisplay()") cookie settings.
69+
p If you wish to opt out of email-based sharing, provide your email address at
70+
a.settings(href="") this link.
71+
6372
.column.pull-request
6473
span Missing something?
6574
a(href='https://github.com/jsonwebtoken/jsonwebtoken.github.io/tree/master/views', target="_blank") Send a Pull Request

0 commit comments

Comments
 (0)