@ory/elements-react 1.0.0-next.9 → 1.0.0-pr.5494d7c2

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 (78) hide show
  1. package/CHANGELOG.md +578 -0
  2. package/DEVELOPMENT.md +94 -0
  3. package/LICENSE +201 -0
  4. package/README.md +359 -32
  5. package/babel.config.js +10 -0
  6. package/dist/client/config.d.mts +21 -0
  7. package/dist/client/config.d.ts +21 -0
  8. package/dist/client/config.js +77 -0
  9. package/dist/client/config.js.map +1 -0
  10. package/dist/client/config.mjs +51 -0
  11. package/dist/client/config.mjs.map +1 -0
  12. package/dist/client/frontendClient.d.mts +10 -0
  13. package/dist/client/frontendClient.d.ts +10 -0
  14. package/dist/client/frontendClient.js +75 -0
  15. package/dist/client/frontendClient.js.map +1 -0
  16. package/dist/client/frontendClient.mjs +54 -0
  17. package/dist/client/frontendClient.mjs.map +1 -0
  18. package/dist/client/index.d.mts +5 -0
  19. package/dist/client/index.d.ts +5 -0
  20. package/dist/client/index.js +33 -0
  21. package/dist/client/index.js.map +1 -0
  22. package/dist/client/index.mjs +10 -0
  23. package/dist/client/index.mjs.map +1 -0
  24. package/dist/client/session-provider.d.mts +62 -0
  25. package/dist/client/session-provider.d.ts +62 -0
  26. package/dist/client/session-provider.js +96 -0
  27. package/dist/client/session-provider.js.map +1 -0
  28. package/dist/client/session-provider.mjs +71 -0
  29. package/dist/client/session-provider.mjs.map +1 -0
  30. package/dist/client/useSession.d.mts +32 -0
  31. package/dist/client/useSession.d.ts +32 -0
  32. package/dist/client/useSession.js +37 -0
  33. package/dist/client/useSession.js.map +1 -0
  34. package/dist/client/useSession.mjs +13 -0
  35. package/dist/client/useSession.mjs.map +1 -0
  36. package/dist/index.d.mts +531 -1888
  37. package/dist/index.d.ts +531 -1888
  38. package/dist/index.js +4159 -2556
  39. package/dist/index.js.map +1 -1
  40. package/dist/index.mjs +4154 -2543
  41. package/dist/index.mjs.map +1 -1
  42. package/dist/theme/default/index.css +986 -308
  43. package/dist/theme/default/index.css.map +1 -1
  44. package/dist/theme/default/index.d.mts +54 -15
  45. package/dist/theme/default/index.d.ts +54 -15
  46. package/dist/theme/default/index.js +5616 -797
  47. package/dist/theme/default/index.js.map +1 -1
  48. package/dist/theme/default/index.mjs +5702 -768
  49. package/dist/theme/default/index.mjs.map +1 -1
  50. package/dist/theme/default/tailwind/defaults.d.mts +737 -0
  51. package/dist/theme/default/tailwind/defaults.d.ts +737 -0
  52. package/dist/theme/default/tailwind/defaults.js +219 -0
  53. package/dist/theme/default/tailwind/defaults.js.map +1 -0
  54. package/dist/theme/default/tailwind/defaults.mjs +196 -0
  55. package/dist/theme/default/tailwind/defaults.mjs.map +1 -0
  56. package/package.json +39 -14
  57. package/tailwind/defaults.ts +34 -0
  58. package/tailwind/generated/README.md +2 -0
  59. package/tailwind/generated/default-variables.css +216 -0
  60. package/tailwind/generated/variables-processed.json +161 -0
  61. package/tsconfig.json +10 -9
  62. package/tsconfig.runtime.json +4 -0
  63. package/.eslintrc.js +0 -61
  64. package/.vscode/i18n-ally-reviews.yml +0 -3
  65. package/.vscode/settings.json +0 -4
  66. package/api-report/elements-react-theme.api.json +0 -1260
  67. package/api-report/elements-react-theme.api.md +0 -128
  68. package/api-report/elements-react.api.json +0 -4262
  69. package/api-report/elements-react.api.md +0 -393
  70. package/api-report/temp/elements-react-theme.api.md +0 -130
  71. package/api-report/temp/elements-react.api.md +0 -328
  72. package/config/api-extractor-core.json +0 -457
  73. package/config/api-extractor-theme.json +0 -463
  74. package/jest.config.ts +0 -16
  75. package/postcss.config.ts +0 -6
  76. package/tailwind.config.ts +0 -54
  77. package/tsconfig.spec.json +0 -20
  78. package/variables-processed.json +0 -193
package/CHANGELOG.md CHANGED
@@ -1,3 +1,581 @@
1
+ ## 1.0.0-rc.3 (2025-05-09)
2
+
3
+ ### 🩹 Fixes
4
+
5
+ - captcha reloading and duplication ([#518](https://github.com/ory/elements/pull/518))
6
+ - ⚠️ rework configuration management ([#515](https://github.com/ory/elements/pull/515))
7
+ - add missing testids to method selector and checkbox ([#517](https://github.com/ory/elements/pull/517))
8
+
9
+ ### ⚠️ Breaking Changes
10
+
11
+ - ⚠️ rework configuration management ([#515](https://github.com/ory/elements/pull/515))
12
+
13
+ ### ❤️ Thank You
14
+
15
+ - hackerman @aeneasr
16
+ - Jonas Hungershausen
17
+
18
+ ## 1.0.0-rc.2 (2025-04-30)
19
+
20
+ ### 🚀 Features
21
+
22
+ - method translation for totp, code, webauthn ([#500](https://github.com/ory/elements/pull/500))
23
+ - add all missing stories ([#480](https://github.com/ory/elements/pull/480))
24
+ - preview deployments for example apps ([#488](https://github.com/ory/elements/pull/488))
25
+ - add back button to settings page ([#464](https://github.com/ory/elements/pull/464))
26
+
27
+ ### 🩹 Fixes
28
+
29
+ - ⚠️ align configuration types to Ory Network APIs ([#423](https://github.com/ory/elements/pull/423))
30
+ - sort captcha before submit button ([#507](https://github.com/ory/elements/pull/507))
31
+ - cors credentials in default client ([#508](https://github.com/ory/elements/pull/508))
32
+ - back button should return to application ([#465](https://github.com/ory/elements/pull/465))
33
+ - adjust design of generic OIDC provider ([#492](https://github.com/ory/elements/pull/492))
34
+ - use proper id for react element arrays ([#495](https://github.com/ory/elements/pull/495))
35
+ - add test id to header messages ([#489](https://github.com/ory/elements/pull/489))
36
+ - re-add missing error message when no methods provided ([#460](https://github.com/ory/elements/pull/460))
37
+ - resend not working for registration ([#468](https://github.com/ory/elements/pull/468))
38
+ - add missing color class to registration footer ([#473](https://github.com/ory/elements/pull/473))
39
+ - resend not working for registration ([#467](https://github.com/ory/elements/pull/467))
40
+
41
+ ### ⚠️ Breaking Changes
42
+
43
+ - ⚠️ align configuration types to Ory Network APIs ([#423](https://github.com/ory/elements/pull/423))
44
+
45
+ ### ❤️ Thank You
46
+
47
+ - hackerman @aeneasr
48
+ - Jonas Hungershausen
49
+
50
+ ## 1.0.0-rc.1 (2025-04-21)
51
+
52
+ ### 🩹 Fixes
53
+
54
+ - re-add missing error message when no methods provided ([#460](https://github.com/ory/elements/pull/460))
55
+ - resend not working for registration ([#468](https://github.com/ory/elements/pull/468))
56
+ - add missing color class to registration footer ([#473](https://github.com/ory/elements/pull/473))
57
+ - resend not working for registration ([#467](https://github.com/ory/elements/pull/467))
58
+
59
+ ### ❤️ Thank You
60
+
61
+ - hackerman @aeneasr
62
+ - Jonas Hungershausen
63
+
64
+ ## 1.0.0-rc.0 (2025-04-17)
65
+
66
+ ### 🚀 Features
67
+
68
+ - add missing translations for de, es and fr ([#456](https://github.com/ory/elements/pull/456))
69
+
70
+ ### 🩹 Fixes
71
+
72
+ - correctly set input field value ([#447](https://github.com/ory/elements/pull/447))
73
+ - add missing settings padding ([#446](https://github.com/ory/elements/pull/446))
74
+ - always omit conflicting keys ([#444](https://github.com/ory/elements/pull/444))
75
+
76
+ ### ❤️ Thank You
77
+
78
+ - hackerman @aeneasr
79
+ - Jonas Hungershausen
80
+
81
+ ## 1.0.0-next.46 (2025-04-16)
82
+
83
+ ### 🩹 Fixes
84
+
85
+ - missing hidden field regression ([#439](https://github.com/ory/elements/pull/439))
86
+ - use correct testid ([#438](https://github.com/ory/elements/pull/438))
87
+
88
+ ### ❤️ Thank You
89
+
90
+ - hackerman @aeneasr
91
+
92
+ ## 1.0.0-next.45 (2025-04-15)
93
+
94
+ ### 🩹 Fixes
95
+
96
+ - add missing test id to scope checkbox label ([#437](https://github.com/ory/elements/pull/437))
97
+ - add missing captcha group to all methods ([#432](https://github.com/ory/elements/pull/432))
98
+
99
+ ### ❤️ Thank You
100
+
101
+ - hackerman @aeneasr
102
+ - Jonas Hungershausen
103
+
104
+ ## 1.0.0-next.44 (2025-04-10)
105
+
106
+ ### 🩹 Fixes
107
+
108
+ - use currentColor in eye icons ([#433](https://github.com/ory/elements/pull/433))
109
+
110
+ ### ❤️ Thank You
111
+
112
+ - Jonas Hungershausen
113
+
114
+ ## 1.0.0-next.43 (2025-04-10)
115
+
116
+ ### 🚀 Features
117
+
118
+ - add missing French translations ([#401](https://github.com/ory/elements/pull/401))
119
+
120
+ ### 🩹 Fixes
121
+
122
+ - two-step registration back button ([#428](https://github.com/ory/elements/pull/428))
123
+ - resolve wcag2aa color contrast issues ([#367](https://github.com/ory/elements/pull/367))
124
+
125
+ ### ❤️ Thank You
126
+
127
+ - hackerman @aeneasr
128
+ - Jonas Hungershausen
129
+ - Jordan Labrosse
130
+
131
+ ## 1.0.0-next.41 (2025-04-07)
132
+
133
+ ### 🩹 Fixes
134
+
135
+ - resolve wcag2aa color contrast issues ([#367](https://github.com/ory/elements/pull/367))
136
+
137
+ ### ❤️ Thank You
138
+
139
+ - Jonas Hungershausen
140
+ - Jordan Labrosse
141
+
142
+ ## 1.0.0-next.40 (2025-04-02)
143
+
144
+ ### 🚀 Features
145
+
146
+ - support SAML-native ([#395](https://github.com/ory/elements/pull/395))
147
+
148
+ ### ❤️ Thank You
149
+
150
+ - hackerman @aeneasr
151
+
152
+ ## 1.0.0-next.39 (2025-03-25)
153
+
154
+ ### 🚀 Features
155
+
156
+ - add SAML group handling ([#390](https://github.com/ory/elements/pull/390))
157
+
158
+ ### ❤️ Thank You
159
+
160
+ - hackerman @aeneasr
161
+
162
+ ## 1.0.0-next.38 (2025-03-24)
163
+
164
+ ### 🩹 Fixes
165
+
166
+ - hide registration link again ([#387](https://github.com/ory/elements/pull/387))
167
+
168
+ ### ❤️ Thank You
169
+
170
+ - hackerman @aeneasr
171
+
172
+ ## 1.0.0-next.37 (2025-03-12)
173
+
174
+ ### 🩹 Fixes
175
+
176
+ - correctly render test id for error card ([#386](https://github.com/ory/elements/pull/386))
177
+
178
+ ### ❤️ Thank You
179
+
180
+ - Jonas Hungershausen
181
+
182
+ ## 1.0.0-next.36 (2025-03-12)
183
+
184
+ ### 🩹 Fixes
185
+
186
+ - handle error messages for selected methods ([#385](https://github.com/ory/elements/pull/385))
187
+
188
+ ### ❤️ Thank You
189
+
190
+ - Pierre Caillaud @pcaillaudm
191
+
192
+ ## 1.0.0-next.35 (2025-03-12)
193
+
194
+ ### 🚀 Features
195
+
196
+ - add more intelligent error screen ([#383](https://github.com/ory/elements/pull/383))
197
+
198
+ ### ❤️ Thank You
199
+
200
+ - Jonas Hungershausen
201
+
202
+ ## 1.0.0-next.34 (2025-03-12)
203
+
204
+ ### 🩹 Fixes
205
+
206
+ - use correct import paths ([#384](https://github.com/ory/elements/pull/384))
207
+
208
+ ### ❤️ Thank You
209
+
210
+ - hackerman @aeneasr
211
+
212
+ ## 1.0.0-next.33 (2025-03-07)
213
+
214
+ ### 🚀 Features
215
+
216
+ - add password toggle to input ([#378](https://github.com/ory/elements/pull/378))
217
+
218
+ ### 🩹 Fixes
219
+
220
+ - validation message regression ([#380](https://github.com/ory/elements/pull/380))
221
+
222
+ ### ❤️ Thank You
223
+
224
+ - Jonas Hungershausen
225
+ - Pierre Caillaud @pcaillaudm
226
+
227
+ ## 1.0.0-next.32 (2025-03-06)
228
+
229
+ ### 🚀 Features
230
+
231
+ - use method selector in 2fa login ([#377](https://github.com/ory/elements/pull/377))
232
+
233
+ ### ❤️ Thank You
234
+
235
+ - Pierre Caillaud @pcaillaudm
236
+
237
+ ## 1.0.0-next.31 (2025-03-06)
238
+
239
+ ### 🚀 Features
240
+
241
+ - support captchas natively in new and old elements ([#372](https://github.com/ory/elements/pull/372))
242
+
243
+ ### 🩹 Fixes
244
+
245
+ - center text on OIDC buttons and debounce state update ([#366](https://github.com/ory/elements/pull/366))
246
+
247
+ ### ❤️ Thank You
248
+
249
+ - hackerman @aeneasr
250
+ - Jonas Hungershausen
251
+
252
+ ## 1.0.0-next.30 (2025-03-05)
253
+
254
+ ### 🩹 Fixes
255
+
256
+ - show possible OIDC connections on login method selector ([#362](https://github.com/ory/elements/pull/362))
257
+ - add correct x/twitter OIDC logo ([#364](https://github.com/ory/elements/pull/364))
258
+
259
+ ### ❤️ Thank You
260
+
261
+ - Jonas Hungershausen
262
+
263
+ ## 1.0.0-next.29 (2025-02-27)
264
+
265
+ ### 🩹 Fixes
266
+
267
+ - remove untranslated aria label from auth list item ([#365](https://github.com/ory/elements/pull/365))
268
+ - spacing in auth method list ([#359](https://github.com/ory/elements/pull/359))
269
+
270
+ ### ❤️ Thank You
271
+
272
+ - Jonas Hungershausen
273
+
274
+ ## 1.0.0-next.28 (2025-02-20)
275
+
276
+ ### 🩹 Fixes
277
+
278
+ - safari click handler and redirect handling ([#361](https://github.com/ory/elements/pull/361))
279
+
280
+ ### ❤️ Thank You
281
+
282
+ - Jonas Hungershausen
283
+
284
+ ## 1.0.0-next.27 (2025-02-18)
285
+
286
+ ### 🩹 Fixes
287
+
288
+ - translate {property} in missing property validation message ([#357](https://github.com/ory/elements/pull/357))
289
+ - invisible LinkedIn icon ([#355](https://github.com/ory/elements/pull/355))
290
+ - in initFlowUrl carry over login challenge ([#347](https://github.com/ory/elements/pull/347))
291
+ - define a fallback font stack ([#349](https://github.com/ory/elements/pull/349))
292
+ - show correct OIDC provider logo ([#350](https://github.com/ory/elements/pull/350))
293
+ - brand logic in social sign in icon ([#348](https://github.com/ory/elements/pull/348))
294
+
295
+ ### ❤️ Thank You
296
+
297
+ - Henning Perl @hperl
298
+ - Jonas Hungershausen
299
+
300
+ ## 1.0.0-next.26 (2025-02-18)
301
+
302
+ ### 🩹 Fixes
303
+
304
+ - translate {property} in missing property validation message ([#357](https://github.com/ory/elements/pull/357))
305
+ - invisible LinkedIn icon ([#355](https://github.com/ory/elements/pull/355))
306
+ - in initFlowUrl carry over login challenge ([#347](https://github.com/ory/elements/pull/347))
307
+ - show correct OIDC provider logo ([#350](https://github.com/ory/elements/pull/350))
308
+
309
+ ### ❤️ Thank You
310
+
311
+ - Henning Perl @hperl
312
+ - Jonas Hungershausen
313
+
314
+ ## 1.0.0-next.25 (2025-01-29)
315
+
316
+ ### 🚀 Features
317
+
318
+ - expose get flow factory ([#333](https://github.com/ory/elements/pull/333))
319
+
320
+ ### 🩹 Fixes
321
+
322
+ - make OIDC remove button loading state specific ([#339](https://github.com/ory/elements/pull/339))
323
+ - only show loading indicator on clicked button ([#335](https://github.com/ory/elements/pull/335))
324
+ - don't short circuit code method selector ([#336](https://github.com/ory/elements/pull/336))
325
+
326
+ ### ❤️ Thank You
327
+
328
+ - hackerman @aeneasr
329
+ - Jonas Hungershausen
330
+
331
+ ## 1.0.0-next.24 (2025-01-22)
332
+
333
+ ### 🩹 Fixes
334
+
335
+ - only show loading indicator on clicked button ([#335](https://github.com/ory/elements/pull/335))
336
+ - don't short circuit code method selector ([#336](https://github.com/ory/elements/pull/336))
337
+
338
+ ### ❤️ Thank You
339
+
340
+ - hackerman @aeneasr
341
+ - Jonas Hungershausen
342
+
343
+ ## 1.0.0-next.23 (2025-01-21)
344
+
345
+ ### 🩹 Fixes
346
+
347
+ - don't short circuit code method selector ([#336](https://github.com/ory/elements/pull/336))
348
+
349
+ ### ❤️ Thank You
350
+
351
+ - hackerman @aeneasr
352
+ - Jonas Hungershausen
353
+
354
+ ## 1.0.0-next.3 (2025-01-21)
355
+
356
+ ### 🚀 Features
357
+
358
+ - expose get flow factory ([#333](https://github.com/ory/elements/pull/333))
359
+
360
+ ### ❤️ Thank You
361
+
362
+ - hackerman @aeneasr
363
+
364
+ ## 1.0.0-next.21 (2025-01-18)
365
+
366
+ This was a version bump only for @ory/elements-react to align it with other projects, there were no code changes.
367
+
368
+ ## 1.0.0-next.20 (2025-01-16)
369
+
370
+ ### 🚀 Features
371
+
372
+ - handle state transition edge cases ([f2e4023](https://github.com/ory/elements/commit/f2e4023))
373
+ - user experience improvements and e2e test coverage ([f68744c](https://github.com/ory/elements/commit/f68744c))
374
+ - do not show two-step selector if only one method exists ([6453673](https://github.com/ory/elements/commit/6453673))
375
+
376
+ ### 🩹 Fixes
377
+
378
+ - better validation for code method ([b0d8e2c](https://github.com/ory/elements/commit/b0d8e2c))
379
+
380
+ ### ❤️ Thank You
381
+
382
+ - aeneasr @aeneasr
383
+
384
+ ## 1.0.0-next.19 (2024-12-31)
385
+
386
+ ### 🩹 Fixes
387
+
388
+ - properly handle form submits in settings flow ([#322](https://github.com/ory/elements/pull/322))
389
+
390
+ ### ❤️ Thank You
391
+
392
+ - Jonas Hungershausen
393
+
394
+ ## 1.0.0-next.18 (2024-12-30)
395
+
396
+ ### 🚀 Features
397
+
398
+ - add page and app router examples ([#307](https://github.com/ory/elements/pull/307))
399
+ - ⚠️ add getServerSession and SessionProvider ([#309](https://github.com/ory/elements/pull/309))
400
+ - add @ory/nextjs package ([#303](https://github.com/ory/elements/pull/303))
401
+
402
+ ### 🩹 Fixes
403
+
404
+ - align font sizes to design & use updated variable names ([#318](https://github.com/ory/elements/pull/318))
405
+ - properly set default value for checkboxes ([#314](https://github.com/ory/elements/pull/314))
406
+ - passkey and webauthn in settings flow ([#317](https://github.com/ory/elements/pull/317))
407
+
408
+ ### ⚠️ Breaking Changes
409
+
410
+ - ⚠️ add getServerSession and SessionProvider ([#309](https://github.com/ory/elements/pull/309))
411
+
412
+ ### ❤️ Thank You
413
+
414
+ - hackerman @aeneasr
415
+ - Jonas Hungershausen
416
+
417
+ ## 1.0.0-next.17 (2024-11-27)
418
+
419
+
420
+ ### 🚀 Features
421
+
422
+ - allow overriding OIDC logos
423
+
424
+ - enable proper account linking flows
425
+
426
+ - **core:** add react-hook form resolver
427
+
428
+
429
+ ### 🩹 Fixes
430
+
431
+ - handle recovery brute force protection
432
+
433
+
434
+ ### ❤️ Thank You
435
+
436
+ - Jonas Hungershausen
437
+
438
+ ## 1.0.0-next.16 (2024-11-26)
439
+
440
+
441
+ ### 🚀 Features
442
+
443
+ - allow overriding of field messages
444
+
445
+ - add test ids to components
446
+
447
+
448
+ ### 🩹 Fixes
449
+
450
+ - use --font-sans CSS variable for font
451
+
452
+ - registration & login flow form states
453
+
454
+ - missing resend button on login & registration
455
+
456
+ - password validation error form state
457
+
458
+ - current identifier button overflowing on long values
459
+
460
+
461
+ ### ❤️ Thank You
462
+
463
+ - Jonas Hungershausen
464
+
465
+ ## 1.0.0-next.15 (2024-11-18)
466
+
467
+
468
+ ### 🩹 Fixes
469
+
470
+ - use --font-sans CSS variable for font
471
+
472
+ - registration & login flow form states
473
+
474
+
475
+ ### ❤️ Thank You
476
+
477
+ - Jonas Hungershausen
478
+
479
+ ## 1.0.0-next.14 (2024-11-08)
480
+
481
+
482
+ ### 🚀 Features
483
+
484
+ - force OIDC account selection on settings
485
+
486
+
487
+ ### 🩹 Fixes
488
+
489
+ - redirect to login if session expired during settings
490
+
491
+
492
+ ### ❤️ Thank You
493
+
494
+ - Jonas Hungershausen
495
+
496
+ ## 1.0.0-next.13 (2024-11-05)
497
+
498
+
499
+ ### 🩹 Fixes
500
+
501
+ - ⚠️ move useSession hook to /client entry point
502
+
503
+ - oidc linking & unlinking form properties
504
+
505
+ - hide two step registration message
506
+
507
+ - implement component merging instead of usign lodash
508
+
509
+ - replace translation merge with custom function
510
+
511
+
512
+ #### ⚠️ Breaking Changes
513
+
514
+ - ⚠️ move useSession hook to /client entry point
515
+
516
+ ### ❤️ Thank You
517
+
518
+ - Jonas Hungershausen
519
+
520
+ ## 1.0.0-next.12 (2024-10-29)
521
+
522
+
523
+ ### 🚀 Features
524
+
525
+ - add elements v1 packages
526
+
527
+ - add useSession hook
528
+
529
+ - add page header component with user menu
530
+
531
+ - support links in checkbox/boolean nodes
532
+
533
+ - add settings flow components
534
+
535
+
536
+ ### 🩹 Fixes
537
+
538
+ - use correct node to detect two step registration
539
+
540
+ - use translations in more missing places
541
+
542
+ - short-circuit code login on two step card
543
+
544
+ - duplicate resend button on recovery & verification
545
+
546
+
547
+ ### ❤️ Thank You
548
+
549
+ - Jonas Hungershausen
550
+ - Miłosz
551
+
552
+ ## 1.0.0-next.11 (2024-10-22)
553
+
554
+ Breaking Changes: This update includes breaking changes to the naming of some variables and functions. Please refer to [Advisory: ory elements‐react upgrade guide to v1.0.0‐next.11](https://github.com/ory/elements/wiki/Advisory:-ory-elements%E2%80%90react-upgrade-guide-to-v1.0.0%E2%80%90next.11) for more information.
555
+
556
+
557
+ ### 🚀 Features
558
+
559
+ - add elements v1 packages
560
+
561
+ - add useSession hook
562
+
563
+ ### ❤️ Thank You
564
+
565
+ - Jonas Hungershausen
566
+
567
+ ## 1.0.0-next.10 (2024-10-14)
568
+
569
+
570
+ ### 🩹 Fixes
571
+
572
+ - add missing translations in all places
573
+
574
+
575
+ ### ❤️ Thank You
576
+
577
+ - Jonas Hungershausen
578
+
1
579
  ## 1.0.0-next.9 (2024-10-10)
2
580
 
3
581
 
package/DEVELOPMENT.md ADDED
@@ -0,0 +1,94 @@
1
+ # Developing @ory/elements-react
2
+
3
+ Ory Elements is built inside this monorepo and hooked up to the other packages
4
+ via nx and npm workspaces.
5
+
6
+ To start a hot reloading development mode:
7
+
8
+ ```bash
9
+ npx nx dev @ory/elements-react
10
+ ```
11
+
12
+ ## API Extractor
13
+
14
+ To make sure there are no unintended changes to the API contract, we use
15
+ [API Extractor](https://api-extractor.com/) to generate API reports, that are
16
+ checked into the repository. The CI of each PR includes a check that this API
17
+ report would not change after merging the PR.
18
+
19
+ If the report would change, the CI fails. If that happens, you can re-generate
20
+ all reports by running
21
+
22
+ ```bash
23
+ npx nx api-extractor-refresh @ory/elements-react
24
+ ```
25
+
26
+ Inspect the resulting changes carefully, and make sure it is in line with what
27
+ you expected. Add the changes to your PR.
28
+
29
+ ## Tests
30
+
31
+ Unit tests use Jest and react-testing-library. To run the tests locally,
32
+ execute:
33
+
34
+ ```bash
35
+ npx nx build @ory/elements-react
36
+ ```
37
+
38
+ ### Test selectors
39
+
40
+ To select DOM elements use a `data-testid` selector. Nomenclature mandates `/`
41
+ as separators and a prefix of `ory/`:
42
+
43
+ - `ory/form/` is the prefix for form elements;
44
+ - `ory/screen/` is the prefix for elements on specific screens;
45
+ - `ory/screen/` is the prefix for translatable messages (e.g. validation
46
+ errors).
47
+
48
+ ## Stories
49
+
50
+ Each flow has its own story in the `packages/elements-react-stories` package. To
51
+ run the storybook development environment, execute:
52
+
53
+ ```bash
54
+ npx nx storybook @ory/elements-react
55
+ ```
56
+
57
+ You can also build the Storybook using:
58
+
59
+ ```bash
60
+ npx nx build @ory/elements-react
61
+ ```
62
+
63
+ The stories use stub responses
64
+
65
+ ## Releasing
66
+
67
+ @ory/elements-react and @ory/nextjs is released using nx releases.
68
+
69
+ There is a helper script located in `./scripts/release.sh`.
70
+
71
+ Usage:
72
+
73
+ ```bash
74
+ ./scripts/release.sh <project> <tag>
75
+
76
+ ./scripts/release.sh @ory/elements-react next
77
+ ```
78
+
79
+ The script asks the user before executing each steps. Please double check
80
+ CHANGELOG.md and dry run outputs. nx also creates git tags and commits, that
81
+ should be commited. The script will do that automatically.
82
+
83
+ ### Pre-releasing unmerged changes
84
+
85
+ You can release a PR's changes to npm to test them in a different repository,
86
+ etc. These versions are released on the `pr` npm tag, and will have the version
87
+ `0.0.0-pr.<git hash>`. These releases wont be pushed to master, but you might
88
+ have to revert the `package.json` and `package-lock.json` files.
89
+
90
+ Usage:
91
+
92
+ ```bash
93
+ ./scripts/release.sh @ory/elements-react pr
94
+ ```