-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathindex.html
More file actions
200 lines (198 loc) · 7.03 KB
/
Copy pathindex.html
File metadata and controls
200 lines (198 loc) · 7.03 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Sign in to Solid</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="color-scheme" content="light">
<meta name="description" content="Universal one-click sign-in for Solid pods. Click the button — you're at your pod.">
<link rel="icon" type="image/svg+xml" href="./solid-emblem.svg">
<!-- Open Graph -->
<meta property="og:title" content="JSS SSO — one click, you're at your pod">
<meta property="og:description" content="Universal Solid login. No username, no IdP picker, no friction.">
<meta property="og:type" content="website">
<style>
:root {
color-scheme: light;
--bg: #fafbfc;
--fg: #1f2328;
--accent: #7c4dff;
--accent-2: #9d7bff;
--accent-hover: #6a3de8;
--muted: #656d76;
--error: #cf222e;
--error-bg: #fff5f5;
--error-border: #ffd7d5;
--ok: #1a7f37;
}
* { box-sizing: border-box; }
html, body {
margin: 0; padding: 0; height: 100%;
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
background: var(--bg); color: var(--fg);
}
body {
background:
radial-gradient(60rem 30rem at 50% -10%, rgba(124, 77, 255, 0.06), transparent 70%),
var(--bg);
}
main {
min-height: 100vh;
display: flex; flex-direction: column;
align-items: center; justify-content: center;
padding: 2rem; gap: 2rem;
text-align: center;
}
.card {
width: 100%; max-width: 28rem;
background: white;
border: 1px solid #e7e9ec;
border-radius: 20px;
padding: clamp(2rem, 6vw, 3rem) clamp(1.25rem, 5vw, 2.5rem);
box-shadow: 0 12px 40px rgba(31, 35, 40, 0.08);
display: flex; flex-direction: column;
align-items: center; gap: 1.75rem;
}
header {
display: flex; flex-direction: column;
align-items: center; gap: 0.9rem;
}
.logo {
width: 64px; height: auto; display: block;
filter: drop-shadow(0 6px 16px rgba(124, 77, 255, 0.35));
}
h1 {
font-size: clamp(1.5rem, 4vw, 1.9rem);
margin: 0; font-weight: 600; letter-spacing: -0.02em;
}
p.tagline {
color: var(--muted); margin: 0; max-width: 32rem;
font-size: 0.95rem; line-height: 1.55;
}
button#signin {
font-size: 1.15rem;
padding: 0.95rem 2.5rem;
background: linear-gradient(180deg, var(--accent-2), var(--accent));
color: white;
border: none; border-radius: 999px;
cursor: pointer;
font-weight: 600;
transition: background 0.15s, transform 0.1s, box-shadow 0.15s;
min-width: 14rem;
box-shadow: 0 2px 8px rgba(124, 77, 255, 0.25), inset 0 1px 0 rgba(255, 255, 255, 0.2);
}
button#signin:hover {
background: linear-gradient(180deg, var(--accent), var(--accent-hover));
transform: translateY(-1px);
box-shadow: 0 6px 16px rgba(124, 77, 255, 0.3);
}
button#signin:active { transform: translateY(0) scale(0.98); }
button#signin:focus-visible { outline: 3px solid #c4b5fd; outline-offset: 3px; }
button#signin:disabled {
opacity: 0.75; cursor: progress;
transform: none; box-shadow: 0 2px 8px rgba(124, 77, 255, 0.25);
}
button#signin[aria-busy="true"]::before {
content: '';
display: inline-block;
width: 1em; height: 1em;
margin-right: 0.6em;
vertical-align: -0.12em;
border: 2px solid rgba(255, 255, 255, 0.35);
border-top-color: white;
border-radius: 50%;
animation: spin 0.7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.linkish {
background: none; border: none; padding: 0;
color: var(--muted); font-size: 0.85rem;
cursor: pointer;
text-decoration: underline; text-underline-offset: 3px;
}
.linkish:hover { color: var(--accent); }
.linkish:focus-visible { outline: 2px solid #c4b5fd; outline-offset: 2px; border-radius: 4px; }
#manual {
width: 100%; margin: 0;
display: flex; flex-wrap: wrap; gap: 0.6rem;
justify-content: center;
}
#manual[hidden] { display: none; }
#manual input {
flex: 1 1 14rem;
font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
font-size: 0.9rem;
padding: 0.65rem 0.9rem;
border: 1px solid #d0d7de; border-radius: 10px;
color: var(--fg); min-width: 0;
}
#manual input:focus-visible { outline: 2px solid #c4b5fd; border-color: var(--accent); }
#manual button {
font-size: 0.95rem; font-weight: 600;
padding: 0.65rem 1.4rem;
background: var(--accent); color: white;
border: none; border-radius: 10px; cursor: pointer;
}
#manual button:hover { background: var(--accent-hover); }
#manual button:disabled { opacity: 0.6; cursor: progress; }
#manual button:focus-visible { outline: 2px solid #c4b5fd; outline-offset: 2px; }
#manual .warn {
flex-basis: 100%; margin: 0;
font-size: 0.8rem; color: #9a6700;
}
#status {
color: var(--muted); font-size: 0.95rem;
min-height: 4rem; max-width: 100%;
}
#status.error {
color: var(--error);
background: var(--error-bg);
border: 1px solid var(--error-border);
border-radius: 12px;
padding: 0.9rem 1.4rem;
}
#status.ok { color: var(--ok); font-weight: 500; }
#status ul.help-links {
list-style: none; padding: 0; margin: 1rem 0 0;
display: flex; flex-direction: column; gap: 0.5rem;
}
#status ul.help-links a {
color: var(--accent); text-decoration: underline;
text-underline-offset: 3px;
}
#status ul.help-links a:hover { color: var(--accent-hover); }
#status ul.help-links a:focus-visible { outline: 2px solid #c4b5fd; outline-offset: 2px; border-radius: 4px; }
footer {
color: var(--muted); font-size: 0.85rem;
}
footer a { color: inherit; }
</style>
</head>
<body>
<main>
<div class="card">
<header>
<img class="logo" src="./solid-emblem.svg" alt="" aria-hidden="true">
<h1>Sign in to Solid</h1>
<p class="tagline">One click. We resolve your Nostr / WebID. You land at your pod.</p>
</header>
<button id="signin">Sign in</button>
<button id="alt-toggle" type="button" class="linkish">No signer? Paste a key instead</button>
<form id="manual" hidden>
<input id="manual-key" autocomplete="off" spellcheck="false"
placeholder="npub1…, nsec1…, or 64-hex pubkey"
aria-label="Nostr public or private key">
<button type="submit">Go</button>
<p class="warn">Proof of concept — paste test keys only. Real keys belong in a signer.</p>
</form>
<div id="status" aria-live="polite"></div>
</div>
<footer>
<a href="https://github.com/JavaScriptSolidServer/sso">source</a>
·
<a href="https://github.com/JavaScriptSolidServer/JavaScriptSolidServer">JSS</a>
</footer>
</main>
<script type="module" src="./login.js"></script>
</body>
</html>