Skip to content

Commit 12583f3

Browse files
authored
Merge pull request #285 from brionmario/refactor-thunder-flows
2 parents b64b2ec + be37350 commit 12583f3

File tree

89 files changed

+3948
-2291
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

89 files changed

+3948
-2291
lines changed

.changeset/pink-bugs-glow.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
---
2+
'@asgardeo/javascript': minor
3+
'@asgardeo/nextjs': minor
4+
'@asgardeo/react': minor
5+
'@asgardeo/i18n': minor
6+
---
7+
8+
Add support to resolve component metadata from Thunder Flow APIs
9+
10+
Refer: https://github.com/asgardeo/thunder/discussions/812

CONTRIBUTING.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -199,8 +199,8 @@ Open your new language file and:
199199

200200
```typescript
201201
const translations: I18nTranslations = {
202-
'elements.buttons.signIn': 'Se connecter',
203-
'elements.buttons.signOut': 'Se déconnecter',
202+
'elements.buttons.signin.text': 'Se connecter',
203+
'elements.buttons.signout.text': 'Se déconnecter',
204204
// ... translate all other keys
205205
};
206206

packages/i18n/src/models/i18n.ts

Lines changed: 73 additions & 69 deletions
Original file line numberDiff line numberDiff line change
@@ -24,136 +24,140 @@ export interface I18nTranslations {
2424
/* |---------------------------------------------------------------| */
2525

2626
//* Buttons */
27-
'elements.buttons.signIn': string;
28-
'elements.buttons.signOut': string;
29-
'elements.buttons.signUp': string;
30-
'elements.buttons.facebook': string;
31-
'elements.buttons.google': string;
32-
'elements.buttons.github': string;
33-
'elements.buttons.microsoft': string;
34-
'elements.buttons.linkedin': string;
35-
'elements.buttons.ethereum': string;
36-
'elements.buttons.smsotp': string;
37-
'elements.buttons.multi.option': string;
38-
'elements.buttons.social': string;
27+
'elements.buttons.signin.text': string;
28+
'elements.buttons.signout.text': string;
29+
'elements.buttons.signup.text': string;
30+
'elements.buttons.submit.text': string;
31+
'elements.buttons.facebook.text': string;
32+
'elements.buttons.google.text': string;
33+
'elements.buttons.github.text': string;
34+
'elements.buttons.microsoft.text': string;
35+
'elements.buttons.linkedin.text': string;
36+
'elements.buttons.ethereum.text': string;
37+
'elements.buttons.smsotp.text': string;
38+
'elements.buttons.multi.option.text': string;
39+
'elements.buttons.social.text': string;
3940

4041
/* Fields */
41-
'elements.fields.placeholder': string;
42-
'elements.fields.username': string;
43-
'elements.fields.password': string;
44-
'elements.fields.ouName': string;
45-
'elements.fields.ouHandle': string;
46-
'elements.fields.ouDescription': string;
42+
'elements.fields.generic.placeholder': string;
43+
'elements.fields.username.label': string;
44+
'elements.fields.username.placeholder': string;
45+
'elements.fields.password.label': string;
46+
'elements.fields.password.placeholder': string;
47+
'elements.fields.first_name.label': string;
48+
'elements.fields.first_name.placeholder': string;
49+
'elements.fields.last_name.label': string;
50+
'elements.fields.last_name.placeholder': string;
51+
'elements.fields.email.label': string;
52+
'elements.fields.email.placeholder': string;
53+
'elements.fields.organization.name.label': string;
54+
'elements.fields.organization.handle.label': string;
55+
'elements.fields.organization.description.label': string;
56+
'elements.fields.organization.select.label': string;
57+
'elements.fields.organization.select.placeholder': string;
4758

4859
/* Validation */
49-
'field.required': string;
60+
'validations.required.field.error': string;
5061

5162
/* |---------------------------------------------------------------| */
5263
/* | Widgets | */
5364
/* |---------------------------------------------------------------| */
5465

5566
/* Base Sign In */
56-
'signin.title': string;
57-
'signin.subtitle': string;
67+
'signin.heading': string;
68+
'signin.subheading': string;
5869

5970
/* Base Sign Up */
60-
'signup.title': string;
61-
'signup.subtitle': string;
71+
'signup.heading': string;
72+
'signup.subheading': string;
6273

6374
/* Email OTP */
64-
'email.otp.title': string;
65-
'email.otp.subtitle': string;
66-
'email.otp.submit.button': string;
75+
'email.otp.heading': string;
76+
'email.otp.subheading': string;
77+
'email.otp.buttons.submit.text': string;
6778

6879
/* Identifier First */
69-
'identifier.first.title': string;
70-
'identifier.first.subtitle': string;
71-
'identifier.first.submit.button': string;
80+
'identifier.first.heading': string;
81+
'identifier.first.subheading': string;
82+
'identifier.first.buttons.submit.text': string;
7283

7384
/* SMS OTP */
74-
'sms.otp.title': string;
75-
'sms.otp.subtitle': string;
76-
'sms.otp.submit.button': string;
85+
'sms.otp.heading': string;
86+
'sms.otp.subheading': string;
87+
'sms.otp.buttons.submit.text': string;
7788

7889
/* TOTP */
79-
'totp.title': string;
80-
'totp.subtitle': string;
81-
'totp.submit.button': string;
90+
'totp.heading': string;
91+
'totp.subheading': string;
92+
'totp.buttons.submit.text': string;
8293

8394
/* Username Password */
84-
'username.password.submit.button': string;
85-
'username.password.title': string;
86-
'username.password.subtitle': string;
95+
'username.password.buttons.submit.text': string;
96+
'username.password.heading': string;
97+
'username.password.subheading': string;
8798

8899
/* |---------------------------------------------------------------| */
89100
/* | User Profile | */
90101
/* |---------------------------------------------------------------| */
91102

92-
'user.profile.title': string;
103+
'user.profile.heading': string;
93104
'user.profile.update.generic.error': string;
94105

95106
/* |---------------------------------------------------------------| */
96107
/* | Organization Switcher | */
97108
/* |---------------------------------------------------------------| */
98109

99-
'organization.switcher.select.organization': string;
100110
'organization.switcher.switch.organization': string;
101-
'organization.switcher.loading.organizations': string;
111+
'organization.switcher.loading.placeholder.organizations': string;
102112
'organization.switcher.members': string;
103113
'organization.switcher.member': string;
104114
'organization.switcher.create.organization': string;
105115
'organization.switcher.manage.organizations': string;
106-
'organization.switcher.manage.button': string;
107-
'organization.switcher.organizations.title': string;
108-
'organization.switcher.switch.button': string;
116+
'organization.switcher.buttons.manage.text': string;
117+
'organization.switcher.organizations.heading': string;
118+
'organization.switcher.buttons.switch.text': string;
109119
'organization.switcher.no.access': string;
110120
'organization.switcher.status.label': string;
111121
'organization.switcher.showing.count': string;
112-
'organization.switcher.refresh.button': string;
113-
'organization.switcher.load.more': string;
122+
'organization.switcher.buttons.refresh.text': string;
123+
'organization.switcher.buttons.load_more.text': string;
114124
'organization.switcher.loading.more': string;
115125
'organization.switcher.no.organizations': string;
116126
'organization.switcher.error.prefix': string;
117-
'organization.profile.title': string;
127+
'organization.profile.heading': string;
118128
'organization.profile.loading': string;
119129
'organization.profile.error': string;
120130

121131
/* |---------------------------------------------------------------| */
122132
/* | Organization Creation | */
123133
/* |---------------------------------------------------------------| */
124134

125-
'organization.create.title': string;
126-
'organization.create.name.label': string;
127-
'organization.create.name.placeholder': string;
128-
'organization.create.handle.label': string;
129-
'organization.create.handle.placeholder': string;
130-
'organization.create.description.label': string;
131-
'organization.create.description.placeholder': string;
132-
'organization.create.button': string;
133-
'organization.create.creating': string;
134-
'organization.create.cancel': string;
135+
'organization.create.heading': string;
136+
'organization.create.buttons.create_organization.text': string;
137+
'organization.create.buttons.create_organization.loading.text': string;
138+
'organization.create.buttons.cancel.text': string;
135139

136140
/* |---------------------------------------------------------------| */
137141
/* | Messages | */
138142
/* |---------------------------------------------------------------| */
139143

140-
'messages.loading': string;
144+
'messages.loading.placeholder': string;
141145

142146
/* |---------------------------------------------------------------| */
143147
/* | Errors | */
144148
/* |---------------------------------------------------------------| */
145149

146-
'errors.title': string;
147-
'errors.sign.in.initialization': string;
148-
'errors.sign.in.flow.failure': string;
149-
'errors.sign.in.flow.completion.failure': string;
150-
'errors.sign.in.flow.passkeys.failure': string;
151-
'errors.sign.in.flow.passkeys.completion.failure': string;
152-
'errors.sign.up.initialization': string;
153-
'errors.sign.up.flow.failure': string;
154-
'errors.sign.up.flow.initialization.failure': string;
155-
'errors.sign.up.components.not.available': string;
156-
'errors.sign.in.components.not.available': string;
150+
'errors.heading': string;
151+
'errors.signin.initialization': string;
152+
'errors.signin.flow.failure': string;
153+
'errors.signin.flow.completion.failure': string;
154+
'errors.signin.flow.passkeys.failure': string;
155+
'errors.signin.flow.passkeys.completion.failure': string;
156+
'errors.signup.initialization': string;
157+
'errors.signup.flow.failure': string;
158+
'errors.signup.flow.initialization.failure': string;
159+
'errors.signup.components.not.available': string;
160+
'errors.signin.components.not.available': string;
157161
}
158162

159163
export type I18nTextDirection = 'ltr' | 'rtl';

0 commit comments

Comments
 (0)