@block-auth.io/angular 0.5.1 → 0.7.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.
package/index.d.ts CHANGED
@@ -1,8 +1,8 @@
1
1
  import * as _angular_core from '@angular/core';
2
2
  import { EnvironmentProviders, Signal, OnInit, OnDestroy, Type } from '@angular/core';
3
3
  import * as _block_auth_io_core from '@block-auth.io/core';
4
- import { BlockAuthClient, BlockAuthClientConfig, Locale, TextKey, BlockAuthUserProfile, BlockAuthUserRole, TxnDataParam, SolicitedEmailChoice, SolicitedField, SolicitedDataForm, TxnDataRequest, openExtensionOnTxn } from '@block-auth.io/core';
5
- export { BlockAuthUserProfile, BlockAuthUserRole, Locale, TextKey, getUserRoleNames, getUserRoleSlugs, getUserRoles, hasAnyRole, hasAnyRoleBySlug, hasRole, hasRoleBySlug, loadUserProfile } from '@block-auth.io/core';
4
+ import { BlockAuthClient, BlockAuthClientConfig, Locale, TextKey, BlockAuthUserProfile, BlockAuthUserRole, PopupAuthCode, HostedLoginUser, AccountLinkErrorReason, TxnDataParam, SolicitedEmailChoice, SolicitedField, SolicitedDataForm, TxnDataRequest, openExtensionOnTxn } from '@block-auth.io/core';
5
+ export { BlockAuthUserProfile, BlockAuthUserRole, HostedLoginUser, Locale, PopupAuthCode, TextKey, getUserRoleNames, getUserRoleSlugs, getUserRoles, hasAnyRole, hasAnyRoleBySlug, hasRole, hasRoleBySlug, loadUserProfile } from '@block-auth.io/core';
6
6
  import { Store, StoreValue } from 'nanostores';
7
7
 
8
8
  /**
@@ -158,7 +158,7 @@ declare class DropdownProfileComponent {
158
158
  static ɵcmp: _angular_core.ɵɵComponentDeclaration<DropdownProfileComponent, "ba-dropdown-profile", never, { "onLogout": { "alias": "onLogout"; "required": false; "isSignal": true; }; "onNavigate": { "alias": "onNavigate"; "required": false; "isSignal": true; }; "isInsideModal": { "alias": "isInsideModal"; "required": false; "isSignal": true; }; "container": { "alias": "container"; "required": false; "isSignal": true; }; "disabled": { "alias": "disabled"; "required": false; "isSignal": true; }; "dropdownBtnSize": { "alias": "dropdownBtnSize"; "required": false; "isSignal": true; }; "dropdownBtnBgClassNames": { "alias": "dropdownBtnBgClassNames"; "required": false; "isSignal": true; }; "dropdownBtnTextColorClassNames": { "alias": "dropdownBtnTextColorClassNames"; "required": false; "isSignal": true; }; "dropdownBtnBorderClassNames": { "alias": "dropdownBtnBorderClassNames"; "required": false; "isSignal": true; }; "dropdownHeight": { "alias": "dropdownHeight"; "required": false; "isSignal": true; }; "additionalDropdownItems": { "alias": "additionalDropdownItems"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
159
159
  }
160
160
 
161
- declare class FlowBlockAuthComponent {
161
+ declare class FlowBlockAuthComponent implements OnInit {
162
162
  showDropdownWhenConnected: _angular_core.InputSignal<boolean>;
163
163
  isInsideModal: _angular_core.InputSignal<boolean>;
164
164
  /** Modal container that scopes the dropdown's click-outside listener when `isInsideModal`. */
@@ -174,6 +174,8 @@ declare class FlowBlockAuthComponent {
174
174
  additionalDropdownItems: _angular_core.InputSignal<DropdownProfileAdditionalItem[] | null>;
175
175
  /** Status-button label override. */
176
176
  buttonText: _angular_core.InputSignal<string>;
177
+ onAuthCode: _angular_core.InputSignal<((authCode: PopupAuthCode) => HostedLoginUser | Promise<HostedLoginUser>) | undefined>;
178
+ user: _angular_core.InputSignal<HostedLoginUser | null | undefined>;
177
179
  success: _angular_core.OutputEmitterRef<string | undefined>;
178
180
  errored: _angular_core.OutputEmitterRef<void>;
179
181
  loggedOut: _angular_core.OutputEmitterRef<void>;
@@ -181,18 +183,50 @@ declare class FlowBlockAuthComponent {
181
183
  protected readonly ws: _angular_core.Signal<_block_auth_io_core.WsState>;
182
184
  protected readonly ui: _angular_core.Signal<_block_auth_io_core.UiState>;
183
185
  private readonly locale;
186
+ private readonly client;
187
+ protected readonly isHosted: boolean;
188
+ protected readonly isPopupOpen: _angular_core.WritableSignal<boolean>;
189
+ private readonly userKey;
190
+ constructor();
191
+ ngOnInit(): void;
184
192
  private readonly isUiConfig;
193
+ private readonly ext;
194
+ private readonly isExtensionLocked;
185
195
  private readonly btnsTexts;
186
196
  protected readonly showDDP: _angular_core.Signal<boolean>;
187
197
  protected readonly bgClassNames: _angular_core.Signal<string>;
188
198
  protected readonly isLoading: _angular_core.Signal<boolean>;
189
199
  private readonly restoreDefault;
200
+ private readonly unlockOtpDefault;
190
201
  protected readonly label: _angular_core.Signal<string>;
202
+ private readonly hostedLoginDefault;
203
+ protected readonly hostedLoginLabel: _angular_core.Signal<string>;
191
204
  /** Reenvía el logout manual del dropdown al output `loggedOut`. */
192
205
  protected readonly onLogoutForwarder: () => void;
206
+ onHostedLoginClicked(): void;
193
207
  onFlowBAClicked(): void;
194
208
  static ɵfac: _angular_core.ɵɵFactoryDeclaration<FlowBlockAuthComponent, never>;
195
- static ɵcmp: _angular_core.ɵɵComponentDeclaration<FlowBlockAuthComponent, "ba-flow-block-auth", never, { "showDropdownWhenConnected": { "alias": "showDropdownWhenConnected"; "required": false; "isSignal": true; }; "isInsideModal": { "alias": "isInsideModal"; "required": false; "isSignal": true; }; "container": { "alias": "container"; "required": false; "isSignal": true; }; "btnClassNames": { "alias": "btnClassNames"; "required": false; "isSignal": true; }; "btnTextClassNames": { "alias": "btnTextClassNames"; "required": false; "isSignal": true; }; "dropdownBtnSize": { "alias": "dropdownBtnSize"; "required": false; "isSignal": true; }; "dropdownBtnBgClassNames": { "alias": "dropdownBtnBgClassNames"; "required": false; "isSignal": true; }; "dropdownBtnTextColorClassNames": { "alias": "dropdownBtnTextColorClassNames"; "required": false; "isSignal": true; }; "dropdownBtnBorderClassNames": { "alias": "dropdownBtnBorderClassNames"; "required": false; "isSignal": true; }; "dropdownHeight": { "alias": "dropdownHeight"; "required": false; "isSignal": true; }; "initializeSdk": { "alias": "initializeSdk"; "required": false; "isSignal": true; }; "additionalDropdownItems": { "alias": "additionalDropdownItems"; "required": false; "isSignal": true; }; "buttonText": { "alias": "buttonText"; "required": false; "isSignal": true; }; }, { "success": "success"; "errored": "errored"; "loggedOut": "loggedOut"; }, never, never, true, never>;
209
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<FlowBlockAuthComponent, "ba-flow-block-auth", never, { "showDropdownWhenConnected": { "alias": "showDropdownWhenConnected"; "required": false; "isSignal": true; }; "isInsideModal": { "alias": "isInsideModal"; "required": false; "isSignal": true; }; "container": { "alias": "container"; "required": false; "isSignal": true; }; "btnClassNames": { "alias": "btnClassNames"; "required": false; "isSignal": true; }; "btnTextClassNames": { "alias": "btnTextClassNames"; "required": false; "isSignal": true; }; "dropdownBtnSize": { "alias": "dropdownBtnSize"; "required": false; "isSignal": true; }; "dropdownBtnBgClassNames": { "alias": "dropdownBtnBgClassNames"; "required": false; "isSignal": true; }; "dropdownBtnTextColorClassNames": { "alias": "dropdownBtnTextColorClassNames"; "required": false; "isSignal": true; }; "dropdownBtnBorderClassNames": { "alias": "dropdownBtnBorderClassNames"; "required": false; "isSignal": true; }; "dropdownHeight": { "alias": "dropdownHeight"; "required": false; "isSignal": true; }; "initializeSdk": { "alias": "initializeSdk"; "required": false; "isSignal": true; }; "additionalDropdownItems": { "alias": "additionalDropdownItems"; "required": false; "isSignal": true; }; "buttonText": { "alias": "buttonText"; "required": false; "isSignal": true; }; "onAuthCode": { "alias": "onAuthCode"; "required": false; "isSignal": true; }; "user": { "alias": "user"; "required": false; "isSignal": true; }; }, { "success": "success"; "errored": "errored"; "loggedOut": "loggedOut"; }, never, never, true, never>;
210
+ }
211
+
212
+ declare class LinkBlockAuthComponent implements OnInit {
213
+ buttonText: _angular_core.InputSignal<string>;
214
+ btnClassNames: _angular_core.InputSignal<string>;
215
+ btnTextClassNames: _angular_core.InputSignal<string>;
216
+ linked: _angular_core.OutputEmitterRef<void>;
217
+ errored: _angular_core.OutputEmitterRef<AccountLinkErrorReason>;
218
+ private readonly ba;
219
+ private readonly client;
220
+ private readonly locale;
221
+ protected readonly canLink: _angular_core.WritableSignal<boolean>;
222
+ protected readonly isPopupOpen: _angular_core.WritableSignal<boolean>;
223
+ private readonly linkDefault;
224
+ protected readonly linkLabel: _angular_core.Signal<string>;
225
+ ngOnInit(): void;
226
+ onLinkClicked(): void;
227
+ private refreshStatus;
228
+ static ɵfac: _angular_core.ɵɵFactoryDeclaration<LinkBlockAuthComponent, never>;
229
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<LinkBlockAuthComponent, "ba-link-block-auth", never, { "buttonText": { "alias": "buttonText"; "required": false; "isSignal": true; }; "btnClassNames": { "alias": "btnClassNames"; "required": false; "isSignal": true; }; "btnTextClassNames": { "alias": "btnTextClassNames"; "required": false; "isSignal": true; }; }, { "linked": "linked"; "errored": "errored"; }, never, never, true, never>;
196
230
  }
197
231
 
198
232
  /**
@@ -1151,5 +1185,5 @@ declare class PermissionsRequiredModalComponent {
1151
1185
  static ɵcmp: _angular_core.ɵɵComponentDeclaration<PermissionsRequiredModalComponent, "ba-permissions-required-modal", never, {}, {}, never, never, true, never>;
1152
1186
  }
1153
1187
 
1154
- export { BlockAuthRuntimeDirective, BlockAuthService, BtnBaseProviderComponent, BtnBlockAuthComponent, BtnGmailComponent, BtnGoogleBaseComponent, BtnMetamaskComponent, BtnMicrosoftComponent, BtnPhantomComponent, BtnSigninComponent, BtnWalletConnectComponent, ChangeAccountComponent, ContentSigninComponent, ContentSignupComponent, DropdownProfileBtnComponent, DropdownProfileComponent, DropdownProfileItemComponent, FlowBlockAuthComponent, FooterSectionComponent, LoginSectionComponent, ModalOverlayComponent, ModalRestorationExpiredComponent, ModalRestoreComponent, ModalSigninComponent, ModalSignupComponent, PermissionsRequiredModalComponent, ProvidersButtonsComponent, ProvidersFiltersComponent, ProvidersSectionComponent, SelectedButtonComponent, SolicitedDataModalComponent, TeleportBodyDirective, TxnComponent, TxnErrorComponent, TxnTypeComponent, TxnsOverviewComponent, injectBlockAuthClient, injectStore, makeWebTypeItems, provideBlockAuth };
1188
+ export { BlockAuthRuntimeDirective, BlockAuthService, BtnBaseProviderComponent, BtnBlockAuthComponent, BtnGmailComponent, BtnGoogleBaseComponent, BtnMetamaskComponent, BtnMicrosoftComponent, BtnPhantomComponent, BtnSigninComponent, BtnWalletConnectComponent, ChangeAccountComponent, ContentSigninComponent, ContentSignupComponent, DropdownProfileBtnComponent, DropdownProfileComponent, DropdownProfileItemComponent, FlowBlockAuthComponent, FooterSectionComponent, LinkBlockAuthComponent, LoginSectionComponent, ModalOverlayComponent, ModalRestorationExpiredComponent, ModalRestoreComponent, ModalSigninComponent, ModalSignupComponent, PermissionsRequiredModalComponent, ProvidersButtonsComponent, ProvidersFiltersComponent, ProvidersSectionComponent, SelectedButtonComponent, SolicitedDataModalComponent, TeleportBodyDirective, TxnComponent, TxnErrorComponent, TxnTypeComponent, TxnsOverviewComponent, injectBlockAuthClient, injectStore, makeWebTypeItems, provideBlockAuth };
1155
1189
  export type { DropdownProfileAdditionalItem, ParamChange, ShareChange, WebTypeItem };
package/package.json CHANGED
@@ -1,8 +1,8 @@
1
1
  {
2
2
  "name": "@block-auth.io/angular",
3
- "version": "0.5.1",
3
+ "version": "0.7.0",
4
4
  "dependencies": {
5
- "@block-auth.io/core": "0.13.1",
5
+ "@block-auth.io/core": "0.14.0",
6
6
  "@block-auth.io/ui-styles": "0.7.0",
7
7
  "nanostores": "^0.10.0",
8
8
  "tslib": "^2.6.0"