diff --git a/Safari/ExtensionPay Dev extension/ExtensionPay Dev extension.xcodeproj/project.xcworkspace/xcuserdata/glen.xcuserdatad/UserInterfaceState.xcuserstate b/Safari/ExtensionPay Dev extension/ExtensionPay Dev extension.xcodeproj/project.xcworkspace/xcuserdata/glen.xcuserdatad/UserInterfaceState.xcuserstate index fa3d00c..770172c 100644 Binary files a/Safari/ExtensionPay Dev extension/ExtensionPay Dev extension.xcodeproj/project.xcworkspace/xcuserdata/glen.xcuserdatad/UserInterfaceState.xcuserstate and b/Safari/ExtensionPay Dev extension/ExtensionPay Dev extension.xcodeproj/project.xcworkspace/xcuserdata/glen.xcuserdatad/UserInterfaceState.xcuserstate differ diff --git a/Safari/ExtensionPay Dev extension/Shared (Extension)/Resources/ExtPay.js b/Safari/ExtensionPay Dev extension/Shared (Extension)/Resources/ExtPay.js index 5bcb28e..016ae71 100644 --- a/Safari/ExtensionPay Dev extension/Shared (Extension)/Resources/ExtPay.js +++ b/Safari/ExtensionPay Dev extension/Shared (Extension)/Resources/ExtPay.js @@ -1407,7 +1407,7 @@ You can copy and paste this to your manifest.json file to fix this error: } async function open_popup(url, width, height) { - if (browserPolyfill.windows) { + if (browserPolyfill.windows && browserPolyfill.windows.create) { const current_window = await browserPolyfill.windows.getCurrent(); // https://stackoverflow.com/a/68456858 const left = Math.round((current_window.width - width) * 0.5 + current_window.left); diff --git a/package.json b/package.json index 5ee6f96..203e185 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "extpay", - "version": "3.0.6", + "version": "3.0.7", "description": "The JavaScript library for https://extensionpay.com - payments for browser extensions, no server needed.", "main": "./dist/ExtPay.common.js", "module": "./dist/ExtPay.module.js", diff --git a/types.d.ts b/types.d.ts index ac24e54..3a28e42 100644 --- a/types.d.ts +++ b/types.d.ts @@ -28,6 +28,7 @@ declare module "extpay" { addListener: (cb: (user: User) => void) => void } openPaymentPage: () => Promise + openLoginPage: () => Promise openTrialPage: (displayText?: string) => Promise onTrialStarted: { addListener: (cb: (user: User) => void) => void