@tensile-tools/auth-client 0.0.0-stage → 0.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (44) hide show
  1. package/LICENSE +202 -0
  2. package/README.md +62 -2
  3. package/dist/client.d.ts +569 -0
  4. package/dist/client.js +637 -0
  5. package/dist/devtools.d.ts +12 -0
  6. package/dist/devtools.js +44 -0
  7. package/dist/elements/account.d.ts +63 -0
  8. package/dist/elements/account.js +331 -0
  9. package/dist/elements/approvals.d.ts +61 -0
  10. package/dist/elements/approvals.js +252 -0
  11. package/dist/elements/auth.d.ts +48 -0
  12. package/dist/elements/auth.js +238 -0
  13. package/dist/elements/base.d.ts +176 -0
  14. package/dist/elements/base.js +540 -0
  15. package/dist/elements/config.d.ts +70 -0
  16. package/dist/elements/config.js +119 -0
  17. package/dist/elements/format.d.ts +32 -0
  18. package/dist/elements/format.js +67 -0
  19. package/dist/elements/index.d.ts +21 -0
  20. package/dist/elements/index.js +31 -0
  21. package/dist/elements/qr.d.ts +9 -0
  22. package/dist/elements/qr.js +302 -0
  23. package/dist/elements/returnto.d.ts +17 -0
  24. package/dist/elements/returnto.js +63 -0
  25. package/dist/elements/setup.d.ts +70 -0
  26. package/dist/elements/setup.js +316 -0
  27. package/dist/elements/styles.d.ts +3 -0
  28. package/dist/elements/styles.js +194 -0
  29. package/dist/elements/text.d.ts +21 -0
  30. package/dist/elements/text.js +302 -0
  31. package/dist/fonts/OFL-geist-mono.txt +93 -0
  32. package/dist/fonts/OFL-geist.txt +93 -0
  33. package/dist/fonts/OFL-inter.txt +93 -0
  34. package/dist/fonts/README.md +18 -0
  35. package/dist/fonts/geist-mono.woff2 +0 -0
  36. package/dist/fonts/geist.woff2 +0 -0
  37. package/dist/fonts/inter.woff2 +0 -0
  38. package/dist/index.d.ts +4 -0
  39. package/dist/index.js +5 -0
  40. package/dist/problem.d.ts +54 -0
  41. package/dist/problem.js +40 -0
  42. package/dist/webauthn.d.ts +46 -0
  43. package/dist/webauthn.js +102 -0
  44. package/package.json +51 -4
@@ -0,0 +1,302 @@
1
+ // Every piece of text the elements show, in English, by key. Override any
2
+ // key with the `text` option. In a template:
3
+ //
4
+ // - {name} is a value, such as {appName} or {count};
5
+ // - [words] are connecting words, shown in grey in a sentence headline;
6
+ // - *words* are good news, shown in green;
7
+ // - !words! are a warning, shown in orange.
8
+ //
9
+ // This module has no DOM, so the tests run it in Node.
10
+ export const english = Object.freeze({
11
+ // Shared
12
+ 'or': 'or',
13
+ 'loading': 'Loading…',
14
+ 'tryAgain': 'Try again',
15
+ 'showAgain': 'Show it again',
16
+ 'copy': 'Copy',
17
+ 'copied': 'Copied',
18
+ 'copyFailed': 'Select the codes and copy them',
19
+ 'download': 'Download',
20
+ 'continue': 'Continue',
21
+ 'cancel': 'Cancel',
22
+ 'you': 'You',
23
+ 'anAgent': 'An agent',
24
+ 'passkey.unsupported': 'This browser can’t use passkeys here.',
25
+ 'passkey.none': 'No passkey came back. You may have closed the prompt, or this device has no passkey for {appName}.',
26
+ 'passkey.exists': 'This device already has a passkey for {appName}. Sign in instead.',
27
+ 'throttled': 'Too many tries. Try again in {seconds} seconds.',
28
+ 'failed': 'That didn’t work. Try again.',
29
+ 'code.label': 'Code from your app',
30
+ 'code.placeholder': '6 digits',
31
+ 'code.bad': 'Enter the 6 digits your app shows.',
32
+ 'time.now': 'Active now',
33
+ 'time.minutes': 'Used {count} min ago',
34
+ 'time.hours': 'Used {count} h ago',
35
+ 'time.yesterday': 'Used yesterday',
36
+ 'time.on': 'Used {date}',
37
+ 'time.today': 'Today, {time}',
38
+ 'time.yesterdayAt': 'Yesterday, {time}',
39
+ 'time.dateAt': '{date}, {time}',
40
+ // Sign in
41
+ 'signIn.headline': 'Welcome back [to {appName}.]',
42
+ 'signIn.title': 'Sign in to {appName}',
43
+ 'signIn.passkey': 'Sign in with passkey',
44
+ 'signIn.email': 'Continue with email',
45
+ 'signIn.emailLabel': 'Email',
46
+ 'signIn.emailPlaceholder': 'you@example.com',
47
+ 'signIn.autofillHint': 'Passkeys appear in this field’s autofill',
48
+ 'signIn.change': 'Change',
49
+ 'signIn.passwordLabel': 'Password',
50
+ 'signIn.submit': 'Sign in',
51
+ 'signIn.forgot': 'Forgot your password?',
52
+ 'signIn.forgotSent': 'If {email} has an account, a link to reset its password is on its way.',
53
+ 'signIn.emailMissing': 'Enter your email address.',
54
+ 'signIn.code.headline': 'One more step. [Enter the code from your app.]',
55
+ 'signIn.code.title': 'Enter the code from your app',
56
+ 'signIn.recovery': 'Use a recovery code',
57
+ 'signIn.recoveryLabel': 'Recovery code',
58
+ 'signIn.useCode': 'Use the code from your app',
59
+ 'signIn.signUp': 'Create an account',
60
+ 'signIn.done': 'You’re signed in to {appName}.',
61
+ 'signIn.doneChip': 'Signed in',
62
+ // Sign up
63
+ 'signUp.headline': 'Create your [{appName} account.]',
64
+ 'signUp.title': 'Create your account',
65
+ 'signUp.emailLabel': 'Email',
66
+ 'signUp.passwordLabel': 'Password',
67
+ 'signUp.passwordHint': 'At least 15 characters. A long phrase works well.',
68
+ 'signUp.passkey': 'Create a passkey',
69
+ 'signUp.password': 'Create account',
70
+ 'signUp.usePassword': 'Use a password instead',
71
+ 'signUp.usePasskey': 'Use a passkey instead',
72
+ 'signUp.signIn': 'Sign in instead',
73
+ 'signUp.done': 'Welcome to {appName}.',
74
+ 'signUp.doneChip': 'Account created',
75
+ 'signUp.checkEmail': 'Check your email. A link to confirm {email} is on its way.',
76
+ 'signUp.checkEmailChip': 'Almost there',
77
+ // Step-up
78
+ 'stepUp.headline': 'Confirm it’s you [{action}] {subject}.',
79
+ 'stepUp.headlinePlain': 'Confirm it’s you [to continue.]',
80
+ 'stepUp.title': 'Confirm it’s you',
81
+ 'stepUp.passkey': 'Confirm with passkey',
82
+ 'stepUp.password': 'Confirm',
83
+ 'stepUp.passwordLabel': 'Password',
84
+ 'stepUp.done': 'Confirmed. You can continue.',
85
+ 'stepUp.doneChip': 'Confirmed',
86
+ 'stepUp.cancelled': 'Nothing changed.',
87
+ 'stepUp.cancelledChip': 'Cancelled',
88
+ // Approve an agent's action
89
+ 'approval.headline': '{agent} [wants to] {action}',
90
+ 'approval.pay': '{agent} [wants to pay]',
91
+ 'approval.payee': '[to] {payee}[{for}.]',
92
+ 'approval.payFor': ' for {for}',
93
+ 'approval.title': '{agent} asks for your approval',
94
+ 'approval.fine': 'Runs once. Expires at {time}.',
95
+ 'approval.signed': 'Your passkey signs this exact request: “{summary}”',
96
+ 'approval.loading': 'A request from your agent',
97
+ 'approval.approve': 'Approve',
98
+ 'approval.decline': 'Decline',
99
+ 'approval.approved': 'Approved at {time}. {agent} can do this once.',
100
+ 'approval.approvedChip': 'Approved',
101
+ 'approval.declined': '{agent} can’t do this. It can ask again.',
102
+ 'approval.declinedChip': 'Declined',
103
+ 'approval.gone': 'It expired, or it was already approved or declined.',
104
+ 'approval.goneChip': 'Closed',
105
+ 'approval.goneHeadline': 'This request [is closed.]',
106
+ 'approval.goneTitle': 'This request is closed',
107
+ 'signedOut.headline': 'You’re signed out. [Sign in to continue.]',
108
+ 'signedOut.title': 'You’re signed out',
109
+ 'signedOut.other': 'Sign in another way',
110
+ 'signedOut.reload': 'Reload this page to sign in again.',
111
+ 'approval.signIn': 'Sign in [to review this request.]',
112
+ 'approval.signInTitle': 'Sign in to review this request',
113
+ 'approval.signInFine': 'An agent asks for your approval. After you sign in, the request shows here.',
114
+ // The inbox of approvals
115
+ 'approvals.none': 'No requests [are waiting for you.]',
116
+ 'approvals.one': '1 request [is waiting for you.]',
117
+ 'approvals.many': '{count} requests [are waiting for you.]',
118
+ 'approvals.title': 'Requests from your agents',
119
+ 'approvals.item': '{agent} wants to {action}',
120
+ 'approvals.expires': 'Expires at {time}',
121
+ 'approvals.approveLabel': 'Approve: {summary}',
122
+ 'approvals.declineLabel': 'Decline: {summary}',
123
+ // Sessions and connected agents
124
+ 'sessions.headline': 'You’re signed in on {devices}. [{agents}]',
125
+ 'sessions.title': 'Where you’re signed in',
126
+ 'sessions.deviceOne': '1 device',
127
+ 'sessions.deviceMany': '{count} devices',
128
+ 'sessions.agentOne': '1 agent acts for you.',
129
+ 'sessions.agentMany': '{count} agents act for you.',
130
+ 'sessions.thisDevice': 'This device',
131
+ 'sessions.revoke': 'Revoke',
132
+ 'sessions.revoked': 'Revoked',
133
+ 'sessions.revokeLabel': 'Revoke {name}',
134
+ 'sessions.revokedLabel': 'Revoked {name}',
135
+ 'sessions.signOutOthers': 'Sign out other devices',
136
+ 'sessions.signedOutOthers': 'Other devices are signed out',
137
+ 'sessions.browser': 'A browser',
138
+ 'sessions.token': 'Token “{name}”',
139
+ 'sessions.app': '{name}',
140
+ // That wasn't me
141
+ 'wasntMe.headline': 'A recovery code signed in to your account. [Was it you?]',
142
+ 'wasntMe.title': 'A recovery code signed in',
143
+ 'wasntMe.lead': 'Was it you?',
144
+ 'wasntMe.device': 'A new sign-in',
145
+ 'wasntMe.hold': 'You can undo it until {time}.',
146
+ 'wasntMe.undo': 'That wasn’t me',
147
+ 'wasntMe.keep': 'It was me',
148
+ 'wasntMe.undoneChip': 'Undone',
149
+ 'wasntMe.kept': 'Nothing changed. The sign-in stays.',
150
+ 'wasntMe.keptChip': 'Kept',
151
+ 'wasntMe.newCodes': 'Make new recovery codes',
152
+ 'change.passkey_added': 'Added a passkey.',
153
+ 'change.passkey_removed': 'Removed a passkey.',
154
+ 'change.recovery_codes_generated': 'Made new recovery codes.',
155
+ 'change.totp_enrolled': 'Set up an authenticator app.',
156
+ 'change.totp_removed': 'Removed the authenticator app.',
157
+ 'change.password_set': 'Set a password.',
158
+ 'change.password_changed': 'Changed the password.',
159
+ 'change.email_changed': 'Changed the email address.',
160
+ 'change.email_change_requested': 'Asked to change the email address.',
161
+ 'change.agent_created': 'Gave an agent access.',
162
+ 'change.pat_created': 'Made a personal access token.',
163
+ 'change.session_revoked': 'Signed out a device.',
164
+ 'change.other': 'Made a change ({kind}).',
165
+ 'undone.sessions': 'Signed out {count} sessions.',
166
+ 'undone.session': 'Signed out 1 session.',
167
+ 'undone.agents': 'Turned off {count} agents.',
168
+ 'undone.agent': 'Turned off 1 agent.',
169
+ 'undone.passkeys': 'Removed {count} passkeys.',
170
+ 'undone.passkey': 'Removed 1 passkey.',
171
+ 'undone.totp': 'Removed the authenticator app.',
172
+ 'undone.password': 'Removed the new password.',
173
+ 'undone.email': 'Put back your email address.',
174
+ 'undone.codes': 'Deleted the remaining recovery codes.',
175
+ // Activity
176
+ 'activity.verified': '*Nothing has changed.* [All {count} entries match their seals.]',
177
+ 'activity.verifiedOne': '*Nothing has changed.* [The entry matches its seal.]',
178
+ 'activity.partly': '{sealed} of {count} entries are sealed. [The rest get their seals within a minute.]',
179
+ 'activity.sealing': '{count} entries [get their seals within a minute.]',
180
+ 'activity.sealingOne': '1 entry [gets its seal within a minute.]',
181
+ 'activity.seal': 'Seal {seal}',
182
+ 'activity.tampered': '!The activity log has changed.! [Tell your administrator.]',
183
+ 'activity.unknown': 'Checking the seals. [This takes a moment.]',
184
+ 'activity.unavailable': 'The seals couldn’t be checked. [Try again in a minute.]',
185
+ 'activity.empty': 'Nothing has happened yet.',
186
+ 'activity.title': 'Activity',
187
+ 'activity.verifiedAt': 'Checked at {time}.',
188
+ 'activity.failedAt': 'The last check at {time} couldn’t run.',
189
+ 'activity.checkAgain': 'Check again',
190
+ 'activity.more': 'Show older entries',
191
+ 'event.session_started': '{who} signed in.',
192
+ 'event.session_revoked': '{who} signed out a session.',
193
+ 'event.session_delegated': '{agent} started a session, with less access.',
194
+ 'event.session_stepped_up': '{who} confirmed it was you.',
195
+ 'event.agent_created': '{who} gave {agent} access.',
196
+ 'event.agent_revoked': '{who} turned off {agent}.',
197
+ 'event.agent_claimed': '{who} claimed {agent}.',
198
+ 'event.approval_requested': '{agent} asked to {action}',
199
+ 'event.approval_granted': '{who} approved {agent}’s request with a passkey.',
200
+ 'event.approval_denied': '{who} declined {agent}’s request.',
201
+ 'event.approval_redeemed': '{agent} did what you approved. It ran once.',
202
+ 'event.access_denied': '{who} was refused access.',
203
+ 'event.passkey_added': '{who} added a passkey.',
204
+ 'event.passkey_removed': '{who} removed a passkey.',
205
+ 'event.recovery_codes_generated': '{who} made new recovery codes.',
206
+ 'event.recovery_codes_confirmed': '{who} saved the recovery codes.',
207
+ 'event.recovery_code_used': '{who} signed in with a recovery code.',
208
+ 'event.recovery_undone': '{who} undid a sign-in with a recovery code.',
209
+ 'event.totp_enrolled': '{who} set up an authenticator app.',
210
+ 'event.totp_removed': '{who} removed the authenticator app.',
211
+ 'event.password_set': '{who} set a password.',
212
+ 'event.password_changed': '{who} changed the password.',
213
+ 'event.password_reset': '{who} reset the password.',
214
+ 'event.email_changed': '{who} changed the email address.',
215
+ 'event.pat_created': '{who} made a personal access token.',
216
+ 'event.factor_rejected': 'A sign-in was refused.',
217
+ 'event.device_approved': '{who} connected a device.',
218
+ 'event.oauth_consented': '{who} connected an app.',
219
+ 'event.tool_called': '{agent} used a tool: {action}.',
220
+ 'event.other': '{who}: {kind}.',
221
+ // Authenticator setup
222
+ 'twoStep.headline': 'Add an authenticator app [in {steps} steps.]',
223
+ 'twoStep.title': 'Set up an authenticator app',
224
+ 'twoStep.three': 'three',
225
+ 'twoStep.two': 'two',
226
+ 'twoStep.codes': 'Save your recovery codes',
227
+ 'twoStep.scan': 'Scan the code with your app',
228
+ 'twoStep.enter': 'Enter the 6-digit code',
229
+ 'twoStep.done': '{appName} asks for a code from your app at sign-in.',
230
+ 'twoStep.doneChip': 'Turned on',
231
+ 'twoStep.stepDone': 'Done',
232
+ 'twoStep.qr': 'QR code for your authenticator app',
233
+ 'twoStep.key': 'Or type this key:',
234
+ 'twoStep.open': 'Open in an authenticator app',
235
+ 'twoStep.turnOn': 'Turn it on',
236
+ 'twoStep.onHeadline': 'Your authenticator app [is on.]',
237
+ 'twoStep.onTitle': 'Authenticator app',
238
+ 'twoStep.onLead': '{appName} asks for a code from it at sign-in.',
239
+ 'twoStep.app': 'Authenticator app',
240
+ 'twoStep.since': 'Set up {date}',
241
+ 'twoStep.onChip': 'On',
242
+ 'twoStep.replace': 'Replace',
243
+ 'twoStep.remove': 'Remove',
244
+ 'twoStep.removeHeadline': 'Remove your authenticator app?',
245
+ 'twoStep.removeTitle': 'Remove your authenticator app?',
246
+ 'twoStep.removeLead': '{appName} stops asking for a code from it at sign-in. If you signed in more than 10 minutes ago, you confirm it’s you first.',
247
+ 'twoStep.removeConfirm': 'Remove it',
248
+ 'twoStep.removedChip': 'Removed',
249
+ 'twoStep.removed': '{appName} no longer asks for a code from your app.',
250
+ 'twoStep.setUp': 'Set up an authenticator app',
251
+ 'twoStep.replaceHeadline': 'Replace your authenticator app?',
252
+ 'twoStep.replaceTitle': 'Replace your authenticator app?',
253
+ 'twoStep.replaceLead': 'Your current app stops working when you continue. Then scan the new code and enter a code from it to turn it on again.',
254
+ 'twoStep.lockedHeadline': 'Your authenticator app !is locked.!',
255
+ 'twoStep.lockedTitle': 'Authenticator app locked',
256
+ 'twoStep.lockedLead': 'Too many wrong codes locked it. Set it up again to sign in with a code, or remove it.',
257
+ 'twoStep.lockedChip': 'Locked',
258
+ 'twoStep.setUpAgain': 'Set it up again',
259
+ // Recovery codes
260
+ 'codes.headline': 'Recovery codes [sign you in when your passkey can’t.]',
261
+ 'codes.title': 'Recovery codes',
262
+ 'codes.cap': 'Each code signs you in once. Making codes replaces the ones you have.',
263
+ 'codes.make': 'Make my codes',
264
+ 'codes.saved': 'I saved them',
265
+ 'codes.confirmLabel': 'To check, type one of the codes',
266
+ 'codes.confirm': 'Check it',
267
+ 'codes.done': 'Saved. Keep them somewhere safe, away from this device.',
268
+ 'codes.doneChip': 'Saved',
269
+ 'codes.file': '{appName} recovery codes',
270
+ });
271
+ /** Fills {name} values in a template. A missing value becomes empty. */
272
+ export function fill(template, vars = {}) {
273
+ return template.replace(/\{(\w+)\}/g, (_, k) => (k in vars ? String(vars[k]) : ''));
274
+ }
275
+ /**
276
+ * Splits a template into runs: [words] are `join`, *words* are `ok`,
277
+ * !words! are `warn`, and the rest is `key`. A {name} outside markup is a
278
+ * `value` run of its own, so the caller can render it, for example in
279
+ * bold; inside markup it stays in its run's text. The caller fills values
280
+ * after splitting, so a value never adds markup.
281
+ */
282
+ export function runs(template) {
283
+ const out = [];
284
+ const re = /\[([^\]]*)\]|\*([^*]*)\*|!([^!\s][^!]*)!|\{(\w+)\}|([^[*!{]+|[[*!{])/g;
285
+ for (const m of template.matchAll(re)) {
286
+ if (m[1] !== undefined)
287
+ out.push({ text: m[1], kind: 'join' });
288
+ else if (m[2] !== undefined)
289
+ out.push({ text: m[2], kind: 'ok' });
290
+ else if (m[3] !== undefined)
291
+ out.push({ text: m[3], kind: 'warn' });
292
+ else if (m[4] !== undefined)
293
+ out.push({ text: '', kind: 'value', name: m[4] });
294
+ else
295
+ out.push({ text: m[5], kind: 'key' });
296
+ }
297
+ return out;
298
+ }
299
+ /** The plain text of a template: its markup removed and its values filled. */
300
+ export function plain(template, vars = {}) {
301
+ return runs(template).map(r => (r.kind === 'value' ? String(vars[r.name ?? ''] ?? '') : fill(r.text, vars))).join('');
302
+ }
@@ -0,0 +1,93 @@
1
+ Copyright 2024 The Geist Project Authors (https://github.com/vercel/geist-font.git) GeistMono-Italic[wght].ttf: Copyright 2024 The Geist Project Authors (https://github.com/vercel/geist-font.git)
2
+
3
+ This Font Software is licensed under the SIL Open Font License, Version 1.1.
4
+ This license is copied below, and is also available with a FAQ at:
5
+ http://scripts.sil.org/OFL
6
+
7
+
8
+ -----------------------------------------------------------
9
+ SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
10
+ -----------------------------------------------------------
11
+
12
+ PREAMBLE
13
+ The goals of the Open Font License (OFL) are to stimulate worldwide
14
+ development of collaborative font projects, to support the font creation
15
+ efforts of academic and linguistic communities, and to provide a free and
16
+ open framework in which fonts may be shared and improved in partnership
17
+ with others.
18
+
19
+ The OFL allows the licensed fonts to be used, studied, modified and
20
+ redistributed freely as long as they are not sold by themselves. The
21
+ fonts, including any derivative works, can be bundled, embedded,
22
+ redistributed and/or sold with any software provided that any reserved
23
+ names are not used by derivative works. The fonts and derivatives,
24
+ however, cannot be released under any other type of license. The
25
+ requirement for fonts to remain under this license does not apply
26
+ to any document created using the fonts or their derivatives.
27
+
28
+ DEFINITIONS
29
+ "Font Software" refers to the set of files released by the Copyright
30
+ Holder(s) under this license and clearly marked as such. This may
31
+ include source files, build scripts and documentation.
32
+
33
+ "Reserved Font Name" refers to any names specified as such after the
34
+ copyright statement(s).
35
+
36
+ "Original Version" refers to the collection of Font Software components as
37
+ distributed by the Copyright Holder(s).
38
+
39
+ "Modified Version" refers to any derivative made by adding to, deleting,
40
+ or substituting -- in part or in whole -- any of the components of the
41
+ Original Version, by changing formats or by porting the Font Software to a
42
+ new environment.
43
+
44
+ "Author" refers to any designer, engineer, programmer, technical
45
+ writer or other person who contributed to the Font Software.
46
+
47
+ PERMISSION & CONDITIONS
48
+ Permission is hereby granted, free of charge, to any person obtaining
49
+ a copy of the Font Software, to use, study, copy, merge, embed, modify,
50
+ redistribute, and sell modified and unmodified copies of the Font
51
+ Software, subject to the following conditions:
52
+
53
+ 1) Neither the Font Software nor any of its individual components,
54
+ in Original or Modified Versions, may be sold by itself.
55
+
56
+ 2) Original or Modified Versions of the Font Software may be bundled,
57
+ redistributed and/or sold with any software, provided that each copy
58
+ contains the above copyright notice and this license. These can be
59
+ included either as stand-alone text files, human-readable headers or
60
+ in the appropriate machine-readable metadata fields within text or
61
+ binary files as long as those fields can be easily viewed by the user.
62
+
63
+ 3) No Modified Version of the Font Software may use the Reserved Font
64
+ Name(s) unless explicit written permission is granted by the corresponding
65
+ Copyright Holder. This restriction only applies to the primary font name as
66
+ presented to the users.
67
+
68
+ 4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font
69
+ Software shall not be used to promote, endorse or advertise any
70
+ Modified Version, except to acknowledge the contribution(s) of the
71
+ Copyright Holder(s) and the Author(s) or with their explicit written
72
+ permission.
73
+
74
+ 5) The Font Software, modified or unmodified, in part or in whole,
75
+ must be distributed entirely under this license, and must not be
76
+ distributed under any other license. The requirement for fonts to
77
+ remain under this license does not apply to any document created
78
+ using the Font Software.
79
+
80
+ TERMINATION
81
+ This license becomes null and void if any of the above conditions are
82
+ not met.
83
+
84
+ DISCLAIMER
85
+ THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
86
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF
87
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT
88
+ OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE
89
+ COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
90
+ INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
91
+ DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
92
+ FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM
93
+ OTHER DEALINGS IN THE FONT SOFTWARE.
@@ -0,0 +1,93 @@
1
+ Copyright 2024 The Geist Project Authors (https://github.com/vercel/geist-font) Geist-Italic[wght].ttf: Copyright 2024 The Geist Project Authors (https://github.com/vercel/geist-font)
2
+
3
+ This Font Software is licensed under the SIL Open Font License, Version 1.1.
4
+ This license is copied below, and is also available with a FAQ at:
5
+ http://scripts.sil.org/OFL
6
+
7
+
8
+ -----------------------------------------------------------
9
+ SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
10
+ -----------------------------------------------------------
11
+
12
+ PREAMBLE
13
+ The goals of the Open Font License (OFL) are to stimulate worldwide
14
+ development of collaborative font projects, to support the font creation
15
+ efforts of academic and linguistic communities, and to provide a free and
16
+ open framework in which fonts may be shared and improved in partnership
17
+ with others.
18
+
19
+ The OFL allows the licensed fonts to be used, studied, modified and
20
+ redistributed freely as long as they are not sold by themselves. The
21
+ fonts, including any derivative works, can be bundled, embedded,
22
+ redistributed and/or sold with any software provided that any reserved
23
+ names are not used by derivative works. The fonts and derivatives,
24
+ however, cannot be released under any other type of license. The
25
+ requirement for fonts to remain under this license does not apply
26
+ to any document created using the fonts or their derivatives.
27
+
28
+ DEFINITIONS
29
+ "Font Software" refers to the set of files released by the Copyright
30
+ Holder(s) under this license and clearly marked as such. This may
31
+ include source files, build scripts and documentation.
32
+
33
+ "Reserved Font Name" refers to any names specified as such after the
34
+ copyright statement(s).
35
+
36
+ "Original Version" refers to the collection of Font Software components as
37
+ distributed by the Copyright Holder(s).
38
+
39
+ "Modified Version" refers to any derivative made by adding to, deleting,
40
+ or substituting -- in part or in whole -- any of the components of the
41
+ Original Version, by changing formats or by porting the Font Software to a
42
+ new environment.
43
+
44
+ "Author" refers to any designer, engineer, programmer, technical
45
+ writer or other person who contributed to the Font Software.
46
+
47
+ PERMISSION & CONDITIONS
48
+ Permission is hereby granted, free of charge, to any person obtaining
49
+ a copy of the Font Software, to use, study, copy, merge, embed, modify,
50
+ redistribute, and sell modified and unmodified copies of the Font
51
+ Software, subject to the following conditions:
52
+
53
+ 1) Neither the Font Software nor any of its individual components,
54
+ in Original or Modified Versions, may be sold by itself.
55
+
56
+ 2) Original or Modified Versions of the Font Software may be bundled,
57
+ redistributed and/or sold with any software, provided that each copy
58
+ contains the above copyright notice and this license. These can be
59
+ included either as stand-alone text files, human-readable headers or
60
+ in the appropriate machine-readable metadata fields within text or
61
+ binary files as long as those fields can be easily viewed by the user.
62
+
63
+ 3) No Modified Version of the Font Software may use the Reserved Font
64
+ Name(s) unless explicit written permission is granted by the corresponding
65
+ Copyright Holder. This restriction only applies to the primary font name as
66
+ presented to the users.
67
+
68
+ 4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font
69
+ Software shall not be used to promote, endorse or advertise any
70
+ Modified Version, except to acknowledge the contribution(s) of the
71
+ Copyright Holder(s) and the Author(s) or with their explicit written
72
+ permission.
73
+
74
+ 5) The Font Software, modified or unmodified, in part or in whole,
75
+ must be distributed entirely under this license, and must not be
76
+ distributed under any other license. The requirement for fonts to
77
+ remain under this license does not apply to any document created
78
+ using the Font Software.
79
+
80
+ TERMINATION
81
+ This license becomes null and void if any of the above conditions are
82
+ not met.
83
+
84
+ DISCLAIMER
85
+ THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
86
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF
87
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT
88
+ OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE
89
+ COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
90
+ INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
91
+ DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
92
+ FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM
93
+ OTHER DEALINGS IN THE FONT SOFTWARE.
@@ -0,0 +1,93 @@
1
+ Copyright 2016 The Inter Project Authors (https://github.com/rsms/inter) Inter-Italic[opsz,wght].ttf: Copyright 2016 The Inter Project Authors (https://github.com/rsms/inter)
2
+
3
+ This Font Software is licensed under the SIL Open Font License, Version 1.1.
4
+ This license is copied below, and is also available with a FAQ at:
5
+ http://scripts.sil.org/OFL
6
+
7
+
8
+ -----------------------------------------------------------
9
+ SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
10
+ -----------------------------------------------------------
11
+
12
+ PREAMBLE
13
+ The goals of the Open Font License (OFL) are to stimulate worldwide
14
+ development of collaborative font projects, to support the font creation
15
+ efforts of academic and linguistic communities, and to provide a free and
16
+ open framework in which fonts may be shared and improved in partnership
17
+ with others.
18
+
19
+ The OFL allows the licensed fonts to be used, studied, modified and
20
+ redistributed freely as long as they are not sold by themselves. The
21
+ fonts, including any derivative works, can be bundled, embedded,
22
+ redistributed and/or sold with any software provided that any reserved
23
+ names are not used by derivative works. The fonts and derivatives,
24
+ however, cannot be released under any other type of license. The
25
+ requirement for fonts to remain under this license does not apply
26
+ to any document created using the fonts or their derivatives.
27
+
28
+ DEFINITIONS
29
+ "Font Software" refers to the set of files released by the Copyright
30
+ Holder(s) under this license and clearly marked as such. This may
31
+ include source files, build scripts and documentation.
32
+
33
+ "Reserved Font Name" refers to any names specified as such after the
34
+ copyright statement(s).
35
+
36
+ "Original Version" refers to the collection of Font Software components as
37
+ distributed by the Copyright Holder(s).
38
+
39
+ "Modified Version" refers to any derivative made by adding to, deleting,
40
+ or substituting -- in part or in whole -- any of the components of the
41
+ Original Version, by changing formats or by porting the Font Software to a
42
+ new environment.
43
+
44
+ "Author" refers to any designer, engineer, programmer, technical
45
+ writer or other person who contributed to the Font Software.
46
+
47
+ PERMISSION & CONDITIONS
48
+ Permission is hereby granted, free of charge, to any person obtaining
49
+ a copy of the Font Software, to use, study, copy, merge, embed, modify,
50
+ redistribute, and sell modified and unmodified copies of the Font
51
+ Software, subject to the following conditions:
52
+
53
+ 1) Neither the Font Software nor any of its individual components,
54
+ in Original or Modified Versions, may be sold by itself.
55
+
56
+ 2) Original or Modified Versions of the Font Software may be bundled,
57
+ redistributed and/or sold with any software, provided that each copy
58
+ contains the above copyright notice and this license. These can be
59
+ included either as stand-alone text files, human-readable headers or
60
+ in the appropriate machine-readable metadata fields within text or
61
+ binary files as long as those fields can be easily viewed by the user.
62
+
63
+ 3) No Modified Version of the Font Software may use the Reserved Font
64
+ Name(s) unless explicit written permission is granted by the corresponding
65
+ Copyright Holder. This restriction only applies to the primary font name as
66
+ presented to the users.
67
+
68
+ 4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font
69
+ Software shall not be used to promote, endorse or advertise any
70
+ Modified Version, except to acknowledge the contribution(s) of the
71
+ Copyright Holder(s) and the Author(s) or with their explicit written
72
+ permission.
73
+
74
+ 5) The Font Software, modified or unmodified, in part or in whole,
75
+ must be distributed entirely under this license, and must not be
76
+ distributed under any other license. The requirement for fonts to
77
+ remain under this license does not apply to any document created
78
+ using the Font Software.
79
+
80
+ TERMINATION
81
+ This license becomes null and void if any of the above conditions are
82
+ not met.
83
+
84
+ DISCLAIMER
85
+ THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
86
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF
87
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT
88
+ OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE
89
+ COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
90
+ INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
91
+ DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
92
+ FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM
93
+ OTHER DEALINGS IN THE FONT SOFTWARE.
@@ -0,0 +1,18 @@
1
+ # fonts
2
+
3
+ The fonts the elements use by default, served with the browser client under `/auth/client/fonts/`. Each is the Latin subset of a variable font, weights 100 to 900, from Fontsource. Browsers download a font only when an element uses it, and never with `font: "system"`.
4
+
5
+ They aren't built from `src/`: they are copied as they are, and `npm run build` leaves them in place.
6
+
7
+ ## Contents
8
+
9
+ | Name | What it holds |
10
+ |---|---|
11
+ | `geist.woff2` | Geist 5.3.0, for headlines |
12
+ | `inter.woff2` | Inter 5.3.0, for text |
13
+ | `geist-mono.woff2` | Geist Mono 5.3.0, for recovery codes and keys |
14
+ | `OFL-geist.txt`, `OFL-inter.txt`, `OFL-geist-mono.txt` | The SIL Open Font License 1.1 of each font |
15
+
16
+ ## See also
17
+
18
+ - [Elements](../../src/elements/README.md)
Binary file
Binary file
Binary file
@@ -0,0 +1,4 @@
1
+ export { AuthClient, createAuthClient, defaultEndpoints, deriveKey, type Activity, type ActivityEvent, type AgentRef, type ApprovalView, type ClientOptions, type RecoverySignInView, type SessionView, type EnterOptions, type Endpoints, type Outcome, type PasswordStatus, type SessionEvent, type StepUpOptions, type TOTPStatus, } from './client.ts';
2
+ export { ProblemError, problemType, readProblem, stepUpCodes, type Assurance, type Challenge, type ChallengeApproval, type Method, type Problem, } from './problem.ts';
3
+ export { capabilities, fromBase64url, toBase64url, type Capabilities } from './webauthn.ts';
4
+ export { mountDevTools, type DevToolsOptions } from './devtools.ts';
package/dist/index.js ADDED
@@ -0,0 +1,5 @@
1
+ // @tensile-tools/auth-client: the browser side of tensile-auth.
2
+ export { AuthClient, createAuthClient, defaultEndpoints, deriveKey, } from "./client.js";
3
+ export { ProblemError, problemType, readProblem, stepUpCodes, } from "./problem.js";
4
+ export { capabilities, fromBase64url, toBase64url } from "./webauthn.js";
5
+ export { mountDevTools } from "./devtools.js";