@explorins/pers-signer 1.0.5 → 1.0.8

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/dist/index.d.ts CHANGED
@@ -459,11 +459,6 @@ interface SigningResult$1 {
459
459
  transactionHash?: string;
460
460
  rawTransaction?: string;
461
461
  }
462
- /**
463
- * Environment variable types for shared services
464
- */
465
- interface SharedLibEnvironment {
466
- }
467
462
  /**
468
463
  * Service configuration options
469
464
  */
@@ -1201,4 +1196,4 @@ interface TenantConfig {
1201
1196
  declare const initTenantAnalytics: (tenantId: string, getTenantConfig: (id: string) => TenantConfig | null) => void;
1202
1197
 
1203
1198
  export { AuthenticationService, FetchHttpClient, KeyWallet, PersService, PersSignerSDK, ReactNativeConfigProvider, SIGNABLE_STATUSES, SigningService, StaticConfigProvider, TransactionErrorHandler, TransactionSigningErrorCode, TransactionSigningService, TransactionSubmissionHandler, TransactionValidator, WalletService, WebAuthnCoordinator, WebConfigProvider, createPersSignerSDK, createSearchParamLogger, createSearchString, createUrlWithSearchParams, generateAnonymousUsername, generateGuestUsername, generateUUID, getAllSearchParams, getBrowserWebAuthnProvider, getConfigProvider, getHttpClient, getReactNativeWebAuthnProvider, getSearchParam, getServiceConfig, initTenantAnalytics, logSearchParams, mergeSearchParams, removeSearchParam, setConfigProvider, setHttpClient, updateSearchParam };
1204
- export type { ApiResponse, AuthResponse, AuthState, AuthToken, AuthenticationResult, CombinedTransactionStatus, ConfigProvider, HashSigningRequest, HttpClient, HttpRequestOptions, HttpResponse, JWTExtractionResult, JWTPayload, WalletItem$1 as KeyWalletItem, WalletListResponse$1 as KeyWalletListResponse, PersAuthResult, PersSignerConfig, PreparedTransaction, RegistrationChallenge, RegistrationResult, RelyingPartyConfig, ServiceConfig$1 as ServiceConfig, ServiceError, SharedLibEnvironment, SignResponse, SignerAuthenticatedUser, SignerUserInfo, SigningAuthTokens, SigningChallenge, SigningRequest, SigningResult$1 as SigningResult, StoredTransactionResult, SubmissionResult, TenantConfig, TransactionMetadata, TransactionSigningError, TransactionSigningParams, TransactionSigningResult, TransactionStatusInfo, TypedDataSigningRequest, UserCredentials, UserProfile, WalletConfig, WalletItem, WalletListResponse, WebAuthnConfig, WebAuthnProvider };
1199
+ export type { ApiResponse, AuthResponse, AuthState, AuthToken, AuthenticationResult, CombinedTransactionStatus, ConfigProvider, HashSigningRequest, HttpClient, HttpRequestOptions, HttpResponse, JWTExtractionResult, JWTPayload, WalletItem$1 as KeyWalletItem, WalletListResponse$1 as KeyWalletListResponse, PersAuthResult, PersSignerConfig, PreparedTransaction, RegistrationChallenge, RegistrationResult, RelyingPartyConfig, ServiceConfig$1 as ServiceConfig, ServiceError, SignResponse, SignerAuthenticatedUser, SignerUserInfo, SigningAuthTokens, SigningChallenge, SigningRequest, SigningResult$1 as SigningResult, StoredTransactionResult, SubmissionResult, TenantConfig, TransactionMetadata, TransactionSigningError, TransactionSigningParams, TransactionSigningResult, TransactionStatusInfo, TypedDataSigningRequest, UserCredentials, UserProfile, WalletConfig, WalletItem, WalletListResponse, WebAuthnConfig, WebAuthnProvider };
package/dist/index.esm.js CHANGED
@@ -468,7 +468,8 @@ const SIGNER_CONFIG = {
468
468
  * Default relying party name for WebAuthn operations
469
469
  * This appears in the browser's authentication prompts
470
470
  */
471
- DEFAULT_RELYING_PARTY_NAME: 'PERS Signer'};
471
+ DEFAULT_RELYING_PARTY_NAME: 'PERS Signer',
472
+ DEFAULT_RELYING_PARTY_ID: 'signer.pers.ninja'};
472
473
 
473
474
  /**
474
475
  * Get PERS API base URL with staging option
@@ -1664,9 +1665,9 @@ class DfnsBrowserWebAuthnProvider {
1664
1665
  async function getBrowserWebAuthnProvider() {
1665
1666
  const config = {
1666
1667
  relyingParty: {
1667
- id: typeof window !== 'undefined' ? window.location.hostname : 'pers.ninja',
1668
- name: 'PERS Blockchain Signer',
1669
- origin: typeof window !== 'undefined' ? window.location.origin : 'https://pers.ninja',
1668
+ id: typeof window !== 'undefined' ? window.location.hostname : SIGNER_CONFIG.DEFAULT_RELYING_PARTY_ID,
1669
+ name: SIGNER_CONFIG.DEFAULT_RELYING_PARTY_NAME,
1670
+ origin: typeof window !== 'undefined' ? window.location.origin : SIGNER_CONFIG.DEFAULT_RELYING_PARTY_ID,
1670
1671
  }
1671
1672
  };
1672
1673
  return new DfnsBrowserWebAuthnProvider(config);
@@ -1736,8 +1737,8 @@ class DfnsReactNativeWebAuthnProvider {
1736
1737
  async function getReactNativeWebAuthnProvider() {
1737
1738
  const config = {
1738
1739
  relyingParty: {
1739
- id: 'pers.ninja',
1740
- name: 'PERS Blockchain Signer',
1740
+ id: SIGNER_CONFIG.DEFAULT_RELYING_PARTY_ID,
1741
+ name: SIGNER_CONFIG.DEFAULT_RELYING_PARTY_NAME,
1741
1742
  }
1742
1743
  };
1743
1744
  return new DfnsReactNativeWebAuthnProvider(config);