diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index ae940efe9..0f4284af6 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -10,14 +10,14 @@ jobs: runs-on: ubuntu-20.04 steps: - name: Checkout - uses: actions/checkout@v2 + uses: actions/checkout@v4 with: ssh-key: ${{ secrets.COMMIT_KEY }} fetch-depth: 0 - name: Setup Node.js - uses: actions/setup-node@v1 + uses: actions/setup-node@v4 with: - node-version: 18 + node-version: 20 - name: Install dependencies run: npm ci - name: Run semantic release @@ -30,12 +30,12 @@ jobs: runs-on: ubuntu-20.04 steps: - name: Checkout - uses: actions/checkout@v2 + uses: actions/checkout@v4 with: ssh-key: ${{ secrets.COMMIT_KEY }} fetch-depth: 0 - name: Setup Node.js - uses: actions/setup-node@v1 + uses: actions/setup-node@v4 with: node-version: 18 - name: Install dependencies diff --git a/.github/workflows/s3cdn.yml b/.github/workflows/s3cdn.yml deleted file mode 100644 index 0d5136754..000000000 --- a/.github/workflows/s3cdn.yml +++ /dev/null @@ -1,28 +0,0 @@ -name: S3 CDN upload - -on: - push: - tags: - - '*' -jobs: - test: - runs-on: ubuntu-20.04 - steps: - - name: Checkout Foxy/foxy-elements - uses: actions/checkout@v2 - - name: Setup Node.js - uses: actions/setup-node@v1 - with: - node-version: 18 - - name: Install dependencies - run: npm ci - - name: Build - run: npm run prepack - - uses: Foxy/foxy-github-action-s3cdn@main - with: - package-name: elements # optional: Default is repo name. - env: - AWS_S3_CDN_BUCKET_NAME: ${{ secrets.AWS_S3_CDN_BUCKET_NAME }} - AWS_S3_CDN_KEY_ID: ${{ secrets.AWS_S3_CDN_KEY_ID }} - AWS_S3_CDN_KEY_SECRET: ${{ secrets.AWS_S3_CDN_KEY_SECRET }} - SOURCE_DIR: 'dist/cdn' # optional: defaults to `dist` directory diff --git a/.scripts/generate-schemas.js b/.scripts/generate-schemas.js deleted file mode 100644 index 1bc0f47e1..000000000 --- a/.scripts/generate-schemas.js +++ /dev/null @@ -1,53 +0,0 @@ -import { readdir, readFile, writeFile } from 'fs/promises'; - -async function updateVSCodeSettings(namespaces) { - const settingsURL = new URL('../.vscode/settings.json', import.meta.url); - const settings = await readFile(settingsURL, { encoding: 'utf-8' }); - const parsedSettings = JSON.parse(settings); - - parsedSettings['json.schemas'] = namespaces.map(ns => ({ - fileMatch: [`/src/static/translations/${ns}/*.json`], - url: `./src/static/schemas/${ns}.json`, - })); - - await writeFile(settingsURL, JSON.stringify(parsedSettings), { encoding: 'utf-8' }); -} - -async function writeSchemaForNs(ns) { - const generateNestedSchema = translations => { - const properties = generateProperties(translations); - return { - additionalProperties: false, - properties: properties, - required: Array.from(Object.keys(properties)), - }; - }; - - const generateProperties = translations => { - return Object.fromEntries( - Object.entries(translations).map(([key, value]) => { - if (typeof value === 'object') return [key, generateNestedSchema(value)]; - return [key, { type: 'string', default: value }]; - }) - ); - }; - - const enTranslationURL = new URL(`../src/static/translations/${ns}/en.json`, import.meta.url); - const enTranslation = await readFile(enTranslationURL, { encoding: 'utf-8' }); - const schema = JSON.stringify({ - $schema: 'http://json-schema.org/draft-07/schema', - ...generateNestedSchema(JSON.parse(enTranslation)), - }); - - const schemaURL = new URL(`../src/static/schemas/${ns}.json`, import.meta.url); - await writeFile(schemaURL, schema, { encoding: 'utf-8' }); -} - -const translationFilesURL = new URL('../src/static/translations', import.meta.url); -const translationFiles = await readdir(translationFilesURL, { withFileTypes: true }); -const namespaces = translationFiles - .filter(file => file.isDirectory && !file.name.startsWith('.')) - .map(file => file.name); - -await Promise.all(namespaces.map(ns => writeSchemaForNs(ns))); -await updateVSCodeSettings(namespaces); diff --git a/.vscode/settings.json b/.vscode/settings.json deleted file mode 100644 index 4dc213508..000000000 --- a/.vscode/settings.json +++ /dev/null @@ -1,428 +0,0 @@ -{ - "json.schemas": [ - { - "fileMatch": ["/src/static/translations/access-recovery-form/*.json"], - "url": "./src/static/schemas/access-recovery-form.json" - }, - { - "fileMatch": ["/src/static/translations/address-card/*.json"], - "url": "./src/static/schemas/address-card.json" - }, - { - "fileMatch": ["/src/static/translations/address-form/*.json"], - "url": "./src/static/schemas/address-form.json" - }, - { - "fileMatch": ["/src/static/translations/admin-subscription-card/*.json"], - "url": "./src/static/schemas/admin-subscription-card.json" - }, - { - "fileMatch": ["/src/static/translations/api-browser/*.json"], - "url": "./src/static/schemas/api-browser.json" - }, - { - "fileMatch": ["/src/static/translations/applied-coupon-code-card/*.json"], - "url": "./src/static/schemas/applied-coupon-code-card.json" - }, - { - "fileMatch": ["/src/static/translations/applied-coupon-code-form/*.json"], - "url": "./src/static/schemas/applied-coupon-code-form.json" - }, - { - "fileMatch": ["/src/static/translations/applied-tax-card/*.json"], - "url": "./src/static/schemas/applied-tax-card.json" - }, - { - "fileMatch": ["/src/static/translations/attribute-card/*.json"], - "url": "./src/static/schemas/attribute-card.json" - }, - { - "fileMatch": ["/src/static/translations/attribute-form/*.json"], - "url": "./src/static/schemas/attribute-form.json" - }, - { - "fileMatch": ["/src/static/translations/billing-address-card/*.json"], - "url": "./src/static/schemas/billing-address-card.json" - }, - { - "fileMatch": ["/src/static/translations/cancellation-form/*.json"], - "url": "./src/static/schemas/cancellation-form.json" - }, - { - "fileMatch": ["/src/static/translations/cart-card/*.json"], - "url": "./src/static/schemas/cart-card.json" - }, - { - "fileMatch": ["/src/static/translations/cart-form/*.json"], - "url": "./src/static/schemas/cart-form.json" - }, - { - "fileMatch": ["/src/static/translations/client-card/*.json"], - "url": "./src/static/schemas/client-card.json" - }, - { - "fileMatch": ["/src/static/translations/client-form/*.json"], - "url": "./src/static/schemas/client-form.json" - }, - { - "fileMatch": ["/src/static/translations/copy-to-clipboard/*.json"], - "url": "./src/static/schemas/copy-to-clipboard.json" - }, - { - "fileMatch": ["/src/static/translations/country/*.json"], - "url": "./src/static/schemas/country.json" - }, - { - "fileMatch": ["/src/static/translations/coupon-card/*.json"], - "url": "./src/static/schemas/coupon-card.json" - }, - { - "fileMatch": ["/src/static/translations/coupon-code-card/*.json"], - "url": "./src/static/schemas/coupon-code-card.json" - }, - { - "fileMatch": ["/src/static/translations/coupon-code-form/*.json"], - "url": "./src/static/schemas/coupon-code-form.json" - }, - { - "fileMatch": ["/src/static/translations/coupon-codes-form/*.json"], - "url": "./src/static/schemas/coupon-codes-form.json" - }, - { - "fileMatch": ["/src/static/translations/coupon-form/*.json"], - "url": "./src/static/schemas/coupon-form.json" - }, - { - "fileMatch": ["/src/static/translations/custom-field-card/*.json"], - "url": "./src/static/schemas/custom-field-card.json" - }, - { - "fileMatch": ["/src/static/translations/custom-field-form/*.json"], - "url": "./src/static/schemas/custom-field-form.json" - }, - { - "fileMatch": ["/src/static/translations/customer/*.json"], - "url": "./src/static/schemas/customer.json" - }, - { - "fileMatch": ["/src/static/translations/customer-card/*.json"], - "url": "./src/static/schemas/customer-card.json" - }, - { - "fileMatch": ["/src/static/translations/customer-form/*.json"], - "url": "./src/static/schemas/customer-form.json" - }, - { - "fileMatch": ["/src/static/translations/customer-portal/*.json"], - "url": "./src/static/schemas/customer-portal.json" - }, - { - "fileMatch": ["/src/static/translations/customer-portal-settings/*.json"], - "url": "./src/static/schemas/customer-portal-settings.json" - }, - { - "fileMatch": ["/src/static/translations/customer-portal-settings-form/*.json"], - "url": "./src/static/schemas/customer-portal-settings-form.json" - }, - { - "fileMatch": ["/src/static/translations/customers-table/*.json"], - "url": "./src/static/schemas/customers-table.json" - }, - { - "fileMatch": ["/src/static/translations/discount-builder/*.json"], - "url": "./src/static/schemas/discount-builder.json" - }, - { - "fileMatch": ["/src/static/translations/discount-card/*.json"], - "url": "./src/static/schemas/discount-card.json" - }, - { - "fileMatch": ["/src/static/translations/donation/*.json"], - "url": "./src/static/schemas/donation.json" - }, - { - "fileMatch": ["/src/static/translations/downloadable-card/*.json"], - "url": "./src/static/schemas/downloadable-card.json" - }, - { - "fileMatch": ["/src/static/translations/downloadable-form/*.json"], - "url": "./src/static/schemas/downloadable-form.json" - }, - { - "fileMatch": ["/src/static/translations/email-template-card/*.json"], - "url": "./src/static/schemas/email-template-card.json" - }, - { - "fileMatch": ["/src/static/translations/email-template-form/*.json"], - "url": "./src/static/schemas/email-template-form.json" - }, - { - "fileMatch": ["/src/static/translations/error-entry-card/*.json"], - "url": "./src/static/schemas/error-entry-card.json" - }, - { - "fileMatch": ["/src/static/translations/filter-attribute-card/*.json"], - "url": "./src/static/schemas/filter-attribute-card.json" - }, - { - "fileMatch": ["/src/static/translations/filter-attribute-form/*.json"], - "url": "./src/static/schemas/filter-attribute-form.json" - }, - { - "fileMatch": ["/src/static/translations/generate-codes-form/*.json"], - "url": "./src/static/schemas/generate-codes-form.json" - }, - { - "fileMatch": ["/src/static/translations/gift-card-card/*.json"], - "url": "./src/static/schemas/gift-card-card.json" - }, - { - "fileMatch": ["/src/static/translations/gift-card-code-card/*.json"], - "url": "./src/static/schemas/gift-card-code-card.json" - }, - { - "fileMatch": ["/src/static/translations/gift-card-code-form/*.json"], - "url": "./src/static/schemas/gift-card-code-form.json" - }, - { - "fileMatch": ["/src/static/translations/gift-card-code-log-card/*.json"], - "url": "./src/static/schemas/gift-card-code-log-card.json" - }, - { - "fileMatch": ["/src/static/translations/gift-card-codes-form/*.json"], - "url": "./src/static/schemas/gift-card-codes-form.json" - }, - { - "fileMatch": ["/src/static/translations/gift-card-form/*.json"], - "url": "./src/static/schemas/gift-card-form.json" - }, - { - "fileMatch": ["/src/static/translations/global/*.json"], - "url": "./src/static/schemas/global.json" - }, - { - "fileMatch": ["/src/static/translations/i18n-editor/*.json"], - "url": "./src/static/schemas/i18n-editor.json" - }, - { - "fileMatch": ["/src/static/translations/integration-card/*.json"], - "url": "./src/static/schemas/integration-card.json" - }, - { - "fileMatch": ["/src/static/translations/integration-form/*.json"], - "url": "./src/static/schemas/integration-form.json" - }, - { - "fileMatch": ["/src/static/translations/item-card/*.json"], - "url": "./src/static/schemas/item-card.json" - }, - { - "fileMatch": ["/src/static/translations/item-category-card/*.json"], - "url": "./src/static/schemas/item-category-card.json" - }, - { - "fileMatch": ["/src/static/translations/item-category-form/*.json"], - "url": "./src/static/schemas/item-category-form.json" - }, - { - "fileMatch": ["/src/static/translations/item-form/*.json"], - "url": "./src/static/schemas/item-form.json" - }, - { - "fileMatch": ["/src/static/translations/item-option-form/*.json"], - "url": "./src/static/schemas/item-option-form.json" - }, - { - "fileMatch": ["/src/static/translations/items-form/*.json"], - "url": "./src/static/schemas/items-form.json" - }, - { - "fileMatch": ["/src/static/translations/native-integration-card/*.json"], - "url": "./src/static/schemas/native-integration-card.json" - }, - { - "fileMatch": ["/src/static/translations/native-integration-form/*.json"], - "url": "./src/static/schemas/native-integration-form.json" - }, - { - "fileMatch": ["/src/static/translations/pagination/*.json"], - "url": "./src/static/schemas/pagination.json" - }, - { - "fileMatch": ["/src/static/translations/passkey-card/*.json"], - "url": "./src/static/schemas/passkey-card.json" - }, - { - "fileMatch": ["/src/static/translations/passkey-form/*.json"], - "url": "./src/static/schemas/passkey-form.json" - }, - { - "fileMatch": ["/src/static/translations/payment-card/*.json"], - "url": "./src/static/schemas/payment-card.json" - }, - { - "fileMatch": ["/src/static/translations/payment-card-embed/*.json"], - "url": "./src/static/schemas/payment-card-embed.json" - }, - { - "fileMatch": ["/src/static/translations/payment-method-card/*.json"], - "url": "./src/static/schemas/payment-method-card.json" - }, - { - "fileMatch": ["/src/static/translations/payments-api-fraud-protection-card/*.json"], - "url": "./src/static/schemas/payments-api-fraud-protection-card.json" - }, - { - "fileMatch": ["/src/static/translations/payments-api-fraud-protection-form/*.json"], - "url": "./src/static/schemas/payments-api-fraud-protection-form.json" - }, - { - "fileMatch": ["/src/static/translations/payments-api-payment-method-card/*.json"], - "url": "./src/static/schemas/payments-api-payment-method-card.json" - }, - { - "fileMatch": ["/src/static/translations/payments-api-payment-method-form/*.json"], - "url": "./src/static/schemas/payments-api-payment-method-form.json" - }, - { - "fileMatch": ["/src/static/translations/payments-api-payment-preset-card/*.json"], - "url": "./src/static/schemas/payments-api-payment-preset-card.json" - }, - { - "fileMatch": ["/src/static/translations/payments-api-payment-preset-form/*.json"], - "url": "./src/static/schemas/payments-api-payment-preset-form.json" - }, - { - "fileMatch": ["/src/static/translations/query-builder/*.json"], - "url": "./src/static/schemas/query-builder.json" - }, - { - "fileMatch": ["/src/static/translations/region/*.json"], - "url": "./src/static/schemas/region.json" - }, - { - "fileMatch": ["/src/static/translations/report-form/*.json"], - "url": "./src/static/schemas/report-form.json" - }, - { - "fileMatch": ["/src/static/translations/reports-table/*.json"], - "url": "./src/static/schemas/reports-table.json" - }, - { - "fileMatch": ["/src/static/translations/shared/*.json"], - "url": "./src/static/schemas/shared.json" - }, - { - "fileMatch": ["/src/static/translations/shipment-card/*.json"], - "url": "./src/static/schemas/shipment-card.json" - }, - { - "fileMatch": ["/src/static/translations/shipping-method-card/*.json"], - "url": "./src/static/schemas/shipping-method-card.json" - }, - { - "fileMatch": ["/src/static/translations/sign-in-form/*.json"], - "url": "./src/static/schemas/sign-in-form.json" - }, - { - "fileMatch": ["/src/static/translations/spinner/*.json"], - "url": "./src/static/schemas/spinner.json" - }, - { - "fileMatch": ["/src/static/translations/store-card/*.json"], - "url": "./src/static/schemas/store-card.json" - }, - { - "fileMatch": ["/src/static/translations/store-form/*.json"], - "url": "./src/static/schemas/store-form.json" - }, - { - "fileMatch": ["/src/static/translations/store-shipping-method-form/*.json"], - "url": "./src/static/schemas/store-shipping-method-form.json" - }, - { - "fileMatch": ["/src/static/translations/subscription-card/*.json"], - "url": "./src/static/schemas/subscription-card.json" - }, - { - "fileMatch": ["/src/static/translations/subscription-form/*.json"], - "url": "./src/static/schemas/subscription-form.json" - }, - { - "fileMatch": ["/src/static/translations/subscription-settings-form/*.json"], - "url": "./src/static/schemas/subscription-settings-form.json" - }, - { - "fileMatch": ["/src/static/translations/subscriptions-table/*.json"], - "url": "./src/static/schemas/subscriptions-table.json" - }, - { - "fileMatch": ["/src/static/translations/tax-card/*.json"], - "url": "./src/static/schemas/tax-card.json" - }, - { - "fileMatch": ["/src/static/translations/tax-form/*.json"], - "url": "./src/static/schemas/tax-form.json" - }, - { - "fileMatch": ["/src/static/translations/template-config-form/*.json"], - "url": "./src/static/schemas/template-config-form.json" - }, - { - "fileMatch": ["/src/static/translations/template-form/*.json"], - "url": "./src/static/schemas/template-form.json" - }, - { - "fileMatch": ["/src/static/translations/template-set-card/*.json"], - "url": "./src/static/schemas/template-set-card.json" - }, - { - "fileMatch": ["/src/static/translations/template-set-form/*.json"], - "url": "./src/static/schemas/template-set-form.json" - }, - { - "fileMatch": ["/src/static/translations/transaction/*.json"], - "url": "./src/static/schemas/transaction.json" - }, - { - "fileMatch": ["/src/static/translations/transaction-card/*.json"], - "url": "./src/static/schemas/transaction-card.json" - }, - { - "fileMatch": ["/src/static/translations/transactions-table/*.json"], - "url": "./src/static/schemas/transactions-table.json" - }, - { - "fileMatch": ["/src/static/translations/update-payment-method-form/*.json"], - "url": "./src/static/schemas/update-payment-method-form.json" - }, - { - "fileMatch": ["/src/static/translations/user-card/*.json"], - "url": "./src/static/schemas/user-card.json" - }, - { - "fileMatch": ["/src/static/translations/user-form/*.json"], - "url": "./src/static/schemas/user-form.json" - }, - { - "fileMatch": ["/src/static/translations/users-table/*.json"], - "url": "./src/static/schemas/users-table.json" - }, - { - "fileMatch": ["/src/static/translations/webhook-card/*.json"], - "url": "./src/static/schemas/webhook-card.json" - }, - { - "fileMatch": ["/src/static/translations/webhook-form/*.json"], - "url": "./src/static/schemas/webhook-form.json" - }, - { - "fileMatch": ["/src/static/translations/webhook-log-card/*.json"], - "url": "./src/static/schemas/webhook-log-card.json" - }, - { - "fileMatch": ["/src/static/translations/webhook-status-card/*.json"], - "url": "./src/static/schemas/webhook-status-card.json" - } - ] -} diff --git a/custom-elements.json b/custom-elements.json index dbbe7c942..97265c13e 100644 --- a/custom-elements.json +++ b/custom-elements.json @@ -90,7 +90,6 @@ "properties": [ { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -254,26 +253,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "email:before" - }, - { - "name": "email:after" - }, - { - "name": "message:before" - }, - { - "name": "message:after" - }, - { - "name": "submit:before" - }, - { - "name": "submit:after" - } ] }, { @@ -365,7 +344,6 @@ "properties": [ { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -529,48 +507,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "address-name:before", - "description": "**new in v1.4.0**" - }, - { - "name": "address-name:after", - "description": "**new in v1.4.0**" - }, - { - "name": "full-name:before", - "description": "**new in v1.4.0**" - }, - { - "name": "full-name:after", - "description": "**new in v1.4.0**" - }, - { - "name": "full-address:before", - "description": "**new in v1.4.0**" - }, - { - "name": "full-address:after", - "description": "**new in v1.4.0**" - }, - { - "name": "company:before", - "description": "**new in v1.4.0**" - }, - { - "name": "company:after", - "description": "**new in v1.4.0**" - }, - { - "name": "phone:before", - "description": "**new in v1.4.0**" - }, - { - "name": "phone:after", - "description": "**new in v1.4.0**" - } ] }, { @@ -694,9 +630,33 @@ "description": "Status message to render at the top of the form. If `null`, the message is hidden.", "type": "object" }, + { + "name": "headerTitleKey", + "description": "Getter that returns a i18n key for the optional form header title.", + "type": "string" + }, + { + "name": "headerTitleOptions", + "description": "I18next options to pass to the header title translation function.", + "type": "Record" + }, + { + "name": "headerSubtitleKey", + "description": "Getter that returns a i18n key for the optional form header subtitle. Note that subtitle is shown only when data is avaiable.", + "type": "string" + }, + { + "name": "headerSubtitleOptions", + "description": "I18next options to pass to the header subtitle translation function. Note that subtitle is shown only when data is avaiable.", + "type": "Record" + }, + { + "name": "headerCopyIdValue", + "description": "ID that will be written to clipboard when Copy ID button in header is clicked.", + "type": "string | number" + }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -843,120 +803,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "address-name:before", - "description": "**new in v1.4.0**" - }, - { - "name": "address-name:after", - "description": "**new in v1.4.0**" - }, - { - "name": "first-name:before", - "description": "**new in v1.4.0**" - }, - { - "name": "first-name:after", - "description": "**new in v1.4.0**" - }, - { - "name": "last-name:before", - "description": "**new in v1.4.0**" - }, - { - "name": "last-name:after", - "description": "**new in v1.4.0**" - }, - { - "name": "region:before", - "description": "**new in v1.4.0**" - }, - { - "name": "region:after", - "description": "**new in v1.4.0**" - }, - { - "name": "city:before", - "description": "**new in v1.4.0**" - }, - { - "name": "city:after", - "description": "**new in v1.4.0**" - }, - { - "name": "phone:before", - "description": "**new in v1.4.0**" - }, - { - "name": "phone:after", - "description": "**new in v1.4.0**" - }, - { - "name": "company:before", - "description": "**new in v1.4.0**" - }, - { - "name": "company:after", - "description": "**new in v1.4.0**" - }, - { - "name": "address-one:before", - "description": "**new in v1.4.0**" - }, - { - "name": "address-one:after", - "description": "**new in v1.4.0**" - }, - { - "name": "address-two:before", - "description": "**new in v1.4.0**" - }, - { - "name": "address-two:after", - "description": "**new in v1.4.0**" - }, - { - "name": "country:before", - "description": "**new in v1.4.0**" - }, - { - "name": "country:after", - "description": "**new in v1.4.0**" - }, - { - "name": "postal-code:before", - "description": "**new in v1.4.0**" - }, - { - "name": "postal-code:after", - "description": "**new in v1.4.0**" - }, - { - "name": "timestamps:before", - "description": "**new in v1.4.0**" - }, - { - "name": "timestamps:after", - "description": "**new in v1.4.0**" - }, - { - "name": "create:before", - "description": "**new in v1.4.0**" - }, - { - "name": "create:after", - "description": "**new in v1.4.0**" - }, - { - "name": "delete:before", - "description": "**new in v1.4.0**" - }, - { - "name": "delete:after", - "description": "**new in v1.4.0**" - } ] }, { @@ -1597,7 +1443,6 @@ }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -1871,9 +1716,33 @@ "description": "Status message to render at the top of the form. If `null`, the message is hidden.", "type": "object" }, + { + "name": "headerTitleKey", + "description": "Getter that returns a i18n key for the optional form header title.", + "type": "string" + }, + { + "name": "headerTitleOptions", + "description": "I18next options to pass to the header title translation function.", + "type": "Record" + }, + { + "name": "headerSubtitleKey", + "description": "Getter that returns a i18n key for the optional form header subtitle. Note that subtitle is shown only when data is avaiable.", + "type": "string" + }, + { + "name": "headerSubtitleOptions", + "description": "I18next options to pass to the header subtitle translation function. Note that subtitle is shown only when data is avaiable.", + "type": "Record" + }, + { + "name": "headerCopyIdValue", + "description": "ID that will be written to clipboard when Copy ID button in header is clicked.", + "type": "string | number" + }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -2020,32 +1889,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "code:before" - }, - { - "name": "code:after" - }, - { - "name": "ignore-usage-limits:before" - }, - { - "name": "ignore-usage-limits:after" - }, - { - "name": "create:before" - }, - { - "name": "create:after" - }, - { - "name": "delete:before" - }, - { - "name": "delete:after" - } ] }, { @@ -2154,7 +1997,6 @@ }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -2305,20 +2147,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "title:before" - }, - { - "name": "title:after" - }, - { - "name": "subtitle:before" - }, - { - "name": "subtitle:after" - } ] }, { @@ -2427,7 +2255,6 @@ }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -2574,24 +2401,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "name:before", - "description": "**new in v1.4.0**" - }, - { - "name": "name:after", - "description": "**new in v1.4.0**" - }, - { - "name": "value:before", - "description": "**new in v1.4.0**" - }, - { - "name": "value:after", - "description": "**new in v1.4.0**" - } ] }, { @@ -2715,9 +2524,33 @@ "description": "Status message to render at the top of the form. If `null`, the message is hidden.", "type": "object" }, + { + "name": "headerTitleKey", + "description": "Getter that returns a i18n key for the optional form header title.", + "type": "string" + }, + { + "name": "headerTitleOptions", + "description": "I18next options to pass to the header title translation function.", + "type": "Record" + }, + { + "name": "headerSubtitleKey", + "description": "Getter that returns a i18n key for the optional form header subtitle. Note that subtitle is shown only when data is avaiable.", + "type": "string" + }, + { + "name": "headerSubtitleOptions", + "description": "I18next options to pass to the header subtitle translation function. Note that subtitle is shown only when data is avaiable.", + "type": "Record" + }, + { + "name": "headerCopyIdValue", + "description": "ID that will be written to clipboard when Copy ID button in header is clicked.", + "type": "string | number" + }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -2864,56 +2697,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "name:before", - "description": "**new in v1.4.0**" - }, - { - "name": "name:after", - "description": "**new in v1.4.0**" - }, - { - "name": "value:before", - "description": "**new in v1.4.0**" - }, - { - "name": "value:after", - "description": "**new in v1.4.0**" - }, - { - "name": "visibility:before", - "description": "**new in v1.4.0**" - }, - { - "name": "visibility:after", - "description": "**new in v1.4.0**" - }, - { - "name": "timestamps:before", - "description": "**new in v1.4.0**" - }, - { - "name": "timestamps:after", - "description": "**new in v1.4.0**" - }, - { - "name": "create:before", - "description": "**new in v1.4.0**" - }, - { - "name": "create:after", - "description": "**new in v1.4.0**" - }, - { - "name": "delete:before", - "description": "**new in v1.4.0**" - }, - { - "name": "delete:after", - "description": "**new in v1.4.0**" - } ] }, { @@ -3176,7 +2959,6 @@ "properties": [ { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -3341,26 +3123,6 @@ "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } ], - "slots": [ - { - "name": "warning:before" - }, - { - "name": "warning:after" - }, - { - "name": "end-date:before" - }, - { - "name": "end-date:after" - }, - { - "name": "submit:before" - }, - { - "name": "submit:after" - } - ], "deprecated": true }, { @@ -3816,10 +3578,33 @@ "description": "Status message to render at the top of the form. If `null`, the message is hidden.", "type": "object" }, + { + "name": "headerTitleKey", + "description": "Getter that returns a i18n key for the optional form header title.", + "type": "string" + }, + { + "name": "headerTitleOptions", + "description": "I18next options to pass to the header title translation function.", + "type": "Record" + }, + { + "name": "headerSubtitleKey", + "description": "Getter that returns a i18n key for the optional form header subtitle. Note that subtitle is shown only when data is avaiable.", + "type": "string" + }, + { + "name": "headerSubtitleOptions", + "description": "I18next options to pass to the header subtitle translation function. Note that subtitle is shown only when data is avaiable.", + "type": "Record" + }, + { + "name": "headerCopyIdValue", + "description": "ID that will be written to clipboard when Copy ID button in header is clicked.", + "type": "string | number" + }, { "name": "templates", - "description": "Template render functions mapped to their name.", - "type": "Templates", "default": "{}" }, { @@ -3966,237 +3751,55 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ + ] + }, + { + "name": "foxy-client-card", + "path": "./src/elements/public/ClientCard/index.ts", + "description": "Card element representing a `fx:client` resource.", + "attributes": [ { - "name": "customer-type:before" + "name": "simplify-ns-loading", + "type": "boolean", + "default": "false" }, { - "name": "customer-type:after" + "name": "ns", + "type": "string", + "default": "\"defaultNS\"" }, { - "name": "customer:before" + "name": "lang", + "description": "Optional ISO 639-1 code describing the language element content is written in.\nChanging the `lang` attribute will update the value of this property.", + "type": "string", + "default": "\"\"" }, { - "name": "customer:after" + "name": "parent", + "description": "Optional URL of the collection this element's resource belongs to.\nChanging the `parent` attribute will update the value of this property.", + "type": "string", + "default": "\"\"" }, { - "name": "template-set-uri:before" + "name": "related", + "description": "Optional URI list of the related resources. If Rumour encounters a related\nresource on creation or deletion, it will be reloaded from source.", + "type": "array", + "default": "[]" }, { - "name": "template-set-uri:after" + "name": "virtual-host", + "description": "Unique identifier for the virtual host used by the element to serve internal requests.\n\nCurrently only one endpoint is supported: `foxy:///form/`.\nThis endpoint supports POST, GET, PATCH and DELETE methods and functions like a hAPI server.\n\nFor example, `GET foxy://nucleon-123/form/subscriptions/allowNextDateModification/0` on a NucleonElement\nwith `fx:customer_portal_settings` will return the first item of the `subscriptions.allowNextDateModification` array.", + "default": "\"uniqueId('nucleon-')\"" }, { - "name": "items:before" + "name": "group", + "description": "Rumour group. Elements in different groups will not share updates. Empty by default.", + "type": "string" }, { - "name": "items:after" - }, - { - "name": "applied-coupon-codes:before" - }, - { - "name": "applied-coupon-codes:after" - }, - { - "name": "custom-fields:before" - }, - { - "name": "custom-fields:after" - }, - { - "name": "attributes:before" - }, - { - "name": "attributes:after" - }, - { - "name": "billing-first-name:before" - }, - { - "name": "billing-first-name:after" - }, - { - "name": "billing-last-name:before" - }, - { - "name": "billing-last-name:after" - }, - { - "name": "billing-company:before" - }, - { - "name": "billing-company:after" - }, - { - "name": "billing-phone:before" - }, - { - "name": "billing-phone:after" - }, - { - "name": "billing-address-one:before" - }, - { - "name": "billing-address-one:after" - }, - { - "name": "billing-address-two:before" - }, - { - "name": "billing-address-two:after" - }, - { - "name": "billing-country:before" - }, - { - "name": "billing-country:after" - }, - { - "name": "billing-region:before" - }, - { - "name": "billing-region:after" - }, - { - "name": "billing-city:before" - }, - { - "name": "billing-city:after" - }, - { - "name": "billing-postal-code:before" - }, - { - "name": "billing-postal-code:after" - }, - { - "name": "shipping-first-name:before" - }, - { - "name": "shipping-first-name:after" - }, - { - "name": "shipping-last-name:before" - }, - { - "name": "shipping-last-name:after" - }, - { - "name": "shipping-company:before" - }, - { - "name": "shipping-company:after" - }, - { - "name": "shipping-phone:before" - }, - { - "name": "shipping-phone:after" - }, - { - "name": "shipping-address-one:before" - }, - { - "name": "shipping-address-one:after" - }, - { - "name": "shipping-address-two:before" - }, - { - "name": "shipping-address-two:after" - }, - { - "name": "shipping-country:before" - }, - { - "name": "shipping-country:after" - }, - { - "name": "shipping-region:before" - }, - { - "name": "shipping-region:after" - }, - { - "name": "shipping-city:before" - }, - { - "name": "shipping-city:after" - }, - { - "name": "shipping-postal-code:before" - }, - { - "name": "shipping-postal-code:after" - }, - { - "name": "view-as-customer:before" - }, - { - "name": "view-as-customer:after" - }, - { - "name": "delete:before" - }, - { - "name": "delete:after" - }, - { - "name": "create:before" - }, - { - "name": "create:after" - } - ] - }, - { - "name": "foxy-client-card", - "path": "./src/elements/public/ClientCard/index.ts", - "description": "Card element representing a `fx:client` resource.", - "attributes": [ - { - "name": "simplify-ns-loading", - "type": "boolean", - "default": "false" - }, - { - "name": "ns", - "type": "string", - "default": "\"defaultNS\"" - }, - { - "name": "lang", - "description": "Optional ISO 639-1 code describing the language element content is written in.\nChanging the `lang` attribute will update the value of this property.", - "type": "string", - "default": "\"\"" - }, - { - "name": "parent", - "description": "Optional URL of the collection this element's resource belongs to.\nChanging the `parent` attribute will update the value of this property.", - "type": "string", - "default": "\"\"" - }, - { - "name": "related", - "description": "Optional URI list of the related resources. If Rumour encounters a related\nresource on creation or deletion, it will be reloaded from source.", - "type": "array", - "default": "[]" - }, - { - "name": "virtual-host", - "description": "Unique identifier for the virtual host used by the element to serve internal requests.\n\nCurrently only one endpoint is supported: `foxy:///form/`.\nThis endpoint supports POST, GET, PATCH and DELETE methods and functions like a hAPI server.\n\nFor example, `GET foxy://nucleon-123/form/subscriptions/allowNextDateModification/0` on a NucleonElement\nwith `fx:customer_portal_settings` will return the first item of the `subscriptions.allowNextDateModification` array.", - "default": "\"uniqueId('nucleon-')\"" - }, - { - "name": "group", - "description": "Rumour group. Elements in different groups will not share updates. Empty by default.", - "type": "string" - }, - { - "name": "href", - "description": "Optional URL of the resource to load. Switches element to `idle.template` state if empty (default).", - "type": "string" + "name": "href", + "description": "Optional URL of the resource to load. Switches element to `idle.template` state if empty (default).", + "type": "string" }, { "name": "infer", @@ -4442,9 +4045,33 @@ "description": "Status message to render at the top of the form. If `null`, the message is hidden.", "type": "object" }, + { + "name": "headerTitleKey", + "description": "Getter that returns a i18n key for the optional form header title.", + "type": "string" + }, + { + "name": "headerTitleOptions", + "description": "I18next options to pass to the header title translation function.", + "type": "Record" + }, + { + "name": "headerSubtitleKey", + "description": "Getter that returns a i18n key for the optional form header subtitle. Note that subtitle is shown only when data is avaiable.", + "type": "string" + }, + { + "name": "headerSubtitleOptions", + "description": "I18next options to pass to the header subtitle translation function. Note that subtitle is shown only when data is avaiable.", + "type": "Record" + }, + { + "name": "headerCopyIdValue", + "description": "ID that will be written to clipboard when Copy ID button in header is clicked.", + "type": "string | number" + }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -4591,92 +4218,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "client-id:before" - }, - { - "name": "client-id:after" - }, - { - "name": "client-secret:before" - }, - { - "name": "client-secret:after" - }, - { - "name": "redirect-uri:before" - }, - { - "name": "redirect-uri:after" - }, - { - "name": "project-name:before" - }, - { - "name": "project-name:after" - }, - { - "name": "project-description:before" - }, - { - "name": "project-description:after" - }, - { - "name": "company-name:before" - }, - { - "name": "company-name:after" - }, - { - "name": "company-url:before" - }, - { - "name": "company-url:after" - }, - { - "name": "company-logo:before" - }, - { - "name": "company-logo:after" - }, - { - "name": "contact-name:before" - }, - { - "name": "contact-name:after" - }, - { - "name": "contact-email:before" - }, - { - "name": "contact-email:after" - }, - { - "name": "contact-phone:before" - }, - { - "name": "contact-phone:after" - }, - { - "name": "timestamps:before" - }, - { - "name": "timestamps:after" - }, - { - "name": "create:before" - }, - { - "name": "create:after" - }, - { - "name": "delete:before" - }, - { - "name": "delete:after" - } ] }, { @@ -5175,6 +4716,11 @@ "path": "./src/elements/public/CopyToClipboard/index.ts", "description": "A simple \"click to copy\" button that takes the size of the font\nyour text is written in (considering that the font styles are applied to container).", "attributes": [ + { + "name": "icon", + "description": "Default icon.", + "type": "string" + }, { "name": "text", "description": "Text to copy.", @@ -5234,6 +4780,12 @@ } ], "properties": [ + { + "name": "icon", + "attribute": "icon", + "description": "Default icon.", + "type": "string" + }, { "name": "text", "attribute": "text", @@ -5415,7 +4967,6 @@ "properties": [ { "name": "templates", - "type": "Partial<{ 'total:before': Renderer; 'total:after': Renderer; 'status:before': Renderer; ... 4 more ...; 'customer:after': Renderer<...>; }>", "default": "{}" }, { @@ -5579,26 +5130,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "title:before" - }, - { - "name": "title:after" - }, - { - "name": "description:before" - }, - { - "name": "description:after" - }, - { - "name": "status:before" - }, - { - "name": "status:after" - } ] }, { @@ -5897,19 +5428,43 @@ "type": "object" }, { - "name": "templates", - "type": "Templates", - "default": "{}" + "name": "headerTitleKey", + "description": "Getter that returns a i18n key for the optional form header title.", + "type": "string" }, { - "name": "mode", - "attribute": "mode", - "type": "string", - "default": "\"production\"" + "name": "headerTitleOptions", + "description": "I18next options to pass to the header title translation function.", + "type": "Record" }, { - "name": "readonly", - "attribute": "readonly", + "name": "headerSubtitleKey", + "description": "Getter that returns a i18n key for the optional form header subtitle. Note that subtitle is shown only when data is avaiable.", + "type": "string" + }, + { + "name": "headerSubtitleOptions", + "description": "I18next options to pass to the header subtitle translation function. Note that subtitle is shown only when data is avaiable.", + "type": "Record" + }, + { + "name": "headerCopyIdValue", + "description": "ID that will be written to clipboard when Copy ID button in header is clicked.", + "type": "string | number" + }, + { + "name": "templates", + "default": "{}" + }, + { + "name": "mode", + "attribute": "mode", + "type": "string", + "default": "\"production\"" + }, + { + "name": "readonly", + "attribute": "readonly", "type": "boolean", "default": "false" }, @@ -6045,40 +5600,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "code:before" - }, - { - "name": "code:after" - }, - { - "name": "number-of-uses-to", - "description": "date:before – **new in v1.27.0**" - }, - { - "name": "", - "description": "transactions:before – **new in v1.27.0**" - }, - { - "name": "timestamps:before" - }, - { - "name": "timestamps:after" - }, - { - "name": "delete:before" - }, - { - "name": "delete:after" - }, - { - "name": "create:before" - }, - { - "name": "create:after" - } ] }, { @@ -6202,9 +5723,33 @@ "description": "Status message to render at the top of the form. If `null`, the message is hidden.", "type": "object" }, + { + "name": "headerTitleKey", + "description": "Getter that returns a i18n key for the optional form header title.", + "type": "string" + }, + { + "name": "headerTitleOptions", + "description": "I18next options to pass to the header title translation function.", + "type": "Record" + }, + { + "name": "headerSubtitleKey", + "description": "Getter that returns a i18n key for the optional form header subtitle. Note that subtitle is shown only when data is avaiable.", + "type": "string" + }, + { + "name": "headerSubtitleOptions", + "description": "I18next options to pass to the header subtitle translation function. Note that subtitle is shown only when data is avaiable.", + "type": "Record" + }, + { + "name": "headerCopyIdValue", + "description": "ID that will be written to clipboard when Copy ID button in header is clicked.", + "type": "string | number" + }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -6351,24 +5896,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "coupon-codes:before", - "description": "**new in v1.27.0**" - }, - { - "name": "coupon-codes:after", - "description": "**new in v1.27.0**" - }, - { - "name": "create:before", - "description": "**new in v1.27.0**" - }, - { - "name": "create:after", - "description": "**new in v1.27.0**" - } ] }, { @@ -6477,7 +6004,6 @@ }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -6628,20 +6154,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "title:before" - }, - { - "name": "title:after" - }, - { - "name": "subtitle:before" - }, - { - "name": "subtitle:after" - } ] }, { @@ -6768,6 +6280,31 @@ "description": "Status message to render at the top of the form. If `null`, the message is hidden.", "type": "object" }, + { + "name": "headerTitleKey", + "description": "Getter that returns a i18n key for the optional form header title.", + "type": "string" + }, + { + "name": "headerTitleOptions", + "description": "I18next options to pass to the header title translation function.", + "type": "Record" + }, + { + "name": "headerSubtitleKey", + "description": "Getter that returns a i18n key for the optional form header subtitle. Note that subtitle is shown only when data is avaiable.", + "type": "string" + }, + { + "name": "headerSubtitleOptions", + "description": "I18next options to pass to the header subtitle translation function. Note that subtitle is shown only when data is avaiable.", + "type": "Record" + }, + { + "name": "headerCopyIdValue", + "description": "ID that will be written to clipboard when Copy ID button in header is clicked.", + "type": "string | number" + }, { "name": "templates", "default": "{}" @@ -6916,134 +6453,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "import:before" - }, - { - "name": "import:after" - }, - { - "name": "generate:before" - }, - { - "name": "generate:after" - }, - { - "name": "name:before" - }, - { - "name": "name:after" - }, - { - "name": "rules:before" - }, - { - "name": "rules:after" - }, - { - "name": "coupon-codes:before" - }, - { - "name": "coupon-codes:after" - }, - { - "name": "item-option-restrictions:before" - }, - { - "name": "item-option-restrictions:after" - }, - { - "name": "product-code-restrictions:before" - }, - { - "name": "product-code-restrictions:after" - }, - { - "name": "category-restrictions:before" - }, - { - "name": "category-restrictions:after" - }, - { - "name": "number-of-uses-allowed:before" - }, - { - "name": "number-of-uses-allowed:after" - }, - { - "name": "number-of-uses-allowed-per-customer:before" - }, - { - "name": "number-of-uses-allowed-per-customer:after" - }, - { - "name": "number-of-uses-allowed-per-code:before" - }, - { - "name": "number-of-uses-allowed-per-code:after" - }, - { - "name": "start-date:before" - }, - { - "name": "start-date:after" - }, - { - "name": "end-date:before" - }, - { - "name": "end-date:after" - }, - { - "name": "inclusive-tax-rate:before" - }, - { - "name": "inclusive-tax-rate:after" - }, - { - "name": "options:before" - }, - { - "name": "options:after" - }, - { - "name": "customer-subscription-restrictions:before" - }, - { - "name": "customer-subscription-restrictions:after" - }, - { - "name": "customer-attribute-restrictions:before" - }, - { - "name": "customer-attribute-restrictions:after" - }, - { - "name": "attributes:before" - }, - { - "name": "attributes:after" - }, - { - "name": "create:before" - }, - { - "name": "create:after" - }, - { - "name": "delete:before" - }, - { - "name": "delete:after" - }, - { - "name": "timestamps:before" - }, - { - "name": "timestamps:after" - } ] }, { @@ -7152,7 +6561,6 @@ }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -7303,20 +6711,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "title:before" - }, - { - "name": "title:after" - }, - { - "name": "subtitle:before" - }, - { - "name": "subtitle:after" - } ] }, { @@ -7440,9 +6834,33 @@ "description": "Status message to render at the top of the form. If `null`, the message is hidden.", "type": "object" }, + { + "name": "headerTitleKey", + "description": "Getter that returns a i18n key for the optional form header title.", + "type": "string" + }, + { + "name": "headerTitleOptions", + "description": "I18next options to pass to the header title translation function.", + "type": "Record" + }, + { + "name": "headerSubtitleKey", + "description": "Getter that returns a i18n key for the optional form header subtitle. Note that subtitle is shown only when data is avaiable.", + "type": "string" + }, + { + "name": "headerSubtitleOptions", + "description": "I18next options to pass to the header subtitle translation function. Note that subtitle is shown only when data is avaiable.", + "type": "Record" + }, + { + "name": "headerCopyIdValue", + "description": "ID that will be written to clipboard when Copy ID button in header is clicked.", + "type": "string | number" + }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -7589,56 +7007,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "name:before", - "description": "**new in v1.4.0**" - }, - { - "name": "name:after", - "description": "**new in v1.4.0**" - }, - { - "name": "value:before", - "description": "**new in v1.4.0**" - }, - { - "name": "value:after", - "description": "**new in v1.4.0**" - }, - { - "name": "visibility:before", - "description": "**new in v1.4.0**" - }, - { - "name": "visibility:after", - "description": "**new in v1.4.0**" - }, - { - "name": "timestamps:before", - "description": "**new in v1.4.0**" - }, - { - "name": "timestamps:after", - "description": "**new in v1.4.0**" - }, - { - "name": "create:before", - "description": "**new in v1.4.0**" - }, - { - "name": "create:after", - "description": "**new in v1.4.0**" - }, - { - "name": "delete:before", - "description": "**new in v1.4.0**" - }, - { - "name": "delete:after", - "description": "**new in v1.4.0**" - } ] }, { @@ -7750,7 +7118,6 @@ }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -7914,181 +7281,59 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ + ] + }, + { + "name": "foxy-customer-api", + "path": "./src/elements/public/CustomerApi/index.ts", + "description": "Element connector for Customer API.", + "attributes": [ { - "name": "header:before", - "description": "**new in v1.4.0**" + "name": "base", + "description": "Bookmark URL for this API. This is where the tree traversal begins. We also use this URL as a base for relative paths.", + "type": "string" }, { - "name": "header:after", - "description": "**new in v1.4.0**" + "name": "level", + "description": "Numeric Consola log level. If omitted, Consola defaults will be used.", + "type": "number" }, { - "name": "header:actions:before", - "description": "**new in v1.4.0**" + "name": "storage", + "description": "Credentials storage implementing Web Storage API. Access tokens and other related info will be stored here. Defaults to in-memory storage.", + "type": "string" }, { - "name": "header:actions:after", - "description": "**new in v1.4.0**" + "name": "mode", + "type": "string", + "default": "\"production\"" }, { - "name": "header:actions:edit:before", - "description": "**new in v1.4.0**" + "name": "readonly", + "type": "boolean", + "default": "false" }, { - "name": "header:actions:edit:after", - "description": "**new in v1.4.0**" + "name": "readonlycontrols", + "default": "\"False\"" }, { - "name": "addresses:before", - "description": "**new in v1.4.0**" + "name": "disabled", + "type": "boolean", + "default": "false" }, { - "name": "addresses:after", - "description": "**new in v1.4.0**" + "name": "disabledcontrols", + "default": "\"False\"" }, { - "name": "addresses:actions:before", - "description": "**new in v1.4.0**" + "name": "hidden", + "type": "boolean", + "default": "false" }, { - "name": "addresses:actions:after", - "description": "**new in v1.4.0**" - }, - { - "name": "addresses:actions:create:before", - "description": "**new in v1.4.0**" - }, - { - "name": "addresses:actions:create:after", - "description": "**new in v1.4.0**" - }, - { - "name": "addresses:list:before", - "description": "**new in v1.4.0**" - }, - { - "name": "addresses:list:after", - "description": "**new in v1.4.0**" - }, - { - "name": "payment-methods:before", - "description": "**new in v1.4.0**" - }, - { - "name": "payment-methods:after", - "description": "**new in v1.4.0**" - }, - { - "name": "payment-methods:list:before", - "description": "**new in v1.4.0**" - }, - { - "name": "payment-methods:list:after", - "description": "**new in v1.4.0**" - }, - { - "name": "attributes:before", - "description": "**new in v1.4.0**" - }, - { - "name": "attributes:after", - "description": "**new in v1.4.0**" - }, - { - "name": "attributes:actions:before", - "description": "**new in v1.4.0**" - }, - { - "name": "attributes:actions:after", - "description": "**new in v1.4.0**" - }, - { - "name": "attributes:actions:create:before", - "description": "**new in v1.4.0**" - }, - { - "name": "attributes:actions:create:after", - "description": "**new in v1.4.0**" - }, - { - "name": "attributes:list:before", - "description": "**new in v1.4.0**" - }, - { - "name": "attributes:list:after", - "description": "**new in v1.4.0**" - }, - { - "name": "transactions:before", - "description": "**new in v1.4.0**" - }, - { - "name": "transactions:after", - "description": "**new in v1.4.0**" - }, - { - "name": "subscriptions:before", - "description": "**new in v1.4.0**" - }, - { - "name": "subscriptions:after", - "description": "**new in v1.4.0**" - } - ] - }, - { - "name": "foxy-customer-api", - "path": "./src/elements/public/CustomerApi/index.ts", - "description": "Element connector for Customer API.", - "attributes": [ - { - "name": "base", - "description": "Bookmark URL for this API. This is where the tree traversal begins. We also use this URL as a base for relative paths.", - "type": "string" - }, - { - "name": "level", - "description": "Numeric Consola log level. If omitted, Consola defaults will be used.", - "type": "number" - }, - { - "name": "storage", - "description": "Credentials storage implementing Web Storage API. Access tokens and other related info will be stored here. Defaults to in-memory storage.", - "type": "string" - }, - { - "name": "mode", - "type": "string", - "default": "\"production\"" - }, - { - "name": "readonly", - "type": "boolean", - "default": "false" - }, - { - "name": "readonlycontrols", - "default": "\"False\"" - }, - { - "name": "disabled", - "type": "boolean", - "default": "false" - }, - { - "name": "disabledcontrols", - "default": "\"False\"" - }, - { - "name": "hidden", - "type": "boolean", - "default": "false" - }, - { - "name": "hiddencontrols", - "default": "\"False\"" + "name": "hiddencontrols", + "default": "\"False\"" }, { "name": "infer", @@ -8305,7 +7550,6 @@ "properties": [ { "name": "templates", - "type": "Partial<{ 'name:before': Renderer; 'name:after': Renderer; 'email:before': Renderer; 'email:after': Renderer<...>; }>", "default": "{}" }, { @@ -8469,20 +7713,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "name:before" - }, - { - "name": "name:after" - }, - { - "name": "email:before" - }, - { - "name": "email:after" - } ] }, { @@ -8630,9 +7860,33 @@ "description": "Status message to render at the top of the form. If `null`, the message is hidden.", "type": "object" }, + { + "name": "headerTitleKey", + "description": "Getter that returns a i18n key for the optional form header title.", + "type": "string" + }, + { + "name": "headerTitleOptions", + "description": "I18next options to pass to the header title translation function.", + "type": "Record" + }, + { + "name": "headerSubtitleKey", + "description": "Getter that returns a i18n key for the optional form header subtitle. Note that subtitle is shown only when data is avaiable.", + "type": "string" + }, + { + "name": "headerSubtitleOptions", + "description": "I18next options to pass to the header subtitle translation function. Note that subtitle is shown only when data is avaiable.", + "type": "Record" + }, + { + "name": "headerCopyIdValue", + "description": "ID that will be written to clipboard when Copy ID button in header is clicked.", + "type": "string | number" + }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -8779,104 +8033,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "first-name:before", - "description": "**new in v1.4.0**" - }, - { - "name": "first-name:after", - "description": "**new in v1.4.0**" - }, - { - "name": "last-name:before", - "description": "**new in v1.4.0**" - }, - { - "name": "last-name:after", - "description": "**new in v1.4.0**" - }, - { - "name": "email:before", - "description": "**new in v1.4.0**" - }, - { - "name": "email:after", - "description": "**new in v1.4.0**" - }, - { - "name": "tax-id:before", - "description": "**new in v1.4.0**" - }, - { - "name": "tax-id:after", - "description": "**new in v1.4.0**" - }, - { - "name": "is-anonymous:before", - "description": "**new in v1.24.0**" - }, - { - "name": "is-anonymous:after", - "description": "**new in v1.24.0**" - }, - { - "name": "password:before", - "description": "**new in v1.24.0**" - }, - { - "name": "password:after", - "description": "**new in v1.24.0**" - }, - { - "name": "password-old:before", - "description": "**new in v1.24.0**" - }, - { - "name": "password-old:after", - "description": "**new in v1.24.0**" - }, - { - "name": "forgot-password:before", - "description": "**new in v1.24.0**" - }, - { - "name": "forgot-password:after", - "description": "**new in v1.24.0**" - }, - { - "name": "legal-notice:before", - "description": "**new in v1.24.0**" - }, - { - "name": "legal-notice:after", - "description": "**new in v1.24.0**" - }, - { - "name": "timestamps:before", - "description": "**new in v1.4.0**" - }, - { - "name": "timestamps:after", - "description": "**new in v1.4.0**" - }, - { - "name": "create:before", - "description": "**new in v1.4.0**" - }, - { - "name": "create:after", - "description": "**new in v1.4.0**" - }, - { - "name": "delete:before", - "description": "**new in v1.4.0**" - }, - { - "name": "delete:after", - "description": "**new in v1.4.0**" - } ] }, { @@ -9028,9 +8184,33 @@ "description": "Status message to render at the top of the form. If `null`, the message is hidden.", "type": "object" }, + { + "name": "headerTitleKey", + "description": "Getter that returns a i18n key for the optional form header title.", + "type": "string" + }, + { + "name": "headerTitleOptions", + "description": "I18next options to pass to the header title translation function.", + "type": "Record" + }, + { + "name": "headerSubtitleKey", + "description": "Getter that returns a i18n key for the optional form header subtitle. Note that subtitle is shown only when data is avaiable.", + "type": "string" + }, + { + "name": "headerSubtitleOptions", + "description": "I18next options to pass to the header subtitle translation function. Note that subtitle is shown only when data is avaiable.", + "type": "Record" + }, + { + "name": "headerCopyIdValue", + "description": "ID that will be written to clipboard when Copy ID button in header is clicked.", + "type": "string | number" + }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -9310,6 +8490,31 @@ "description": "Status message to render at the top of the form. If `null`, the message is hidden.", "type": "object" }, + { + "name": "headerTitleKey", + "description": "Getter that returns a i18n key for the optional form header title.", + "type": "string" + }, + { + "name": "headerTitleOptions", + "description": "I18next options to pass to the header title translation function.", + "type": "Record" + }, + { + "name": "headerSubtitleKey", + "description": "Getter that returns a i18n key for the optional form header subtitle. Note that subtitle is shown only when data is avaiable.", + "type": "string" + }, + { + "name": "headerSubtitleOptions", + "description": "I18next options to pass to the header subtitle translation function. Note that subtitle is shown only when data is avaiable.", + "type": "Record" + }, + { + "name": "headerCopyIdValue", + "description": "ID that will be written to clipboard when Copy ID button in header is clicked.", + "type": "string | number" + }, { "name": "templates", "default": "{}" @@ -10235,6 +9440,31 @@ "description": "Status message to render at the top of the form. If `null`, the message is hidden.", "type": "object" }, + { + "name": "headerTitleKey", + "description": "Getter that returns a i18n key for the optional form header title.", + "type": "string" + }, + { + "name": "headerTitleOptions", + "description": "I18next options to pass to the header title translation function.", + "type": "Record" + }, + { + "name": "headerSubtitleKey", + "description": "Getter that returns a i18n key for the optional form header subtitle. Note that subtitle is shown only when data is avaiable.", + "type": "string" + }, + { + "name": "headerSubtitleOptions", + "description": "I18next options to pass to the header subtitle translation function. Note that subtitle is shown only when data is avaiable.", + "type": "Record" + }, + { + "name": "headerCopyIdValue", + "description": "ID that will be written to clipboard when Copy ID button in header is clicked.", + "type": "string | number" + }, { "name": "templates", "default": "{}" @@ -10499,7 +9729,6 @@ }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -10936,7 +10165,6 @@ }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -11087,20 +10315,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "title:before" - }, - { - "name": "title:after" - }, - { - "name": "subtitle:before" - }, - { - "name": "subtitle:after" - } ] }, { @@ -11209,7 +10423,6 @@ }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -11360,20 +10573,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "title:before" - }, - { - "name": "title:after" - }, - { - "name": "subtitle:before" - }, - { - "name": "subtitle:after" - } ] }, { @@ -11756,7 +10955,6 @@ }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -12039,6 +11237,31 @@ "description": "Status message to render at the top of the form. If `null`, the message is hidden.", "type": "object" }, + { + "name": "headerTitleKey", + "description": "Getter that returns a i18n key for the optional form header title.", + "type": "string" + }, + { + "name": "headerTitleOptions", + "description": "I18next options to pass to the header title translation function.", + "type": "Record" + }, + { + "name": "headerSubtitleKey", + "description": "Getter that returns a i18n key for the optional form header subtitle. Note that subtitle is shown only when data is avaiable.", + "type": "string" + }, + { + "name": "headerSubtitleOptions", + "description": "I18next options to pass to the header subtitle translation function. Note that subtitle is shown only when data is avaiable.", + "type": "Record" + }, + { + "name": "headerCopyIdValue", + "description": "ID that will be written to clipboard when Copy ID button in header is clicked.", + "type": "string | number" + }, { "name": "templates", "default": "{}" @@ -12187,86 +11410,36 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ + ] + }, + { + "name": "foxy-email-template-card", + "path": "./src/elements/public/EmailTemplateCard/index.ts", + "description": "Card element displaying an email template (`fx:email_template`).", + "attributes": [ { - "name": "item-category-uri:before" + "name": "simplify-ns-loading", + "type": "boolean", + "default": "false" }, { - "name": "item-category-uri:after" + "name": "ns", + "type": "string", + "default": "\"defaultNS\"" }, { - "name": "name:before" + "name": "mode", + "type": "string", + "default": "\"production\"" }, { - "name": "name:after" + "name": "readonly", + "type": "boolean", + "default": "false" }, { - "name": "code:before" - }, - { - "name": "code:after" - }, - { - "name": "price:before" - }, - { - "name": "price:after" - }, - { - "name": "upload:before" - }, - { - "name": "upload:after" - }, - { - "name": "timestamps:before" - }, - { - "name": "timestamps:after" - }, - { - "name": "create:before" - }, - { - "name": "create:after" - }, - { - "name": "delete:before" - }, - { - "name": "delete:after" - } - ] - }, - { - "name": "foxy-email-template-card", - "path": "./src/elements/public/EmailTemplateCard/index.ts", - "description": "Card element displaying an email template (`fx:email_template`).", - "attributes": [ - { - "name": "simplify-ns-loading", - "type": "boolean", - "default": "false" - }, - { - "name": "ns", - "type": "string", - "default": "\"defaultNS\"" - }, - { - "name": "mode", - "type": "string", - "default": "\"production\"" - }, - { - "name": "readonly", - "type": "boolean", - "default": "false" - }, - { - "name": "readonlycontrols", - "default": "\"False\"" + "name": "readonlycontrols", + "default": "\"False\"" }, { "name": "disabled", @@ -12345,7 +11518,6 @@ }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -12496,20 +11668,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "title:before" - }, - { - "name": "title:after" - }, - { - "name": "subtitle:before" - }, - { - "name": "subtitle:after" - } ] }, { @@ -12601,7 +11759,6 @@ "properties": [ { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -12765,44 +11922,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "description:before" - }, - { - "name": "description:after" - }, - { - "name": "template-language:before" - }, - { - "name": "template-language:after" - }, - { - "name": "content:before" - }, - { - "name": "content:after" - }, - { - "name": "timestamps:before" - }, - { - "name": "timestamps:after" - }, - { - "name": "create:before" - }, - { - "name": "create:after" - }, - { - "name": "delete:before" - }, - { - "name": "delete:after" - } ] }, { @@ -13343,6 +12462,31 @@ "description": "Status message to render at the top of the form. If `null`, the message is hidden.", "type": "object" }, + { + "name": "headerTitleKey", + "description": "Getter that returns a i18n key for the optional form header title.", + "type": "string" + }, + { + "name": "headerTitleOptions", + "description": "I18next options to pass to the header title translation function.", + "type": "Record" + }, + { + "name": "headerSubtitleKey", + "description": "Getter that returns a i18n key for the optional form header subtitle. Note that subtitle is shown only when data is avaiable.", + "type": "string" + }, + { + "name": "headerSubtitleOptions", + "description": "I18next options to pass to the header subtitle translation function. Note that subtitle is shown only when data is avaiable.", + "type": "Record" + }, + { + "name": "headerCopyIdValue", + "description": "ID that will be written to clipboard when Copy ID button in header is clicked.", + "type": "string | number" + }, { "name": "templates", "default": "{}" @@ -13491,26 +12635,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "filter-query:before" - }, - { - "name": "filter-query:after" - }, - { - "name": "filter-name:before" - }, - { - "name": "filter-name:after" - }, - { - "name": "action:before" - }, - { - "name": "action:after" - } ] }, { @@ -14019,9 +13143,33 @@ "description": "Status message to render at the top of the form. If `null`, the message is hidden.", "type": "object" }, + { + "name": "headerTitleKey", + "description": "Getter that returns a i18n key for the optional form header title.", + "type": "string" + }, + { + "name": "headerTitleOptions", + "description": "I18next options to pass to the header title translation function.", + "type": "Record" + }, + { + "name": "headerSubtitleKey", + "description": "Getter that returns a i18n key for the optional form header subtitle. Note that subtitle is shown only when data is avaiable.", + "type": "string" + }, + { + "name": "headerSubtitleOptions", + "description": "I18next options to pass to the header subtitle translation function. Note that subtitle is shown only when data is avaiable.", + "type": "Record" + }, + { + "name": "headerCopyIdValue", + "description": "ID that will be written to clipboard when Copy ID button in header is clicked.", + "type": "string | number" + }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -14168,38 +13316,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "length:before" - }, - { - "name": "length:after" - }, - { - "name": "number-of-codes:before" - }, - { - "name": "number-of-codes:after" - }, - { - "name": "prefix:before" - }, - { - "name": "prefix:after" - }, - { - "name": "current-balance:before" - }, - { - "name": "current-balance:after" - }, - { - "name": "create:before" - }, - { - "name": "create:after" - } ] }, { @@ -14291,7 +13407,6 @@ "properties": [ { "name": "templates", - "type": "Partial<{ 'title:before': Renderer; 'title:after': Renderer; 'status:before': Renderer; 'status:after': Renderer<...>; }>", "default": "{}" }, { @@ -14455,20 +13570,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "title:before" - }, - { - "name": "title:after" - }, - { - "name": "status:before" - }, - { - "name": "status:after" - } ] }, { @@ -14768,9 +13869,33 @@ "description": "Status message to render at the top of the form. If `null`, the message is hidden.", "type": "object" }, + { + "name": "headerTitleKey", + "description": "Getter that returns a i18n key for the optional form header title.", + "type": "string" + }, + { + "name": "headerTitleOptions", + "description": "I18next options to pass to the header title translation function.", + "type": "Record" + }, + { + "name": "headerSubtitleKey", + "description": "Getter that returns a i18n key for the optional form header subtitle. Note that subtitle is shown only when data is avaiable.", + "type": "string" + }, + { + "name": "headerSubtitleOptions", + "description": "I18next options to pass to the header subtitle translation function. Note that subtitle is shown only when data is avaiable.", + "type": "Record" + }, + { + "name": "headerCopyIdValue", + "description": "ID that will be written to clipboard when Copy ID button in header is clicked.", + "type": "string | number" + }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -14917,54 +14042,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "code:before" - }, - { - "name": "code:after" - }, - { - "name": "current-balance:before" - }, - { - "name": "current-balance:after" - }, - { - "name": "end-date:before" - }, - { - "name": "end-date:after" - }, - { - "name": "", - "description": "customer:before – **new in v1.27.0**" - }, - { - "name": "logs:before" - }, - { - "name": "logs:after" - }, - { - "name": "timestamps:before" - }, - { - "name": "timestamps:after" - }, - { - "name": "delete:before" - }, - { - "name": "delete:after" - }, - { - "name": "create:before" - }, - { - "name": "create:after" - } ] }, { @@ -15259,9 +14336,33 @@ "description": "Status message to render at the top of the form. If `null`, the message is hidden.", "type": "object" }, + { + "name": "headerTitleKey", + "description": "Getter that returns a i18n key for the optional form header title.", + "type": "string" + }, + { + "name": "headerTitleOptions", + "description": "I18next options to pass to the header title translation function.", + "type": "Record" + }, + { + "name": "headerSubtitleKey", + "description": "Getter that returns a i18n key for the optional form header subtitle. Note that subtitle is shown only when data is avaiable.", + "type": "string" + }, + { + "name": "headerSubtitleOptions", + "description": "I18next options to pass to the header subtitle translation function. Note that subtitle is shown only when data is avaiable.", + "type": "Record" + }, + { + "name": "headerCopyIdValue", + "description": "ID that will be written to clipboard when Copy ID button in header is clicked.", + "type": "string | number" + }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -15408,32 +14509,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "gift-card-codes:before", - "description": "**new in v1.27.0**" - }, - { - "name": "gift-card-codes:after", - "description": "**new in v1.27.0**" - }, - { - "name": "current-balance:before", - "description": "**new in v1.27.0**" - }, - { - "name": "current-balance:after", - "description": "**new in v1.27.0**" - }, - { - "name": "create:before", - "description": "**new in v1.27.0**" - }, - { - "name": "create:after", - "description": "**new in v1.27.0**" - } ] }, { @@ -15562,6 +14637,31 @@ "description": "Status message to render at the top of the form. If `null`, the message is hidden.", "type": "object" }, + { + "name": "headerTitleKey", + "description": "Getter that returns a i18n key for the optional form header title.", + "type": "string" + }, + { + "name": "headerTitleOptions", + "description": "I18next options to pass to the header title translation function.", + "type": "Record" + }, + { + "name": "headerSubtitleKey", + "description": "Getter that returns a i18n key for the optional form header subtitle. Note that subtitle is shown only when data is avaiable.", + "type": "string" + }, + { + "name": "headerSubtitleOptions", + "description": "I18next options to pass to the header subtitle translation function. Note that subtitle is shown only when data is avaiable.", + "type": "Record" + }, + { + "name": "headerCopyIdValue", + "description": "ID that will be written to clipboard when Copy ID button in header is clicked.", + "type": "string | number" + }, { "name": "templates", "default": "{}" @@ -15710,82 +14810,18 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "name:before" - }, + ] + }, + { + "name": "foxy-i18n", + "path": "./src/elements/public/I18n/index.ts", + "description": "Custom element for effortless localization with i18next.", + "attributes": [ { - "name": "name:after" - }, - { - "name": "currency:before" - }, - { - "name": "currency:after" - }, - { - "name": "expires:before" - }, - { - "name": "expires:after" - }, - { - "name": "codes:before" - }, - { - "name": "codes:after" - }, - { - "name": "product-restrictions:before" - }, - { - "name": "product-restrictions:after" - }, - { - "name": "category-restrictions:before" - }, - { - "name": "category-restrictions:after" - }, - { - "name": "attributes:before", - "description": "**new in v1.27.0**" - }, - { - "name": "attributes:after", - "description": "**new in v1.27.0**" - }, - { - "name": "timestamps:before" - }, - { - "name": "timestamps:after" - }, - { - "name": "delete:before" - }, - { - "name": "delete:after" - }, - { - "name": "create:before" - }, - { - "name": "create:after" - } - ] - }, - { - "name": "foxy-i18n", - "path": "./src/elements/public/I18n/index.ts", - "description": "Custom element for effortless localization with i18next.", - "attributes": [ - { - "name": "options", - "description": "Optional i18next translation function\n[options](https://www.i18next.com/translation-function/essentials#overview-options).", - "type": "object", - "default": "{}" + "name": "options", + "description": "Optional i18next translation function\n[options](https://www.i18next.com/translation-function/essentials#overview-options).", + "type": "object", + "default": "{}" }, { "name": "key", @@ -16442,6 +15478,31 @@ "description": "Status message to render at the top of the form. If `null`, the message is hidden.", "type": "object" }, + { + "name": "headerTitleKey", + "description": "Getter that returns a i18n key for the optional form header title.", + "type": "string" + }, + { + "name": "headerTitleOptions", + "description": "I18next options to pass to the header title translation function.", + "type": "Record" + }, + { + "name": "headerSubtitleKey", + "description": "Getter that returns a i18n key for the optional form header subtitle. Note that subtitle is shown only when data is avaiable.", + "type": "string" + }, + { + "name": "headerSubtitleOptions", + "description": "I18next options to pass to the header subtitle translation function. Note that subtitle is shown only when data is avaiable.", + "type": "Record" + }, + { + "name": "headerCopyIdValue", + "description": "ID that will be written to clipboard when Copy ID button in header is clicked.", + "type": "string | number" + }, { "name": "templates", "default": "{}" @@ -16590,50 +15651,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "project-name:before" - }, - { - "name": "project-name:after" - }, - { - "name": "project-description:before" - }, - { - "name": "project-description:after" - }, - { - "name": "create:before" - }, - { - "name": "create:after" - }, - { - "name": "header:before" - }, - { - "name": "header:after" - }, - { - "name": "message:before" - }, - { - "name": "message:after" - }, - { - "name": "table:before" - }, - { - "name": "table:after" - }, - { - "name": "delete:before" - }, - { - "name": "delete:after" - } ] }, { @@ -17009,7 +16026,6 @@ }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -17160,20 +16176,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "title:before" - }, - { - "name": "title:after" - }, - { - "name": "subtitle:before" - }, - { - "name": "subtitle:after" - } ] }, { @@ -17315,10 +16317,33 @@ "description": "Status message to render at the top of the form. If `null`, the message is hidden.", "type": "object" }, + { + "name": "headerTitleKey", + "description": "Getter that returns a i18n key for the optional form header title.", + "type": "string" + }, + { + "name": "headerTitleOptions", + "description": "I18next options to pass to the header title translation function.", + "type": "Record" + }, + { + "name": "headerSubtitleKey", + "description": "Getter that returns a i18n key for the optional form header subtitle. Note that subtitle is shown only when data is avaiable.", + "type": "string" + }, + { + "name": "headerSubtitleOptions", + "description": "I18next options to pass to the header subtitle translation function. Note that subtitle is shown only when data is avaiable.", + "type": "Record" + }, + { + "name": "headerCopyIdValue", + "description": "ID that will be written to clipboard when Copy ID button in header is clicked.", + "type": "string | number" + }, { "name": "templates", - "description": "Template render functions mapped to their name.", - "type": "Templates", "default": "{}" }, { @@ -17465,152 +16490,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "name:before" - }, - { - "name": "name:after" - }, - { - "name": "code:before" - }, - { - "name": "code:after" - }, - { - "name": "handling-fee-type:before" - }, - { - "name": "handling-fee-type:after" - }, - { - "name": "handling-fee:before" - }, - { - "name": "handling-fee:after" - }, - { - "name": "handling-fee-percentage:before" - }, - { - "name": "handling-fee-percentage:after" - }, - { - "name": "handling-fee-minimum:before" - }, - { - "name": "handling-fee-minimum:after" - }, - { - "name": "item-delivery-type:before" - }, - { - "name": "item-delivery-type:after" - }, - { - "name": "max-downloads-per-customer:before" - }, - { - "name": "max-downloads-per-customer:after" - }, - { - "name": "max-downloads-time-period:before" - }, - { - "name": "max-downloads-time-period:after" - }, - { - "name": "shipping-flat-rate:before" - }, - { - "name": "shipping-flat-rate:after" - }, - { - "name": "shipping-flat-rate-type:before" - }, - { - "name": "shipping-flat-rate-type:after" - }, - { - "name": "default-weight:before" - }, - { - "name": "default-weight:after" - }, - { - "name": "default-weight-unit:before" - }, - { - "name": "default-weight-unit:after" - }, - { - "name": "default-length-unit:before" - }, - { - "name": "default-length-unit:after" - }, - { - "name": "customs-value:before" - }, - { - "name": "customs-value:after" - }, - { - "name": "discount-name:before" - }, - { - "name": "discount-name:after" - }, - { - "name": "discount-builder:before" - }, - { - "name": "discount-builder:after" - }, - { - "name": "admin-email-template-uri:before" - }, - { - "name": "admin-email-template-uri:after" - }, - { - "name": "customer-email-template-uri:before" - }, - { - "name": "customer-email-template-uri:after" - }, - { - "name": "gift-recipient-email-template-uri:before" - }, - { - "name": "gift-recipient-email-template-uri:after" - }, - { - "name": "taxes:before" - }, - { - "name": "taxes:after" - }, - { - "name": "timestamps:before" - }, - { - "name": "timestamps:after" - }, - { - "name": "create:before" - }, - { - "name": "create:after" - }, - { - "name": "delete:before" - }, - { - "name": "delete:after" - } ] }, { @@ -17620,8 +16499,8 @@ "attributes": [ { "name": "customer-addresses", - "description": "Link to the collection of customer addresses that can be used with this item.", - "type": "string" + "type": "string", + "deprecatedMessage": "Link to the collection of customer addresses that can be used with this item." }, { "name": "item-categories", @@ -17727,8 +16606,8 @@ { "name": "customerAddresses", "attribute": "customer-addresses", - "description": "Link to the collection of customer addresses that can be used with this item.", - "type": "string" + "type": "string", + "deprecatedMessage": "Link to the collection of customer addresses that can be used with this item." }, { "name": "itemCategories", @@ -17776,9 +16655,33 @@ "description": "Status message to render at the top of the form. If `null`, the message is hidden.", "type": "object" }, + { + "name": "headerTitleKey", + "description": "Getter that returns a i18n key for the optional form header title.", + "type": "string" + }, + { + "name": "headerTitleOptions", + "description": "I18next options to pass to the header title translation function.", + "type": "Record" + }, + { + "name": "headerSubtitleKey", + "description": "Getter that returns a i18n key for the optional form header subtitle. Note that subtitle is shown only when data is avaiable.", + "type": "string" + }, + { + "name": "headerSubtitleOptions", + "description": "I18next options to pass to the header subtitle translation function. Note that subtitle is shown only when data is avaiable.", + "type": "Record" + }, + { + "name": "headerCopyIdValue", + "description": "ID that will be written to clipboard when Copy ID button in header is clicked.", + "type": "string | number" + }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -17925,126 +16828,48 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ + ] + }, + { + "name": "foxy-item-option-card", + "path": "./src/elements/public/ItemOptionCard/index.ts", + "description": "Basic card displaying an item option.", + "attributes": [ { - "name": "name:before" + "name": "locale-codes" }, { - "name": "name:after" + "name": "simplify-ns-loading", + "type": "boolean", + "default": "false" }, { - "name": "price:before" + "name": "ns", + "type": "string", + "default": "\"defaultNS\"" }, { - "name": "price:after" + "name": "mode", + "type": "string", + "default": "\"production\"" }, { - "name": "quantity:before" + "name": "readonly", + "type": "boolean", + "default": "false" }, { - "name": "quantity:after" + "name": "readonlycontrols", + "default": "\"False\"" }, { - "name": "subscription", - "description": "frequency:before – new in 1.25.0" + "name": "disabled", + "type": "boolean", + "default": "false" }, { - "name": "subscription-start", - "description": "date:before – new in 1.25.0" - }, - { - "name": "subscription-end", - "description": "date:before – new in 1.25.0" - }, - { - "name": "discount", - "description": "name:before – new in 1.25.0" - }, - { - "name": "", - "description": "expires:before – new in 1.25.0" - }, - { - "name": "quantity", - "description": "min:before – new in 1.25.0" - }, - { - "name": "item-category", - "description": "uri:before – new in 1.25.0" - }, - { - "name": "parent", - "description": "code:before – new in 1.25.0" - }, - { - "name": "coupon", - "description": "details:before – new in 1.25.0" - }, - { - "name": "item", - "description": "options:before – new in 1.25.0" - }, - { - "name": "timestamps:before" - }, - { - "name": "timestamps:after" - }, - { - "name": "delete:before" - }, - { - "name": "delete:after" - }, - { - "name": "create:before" - }, - { - "name": "create:after" - } - ] - }, - { - "name": "foxy-item-option-card", - "path": "./src/elements/public/ItemOptionCard/index.ts", - "description": "Basic card displaying an item option.", - "attributes": [ - { - "name": "locale-codes" - }, - { - "name": "simplify-ns-loading", - "type": "boolean", - "default": "false" - }, - { - "name": "ns", - "type": "string", - "default": "\"defaultNS\"" - }, - { - "name": "mode", - "type": "string", - "default": "\"production\"" - }, - { - "name": "readonly", - "type": "boolean", - "default": "false" - }, - { - "name": "readonlycontrols", - "default": "\"False\"" - }, - { - "name": "disabled", - "type": "boolean", - "default": "false" - }, - { - "name": "disabledcontrols", - "default": "\"False\"" + "name": "disabledcontrols", + "default": "\"False\"" }, { "name": "hidden", @@ -18118,7 +16943,6 @@ }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -18269,20 +17093,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "title:before" - }, - { - "name": "title:after" - }, - { - "name": "subtitle:before" - }, - { - "name": "subtitle:after" - } ] }, { @@ -18406,6 +17216,31 @@ "description": "Status message to render at the top of the form. If `null`, the message is hidden.", "type": "object" }, + { + "name": "headerTitleKey", + "description": "Getter that returns a i18n key for the optional form header title.", + "type": "string" + }, + { + "name": "headerTitleOptions", + "description": "I18next options to pass to the header title translation function.", + "type": "Record" + }, + { + "name": "headerSubtitleKey", + "description": "Getter that returns a i18n key for the optional form header subtitle. Note that subtitle is shown only when data is avaiable.", + "type": "string" + }, + { + "name": "headerSubtitleOptions", + "description": "I18next options to pass to the header subtitle translation function. Note that subtitle is shown only when data is avaiable.", + "type": "Record" + }, + { + "name": "headerCopyIdValue", + "description": "ID that will be written to clipboard when Copy ID button in header is clicked.", + "type": "string | number" + }, { "name": "templates", "default": "{}" @@ -18554,32 +17389,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "name:before" - }, - { - "name": "name:after" - }, - { - "name": "value:before" - }, - { - "name": "value:after" - }, - { - "name": "price-mod:before" - }, - { - "name": "price-mod:after" - }, - { - "name": "weight-mod:before" - }, - { - "name": "weight-mod:after" - } ] }, { @@ -19443,9 +18252,33 @@ "description": "Status message to render at the top of the form. If `null`, the message is hidden.", "type": "object" }, + { + "name": "headerTitleKey", + "description": "Getter that returns a i18n key for the optional form header title.", + "type": "string" + }, + { + "name": "headerTitleOptions", + "description": "I18next options to pass to the header title translation function.", + "type": "Record" + }, + { + "name": "headerSubtitleKey", + "description": "Getter that returns a i18n key for the optional form header subtitle. Note that subtitle is shown only when data is avaiable.", + "type": "string" + }, + { + "name": "headerSubtitleOptions", + "description": "I18next options to pass to the header subtitle translation function. Note that subtitle is shown only when data is avaiable.", + "type": "Record" + }, + { + "name": "headerCopyIdValue", + "description": "ID that will be written to clipboard when Copy ID button in header is clicked.", + "type": "string | number" + }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -19592,301 +18425,467 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ + ] + }, + { + "name": "foxy-nucleon", + "path": "./src/elements/public/NucleonElement/index.ts", + "description": "Base class for custom elements working with remote HAL+JSON resources.", + "attributes": [ { - "name": "timestamps:before" + "name": "lang", + "description": "Optional ISO 639-1 code describing the language element content is written in.\nChanging the `lang` attribute will update the value of this property.", + "type": "string", + "default": "\"\"" }, { - "name": "timestamps:after" + "name": "parent", + "description": "Optional URL of the collection this element's resource belongs to.\nChanging the `parent` attribute will update the value of this property.", + "type": "string", + "default": "\"\"" }, { - "name": "delete:before" + "name": "related", + "description": "Optional URI list of the related resources. If Rumour encounters a related\nresource on creation or deletion, it will be reloaded from source.", + "type": "array", + "default": "[]" }, { - "name": "delete:after" + "name": "virtual-host", + "description": "Unique identifier for the virtual host used by the element to serve internal requests.\n\nCurrently only one endpoint is supported: `foxy:///form/`.\nThis endpoint supports POST, GET, PATCH and DELETE methods and functions like a hAPI server.\n\nFor example, `GET foxy://nucleon-123/form/subscriptions/allowNextDateModification/0` on a NucleonElement\nwith `fx:customer_portal_settings` will return the first item of the `subscriptions.allowNextDateModification` array.", + "default": "\"uniqueId('nucleon-')\"" }, { - "name": "create:before" + "name": "group", + "description": "Rumour group. Elements in different groups will not share updates. Empty by default.", + "type": "string" }, { - "name": "create:after" + "name": "href", + "description": "Optional URL of the resource to load. Switches element to `idle.template` state if empty (default).", + "type": "string" }, { - "name": "provider:before" - }, + "name": "infer", + "description": "Set a name for this element here to enable property inference. Set to `null` to disable.", + "type": "string" + } + ], + "properties": [ { - "name": "provider:after" + "name": "UpdateEvent", + "description": "Instances of this event are dispatched on an element whenever it changes its\nstate (e.g. when going from `busy` to `idle` or on `form` data change).\nThis event isn't cancelable, and it does not bubble.", + "type": "typeof UpdateEvent", + "default": "\"UpdateEvent\"" }, { - "name": "avalara-service-url:before" + "name": "Rumour", + "description": "Creates a tagged [Rumour](https://sdk.foxy.dev/classes/_core_index_.rumour.html)\ninstance if it doesn't exist or returns cached one otherwise. NucleonElements\nuse empty Rumour group by default.", + "type": "((group: string) => Rumour) & MemoizedFunction", + "default": "\"memoize<(group: string) => Rumour>(() => new Rumour())\"" }, { - "name": "avalara-service-url:after" + "name": "API", + "description": "Universal [API](https://sdk.foxy.dev/classes/_core_index_.api.html) client\nthat dispatches cancellable `FetchEvent` on an element before each request.", + "type": "typeof API", + "default": "\"API\"" }, { - "name": "avalara-id:before" + "name": "lang", + "attribute": "lang", + "description": "Optional ISO 639-1 code describing the language element content is written in.\nChanging the `lang` attribute will update the value of this property.", + "type": "string", + "default": "\"\"" }, { - "name": "avalara-id:after" + "name": "parent", + "attribute": "parent", + "description": "Optional URL of the collection this element's resource belongs to.\nChanging the `parent` attribute will update the value of this property.", + "type": "string", + "default": "\"\"" }, { - "name": "avalara-key:before" + "name": "related", + "attribute": "related", + "description": "Optional URI list of the related resources. If Rumour encounters a related\nresource on creation or deletion, it will be reloaded from source.", + "type": "array", + "default": "[]" }, { - "name": "avalara-key:after" + "name": "virtualHost", + "attribute": "virtual-host", + "description": "Unique identifier for the virtual host used by the element to serve internal requests.\n\nCurrently only one endpoint is supported: `foxy:///form/`.\nThis endpoint supports POST, GET, PATCH and DELETE methods and functions like a hAPI server.\n\nFor example, `GET foxy://nucleon-123/form/subscriptions/allowNextDateModification/0` on a NucleonElement\nwith `fx:customer_portal_settings` will return the first item of the `subscriptions.allowNextDateModification` array.", + "default": "\"uniqueId('nucleon-')\"" }, { - "name": "avalara-company-code:before" + "name": "failure", + "description": "If network request returns non-2XX code, the entire error response\nwill be available via this getter.\n\nThis property is readonly. Changing failure records via this property is\nnot guaranteed to work. NucleonElement does not provide a way to override error status.", + "type": "Response | null" }, { - "name": "avalara-company-code:after" + "name": "errors", + "description": "Array of validation errors returned from `NucleonElement.v8n` checks.\n\nThis property is readonly. Adding or removing error codes via this property is\nnot guaranteed to work. NucleonElement does not provide a way to override validity status.", + "type": "string[]" }, { - "name": "avalara-options:before" + "name": "form", + "description": "Resource snapshot with edits applied. Empty object if unavailable.\n\nThis property and its value are readonly. Assignments like `element.data.foo = 'bar'`\nare not guaranteed to work. Please use `element.edit({ foo: 'bar' })` instead.\nIf you need to replace the entire data object, consider using `element.data`.", + "type": "Partial" }, { - "name": "avalara-options:after" + "name": "data", + "description": "Resource snapshot as-is, no edits applied. Null if unavailable.\n\nReturned value is not reactive. Assignments like `element.data.foo = 'bar'`\nare not guaranteed to work. Please set the property instead: `element.data = { ...element.data, foo: 'bar' }`.\nIf you're processing user input, consider using `element.form` and `element.edit()` instead.", + "type": "TData | null" }, { - "name": "avalara-address-validation-countries:before" + "name": "group", + "attribute": "group", + "description": "Rumour group. Elements in different groups will not share updates. Empty by default.", + "type": "string" }, { - "name": "avalara-address-validation-countries:after" + "name": "href", + "attribute": "href", + "description": "Optional URL of the resource to load. Switches element to `idle.template` state if empty (default).", + "type": "string" }, { - "name": "avalara-category-to-product-tax-code-mappings:before" - }, + "name": "infer", + "attribute": "infer", + "description": "Set a name for this element here to enable property inference. Set to `null` to disable.", + "type": "string" + } + ], + "events": [ { - "name": "avalara-category-to-product-tax-code-mappings:after" + "name": "update", + "description": "Instance of `NucleonElement.UpdateEvent`. Dispatched on an element whenever it changes its state." }, { - "name": "taxjar-api-token:before" - }, + "name": "fetch", + "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." + } + ] + }, + { + "name": "foxy-pagination", + "path": "./src/elements/public/Pagination/index.ts", + "description": "Helper element that adds pagination controls to elements\nrepresenting Hypermedia API collection pages. Works with NucleonElement instances only.\nPage element **MUST** be a direct descendant of `foxy-pagination`.", + "attributes": [ { - "name": "taxjar-api-token:after" + "name": "first", + "description": "URL of the first page of the colletion.", + "type": "string" }, { - "name": "taxjar-category-to-product-tax-code-mappings:before" + "name": "mode", + "type": "string", + "default": "\"production\"" }, { - "name": "taxjar-category-to-product-tax-code-mappings:after" + "name": "readonly", + "type": "boolean", + "default": "false" }, { - "name": "taxjar-options:before" + "name": "readonlycontrols", + "default": "\"False\"" }, { - "name": "taxjar-options:after" + "name": "disabled", + "type": "boolean", + "default": "false" }, { - "name": "onesource-service-url:before" + "name": "disabledcontrols", + "default": "\"False\"" }, { - "name": "onesource-service-url:after" + "name": "hidden", + "type": "boolean", + "default": "false" }, { - "name": "onesource-external-company-id:before" + "name": "hiddencontrols", + "default": "\"False\"" }, { - "name": "onesource-external-company-id:after" - }, - { - "name": "onesource-calling-system-number:before" - }, - { - "name": "onesource-calling-system-number:after" - }, - { - "name": "onesource-from-city:before" - }, - { - "name": "onesource-from-city:after" + "name": "simplify-ns-loading", + "type": "boolean", + "default": "false" }, { - "name": "onesource-host-system:before" + "name": "lang", + "type": "string", + "default": "\"\"" }, { - "name": "onesource-host-system:after" + "name": "ns", + "type": "string", + "default": "\"defaultNS\"" }, { - "name": "onesource-company-role:before" - }, + "name": "infer", + "description": "Set a name for this element here to enable property inference. Set to `null` to disable.", + "type": "string" + } + ], + "properties": [ { - "name": "onesource-company-role:after" + "name": "first", + "attribute": "first", + "description": "URL of the first page of the colletion.", + "type": "string" }, { - "name": "onesource-part-number-product-option:before" + "name": "templates", + "default": "{}" }, { - "name": "onesource-part-number-product-option:after" + "name": "mode", + "attribute": "mode", + "type": "string", + "default": "\"production\"" }, { - "name": "onesource-product-order-priority:before" + "name": "readonly", + "attribute": "readonly", + "type": "boolean", + "default": "false" }, { - "name": "onesource-product-order-priority:after" + "name": "readonlyControls", + "attribute": "readonlycontrols", + "default": "\"False\"" }, { - "name": "onesource-audit-settings:before" + "name": "disabled", + "attribute": "disabled", + "type": "boolean", + "default": "false" }, { - "name": "onesource-audit-settings:after" + "name": "disabledControls", + "attribute": "disabledcontrols", + "default": "\"False\"" }, { - "name": "webhook-service:before" + "name": "hidden", + "attribute": "hidden", + "type": "boolean", + "default": "false" }, { - "name": "webhook-service:after" + "name": "hiddenControls", + "attribute": "hiddencontrols", + "default": "\"False\"" }, { - "name": "webhook-json-title:before" + "name": "readonlySelector", + "type": "BooleanSelector" }, { - "name": "webhook-json-title:after" + "name": "disabledSelector", + "type": "BooleanSelector" }, { - "name": "webhook-json-encryption-key:before" + "name": "hiddenSelector", + "type": "BooleanSelector" }, { - "name": "webhook-json-encryption-key:after" + "name": "simplifyNsLoading", + "attribute": "simplify-ns-loading", + "type": "boolean", + "default": "false" }, { - "name": "webhook-json-url:before" + "name": "lang", + "attribute": "lang", + "type": "string", + "default": "\"\"" }, { - "name": "webhook-json-url:after" + "name": "ns", + "attribute": "ns", + "type": "string", + "default": "\"defaultNS\"" }, { - "name": "webhook-json-events:before" + "name": "t", + "type": "Translator", + "default": "\"(key, options) => {\\n const I18nElement = customElements.get('foxy-i18n') as typeof I18n | undefined;\\n\\n if (!I18nElement) return key;\\n\\n let keys: string[];\\n\\n if (this.simplifyNsLoading) {\\n const namespaces = this.ns.split(' ').filter(v => v.length > 0);\\n const path = [...namespaces.slice(1), key].join('.');\\n keys = namespaces[0] ? [`${namespaces[0]}:${path}`] : [path];\\n } else {\\n keys = this.ns\\n .split(' ')\\n .reverse()\\n .map(v => v.trim())\\n .filter(v => v.length > 0)\\n .reverse()\\n .map((v, i, a) => `${v}:${[...a.slice(i + 1), key].join('.')}`);\\n }\\n\\n keys.push(key);\\n\\n return I18nElement.i18next.t(keys, { lng: this.lang, ...options }).toString();\\n }\"" }, { - "name": "webhook-json-events:after" - }, + "name": "infer", + "attribute": "infer", + "description": "Set a name for this element here to enable property inference. Set to `null` to disable.", + "type": "string" + } + ] + }, + { + "name": "foxy-passkey-card", + "path": "./src/elements/public/PasskeyCard/index.ts", + "description": "Basic card displaying a saved passkey.", + "attributes": [ { - "name": "webhook-legacy-xml-title:before" + "name": "simplify-ns-loading", + "type": "boolean", + "default": "false" }, { - "name": "webhook-legacy-xml-title:after" + "name": "ns", + "type": "string", + "default": "\"defaultNS\"" }, { - "name": "webhook-legacy-xml-url:before" + "name": "mode", + "type": "string", + "default": "\"production\"" }, { - "name": "webhook-legacy-xml-url:after" + "name": "readonly", + "type": "boolean", + "default": "false" }, { - "name": "webflow-site-id:before" + "name": "readonlycontrols", + "default": "\"False\"" }, { - "name": "webflow-site-id:after" + "name": "disabled", + "type": "boolean", + "default": "false" }, { - "name": "webflow-site-name:before" + "name": "disabledcontrols", + "default": "\"False\"" }, { - "name": "webflow-site-name:after" + "name": "hidden", + "type": "boolean", + "default": "false" }, { - "name": "webflow-collection-id:before" + "name": "hiddencontrols", + "default": "\"False\"" }, { - "name": "webflow-collection-id:after" + "name": "lang", + "description": "Optional ISO 639-1 code describing the language element content is written in.\nChanging the `lang` attribute will update the value of this property.", + "type": "string", + "default": "\"\"" }, { - "name": "webflow-collection-name:before" + "name": "parent", + "description": "Optional URL of the collection this element's resource belongs to.\nChanging the `parent` attribute will update the value of this property.", + "type": "string", + "default": "\"\"" }, { - "name": "webflow-collection-name:after" + "name": "related", + "description": "Optional URI list of the related resources. If Rumour encounters a related\nresource on creation or deletion, it will be reloaded from source.", + "type": "array", + "default": "[]" }, { - "name": "webflow-sku-field-id:before" + "name": "virtual-host", + "description": "Unique identifier for the virtual host used by the element to serve internal requests.\n\nCurrently only one endpoint is supported: `foxy:///form/`.\nThis endpoint supports POST, GET, PATCH and DELETE methods and functions like a hAPI server.\n\nFor example, `GET foxy://nucleon-123/form/subscriptions/allowNextDateModification/0` on a NucleonElement\nwith `fx:customer_portal_settings` will return the first item of the `subscriptions.allowNextDateModification` array.", + "default": "\"uniqueId('nucleon-')\"" }, { - "name": "webflow-sku-field-id:after" + "name": "group", + "description": "Rumour group. Elements in different groups will not share updates. Empty by default.", + "type": "string" }, { - "name": "webflow-sku-field-name:before" + "name": "href", + "description": "Optional URL of the resource to load. Switches element to `idle.template` state if empty (default).", + "type": "string" }, { - "name": "webflow-sku-field-name:after" - }, + "name": "infer", + "description": "Set a name for this element here to enable property inference. Set to `null` to disable.", + "type": "string" + } + ], + "properties": [ { - "name": "webflow-inventory-field-id:before" + "name": "simplifyNsLoading", + "attribute": "simplify-ns-loading", + "type": "boolean", + "default": "false" }, { - "name": "webflow-inventory-field-id:after" + "name": "ns", + "attribute": "ns", + "type": "string", + "default": "\"defaultNS\"" }, { - "name": "webflow-inventory-field-name:before" + "name": "t", + "type": "Translator", + "default": "\"(key, options) => {\\n const I18nElement = customElements.get('foxy-i18n') as typeof I18n | undefined;\\n\\n if (!I18nElement) return key;\\n\\n let keys: string[];\\n\\n if (this.simplifyNsLoading) {\\n const namespaces = this.ns.split(' ').filter(v => v.length > 0);\\n const path = [...namespaces.slice(1), key].join('.');\\n keys = namespaces[0] ? [`${namespaces[0]}:${path}`] : [path];\\n } else {\\n keys = this.ns\\n .split(' ')\\n .reverse()\\n .map(v => v.trim())\\n .filter(v => v.length > 0)\\n .reverse()\\n .map((v, i, a) => `${v}:${[...a.slice(i + 1), key].join('.')}`);\\n }\\n\\n keys.push(key);\\n\\n return I18nElement.i18next.t(keys, { lng: this.lang, ...options }).toString();\\n }\"" }, { - "name": "webflow-inventory-field-name:after" + "name": "templates", + "default": "{}" }, { - "name": "webflow-auth:before" + "name": "mode", + "attribute": "mode", + "type": "string", + "default": "\"production\"" }, { - "name": "webflow-auth:after" + "name": "readonly", + "attribute": "readonly", + "type": "boolean", + "default": "false" }, { - "name": "zapier-event:before" + "name": "readonlyControls", + "attribute": "readonlycontrols", + "default": "\"False\"" }, { - "name": "zapier-event:after" + "name": "disabled", + "attribute": "disabled", + "type": "boolean", + "default": "false" }, { - "name": "zapier-url:before" + "name": "disabledControls", + "attribute": "disabledcontrols", + "default": "\"False\"" }, { - "name": "zapier-url:after" - } - ] - }, - { - "name": "foxy-nucleon", - "path": "./src/elements/public/NucleonElement/index.ts", - "description": "Base class for custom elements working with remote HAL+JSON resources.", - "attributes": [ - { - "name": "lang", - "description": "Optional ISO 639-1 code describing the language element content is written in.\nChanging the `lang` attribute will update the value of this property.", - "type": "string", - "default": "\"\"" + "name": "hidden", + "attribute": "hidden", + "type": "boolean", + "default": "false" }, { - "name": "parent", - "description": "Optional URL of the collection this element's resource belongs to.\nChanging the `parent` attribute will update the value of this property.", - "type": "string", - "default": "\"\"" + "name": "hiddenControls", + "attribute": "hiddencontrols", + "default": "\"False\"" }, { - "name": "related", - "description": "Optional URI list of the related resources. If Rumour encounters a related\nresource on creation or deletion, it will be reloaded from source.", - "type": "array", - "default": "[]" + "name": "readonlySelector", + "type": "BooleanSelector" }, { - "name": "virtual-host", - "description": "Unique identifier for the virtual host used by the element to serve internal requests.\n\nCurrently only one endpoint is supported: `foxy:///form/`.\nThis endpoint supports POST, GET, PATCH and DELETE methods and functions like a hAPI server.\n\nFor example, `GET foxy://nucleon-123/form/subscriptions/allowNextDateModification/0` on a NucleonElement\nwith `fx:customer_portal_settings` will return the first item of the `subscriptions.allowNextDateModification` array.", - "default": "\"uniqueId('nucleon-')\"" + "name": "disabledSelector", + "type": "BooleanSelector" }, { - "name": "group", - "description": "Rumour group. Elements in different groups will not share updates. Empty by default.", - "type": "string" + "name": "hiddenSelector", + "type": "BooleanSelector" }, { - "name": "href", - "description": "Optional URL of the resource to load. Switches element to `idle.template` state if empty (default).", - "type": "string" + "name": "isBodyReady", + "type": "boolean" }, - { - "name": "infer", - "description": "Set a name for this element here to enable property inference. Set to `null` to disable.", - "type": "string" - } - ], - "properties": [ { "name": "UpdateEvent", "description": "Instances of this event are dispatched on an element whenever it changes its\nstate (e.g. when going from `busy` to `idle` or on `form` data change).\nThis event isn't cancelable, and it does not bubble.", @@ -19983,14 +18982,24 @@ ] }, { - "name": "foxy-pagination", - "path": "./src/elements/public/Pagination/index.ts", - "description": "Helper element that adds pagination controls to elements\nrepresenting Hypermedia API collection pages. Works with NucleonElement instances only.\nPage element **MUST** be a direct descendant of `foxy-pagination`.", + "name": "foxy-passkey-form", + "path": "./src/elements/public/PasskeyForm/index.ts", + "description": "Form element for viewing and deleting passkeys (`fx:passkey`).", "attributes": [ { - "name": "first", - "description": "URL of the first page of the colletion.", - "type": "string" + "name": "simplify-ns-loading", + "type": "boolean", + "default": "false" + }, + { + "name": "ns", + "type": "string", + "default": "\"defaultNS\"" + }, + { + "name": "status", + "description": "Status message to render at the top of the form. If `null`, the message is hidden.", + "type": "object" }, { "name": "mode", @@ -20024,176 +19033,15 @@ "name": "hiddencontrols", "default": "\"False\"" }, - { - "name": "simplify-ns-loading", - "type": "boolean", - "default": "false" - }, { "name": "lang", + "description": "Optional ISO 639-1 code describing the language element content is written in.\nChanging the `lang` attribute will update the value of this property.", "type": "string", "default": "\"\"" }, { - "name": "ns", - "type": "string", - "default": "\"defaultNS\"" - }, - { - "name": "infer", - "description": "Set a name for this element here to enable property inference. Set to `null` to disable.", - "type": "string" - } - ], - "properties": [ - { - "name": "first", - "attribute": "first", - "description": "URL of the first page of the colletion.", - "type": "string" - }, - { - "name": "templates", - "default": "{}" - }, - { - "name": "mode", - "attribute": "mode", - "type": "string", - "default": "\"production\"" - }, - { - "name": "readonly", - "attribute": "readonly", - "type": "boolean", - "default": "false" - }, - { - "name": "readonlyControls", - "attribute": "readonlycontrols", - "default": "\"False\"" - }, - { - "name": "disabled", - "attribute": "disabled", - "type": "boolean", - "default": "false" - }, - { - "name": "disabledControls", - "attribute": "disabledcontrols", - "default": "\"False\"" - }, - { - "name": "hidden", - "attribute": "hidden", - "type": "boolean", - "default": "false" - }, - { - "name": "hiddenControls", - "attribute": "hiddencontrols", - "default": "\"False\"" - }, - { - "name": "readonlySelector", - "type": "BooleanSelector" - }, - { - "name": "disabledSelector", - "type": "BooleanSelector" - }, - { - "name": "hiddenSelector", - "type": "BooleanSelector" - }, - { - "name": "simplifyNsLoading", - "attribute": "simplify-ns-loading", - "type": "boolean", - "default": "false" - }, - { - "name": "lang", - "attribute": "lang", - "type": "string", - "default": "\"\"" - }, - { - "name": "ns", - "attribute": "ns", - "type": "string", - "default": "\"defaultNS\"" - }, - { - "name": "t", - "type": "Translator", - "default": "\"(key, options) => {\\n const I18nElement = customElements.get('foxy-i18n') as typeof I18n | undefined;\\n\\n if (!I18nElement) return key;\\n\\n let keys: string[];\\n\\n if (this.simplifyNsLoading) {\\n const namespaces = this.ns.split(' ').filter(v => v.length > 0);\\n const path = [...namespaces.slice(1), key].join('.');\\n keys = namespaces[0] ? [`${namespaces[0]}:${path}`] : [path];\\n } else {\\n keys = this.ns\\n .split(' ')\\n .reverse()\\n .map(v => v.trim())\\n .filter(v => v.length > 0)\\n .reverse()\\n .map((v, i, a) => `${v}:${[...a.slice(i + 1), key].join('.')}`);\\n }\\n\\n keys.push(key);\\n\\n return I18nElement.i18next.t(keys, { lng: this.lang, ...options }).toString();\\n }\"" - }, - { - "name": "infer", - "attribute": "infer", - "description": "Set a name for this element here to enable property inference. Set to `null` to disable.", - "type": "string" - } - ] - }, - { - "name": "foxy-passkey-card", - "path": "./src/elements/public/PasskeyCard/index.ts", - "description": "Basic card displaying a saved passkey.", - "attributes": [ - { - "name": "simplify-ns-loading", - "type": "boolean", - "default": "false" - }, - { - "name": "ns", - "type": "string", - "default": "\"defaultNS\"" - }, - { - "name": "mode", - "type": "string", - "default": "\"production\"" - }, - { - "name": "readonly", - "type": "boolean", - "default": "false" - }, - { - "name": "readonlycontrols", - "default": "\"False\"" - }, - { - "name": "disabled", - "type": "boolean", - "default": "false" - }, - { - "name": "disabledcontrols", - "default": "\"False\"" - }, - { - "name": "hidden", - "type": "boolean", - "default": "false" - }, - { - "name": "hiddencontrols", - "default": "\"False\"" - }, - { - "name": "lang", - "description": "Optional ISO 639-1 code describing the language element content is written in.\nChanging the `lang` attribute will update the value of this property.", - "type": "string", - "default": "\"\"" - }, - { - "name": "parent", - "description": "Optional URL of the collection this element's resource belongs to.\nChanging the `parent` attribute will update the value of this property.", + "name": "parent", + "description": "Optional URL of the collection this element's resource belongs to.\nChanging the `parent` attribute will update the value of this property.", "type": "string", "default": "\"\"" }, @@ -20242,9 +19090,45 @@ "type": "Translator", "default": "\"(key, options) => {\\n const I18nElement = customElements.get('foxy-i18n') as typeof I18n | undefined;\\n\\n if (!I18nElement) return key;\\n\\n let keys: string[];\\n\\n if (this.simplifyNsLoading) {\\n const namespaces = this.ns.split(' ').filter(v => v.length > 0);\\n const path = [...namespaces.slice(1), key].join('.');\\n keys = namespaces[0] ? [`${namespaces[0]}:${path}`] : [path];\\n } else {\\n keys = this.ns\\n .split(' ')\\n .reverse()\\n .map(v => v.trim())\\n .filter(v => v.length > 0)\\n .reverse()\\n .map((v, i, a) => `${v}:${[...a.slice(i + 1), key].join('.')}`);\\n }\\n\\n keys.push(key);\\n\\n return I18nElement.i18next.t(keys, { lng: this.lang, ...options }).toString();\\n }\"" }, + { + "name": "generalErrorPrefix", + "description": "Validation errors with this prefix will show up at the top of the form.", + "type": "string", + "default": "\"error:\"" + }, + { + "name": "status", + "attribute": "status", + "description": "Status message to render at the top of the form. If `null`, the message is hidden.", + "type": "object" + }, + { + "name": "headerTitleKey", + "description": "Getter that returns a i18n key for the optional form header title.", + "type": "string" + }, + { + "name": "headerTitleOptions", + "description": "I18next options to pass to the header title translation function.", + "type": "Record" + }, + { + "name": "headerSubtitleKey", + "description": "Getter that returns a i18n key for the optional form header subtitle. Note that subtitle is shown only when data is avaiable.", + "type": "string" + }, + { + "name": "headerSubtitleOptions", + "description": "I18next options to pass to the header subtitle translation function. Note that subtitle is shown only when data is avaiable.", + "type": "Record" + }, + { + "name": "headerCopyIdValue", + "description": "ID that will be written to clipboard when Copy ID button in header is clicked.", + "type": "string | number" + }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -20298,10 +19182,6 @@ "name": "hiddenSelector", "type": "BooleanSelector" }, - { - "name": "isBodyReady", - "type": "boolean" - }, { "name": "UpdateEvent", "description": "Instances of this event are dispatched on an element whenever it changes its\nstate (e.g. when going from `busy` to `idle` or on `form` data change).\nThis event isn't cancelable, and it does not bubble.", @@ -20395,73 +19275,30 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "title:before" - }, - { - "name": "title:after" - }, - { - "name": "subtitle:before" - }, - { - "name": "subtitle:after" - } ] }, { - "name": "foxy-passkey-form", - "path": "./src/elements/public/PasskeyForm/index.ts", - "description": "Form element for viewing and deleting passkeys (`fx:passkey`).", + "name": "foxy-payment-card", + "path": "./src/elements/public/PaymentCard/index.ts", + "description": "Basic card displaying a payment resource (`fx:payment`).", "attributes": [ { - "name": "simplify-ns-loading", - "type": "boolean", - "default": "false" - }, - { - "name": "ns", - "type": "string", - "default": "\"defaultNS\"" - }, - { - "name": "status", - "description": "Status message to render at the top of the form. If `null`, the message is hidden.", - "type": "object" - }, - { - "name": "mode", - "type": "string", - "default": "\"production\"" - }, - { - "name": "readonly", - "type": "boolean", - "default": "false" - }, - { - "name": "readonlycontrols", - "default": "\"False\"" - }, - { - "name": "disabled", - "type": "boolean", - "default": "false" + "name": "hosted-payment-gateways-helper", + "description": "URL of the `fx:hosted_payment_gateways` property helper resource." }, { - "name": "disabledcontrols", - "default": "\"False\"" + "name": "payment-gateways-helper", + "description": "URL of the `fx:payment_gateways` property helper resource." }, { - "name": "hidden", + "name": "simplify-ns-loading", "type": "boolean", "default": "false" }, { - "name": "hiddencontrols", - "default": "\"False\"" + "name": "ns", + "type": "string", + "default": "\"defaultNS\"" }, { "name": "lang", @@ -20503,6 +19340,16 @@ } ], "properties": [ + { + "name": "hostedPaymentGatewaysHelper", + "attribute": "hosted-payment-gateways-helper", + "description": "URL of the `fx:hosted_payment_gateways` property helper resource." + }, + { + "name": "paymentGatewaysHelper", + "attribute": "payment-gateways-helper", + "description": "URL of the `fx:payment_gateways` property helper resource." + }, { "name": "simplifyNsLoading", "attribute": "simplify-ns-loading", @@ -20521,71 +19368,8 @@ "default": "\"(key, options) => {\\n const I18nElement = customElements.get('foxy-i18n') as typeof I18n | undefined;\\n\\n if (!I18nElement) return key;\\n\\n let keys: string[];\\n\\n if (this.simplifyNsLoading) {\\n const namespaces = this.ns.split(' ').filter(v => v.length > 0);\\n const path = [...namespaces.slice(1), key].join('.');\\n keys = namespaces[0] ? [`${namespaces[0]}:${path}`] : [path];\\n } else {\\n keys = this.ns\\n .split(' ')\\n .reverse()\\n .map(v => v.trim())\\n .filter(v => v.length > 0)\\n .reverse()\\n .map((v, i, a) => `${v}:${[...a.slice(i + 1), key].join('.')}`);\\n }\\n\\n keys.push(key);\\n\\n return I18nElement.i18next.t(keys, { lng: this.lang, ...options }).toString();\\n }\"" }, { - "name": "generalErrorPrefix", - "description": "Validation errors with this prefix will show up at the top of the form.", - "type": "string", - "default": "\"error:\"" - }, - { - "name": "status", - "attribute": "status", - "description": "Status message to render at the top of the form. If `null`, the message is hidden.", - "type": "object" - }, - { - "name": "templates", - "default": "{}" - }, - { - "name": "mode", - "attribute": "mode", - "type": "string", - "default": "\"production\"" - }, - { - "name": "readonly", - "attribute": "readonly", - "type": "boolean", - "default": "false" - }, - { - "name": "readonlyControls", - "attribute": "readonlycontrols", - "default": "\"False\"" - }, - { - "name": "disabled", - "attribute": "disabled", - "type": "boolean", - "default": "false" - }, - { - "name": "disabledControls", - "attribute": "disabledcontrols", - "default": "\"False\"" - }, - { - "name": "hidden", - "attribute": "hidden", - "type": "boolean", - "default": "false" - }, - { - "name": "hiddenControls", - "attribute": "hiddencontrols", - "default": "\"False\"" - }, - { - "name": "readonlySelector", - "type": "BooleanSelector" - }, - { - "name": "disabledSelector", - "type": "BooleanSelector" - }, - { - "name": "hiddenSelector", - "type": "BooleanSelector" + "name": "isBodyReady", + "type": "boolean" }, { "name": "UpdateEvent", @@ -20680,58 +19464,213 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } + ] + }, + { + "name": "foxy-payment-card-embed", + "path": "./src/elements/public/PaymentCardEmbed/index.ts", + "description": "A secure, PCI-compliant element for collecting payment card information with\nsupport for Stripe, Square and embedded gateways.", + "attributes": [ + { + "name": "url", + "description": "Full Bank Card Embed URL, e.g. `https://embed.foxy.io/v1.html?template_set_id=123`.\n\nThe following demo URLs are available:\n- `https://embed.foxy.io/v1.html?demo=default` (Default form)\n- `https://embed.foxy.io/v1.html?demo=stripe` (Stripe Card Element)\n- `https://embed.foxy.io/v1.html?demo=square` (Square Card Element)" + }, + { + "name": "mode", + "type": "string", + "default": "\"production\"" + }, + { + "name": "readonly", + "type": "boolean", + "default": "false" + }, + { + "name": "readonlycontrols", + "default": "\"False\"" + }, + { + "name": "disabled", + "type": "boolean", + "default": "false" + }, + { + "name": "disabledcontrols", + "default": "\"False\"" + }, + { + "name": "hidden", + "type": "boolean", + "default": "false" + }, + { + "name": "hiddencontrols", + "default": "\"False\"" + }, + { + "name": "simplify-ns-loading", + "type": "boolean", + "default": "false" + }, + { + "name": "lang", + "type": "string", + "default": "\"\"" + }, + { + "name": "ns", + "type": "string", + "default": "\"defaultNS\"" + }, + { + "name": "infer", + "description": "Set a name for this element here to enable property inference. Set to `null` to disable.", + "type": "string" + } ], - "slots": [ + "properties": [ { - "name": "credential-id:before" + "name": "PaymentCardEmbed", + "type": "typeof PaymentCardEmbed", + "default": "\"SDKPaymentCardEmbed\"" }, { - "name": "credential-id:after" + "name": "url", + "attribute": "url", + "description": "Full Bank Card Embed URL, e.g. `https://embed.foxy.io/v1.html?template_set_id=123`.\n\nThe following demo URLs are available:\n- `https://embed.foxy.io/v1.html?demo=default` (Default form)\n- `https://embed.foxy.io/v1.html?demo=stripe` (Stripe Card Element)\n- `https://embed.foxy.io/v1.html?demo=square` (Square Card Element)" }, { - "name": "last-login-date:before" + "name": "templates", + "default": "{}" }, { - "name": "last-login-date:after" + "name": "mode", + "attribute": "mode", + "type": "string", + "default": "\"production\"" }, { - "name": "last-login-ua:before" + "name": "readonly", + "attribute": "readonly", + "type": "boolean", + "default": "false" }, { - "name": "last-login-ua:after" + "name": "readonlyControls", + "attribute": "readonlycontrols", + "default": "\"False\"" }, { - "name": "timestamps:before" + "name": "disabled", + "attribute": "disabled", + "type": "boolean", + "default": "false" }, { - "name": "timestamps:after" + "name": "disabledControls", + "attribute": "disabledcontrols", + "default": "\"False\"" }, { - "name": "create:before" + "name": "hidden", + "attribute": "hidden", + "type": "boolean", + "default": "false" + }, + { + "name": "hiddenControls", + "attribute": "hiddencontrols", + "default": "\"False\"" + }, + { + "name": "readonlySelector", + "type": "BooleanSelector" + }, + { + "name": "disabledSelector", + "type": "BooleanSelector" + }, + { + "name": "hiddenSelector", + "type": "BooleanSelector" + }, + { + "name": "simplifyNsLoading", + "attribute": "simplify-ns-loading", + "type": "boolean", + "default": "false" + }, + { + "name": "lang", + "attribute": "lang", + "type": "string", + "default": "\"\"" }, { - "name": "create:after" + "name": "ns", + "attribute": "ns", + "type": "string", + "default": "\"defaultNS\"" }, { - "name": "delete:before" + "name": "t", + "type": "Translator", + "default": "\"(key, options) => {\\n const I18nElement = customElements.get('foxy-i18n') as typeof I18n | undefined;\\n\\n if (!I18nElement) return key;\\n\\n let keys: string[];\\n\\n if (this.simplifyNsLoading) {\\n const namespaces = this.ns.split(' ').filter(v => v.length > 0);\\n const path = [...namespaces.slice(1), key].join('.');\\n keys = namespaces[0] ? [`${namespaces[0]}:${path}`] : [path];\\n } else {\\n keys = this.ns\\n .split(' ')\\n .reverse()\\n .map(v => v.trim())\\n .filter(v => v.length > 0)\\n .reverse()\\n .map((v, i, a) => `${v}:${[...a.slice(i + 1), key].join('.')}`);\\n }\\n\\n keys.push(key);\\n\\n return I18nElement.i18next.t(keys, { lng: this.lang, ...options }).toString();\\n }\"" }, { - "name": "delete:after" + "name": "infer", + "attribute": "infer", + "description": "Set a name for this element here to enable property inference. Set to `null` to disable.", + "type": "string" + } + ], + "events": [ + { + "name": "CustomEvent", + "description": "Instance of `CustomEvent` with type `submit`. Dispatched when the user submits the form (not available for Stripe)." } ] }, { - "name": "foxy-payment-card", - "path": "./src/elements/public/PaymentCard/index.ts", - "description": "Basic card displaying a payment resource (`fx:payment`).", + "name": "foxy-payment-method-card", + "path": "./src/elements/public/PaymentMethodCard/index.ts", + "description": "Basic card displaying a payment method.", "attributes": [ { - "name": "hosted-payment-gateways-helper", - "description": "URL of the `fx:hosted_payment_gateways` property helper resource." + "name": "embed-url", + "description": "Configuration URL for the Payment Card Embed. If provided,\nthe card will have an option of updating payment method.\nOtherwise, only the delete option will be available." }, { - "name": "payment-gateways-helper", - "description": "URL of the `fx:payment_gateways` property helper resource." + "name": "mode", + "type": "string", + "default": "\"production\"" + }, + { + "name": "readonly", + "type": "boolean", + "default": "false" + }, + { + "name": "readonlycontrols", + "default": "\"False\"" + }, + { + "name": "disabled", + "type": "boolean", + "default": "false" + }, + { + "name": "disabledcontrols", + "default": "\"False\"" + }, + { + "name": "hidden", + "type": "boolean", + "default": "false" + }, + { + "name": "hiddencontrols", + "default": "\"False\"" }, { "name": "simplify-ns-loading", @@ -20784,14 +19723,64 @@ ], "properties": [ { - "name": "hostedPaymentGatewaysHelper", - "attribute": "hosted-payment-gateways-helper", - "description": "URL of the `fx:hosted_payment_gateways` property helper resource." + "name": "embedUrl", + "attribute": "embed-url", + "description": "Configuration URL for the Payment Card Embed. If provided,\nthe card will have an option of updating payment method.\nOtherwise, only the delete option will be available." }, { - "name": "paymentGatewaysHelper", - "attribute": "payment-gateways-helper", - "description": "URL of the `fx:payment_gateways` property helper resource." + "name": "templates", + "default": "{}" + }, + { + "name": "mode", + "attribute": "mode", + "type": "string", + "default": "\"production\"" + }, + { + "name": "readonly", + "attribute": "readonly", + "type": "boolean", + "default": "false" + }, + { + "name": "readonlyControls", + "attribute": "readonlycontrols", + "default": "\"False\"" + }, + { + "name": "disabled", + "attribute": "disabled", + "type": "boolean", + "default": "false" + }, + { + "name": "disabledControls", + "attribute": "disabledcontrols", + "default": "\"False\"" + }, + { + "name": "hidden", + "attribute": "hidden", + "type": "boolean", + "default": "false" + }, + { + "name": "hiddenControls", + "attribute": "hiddencontrols", + "default": "\"False\"" + }, + { + "name": "readonlySelector", + "type": "BooleanSelector" + }, + { + "name": "disabledSelector", + "type": "BooleanSelector" + }, + { + "name": "hiddenSelector", + "type": "BooleanSelector" }, { "name": "simplifyNsLoading", @@ -20806,13 +19795,9 @@ "default": "\"defaultNS\"" }, { - "name": "t", - "type": "Translator", - "default": "\"(key, options) => {\\n const I18nElement = customElements.get('foxy-i18n') as typeof I18n | undefined;\\n\\n if (!I18nElement) return key;\\n\\n let keys: string[];\\n\\n if (this.simplifyNsLoading) {\\n const namespaces = this.ns.split(' ').filter(v => v.length > 0);\\n const path = [...namespaces.slice(1), key].join('.');\\n keys = namespaces[0] ? [`${namespaces[0]}:${path}`] : [path];\\n } else {\\n keys = this.ns\\n .split(' ')\\n .reverse()\\n .map(v => v.trim())\\n .filter(v => v.length > 0)\\n .reverse()\\n .map((v, i, a) => `${v}:${[...a.slice(i + 1), key].join('.')}`);\\n }\\n\\n keys.push(key);\\n\\n return I18nElement.i18next.t(keys, { lng: this.lang, ...options }).toString();\\n }\"" - }, - { - "name": "isBodyReady", - "type": "boolean" + "name": "t", + "type": "Translator", + "default": "\"(key, options) => {\\n const I18nElement = customElements.get('foxy-i18n') as typeof I18n | undefined;\\n\\n if (!I18nElement) return key;\\n\\n let keys: string[];\\n\\n if (this.simplifyNsLoading) {\\n const namespaces = this.ns.split(' ').filter(v => v.length > 0);\\n const path = [...namespaces.slice(1), key].join('.');\\n keys = namespaces[0] ? [`${namespaces[0]}:${path}`] : [path];\\n } else {\\n keys = this.ns\\n .split(' ')\\n .reverse()\\n .map(v => v.trim())\\n .filter(v => v.length > 0)\\n .reverse()\\n .map((v, i, a) => `${v}:${[...a.slice(i + 1), key].join('.')}`);\\n }\\n\\n keys.push(key);\\n\\n return I18nElement.i18next.t(keys, { lng: this.lang, ...options }).toString();\\n }\"" }, { "name": "UpdateEvent", @@ -20910,13 +19895,136 @@ ] }, { - "name": "foxy-payment-card-embed", - "path": "./src/elements/public/PaymentCardEmbed/index.ts", - "description": "A secure, PCI-compliant element for collecting payment card information with\nsupport for Stripe, Square and embedded gateways.", + "name": "foxy-payments-api", + "path": "./src/elements/public/PaymentsApi/index.ts", + "description": "Adapter element for Payments API. This element requires an additional hAPI adapter\nthat will handle authentication and session management.\n\n_Payments API is a client-side virtual API layer built on top of hAPI\nin an attempt to streamline access to stores' payment method settings\nthat is currently a bit quirky due to the legacy functionality. To use\nPayments API elements with hAPI, wrap them into this node._", "attributes": [ { - "name": "url", - "description": "Full Bank Card Embed URL, e.g. `https://embed.foxy.io/v1.html?template_set_id=123`.\n\nThe following demo URLs are available:\n- `https://embed.foxy.io/v1.html?demo=default` (Default form)\n- `https://embed.foxy.io/v1.html?demo=stripe` (Stripe Card Element)\n- `https://embed.foxy.io/v1.html?demo=square` (Square Card Element)" + "name": "payment-method-set-hosted-payment-gateway-base-url", + "description": "Base URL of the `fx:payment_method_set_hosted_payment_gateway` resource (without ID)." + }, + { + "name": "payment-method-set-hosted-payment-gateways-url", + "description": "URL of the `fx:payment_method_set_hosted_payment_gateways` collection." + }, + { + "name": "hosted-payment-gateways-helper-url", + "description": "URL of the `fx:hosted_payment_gateways` property helper." + }, + { + "name": "hosted-payment-gateway-base-url", + "description": "Base URL of the `fx:hosted_payment_gateway` resource (without ID)." + }, + { + "name": "hosted-payment-gateways-url", + "description": "URL of the `fx:hosted_payment_gateways` collection." + }, + { + "name": "payment-gateways-helper-url", + "description": "URL of the `fx:payment_gateways` property helper." + }, + { + "name": "payment-method-set-base-url", + "description": "Base URL of the `fx:payment_method_set` resource (without ID)." + }, + { + "name": "payment-method-sets-url", + "description": "URL of the `fx:payment_method_sets` collection." + }, + { + "name": "fraud-protection-base-url", + "description": "Base URL of the `fx:fraud_protection` resource (without ID)." + }, + { + "name": "fraud-protections-url", + "description": "URL of the `fx:fraud_protections` collection." + }, + { + "name": "payment-gateway-base-url", + "description": "Base URL of the `fx:payment_gateway` resource (without ID)." + }, + { + "name": "payment-gateways-url", + "description": "URL of the `fx:payment_gateways` collection." + } + ], + "properties": [ + { + "name": "paymentMethodSetHostedPaymentGatewayBaseUrl", + "attribute": "payment-method-set-hosted-payment-gateway-base-url", + "description": "Base URL of the `fx:payment_method_set_hosted_payment_gateway` resource (without ID)." + }, + { + "name": "paymentMethodSetHostedPaymentGatewaysUrl", + "attribute": "payment-method-set-hosted-payment-gateways-url", + "description": "URL of the `fx:payment_method_set_hosted_payment_gateways` collection." + }, + { + "name": "hostedPaymentGatewaysHelperUrl", + "attribute": "hosted-payment-gateways-helper-url", + "description": "URL of the `fx:hosted_payment_gateways` property helper." + }, + { + "name": "hostedPaymentGatewayBaseUrl", + "attribute": "hosted-payment-gateway-base-url", + "description": "Base URL of the `fx:hosted_payment_gateway` resource (without ID)." + }, + { + "name": "hostedPaymentGatewaysUrl", + "attribute": "hosted-payment-gateways-url", + "description": "URL of the `fx:hosted_payment_gateways` collection." + }, + { + "name": "paymentGatewaysHelperUrl", + "attribute": "payment-gateways-helper-url", + "description": "URL of the `fx:payment_gateways` property helper." + }, + { + "name": "paymentMethodSetBaseUrl", + "attribute": "payment-method-set-base-url", + "description": "Base URL of the `fx:payment_method_set` resource (without ID)." + }, + { + "name": "paymentMethodSetsUrl", + "attribute": "payment-method-sets-url", + "description": "URL of the `fx:payment_method_sets` collection." + }, + { + "name": "fraudProtectionBaseUrl", + "attribute": "fraud-protection-base-url", + "description": "Base URL of the `fx:fraud_protection` resource (without ID)." + }, + { + "name": "fraudProtectionsUrl", + "attribute": "fraud-protections-url", + "description": "URL of the `fx:fraud_protections` collection." + }, + { + "name": "paymentGatewayBaseUrl", + "attribute": "payment-gateway-base-url", + "description": "Base URL of the `fx:payment_gateway` resource (without ID)." + }, + { + "name": "paymentGatewaysUrl", + "attribute": "payment-gateways-url", + "description": "URL of the `fx:payment_gateways` collection." + } + ] + }, + { + "name": "foxy-payments-api-fraud-protection-card", + "path": "./src/elements/public/PaymentsApiFraudProtectionCard/index.ts", + "description": "Card element representing a `fx:fraud_protection` resource of Payments API.\n\n_Payments API is a client-side virtual API layer built on top of hAPI\nin an attempt to streamline access to stores' payment method settings\nthat is currently a bit quirky due to the legacy functionality. To use\nthis element with hAPI, wrap it into a foxy-payments-api node._", + "attributes": [ + { + "name": "simplify-ns-loading", + "type": "boolean", + "default": "false" + }, + { + "name": "ns", + "type": "string", + "default": "\"defaultNS\"" }, { "name": "mode", @@ -20950,20 +20058,38 @@ "name": "hiddencontrols", "default": "\"False\"" }, - { - "name": "simplify-ns-loading", - "type": "boolean", - "default": "false" - }, { "name": "lang", + "description": "Optional ISO 639-1 code describing the language element content is written in.\nChanging the `lang` attribute will update the value of this property.", "type": "string", "default": "\"\"" }, { - "name": "ns", + "name": "parent", + "description": "Optional URL of the collection this element's resource belongs to.\nChanging the `parent` attribute will update the value of this property.", "type": "string", - "default": "\"defaultNS\"" + "default": "\"\"" + }, + { + "name": "related", + "description": "Optional URI list of the related resources. If Rumour encounters a related\nresource on creation or deletion, it will be reloaded from source.", + "type": "array", + "default": "[]" + }, + { + "name": "virtual-host", + "description": "Unique identifier for the virtual host used by the element to serve internal requests.\n\nCurrently only one endpoint is supported: `foxy:///form/`.\nThis endpoint supports POST, GET, PATCH and DELETE methods and functions like a hAPI server.\n\nFor example, `GET foxy://nucleon-123/form/subscriptions/allowNextDateModification/0` on a NucleonElement\nwith `fx:customer_portal_settings` will return the first item of the `subscriptions.allowNextDateModification` array.", + "default": "\"uniqueId('nucleon-')\"" + }, + { + "name": "group", + "description": "Rumour group. Elements in different groups will not share updates. Empty by default.", + "type": "string" + }, + { + "name": "href", + "description": "Optional URL of the resource to load. Switches element to `idle.template` state if empty (default).", + "type": "string" }, { "name": "infer", @@ -20973,14 +20099,25 @@ ], "properties": [ { - "name": "PaymentCardEmbed", - "type": "typeof PaymentCardEmbed", - "default": "\"SDKPaymentCardEmbed\"" + "name": "getImageSrc", + "description": "Fraud protection image/logo URL getter.\nIf left `null`, the card will display the default image." }, { - "name": "url", - "attribute": "url", - "description": "Full Bank Card Embed URL, e.g. `https://embed.foxy.io/v1.html?template_set_id=123`.\n\nThe following demo URLs are available:\n- `https://embed.foxy.io/v1.html?demo=default` (Default form)\n- `https://embed.foxy.io/v1.html?demo=stripe` (Stripe Card Element)\n- `https://embed.foxy.io/v1.html?demo=square` (Square Card Element)" + "name": "simplifyNsLoading", + "attribute": "simplify-ns-loading", + "type": "boolean", + "default": "false" + }, + { + "name": "ns", + "attribute": "ns", + "type": "string", + "default": "\"defaultNS\"" + }, + { + "name": "t", + "type": "Translator", + "default": "\"(key, options) => {\\n const I18nElement = customElements.get('foxy-i18n') as typeof I18n | undefined;\\n\\n if (!I18nElement) return key;\\n\\n let keys: string[];\\n\\n if (this.simplifyNsLoading) {\\n const namespaces = this.ns.split(' ').filter(v => v.length > 0);\\n const path = [...namespaces.slice(1), key].join('.');\\n keys = namespaces[0] ? [`${namespaces[0]}:${path}`] : [path];\\n } else {\\n keys = this.ns\\n .split(' ')\\n .reverse()\\n .map(v => v.trim())\\n .filter(v => v.length > 0)\\n .reverse()\\n .map((v, i, a) => `${v}:${[...a.slice(i + 1), key].join('.')}`);\\n }\\n\\n keys.push(key);\\n\\n return I18nElement.i18next.t(keys, { lng: this.lang, ...options }).toString();\\n }\"" }, { "name": "templates", @@ -21038,27 +20175,85 @@ "type": "BooleanSelector" }, { - "name": "simplifyNsLoading", - "attribute": "simplify-ns-loading", - "type": "boolean", - "default": "false" + "name": "isBodyReady", + "type": "boolean" + }, + { + "name": "UpdateEvent", + "description": "Instances of this event are dispatched on an element whenever it changes its\nstate (e.g. when going from `busy` to `idle` or on `form` data change).\nThis event isn't cancelable, and it does not bubble.", + "type": "typeof UpdateEvent", + "default": "\"UpdateEvent\"" + }, + { + "name": "Rumour", + "description": "Creates a tagged [Rumour](https://sdk.foxy.dev/classes/_core_index_.rumour.html)\ninstance if it doesn't exist or returns cached one otherwise. NucleonElements\nuse empty Rumour group by default.", + "type": "((group: string) => Rumour) & MemoizedFunction", + "default": "\"memoize<(group: string) => Rumour>(() => new Rumour())\"" + }, + { + "name": "API", + "description": "Universal [API](https://sdk.foxy.dev/classes/_core_index_.api.html) client\nthat dispatches cancellable `FetchEvent` on an element before each request.", + "type": "typeof API", + "default": "\"API\"" + }, + { + "name": "lang", + "attribute": "lang", + "description": "Optional ISO 639-1 code describing the language element content is written in.\nChanging the `lang` attribute will update the value of this property.", + "type": "string", + "default": "\"\"" + }, + { + "name": "parent", + "attribute": "parent", + "description": "Optional URL of the collection this element's resource belongs to.\nChanging the `parent` attribute will update the value of this property.", + "type": "string", + "default": "\"\"" + }, + { + "name": "related", + "attribute": "related", + "description": "Optional URI list of the related resources. If Rumour encounters a related\nresource on creation or deletion, it will be reloaded from source.", + "type": "array", + "default": "[]" + }, + { + "name": "virtualHost", + "attribute": "virtual-host", + "description": "Unique identifier for the virtual host used by the element to serve internal requests.\n\nCurrently only one endpoint is supported: `foxy:///form/`.\nThis endpoint supports POST, GET, PATCH and DELETE methods and functions like a hAPI server.\n\nFor example, `GET foxy://nucleon-123/form/subscriptions/allowNextDateModification/0` on a NucleonElement\nwith `fx:customer_portal_settings` will return the first item of the `subscriptions.allowNextDateModification` array.", + "default": "\"uniqueId('nucleon-')\"" + }, + { + "name": "failure", + "description": "If network request returns non-2XX code, the entire error response\nwill be available via this getter.\n\nThis property is readonly. Changing failure records via this property is\nnot guaranteed to work. NucleonElement does not provide a way to override error status.", + "type": "Response | null" + }, + { + "name": "errors", + "description": "Array of validation errors returned from `NucleonElement.v8n` checks.\n\nThis property is readonly. Adding or removing error codes via this property is\nnot guaranteed to work. NucleonElement does not provide a way to override validity status.", + "type": "string[]" + }, + { + "name": "form", + "description": "Resource snapshot with edits applied. Empty object if unavailable.\n\nThis property and its value are readonly. Assignments like `element.data.foo = 'bar'`\nare not guaranteed to work. Please use `element.edit({ foo: 'bar' })` instead.\nIf you need to replace the entire data object, consider using `element.data`.", + "type": "Partial" }, { - "name": "lang", - "attribute": "lang", - "type": "string", - "default": "\"\"" + "name": "data", + "description": "Resource snapshot as-is, no edits applied. Null if unavailable.\n\nReturned value is not reactive. Assignments like `element.data.foo = 'bar'`\nare not guaranteed to work. Please set the property instead: `element.data = { ...element.data, foo: 'bar' }`.\nIf you're processing user input, consider using `element.form` and `element.edit()` instead.", + "type": "TData | null" }, { - "name": "ns", - "attribute": "ns", - "type": "string", - "default": "\"defaultNS\"" + "name": "group", + "attribute": "group", + "description": "Rumour group. Elements in different groups will not share updates. Empty by default.", + "type": "string" }, { - "name": "t", - "type": "Translator", - "default": "\"(key, options) => {\\n const I18nElement = customElements.get('foxy-i18n') as typeof I18n | undefined;\\n\\n if (!I18nElement) return key;\\n\\n let keys: string[];\\n\\n if (this.simplifyNsLoading) {\\n const namespaces = this.ns.split(' ').filter(v => v.length > 0);\\n const path = [...namespaces.slice(1), key].join('.');\\n keys = namespaces[0] ? [`${namespaces[0]}:${path}`] : [path];\\n } else {\\n keys = this.ns\\n .split(' ')\\n .reverse()\\n .map(v => v.trim())\\n .filter(v => v.length > 0)\\n .reverse()\\n .map((v, i, a) => `${v}:${[...a.slice(i + 1), key].join('.')}`);\\n }\\n\\n keys.push(key);\\n\\n return I18nElement.i18next.t(keys, { lng: this.lang, ...options }).toString();\\n }\"" + "name": "href", + "attribute": "href", + "description": "Optional URL of the resource to load. Switches element to `idle.template` state if empty (default).", + "type": "string" }, { "name": "infer", @@ -21069,19 +20264,34 @@ ], "events": [ { - "name": "CustomEvent", - "description": "Instance of `CustomEvent` with type `submit`. Dispatched when the user submits the form (not available for Stripe)." + "name": "update", + "description": "Instance of `NucleonElement.UpdateEvent`. Dispatched on an element whenever it changes its state." + }, + { + "name": "fetch", + "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } ] }, { - "name": "foxy-payment-method-card", - "path": "./src/elements/public/PaymentMethodCard/index.ts", - "description": "Basic card displaying a payment method.", + "name": "foxy-payments-api-fraud-protection-form", + "path": "./src/elements/public/PaymentsApiFraudProtectionForm/index.ts", + "description": "Form element for the `fx:fraud_protection` resource of Payments API.\n\n_Payments API is a client-side virtual API layer built on top of hAPI\nin an attempt to streamline access to stores' payment method settings\nthat is currently a bit quirky due to the legacy functionality. To use\nthis element with hAPI, wrap it into a foxy-payments-api node._", "attributes": [ { - "name": "embed-url", - "description": "Configuration URL for the Payment Card Embed. If provided,\nthe card will have an option of updating payment method.\nOtherwise, only the delete option will be available." + "name": "simplify-ns-loading", + "type": "boolean", + "default": "false" + }, + { + "name": "ns", + "type": "string", + "default": "\"defaultNS\"" + }, + { + "name": "status", + "description": "Status message to render at the top of the form. If `null`, the message is hidden.", + "type": "object" }, { "name": "mode", @@ -21115,16 +20325,6 @@ "name": "hiddencontrols", "default": "\"False\"" }, - { - "name": "simplify-ns-loading", - "type": "boolean", - "default": "false" - }, - { - "name": "ns", - "type": "string", - "default": "\"defaultNS\"" - }, { "name": "lang", "description": "Optional ISO 639-1 code describing the language element content is written in.\nChanging the `lang` attribute will update the value of this property.", @@ -21166,13 +20366,65 @@ ], "properties": [ { - "name": "embedUrl", - "attribute": "embed-url", - "description": "Configuration URL for the Payment Card Embed. If provided,\nthe card will have an option of updating payment method.\nOtherwise, only the delete option will be available." + "name": "getImageSrc", + "description": "A function that returns a URL of a fraud protection icon based on the given type." + }, + { + "name": "simplifyNsLoading", + "attribute": "simplify-ns-loading", + "type": "boolean", + "default": "false" + }, + { + "name": "ns", + "attribute": "ns", + "type": "string", + "default": "\"defaultNS\"" + }, + { + "name": "t", + "type": "Translator", + "default": "\"(key, options) => {\\n const I18nElement = customElements.get('foxy-i18n') as typeof I18n | undefined;\\n\\n if (!I18nElement) return key;\\n\\n let keys: string[];\\n\\n if (this.simplifyNsLoading) {\\n const namespaces = this.ns.split(' ').filter(v => v.length > 0);\\n const path = [...namespaces.slice(1), key].join('.');\\n keys = namespaces[0] ? [`${namespaces[0]}:${path}`] : [path];\\n } else {\\n keys = this.ns\\n .split(' ')\\n .reverse()\\n .map(v => v.trim())\\n .filter(v => v.length > 0)\\n .reverse()\\n .map((v, i, a) => `${v}:${[...a.slice(i + 1), key].join('.')}`);\\n }\\n\\n keys.push(key);\\n\\n return I18nElement.i18next.t(keys, { lng: this.lang, ...options }).toString();\\n }\"" + }, + { + "name": "generalErrorPrefix", + "description": "Validation errors with this prefix will show up at the top of the form.", + "type": "string", + "default": "\"error:\"" + }, + { + "name": "status", + "attribute": "status", + "description": "Status message to render at the top of the form. If `null`, the message is hidden.", + "type": "object" + }, + { + "name": "headerTitleKey", + "description": "Getter that returns a i18n key for the optional form header title.", + "type": "string" + }, + { + "name": "headerTitleOptions", + "description": "I18next options to pass to the header title translation function.", + "type": "Record" + }, + { + "name": "headerSubtitleKey", + "description": "Getter that returns a i18n key for the optional form header subtitle. Note that subtitle is shown only when data is avaiable.", + "type": "string" + }, + { + "name": "headerSubtitleOptions", + "description": "I18next options to pass to the header subtitle translation function. Note that subtitle is shown only when data is avaiable.", + "type": "Record" + }, + { + "name": "headerCopyIdValue", + "description": "ID that will be written to clipboard when Copy ID button in header is clicked.", + "type": "string | number" }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -21226,23 +20478,6 @@ "name": "hiddenSelector", "type": "BooleanSelector" }, - { - "name": "simplifyNsLoading", - "attribute": "simplify-ns-loading", - "type": "boolean", - "default": "false" - }, - { - "name": "ns", - "attribute": "ns", - "type": "string", - "default": "\"defaultNS\"" - }, - { - "name": "t", - "type": "Translator", - "default": "\"(key, options) => {\\n const I18nElement = customElements.get('foxy-i18n') as typeof I18n | undefined;\\n\\n if (!I18nElement) return key;\\n\\n let keys: string[];\\n\\n if (this.simplifyNsLoading) {\\n const namespaces = this.ns.split(' ').filter(v => v.length > 0);\\n const path = [...namespaces.slice(1), key].join('.');\\n keys = namespaces[0] ? [`${namespaces[0]}:${path}`] : [path];\\n } else {\\n keys = this.ns\\n .split(' ')\\n .reverse()\\n .map(v => v.trim())\\n .filter(v => v.length > 0)\\n .reverse()\\n .map((v, i, a) => `${v}:${[...a.slice(i + 1), key].join('.')}`);\\n }\\n\\n keys.push(key);\\n\\n return I18nElement.i18next.t(keys, { lng: this.lang, ...options }).toString();\\n }\"" - }, { "name": "UpdateEvent", "description": "Instances of this event are dispatched on an element whenever it changes its\nstate (e.g. when going from `busy` to `idle` or on `form` data change).\nThis event isn't cancelable, and it does not bubble.", @@ -21336,155 +20571,12 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "actions:before", - "description": "**new in v1.4.0**" - }, - { - "name": "actions:after", - "description": "**new in v1.4.0**" - }, - { - "name": "actions:delete:before", - "description": "**new in v1.4.0**" - }, - { - "name": "actions:delete:after", - "description": "**new in v1.4.0**" - }, - { - "name": "actions:update:before", - "description": "**new in v1.27.0**" - }, - { - "name": "actions:update:after", - "description": "**new in v1.27.0**" - } - ] - }, - { - "name": "foxy-payments-api", - "path": "./src/elements/public/PaymentsApi/index.ts", - "description": "Adapter element for Payments API. This element requires an additional hAPI adapter\nthat will handle authentication and session management.\n\n_Payments API is a client-side virtual API layer built on top of hAPI\nin an attempt to streamline access to stores' payment method settings\nthat is currently a bit quirky due to the legacy functionality. To use\nPayments API elements with hAPI, wrap them into this node._", - "attributes": [ - { - "name": "payment-method-set-hosted-payment-gateway-base-url", - "description": "Base URL of the `fx:payment_method_set_hosted_payment_gateway` resource (without ID)." - }, - { - "name": "payment-method-set-hosted-payment-gateways-url", - "description": "URL of the `fx:payment_method_set_hosted_payment_gateways` collection." - }, - { - "name": "hosted-payment-gateways-helper-url", - "description": "URL of the `fx:hosted_payment_gateways` property helper." - }, - { - "name": "hosted-payment-gateway-base-url", - "description": "Base URL of the `fx:hosted_payment_gateway` resource (without ID)." - }, - { - "name": "hosted-payment-gateways-url", - "description": "URL of the `fx:hosted_payment_gateways` collection." - }, - { - "name": "payment-gateways-helper-url", - "description": "URL of the `fx:payment_gateways` property helper." - }, - { - "name": "payment-method-set-base-url", - "description": "Base URL of the `fx:payment_method_set` resource (without ID)." - }, - { - "name": "payment-method-sets-url", - "description": "URL of the `fx:payment_method_sets` collection." - }, - { - "name": "fraud-protection-base-url", - "description": "Base URL of the `fx:fraud_protection` resource (without ID)." - }, - { - "name": "fraud-protections-url", - "description": "URL of the `fx:fraud_protections` collection." - }, - { - "name": "payment-gateway-base-url", - "description": "Base URL of the `fx:payment_gateway` resource (without ID)." - }, - { - "name": "payment-gateways-url", - "description": "URL of the `fx:payment_gateways` collection." - } - ], - "properties": [ - { - "name": "paymentMethodSetHostedPaymentGatewayBaseUrl", - "attribute": "payment-method-set-hosted-payment-gateway-base-url", - "description": "Base URL of the `fx:payment_method_set_hosted_payment_gateway` resource (without ID)." - }, - { - "name": "paymentMethodSetHostedPaymentGatewaysUrl", - "attribute": "payment-method-set-hosted-payment-gateways-url", - "description": "URL of the `fx:payment_method_set_hosted_payment_gateways` collection." - }, - { - "name": "hostedPaymentGatewaysHelperUrl", - "attribute": "hosted-payment-gateways-helper-url", - "description": "URL of the `fx:hosted_payment_gateways` property helper." - }, - { - "name": "hostedPaymentGatewayBaseUrl", - "attribute": "hosted-payment-gateway-base-url", - "description": "Base URL of the `fx:hosted_payment_gateway` resource (without ID)." - }, - { - "name": "hostedPaymentGatewaysUrl", - "attribute": "hosted-payment-gateways-url", - "description": "URL of the `fx:hosted_payment_gateways` collection." - }, - { - "name": "paymentGatewaysHelperUrl", - "attribute": "payment-gateways-helper-url", - "description": "URL of the `fx:payment_gateways` property helper." - }, - { - "name": "paymentMethodSetBaseUrl", - "attribute": "payment-method-set-base-url", - "description": "Base URL of the `fx:payment_method_set` resource (without ID)." - }, - { - "name": "paymentMethodSetsUrl", - "attribute": "payment-method-sets-url", - "description": "URL of the `fx:payment_method_sets` collection." - }, - { - "name": "fraudProtectionBaseUrl", - "attribute": "fraud-protection-base-url", - "description": "Base URL of the `fx:fraud_protection` resource (without ID)." - }, - { - "name": "fraudProtectionsUrl", - "attribute": "fraud-protections-url", - "description": "URL of the `fx:fraud_protections` collection." - }, - { - "name": "paymentGatewayBaseUrl", - "attribute": "payment-gateway-base-url", - "description": "Base URL of the `fx:payment_gateway` resource (without ID)." - }, - { - "name": "paymentGatewaysUrl", - "attribute": "payment-gateways-url", - "description": "URL of the `fx:payment_gateways` collection." - } ] }, { - "name": "foxy-payments-api-fraud-protection-card", - "path": "./src/elements/public/PaymentsApiFraudProtectionCard/index.ts", - "description": "Card element representing a `fx:fraud_protection` resource of Payments API.\n\n_Payments API is a client-side virtual API layer built on top of hAPI\nin an attempt to streamline access to stores' payment method settings\nthat is currently a bit quirky due to the legacy functionality. To use\nthis element with hAPI, wrap it into a foxy-payments-api node._", + "name": "foxy-payments-api-payment-method-card", + "path": "./src/elements/public/PaymentsApiPaymentMethodCard/index.ts", + "description": "Card element representing a `fx:payment_method` resource of Payments API.\n\n_Payments API is a client-side virtual API layer built on top of hAPI\nin an attempt to streamline access to stores' payment method settings\nthat is currently a bit quirky due to the legacy functionality. To use\nthis element with hAPI, wrap it into a foxy-payments-api node._", "attributes": [ { "name": "simplify-ns-loading", @@ -21570,7 +20662,7 @@ "properties": [ { "name": "getImageSrc", - "description": "Fraud protection image/logo URL getter.\nIf left `null`, the card will display the default image." + "description": "Payment method image/logo URL getter.\nIf left `null`, the card will display the default image." }, { "name": "simplifyNsLoading", @@ -21591,7 +20683,6 @@ }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -21742,26 +20833,12 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "title:before" - }, - { - "name": "title:after" - }, - { - "name": "subtitle:before" - }, - { - "name": "subtitle:after" - } ] }, { - "name": "foxy-payments-api-fraud-protection-form", - "path": "./src/elements/public/PaymentsApiFraudProtectionForm/index.ts", - "description": "Form element for the `fx:fraud_protection` resource of Payments API.\n\n_Payments API is a client-side virtual API layer built on top of hAPI\nin an attempt to streamline access to stores' payment method settings\nthat is currently a bit quirky due to the legacy functionality. To use\nthis element with hAPI, wrap it into a foxy-payments-api node._", + "name": "foxy-payments-api-payment-method-form", + "path": "./src/elements/public/PaymentsApiPaymentMethodForm/index.ts", + "description": "Form element for the `fx:payment_method` resource of Payments API.\n\n_Payments API is a client-side virtual API layer built on top of hAPI\nin an attempt to streamline access to stores' payment method settings\nthat is currently a bit quirky due to the legacy functionality. To use\nthis element with hAPI, wrap it into a foxy-payments-api node._", "attributes": [ { "name": "simplify-ns-loading", @@ -21852,7 +20929,7 @@ "properties": [ { "name": "getImageSrc", - "description": "A function that returns a URL of a fraud protection icon based on the given type." + "description": "A function that returns a URL of a payment method icon based on the given type." }, { "name": "simplifyNsLoading", @@ -21883,10 +20960,33 @@ "description": "Status message to render at the top of the form. If `null`, the message is hidden.", "type": "object" }, + { + "name": "headerTitleKey", + "description": "Getter that returns a i18n key for the optional form header title.", + "type": "string" + }, + { + "name": "headerTitleOptions", + "description": "I18next options to pass to the header title translation function.", + "type": "Record" + }, + { + "name": "headerSubtitleKey", + "description": "Getter that returns a i18n key for the optional form header subtitle. Note that subtitle is shown only when data is avaiable.", + "type": "string" + }, + { + "name": "headerSubtitleOptions", + "description": "I18next options to pass to the header subtitle translation function. Note that subtitle is shown only when data is avaiable.", + "type": "Record" + }, + { + "name": "headerCopyIdValue", + "description": "ID that will be written to clipboard when Copy ID button in header is clicked.", + "type": "string | number" + }, { "name": "templates", - "description": "Template render functions mapped to their name.", - "type": "Templates", "default": "{}" }, { @@ -22033,50 +21133,12 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "description:before" - }, - { - "name": "description:after" - }, - { - "name": "score-threshold-reject:before" - }, - { - "name": "score-threshold-reject:after" - }, - { - "name": "json-[field-name-in-kebab-case]:before" - }, - { - "name": "json-[field-name-in-kebab-case]:after" - }, - { - "name": "timestamps:before" - }, - { - "name": "timestamps:after" - }, - { - "name": "create:before" - }, - { - "name": "create:after" - }, - { - "name": "delete:before" - }, - { - "name": "delete:after" - } ] }, { - "name": "foxy-payments-api-payment-method-card", - "path": "./src/elements/public/PaymentsApiPaymentMethodCard/index.ts", - "description": "Card element representing a `fx:payment_method` resource of Payments API.\n\n_Payments API is a client-side virtual API layer built on top of hAPI\nin an attempt to streamline access to stores' payment method settings\nthat is currently a bit quirky due to the legacy functionality. To use\nthis element with hAPI, wrap it into a foxy-payments-api node._", + "name": "foxy-payments-api-payment-preset-card", + "path": "./src/elements/public/PaymentsApiPaymentPresetCard/index.ts", + "description": "Card element representing a `fx:payment_preset` resource of Payments API.\n\n_Payments API is a client-side virtual API layer built on top of hAPI\nin an attempt to streamline access to stores' payment method settings\nthat is currently a bit quirky due to the legacy functionality. To use\nthis element with hAPI, wrap it into a foxy-payments-api node._", "attributes": [ { "name": "simplify-ns-loading", @@ -22160,10 +21222,6 @@ } ], "properties": [ - { - "name": "getImageSrc", - "description": "Payment method image/logo URL getter.\nIf left `null`, the card will display the default image." - }, { "name": "simplifyNsLoading", "attribute": "simplify-ns-loading", @@ -22183,7 +21241,6 @@ }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -22334,26 +21391,12 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "title:before" - }, - { - "name": "title:after" - }, - { - "name": "subtitle:before" - }, - { - "name": "subtitle:after" - } ] }, { - "name": "foxy-payments-api-payment-method-form", - "path": "./src/elements/public/PaymentsApiPaymentMethodForm/index.ts", - "description": "Form element for the `fx:payment_method` resource of Payments API.\n\n_Payments API is a client-side virtual API layer built on top of hAPI\nin an attempt to streamline access to stores' payment method settings\nthat is currently a bit quirky due to the legacy functionality. To use\nthis element with hAPI, wrap it into a foxy-payments-api node._", + "name": "foxy-payments-api-payment-preset-form", + "path": "./src/elements/public/PaymentsApiPaymentPresetForm/index.ts", + "description": "Form element for the `fx:payment_preset` resource of Payments API.\n\n_Payments API is a client-side virtual API layer built on top of hAPI\nin an attempt to streamline access to stores' payment method settings\nthat is currently a bit quirky due to the legacy functionality. To use\nthis element with hAPI, wrap it into a foxy-payments-api node._", "attributes": [ { "name": "simplify-ns-loading", @@ -22443,8 +21486,12 @@ ], "properties": [ { - "name": "getImageSrc", - "description": "A function that returns a URL of a payment method icon based on the given type." + "name": "getFraudProtectionImageSrc", + "description": "A function that returns image URL for given fraud protection `type`." + }, + { + "name": "getPaymentMethodImageSrc", + "description": "A function that returns image URL for given payment method `type`." }, { "name": "simplifyNsLoading", @@ -22475,10 +21522,33 @@ "description": "Status message to render at the top of the form. If `null`, the message is hidden.", "type": "object" }, + { + "name": "headerTitleKey", + "description": "Getter that returns a i18n key for the optional form header title.", + "type": "string" + }, + { + "name": "headerTitleOptions", + "description": "I18next options to pass to the header title translation function.", + "type": "Record" + }, + { + "name": "headerSubtitleKey", + "description": "Getter that returns a i18n key for the optional form header subtitle. Note that subtitle is shown only when data is avaiable.", + "type": "string" + }, + { + "name": "headerSubtitleOptions", + "description": "I18next options to pass to the header subtitle translation function. Note that subtitle is shown only when data is avaiable.", + "type": "Record" + }, + { + "name": "headerCopyIdValue", + "description": "ID that will be written to clipboard when Copy ID button in header is clicked.", + "type": "string | number" + }, { "name": "templates", - "description": "Template render functions mapped to their name.", - "type": "Templates", "default": "{}" }, { @@ -22625,102 +21695,34 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "description:before" - }, - { - "name": "description:after" - }, - { - "name": "account-id:before" - }, - { - "name": "account-id:after" - }, - { - "name": "account-key:before" - }, - { - "name": "account-key:after" - }, - { - "name": "third-party-key:before" - }, - { - "name": "third-party-key:after" - }, - { - "name": "test-account-id:before" - }, - { - "name": "test-account-id:after" - }, - { - "name": "test-account-key:before" - }, - { - "name": "test-account-key:after" - }, - { - "name": "test-third-party-key:before" - }, - { - "name": "test-third-party-key:after" - }, - { - "name": "additional-fields-[field-name-in-kebab-case]:before" - }, - { - "name": "additional-fields-[field-name-in-kebab-case]:after" - }, - { - "name": "three-d-secure-toggle:before" - }, - { - "name": "three-d-secure-toggle:after" - }, - { - "name": "three-d-secure-response:before" - }, - { - "name": "three-d-secure-response:after" - }, - { - "name": "timestamps:before" - }, - { - "name": "timestamps:after" - }, - { - "name": "create:before" - }, - { - "name": "create:after" - }, - { - "name": "delete:before" - }, - { - "name": "delete:after" - } ] }, { - "name": "foxy-payments-api-payment-preset-card", - "path": "./src/elements/public/PaymentsApiPaymentPresetCard/index.ts", - "description": "Card element representing a `fx:payment_preset` resource of Payments API.\n\n_Payments API is a client-side virtual API layer built on top of hAPI\nin an attempt to streamline access to stores' payment method settings\nthat is currently a bit quirky due to the legacy functionality. To use\nthis element with hAPI, wrap it into a foxy-payments-api node._", + "name": "foxy-query-builder", + "path": "./src/elements/public/QueryBuilder/index.ts", + "description": "UI component for creating Foxy hAPI filters visually. Compatible with\nBackend API, Customer API or any other API using the same format as described\nin our [docs](https://api.foxy.io/docs/cheat-sheet).", "attributes": [ { - "name": "simplify-ns-loading", + "name": "operators", + "description": "List of operators available in the builder UI.", + "type": "array", + "default": "\"Object.values(Operator)\"" + }, + { + "name": "disable-or", + "description": "If true, hides the UI for the \"OR\" operator in queries.", "type": "boolean", "default": "false" }, { - "name": "ns", - "type": "string", - "default": "\"defaultNS\"" + "name": "options", + "description": "Autocomplete suggestions.", + "type": "array" + }, + { + "name": "value", + "description": "Current value as hAPI filter string.", + "type": "string" }, { "name": "mode", @@ -22754,66 +21756,74 @@ "name": "hiddencontrols", "default": "\"False\"" }, + { + "name": "simplify-ns-loading", + "type": "boolean", + "default": "false" + }, { "name": "lang", - "description": "Optional ISO 639-1 code describing the language element content is written in.\nChanging the `lang` attribute will update the value of this property.", "type": "string", "default": "\"\"" }, { - "name": "parent", - "description": "Optional URL of the collection this element's resource belongs to.\nChanging the `parent` attribute will update the value of this property.", + "name": "ns", "type": "string", - "default": "\"\"" + "default": "\"defaultNS\"" }, { - "name": "related", - "description": "Optional URI list of the related resources. If Rumour encounters a related\nresource on creation or deletion, it will be reloaded from source.", - "type": "array", - "default": "[]" - }, + "name": "infer", + "description": "Set a name for this element here to enable property inference. Set to `null` to disable.", + "type": "string" + } + ], + "properties": [ { - "name": "virtual-host", - "description": "Unique identifier for the virtual host used by the element to serve internal requests.\n\nCurrently only one endpoint is supported: `foxy:///form/`.\nThis endpoint supports POST, GET, PATCH and DELETE methods and functions like a hAPI server.\n\nFor example, `GET foxy://nucleon-123/form/subscriptions/allowNextDateModification/0` on a NucleonElement\nwith `fx:customer_portal_settings` will return the first item of the `subscriptions.allowNextDateModification` array.", - "default": "\"uniqueId('nucleon-')\"" + "name": "ChangeEvent", + "description": "QueryBuilder dispatches this event on itself when value changes.", + "type": "typeof (Anonymous class)", + "default": "\"class extends CustomEvent {}\"" }, { - "name": "group", - "description": "Rumour group. Elements in different groups will not share updates. Empty by default.", - "type": "string" + "name": "Operator", + "description": "Operator dictionary for use in autocomplete options.", + "type": "typeof Operator", + "default": "\"Operator\"" }, { - "name": "href", - "description": "Optional URL of the resource to load. Switches element to `idle.template` state if empty (default).", - "type": "string" + "name": "Type", + "description": "Field type dictionary for use in autocomplete options.", + "type": "typeof Type", + "default": "\"Type\"" }, { - "name": "infer", - "description": "Set a name for this element here to enable property inference. Set to `null` to disable.", - "type": "string" - } - ], - "properties": [ + "name": "operators", + "attribute": "operators", + "description": "List of operators available in the builder UI.", + "type": "array", + "default": "\"Object.values(Operator)\"" + }, { - "name": "simplifyNsLoading", - "attribute": "simplify-ns-loading", + "name": "disableOr", + "attribute": "disable-or", + "description": "If true, hides the UI for the \"OR\" operator in queries.", "type": "boolean", "default": "false" }, { - "name": "ns", - "attribute": "ns", - "type": "string", - "default": "\"defaultNS\"" + "name": "options", + "attribute": "options", + "description": "Autocomplete suggestions.", + "type": "array" }, { - "name": "t", - "type": "Translator", - "default": "\"(key, options) => {\\n const I18nElement = customElements.get('foxy-i18n') as typeof I18n | undefined;\\n\\n if (!I18nElement) return key;\\n\\n let keys: string[];\\n\\n if (this.simplifyNsLoading) {\\n const namespaces = this.ns.split(' ').filter(v => v.length > 0);\\n const path = [...namespaces.slice(1), key].join('.');\\n keys = namespaces[0] ? [`${namespaces[0]}:${path}`] : [path];\\n } else {\\n keys = this.ns\\n .split(' ')\\n .reverse()\\n .map(v => v.trim())\\n .filter(v => v.length > 0)\\n .reverse()\\n .map((v, i, a) => `${v}:${[...a.slice(i + 1), key].join('.')}`);\\n }\\n\\n keys.push(key);\\n\\n return I18nElement.i18next.t(keys, { lng: this.lang, ...options }).toString();\\n }\"" + "name": "value", + "attribute": "value", + "description": "Current value as hAPI filter string.", + "type": "string" }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -22868,85 +21878,27 @@ "type": "BooleanSelector" }, { - "name": "isBodyReady", - "type": "boolean" - }, - { - "name": "UpdateEvent", - "description": "Instances of this event are dispatched on an element whenever it changes its\nstate (e.g. when going from `busy` to `idle` or on `form` data change).\nThis event isn't cancelable, and it does not bubble.", - "type": "typeof UpdateEvent", - "default": "\"UpdateEvent\"" - }, - { - "name": "Rumour", - "description": "Creates a tagged [Rumour](https://sdk.foxy.dev/classes/_core_index_.rumour.html)\ninstance if it doesn't exist or returns cached one otherwise. NucleonElements\nuse empty Rumour group by default.", - "type": "((group: string) => Rumour) & MemoizedFunction", - "default": "\"memoize<(group: string) => Rumour>(() => new Rumour())\"" - }, - { - "name": "API", - "description": "Universal [API](https://sdk.foxy.dev/classes/_core_index_.api.html) client\nthat dispatches cancellable `FetchEvent` on an element before each request.", - "type": "typeof API", - "default": "\"API\"" + "name": "simplifyNsLoading", + "attribute": "simplify-ns-loading", + "type": "boolean", + "default": "false" }, { "name": "lang", "attribute": "lang", - "description": "Optional ISO 639-1 code describing the language element content is written in.\nChanging the `lang` attribute will update the value of this property.", "type": "string", "default": "\"\"" }, { - "name": "parent", - "attribute": "parent", - "description": "Optional URL of the collection this element's resource belongs to.\nChanging the `parent` attribute will update the value of this property.", + "name": "ns", + "attribute": "ns", "type": "string", - "default": "\"\"" - }, - { - "name": "related", - "attribute": "related", - "description": "Optional URI list of the related resources. If Rumour encounters a related\nresource on creation or deletion, it will be reloaded from source.", - "type": "array", - "default": "[]" - }, - { - "name": "virtualHost", - "attribute": "virtual-host", - "description": "Unique identifier for the virtual host used by the element to serve internal requests.\n\nCurrently only one endpoint is supported: `foxy:///form/`.\nThis endpoint supports POST, GET, PATCH and DELETE methods and functions like a hAPI server.\n\nFor example, `GET foxy://nucleon-123/form/subscriptions/allowNextDateModification/0` on a NucleonElement\nwith `fx:customer_portal_settings` will return the first item of the `subscriptions.allowNextDateModification` array.", - "default": "\"uniqueId('nucleon-')\"" - }, - { - "name": "failure", - "description": "If network request returns non-2XX code, the entire error response\nwill be available via this getter.\n\nThis property is readonly. Changing failure records via this property is\nnot guaranteed to work. NucleonElement does not provide a way to override error status.", - "type": "Response | null" - }, - { - "name": "errors", - "description": "Array of validation errors returned from `NucleonElement.v8n` checks.\n\nThis property is readonly. Adding or removing error codes via this property is\nnot guaranteed to work. NucleonElement does not provide a way to override validity status.", - "type": "string[]" - }, - { - "name": "form", - "description": "Resource snapshot with edits applied. Empty object if unavailable.\n\nThis property and its value are readonly. Assignments like `element.data.foo = 'bar'`\nare not guaranteed to work. Please use `element.edit({ foo: 'bar' })` instead.\nIf you need to replace the entire data object, consider using `element.data`.", - "type": "Partial" - }, - { - "name": "data", - "description": "Resource snapshot as-is, no edits applied. Null if unavailable.\n\nReturned value is not reactive. Assignments like `element.data.foo = 'bar'`\nare not guaranteed to work. Please set the property instead: `element.data = { ...element.data, foo: 'bar' }`.\nIf you're processing user input, consider using `element.form` and `element.edit()` instead.", - "type": "TData | null" - }, - { - "name": "group", - "attribute": "group", - "description": "Rumour group. Elements in different groups will not share updates. Empty by default.", - "type": "string" + "default": "\"defaultNS\"" }, { - "name": "href", - "attribute": "href", - "description": "Optional URL of the resource to load. Switches element to `idle.template` state if empty (default).", - "type": "string" + "name": "t", + "type": "Translator", + "default": "\"(key, options) => {\\n const I18nElement = customElements.get('foxy-i18n') as typeof I18n | undefined;\\n\\n if (!I18nElement) return key;\\n\\n let keys: string[];\\n\\n if (this.simplifyNsLoading) {\\n const namespaces = this.ns.split(' ').filter(v => v.length > 0);\\n const path = [...namespaces.slice(1), key].join('.');\\n keys = namespaces[0] ? [`${namespaces[0]}:${path}`] : [path];\\n } else {\\n keys = this.ns\\n .split(' ')\\n .reverse()\\n .map(v => v.trim())\\n .filter(v => v.length > 0)\\n .reverse()\\n .map((v, i, a) => `${v}:${[...a.slice(i + 1), key].join('.')}`);\\n }\\n\\n keys.push(key);\\n\\n return I18nElement.i18next.t(keys, { lng: this.lang, ...options }).toString();\\n }\"" }, { "name": "infer", @@ -22954,52 +21906,13 @@ "description": "Set a name for this element here to enable property inference. Set to `null` to disable.", "type": "string" } - ], - "events": [ - { - "name": "update", - "description": "Instance of `NucleonElement.UpdateEvent`. Dispatched on an element whenever it changes its state." - }, - { - "name": "fetch", - "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." - } - ], - "slots": [ - { - "name": "title:before" - }, - { - "name": "title:after" - }, - { - "name": "subtitle:before" - }, - { - "name": "subtitle:after" - } ] }, { - "name": "foxy-payments-api-payment-preset-form", - "path": "./src/elements/public/PaymentsApiPaymentPresetForm/index.ts", - "description": "Form element for the `fx:payment_preset` resource of Payments API.\n\n_Payments API is a client-side virtual API layer built on top of hAPI\nin an attempt to streamline access to stores' payment method settings\nthat is currently a bit quirky due to the legacy functionality. To use\nthis element with hAPI, wrap it into a foxy-payments-api node._", + "name": "foxy-report-form", + "path": "./src/elements/public/ReportForm/index.ts", + "description": "Form element for creating or editing reports (`fx:report`).", "attributes": [ - { - "name": "simplify-ns-loading", - "type": "boolean", - "default": "false" - }, - { - "name": "ns", - "type": "string", - "default": "\"defaultNS\"" - }, - { - "name": "status", - "description": "Status message to render at the top of the form. If `null`, the message is hidden.", - "type": "object" - }, { "name": "mode", "type": "string", @@ -23032,6 +21945,16 @@ "name": "hiddencontrols", "default": "\"False\"" }, + { + "name": "simplify-ns-loading", + "type": "boolean", + "default": "false" + }, + { + "name": "ns", + "type": "string", + "default": "\"defaultNS\"" + }, { "name": "lang", "description": "Optional ISO 639-1 code describing the language element content is written in.\nChanging the `lang` attribute will update the value of this property.", @@ -23072,47 +21995,8 @@ } ], "properties": [ - { - "name": "getFraudProtectionImageSrc", - "description": "A function that returns image URL for given fraud protection `type`." - }, - { - "name": "getPaymentMethodImageSrc", - "description": "A function that returns image URL for given payment method `type`." - }, - { - "name": "simplifyNsLoading", - "attribute": "simplify-ns-loading", - "type": "boolean", - "default": "false" - }, - { - "name": "ns", - "attribute": "ns", - "type": "string", - "default": "\"defaultNS\"" - }, - { - "name": "t", - "type": "Translator", - "default": "\"(key, options) => {\\n const I18nElement = customElements.get('foxy-i18n') as typeof I18n | undefined;\\n\\n if (!I18nElement) return key;\\n\\n let keys: string[];\\n\\n if (this.simplifyNsLoading) {\\n const namespaces = this.ns.split(' ').filter(v => v.length > 0);\\n const path = [...namespaces.slice(1), key].join('.');\\n keys = namespaces[0] ? [`${namespaces[0]}:${path}`] : [path];\\n } else {\\n keys = this.ns\\n .split(' ')\\n .reverse()\\n .map(v => v.trim())\\n .filter(v => v.length > 0)\\n .reverse()\\n .map((v, i, a) => `${v}:${[...a.slice(i + 1), key].join('.')}`);\\n }\\n\\n keys.push(key);\\n\\n return I18nElement.i18next.t(keys, { lng: this.lang, ...options }).toString();\\n }\"" - }, - { - "name": "generalErrorPrefix", - "description": "Validation errors with this prefix will show up at the top of the form.", - "type": "string", - "default": "\"error:\"" - }, - { - "name": "status", - "attribute": "status", - "description": "Status message to render at the top of the form. If `null`, the message is hidden.", - "type": "object" - }, { "name": "templates", - "description": "Template render functions mapped to their name.", - "type": "Templates", "default": "{}" }, { @@ -23166,6 +22050,23 @@ "name": "hiddenSelector", "type": "BooleanSelector" }, + { + "name": "simplifyNsLoading", + "attribute": "simplify-ns-loading", + "type": "boolean", + "default": "false" + }, + { + "name": "ns", + "attribute": "ns", + "type": "string", + "default": "\"defaultNS\"" + }, + { + "name": "t", + "type": "Translator", + "default": "\"(key, options) => {\\n const I18nElement = customElements.get('foxy-i18n') as typeof I18n | undefined;\\n\\n if (!I18nElement) return key;\\n\\n let keys: string[];\\n\\n if (this.simplifyNsLoading) {\\n const namespaces = this.ns.split(' ').filter(v => v.length > 0);\\n const path = [...namespaces.slice(1), key].join('.');\\n keys = namespaces[0] ? [`${namespaces[0]}:${path}`] : [path];\\n } else {\\n keys = this.ns\\n .split(' ')\\n .reverse()\\n .map(v => v.trim())\\n .filter(v => v.length > 0)\\n .reverse()\\n .map((v, i, a) => `${v}:${[...a.slice(i + 1), key].join('.')}`);\\n }\\n\\n keys.push(key);\\n\\n return I18nElement.i18next.t(keys, { lng: this.lang, ...options }).toString();\\n }\"" + }, { "name": "UpdateEvent", "description": "Instances of this event are dispatched on an element whenever it changes its\nstate (e.g. when going from `busy` to `idle` or on `form` data change).\nThis event isn't cancelable, and it does not bubble.", @@ -23258,86 +22159,14 @@ { "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." - } - ], - "slots": [ - { - "name": "description:before" - }, - { - "name": "description:after" - }, - { - "name": "is-live:before" - }, - { - "name": "is-live:after" - }, - { - "name": "is-purchase-order-enabled:before" - }, - { - "name": "is-purchase-order-enabled:after" - }, - { - "name": "payment-methods:before" - }, - { - "name": "payment-methods:after" - }, - { - "name": "fraud-protections:before" - }, - { - "name": "fraud-protections:after" - }, - { - "name": "timestamps:before" - }, - { - "name": "timestamps:after" - }, - { - "name": "create:before" - }, - { - "name": "create:after" - }, - { - "name": "delete:before" - }, - { - "name": "delete:after" - } - ] - }, - { - "name": "foxy-query-builder", - "path": "./src/elements/public/QueryBuilder/index.ts", - "description": "UI component for creating Foxy hAPI filters visually. Compatible with\nBackend API, Customer API or any other API using the same format as described\nin our [docs](https://api.foxy.io/docs/cheat-sheet).", - "attributes": [ - { - "name": "operators", - "description": "List of operators available in the builder UI.", - "type": "array", - "default": "\"Object.values(Operator)\"" - }, - { - "name": "disable-or", - "description": "If true, hides the UI for the \"OR\" operator in queries.", - "type": "boolean", - "default": "false" - }, - { - "name": "options", - "description": "Autocomplete suggestions.", - "type": "array" - }, - { - "name": "value", - "description": "Current value as hAPI filter string.", - "type": "string" - }, + } + ] + }, + { + "name": "foxy-reports-table", + "path": "./src/elements/public/ReportsTable/index.ts", + "description": "Configurable table element for 'fx:reports' collection.", + "attributes": [ { "name": "mode", "type": "string", @@ -23375,15 +22204,43 @@ "type": "boolean", "default": "false" }, + { + "name": "ns", + "type": "string", + "default": "\"defaultNS\"" + }, { "name": "lang", + "description": "Optional ISO 639-1 code describing the language element content is written in.\nChanging the `lang` attribute will update the value of this property.", "type": "string", "default": "\"\"" }, { - "name": "ns", + "name": "parent", + "description": "Optional URL of the collection this element's resource belongs to.\nChanging the `parent` attribute will update the value of this property.", "type": "string", - "default": "\"defaultNS\"" + "default": "\"\"" + }, + { + "name": "related", + "description": "Optional URI list of the related resources. If Rumour encounters a related\nresource on creation or deletion, it will be reloaded from source.", + "type": "array", + "default": "[]" + }, + { + "name": "virtual-host", + "description": "Unique identifier for the virtual host used by the element to serve internal requests.\n\nCurrently only one endpoint is supported: `foxy:///form/`.\nThis endpoint supports POST, GET, PATCH and DELETE methods and functions like a hAPI server.\n\nFor example, `GET foxy://nucleon-123/form/subscriptions/allowNextDateModification/0` on a NucleonElement\nwith `fx:customer_portal_settings` will return the first item of the `subscriptions.allowNextDateModification` array.", + "default": "\"uniqueId('nucleon-')\"" + }, + { + "name": "group", + "description": "Rumour group. Elements in different groups will not share updates. Empty by default.", + "type": "string" + }, + { + "name": "href", + "description": "Optional URL of the resource to load. Switches element to `idle.template` state if empty (default).", + "type": "string" }, { "name": "infer", @@ -23393,48 +22250,35 @@ ], "properties": [ { - "name": "ChangeEvent", - "description": "QueryBuilder dispatches this event on itself when value changes.", - "type": "typeof (Anonymous class)", - "default": "\"class extends CustomEvent {}\"" - }, - { - "name": "Operator", - "description": "Operator dictionary for use in autocomplete options.", - "type": "typeof Operator", - "default": "\"Operator\"" + "name": "nameColumn", + "type": "Column>", + "default": "{}" }, { - "name": "Type", - "description": "Field type dictionary for use in autocomplete options.", - "type": "typeof Type", - "default": "\"Type\"" + "name": "startColumn", + "type": "Column>", + "default": "{\"hideBelow\":\"md\"}" }, { - "name": "operators", - "attribute": "operators", - "description": "List of operators available in the builder UI.", - "type": "array", - "default": "\"Object.values(Operator)\"" + "name": "endColumn", + "type": "Column>", + "default": "{\"hideBelow\":\"md\"}" }, { - "name": "disableOr", - "attribute": "disable-or", - "description": "If true, hides the UI for the \"OR\" operator in queries.", - "type": "boolean", - "default": "false" + "name": "createdOnColumn", + "type": "Column>", + "default": "{}" }, { - "name": "options", - "attribute": "options", - "description": "Autocomplete suggestions.", - "type": "array" + "name": "linkColumn", + "type": "Column>", + "default": "{}" }, { - "name": "value", - "attribute": "value", - "description": "Current value as hAPI filter string.", - "type": "string" + "name": "columns", + "description": "Array of column templates. See `Column` type for more details.", + "type": "Column>[]", + "default": "[\"nameColumn\",\"startColumn\",\"endColumn\",\"createdOnColumn\",\"linkColumn\"]" }, { "name": "templates", @@ -23497,12 +22341,6 @@ "type": "boolean", "default": "false" }, - { - "name": "lang", - "attribute": "lang", - "type": "string", - "default": "\"\"" - }, { "name": "ns", "attribute": "ns", @@ -23515,156 +22353,155 @@ "default": "\"(key, options) => {\\n const I18nElement = customElements.get('foxy-i18n') as typeof I18n | undefined;\\n\\n if (!I18nElement) return key;\\n\\n let keys: string[];\\n\\n if (this.simplifyNsLoading) {\\n const namespaces = this.ns.split(' ').filter(v => v.length > 0);\\n const path = [...namespaces.slice(1), key].join('.');\\n keys = namespaces[0] ? [`${namespaces[0]}:${path}`] : [path];\\n } else {\\n keys = this.ns\\n .split(' ')\\n .reverse()\\n .map(v => v.trim())\\n .filter(v => v.length > 0)\\n .reverse()\\n .map((v, i, a) => `${v}:${[...a.slice(i + 1), key].join('.')}`);\\n }\\n\\n keys.push(key);\\n\\n return I18nElement.i18next.t(keys, { lng: this.lang, ...options }).toString();\\n }\"" }, { - "name": "infer", - "attribute": "infer", - "description": "Set a name for this element here to enable property inference. Set to `null` to disable.", - "type": "string" - } - ] - }, - { - "name": "foxy-report-form", - "path": "./src/elements/public/ReportForm/index.ts", - "description": "Form element for creating or editing reports (`fx:report`).", - "attributes": [ - { - "name": "mode", - "type": "string", - "default": "\"production\"" - }, - { - "name": "readonly", - "type": "boolean", - "default": "false" - }, - { - "name": "readonlycontrols", - "default": "\"False\"" - }, - { - "name": "disabled", - "type": "boolean", - "default": "false" - }, - { - "name": "disabledcontrols", - "default": "\"False\"" - }, - { - "name": "hidden", - "type": "boolean", - "default": "false" - }, - { - "name": "hiddencontrols", - "default": "\"False\"" + "name": "UpdateEvent", + "description": "Instances of this event are dispatched on an element whenever it changes its\nstate (e.g. when going from `busy` to `idle` or on `form` data change).\nThis event isn't cancelable, and it does not bubble.", + "type": "typeof UpdateEvent", + "default": "\"UpdateEvent\"" }, { - "name": "simplify-ns-loading", - "type": "boolean", - "default": "false" + "name": "Rumour", + "description": "Creates a tagged [Rumour](https://sdk.foxy.dev/classes/_core_index_.rumour.html)\ninstance if it doesn't exist or returns cached one otherwise. NucleonElements\nuse empty Rumour group by default.", + "type": "((group: string) => Rumour) & MemoizedFunction", + "default": "\"memoize<(group: string) => Rumour>(() => new Rumour())\"" }, { - "name": "ns", - "type": "string", - "default": "\"defaultNS\"" + "name": "API", + "description": "Universal [API](https://sdk.foxy.dev/classes/_core_index_.api.html) client\nthat dispatches cancellable `FetchEvent` on an element before each request.", + "type": "typeof API", + "default": "\"API\"" }, { "name": "lang", + "attribute": "lang", "description": "Optional ISO 639-1 code describing the language element content is written in.\nChanging the `lang` attribute will update the value of this property.", "type": "string", "default": "\"\"" }, { "name": "parent", + "attribute": "parent", "description": "Optional URL of the collection this element's resource belongs to.\nChanging the `parent` attribute will update the value of this property.", "type": "string", "default": "\"\"" }, { "name": "related", + "attribute": "related", "description": "Optional URI list of the related resources. If Rumour encounters a related\nresource on creation or deletion, it will be reloaded from source.", "type": "array", "default": "[]" }, { - "name": "virtual-host", + "name": "virtualHost", + "attribute": "virtual-host", "description": "Unique identifier for the virtual host used by the element to serve internal requests.\n\nCurrently only one endpoint is supported: `foxy:///form/`.\nThis endpoint supports POST, GET, PATCH and DELETE methods and functions like a hAPI server.\n\nFor example, `GET foxy://nucleon-123/form/subscriptions/allowNextDateModification/0` on a NucleonElement\nwith `fx:customer_portal_settings` will return the first item of the `subscriptions.allowNextDateModification` array.", "default": "\"uniqueId('nucleon-')\"" }, + { + "name": "failure", + "description": "If network request returns non-2XX code, the entire error response\nwill be available via this getter.\n\nThis property is readonly. Changing failure records via this property is\nnot guaranteed to work. NucleonElement does not provide a way to override error status.", + "type": "Response | null" + }, + { + "name": "errors", + "description": "Array of validation errors returned from `NucleonElement.v8n` checks.\n\nThis property is readonly. Adding or removing error codes via this property is\nnot guaranteed to work. NucleonElement does not provide a way to override validity status.", + "type": "string[]" + }, + { + "name": "form", + "description": "Resource snapshot with edits applied. Empty object if unavailable.\n\nThis property and its value are readonly. Assignments like `element.data.foo = 'bar'`\nare not guaranteed to work. Please use `element.edit({ foo: 'bar' })` instead.\nIf you need to replace the entire data object, consider using `element.data`.", + "type": "Partial" + }, + { + "name": "data", + "description": "Resource snapshot as-is, no edits applied. Null if unavailable.\n\nReturned value is not reactive. Assignments like `element.data.foo = 'bar'`\nare not guaranteed to work. Please set the property instead: `element.data = { ...element.data, foo: 'bar' }`.\nIf you're processing user input, consider using `element.form` and `element.edit()` instead.", + "type": "TData | null" + }, { "name": "group", + "attribute": "group", "description": "Rumour group. Elements in different groups will not share updates. Empty by default.", "type": "string" }, { "name": "href", + "attribute": "href", "description": "Optional URL of the resource to load. Switches element to `idle.template` state if empty (default).", "type": "string" }, { "name": "infer", + "attribute": "infer", "description": "Set a name for this element here to enable property inference. Set to `null` to disable.", "type": "string" } ], - "properties": [ + "events": [ { - "name": "templates", - "type": "Templates", - "default": "{}" + "name": "update", + "description": "Instance of `NucleonElement.UpdateEvent`. Dispatched on an element whenever it changes its state." }, { - "name": "mode", - "attribute": "mode", - "type": "string", - "default": "\"production\"" - }, + "name": "fetch", + "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." + } + ] + }, + { + "name": "foxy-shipment-card", + "path": "./src/elements/public/ShipmentCard/index.ts", + "description": "Basic card displaying a shipment (`fx:shipment`).", + "attributes": [ { - "name": "readonly", - "attribute": "readonly", + "name": "simplify-ns-loading", "type": "boolean", "default": "false" }, { - "name": "readonlyControls", - "attribute": "readonlycontrols", - "default": "\"False\"" + "name": "ns", + "type": "string", + "default": "\"defaultNS\"" }, { - "name": "disabled", - "attribute": "disabled", - "type": "boolean", - "default": "false" + "name": "lang", + "description": "Optional ISO 639-1 code describing the language element content is written in.\nChanging the `lang` attribute will update the value of this property.", + "type": "string", + "default": "\"\"" }, { - "name": "disabledControls", - "attribute": "disabledcontrols", - "default": "\"False\"" + "name": "parent", + "description": "Optional URL of the collection this element's resource belongs to.\nChanging the `parent` attribute will update the value of this property.", + "type": "string", + "default": "\"\"" }, { - "name": "hidden", - "attribute": "hidden", - "type": "boolean", - "default": "false" + "name": "related", + "description": "Optional URI list of the related resources. If Rumour encounters a related\nresource on creation or deletion, it will be reloaded from source.", + "type": "array", + "default": "[]" }, { - "name": "hiddenControls", - "attribute": "hiddencontrols", - "default": "\"False\"" + "name": "virtual-host", + "description": "Unique identifier for the virtual host used by the element to serve internal requests.\n\nCurrently only one endpoint is supported: `foxy:///form/`.\nThis endpoint supports POST, GET, PATCH and DELETE methods and functions like a hAPI server.\n\nFor example, `GET foxy://nucleon-123/form/subscriptions/allowNextDateModification/0` on a NucleonElement\nwith `fx:customer_portal_settings` will return the first item of the `subscriptions.allowNextDateModification` array.", + "default": "\"uniqueId('nucleon-')\"" }, { - "name": "readonlySelector", - "type": "BooleanSelector" + "name": "group", + "description": "Rumour group. Elements in different groups will not share updates. Empty by default.", + "type": "string" }, { - "name": "disabledSelector", - "type": "BooleanSelector" + "name": "href", + "description": "Optional URL of the resource to load. Switches element to `idle.template` state if empty (default).", + "type": "string" }, { - "name": "hiddenSelector", - "type": "BooleanSelector" - }, + "name": "infer", + "description": "Set a name for this element here to enable property inference. Set to `null` to disable.", + "type": "string" + } + ], + "properties": [ { "name": "simplifyNsLoading", "attribute": "simplify-ns-loading", @@ -23682,6 +22519,10 @@ "type": "Translator", "default": "\"(key, options) => {\\n const I18nElement = customElements.get('foxy-i18n') as typeof I18n | undefined;\\n\\n if (!I18nElement) return key;\\n\\n let keys: string[];\\n\\n if (this.simplifyNsLoading) {\\n const namespaces = this.ns.split(' ').filter(v => v.length > 0);\\n const path = [...namespaces.slice(1), key].join('.');\\n keys = namespaces[0] ? [`${namespaces[0]}:${path}`] : [path];\\n } else {\\n keys = this.ns\\n .split(' ')\\n .reverse()\\n .map(v => v.trim())\\n .filter(v => v.length > 0)\\n .reverse()\\n .map((v, i, a) => `${v}:${[...a.slice(i + 1), key].join('.')}`);\\n }\\n\\n keys.push(key);\\n\\n return I18nElement.i18next.t(keys, { lng: this.lang, ...options }).toString();\\n }\"" }, + { + "name": "isBodyReady", + "type": "boolean" + }, { "name": "UpdateEvent", "description": "Instances of this event are dispatched on an element whenever it changes its\nstate (e.g. when going from `busy` to `idle` or on `form` data change).\nThis event isn't cancelable, and it does not bubble.", @@ -23775,45 +22616,23 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "name:before" - }, - { - "name": "name:after" - }, - { - "name": "range:before" - }, - { - "name": "range:after" - }, - { - "name": "timestamps:before" - }, - { - "name": "timestamps:after" - }, - { - "name": "delete:before" - }, - { - "name": "delete:after" - }, - { - "name": "create:before" - }, - { - "name": "create:after" - } ] }, { - "name": "foxy-reports-table", - "path": "./src/elements/public/ReportsTable/index.ts", - "description": "Configurable table element for 'fx:reports' collection.", + "name": "foxy-shipping-container-card", + "path": "./src/elements/public/ShippingContainerCard/index.ts", + "description": "Basic card displaying a shipping container (`fx:shipping_container`).", "attributes": [ + { + "name": "simplify-ns-loading", + "type": "boolean", + "default": "false" + }, + { + "name": "ns", + "type": "string", + "default": "\"defaultNS\"" + }, { "name": "mode", "type": "string", @@ -23846,16 +22665,6 @@ "name": "hiddencontrols", "default": "\"False\"" }, - { - "name": "simplify-ns-loading", - "type": "boolean", - "default": "false" - }, - { - "name": "ns", - "type": "string", - "default": "\"defaultNS\"" - }, { "name": "lang", "description": "Optional ISO 639-1 code describing the language element content is written in.\nChanging the `lang` attribute will update the value of this property.", @@ -23897,39 +22706,24 @@ ], "properties": [ { - "name": "nameColumn", - "type": "Column>", - "default": "{}" - }, - { - "name": "startColumn", - "type": "Column>", - "default": "{\"hideBelow\":\"md\"}" - }, - { - "name": "endColumn", - "type": "Column>", - "default": "{\"hideBelow\":\"md\"}" - }, - { - "name": "createdOnColumn", - "type": "Column>", - "default": "{}" + "name": "simplifyNsLoading", + "attribute": "simplify-ns-loading", + "type": "boolean", + "default": "false" }, { - "name": "linkColumn", - "type": "Column>", - "default": "{}" + "name": "ns", + "attribute": "ns", + "type": "string", + "default": "\"defaultNS\"" }, { - "name": "columns", - "description": "Array of column templates. See `Column` type for more details.", - "type": "Column>[]", - "default": "[\"nameColumn\",\"startColumn\",\"endColumn\",\"createdOnColumn\",\"linkColumn\"]" + "name": "t", + "type": "Translator", + "default": "\"(key, options) => {\\n const I18nElement = customElements.get('foxy-i18n') as typeof I18n | undefined;\\n\\n if (!I18nElement) return key;\\n\\n let keys: string[];\\n\\n if (this.simplifyNsLoading) {\\n const namespaces = this.ns.split(' ').filter(v => v.length > 0);\\n const path = [...namespaces.slice(1), key].join('.');\\n keys = namespaces[0] ? [`${namespaces[0]}:${path}`] : [path];\\n } else {\\n keys = this.ns\\n .split(' ')\\n .reverse()\\n .map(v => v.trim())\\n .filter(v => v.length > 0)\\n .reverse()\\n .map((v, i, a) => `${v}:${[...a.slice(i + 1), key].join('.')}`);\\n }\\n\\n keys.push(key);\\n\\n return I18nElement.i18next.t(keys, { lng: this.lang, ...options }).toString();\\n }\"" }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -23984,21 +22778,8 @@ "type": "BooleanSelector" }, { - "name": "simplifyNsLoading", - "attribute": "simplify-ns-loading", - "type": "boolean", - "default": "false" - }, - { - "name": "ns", - "attribute": "ns", - "type": "string", - "default": "\"defaultNS\"" - }, - { - "name": "t", - "type": "Translator", - "default": "\"(key, options) => {\\n const I18nElement = customElements.get('foxy-i18n') as typeof I18n | undefined;\\n\\n if (!I18nElement) return key;\\n\\n let keys: string[];\\n\\n if (this.simplifyNsLoading) {\\n const namespaces = this.ns.split(' ').filter(v => v.length > 0);\\n const path = [...namespaces.slice(1), key].join('.');\\n keys = namespaces[0] ? [`${namespaces[0]}:${path}`] : [path];\\n } else {\\n keys = this.ns\\n .split(' ')\\n .reverse()\\n .map(v => v.trim())\\n .filter(v => v.length > 0)\\n .reverse()\\n .map((v, i, a) => `${v}:${[...a.slice(i + 1), key].join('.')}`);\\n }\\n\\n keys.push(key);\\n\\n return I18nElement.i18next.t(keys, { lng: this.lang, ...options }).toString();\\n }\"" + "name": "isBodyReady", + "type": "boolean" }, { "name": "UpdateEvent", @@ -24096,9 +22877,9 @@ ] }, { - "name": "foxy-shipment-card", - "path": "./src/elements/public/ShipmentCard/index.ts", - "description": "Basic card displaying a shipment (`fx:shipment`).", + "name": "foxy-shipping-drop-type-card", + "path": "./src/elements/public/ShippingDropTypeCard/index.ts", + "description": "Basic card displaying a shipping drop type (`fx:shipping_drop_type`).", "attributes": [ { "name": "simplify-ns-loading", @@ -24110,6 +22891,38 @@ "type": "string", "default": "\"defaultNS\"" }, + { + "name": "mode", + "type": "string", + "default": "\"production\"" + }, + { + "name": "readonly", + "type": "boolean", + "default": "false" + }, + { + "name": "readonlycontrols", + "default": "\"False\"" + }, + { + "name": "disabled", + "type": "boolean", + "default": "false" + }, + { + "name": "disabledcontrols", + "default": "\"False\"" + }, + { + "name": "hidden", + "type": "boolean", + "default": "false" + }, + { + "name": "hiddencontrols", + "default": "\"False\"" + }, { "name": "lang", "description": "Optional ISO 639-1 code describing the language element content is written in.\nChanging the `lang` attribute will update the value of this property.", @@ -24167,6 +22980,61 @@ "type": "Translator", "default": "\"(key, options) => {\\n const I18nElement = customElements.get('foxy-i18n') as typeof I18n | undefined;\\n\\n if (!I18nElement) return key;\\n\\n let keys: string[];\\n\\n if (this.simplifyNsLoading) {\\n const namespaces = this.ns.split(' ').filter(v => v.length > 0);\\n const path = [...namespaces.slice(1), key].join('.');\\n keys = namespaces[0] ? [`${namespaces[0]}:${path}`] : [path];\\n } else {\\n keys = this.ns\\n .split(' ')\\n .reverse()\\n .map(v => v.trim())\\n .filter(v => v.length > 0)\\n .reverse()\\n .map((v, i, a) => `${v}:${[...a.slice(i + 1), key].join('.')}`);\\n }\\n\\n keys.push(key);\\n\\n return I18nElement.i18next.t(keys, { lng: this.lang, ...options }).toString();\\n }\"" }, + { + "name": "templates", + "default": "{}" + }, + { + "name": "mode", + "attribute": "mode", + "type": "string", + "default": "\"production\"" + }, + { + "name": "readonly", + "attribute": "readonly", + "type": "boolean", + "default": "false" + }, + { + "name": "readonlyControls", + "attribute": "readonlycontrols", + "default": "\"False\"" + }, + { + "name": "disabled", + "attribute": "disabled", + "type": "boolean", + "default": "false" + }, + { + "name": "disabledControls", + "attribute": "disabledcontrols", + "default": "\"False\"" + }, + { + "name": "hidden", + "attribute": "hidden", + "type": "boolean", + "default": "false" + }, + { + "name": "hiddenControls", + "attribute": "hiddencontrols", + "default": "\"False\"" + }, + { + "name": "readonlySelector", + "type": "BooleanSelector" + }, + { + "name": "disabledSelector", + "type": "BooleanSelector" + }, + { + "name": "hiddenSelector", + "type": "BooleanSelector" + }, { "name": "isBodyReady", "type": "boolean" @@ -24451,14 +23319,19 @@ ] }, { - "name": "foxy-sign-in-form", - "path": "./src/elements/public/SignInForm/index.ts", - "description": "Form element for email/password sign in.", + "name": "foxy-shipping-service-card", + "path": "./src/elements/public/ShippingServiceCard/index.ts", + "description": "Basic card displaying a shipping service (`fx:shipping_service`).", "attributes": [ { - "name": "issuer", + "name": "simplify-ns-loading", + "type": "boolean", + "default": "false" + }, + { + "name": "ns", "type": "string", - "default": "\"Unknown\"" + "default": "\"defaultNS\"" }, { "name": "mode", @@ -24492,16 +23365,6 @@ "name": "hiddencontrols", "default": "\"False\"" }, - { - "name": "simplify-ns-loading", - "type": "boolean", - "default": "false" - }, - { - "name": "ns", - "type": "string", - "default": "\"defaultNS\"" - }, { "name": "lang", "description": "Optional ISO 639-1 code describing the language element content is written in.\nChanging the `lang` attribute will update the value of this property.", @@ -24543,14 +23406,24 @@ ], "properties": [ { - "name": "issuer", - "attribute": "issuer", + "name": "simplifyNsLoading", + "attribute": "simplify-ns-loading", + "type": "boolean", + "default": "false" + }, + { + "name": "ns", + "attribute": "ns", "type": "string", - "default": "\"Unknown\"" + "default": "\"defaultNS\"" + }, + { + "name": "t", + "type": "Translator", + "default": "\"(key, options) => {\\n const I18nElement = customElements.get('foxy-i18n') as typeof I18n | undefined;\\n\\n if (!I18nElement) return key;\\n\\n let keys: string[];\\n\\n if (this.simplifyNsLoading) {\\n const namespaces = this.ns.split(' ').filter(v => v.length > 0);\\n const path = [...namespaces.slice(1), key].join('.');\\n keys = namespaces[0] ? [`${namespaces[0]}:${path}`] : [path];\\n } else {\\n keys = this.ns\\n .split(' ')\\n .reverse()\\n .map(v => v.trim())\\n .filter(v => v.length > 0)\\n .reverse()\\n .map((v, i, a) => `${v}:${[...a.slice(i + 1), key].join('.')}`);\\n }\\n\\n keys.push(key);\\n\\n return I18nElement.i18next.t(keys, { lng: this.lang, ...options }).toString();\\n }\"" }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -24604,22 +23477,9 @@ "name": "hiddenSelector", "type": "BooleanSelector" }, - { - "name": "simplifyNsLoading", - "attribute": "simplify-ns-loading", - "type": "boolean", - "default": "false" - }, - { - "name": "ns", - "attribute": "ns", - "type": "string", - "default": "\"defaultNS\"" - }, - { - "name": "t", - "type": "Translator", - "default": "\"(key, options) => {\\n const I18nElement = customElements.get('foxy-i18n') as typeof I18n | undefined;\\n\\n if (!I18nElement) return key;\\n\\n let keys: string[];\\n\\n if (this.simplifyNsLoading) {\\n const namespaces = this.ns.split(' ').filter(v => v.length > 0);\\n const path = [...namespaces.slice(1), key].join('.');\\n keys = namespaces[0] ? [`${namespaces[0]}:${path}`] : [path];\\n } else {\\n keys = this.ns\\n .split(' ')\\n .reverse()\\n .map(v => v.trim())\\n .filter(v => v.length > 0)\\n .reverse()\\n .map((v, i, a) => `${v}:${[...a.slice(i + 1), key].join('.')}`);\\n }\\n\\n keys.push(key);\\n\\n return I18nElement.i18next.t(keys, { lng: this.lang, ...options }).toString();\\n }\"" + { + "name": "isBodyReady", + "type": "boolean" }, { "name": "UpdateEvent", @@ -24714,159 +23574,17 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "email:before" - }, - { - "name": "email:after" - }, - { - "name": "password:before" - }, - { - "name": "password:after" - }, - { - "name": "new-password:before" - }, - { - "name": "new-password:after" - }, - { - "name": "mfa-secret-code:before" - }, - { - "name": "mfa-secret-code:after" - }, - { - "name": "mfa-totp-code:before" - }, - { - "name": "mfa-totp-code:after" - }, - { - "name": "mfa-remember-device:before" - }, - { - "name": "mfa-remember-device:after" - }, - { - "name": "error:before" - }, - { - "name": "error:after" - }, - { - "name": "submit:before" - }, - { - "name": "submit:after" - } - ] - }, - { - "name": "foxy-spinner", - "path": "./src/elements/public/Spinner/index.ts", - "attributes": [ - { - "name": "layout", - "description": "Optional spinner layout: horizonal (default) or vertical. First puts icon next\nto the label, second puts it above the text.", - "type": "string", - "default": "\"horizontal\"" - }, - { - "name": "state", - "description": "Optional spinner state:\n\n- `busy` (default) for loading data;\n- `error` for failures;\n- `empty` for when there's no data;\n- `paused` for a pause or a timeout before fetching the next chunk of data;\n- `end` for when there's no more data;", - "type": "string", - "default": "\"busy\"" - }, - { - "name": "simplify-ns-loading", - "type": "boolean", - "default": "false" - }, - { - "name": "lang", - "type": "string", - "default": "\"\"" - }, - { - "name": "ns", - "type": "string", - "default": "\"defaultNS\"" - }, - { - "name": "infer", - "description": "Set a name for this element here to enable property inference. Set to `null` to disable.", - "type": "string" - } - ], - "properties": [ - { - "name": "layout", - "attribute": "layout", - "description": "Optional spinner layout: horizonal (default) or vertical. First puts icon next\nto the label, second puts it above the text.", - "type": "string", - "default": "\"horizontal\"" - }, - { - "name": "state", - "attribute": "state", - "description": "Optional spinner state:\n\n- `busy` (default) for loading data;\n- `error` for failures;\n- `empty` for when there's no data;\n- `paused` for a pause or a timeout before fetching the next chunk of data;\n- `end` for when there's no more data;", - "type": "string", - "default": "\"busy\"" - }, - { - "name": "simplifyNsLoading", - "attribute": "simplify-ns-loading", - "type": "boolean", - "default": "false" - }, - { - "name": "lang", - "attribute": "lang", - "type": "string", - "default": "\"\"" - }, - { - "name": "ns", - "attribute": "ns", - "type": "string", - "default": "\"defaultNS\"" - }, - { - "name": "t", - "type": "Translator", - "default": "\"(key, options) => {\\n const I18nElement = customElements.get('foxy-i18n') as typeof I18n | undefined;\\n\\n if (!I18nElement) return key;\\n\\n let keys: string[];\\n\\n if (this.simplifyNsLoading) {\\n const namespaces = this.ns.split(' ').filter(v => v.length > 0);\\n const path = [...namespaces.slice(1), key].join('.');\\n keys = namespaces[0] ? [`${namespaces[0]}:${path}`] : [path];\\n } else {\\n keys = this.ns\\n .split(' ')\\n .reverse()\\n .map(v => v.trim())\\n .filter(v => v.length > 0)\\n .reverse()\\n .map((v, i, a) => `${v}:${[...a.slice(i + 1), key].join('.')}`);\\n }\\n\\n keys.push(key);\\n\\n return I18nElement.i18next.t(keys, { lng: this.lang, ...options }).toString();\\n }\"" - }, - { - "name": "infer", - "attribute": "infer", - "description": "Set a name for this element here to enable property inference. Set to `null` to disable.", - "type": "string" - } ] }, { - "name": "foxy-store-card", - "path": "./src/elements/public/StoreCard/index.ts", - "description": "Card element representing a `fx:store` resource.", + "name": "foxy-sign-in-form", + "path": "./src/elements/public/SignInForm/index.ts", + "description": "Form element for email/password sign in.", "attributes": [ { - "name": "default-domain", - "description": "Default host domain for stores that don't use a custom domain name, e.g. `foxycart.com`." - }, - { - "name": "simplify-ns-loading", - "type": "boolean", - "default": "false" - }, - { - "name": "ns", + "name": "issuer", "type": "string", - "default": "\"defaultNS\"" + "default": "\"Unknown\"" }, { "name": "mode", @@ -24900,6 +23618,16 @@ "name": "hiddencontrols", "default": "\"False\"" }, + { + "name": "simplify-ns-loading", + "type": "boolean", + "default": "false" + }, + { + "name": "ns", + "type": "string", + "default": "\"defaultNS\"" + }, { "name": "lang", "description": "Optional ISO 639-1 code describing the language element content is written in.\nChanging the `lang` attribute will update the value of this property.", @@ -24941,30 +23669,13 @@ ], "properties": [ { - "name": "defaultDomain", - "attribute": "default-domain", - "description": "Default host domain for stores that don't use a custom domain name, e.g. `foxycart.com`." - }, - { - "name": "simplifyNsLoading", - "attribute": "simplify-ns-loading", - "type": "boolean", - "default": "false" - }, - { - "name": "ns", - "attribute": "ns", + "name": "issuer", + "attribute": "issuer", "type": "string", - "default": "\"defaultNS\"" - }, - { - "name": "t", - "type": "Translator", - "default": "\"(key, options) => {\\n const I18nElement = customElements.get('foxy-i18n') as typeof I18n | undefined;\\n\\n if (!I18nElement) return key;\\n\\n let keys: string[];\\n\\n if (this.simplifyNsLoading) {\\n const namespaces = this.ns.split(' ').filter(v => v.length > 0);\\n const path = [...namespaces.slice(1), key].join('.');\\n keys = namespaces[0] ? [`${namespaces[0]}:${path}`] : [path];\\n } else {\\n keys = this.ns\\n .split(' ')\\n .reverse()\\n .map(v => v.trim())\\n .filter(v => v.length > 0)\\n .reverse()\\n .map((v, i, a) => `${v}:${[...a.slice(i + 1), key].join('.')}`);\\n }\\n\\n keys.push(key);\\n\\n return I18nElement.i18next.t(keys, { lng: this.lang, ...options }).toString();\\n }\"" + "default": "\"Unknown\"" }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -25019,8 +23730,21 @@ "type": "BooleanSelector" }, { - "name": "isBodyReady", - "type": "boolean" + "name": "simplifyNsLoading", + "attribute": "simplify-ns-loading", + "type": "boolean", + "default": "false" + }, + { + "name": "ns", + "attribute": "ns", + "type": "string", + "default": "\"defaultNS\"" + }, + { + "name": "t", + "type": "Translator", + "default": "\"(key, options) => {\\n const I18nElement = customElements.get('foxy-i18n') as typeof I18n | undefined;\\n\\n if (!I18nElement) return key;\\n\\n let keys: string[];\\n\\n if (this.simplifyNsLoading) {\\n const namespaces = this.ns.split(' ').filter(v => v.length > 0);\\n const path = [...namespaces.slice(1), key].join('.');\\n keys = namespaces[0] ? [`${namespaces[0]}:${path}`] : [path];\\n } else {\\n keys = this.ns\\n .split(' ')\\n .reverse()\\n .map(v => v.trim())\\n .filter(v => v.length > 0)\\n .reverse()\\n .map((v, i, a) => `${v}:${[...a.slice(i + 1), key].join('.')}`);\\n }\\n\\n keys.push(key);\\n\\n return I18nElement.i18next.t(keys, { lng: this.lang, ...options }).toString();\\n }\"" }, { "name": "UpdateEvent", @@ -25115,62 +23839,99 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ + ] + }, + { + "name": "foxy-spinner", + "path": "./src/elements/public/Spinner/index.ts", + "attributes": [ { - "name": "title:before" + "name": "layout", + "description": "Optional spinner layout: horizonal (default) or vertical. First puts icon next\nto the label, second puts it above the text.", + "type": "string", + "default": "\"horizontal\"" }, { - "name": "title:after" + "name": "state", + "description": "Optional spinner state:\n\n- `busy` (default) for loading data;\n- `error` for failures;\n- `empty` for when there's no data;\n- `paused` for a pause or a timeout before fetching the next chunk of data;\n- `end` for when there's no more data;", + "type": "string", + "default": "\"busy\"" }, { - "name": "subtitle:before" + "name": "simplify-ns-loading", + "type": "boolean", + "default": "false" }, { - "name": "subtitle:after" - } - ] - }, - { - "name": "foxy-store-form", - "path": "./src/elements/public/StoreForm/index.ts", - "description": "Form element for store settings (`fx:store`).", - "attributes": [ + "name": "lang", + "type": "string", + "default": "\"\"" + }, { - "name": "customer-password-hash-types", - "description": "URL of the `fx:customer_password_hash_types` property helper resource." + "name": "ns", + "type": "string", + "default": "\"defaultNS\"" }, { - "name": "shipping-address-types", - "description": "URL of the `fx:shipping_address_types` property helper resource." + "name": "infer", + "description": "Set a name for this element here to enable property inference. Set to `null` to disable.", + "type": "string" + } + ], + "properties": [ + { + "name": "layout", + "attribute": "layout", + "description": "Optional spinner layout: horizonal (default) or vertical. First puts icon next\nto the label, second puts it above the text.", + "type": "string", + "default": "\"horizontal\"" }, { - "name": "store-versions", - "description": "URL of the `fx:store_versions` property helper resource." + "name": "state", + "attribute": "state", + "description": "Optional spinner state:\n\n- `busy` (default) for loading data;\n- `error` for failures;\n- `empty` for when there's no data;\n- `paused` for a pause or a timeout before fetching the next chunk of data;\n- `end` for when there's no more data;", + "type": "string", + "default": "\"busy\"" }, { - "name": "checkout-types", - "description": "URL of the `fx:checkout_types` property helper resource." + "name": "simplifyNsLoading", + "attribute": "simplify-ns-loading", + "type": "boolean", + "default": "false" }, { - "name": "locale-codes", - "description": "URL of the `fx:locale_codes` property helper resource." + "name": "lang", + "attribute": "lang", + "type": "string", + "default": "\"\"" }, { - "name": "languages", - "description": "URL of the `fx:languages` property helper resource." + "name": "ns", + "attribute": "ns", + "type": "string", + "default": "\"defaultNS\"" }, { - "name": "timezones", - "description": "URL of the `fx:timezones` property helper resource." + "name": "t", + "type": "Translator", + "default": "\"(key, options) => {\\n const I18nElement = customElements.get('foxy-i18n') as typeof I18n | undefined;\\n\\n if (!I18nElement) return key;\\n\\n let keys: string[];\\n\\n if (this.simplifyNsLoading) {\\n const namespaces = this.ns.split(' ').filter(v => v.length > 0);\\n const path = [...namespaces.slice(1), key].join('.');\\n keys = namespaces[0] ? [`${namespaces[0]}:${path}`] : [path];\\n } else {\\n keys = this.ns\\n .split(' ')\\n .reverse()\\n .map(v => v.trim())\\n .filter(v => v.length > 0)\\n .reverse()\\n .map((v, i, a) => `${v}:${[...a.slice(i + 1), key].join('.')}`);\\n }\\n\\n keys.push(key);\\n\\n return I18nElement.i18next.t(keys, { lng: this.lang, ...options }).toString();\\n }\"" }, { - "name": "countries", - "description": "URL of the `fx:countries` property helper resource." - }, + "name": "infer", + "attribute": "infer", + "description": "Set a name for this element here to enable property inference. Set to `null` to disable.", + "type": "string" + } + ] + }, + { + "name": "foxy-store-card", + "path": "./src/elements/public/StoreCard/index.ts", + "description": "Card element representing a `fx:store` resource.", + "attributes": [ { - "name": "regions", - "description": "URL of the `fx:regions` property helper resource." + "name": "default-domain", + "description": "Default host domain for stores that don't use a custom domain name, e.g. `foxycart.com`." }, { "name": "simplify-ns-loading", @@ -25182,11 +23943,6 @@ "type": "string", "default": "\"defaultNS\"" }, - { - "name": "status", - "description": "Status message to render at the top of the form. If `null`, the message is hidden.", - "type": "object" - }, { "name": "mode", "type": "string", @@ -25260,49 +24016,9 @@ ], "properties": [ { - "name": "customerPasswordHashTypes", - "attribute": "customer-password-hash-types", - "description": "URL of the `fx:customer_password_hash_types` property helper resource." - }, - { - "name": "shippingAddressTypes", - "attribute": "shipping-address-types", - "description": "URL of the `fx:shipping_address_types` property helper resource." - }, - { - "name": "storeVersions", - "attribute": "store-versions", - "description": "URL of the `fx:store_versions` property helper resource." - }, - { - "name": "checkoutTypes", - "attribute": "checkout-types", - "description": "URL of the `fx:checkout_types` property helper resource." - }, - { - "name": "localeCodes", - "attribute": "locale-codes", - "description": "URL of the `fx:locale_codes` property helper resource." - }, - { - "name": "languages", - "attribute": "languages", - "description": "URL of the `fx:languages` property helper resource." - }, - { - "name": "timezones", - "attribute": "timezones", - "description": "URL of the `fx:timezones` property helper resource." - }, - { - "name": "countries", - "attribute": "countries", - "description": "URL of the `fx:countries` property helper resource." - }, - { - "name": "regions", - "attribute": "regions", - "description": "URL of the `fx:regions` property helper resource." + "name": "defaultDomain", + "attribute": "default-domain", + "description": "Default host domain for stores that don't use a custom domain name, e.g. `foxycart.com`." }, { "name": "simplifyNsLoading", @@ -25321,22 +24037,8 @@ "type": "Translator", "default": "\"(key, options) => {\\n const I18nElement = customElements.get('foxy-i18n') as typeof I18n | undefined;\\n\\n if (!I18nElement) return key;\\n\\n let keys: string[];\\n\\n if (this.simplifyNsLoading) {\\n const namespaces = this.ns.split(' ').filter(v => v.length > 0);\\n const path = [...namespaces.slice(1), key].join('.');\\n keys = namespaces[0] ? [`${namespaces[0]}:${path}`] : [path];\\n } else {\\n keys = this.ns\\n .split(' ')\\n .reverse()\\n .map(v => v.trim())\\n .filter(v => v.length > 0)\\n .reverse()\\n .map((v, i, a) => `${v}:${[...a.slice(i + 1), key].join('.')}`);\\n }\\n\\n keys.push(key);\\n\\n return I18nElement.i18next.t(keys, { lng: this.lang, ...options }).toString();\\n }\"" }, - { - "name": "generalErrorPrefix", - "description": "Validation errors with this prefix will show up at the top of the form.", - "type": "string", - "default": "\"error:\"" - }, - { - "name": "status", - "attribute": "status", - "description": "Status message to render at the top of the form. If `null`, the message is hidden.", - "type": "object" - }, { "name": "templates", - "description": "Template render functions mapped to their name.", - "type": "Templates", "default": "{}" }, { @@ -25390,6 +24092,10 @@ "name": "hiddenSelector", "type": "BooleanSelector" }, + { + "name": "isBodyReady", + "type": "boolean" + }, { "name": "UpdateEvent", "description": "Instances of this event are dispatched on an element whenever it changes its\nstate (e.g. when going from `busy` to `idle` or on `form` data change).\nThis event isn't cancelable, and it does not bubble.", @@ -25483,277 +24189,382 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "store-name:before" - }, - { - "name": "store-name:after" - }, - { - "name": "logo-url:before" - }, - { - "name": "logo-url:after" - }, - { - "name": "store-domain:before" - }, - { - "name": "store-domain:after" - }, - { - "name": "store-url:before" - }, - { - "name": "store-url:after" - }, - { - "name": "store-email:before" - }, - { - "name": "store-email:after" - }, - { - "name": "timezone:before" - }, - { - "name": "timezone:after" - }, - { - "name": "store-version-uri:before" - }, - { - "name": "store-version-uri:after" - }, - { - "name": "from-email:before" - }, - { - "name": "from-email:after" - }, - { - "name": "bcc-on-receipt-email:before" - }, - { - "name": "bcc-on-receipt-email:after" - }, + ] + }, + { + "name": "foxy-store-form", + "path": "./src/elements/public/StoreForm/index.ts", + "description": "Form element for store settings (`fx:store`).", + "attributes": [ { - "name": "use-email-dns:before" + "name": "customer-password-hash-types", + "description": "URL of the `fx:customer_password_hash_types` property helper resource." }, { - "name": "use-email-dns:after" + "name": "shipping-address-types", + "description": "URL of the `fx:shipping_address_types` property helper resource." }, { - "name": "use-smtp-config:before" + "name": "store-versions", + "description": "URL of the `fx:store_versions` property helper resource." }, { - "name": "use-smtp-config:after" + "name": "checkout-types", + "description": "URL of the `fx:checkout_types` property helper resource." }, { - "name": "smtp-config:before" + "name": "locale-codes", + "description": "URL of the `fx:locale_codes` property helper resource." }, { - "name": "smtp-config:after" + "name": "languages", + "description": "URL of the `fx:languages` property helper resource." }, { - "name": "smtp-config-host:before" + "name": "timezones", + "description": "URL of the `fx:timezones` property helper resource." }, { - "name": "smtp-config-host:after" + "name": "countries", + "description": "URL of the `fx:countries` property helper resource." }, { - "name": "smtp-config-port:before" + "name": "regions", + "description": "URL of the `fx:regions` property helper resource." }, { - "name": "smtp-config-port:after" + "name": "simplify-ns-loading", + "type": "boolean", + "default": "false" }, { - "name": "smtp-config-username:before" + "name": "ns", + "type": "string", + "default": "\"defaultNS\"" }, { - "name": "smtp-config-username:after" + "name": "status", + "description": "Status message to render at the top of the form. If `null`, the message is hidden.", + "type": "object" }, { - "name": "smtp-config-password:before" + "name": "mode", + "type": "string", + "default": "\"production\"" }, { - "name": "smtp-config-password:after" + "name": "readonly", + "type": "boolean", + "default": "false" }, { - "name": "smtp-config-security:before" + "name": "readonlycontrols", + "default": "\"False\"" }, { - "name": "smtp-config-security:after" + "name": "disabled", + "type": "boolean", + "default": "false" }, { - "name": "country:before" + "name": "disabledcontrols", + "default": "\"False\"" }, { - "name": "country:after" + "name": "hidden", + "type": "boolean", + "default": "false" }, { - "name": "region:before" + "name": "hiddencontrols", + "default": "\"False\"" }, { - "name": "region:after" + "name": "lang", + "description": "Optional ISO 639-1 code describing the language element content is written in.\nChanging the `lang` attribute will update the value of this property.", + "type": "string", + "default": "\"\"" }, { - "name": "postal-code:before" + "name": "parent", + "description": "Optional URL of the collection this element's resource belongs to.\nChanging the `parent` attribute will update the value of this property.", + "type": "string", + "default": "\"\"" }, { - "name": "postal-code:after" + "name": "related", + "description": "Optional URI list of the related resources. If Rumour encounters a related\nresource on creation or deletion, it will be reloaded from source.", + "type": "array", + "default": "[]" }, { - "name": "shipping-address-type:before" + "name": "virtual-host", + "description": "Unique identifier for the virtual host used by the element to serve internal requests.\n\nCurrently only one endpoint is supported: `foxy:///form/`.\nThis endpoint supports POST, GET, PATCH and DELETE methods and functions like a hAPI server.\n\nFor example, `GET foxy://nucleon-123/form/subscriptions/allowNextDateModification/0` on a NucleonElement\nwith `fx:customer_portal_settings` will return the first item of the `subscriptions.allowNextDateModification` array.", + "default": "\"uniqueId('nucleon-')\"" }, { - "name": "shipping-address-type:after" + "name": "group", + "description": "Rumour group. Elements in different groups will not share updates. Empty by default.", + "type": "string" }, { - "name": "features-multiship:before" + "name": "href", + "description": "Optional URL of the resource to load. Switches element to `idle.template` state if empty (default).", + "type": "string" }, { - "name": "features-multiship:after" - }, + "name": "infer", + "description": "Set a name for this element here to enable property inference. Set to `null` to disable.", + "type": "string" + } + ], + "properties": [ { - "name": "require-signed-shipping-rates:before" + "name": "customerPasswordHashTypes", + "attribute": "customer-password-hash-types", + "description": "URL of the `fx:customer_password_hash_types` property helper resource." }, { - "name": "require-signed-shipping-rates:after" + "name": "shippingAddressTypes", + "attribute": "shipping-address-types", + "description": "URL of the `fx:shipping_address_types` property helper resource." }, { - "name": "language:before" + "name": "storeVersions", + "attribute": "store-versions", + "description": "URL of the `fx:store_versions` property helper resource." }, { - "name": "language:after" + "name": "checkoutTypes", + "attribute": "checkout-types", + "description": "URL of the `fx:checkout_types` property helper resource." }, { - "name": "locale-code:before" + "name": "localeCodes", + "attribute": "locale-codes", + "description": "URL of the `fx:locale_codes` property helper resource." }, { - "name": "locale-code:after" + "name": "languages", + "attribute": "languages", + "description": "URL of the `fx:languages` property helper resource." }, { - "name": "currency-style:before" + "name": "timezones", + "attribute": "timezones", + "description": "URL of the `fx:timezones` property helper resource." }, { - "name": "currency-style:after" + "name": "countries", + "attribute": "countries", + "description": "URL of the `fx:countries` property helper resource." }, { - "name": "custom-display-id-config:before" + "name": "regions", + "attribute": "regions", + "description": "URL of the `fx:regions` property helper resource." }, { - "name": "custom-display-id-config:after" + "name": "simplifyNsLoading", + "attribute": "simplify-ns-loading", + "type": "boolean", + "default": "false" }, { - "name": "receipt-continue-url:before" + "name": "ns", + "attribute": "ns", + "type": "string", + "default": "\"defaultNS\"" }, { - "name": "receipt-continue-url:after" + "name": "t", + "type": "Translator", + "default": "\"(key, options) => {\\n const I18nElement = customElements.get('foxy-i18n') as typeof I18n | undefined;\\n\\n if (!I18nElement) return key;\\n\\n let keys: string[];\\n\\n if (this.simplifyNsLoading) {\\n const namespaces = this.ns.split(' ').filter(v => v.length > 0);\\n const path = [...namespaces.slice(1), key].join('.');\\n keys = namespaces[0] ? [`${namespaces[0]}:${path}`] : [path];\\n } else {\\n keys = this.ns\\n .split(' ')\\n .reverse()\\n .map(v => v.trim())\\n .filter(v => v.length > 0)\\n .reverse()\\n .map((v, i, a) => `${v}:${[...a.slice(i + 1), key].join('.')}`);\\n }\\n\\n keys.push(key);\\n\\n return I18nElement.i18next.t(keys, { lng: this.lang, ...options }).toString();\\n }\"" }, { - "name": "app-session-time:before" + "name": "generalErrorPrefix", + "description": "Validation errors with this prefix will show up at the top of the form.", + "type": "string", + "default": "\"error:\"" }, { - "name": "app-session-time:after" + "name": "status", + "attribute": "status", + "description": "Status message to render at the top of the form. If `null`, the message is hidden.", + "type": "object" }, { - "name": "products-require-expires-property:before" + "name": "headerTitleKey", + "description": "Getter that returns a i18n key for the optional form header title.", + "type": "string" }, { - "name": "products-require-expires-property:after" + "name": "headerTitleOptions", + "description": "I18next options to pass to the header title translation function.", + "type": "Record" }, { - "name": "use-cart-validation:before" + "name": "headerSubtitleKey", + "description": "Getter that returns a i18n key for the optional form header subtitle. Note that subtitle is shown only when data is avaiable.", + "type": "string" }, { - "name": "use-cart-validation:after" + "name": "headerSubtitleOptions", + "description": "I18next options to pass to the header subtitle translation function. Note that subtitle is shown only when data is avaiable.", + "type": "Record" }, { - "name": "checkout-type:before" + "name": "headerCopyIdValue", + "description": "ID that will be written to clipboard when Copy ID button in header is clicked.", + "type": "string | number" }, { - "name": "checkout-type:after" + "name": "templates", + "default": "{}" }, { - "name": "customer-password-hash-type:before" + "name": "mode", + "attribute": "mode", + "type": "string", + "default": "\"production\"" }, { - "name": "customer-password-hash-type:after" + "name": "readonly", + "attribute": "readonly", + "type": "boolean", + "default": "false" }, { - "name": "customer-password-hash-config:before" + "name": "readonlyControls", + "attribute": "readonlycontrols", + "default": "\"False\"" }, { - "name": "customer-password-hash-config:after" + "name": "disabled", + "attribute": "disabled", + "type": "boolean", + "default": "false" }, { - "name": "unified-order-entry-password:before" + "name": "disabledControls", + "attribute": "disabledcontrols", + "default": "\"False\"" }, { - "name": "unified-order-entry-password:after" + "name": "hidden", + "attribute": "hidden", + "type": "boolean", + "default": "false" }, { - "name": "single-sign-on-url:before" + "name": "hiddenControls", + "attribute": "hiddencontrols", + "default": "\"False\"" }, { - "name": "single-sign-on-url:after" + "name": "readonlySelector", + "type": "BooleanSelector" }, { - "name": "webhook-url:before" + "name": "disabledSelector", + "type": "BooleanSelector" }, { - "name": "webhook-url:after" + "name": "hiddenSelector", + "type": "BooleanSelector" }, { - "name": "webhook-key-cart-signing:before" + "name": "UpdateEvent", + "description": "Instances of this event are dispatched on an element whenever it changes its\nstate (e.g. when going from `busy` to `idle` or on `form` data change).\nThis event isn't cancelable, and it does not bubble.", + "type": "typeof UpdateEvent", + "default": "\"UpdateEvent\"" }, { - "name": "webhook-key-cart-signing:after" + "name": "Rumour", + "description": "Creates a tagged [Rumour](https://sdk.foxy.dev/classes/_core_index_.rumour.html)\ninstance if it doesn't exist or returns cached one otherwise. NucleonElements\nuse empty Rumour group by default.", + "type": "((group: string) => Rumour) & MemoizedFunction", + "default": "\"memoize<(group: string) => Rumour>(() => new Rumour())\"" }, { - "name": "webhook-key-xml-datafeed:before" + "name": "API", + "description": "Universal [API](https://sdk.foxy.dev/classes/_core_index_.api.html) client\nthat dispatches cancellable `FetchEvent` on an element before each request.", + "type": "typeof API", + "default": "\"API\"" }, { - "name": "webhook-key-xml-datafeed:after" + "name": "lang", + "attribute": "lang", + "description": "Optional ISO 639-1 code describing the language element content is written in.\nChanging the `lang` attribute will update the value of this property.", + "type": "string", + "default": "\"\"" }, { - "name": "webhook-key-api-legacy:before" + "name": "parent", + "attribute": "parent", + "description": "Optional URL of the collection this element's resource belongs to.\nChanging the `parent` attribute will update the value of this property.", + "type": "string", + "default": "\"\"" }, { - "name": "webhook-key-api-legacy:after" + "name": "related", + "attribute": "related", + "description": "Optional URI list of the related resources. If Rumour encounters a related\nresource on creation or deletion, it will be reloaded from source.", + "type": "array", + "default": "[]" }, { - "name": "webhook-key-sso:before" + "name": "virtualHost", + "attribute": "virtual-host", + "description": "Unique identifier for the virtual host used by the element to serve internal requests.\n\nCurrently only one endpoint is supported: `foxy:///form/`.\nThis endpoint supports POST, GET, PATCH and DELETE methods and functions like a hAPI server.\n\nFor example, `GET foxy://nucleon-123/form/subscriptions/allowNextDateModification/0` on a NucleonElement\nwith `fx:customer_portal_settings` will return the first item of the `subscriptions.allowNextDateModification` array.", + "default": "\"uniqueId('nucleon-')\"" }, { - "name": "webhook-key-sso:after" + "name": "failure", + "description": "If network request returns non-2XX code, the entire error response\nwill be available via this getter.\n\nThis property is readonly. Changing failure records via this property is\nnot guaranteed to work. NucleonElement does not provide a way to override error status.", + "type": "Response | null" }, { - "name": "is-maintenance-mode:before" + "name": "errors", + "description": "Array of validation errors returned from `NucleonElement.v8n` checks.\n\nThis property is readonly. Adding or removing error codes via this property is\nnot guaranteed to work. NucleonElement does not provide a way to override validity status.", + "type": "string[]" }, { - "name": "is-maintenance-mode:after" + "name": "form", + "description": "Resource snapshot with edits applied. Empty object if unavailable.\n\nThis property and its value are readonly. Assignments like `element.data.foo = 'bar'`\nare not guaranteed to work. Please use `element.edit({ foo: 'bar' })` instead.\nIf you need to replace the entire data object, consider using `element.data`.", + "type": "Partial" }, { - "name": "timestamps:before" + "name": "data", + "description": "Resource snapshot as-is, no edits applied. Null if unavailable.\n\nReturned value is not reactive. Assignments like `element.data.foo = 'bar'`\nare not guaranteed to work. Please set the property instead: `element.data = { ...element.data, foo: 'bar' }`.\nIf you're processing user input, consider using `element.form` and `element.edit()` instead.", + "type": "TData | null" }, { - "name": "timestamps:after" + "name": "group", + "attribute": "group", + "description": "Rumour group. Elements in different groups will not share updates. Empty by default.", + "type": "string" }, { - "name": "create:before" + "name": "href", + "attribute": "href", + "description": "Optional URL of the resource to load. Switches element to `idle.template` state if empty (default).", + "type": "string" }, { - "name": "create:after" - }, + "name": "infer", + "attribute": "infer", + "description": "Set a name for this element here to enable property inference. Set to `null` to disable.", + "type": "string" + } + ], + "events": [ { - "name": "delete:before" + "name": "update", + "description": "Instance of `NucleonElement.UpdateEvent`. Dispatched on an element whenever it changes its state." }, { - "name": "delete:after" + "name": "fetch", + "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } ] }, @@ -25887,10 +24698,33 @@ "description": "Status message to render at the top of the form. If `null`, the message is hidden.", "type": "object" }, + { + "name": "headerTitleKey", + "description": "Getter that returns a i18n key for the optional form header title.", + "type": "string" + }, + { + "name": "headerTitleOptions", + "description": "I18next options to pass to the header title translation function.", + "type": "Record" + }, + { + "name": "headerSubtitleKey", + "description": "Getter that returns a i18n key for the optional form header subtitle. Note that subtitle is shown only when data is avaiable.", + "type": "string" + }, + { + "name": "headerSubtitleOptions", + "description": "I18next options to pass to the header subtitle translation function. Note that subtitle is shown only when data is avaiable.", + "type": "Record" + }, + { + "name": "headerCopyIdValue", + "description": "ID that will be written to clipboard when Copy ID button in header is clicked.", + "type": "string | number" + }, { "name": "templates", - "description": "Template render functions mapped to their name.", - "type": "Templates", "default": "{}" }, { @@ -26037,92 +24871,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "shipping-method-uri:before" - }, - { - "name": "shipping-method-uri:after" - }, - { - "name": "shipping-container-uri:before" - }, - { - "name": "shipping-container-uri:after" - }, - { - "name": "shipping-drop-type-uri:before" - }, - { - "name": "shipping-drop-type-uri:after" - }, - { - "name": "destinations:before" - }, - { - "name": "destinations:after" - }, - { - "name": "authentication-key:before" - }, - { - "name": "authentication-key:after" - }, - { - "name": "meter-number:before" - }, - { - "name": "meter-number:after" - }, - { - "name": "endpoint:before" - }, - { - "name": "endpoint:after" - }, - { - "name": "accountid:before" - }, - { - "name": "accountid:after" - }, - { - "name": "password:before" - }, - { - "name": "password:after" - }, - { - "name": "custom-code:before" - }, - { - "name": "custom-code:after" - }, - { - "name": "services:before" - }, - { - "name": "services:after" - }, - { - "name": "timestamps:before" - }, - { - "name": "timestamps:after" - }, - { - "name": "create:before" - }, - { - "name": "create:after" - }, - { - "name": "delete:before" - }, - { - "name": "delete:after" - } ] }, { @@ -26544,9 +25292,33 @@ "description": "Status message to render at the top of the form. If `null`, the message is hidden.", "type": "object" }, + { + "name": "headerTitleKey", + "description": "Getter that returns a i18n key for the optional form header title.", + "type": "string" + }, + { + "name": "headerTitleOptions", + "description": "I18next options to pass to the header title translation function.", + "type": "Record" + }, + { + "name": "headerSubtitleKey", + "description": "Getter that returns a i18n key for the optional form header subtitle. Note that subtitle is shown only when data is avaiable.", + "type": "string" + }, + { + "name": "headerSubtitleOptions", + "description": "I18next options to pass to the header subtitle translation function. Note that subtitle is shown only when data is avaiable.", + "type": "Record" + }, + { + "name": "headerCopyIdValue", + "description": "ID that will be written to clipboard when Copy ID button in header is clicked.", + "type": "string | number" + }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -26656,132 +25428,42 @@ "type": "string[]" }, { - "name": "form", - "description": "Resource snapshot with edits applied. Empty object if unavailable.\n\nThis property and its value are readonly. Assignments like `element.data.foo = 'bar'`\nare not guaranteed to work. Please use `element.edit({ foo: 'bar' })` instead.\nIf you need to replace the entire data object, consider using `element.data`.", - "type": "Partial" - }, - { - "name": "data", - "description": "Resource snapshot as-is, no edits applied. Null if unavailable.\n\nReturned value is not reactive. Assignments like `element.data.foo = 'bar'`\nare not guaranteed to work. Please set the property instead: `element.data = { ...element.data, foo: 'bar' }`.\nIf you're processing user input, consider using `element.form` and `element.edit()` instead.", - "type": "TData | null" - }, - { - "name": "group", - "attribute": "group", - "description": "Rumour group. Elements in different groups will not share updates. Empty by default.", - "type": "string" - }, - { - "name": "href", - "attribute": "href", - "description": "Optional URL of the resource to load. Switches element to `idle.template` state if empty (default).", - "type": "string" - }, - { - "name": "infer", - "attribute": "infer", - "description": "Set a name for this element here to enable property inference. Set to `null` to disable.", - "type": "string" - } - ], - "events": [ - { - "name": "update", - "description": "Instance of `NucleonElement.UpdateEvent`. Dispatched on an element whenever it changes its state." - }, - { - "name": "fetch", - "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." - } - ], - "slots": [ - { - "name": "header:before", - "description": "**new in v1.4.0**" - }, - { - "name": "header:after", - "description": "**new in v1.4.0**" - }, - { - "name": "items:before", - "description": "**new in v1.4.0**" - }, - { - "name": "items:after", - "description": "**new in v1.4.0**" - }, - { - "name": "items:actions:before", - "description": "**new in v1.4.0**" - }, - { - "name": "items:actions:after", - "description": "**new in v1.4.0**" - }, - { - "name": "end-date:before", - "description": "**new in v1.4.0**" - }, - { - "name": "end-date:after", - "description": "**new in v1.4.0**" - }, - { - "name": "next-transaction-date:before", - "description": "**new in v1.4.0**" - }, - { - "name": "next-transaction-date:after", - "description": "**new in v1.4.0**" - }, - { - "name": "frequency:before", - "description": "**new in v1.4.0**" - }, - { - "name": "frequency:after", - "description": "**new in v1.4.0**" - }, - { - "name": "transactions:before", - "description": "**new in v1.4.0**" - }, - { - "name": "transactions:after", - "description": "**new in v1.4.0**" - }, - { - "name": "attributes:before", - "description": "**new in v1.20.0**" - }, - { - "name": "attributes:after", - "description": "**new in v1.20.0**" + "name": "form", + "description": "Resource snapshot with edits applied. Empty object if unavailable.\n\nThis property and its value are readonly. Assignments like `element.data.foo = 'bar'`\nare not guaranteed to work. Please use `element.edit({ foo: 'bar' })` instead.\nIf you need to replace the entire data object, consider using `element.data`.", + "type": "Partial" }, { - "name": "timestamps:before", - "description": "**new in v1.20.0**" + "name": "data", + "description": "Resource snapshot as-is, no edits applied. Null if unavailable.\n\nReturned value is not reactive. Assignments like `element.data.foo = 'bar'`\nare not guaranteed to work. Please set the property instead: `element.data = { ...element.data, foo: 'bar' }`.\nIf you're processing user input, consider using `element.form` and `element.edit()` instead.", + "type": "TData | null" }, { - "name": "timestamps:after", - "description": "**new in v1.20.0**" + "name": "group", + "attribute": "group", + "description": "Rumour group. Elements in different groups will not share updates. Empty by default.", + "type": "string" }, { - "name": "past-due-amount:before", - "description": "**new in v1.20.0**" + "name": "href", + "attribute": "href", + "description": "Optional URL of the resource to load. Switches element to `idle.template` state if empty (default).", + "type": "string" }, { - "name": "past-due-amount:after", - "description": "**new in v1.20.0**" - }, + "name": "infer", + "attribute": "infer", + "description": "Set a name for this element here to enable property inference. Set to `null` to disable.", + "type": "string" + } + ], + "events": [ { - "name": "start-date:before", - "description": "**new in v1.20.0**" + "name": "update", + "description": "Instance of `NucleonElement.UpdateEvent`. Dispatched on an element whenever it changes its state." }, { - "name": "start-date:after", - "description": "**new in v1.20.0**" + "name": "fetch", + "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } ] }, @@ -26906,9 +25588,33 @@ "description": "Status message to render at the top of the form. If `null`, the message is hidden.", "type": "object" }, + { + "name": "headerTitleKey", + "description": "Getter that returns a i18n key for the optional form header title.", + "type": "string" + }, + { + "name": "headerTitleOptions", + "description": "I18next options to pass to the header title translation function.", + "type": "Record" + }, + { + "name": "headerSubtitleKey", + "description": "Getter that returns a i18n key for the optional form header subtitle. Note that subtitle is shown only when data is avaiable.", + "type": "string" + }, + { + "name": "headerSubtitleOptions", + "description": "I18next options to pass to the header subtitle translation function. Note that subtitle is shown only when data is avaiable.", + "type": "Record" + }, + { + "name": "headerCopyIdValue", + "description": "ID that will be written to clipboard when Copy ID button in header is clicked.", + "type": "string | number" + }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -27055,88 +25761,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "past-due-amount-handling:before" - }, - { - "name": "past-due-amount-handling:after" - }, - { - "name": "automatically-charge-past-due-amount:before" - }, - { - "name": "automatically-charge-past-due-amount:after" - }, - { - "name": "clear-past-due-amounts-on", - "description": "success:before – only if `form.automatically_charge_past_due_amount` is `false`" - }, - { - "name": "reset-nextdate-on-makeup", - "description": "payment:before – only if `form.automatically_charge_past_due_amount` is `false`" - }, - { - "name": "reattempt-bypass:before" - }, - { - "name": "reattempt-bypass:after" - }, - { - "name": "reattempt-schedule:before" - }, - { - "name": "reattempt-schedule:after" - }, - { - "name": "reminder-email-schedule:before" - }, - { - "name": "reminder-email-schedule:after" - }, - { - "name": "expiring-soon-payment-reminder-schedule:before" - }, - { - "name": "expiring-soon-payment-reminder-schedule:after" - }, - { - "name": "send-email-receipts-for-automated-billing:before" - }, - { - "name": "send-email-receipts-for-automated-billing:after" - }, - { - "name": "cancellation-schedule:before" - }, - { - "name": "cancellation-schedule:after" - }, - { - "name": "modification-url:before" - }, - { - "name": "modification-url:after" - }, - { - "name": "timestamps:before" - }, - { - "name": "timestamps:after" - }, - { - "name": "create:before" - }, - { - "name": "create:after" - }, - { - "name": "delete:before" - }, - { - "name": "delete:after" - } ] }, { @@ -27253,7 +25877,6 @@ }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -27518,7 +26141,6 @@ }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -27940,20 +26562,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "title:before" - }, - { - "name": "title:after" - }, - { - "name": "subtitle:before" - }, - { - "name": "subtitle:after" - } ] }, { @@ -28067,7 +26675,6 @@ }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -28231,86 +26838,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "name:before" - }, - { - "name": "name:after" - }, - { - "name": "type:before" - }, - { - "name": "type:after" - }, - { - "name": "country:before" - }, - { - "name": "country:after" - }, - { - "name": "region:before" - }, - { - "name": "region:after" - }, - { - "name": "city:before" - }, - { - "name": "city:after" - }, - { - "name": "provider:before" - }, - { - "name": "provider:after" - }, - { - "name": "rate:before" - }, - { - "name": "rate:after" - }, - { - "name": "apply-to-shipping:before" - }, - { - "name": "apply-to-shipping:after" - }, - { - "name": "use-origin-rates:before" - }, - { - "name": "use-origin-rates:after" - }, - { - "name": "exempt-all-customer-tax-ids:before" - }, - { - "name": "exempt-all-customer-tax-ids:after" - }, - { - "name": "timestamps:before" - }, - { - "name": "timestamps:after" - }, - { - "name": "delete:before" - }, - { - "name": "delete:after" - }, - { - "name": "create:before" - }, - { - "name": "create:after" - } ] }, { @@ -28428,7 +26955,6 @@ }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -28533,156 +27059,64 @@ }, { "name": "related", - "attribute": "related", - "description": "Optional URI list of the related resources. If Rumour encounters a related\nresource on creation or deletion, it will be reloaded from source.", - "type": "array", - "default": "[]" - }, - { - "name": "virtualHost", - "attribute": "virtual-host", - "description": "Unique identifier for the virtual host used by the element to serve internal requests.\n\nCurrently only one endpoint is supported: `foxy:///form/`.\nThis endpoint supports POST, GET, PATCH and DELETE methods and functions like a hAPI server.\n\nFor example, `GET foxy://nucleon-123/form/subscriptions/allowNextDateModification/0` on a NucleonElement\nwith `fx:customer_portal_settings` will return the first item of the `subscriptions.allowNextDateModification` array.", - "default": "\"uniqueId('nucleon-')\"" - }, - { - "name": "failure", - "description": "If network request returns non-2XX code, the entire error response\nwill be available via this getter.\n\nThis property is readonly. Changing failure records via this property is\nnot guaranteed to work. NucleonElement does not provide a way to override error status.", - "type": "Response | null" - }, - { - "name": "errors", - "description": "Array of validation errors returned from `NucleonElement.v8n` checks.\n\nThis property is readonly. Adding or removing error codes via this property is\nnot guaranteed to work. NucleonElement does not provide a way to override validity status.", - "type": "string[]" - }, - { - "name": "form", - "description": "Resource snapshot with edits applied. Empty object if unavailable.\n\nThis property and its value are readonly. Assignments like `element.data.foo = 'bar'`\nare not guaranteed to work. Please use `element.edit({ foo: 'bar' })` instead.\nIf you need to replace the entire data object, consider using `element.data`.", - "type": "Partial" - }, - { - "name": "data", - "description": "Resource snapshot as-is, no edits applied. Null if unavailable.\n\nReturned value is not reactive. Assignments like `element.data.foo = 'bar'`\nare not guaranteed to work. Please set the property instead: `element.data = { ...element.data, foo: 'bar' }`.\nIf you're processing user input, consider using `element.form` and `element.edit()` instead.", - "type": "TData | null" - }, - { - "name": "group", - "attribute": "group", - "description": "Rumour group. Elements in different groups will not share updates. Empty by default.", - "type": "string" - }, - { - "name": "href", - "attribute": "href", - "description": "Optional URL of the resource to load. Switches element to `idle.template` state if empty (default).", - "type": "string" - }, - { - "name": "infer", - "attribute": "infer", - "description": "Set a name for this element here to enable property inference. Set to `null` to disable.", - "type": "string" - } - ], - "events": [ - { - "name": "update", - "description": "Instance of `NucleonElement.UpdateEvent`. Dispatched on an element whenever it changes its state." - }, - { - "name": "fetch", - "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." - } - ], - "slots": [ - { - "name": "cart-type:before" - }, - { - "name": "cart-type:after" - }, - { - "name": "foxycomplete:before" - }, - { - "name": "foxycomplete:after" - }, - { - "name": "locations:before" - }, - { - "name": "locations:after" - }, - { - "name": "hidden-fields:before" - }, - { - "name": "hidden-fields:after" - }, - { - "name": "cards:before" - }, - { - "name": "cards:after" - }, - { - "name": "checkout-type:before" - }, - { - "name": "checkout-type:after" - }, - { - "name": "consent:before" - }, - { - "name": "consent:after" - }, - { - "name": "fields:before" - }, - { - "name": "fields:after" - }, - { - "name": "google-analytics:before" - }, - { - "name": "google-analytics:after" - }, - { - "name": "google-tag:before" - }, - { - "name": "google-tag:after" + "attribute": "related", + "description": "Optional URI list of the related resources. If Rumour encounters a related\nresource on creation or deletion, it will be reloaded from source.", + "type": "array", + "default": "[]" }, { - "name": "troubleshooting:before" + "name": "virtualHost", + "attribute": "virtual-host", + "description": "Unique identifier for the virtual host used by the element to serve internal requests.\n\nCurrently only one endpoint is supported: `foxy:///form/`.\nThis endpoint supports POST, GET, PATCH and DELETE methods and functions like a hAPI server.\n\nFor example, `GET foxy://nucleon-123/form/subscriptions/allowNextDateModification/0` on a NucleonElement\nwith `fx:customer_portal_settings` will return the first item of the `subscriptions.allowNextDateModification` array.", + "default": "\"uniqueId('nucleon-')\"" }, { - "name": "troubleshooting:after" + "name": "failure", + "description": "If network request returns non-2XX code, the entire error response\nwill be available via this getter.\n\nThis property is readonly. Changing failure records via this property is\nnot guaranteed to work. NucleonElement does not provide a way to override error status.", + "type": "Response | null" }, { - "name": "custom-config:before" + "name": "errors", + "description": "Array of validation errors returned from `NucleonElement.v8n` checks.\n\nThis property is readonly. Adding or removing error codes via this property is\nnot guaranteed to work. NucleonElement does not provide a way to override validity status.", + "type": "string[]" }, { - "name": "custom-config:after" + "name": "form", + "description": "Resource snapshot with edits applied. Empty object if unavailable.\n\nThis property and its value are readonly. Assignments like `element.data.foo = 'bar'`\nare not guaranteed to work. Please use `element.edit({ foo: 'bar' })` instead.\nIf you need to replace the entire data object, consider using `element.data`.", + "type": "Partial" }, { - "name": "header:before" + "name": "data", + "description": "Resource snapshot as-is, no edits applied. Null if unavailable.\n\nReturned value is not reactive. Assignments like `element.data.foo = 'bar'`\nare not guaranteed to work. Please set the property instead: `element.data = { ...element.data, foo: 'bar' }`.\nIf you're processing user input, consider using `element.form` and `element.edit()` instead.", + "type": "TData | null" }, { - "name": "header:after" + "name": "group", + "attribute": "group", + "description": "Rumour group. Elements in different groups will not share updates. Empty by default.", + "type": "string" }, { - "name": "custom-fields:before" + "name": "href", + "attribute": "href", + "description": "Optional URL of the resource to load. Switches element to `idle.template` state if empty (default).", + "type": "string" }, { - "name": "custom-fields:after" - }, + "name": "infer", + "attribute": "infer", + "description": "Set a name for this element here to enable property inference. Set to `null` to disable.", + "type": "string" + } + ], + "events": [ { - "name": "footer:before" + "name": "update", + "description": "Instance of `NucleonElement.UpdateEvent`. Dispatched on an element whenever it changes its state." }, { - "name": "footer:after" + "name": "fetch", + "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } ] }, @@ -28775,7 +27209,6 @@ "properties": [ { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -28939,38 +27372,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "description:before" - }, - { - "name": "description:after" - }, - { - "name": "content:before" - }, - { - "name": "content:after" - }, - { - "name": "timestamps:before" - }, - { - "name": "timestamps:after" - }, - { - "name": "create:before" - }, - { - "name": "create:after" - }, - { - "name": "delete:before" - }, - { - "name": "delete:after" - } ] }, { @@ -29079,7 +27480,6 @@ }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -29230,20 +27630,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "title:before" - }, - { - "name": "title:after" - }, - { - "name": "subtitle:before" - }, - { - "name": "subtitle:after" - } ] }, { @@ -29403,10 +27789,33 @@ "description": "Status message to render at the top of the form. If `null`, the message is hidden.", "type": "object" }, + { + "name": "headerTitleKey", + "description": "Getter that returns a i18n key for the optional form header title.", + "type": "string" + }, + { + "name": "headerTitleOptions", + "description": "I18next options to pass to the header title translation function.", + "type": "Record" + }, + { + "name": "headerSubtitleKey", + "description": "Getter that returns a i18n key for the optional form header subtitle. Note that subtitle is shown only when data is avaiable.", + "type": "string" + }, + { + "name": "headerSubtitleOptions", + "description": "I18next options to pass to the header subtitle translation function. Note that subtitle is shown only when data is avaiable.", + "type": "Record" + }, + { + "name": "headerCopyIdValue", + "description": "ID that will be written to clipboard when Copy ID button in header is clicked.", + "type": "string | number" + }, { "name": "templates", - "description": "Template render functions mapped to their name.", - "type": "Templates", "default": "{}" }, { @@ -29553,62 +27962,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "description:before" - }, - { - "name": "description:after" - }, - { - "name": "code:before" - }, - { - "name": "code:after" - }, - { - "name": "language:before" - }, - { - "name": "language:after" - }, - { - "name": "locale-code:before" - }, - { - "name": "locale-code:after" - }, - { - "name": "payment-method-set-uri:before" - }, - { - "name": "payment-method-set-uri:after" - }, - { - "name": "language-overrides:before" - }, - { - "name": "language-overrides:after" - }, - { - "name": "timestamps:before" - }, - { - "name": "timestamps:after" - }, - { - "name": "create:before" - }, - { - "name": "create:after" - }, - { - "name": "delete:before" - }, - { - "name": "delete:after" - } ] }, { @@ -29756,6 +28109,31 @@ "description": "Status message to render at the top of the form. If `null`, the message is hidden.", "type": "object" }, + { + "name": "headerTitleKey", + "description": "Getter that returns a i18n key for the optional form header title.", + "type": "string" + }, + { + "name": "headerTitleOptions", + "description": "I18next options to pass to the header title translation function.", + "type": "Record" + }, + { + "name": "headerSubtitleKey", + "description": "Getter that returns a i18n key for the optional form header subtitle. Note that subtitle is shown only when data is avaiable.", + "type": "string" + }, + { + "name": "headerSubtitleOptions", + "description": "I18next options to pass to the header subtitle translation function. Note that subtitle is shown only when data is avaiable.", + "type": "Record" + }, + { + "name": "headerCopyIdValue", + "description": "ID that will be written to clipboard when Copy ID button in header is clicked.", + "type": "string" + }, { "name": "templates", "default": "{}" @@ -29995,7 +28373,6 @@ "properties": [ { "name": "templates", - "type": "Partial<{ 'total:before': Renderer; 'total:after': Renderer; 'status:before': Renderer; ... 4 more ...; 'customer:after': Renderer<...>; }>", "default": "{}" }, { @@ -30163,32 +28540,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "total:before" - }, - { - "name": "total:after" - }, - { - "name": "status:before" - }, - { - "name": "status:after" - }, - { - "name": "description:before" - }, - { - "name": "description:after" - }, - { - "name": "customer:before" - }, - { - "name": "customer:after" - } ] }, { @@ -30315,7 +28666,6 @@ }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -30611,6 +28961,31 @@ "description": "Status message to render at the top of the form. If `null`, the message is hidden.", "type": "object" }, + { + "name": "headerTitleKey", + "description": "Getter that returns a i18n key for the optional form header title.", + "type": "string" + }, + { + "name": "headerTitleOptions", + "description": "I18next options to pass to the header title translation function.", + "type": "Record" + }, + { + "name": "headerSubtitleKey", + "description": "Getter that returns a i18n key for the optional form header subtitle. Note that subtitle is shown only when data is avaiable.", + "type": "string" + }, + { + "name": "headerSubtitleOptions", + "description": "I18next options to pass to the header subtitle translation function. Note that subtitle is shown only when data is avaiable.", + "type": "Record" + }, + { + "name": "headerCopyIdValue", + "description": "ID that will be written to clipboard when Copy ID button in header is clicked.", + "type": "string | number" + }, { "name": "templates", "default": "{}" @@ -30759,20 +29134,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "template-set:before" - }, - { - "name": "template-set:after" - }, - { - "name": "cc-token:before" - }, - { - "name": "cc-token:after" - } ] }, { @@ -30881,7 +29242,6 @@ }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -31032,20 +29392,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "title:before" - }, - { - "name": "title:after" - }, - { - "name": "subtitle:before" - }, - { - "name": "subtitle:after" - } ] }, { @@ -31169,9 +29515,33 @@ "description": "Status message to render at the top of the form. If `null`, the message is hidden.", "type": "object" }, + { + "name": "headerTitleKey", + "description": "Getter that returns a i18n key for the optional form header title.", + "type": "string" + }, + { + "name": "headerTitleOptions", + "description": "I18next options to pass to the header title translation function.", + "type": "Record" + }, + { + "name": "headerSubtitleKey", + "description": "Getter that returns a i18n key for the optional form header subtitle. Note that subtitle is shown only when data is avaiable.", + "type": "string" + }, + { + "name": "headerSubtitleOptions", + "description": "I18next options to pass to the header subtitle translation function. Note that subtitle is shown only when data is avaiable.", + "type": "Record" + }, + { + "name": "headerCopyIdValue", + "description": "ID that will be written to clipboard when Copy ID button in header is clicked.", + "type": "string | number" + }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -31318,20 +29688,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "first", - "description": "name:before – new in v1.22.0" - }, - { - "name": "last", - "description": "name:before – new in v1.22.0" - }, - { - "name": "", - "description": "email:before – new in v1.22.0" - } ] }, { @@ -31453,7 +29809,6 @@ }, { "name": "templates", - "type": "Templates", "default": "{}" }, { @@ -31911,6 +30266,31 @@ "description": "Status message to render at the top of the form. If `null`, the message is hidden.", "type": "object" }, + { + "name": "headerTitleKey", + "description": "Getter that returns a i18n key for the optional form header title.", + "type": "string" + }, + { + "name": "headerTitleOptions", + "description": "I18next options to pass to the header title translation function.", + "type": "Record" + }, + { + "name": "headerSubtitleKey", + "description": "Getter that returns a i18n key for the optional form header subtitle. Note that subtitle is shown only when data is avaiable.", + "type": "string" + }, + { + "name": "headerSubtitleOptions", + "description": "I18next options to pass to the header subtitle translation function. Note that subtitle is shown only when data is avaiable.", + "type": "Record" + }, + { + "name": "headerCopyIdValue", + "description": "ID that will be written to clipboard when Copy ID button in header is clicked.", + "type": "string | number" + }, { "name": "templates", "default": "{}" @@ -32059,62 +30439,6 @@ "name": "fetch", "description": "Instance of `NucleonElement.API.FetchEvent`. Emitted before each API request." } - ], - "slots": [ - { - "name": "name:before" - }, - { - "name": "name:after" - }, - { - "name": "event-resource:before" - }, - { - "name": "event-resource:after" - }, - { - "name": "query:before" - }, - { - "name": "query:after" - }, - { - "name": "url:before" - }, - { - "name": "url:after" - }, - { - "name": "format:before" - }, - { - "name": "format:after" - }, - { - "name": "encryption-key:before" - }, - { - "name": "encryption-key:after" - }, - { - "name": "version:before" - }, - { - "name": "version:after" - }, - { - "name": "statuses:before" - }, - { - "name": "statuses:after" - }, - { - "name": "logs:before" - }, - { - "name": "logs:after" - } ] }, { diff --git a/package-lock.json b/package-lock.json index 46ad0e880..fe495ced4 100644 --- a/package-lock.json +++ b/package-lock.json @@ -87,7 +87,7 @@ "rollup-plugin-copy": "^3.4.0", "rollup-plugin-multi-input": "^1.1.1", "rollup-plugin-terser": "^7.0.1", - "semantic-release": "^17.2.2", + "semantic-release": "^24.0.0", "sinon": "^9.0.2", "tailwindcss": "^2.0.4", "tslib": "2.1.0", @@ -2620,153 +2620,147 @@ } }, "node_modules/@octokit/auth-token": { - "version": "2.5.0", - "resolved": "https://registry.npmjs.org/@octokit/auth-token/-/auth-token-2.5.0.tgz", - "integrity": "sha512-r5FVUJCOLl19AxiuZD2VRZ/ORjp/4IN98Of6YJoJOkY75CIBuYfmiNHGrDwXr+aLGG55igl9QrxX3hbiXlLb+g==", + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/@octokit/auth-token/-/auth-token-5.1.1.tgz", + "integrity": "sha512-rh3G3wDO8J9wSjfI436JUKzHIxq8NaiL0tVeB2aXmG6p/9859aUOAjA9pmSPNGGZxfwmaJ9ozOJImuNVJdpvbA==", "dev": true, - "dependencies": { - "@octokit/types": "^6.0.3" + "engines": { + "node": ">= 18" } }, "node_modules/@octokit/core": { - "version": "3.6.0", - "resolved": "https://registry.npmjs.org/@octokit/core/-/core-3.6.0.tgz", - "integrity": "sha512-7RKRKuA4xTjMhY+eG3jthb3hlZCsOwg3rztWh75Xc+ShDWOfDDATWbeZpAHBNRpm4Tv9WgBMOy1zEJYXG6NJ7Q==", + "version": "6.1.2", + "resolved": "https://registry.npmjs.org/@octokit/core/-/core-6.1.2.tgz", + "integrity": "sha512-hEb7Ma4cGJGEUNOAVmyfdB/3WirWMg5hDuNFVejGEDFqupeOysLc2sG6HJxY2etBp5YQu5Wtxwi020jS9xlUwg==", "dev": true, "dependencies": { - "@octokit/auth-token": "^2.4.4", - "@octokit/graphql": "^4.5.8", - "@octokit/request": "^5.6.3", - "@octokit/request-error": "^2.0.5", - "@octokit/types": "^6.0.3", - "before-after-hook": "^2.2.0", - "universal-user-agent": "^6.0.0" + "@octokit/auth-token": "^5.0.0", + "@octokit/graphql": "^8.0.0", + "@octokit/request": "^9.0.0", + "@octokit/request-error": "^6.0.1", + "@octokit/types": "^13.0.0", + "before-after-hook": "^3.0.2", + "universal-user-agent": "^7.0.0" + }, + "engines": { + "node": ">= 18" } }, "node_modules/@octokit/endpoint": { - "version": "6.0.12", - "resolved": "https://registry.npmjs.org/@octokit/endpoint/-/endpoint-6.0.12.tgz", - "integrity": "sha512-lF3puPwkQWGfkMClXb4k/eUT/nZKQfxinRWJrdZaJO85Dqwo/G0yOC434Jr2ojwafWJMYqFGFa5ms4jJUgujdA==", + "version": "10.1.1", + "resolved": "https://registry.npmjs.org/@octokit/endpoint/-/endpoint-10.1.1.tgz", + "integrity": "sha512-JYjh5rMOwXMJyUpj028cu0Gbp7qe/ihxfJMLc8VZBMMqSwLgOxDI1911gV4Enl1QSavAQNJcwmwBF9M0VvLh6Q==", "dev": true, "dependencies": { - "@octokit/types": "^6.0.3", - "is-plain-object": "^5.0.0", - "universal-user-agent": "^6.0.0" - } - }, - "node_modules/@octokit/endpoint/node_modules/is-plain-object": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/is-plain-object/-/is-plain-object-5.0.0.tgz", - "integrity": "sha512-VRSzKkbMm5jMDoKLbltAkFQ5Qr7VDiTFGXxYFXXowVj387GeGNOCsOH6Msy00SGZ3Fp84b1Naa1psqgcCIEP5Q==", - "dev": true, + "@octokit/types": "^13.0.0", + "universal-user-agent": "^7.0.2" + }, "engines": { - "node": ">=0.10.0" + "node": ">= 18" } }, "node_modules/@octokit/graphql": { - "version": "4.8.0", - "resolved": "https://registry.npmjs.org/@octokit/graphql/-/graphql-4.8.0.tgz", - "integrity": "sha512-0gv+qLSBLKF0z8TKaSKTsS39scVKF9dbMxJpj3U0vC7wjNWFuIpL/z76Qe2fiuCbDRcJSavkXsVtMS6/dtQQsg==", + "version": "8.1.1", + "resolved": "https://registry.npmjs.org/@octokit/graphql/-/graphql-8.1.1.tgz", + "integrity": "sha512-ukiRmuHTi6ebQx/HFRCXKbDlOh/7xEV6QUXaE7MJEKGNAncGI/STSbOkl12qVXZrfZdpXctx5O9X1AIaebiDBg==", "dev": true, "dependencies": { - "@octokit/request": "^5.6.0", - "@octokit/types": "^6.0.3", - "universal-user-agent": "^6.0.0" + "@octokit/request": "^9.0.0", + "@octokit/types": "^13.0.0", + "universal-user-agent": "^7.0.0" + }, + "engines": { + "node": ">= 18" } }, "node_modules/@octokit/openapi-types": { - "version": "12.11.0", - "resolved": "https://registry.npmjs.org/@octokit/openapi-types/-/openapi-types-12.11.0.tgz", - "integrity": "sha512-VsXyi8peyRq9PqIz/tpqiL2w3w80OgVMwBHltTml3LmVvXiphgeqmY9mvBw9Wu7e0QWk/fqD37ux8yP5uVekyQ==", + "version": "22.2.0", + "resolved": "https://registry.npmjs.org/@octokit/openapi-types/-/openapi-types-22.2.0.tgz", + "integrity": "sha512-QBhVjcUa9W7Wwhm6DBFu6ZZ+1/t/oYxqc2tp81Pi41YNuJinbFRx8B133qVOrAaBbF7D/m0Et6f9/pZt9Rc+tg==", "dev": true }, "node_modules/@octokit/plugin-paginate-rest": { - "version": "2.21.3", - "resolved": "https://registry.npmjs.org/@octokit/plugin-paginate-rest/-/plugin-paginate-rest-2.21.3.tgz", - "integrity": "sha512-aCZTEf0y2h3OLbrgKkrfFdjRL6eSOo8komneVQJnYecAxIej7Bafor2xhuDJOIFau4pk0i/P28/XgtbyPF0ZHw==", + "version": "11.3.0", + "resolved": "https://registry.npmjs.org/@octokit/plugin-paginate-rest/-/plugin-paginate-rest-11.3.0.tgz", + "integrity": "sha512-n4znWfRinnUQF6TPyxs7EctSAA3yVSP4qlJP2YgI3g9d4Ae2n5F3XDOjbUluKRxPU3rfsgpOboI4O4VtPc6Ilg==", "dev": true, "dependencies": { - "@octokit/types": "^6.40.0" + "@octokit/types": "^13.5.0" + }, + "engines": { + "node": ">= 18" }, "peerDependencies": { - "@octokit/core": ">=2" + "@octokit/core": ">=6" } }, - "node_modules/@octokit/plugin-request-log": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/@octokit/plugin-request-log/-/plugin-request-log-1.0.4.tgz", - "integrity": "sha512-mLUsMkgP7K/cnFEw07kWqXGF5LKrOkD+lhCrKvPHXWDywAwuDUeDwWBpc69XK3pNX0uKiVt8g5z96PJ6z9xCFA==", + "node_modules/@octokit/plugin-retry": { + "version": "7.1.1", + "resolved": "https://registry.npmjs.org/@octokit/plugin-retry/-/plugin-retry-7.1.1.tgz", + "integrity": "sha512-G9Ue+x2odcb8E1XIPhaFBnTTIrrUDfXN05iFXiqhR+SeeeDMMILcAnysOsxUpEWcQp2e5Ft397FCXTcPkiPkLw==", "dev": true, + "dependencies": { + "@octokit/request-error": "^6.0.0", + "@octokit/types": "^13.0.0", + "bottleneck": "^2.15.3" + }, + "engines": { + "node": ">= 18" + }, "peerDependencies": { - "@octokit/core": ">=3" + "@octokit/core": ">=6" } }, - "node_modules/@octokit/plugin-rest-endpoint-methods": { - "version": "5.16.2", - "resolved": "https://registry.npmjs.org/@octokit/plugin-rest-endpoint-methods/-/plugin-rest-endpoint-methods-5.16.2.tgz", - "integrity": "sha512-8QFz29Fg5jDuTPXVtey05BLm7OB+M8fnvE64RNegzX7U+5NUXcOcnpTIK0YfSHBg8gYd0oxIq3IZTe9SfPZiRw==", + "node_modules/@octokit/plugin-throttling": { + "version": "9.3.0", + "resolved": "https://registry.npmjs.org/@octokit/plugin-throttling/-/plugin-throttling-9.3.0.tgz", + "integrity": "sha512-B5YTToSRTzNSeEyssnrT7WwGhpIdbpV9NKIs3KyTWHX6PhpYn7gqF/+lL3BvsASBM3Sg5BAUYk7KZx5p/Ec77w==", "dev": true, "dependencies": { - "@octokit/types": "^6.39.0", - "deprecation": "^2.3.1" + "@octokit/types": "^13.0.0", + "bottleneck": "^2.15.3" + }, + "engines": { + "node": ">= 18" }, "peerDependencies": { - "@octokit/core": ">=3" + "@octokit/core": "^6.0.0" } }, "node_modules/@octokit/request": { - "version": "5.6.3", - "resolved": "https://registry.npmjs.org/@octokit/request/-/request-5.6.3.tgz", - "integrity": "sha512-bFJl0I1KVc9jYTe9tdGGpAMPy32dLBXXo1dS/YwSCTL/2nd9XeHsY616RE3HPXDVk+a+dBuzyz5YdlXwcDTr2A==", + "version": "9.1.1", + "resolved": "https://registry.npmjs.org/@octokit/request/-/request-9.1.1.tgz", + "integrity": "sha512-pyAguc0p+f+GbQho0uNetNQMmLG1e80WjkIaqqgUkihqUp0boRU6nKItXO4VWnr+nbZiLGEyy4TeKRwqaLvYgw==", "dev": true, "dependencies": { - "@octokit/endpoint": "^6.0.1", - "@octokit/request-error": "^2.1.0", - "@octokit/types": "^6.16.1", - "is-plain-object": "^5.0.0", - "node-fetch": "^2.6.7", - "universal-user-agent": "^6.0.0" + "@octokit/endpoint": "^10.0.0", + "@octokit/request-error": "^6.0.1", + "@octokit/types": "^13.1.0", + "universal-user-agent": "^7.0.2" + }, + "engines": { + "node": ">= 18" } }, "node_modules/@octokit/request-error": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/@octokit/request-error/-/request-error-2.1.0.tgz", - "integrity": "sha512-1VIvgXxs9WHSjicsRwq8PlR2LR2x6DwsJAaFgzdi0JfJoGSO8mYI/cHJQ+9FbN21aa+DrgNLnwObmyeSC8Rmpg==", + "version": "6.1.1", + "resolved": "https://registry.npmjs.org/@octokit/request-error/-/request-error-6.1.1.tgz", + "integrity": "sha512-1mw1gqT3fR/WFvnoVpY/zUM2o/XkMs/2AszUUG9I69xn0JFLv6PGkPhNk5lbfvROs79wiS0bqiJNxfCZcRJJdg==", "dev": true, "dependencies": { - "@octokit/types": "^6.0.3", - "deprecation": "^2.0.0", - "once": "^1.4.0" - } - }, - "node_modules/@octokit/request/node_modules/is-plain-object": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/is-plain-object/-/is-plain-object-5.0.0.tgz", - "integrity": "sha512-VRSzKkbMm5jMDoKLbltAkFQ5Qr7VDiTFGXxYFXXowVj387GeGNOCsOH6Msy00SGZ3Fp84b1Naa1psqgcCIEP5Q==", - "dev": true, + "@octokit/types": "^13.0.0" + }, "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/@octokit/rest": { - "version": "18.12.0", - "resolved": "https://registry.npmjs.org/@octokit/rest/-/rest-18.12.0.tgz", - "integrity": "sha512-gDPiOHlyGavxr72y0guQEhLsemgVjwRePayJ+FcKc2SJqKUbxbkvf5kAZEWA/MKvsfYlQAMVzNJE3ezQcxMJ2Q==", - "dev": true, - "dependencies": { - "@octokit/core": "^3.5.1", - "@octokit/plugin-paginate-rest": "^2.16.8", - "@octokit/plugin-request-log": "^1.0.4", - "@octokit/plugin-rest-endpoint-methods": "^5.12.0" + "node": ">= 18" } }, "node_modules/@octokit/types": { - "version": "6.41.0", - "resolved": "https://registry.npmjs.org/@octokit/types/-/types-6.41.0.tgz", - "integrity": "sha512-eJ2jbzjdijiL3B4PrSQaSjuF2sPEQPVCPzBvTHJD9Nz+9dw2SGH4K4xeQJ77YfTq5bRQ+bD8wT11JbeDPmxmGg==", + "version": "13.5.0", + "resolved": "https://registry.npmjs.org/@octokit/types/-/types-13.5.0.tgz", + "integrity": "sha512-HdqWTf5Z3qwDVlzCrP8UJquMwunpDiMPt5er+QjGzL4hqr/vBVY/MauQgS1xWxCDT1oMx1EULyqxncdCY/NVSQ==", "dev": true, "dependencies": { - "@octokit/openapi-types": "^12.11.0" + "@octokit/openapi-types": "^22.2.0" } }, "node_modules/@open-wc/chai-dom-equals": { @@ -2888,6 +2882,47 @@ "integrity": "sha512-NYrtPht0wGzhwe9+/idPaBB+TqkY9AhTvOLMkThm0IoEfLaiVQZwBwyJ5puCkO3AUCWrmcoePjp2mbFocKy4SQ==", "dev": true }, + "node_modules/@pnpm/config.env-replace": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@pnpm/config.env-replace/-/config.env-replace-1.1.0.tgz", + "integrity": "sha512-htyl8TWnKL7K/ESFa1oW2UB5lVDxuF5DpM7tBi6Hu2LNL3mWkIzNLG6N4zoCUP1lCKNxWy/3iu8mS8MvToGd6w==", + "dev": true, + "engines": { + "node": ">=12.22.0" + } + }, + "node_modules/@pnpm/network.ca-file": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/@pnpm/network.ca-file/-/network.ca-file-1.0.2.tgz", + "integrity": "sha512-YcPQ8a0jwYU9bTdJDpXjMi7Brhkr1mXsXrUJvjqM2mQDgkRiz8jFaQGOdaLxgjtUfQgZhKy/O3cG/YwmgKaxLA==", + "dev": true, + "dependencies": { + "graceful-fs": "4.2.10" + }, + "engines": { + "node": ">=12.22.0" + } + }, + "node_modules/@pnpm/network.ca-file/node_modules/graceful-fs": { + "version": "4.2.10", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.10.tgz", + "integrity": "sha512-9ByhssR2fPVsNZj478qUUbKfmL0+t5BDVyjShtyZZLiK7ZDAArFFfopyOTj0M05wE2tJPisA4iTnnXl2YoPvOA==", + "dev": true + }, + "node_modules/@pnpm/npm-conf": { + "version": "2.2.2", + "resolved": "https://registry.npmjs.org/@pnpm/npm-conf/-/npm-conf-2.2.2.tgz", + "integrity": "sha512-UA91GwWPhFExt3IizW6bOeY/pQ0BkuNwKjk9iQW9KqxluGCrg4VenZ0/L+2Y0+ZOtme72EVvg6v0zo3AMQRCeA==", + "dev": true, + "dependencies": { + "@pnpm/config.env-replace": "^1.1.0", + "@pnpm/network.ca-file": "^1.0.1", + "config-chain": "^1.1.11" + }, + "engines": { + "node": ">=12" + } + }, "node_modules/@polymer/iron-a11y-announcer": { "version": "3.2.0", "resolved": "https://registry.npmjs.org/@polymer/iron-a11y-announcer/-/iron-a11y-announcer-3.2.0.tgz", @@ -3161,265 +3196,562 @@ "integrity": "sha512-1fMXF3YP4pZZVozF8j/ZLfvnR8NSIljt56UhbZ5PeeDmmGHpgpdwQt7ITlGvYaQukCvuBRMLEiKiYC+oeIg4cg==", "dev": true }, + "node_modules/@sec-ant/readable-stream": { + "version": "0.4.1", + "resolved": "https://registry.npmjs.org/@sec-ant/readable-stream/-/readable-stream-0.4.1.tgz", + "integrity": "sha512-831qok9r2t8AlxLko40y2ebgSDhenenCatLVeW/uBtnHPyhHOvG0C7TvfgecV+wHzIm5KUICgzmVpWS+IMEAeg==", + "dev": true + }, "node_modules/@semantic-release/commit-analyzer": { - "version": "8.0.1", - "resolved": "https://registry.npmjs.org/@semantic-release/commit-analyzer/-/commit-analyzer-8.0.1.tgz", - "integrity": "sha512-5bJma/oB7B4MtwUkZC2Bf7O1MHfi4gWe4mA+MIQ3lsEV0b422Bvl1z5HRpplDnMLHH3EXMoRdEng6Ds5wUqA3A==", + "version": "13.0.0", + "resolved": "https://registry.npmjs.org/@semantic-release/commit-analyzer/-/commit-analyzer-13.0.0.tgz", + "integrity": "sha512-KtXWczvTAB1ZFZ6B4O+w8HkfYm/OgQb1dUGNFZtDgQ0csggrmkq8sTxhd+lwGF8kMb59/RnG9o4Tn7M/I8dQ9Q==", "dev": true, "dependencies": { - "conventional-changelog-angular": "^5.0.0", - "conventional-commits-filter": "^2.0.0", - "conventional-commits-parser": "^3.0.7", + "conventional-changelog-angular": "^8.0.0", + "conventional-changelog-writer": "^8.0.0", + "conventional-commits-filter": "^5.0.0", + "conventional-commits-parser": "^6.0.0", "debug": "^4.0.0", - "import-from": "^3.0.0", - "lodash": "^4.17.4", + "import-from-esm": "^1.0.3", + "lodash-es": "^4.17.21", "micromatch": "^4.0.2" }, "engines": { - "node": ">=10.18" + "node": ">=20.8.1" }, "peerDependencies": { - "semantic-release": ">=16.0.0 <18.0.0" + "semantic-release": ">=20.1.0" } }, "node_modules/@semantic-release/error": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/@semantic-release/error/-/error-2.2.0.tgz", - "integrity": "sha512-9Tj/qn+y2j+sjCI3Jd+qseGtHjOAeg7dU2/lVcqIQ9TV3QDaDXDYXcoOHU+7o2Hwh8L8ymL4gfuO7KxDs3q2zg==", - "dev": true + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/@semantic-release/error/-/error-4.0.0.tgz", + "integrity": "sha512-mgdxrHTLOjOddRVYIYDo0fR3/v61GNN1YGkfbrjuIKg/uMgCd+Qzo3UAXJ+woLQQpos4pl5Esuw5A7AoNlzjUQ==", + "dev": true, + "engines": { + "node": ">=18" + } }, "node_modules/@semantic-release/github": { - "version": "7.2.3", - "resolved": "https://registry.npmjs.org/@semantic-release/github/-/github-7.2.3.tgz", - "integrity": "sha512-lWjIVDLal+EQBzy697ayUNN8MoBpp+jYIyW2luOdqn5XBH4d9bQGfTnjuLyzARZBHejqh932HVjiH/j4+R7VHw==", - "dev": true, - "dependencies": { - "@octokit/rest": "^18.0.0", - "@semantic-release/error": "^2.2.0", - "aggregate-error": "^3.0.0", - "bottleneck": "^2.18.1", - "debug": "^4.0.0", - "dir-glob": "^3.0.0", - "fs-extra": "^10.0.0", - "globby": "^11.0.0", - "http-proxy-agent": "^4.0.0", - "https-proxy-agent": "^5.0.0", - "issue-parser": "^6.0.0", - "lodash": "^4.17.4", - "mime": "^2.4.3", - "p-filter": "^2.0.0", - "p-retry": "^4.0.0", - "url-join": "^4.0.0" + "version": "10.0.6", + "resolved": "https://registry.npmjs.org/@semantic-release/github/-/github-10.0.6.tgz", + "integrity": "sha512-sS4psqZacGTFEN49UQGqwFNG6Jyx2/RX1BhhDGn/2WoPbhAHislohOY05/5r+JoL4gJMWycfH7tEm1eGVutYeg==", + "dev": true, + "dependencies": { + "@octokit/core": "^6.0.0", + "@octokit/plugin-paginate-rest": "^11.0.0", + "@octokit/plugin-retry": "^7.0.0", + "@octokit/plugin-throttling": "^9.0.0", + "@semantic-release/error": "^4.0.0", + "aggregate-error": "^5.0.0", + "debug": "^4.3.4", + "dir-glob": "^3.0.1", + "globby": "^14.0.0", + "http-proxy-agent": "^7.0.0", + "https-proxy-agent": "^7.0.0", + "issue-parser": "^7.0.0", + "lodash-es": "^4.17.21", + "mime": "^4.0.0", + "p-filter": "^4.0.0", + "url-join": "^5.0.0" }, "engines": { - "node": ">=10.18" + "node": ">=20.8.1" }, "peerDependencies": { - "semantic-release": ">=16.0.0 <18.0.0" + "semantic-release": ">=20.1.0" } }, - "node_modules/@semantic-release/github/node_modules/fs-extra": { - "version": "10.1.0", - "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-10.1.0.tgz", - "integrity": "sha512-oRXApq54ETRj4eMiFzGnHWGy+zo5raudjuxN0b8H7s/RU2oW0Wvsx9O0ACRN/kRq9E8Vu/ReskGB5o3ji+FzHQ==", + "node_modules/@semantic-release/github/node_modules/agent-base": { + "version": "7.1.1", + "resolved": "https://registry.npmjs.org/agent-base/-/agent-base-7.1.1.tgz", + "integrity": "sha512-H0TSyFNDMomMNJQBn8wFV5YC/2eJ+VXECwOadZJT554xP6cODZHPX3H9QMQECxvrgiSOP1pHjy1sMWQVYJOUOA==", "dev": true, "dependencies": { - "graceful-fs": "^4.2.0", - "jsonfile": "^6.0.1", - "universalify": "^2.0.0" + "debug": "^4.3.4" }, "engines": { - "node": ">=12" + "node": ">= 14" } }, - "node_modules/@semantic-release/npm": { - "version": "7.1.3", - "resolved": "https://registry.npmjs.org/@semantic-release/npm/-/npm-7.1.3.tgz", - "integrity": "sha512-x52kQ/jR09WjuWdaTEHgQCvZYMOTx68WnS+TZ4fya5ZAJw4oRtJETtrvUw10FdfM28d/keInQdc66R1Gw5+OEQ==", + "node_modules/@semantic-release/github/node_modules/aggregate-error": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/aggregate-error/-/aggregate-error-5.0.0.tgz", + "integrity": "sha512-gOsf2YwSlleG6IjRYG2A7k0HmBMEo6qVNk9Bp/EaLgAJT5ngH6PXbqa4ItvnEwCm/velL5jAnQgsHsWnjhGmvw==", "dev": true, "dependencies": { - "@semantic-release/error": "^2.2.0", - "aggregate-error": "^3.0.0", - "execa": "^5.0.0", - "fs-extra": "^10.0.0", - "lodash": "^4.17.15", - "nerf-dart": "^1.0.0", - "normalize-url": "^6.0.0", - "npm": "^7.0.0", - "rc": "^1.2.8", - "read-pkg": "^5.0.0", - "registry-auth-token": "^4.0.0", - "semver": "^7.1.2", - "tempy": "^1.0.0" + "clean-stack": "^5.2.0", + "indent-string": "^5.0.0" }, "engines": { - "node": ">=10.19" + "node": ">=18" }, - "peerDependencies": { - "semantic-release": ">=16.0.0 <18.0.0" + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/@semantic-release/npm/node_modules/execa": { - "version": "5.1.1", - "resolved": "https://registry.npmjs.org/execa/-/execa-5.1.1.tgz", - "integrity": "sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg==", + "node_modules/@semantic-release/github/node_modules/clean-stack": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/clean-stack/-/clean-stack-5.2.0.tgz", + "integrity": "sha512-TyUIUJgdFnCISzG5zu3291TAsE77ddchd0bepon1VVQrKLGKFED4iXFEDQ24mIPdPBbyE16PK3F8MYE1CmcBEQ==", "dev": true, "dependencies": { - "cross-spawn": "^7.0.3", - "get-stream": "^6.0.0", - "human-signals": "^2.1.0", - "is-stream": "^2.0.0", - "merge-stream": "^2.0.0", - "npm-run-path": "^4.0.1", - "onetime": "^5.1.2", - "signal-exit": "^3.0.3", - "strip-final-newline": "^2.0.0" + "escape-string-regexp": "5.0.0" }, "engines": { - "node": ">=10" + "node": ">=14.16" }, "funding": { - "url": "https://github.com/sindresorhus/execa?sponsor=1" + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/@semantic-release/npm/node_modules/fs-extra": { - "version": "10.1.0", - "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-10.1.0.tgz", - "integrity": "sha512-oRXApq54ETRj4eMiFzGnHWGy+zo5raudjuxN0b8H7s/RU2oW0Wvsx9O0ACRN/kRq9E8Vu/ReskGB5o3ji+FzHQ==", + "node_modules/@semantic-release/github/node_modules/escape-string-regexp": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-5.0.0.tgz", + "integrity": "sha512-/veY75JbMK4j1yjvuUxuVsiS/hr/4iHs9FTT6cgTexxdE0Ly/glccBAkloH/DofkjRbZU3bnoj38mOmhkZ0lHw==", "dev": true, - "dependencies": { - "graceful-fs": "^4.2.0", - "jsonfile": "^6.0.1", - "universalify": "^2.0.0" - }, "engines": { "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/@semantic-release/npm/node_modules/human-signals": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-2.1.0.tgz", - "integrity": "sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw==", + "node_modules/@semantic-release/github/node_modules/globby": { + "version": "14.0.1", + "resolved": "https://registry.npmjs.org/globby/-/globby-14.0.1.tgz", + "integrity": "sha512-jOMLD2Z7MAhyG8aJpNOpmziMOP4rPLcc95oQPKXBazW82z+CEgPFBQvEpRUa1KeIMUJo4Wsm+q6uzO/Q/4BksQ==", "dev": true, + "dependencies": { + "@sindresorhus/merge-streams": "^2.1.0", + "fast-glob": "^3.3.2", + "ignore": "^5.2.4", + "path-type": "^5.0.0", + "slash": "^5.1.0", + "unicorn-magic": "^0.1.0" + }, "engines": { - "node": ">=10.17.0" + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/@semantic-release/npm/node_modules/lru-cache": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", - "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", + "node_modules/@semantic-release/github/node_modules/http-proxy-agent": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/http-proxy-agent/-/http-proxy-agent-7.0.2.tgz", + "integrity": "sha512-T1gkAiYYDWYx3V5Bmyu7HcfcvL7mUrTWiM6yOfa3PIphViJ/gFPbvidQ+veqSOHci/PxBcDabeUNCzpOODJZig==", "dev": true, "dependencies": { - "yallist": "^4.0.0" + "agent-base": "^7.1.0", + "debug": "^4.3.4" }, "engines": { - "node": ">=10" + "node": ">= 14" } }, - "node_modules/@semantic-release/npm/node_modules/semver": { - "version": "7.5.4", - "resolved": "https://registry.npmjs.org/semver/-/semver-7.5.4.tgz", - "integrity": "sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA==", + "node_modules/@semantic-release/github/node_modules/https-proxy-agent": { + "version": "7.0.4", + "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-7.0.4.tgz", + "integrity": "sha512-wlwpilI7YdjSkWaQ/7omYBMTliDcmCN8OLihO6I9B86g06lMyAoqgoDpV0XqoaPOKj+0DIdAvnsWfyAAhmimcg==", "dev": true, "dependencies": { - "lru-cache": "^6.0.0" + "agent-base": "^7.0.2", + "debug": "4" }, - "bin": { - "semver": "bin/semver.js" + "engines": { + "node": ">= 14" + } + }, + "node_modules/@semantic-release/github/node_modules/indent-string": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/indent-string/-/indent-string-5.0.0.tgz", + "integrity": "sha512-m6FAo/spmsW2Ab2fU35JTYwtOKa2yAwXSwgjSv1TJzh4Mh7mC3lzAOVLBprb72XsTrgkEIsl7YrFNAiDiRhIGg==", + "dev": true, + "engines": { + "node": ">=12" }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/@semantic-release/github/node_modules/path-type": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/path-type/-/path-type-5.0.0.tgz", + "integrity": "sha512-5HviZNaZcfqP95rwpv+1HDgUamezbqdSYTyzjTvwtJSnIH+3vnbmWsItli8OFEndS984VT55M3jduxZbX351gg==", + "dev": true, "engines": { - "node": ">=10" + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/@semantic-release/npm/node_modules/yallist": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", - "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==", - "dev": true + "node_modules/@semantic-release/github/node_modules/slash": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/slash/-/slash-5.1.0.tgz", + "integrity": "sha512-ZA6oR3T/pEyuqwMgAKT0/hAv8oAXckzbkmR0UkUosQ+Mc4RxGoJkRmwHgHufaenlyAgE1Mxgpdcrf75y6XcnDg==", + "dev": true, + "engines": { + "node": ">=14.16" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } }, - "node_modules/@semantic-release/release-notes-generator": { - "version": "9.0.3", - "resolved": "https://registry.npmjs.org/@semantic-release/release-notes-generator/-/release-notes-generator-9.0.3.tgz", - "integrity": "sha512-hMZyddr0u99OvM2SxVOIelHzly+PP3sYtJ8XOLHdMp8mrluN5/lpeTnIO27oeCYdupY/ndoGfvrqDjHqkSyhVg==", + "node_modules/@semantic-release/npm": { + "version": "12.0.1", + "resolved": "https://registry.npmjs.org/@semantic-release/npm/-/npm-12.0.1.tgz", + "integrity": "sha512-/6nntGSUGK2aTOI0rHPwY3ZjgY9FkXmEHbW9Kr+62NVOsyqpKKeP0lrCH+tphv+EsNdJNmqqwijTEnVWUMQ2Nw==", "dev": true, "dependencies": { - "conventional-changelog-angular": "^5.0.0", - "conventional-changelog-writer": "^4.0.0", - "conventional-commits-filter": "^2.0.0", - "conventional-commits-parser": "^3.0.0", - "debug": "^4.0.0", - "get-stream": "^6.0.0", - "import-from": "^3.0.0", - "into-stream": "^6.0.0", - "lodash": "^4.17.4", - "read-pkg-up": "^7.0.0" + "@semantic-release/error": "^4.0.0", + "aggregate-error": "^5.0.0", + "execa": "^9.0.0", + "fs-extra": "^11.0.0", + "lodash-es": "^4.17.21", + "nerf-dart": "^1.0.0", + "normalize-url": "^8.0.0", + "npm": "^10.5.0", + "rc": "^1.2.8", + "read-pkg": "^9.0.0", + "registry-auth-token": "^5.0.0", + "semver": "^7.1.2", + "tempy": "^3.0.0" }, "engines": { - "node": ">=10.18" + "node": ">=20.8.1" }, "peerDependencies": { - "semantic-release": ">=15.8.0 <18.0.0" + "semantic-release": ">=20.1.0" } }, - "node_modules/@sinonjs/commons": { - "version": "1.8.6", - "resolved": "https://registry.npmjs.org/@sinonjs/commons/-/commons-1.8.6.tgz", - "integrity": "sha512-Ky+XkAkqPZSm3NLBeUng77EBQl3cmeJhITaGHdYH8kjVB+aun3S4XBRti2zt17mtt0mIUDiNxYeoJm6drVvBJQ==", + "node_modules/@semantic-release/npm/node_modules/@sindresorhus/merge-streams": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/@sindresorhus/merge-streams/-/merge-streams-4.0.0.tgz", + "integrity": "sha512-tlqY9xq5ukxTUZBmoOp+m61cqwQD5pHJtFY3Mn8CA8ps6yghLH/Hw8UPdqg4OLmFW3IFlcXnQNmo/dh8HzXYIQ==", "dev": true, - "dependencies": { - "type-detect": "4.0.8" + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/@sinonjs/fake-timers": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/@sinonjs/fake-timers/-/fake-timers-6.0.1.tgz", - "integrity": "sha512-MZPUxrmFubI36XS1DI3qmI0YdN1gks62JtFZvxR67ljjSNCeK6U08Zx4msEWOXuofgqUt6zPHSi1H9fbjR/NRA==", + "node_modules/@semantic-release/npm/node_modules/aggregate-error": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/aggregate-error/-/aggregate-error-5.0.0.tgz", + "integrity": "sha512-gOsf2YwSlleG6IjRYG2A7k0HmBMEo6qVNk9Bp/EaLgAJT5ngH6PXbqa4ItvnEwCm/velL5jAnQgsHsWnjhGmvw==", "dev": true, "dependencies": { - "@sinonjs/commons": "^1.7.0" + "clean-stack": "^5.2.0", + "indent-string": "^5.0.0" + }, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/@sinonjs/samsam": { - "version": "5.3.1", - "resolved": "https://registry.npmjs.org/@sinonjs/samsam/-/samsam-5.3.1.tgz", - "integrity": "sha512-1Hc0b1TtyfBu8ixF/tpfSHTVWKwCBLY4QJbkgnE7HcwyvT2xArDxb4K7dMgqRm3szI+LJbzmW/s4xxEhv6hwDg==", + "node_modules/@semantic-release/npm/node_modules/clean-stack": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/clean-stack/-/clean-stack-5.2.0.tgz", + "integrity": "sha512-TyUIUJgdFnCISzG5zu3291TAsE77ddchd0bepon1VVQrKLGKFED4iXFEDQ24mIPdPBbyE16PK3F8MYE1CmcBEQ==", "dev": true, "dependencies": { - "@sinonjs/commons": "^1.6.0", - "lodash.get": "^4.4.2", - "type-detect": "^4.0.8" + "escape-string-regexp": "5.0.0" + }, + "engines": { + "node": ">=14.16" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/@sinonjs/text-encoding": { - "version": "0.7.2", - "resolved": "https://registry.npmjs.org/@sinonjs/text-encoding/-/text-encoding-0.7.2.tgz", - "integrity": "sha512-sXXKG+uL9IrKqViTtao2Ws6dy0znu9sOaP1di/jKGW1M6VssO8vlpXCQcpZ+jisQ1tTFAC5Jo/EOzFbggBagFQ==", - "dev": true + "node_modules/@semantic-release/npm/node_modules/escape-string-regexp": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-5.0.0.tgz", + "integrity": "sha512-/veY75JbMK4j1yjvuUxuVsiS/hr/4iHs9FTT6cgTexxdE0Ly/glccBAkloH/DofkjRbZU3bnoj38mOmhkZ0lHw==", + "dev": true, + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } }, - "node_modules/@storybook/csf": { - "version": "0.0.2--canary.4566f4d.1", - "resolved": "https://registry.npmjs.org/@storybook/csf/-/csf-0.0.2--canary.4566f4d.1.tgz", - "integrity": "sha512-9OVvMVh3t9znYZwb0Svf/YQoxX2gVOeQTGe2bses2yj+a3+OJnCrUF3/hGv6Em7KujtOdL2LL+JnG49oMVGFgQ==", + "node_modules/@semantic-release/npm/node_modules/execa": { + "version": "9.3.0", + "resolved": "https://registry.npmjs.org/execa/-/execa-9.3.0.tgz", + "integrity": "sha512-l6JFbqnHEadBoVAVpN5dl2yCyfX28WoBAGaoQcNmLLSedOxTxcn2Qa83s8I/PA5i56vWru2OHOtrwF7Om2vqlg==", "dev": true, "dependencies": { - "lodash": "^4.17.15" + "@sindresorhus/merge-streams": "^4.0.0", + "cross-spawn": "^7.0.3", + "figures": "^6.1.0", + "get-stream": "^9.0.0", + "human-signals": "^7.0.0", + "is-plain-obj": "^4.1.0", + "is-stream": "^4.0.1", + "npm-run-path": "^5.2.0", + "pretty-ms": "^9.0.0", + "signal-exit": "^4.1.0", + "strip-final-newline": "^4.0.0", + "yoctocolors": "^2.0.0" + }, + "engines": { + "node": "^18.19.0 || >=20.5.0" + }, + "funding": { + "url": "https://github.com/sindresorhus/execa?sponsor=1" } }, - "node_modules/@storybook/csf-tools": { - "version": "6.5.16", - "resolved": "https://registry.npmjs.org/@storybook/csf-tools/-/csf-tools-6.5.16.tgz", - "integrity": "sha512-+WD4sH/OwAfXZX3IN6/LOZ9D9iGEFcN+Vvgv9wOsLRgsAZ10DG/NK6c1unXKDM/ogJtJYccNI8Hd+qNE/GFV6A==", + "node_modules/@semantic-release/npm/node_modules/fs-extra": { + "version": "11.2.0", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-11.2.0.tgz", + "integrity": "sha512-PmDi3uwK5nFuXh7XDTlVnS17xJS7vW36is2+w3xcv8SVxiB4NyATf4ctkVY5bkSjX0Y4nbvZCq1/EjtEyr9ktw==", "dev": true, "dependencies": { - "@babel/core": "^7.12.10", - "@babel/generator": "^7.12.11", - "@babel/parser": "^7.12.11", - "@babel/plugin-transform-react-jsx": "^7.12.12", - "@babel/preset-env": "^7.12.11", - "@babel/traverse": "^7.12.11", - "@babel/types": "^7.12.11", - "@storybook/csf": "0.0.2--canary.4566f4d.1", + "graceful-fs": "^4.2.0", + "jsonfile": "^6.0.1", + "universalify": "^2.0.0" + }, + "engines": { + "node": ">=14.14" + } + }, + "node_modules/@semantic-release/npm/node_modules/get-stream": { + "version": "9.0.1", + "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-9.0.1.tgz", + "integrity": "sha512-kVCxPF3vQM/N0B1PmoqVUqgHP+EeVjmZSQn+1oCRPxd2P21P2F19lIgbR3HBosbB1PUhOAoctJnfEn2GbN2eZA==", + "dev": true, + "dependencies": { + "@sec-ant/readable-stream": "^0.4.1", + "is-stream": "^4.0.1" + }, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/@semantic-release/npm/node_modules/human-signals": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-7.0.0.tgz", + "integrity": "sha512-74kytxOUSvNbjrT9KisAbaTZ/eJwD/LrbM/kh5j0IhPuJzwuA19dWvniFGwBzN9rVjg+O/e+F310PjObDXS+9Q==", + "dev": true, + "engines": { + "node": ">=18.18.0" + } + }, + "node_modules/@semantic-release/npm/node_modules/indent-string": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/indent-string/-/indent-string-5.0.0.tgz", + "integrity": "sha512-m6FAo/spmsW2Ab2fU35JTYwtOKa2yAwXSwgjSv1TJzh4Mh7mC3lzAOVLBprb72XsTrgkEIsl7YrFNAiDiRhIGg==", + "dev": true, + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/@semantic-release/npm/node_modules/is-stream": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-4.0.1.tgz", + "integrity": "sha512-Dnz92NInDqYckGEUJv689RbRiTSEHCQ7wOVeALbkOz999YpqT46yMRIGtSNl2iCL1waAZSx40+h59NV/EwzV/A==", + "dev": true, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/@semantic-release/npm/node_modules/npm-run-path": { + "version": "5.3.0", + "resolved": "https://registry.npmjs.org/npm-run-path/-/npm-run-path-5.3.0.tgz", + "integrity": "sha512-ppwTtiJZq0O/ai0z7yfudtBpWIoxM8yE6nHi1X47eFR2EWORqfbu6CnPlNsjeN683eT0qG6H/Pyf9fCcvjnnnQ==", + "dev": true, + "dependencies": { + "path-key": "^4.0.0" + }, + "engines": { + "node": "^12.20.0 || ^14.13.1 || >=16.0.0" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/@semantic-release/npm/node_modules/path-key": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/path-key/-/path-key-4.0.0.tgz", + "integrity": "sha512-haREypq7xkM7ErfgIyA0z+Bj4AGKlMSdlQE2jvJo6huWD1EdkKYV+G/T4nq0YEF2vgTT8kqMFKo1uHn950r4SQ==", + "dev": true, + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/@semantic-release/npm/node_modules/semver": { + "version": "7.6.2", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.6.2.tgz", + "integrity": "sha512-FNAIBWCx9qcRhoHcgcJ0gvU7SN1lYU2ZXuSfl04bSC5OpvDHFyJCjdNHomPXxjQlCBU67YW64PzY7/VIEH7F2w==", + "dev": true, + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/@semantic-release/npm/node_modules/signal-exit": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-4.1.0.tgz", + "integrity": "sha512-bzyZ1e88w9O1iNJbKnOlvYTrWPDl46O1bG0D3XInv+9tkPrxrN8jUUTiFlDkkmKWgn1M6CfIA13SuGqOa9Korw==", + "dev": true, + "engines": { + "node": ">=14" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "node_modules/@semantic-release/npm/node_modules/strip-final-newline": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/strip-final-newline/-/strip-final-newline-4.0.0.tgz", + "integrity": "sha512-aulFJcD6YK8V1G7iRB5tigAP4TsHBZZrOV8pjV++zdUwmeV8uzbY7yn6h9MswN62adStNZFuCIx4haBnRuMDaw==", + "dev": true, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/@semantic-release/release-notes-generator": { + "version": "14.0.1", + "resolved": "https://registry.npmjs.org/@semantic-release/release-notes-generator/-/release-notes-generator-14.0.1.tgz", + "integrity": "sha512-K0w+5220TM4HZTthE5dDpIuFrnkN1NfTGPidJFm04ULT1DEZ9WG89VNXN7F0c+6nMEpWgqmPvb7vY7JkB2jyyA==", + "dev": true, + "dependencies": { + "conventional-changelog-angular": "^8.0.0", + "conventional-changelog-writer": "^8.0.0", + "conventional-commits-filter": "^5.0.0", + "conventional-commits-parser": "^6.0.0", + "debug": "^4.0.0", + "get-stream": "^7.0.0", + "import-from-esm": "^1.0.3", + "into-stream": "^7.0.0", + "lodash-es": "^4.17.21", + "read-package-up": "^11.0.0" + }, + "engines": { + "node": ">=20.8.1" + }, + "peerDependencies": { + "semantic-release": ">=20.1.0" + } + }, + "node_modules/@semantic-release/release-notes-generator/node_modules/get-stream": { + "version": "7.0.1", + "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-7.0.1.tgz", + "integrity": "sha512-3M8C1EOFN6r8AMUhwUAACIoXZJEOufDU5+0gFFN5uNs6XYOralD2Pqkl7m046va6x77FwposWXbAhPPIOus7mQ==", + "dev": true, + "engines": { + "node": ">=16" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/@sindresorhus/is": { + "version": "4.6.0", + "resolved": "https://registry.npmjs.org/@sindresorhus/is/-/is-4.6.0.tgz", + "integrity": "sha512-t09vSN3MdfsyCHoFcTRCH/iUtG7OJ0CsjzB8cjAmKc/va/kIgeDI/TxsigdncE/4be734m0cvIYwNaV4i2XqAw==", + "dev": true, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sindresorhus/is?sponsor=1" + } + }, + "node_modules/@sindresorhus/merge-streams": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/@sindresorhus/merge-streams/-/merge-streams-2.3.0.tgz", + "integrity": "sha512-LtoMMhxAlorcGhmFYI+LhPgbPZCkgP6ra1YL604EeF6U98pLlQ3iWIGMdWSC+vWmPBWBNgmDBAhnAobLROJmwg==", + "dev": true, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/@sinonjs/commons": { + "version": "1.8.6", + "resolved": "https://registry.npmjs.org/@sinonjs/commons/-/commons-1.8.6.tgz", + "integrity": "sha512-Ky+XkAkqPZSm3NLBeUng77EBQl3cmeJhITaGHdYH8kjVB+aun3S4XBRti2zt17mtt0mIUDiNxYeoJm6drVvBJQ==", + "dev": true, + "dependencies": { + "type-detect": "4.0.8" + } + }, + "node_modules/@sinonjs/fake-timers": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/@sinonjs/fake-timers/-/fake-timers-6.0.1.tgz", + "integrity": "sha512-MZPUxrmFubI36XS1DI3qmI0YdN1gks62JtFZvxR67ljjSNCeK6U08Zx4msEWOXuofgqUt6zPHSi1H9fbjR/NRA==", + "dev": true, + "dependencies": { + "@sinonjs/commons": "^1.7.0" + } + }, + "node_modules/@sinonjs/samsam": { + "version": "5.3.1", + "resolved": "https://registry.npmjs.org/@sinonjs/samsam/-/samsam-5.3.1.tgz", + "integrity": "sha512-1Hc0b1TtyfBu8ixF/tpfSHTVWKwCBLY4QJbkgnE7HcwyvT2xArDxb4K7dMgqRm3szI+LJbzmW/s4xxEhv6hwDg==", + "dev": true, + "dependencies": { + "@sinonjs/commons": "^1.6.0", + "lodash.get": "^4.4.2", + "type-detect": "^4.0.8" + } + }, + "node_modules/@sinonjs/text-encoding": { + "version": "0.7.2", + "resolved": "https://registry.npmjs.org/@sinonjs/text-encoding/-/text-encoding-0.7.2.tgz", + "integrity": "sha512-sXXKG+uL9IrKqViTtao2Ws6dy0znu9sOaP1di/jKGW1M6VssO8vlpXCQcpZ+jisQ1tTFAC5Jo/EOzFbggBagFQ==", + "dev": true + }, + "node_modules/@storybook/csf": { + "version": "0.0.2--canary.4566f4d.1", + "resolved": "https://registry.npmjs.org/@storybook/csf/-/csf-0.0.2--canary.4566f4d.1.tgz", + "integrity": "sha512-9OVvMVh3t9znYZwb0Svf/YQoxX2gVOeQTGe2bses2yj+a3+OJnCrUF3/hGv6Em7KujtOdL2LL+JnG49oMVGFgQ==", + "dev": true, + "dependencies": { + "lodash": "^4.17.15" + } + }, + "node_modules/@storybook/csf-tools": { + "version": "6.5.16", + "resolved": "https://registry.npmjs.org/@storybook/csf-tools/-/csf-tools-6.5.16.tgz", + "integrity": "sha512-+WD4sH/OwAfXZX3IN6/LOZ9D9iGEFcN+Vvgv9wOsLRgsAZ10DG/NK6c1unXKDM/ogJtJYccNI8Hd+qNE/GFV6A==", + "dev": true, + "dependencies": { + "@babel/core": "^7.12.10", + "@babel/generator": "^7.12.11", + "@babel/parser": "^7.12.11", + "@babel/plugin-transform-react-jsx": "^7.12.12", + "@babel/preset-env": "^7.12.11", + "@babel/traverse": "^7.12.11", + "@babel/types": "^7.12.11", + "@storybook/csf": "0.0.2--canary.4566f4d.1", "@storybook/mdx1-csf": "^0.0.1", "core-js": "^3.8.2", "fs-extra": "^9.0.1", @@ -3771,12 +4103,6 @@ "integrity": "sha512-K0VQKziLUWkVKiRVrx4a40iPaxTUefQmjtkQofBkYRcoaaL/8rhwDWww9qWbrgicNOgnpIsMxyNIUM4+n6dUIA==", "dev": true }, - "node_modules/@types/minimist": { - "version": "1.2.3", - "resolved": "https://registry.npmjs.org/@types/minimist/-/minimist-1.2.3.tgz", - "integrity": "sha512-ZYFzrvyWUNhaPomn80dsMNgMeXxNWZBdkuG/hWlUvXvbdUH8ZERNBGXnU87McuGcWDsyzX2aChCv/SVN348k3A==", - "dev": true - }, "node_modules/@types/mocha": { "version": "8.2.3", "resolved": "https://registry.npmjs.org/@types/mocha/-/mocha-8.2.3.tgz", @@ -3789,9 +4115,9 @@ "integrity": "sha512-fAtCfv4jJg+ExtXhvCkCqUKZ+4ok/JQk01qDKhL5BDDoS3AxKXhV5/MAVUZyQnSEd2GT92fkgZl0pz0Q0AzcIQ==" }, "node_modules/@types/normalize-package-data": { - "version": "2.4.2", - "resolved": "https://registry.npmjs.org/@types/normalize-package-data/-/normalize-package-data-2.4.2.tgz", - "integrity": "sha512-lqa4UEhhv/2sjjIQgjX8B+RBjj47eo0mzGasklVJ78UKGQY1r0VpB9XHDaZZO9qzEFDdy4MrXLuEaSmPrPSe/A==", + "version": "2.4.4", + "resolved": "https://registry.npmjs.org/@types/normalize-package-data/-/normalize-package-data-2.4.4.tgz", + "integrity": "sha512-37i+OaWTh9qeK4LSHPsyRC7NahnGotNuZvjLSgcPzblpHB3rrCJxAOgI5gCdKm7coonsaX1Of0ILiTcnZjbfxA==", "dev": true }, "node_modules/@types/parse-json": { @@ -3838,10 +4164,10 @@ "@types/node": "*" } }, - "node_modules/@types/retry": { - "version": "0.12.0", - "resolved": "https://registry.npmjs.org/@types/retry/-/retry-0.12.0.tgz", - "integrity": "sha512-wWKOClTTiizcZhXnPY4wikVAwmdYHp8q6DmC+EJUzAMsycb7HB32Kh9RN4+0gExjmPmZSAQjgURXIGATPegAvA==", + "node_modules/@types/semver": { + "version": "7.5.8", + "resolved": "https://registry.npmjs.org/@types/semver/-/semver-7.5.8.tgz", + "integrity": "sha512-I8EUhyrgfLrcTkzV3TSsGyl1tSuPrEDzr0yd5m90UgNxQkyDXULk3b6MlQqTCpZpNtWe1K0hzclnZkTcLBe2UQ==", "dev": true }, "node_modules/@types/send": { @@ -5748,10 +6074,10 @@ "node": ">=4" } }, - "node_modules/ansicolors": { - "version": "0.3.2", - "resolved": "https://registry.npmjs.org/ansicolors/-/ansicolors-0.3.2.tgz", - "integrity": "sha512-QXu7BPrP29VllRxH8GwB7x5iX5qWKAAMLqKQGWTeLWVlNHNOpVMJ91dsxQAIWXpjuW5wqvxu3Jd/nRjrJ+0pqg==", + "node_modules/any-promise": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/any-promise/-/any-promise-1.3.0.tgz", + "integrity": "sha512-7UvmKalWRt1wgjL1RrGxoSJW/0QZFIegpeGvZG9kjp8vrRu55XTHbwnqq2GpXm9uLbcuhxm3IqX9OB4MZR1b2A==", "dev": true }, "node_modules/anymatch": { @@ -5939,15 +6265,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/arrify": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/arrify/-/arrify-1.0.1.tgz", - "integrity": "sha512-3CYzex9M9FGQjCGMGyi6/31c8GJbgb0qGyrx5HWxPd0aCwh4cB2YjMb2Xf9UuoogrMrlO9cTqnB5rI5GHZTcUA==", - "dev": true, - "engines": { - "node": ">=0.10.0" - } - }, "node_modules/assertion-error": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/assertion-error/-/assertion-error-1.1.0.tgz", @@ -6292,9 +6609,9 @@ ] }, "node_modules/before-after-hook": { - "version": "2.2.3", - "resolved": "https://registry.npmjs.org/before-after-hook/-/before-after-hook-2.2.3.tgz", - "integrity": "sha512-NzUnlZexiaH/46WDhANlyR2bXRopNg4F/zuSA3OpZnllCUgRaOF2znDioDWrmbNVsuZk6l9pMquQB38cfBZwkQ==", + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/before-after-hook/-/before-after-hook-3.0.2.tgz", + "integrity": "sha512-Nik3Sc0ncrMK4UUdXQmAnRtzmNQTAAXmXIopizwZ1W1t8QmfJj+zL4OA2I7XPTPW5z5TDqv4hRo/JzouDJnX3A==", "dev": true }, "node_modules/big.js": { @@ -6543,32 +6860,6 @@ "node": ">= 6" } }, - "node_modules/camelcase-keys": { - "version": "6.2.2", - "resolved": "https://registry.npmjs.org/camelcase-keys/-/camelcase-keys-6.2.2.tgz", - "integrity": "sha512-YrwaA0vEKazPBkn0ipTiMpSajYDSe+KjQfrjhcBMxJt/znbvlHd8Pw/Vamaz5EB4Wfhs3SUR3Z9mwRu/P3s3Yg==", - "dev": true, - "dependencies": { - "camelcase": "^5.3.1", - "map-obj": "^4.0.0", - "quick-lru": "^4.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/camelcase-keys/node_modules/camelcase": { - "version": "5.3.1", - "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-5.3.1.tgz", - "integrity": "sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==", - "dev": true, - "engines": { - "node": ">=6" - } - }, "node_modules/caniuse-lite": { "version": "1.0.30001547", "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001547.tgz", @@ -6600,19 +6891,6 @@ "upper-case-first": "^2.0.2" } }, - "node_modules/cardinal": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/cardinal/-/cardinal-2.1.1.tgz", - "integrity": "sha512-JSr5eOgoEymtYHBjNWyjrMqet9Am2miJhlfKNdqLp6zoeAh0KN5dRAcxlecj5mAJrmQomgiOBj35xHLrFjqBpw==", - "dev": true, - "dependencies": { - "ansicolors": "~0.3.2", - "redeyed": "~2.1.0" - }, - "bin": { - "cdl": "bin/cdl.js" - } - }, "node_modules/ccount": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/ccount/-/ccount-1.1.0.tgz", @@ -6782,6 +7060,15 @@ "tslib": "^2.0.3" } }, + "node_modules/char-regex": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/char-regex/-/char-regex-1.0.2.tgz", + "integrity": "sha512-kWWXztvZ5SBQV+eRgKFeh8q5sLuZY2+8WUIzlxWVTg+oGwY14qylx1KbKzHd8P6ZYkAg0xyIDU9JMHhyJMZ1jw==", + "dev": true, + "engines": { + "node": ">=10" + } + }, "node_modules/character-entities": { "version": "1.2.4", "resolved": "https://registry.npmjs.org/character-entities/-/character-entities-1.2.4.tgz", @@ -6950,44 +7237,188 @@ "node": ">=8" } }, - "node_modules/cli-table3": { - "version": "0.6.3", - "resolved": "https://registry.npmjs.org/cli-table3/-/cli-table3-0.6.3.tgz", - "integrity": "sha512-w5Jac5SykAeZJKntOxJCrm63Eg5/4dhMWIcuTbo9rpE+brgaSZo0RuNJZeOyMgsUdhDeojvgyQLmjI+K50ZGyg==", + "node_modules/cli-highlight": { + "version": "2.1.11", + "resolved": "https://registry.npmjs.org/cli-highlight/-/cli-highlight-2.1.11.tgz", + "integrity": "sha512-9KDcoEVwyUXrjcJNvHD0NFc/hiwe/WPVYIleQh2O1N2Zro5gWJZ/K+3DGn8w8P/F6FxOgzyC5bxDyHIgCSPhGg==", "dev": true, "dependencies": { - "string-width": "^4.2.0" + "chalk": "^4.0.0", + "highlight.js": "^10.7.1", + "mz": "^2.4.0", + "parse5": "^5.1.1", + "parse5-htmlparser2-tree-adapter": "^6.0.0", + "yargs": "^16.0.0" }, - "engines": { - "node": "10.* || >= 12.*" + "bin": { + "highlight": "bin/highlight" }, - "optionalDependencies": { - "@colors/colors": "1.5.0" + "engines": { + "node": ">=8.0.0", + "npm": ">=5.0.0" } }, - "node_modules/cli-truncate": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/cli-truncate/-/cli-truncate-2.1.0.tgz", - "integrity": "sha512-n8fOixwDD6b/ObinzTrp1ZKFzbgvKZvuz/TvejnLn1aQfC6r52XEx85FmuC+3HI+JM7coBRXUvNqEU2PHVrHpg==", + "node_modules/cli-highlight/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, "dependencies": { - "slice-ansi": "^3.0.0", - "string-width": "^4.2.0" + "color-convert": "^2.0.1" }, "engines": { "node": ">=8" }, "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, - "node_modules/cliui": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/cliui/-/cliui-5.0.0.tgz", - "integrity": "sha512-PYeGSEmmHM6zvoef2w8TPzlrnNpXIjTipYK780YswmIP9vjxmd6Y2a3CB2Ks6/AU8NHjZugXvo8w3oWM2qnwXA==", + "node_modules/cli-highlight/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, "dependencies": { - "string-width": "^3.1.0", + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/cli-highlight/node_modules/cliui": { + "version": "7.0.4", + "resolved": "https://registry.npmjs.org/cliui/-/cliui-7.0.4.tgz", + "integrity": "sha512-OcRE68cOsVMXp1Yvonl/fzkQOyjLSu/8bhPDfQt0e0/Eb283TKP20Fs2MqoPsr9SwA595rRCA+QMzYc9nBP+JQ==", + "dev": true, + "dependencies": { + "string-width": "^4.2.0", + "strip-ansi": "^6.0.0", + "wrap-ansi": "^7.0.0" + } + }, + "node_modules/cli-highlight/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/cli-highlight/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true + }, + "node_modules/cli-highlight/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/cli-highlight/node_modules/parse5": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/parse5/-/parse5-5.1.1.tgz", + "integrity": "sha512-ugq4DFI0Ptb+WWjAdOK16+u/nHfiIrcE+sh8kZMaM0WllQKLI9rOUq6c2b7cwPkXdzfQESqvoqK6ug7U/Yyzug==", + "dev": true + }, + "node_modules/cli-highlight/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dev": true, + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/cli-highlight/node_modules/y18n": { + "version": "5.0.8", + "resolved": "https://registry.npmjs.org/y18n/-/y18n-5.0.8.tgz", + "integrity": "sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA==", + "dev": true, + "engines": { + "node": ">=10" + } + }, + "node_modules/cli-highlight/node_modules/yargs": { + "version": "16.2.0", + "resolved": "https://registry.npmjs.org/yargs/-/yargs-16.2.0.tgz", + "integrity": "sha512-D1mvvtDG0L5ft/jGWkLpG1+m0eQxOfaBvTNELraWj22wSVUMWxZUvYgJYcKh6jGGIkJFhH4IZPQhR4TKpc8mBw==", + "dev": true, + "dependencies": { + "cliui": "^7.0.2", + "escalade": "^3.1.1", + "get-caller-file": "^2.0.5", + "require-directory": "^2.1.1", + "string-width": "^4.2.0", + "y18n": "^5.0.5", + "yargs-parser": "^20.2.2" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/cli-highlight/node_modules/yargs-parser": { + "version": "20.2.9", + "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-20.2.9.tgz", + "integrity": "sha512-y11nGElTIV+CT3Zv9t7VKl+Q3hTQoT9a1Qzezhhl6Rp21gJ/IVTW7Z3y9EWXhuUBC2Shnf+DX0antecpAwSP8w==", + "dev": true, + "engines": { + "node": ">=10" + } + }, + "node_modules/cli-table3": { + "version": "0.6.5", + "resolved": "https://registry.npmjs.org/cli-table3/-/cli-table3-0.6.5.tgz", + "integrity": "sha512-+W/5efTR7y5HRD7gACw9yQjqMVvEMLBHmboM/kPWam+H+Hmyrgjh6YncVKK122YZkXrLudzTuAukUw9FnMf7IQ==", + "dev": true, + "dependencies": { + "string-width": "^4.2.0" + }, + "engines": { + "node": "10.* || >= 12.*" + }, + "optionalDependencies": { + "@colors/colors": "1.5.0" + } + }, + "node_modules/cli-truncate": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/cli-truncate/-/cli-truncate-2.1.0.tgz", + "integrity": "sha512-n8fOixwDD6b/ObinzTrp1ZKFzbgvKZvuz/TvejnLn1aQfC6r52XEx85FmuC+3HI+JM7coBRXUvNqEU2PHVrHpg==", + "dev": true, + "dependencies": { + "slice-ansi": "^3.0.0", + "string-width": "^4.2.0" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/cliui": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/cliui/-/cliui-5.0.0.tgz", + "integrity": "sha512-PYeGSEmmHM6zvoef2w8TPzlrnNpXIjTipYK780YswmIP9vjxmd6Y2a3CB2Ks6/AU8NHjZugXvo8w3oWM2qnwXA==", + "dev": true, + "dependencies": { + "string-width": "^3.1.0", "strip-ansi": "^5.2.0", "wrap-ansi": "^5.1.0" } @@ -7265,6 +7696,16 @@ "integrity": "sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==", "dev": true }, + "node_modules/config-chain": { + "version": "1.1.13", + "resolved": "https://registry.npmjs.org/config-chain/-/config-chain-1.1.13.tgz", + "integrity": "sha512-qj+f8APARXHrM0hraqXYb2/bOVSV4PvJQlNZ/DVj0QrmNM2q2euizkeuVckQ57J+W0mRH6Hvi+k50M4Jul2VRQ==", + "dev": true, + "dependencies": { + "ini": "^1.3.4", + "proto-list": "~1.2.1" + } + }, "node_modules/confusing-browser-globals": { "version": "1.0.11", "resolved": "https://registry.npmjs.org/confusing-browser-globals/-/confusing-browser-globals-1.0.11.tgz", @@ -7315,73 +7756,82 @@ } }, "node_modules/conventional-changelog-angular": { - "version": "5.0.13", - "resolved": "https://registry.npmjs.org/conventional-changelog-angular/-/conventional-changelog-angular-5.0.13.tgz", - "integrity": "sha512-i/gipMxs7s8L/QeuavPF2hLnJgH6pEZAttySB6aiQLWcX3puWDL3ACVmvBhJGxnAy52Qc15ua26BufY6KpmrVA==", + "version": "8.0.0", + "resolved": "https://registry.npmjs.org/conventional-changelog-angular/-/conventional-changelog-angular-8.0.0.tgz", + "integrity": "sha512-CLf+zr6St0wIxos4bmaKHRXWAcsCXrJU6F4VdNDrGRK3B8LDLKoX3zuMV5GhtbGkVR/LohZ6MT6im43vZLSjmA==", "dev": true, "dependencies": { - "compare-func": "^2.0.0", - "q": "^1.5.1" + "compare-func": "^2.0.0" }, "engines": { - "node": ">=10" + "node": ">=18" } }, "node_modules/conventional-changelog-writer": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/conventional-changelog-writer/-/conventional-changelog-writer-4.1.0.tgz", - "integrity": "sha512-WwKcUp7WyXYGQmkLsX4QmU42AZ1lqlvRW9mqoyiQzdD+rJWbTepdWoKJuwXTS+yq79XKnQNa93/roViPQrAQgw==", + "version": "8.0.0", + "resolved": "https://registry.npmjs.org/conventional-changelog-writer/-/conventional-changelog-writer-8.0.0.tgz", + "integrity": "sha512-TQcoYGRatlAnT2qEWDON/XSfnVG38JzA7E0wcGScu7RElQBkg9WWgZd1peCWFcWDh1xfb2CfsrcvOn1bbSzztA==", "dev": true, "dependencies": { - "compare-func": "^2.0.0", - "conventional-commits-filter": "^2.0.7", - "dateformat": "^3.0.0", - "handlebars": "^4.7.6", - "json-stringify-safe": "^5.0.1", - "lodash": "^4.17.15", - "meow": "^8.0.0", - "semver": "^6.0.0", - "split": "^1.0.0", - "through2": "^4.0.0" + "@types/semver": "^7.5.5", + "conventional-commits-filter": "^5.0.0", + "handlebars": "^4.7.7", + "meow": "^13.0.0", + "semver": "^7.5.2" }, "bin": { - "conventional-changelog-writer": "cli.js" + "conventional-changelog-writer": "dist/cli/index.js" }, "engines": { - "node": ">=10" + "node": ">=18" } }, - "node_modules/conventional-commits-filter": { - "version": "2.0.7", - "resolved": "https://registry.npmjs.org/conventional-commits-filter/-/conventional-commits-filter-2.0.7.tgz", - "integrity": "sha512-ASS9SamOP4TbCClsRHxIHXRfcGCnIoQqkvAzCSbZzTFLfcTqJVugB0agRgsEELsqaeWgsXv513eS116wnlSSPA==", + "node_modules/conventional-changelog-writer/node_modules/semver": { + "version": "7.6.2", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.6.2.tgz", + "integrity": "sha512-FNAIBWCx9qcRhoHcgcJ0gvU7SN1lYU2ZXuSfl04bSC5OpvDHFyJCjdNHomPXxjQlCBU67YW64PzY7/VIEH7F2w==", "dev": true, - "dependencies": { - "lodash.ismatch": "^4.4.0", - "modify-values": "^1.0.0" + "bin": { + "semver": "bin/semver.js" }, "engines": { "node": ">=10" } }, + "node_modules/conventional-commits-filter": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/conventional-commits-filter/-/conventional-commits-filter-5.0.0.tgz", + "integrity": "sha512-tQMagCOC59EVgNZcC5zl7XqO30Wki9i9J3acbUvkaosCT6JX3EeFwJD7Qqp4MCikRnzS18WXV3BLIQ66ytu6+Q==", + "dev": true, + "engines": { + "node": ">=18" + } + }, "node_modules/conventional-commits-parser": { - "version": "3.2.4", - "resolved": "https://registry.npmjs.org/conventional-commits-parser/-/conventional-commits-parser-3.2.4.tgz", - "integrity": "sha512-nK7sAtfi+QXbxHCYfhpZsfRtaitZLIA6889kFIouLvz6repszQDgxBu7wf2WbU+Dco7sAnNCJYERCwt54WPC2Q==", + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/conventional-commits-parser/-/conventional-commits-parser-6.0.0.tgz", + "integrity": "sha512-TbsINLp48XeMXR8EvGjTnKGsZqBemisPoyWESlpRyR8lif0lcwzqz+NMtYSj1ooF/WYjSuu7wX0CtdeeMEQAmA==", "dev": true, "dependencies": { - "is-text-path": "^1.0.1", - "JSONStream": "^1.0.4", - "lodash": "^4.17.15", - "meow": "^8.0.0", - "split2": "^3.0.0", - "through2": "^4.0.0" + "meow": "^13.0.0" }, "bin": { - "conventional-commits-parser": "cli.js" + "conventional-commits-parser": "dist/cli/index.js" }, "engines": { - "node": ">=10" + "node": ">=18" + } + }, + "node_modules/convert-hrtime": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/convert-hrtime/-/convert-hrtime-5.0.0.tgz", + "integrity": "sha512-lOETlkIeYSJWcbbcvjRKGxVMXJR+8+OQb/mTPbA4ObPMytYIsUbuOE0Jzy60hjARYszq1id0j8KgVhC+WGZVTg==", + "dev": true, + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, "node_modules/convert-source-map": { @@ -7493,12 +7943,30 @@ } }, "node_modules/crypto-random-string": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/crypto-random-string/-/crypto-random-string-2.0.0.tgz", - "integrity": "sha512-v1plID3y9r/lPhviJ1wrXpLeyUIGAZ2SHNYTEapm7/8A9nLPoyvVp3RK/EPFqn5kEznyWgYZNsRtYYIWbuG8KA==", + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/crypto-random-string/-/crypto-random-string-4.0.0.tgz", + "integrity": "sha512-x8dy3RnvYdlUcPOjkEHqozhiwzKNSq7GcPuXFbnyMOCHxX8V3OgIg/pYuabl2sbUPfIJaeAQB7PMOK8DFIdoRA==", "dev": true, + "dependencies": { + "type-fest": "^1.0.1" + }, "engines": { - "node": ">=8" + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/crypto-random-string/node_modules/type-fest": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-1.4.0.tgz", + "integrity": "sha512-yGSza74xk0UG8k+pLh5oeoYirvIiWo5t0/o3zHHAO2tRDiZcxWP7fywNlXhqb6/r6sWvwi+RsyQMWhVLe4BVuA==", + "dev": true, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, "node_modules/css-color-names": { @@ -7592,15 +8060,6 @@ "node": ">=10" } }, - "node_modules/dateformat": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/dateformat/-/dateformat-3.0.3.tgz", - "integrity": "sha512-jyCETtSl3VMZMWeRo7iY1FL19ges1t55hMo5yaam4Jrsm5EPL89UQkoQRyiI+Yf4k8r2ZpdngkV8hr1lIdjb3Q==", - "dev": true, - "engines": { - "node": "*" - } - }, "node_modules/debounce": { "version": "1.2.1", "resolved": "https://registry.npmjs.org/debounce/-/debounce-1.2.1.tgz", @@ -7632,31 +8091,6 @@ "node": ">=0.10.0" } }, - "node_modules/decamelize-keys": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/decamelize-keys/-/decamelize-keys-1.1.1.tgz", - "integrity": "sha512-WiPxgEirIV0/eIOMcnFBA3/IJZAZqKnwAwWyvvdi4lsr1WCN22nhdf/3db3DoZcUjTV2SqfzIwNyp6y2xs3nmg==", - "dev": true, - "dependencies": { - "decamelize": "^1.1.0", - "map-obj": "^1.0.0" - }, - "engines": { - "node": ">=0.10.0" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/decamelize-keys/node_modules/map-obj": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/map-obj/-/map-obj-1.0.1.tgz", - "integrity": "sha512-7N/q3lyZ+LVCp7PzuxrJr4KMbBE2hW7BT7YNia330OFxIf4d3r5zVpicP2650l7CPN6RM9zOJRl3NGpqSiw3Eg==", - "dev": true, - "engines": { - "node": ">=0.10.0" - } - }, "node_modules/decimal.js": { "version": "10.4.3", "resolved": "https://registry.npmjs.org/decimal.js/-/decimal.js-10.4.3.tgz", @@ -7758,28 +8192,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/del": { - "version": "6.1.1", - "resolved": "https://registry.npmjs.org/del/-/del-6.1.1.tgz", - "integrity": "sha512-ua8BhapfP0JUJKC/zV9yHHDW/rDoDxP4Zhn3AkA6/xT6gY7jYXJiaeyBZznYVujhZZET+UgcbZiQ7sN3WqcImg==", - "dev": true, - "dependencies": { - "globby": "^11.0.1", - "graceful-fs": "^4.2.4", - "is-glob": "^4.0.1", - "is-path-cwd": "^2.2.0", - "is-path-inside": "^3.0.2", - "p-map": "^4.0.0", - "rimraf": "^3.0.2", - "slash": "^3.0.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, "node_modules/delayed-stream": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", @@ -7812,12 +8224,6 @@ "node": ">= 0.6.0" } }, - "node_modules/deprecation": { - "version": "2.3.1", - "resolved": "https://registry.npmjs.org/deprecation/-/deprecation-2.3.1.tgz", - "integrity": "sha512-xmHIy4F3scKVwMsQ4WnVaS8bHOx0DmVwRywosKhaILI0ywMDWPtBSku2HNxRvF7jtwDRsoEwYQSfbxj8b7RlJQ==", - "dev": true - }, "node_modules/destroy": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/destroy/-/destroy-1.2.0.tgz", @@ -8061,6 +8467,12 @@ "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==", "dev": true }, + "node_modules/emojilib": { + "version": "2.4.0", + "resolved": "https://registry.npmjs.org/emojilib/-/emojilib-2.4.0.tgz", + "integrity": "sha512-5U0rVMU5Y2n2+ykNLQqMoqklN9ICBT/KsvC1Gz6vqHbz2AXXGkG+Pm5rMWk/8Vjrr/mY9985Hi8DYzn1F09Nyw==", + "dev": true + }, "node_modules/emojis-list": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/emojis-list/-/emojis-list-3.0.0.tgz", @@ -8114,61 +8526,183 @@ } }, "node_modules/env-ci": { - "version": "5.5.0", - "resolved": "https://registry.npmjs.org/env-ci/-/env-ci-5.5.0.tgz", - "integrity": "sha512-o0JdWIbOLP+WJKIUt36hz1ImQQFuN92nhsfTkHHap+J8CiI8WgGpH/a9jEGHh4/TU5BUUGjlnKXNoDb57+ne+A==", + "version": "11.0.0", + "resolved": "https://registry.npmjs.org/env-ci/-/env-ci-11.0.0.tgz", + "integrity": "sha512-apikxMgkipkgTvMdRT9MNqWx5VLOci79F4VBd7Op/7OPjjoanjdAvn6fglMCCEf/1bAh8eOiuEVCUs4V3qP3nQ==", "dev": true, "dependencies": { - "execa": "^5.0.0", - "fromentries": "^1.3.2", - "java-properties": "^1.0.0" + "execa": "^8.0.0", + "java-properties": "^1.0.2" }, "engines": { - "node": ">=10.17" + "node": "^18.17 || >=20.6.1" } }, "node_modules/env-ci/node_modules/execa": { - "version": "5.1.1", - "resolved": "https://registry.npmjs.org/execa/-/execa-5.1.1.tgz", - "integrity": "sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg==", + "version": "8.0.1", + "resolved": "https://registry.npmjs.org/execa/-/execa-8.0.1.tgz", + "integrity": "sha512-VyhnebXciFV2DESc+p6B+y0LjSm0krU4OgJN44qFAhBY0TJ+1V61tYD2+wHusZ6F9n5K+vl8k0sTy7PEfV4qpg==", "dev": true, "dependencies": { "cross-spawn": "^7.0.3", - "get-stream": "^6.0.0", - "human-signals": "^2.1.0", - "is-stream": "^2.0.0", + "get-stream": "^8.0.1", + "human-signals": "^5.0.0", + "is-stream": "^3.0.0", "merge-stream": "^2.0.0", - "npm-run-path": "^4.0.1", - "onetime": "^5.1.2", - "signal-exit": "^3.0.3", - "strip-final-newline": "^2.0.0" + "npm-run-path": "^5.1.0", + "onetime": "^6.0.0", + "signal-exit": "^4.1.0", + "strip-final-newline": "^3.0.0" }, "engines": { - "node": ">=10" + "node": ">=16.17" }, "funding": { "url": "https://github.com/sindresorhus/execa?sponsor=1" } }, + "node_modules/env-ci/node_modules/get-stream": { + "version": "8.0.1", + "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-8.0.1.tgz", + "integrity": "sha512-VaUJspBffn/LMCJVoMvSAdmscJyS1auj5Zulnn5UoYcY531UWmdwhRWkcGKnGU93m5HSXP9LP2usOryrBtQowA==", + "dev": true, + "engines": { + "node": ">=16" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/env-ci/node_modules/human-signals": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-2.1.0.tgz", - "integrity": "sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw==", + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-5.0.0.tgz", + "integrity": "sha512-AXcZb6vzzrFAUE61HnN4mpLqd/cSIwNQjtNWR0euPm6y0iqx3G4gOXaIDdtdDwZmhwe82LA6+zinmW4UBWVePQ==", "dev": true, "engines": { - "node": ">=10.17.0" + "node": ">=16.17.0" } }, - "node_modules/error-ex": { - "version": "1.3.2", - "resolved": "https://registry.npmjs.org/error-ex/-/error-ex-1.3.2.tgz", - "integrity": "sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g==", + "node_modules/env-ci/node_modules/is-stream": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-3.0.0.tgz", + "integrity": "sha512-LnQR4bZ9IADDRSkvpqMGvt/tEJWclzklNgSw48V5EAaAeDd6qGvN8ei6k5p0tvxSR171VmGyHuTiAOfxAbr8kA==", "dev": true, - "dependencies": { - "is-arrayish": "^0.2.1" + "engines": { + "node": "^12.20.0 || ^14.13.1 || >=16.0.0" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/errorstacks": { + "node_modules/env-ci/node_modules/mimic-fn": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/mimic-fn/-/mimic-fn-4.0.0.tgz", + "integrity": "sha512-vqiC06CuhBTUdZH+RYl8sFrL096vA45Ok5ISO6sE/Mr1jRbGH4Csnhi8f3wKVl7x8mO4Au7Ir9D3Oyv1VYMFJw==", + "dev": true, + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/env-ci/node_modules/npm-run-path": { + "version": "5.3.0", + "resolved": "https://registry.npmjs.org/npm-run-path/-/npm-run-path-5.3.0.tgz", + "integrity": "sha512-ppwTtiJZq0O/ai0z7yfudtBpWIoxM8yE6nHi1X47eFR2EWORqfbu6CnPlNsjeN683eT0qG6H/Pyf9fCcvjnnnQ==", + "dev": true, + "dependencies": { + "path-key": "^4.0.0" + }, + "engines": { + "node": "^12.20.0 || ^14.13.1 || >=16.0.0" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/env-ci/node_modules/onetime": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/onetime/-/onetime-6.0.0.tgz", + "integrity": "sha512-1FlR+gjXK7X+AsAHso35MnyN5KqGwJRi/31ft6x0M194ht7S+rWAvd7PHss9xSKMzE0asv1pyIHaJYq+BbacAQ==", + "dev": true, + "dependencies": { + "mimic-fn": "^4.0.0" + }, + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/env-ci/node_modules/path-key": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/path-key/-/path-key-4.0.0.tgz", + "integrity": "sha512-haREypq7xkM7ErfgIyA0z+Bj4AGKlMSdlQE2jvJo6huWD1EdkKYV+G/T4nq0YEF2vgTT8kqMFKo1uHn950r4SQ==", + "dev": true, + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/env-ci/node_modules/signal-exit": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-4.1.0.tgz", + "integrity": "sha512-bzyZ1e88w9O1iNJbKnOlvYTrWPDl46O1bG0D3XInv+9tkPrxrN8jUUTiFlDkkmKWgn1M6CfIA13SuGqOa9Korw==", + "dev": true, + "engines": { + "node": ">=14" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "node_modules/env-ci/node_modules/strip-final-newline": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/strip-final-newline/-/strip-final-newline-3.0.0.tgz", + "integrity": "sha512-dOESqjYr96iWYylGObzd39EuNTa5VJxyvVAEm5Jnh7KGo75V43Hk1odPQkNDyXNmUR6k+gEiDVXnjB8HJ3crXw==", + "dev": true, + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/env-paths": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/env-paths/-/env-paths-2.2.1.tgz", + "integrity": "sha512-+h1lkLKhZMTYjog1VEpJNG7NZJWcuc2DDk/qsqSTRRCOXiLjeQ1d1/udrUGhqMxUgAlwKNZ0cf2uqan5GLuS2A==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/environment": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/environment/-/environment-1.1.0.tgz", + "integrity": "sha512-xUtoPkMggbz0MPyPiIWr1Kp4aeWJjDZ6SMvURhimjdZgsRuDplF5/s9hcgGhyXMhs+6vpnuoiZ2kFiu3FMnS8Q==", + "dev": true, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/error-ex": { + "version": "1.3.2", + "resolved": "https://registry.npmjs.org/error-ex/-/error-ex-1.3.2.tgz", + "integrity": "sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g==", + "dev": true, + "dependencies": { + "is-arrayish": "^0.2.1" + } + }, + "node_modules/errorstacks": { "version": "2.4.0", "resolved": "https://registry.npmjs.org/errorstacks/-/errorstacks-2.4.0.tgz", "integrity": "sha512-5ecWhU5gt0a5G05nmQcgCxP5HperSMxLDzvWlT5U+ZSKkuDK0rJ3dbCQny6/vSCIXjwrhwSecXBbw1alr295hQ==", @@ -9082,9 +9616,9 @@ "dev": true }, "node_modules/fast-glob": { - "version": "3.3.1", - "resolved": "https://registry.npmjs.org/fast-glob/-/fast-glob-3.3.1.tgz", - "integrity": "sha512-kNFPyjhh5cKjrUltxs+wFx+ZkbRaxxmZ+X0ZU31SOsxCEtP9VPgtq2teZw1DebupL5GmDaNQ6yKMMVcM41iqDg==", + "version": "3.3.2", + "resolved": "https://registry.npmjs.org/fast-glob/-/fast-glob-3.3.2.tgz", + "integrity": "sha512-oX2ruAFQwf/Orj8m737Y5adxDQO0LAB7/S5MnxCdTNDd4p6BsyIVsv9JQsATbTSq8KHRpLwIHbVlUNatxd+1Ow==", "dev": true, "dependencies": { "@nodelib/fs.stat": "^2.0.2", @@ -9128,15 +9662,27 @@ } }, "node_modules/figures": { - "version": "3.2.0", - "resolved": "https://registry.npmjs.org/figures/-/figures-3.2.0.tgz", - "integrity": "sha512-yaduQFRKLXYOGgEn6AZau90j3ggSOyiqXU0F9JZfeXYhNa+Jk4X+s45A2zg5jns87GAFa34BBm2kXw4XpNcbdg==", + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/figures/-/figures-6.1.0.tgz", + "integrity": "sha512-d+l3qxjSesT4V7v2fh+QnmFnUWv9lSpjarhShNTgBOfA0ttejbQUAlHLitbjkoRiDulW0OPoQPYIGhIC8ohejg==", "dev": true, "dependencies": { - "escape-string-regexp": "^1.0.5" + "is-unicode-supported": "^2.0.0" }, "engines": { - "node": ">=8" + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/figures/node_modules/is-unicode-supported": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/is-unicode-supported/-/is-unicode-supported-2.0.0.tgz", + "integrity": "sha512-FRdAyx5lusK1iHG0TWpVtk9+1i+GjrzRffhDg4ovQ7mcidMQ6mj+MhKPmvh7Xwyv5gIS06ns49CA7Sqg7lC22Q==", + "dev": true, + "engines": { + "node": ">=18" }, "funding": { "url": "https://github.com/sponsors/sindresorhus" @@ -9229,6 +9775,18 @@ "node": ">=6" } }, + "node_modules/find-up-simple": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/find-up-simple/-/find-up-simple-1.0.0.tgz", + "integrity": "sha512-q7Us7kcjj2VMePAa02hDAF6d+MzsdsAWEwYyOpwUtlerRBkOEPBCRZrAV4XfcSN8fHAgaD0hP7miwoay6DCprw==", + "dev": true, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/find-versions": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/find-versions/-/find-versions-4.0.0.tgz", @@ -9330,26 +9888,6 @@ "readable-stream": "^2.0.0" } }, - "node_modules/fromentries": { - "version": "1.3.2", - "resolved": "https://registry.npmjs.org/fromentries/-/fromentries-1.3.2.tgz", - "integrity": "sha512-cHEpEQHUg0f8XdtZCc2ZAhrHzKzT0MrFUTcvx+hfxYu7rGMDc5SKoXFh+n4YigxsHXRzc6OrCshdR1bWH6HHyg==", - "dev": true, - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ] - }, "node_modules/fs-constants": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/fs-constants/-/fs-constants-1.0.0.tgz", @@ -9397,6 +9935,18 @@ "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==", "dev": true }, + "node_modules/function-timeout": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/function-timeout/-/function-timeout-1.0.2.tgz", + "integrity": "sha512-939eZS4gJ3htTHAldmyyuzlrD58P03fHG49v2JfFXbV6OhvZKRC9j2yAtdHw/zrp2zXHuv05zMIy40F0ge7spA==", + "dev": true, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/function.prototype.name": { "version": "1.1.6", "resolved": "https://registry.npmjs.org/function.prototype.name/-/function.prototype.name-1.1.6.tgz", @@ -9706,15 +10256,6 @@ "node": ">=0.10.0" } }, - "node_modules/hard-rejection": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/hard-rejection/-/hard-rejection-2.1.0.tgz", - "integrity": "sha512-VIZB+ibDhx7ObhAe7OVtoEbuP4h/MuOTHJ+J8h/eBXotJYl0fBgR72xDFCKgIh22OJZIOVNxBMWuhAr10r8HdA==", - "dev": true, - "engines": { - "node": ">=6" - } - }, "node_modules/has": { "version": "1.0.4", "resolved": "https://registry.npmjs.org/has/-/has-1.0.4.tgz", @@ -10027,44 +10568,38 @@ } }, "node_modules/hook-std": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/hook-std/-/hook-std-2.0.0.tgz", - "integrity": "sha512-zZ6T5WcuBMIUVh49iPQS9t977t7C0l7OtHrpeMb5uk48JdflRX0NSFvCekfYNmGQETnLq9W/isMyHl69kxGi8g==", + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/hook-std/-/hook-std-3.0.0.tgz", + "integrity": "sha512-jHRQzjSDzMtFy34AGj1DN+vq54WVuhSvKgrHf0OMiFQTwDD4L/qqofVEWjLOBMTn5+lCD3fPg32W9yOfnEJTTw==", "dev": true, "engines": { - "node": ">=8" + "node": "^12.20.0 || ^14.13.1 || >=16.0.0" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, "node_modules/hosted-git-info": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-4.1.0.tgz", - "integrity": "sha512-kyCuEOWjJqZuDbRHzL8V93NzQhwIB71oFWSyzVo+KPZI+pnQPPxucdkrOZvkLRnrf5URsQM+IJ09Dw29cRALIA==", + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-7.0.2.tgz", + "integrity": "sha512-puUZAUKT5m8Zzvs72XWy3HtvVbTWljRE66cP60bxJzAqf2DgICo7lYTY2IHUmLnNpjYvw5bvmoHvPc0QO2a62w==", "dev": true, "dependencies": { - "lru-cache": "^6.0.0" + "lru-cache": "^10.0.1" }, "engines": { - "node": ">=10" + "node": "^16.14.0 || >=18.0.0" } }, "node_modules/hosted-git-info/node_modules/lru-cache": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", - "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", + "version": "10.2.2", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-10.2.2.tgz", + "integrity": "sha512-9hp3Vp2/hFQUiIwKo8XCeFVnrg8Pk3TYNPIR7tJADKi5YfcF7vEaK7avFHTlSy3kOKYaJQaalfEo6YuXdceBOQ==", "dev": true, - "dependencies": { - "yallist": "^4.0.0" - }, "engines": { - "node": ">=10" + "node": "14 || >=16.14" } }, - "node_modules/hosted-git-info/node_modules/yallist": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", - "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==", - "dev": true - }, "node_modules/hsl-regex": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/hsl-regex/-/hsl-regex-1.0.0.tgz", @@ -10576,25 +11111,27 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/import-from": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/import-from/-/import-from-3.0.0.tgz", - "integrity": "sha512-CiuXOFFSzkU5x/CR0+z7T91Iht4CXgfCxVOFRhh2Zyhg5wOpWvvDLQUsWl+gcN+QscYBjez8hDCt85O7RLDttQ==", + "node_modules/import-from-esm": { + "version": "1.3.4", + "resolved": "https://registry.npmjs.org/import-from-esm/-/import-from-esm-1.3.4.tgz", + "integrity": "sha512-7EyUlPFC0HOlBDpUFGfYstsU7XHxZJKAAMzCT8wZ0hMW7b+hG51LIKTDcsgtz8Pu6YC0HqRVbX+rVUtsGMUKvg==", "dev": true, "dependencies": { - "resolve-from": "^5.0.0" + "debug": "^4.3.4", + "import-meta-resolve": "^4.0.0" }, "engines": { - "node": ">=8" + "node": ">=16.20" } }, - "node_modules/import-from/node_modules/resolve-from": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-5.0.0.tgz", - "integrity": "sha512-qYg9KP24dD5qka9J47d0aVky0N+b4fTU89LN9iDnjB5waksiC49rvMB0PrUJQGoTmH50XPiqOvAjDfaijGxYZw==", + "node_modules/import-meta-resolve": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/import-meta-resolve/-/import-meta-resolve-4.1.0.tgz", + "integrity": "sha512-I6fiaX09Xivtk+THaMfAwnA3MVA5Big1WHF1Dfx9hFuvNIWpXnorlkzhcQf6ehrqQiiZECRt1poOAkPmer3ruw==", "dev": true, - "engines": { - "node": ">=8" + "funding": { + "type": "github", + "url": "https://github.com/sponsors/wooorm" } }, "node_modules/imurmurhash": { @@ -10615,6 +11152,18 @@ "node": ">=8" } }, + "node_modules/index-to-position": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/index-to-position/-/index-to-position-0.1.2.tgz", + "integrity": "sha512-MWDKS3AS1bGCHLBA2VLImJz42f7bJh8wQsTGCzI3j519/CASStoDONUBVz2I/VID0MpiX3SGSnbOD2xUalbE5g==", + "dev": true, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/inflation": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/inflation/-/inflation-2.0.0.tgz", @@ -10673,16 +11222,16 @@ "dev": true }, "node_modules/into-stream": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/into-stream/-/into-stream-6.0.0.tgz", - "integrity": "sha512-XHbaOAvP+uFKUFsOgoNPRjLkwB+I22JFPFe5OjTkQ0nwgj6+pSjb4NmB6VMxaPshLiOf+zcpOCBQuLwC1KHhZA==", + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/into-stream/-/into-stream-7.0.0.tgz", + "integrity": "sha512-2dYz766i9HprMBasCMvHMuazJ7u4WzhJwo5kb3iPSiW/iRYV6uPari3zHoqZlnuaR7V1bEiNMxikhp37rdBXbw==", "dev": true, "dependencies": { "from2": "^2.3.0", "p-is-promise": "^3.0.0" }, "engines": { - "node": ">=10" + "node": ">=12" }, "funding": { "url": "https://github.com/sponsors/sindresorhus" @@ -11000,31 +11549,16 @@ "node": ">=8" } }, - "node_modules/is-path-cwd": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/is-path-cwd/-/is-path-cwd-2.2.0.tgz", - "integrity": "sha512-w942bTcih8fdJPJmQHFzkS76NEP8Kzzvmw92cXsazb8intwLqPibPPdXf4ANdKV3rYMuuQYGIWtvz9JilB3NFQ==", - "dev": true, - "engines": { - "node": ">=6" - } - }, - "node_modules/is-path-inside": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/is-path-inside/-/is-path-inside-3.0.3.tgz", - "integrity": "sha512-Fd4gABb+ycGAmKou8eMftCupSir5lRxqf4aD/vd0cD2qc4HL07OjCeuHMr8Ro4CoMaeCKDB0/ECBOVWjTwUvPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, "node_modules/is-plain-obj": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/is-plain-obj/-/is-plain-obj-1.1.0.tgz", - "integrity": "sha512-yvkRyxmFKEOQ4pNXCmJG5AEQNlXJS5LaONXo5/cLdTZdWvsZ1ioJEonLGAosKlMWE8lwUy/bJzMjcw8az73+Fg==", + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/is-plain-obj/-/is-plain-obj-4.1.0.tgz", + "integrity": "sha512-+Pgi+vMuUNkJyExiMBt5IlFoMyKnr5zhJ4Uspz58WOhBF5QoIZkFyNHIbBAtHwzVAgk5RtndVNsDRN61/mmDqg==", "dev": true, "engines": { - "node": ">=0.10.0" + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, "node_modules/is-plain-object": { @@ -11129,18 +11663,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/is-text-path": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/is-text-path/-/is-text-path-1.0.1.tgz", - "integrity": "sha512-xFuJpne9oFz5qDaodwmmG08e3CawH/2ZV8Qqza1Ko7Sk8POWbkRdwIoAWVhqvq0XeUzANEhKo2n0IXUGBm7A/w==", - "dev": true, - "dependencies": { - "text-extensions": "^1.0.0" - }, - "engines": { - "node": ">=0.10.0" - } - }, "node_modules/is-typed-array": { "version": "1.1.12", "resolved": "https://registry.npmjs.org/is-typed-array/-/is-typed-array-1.1.12.tgz", @@ -11246,9 +11768,9 @@ "dev": true }, "node_modules/issue-parser": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/issue-parser/-/issue-parser-6.0.0.tgz", - "integrity": "sha512-zKa/Dxq2lGsBIXQ7CUZWTHfvxPC2ej0KfO7fIPqLlHB9J2hJ7rGhZ5rilhuufylr4RXYPzJUeFjKxz305OsNlA==", + "version": "7.0.1", + "resolved": "https://registry.npmjs.org/issue-parser/-/issue-parser-7.0.1.tgz", + "integrity": "sha512-3YZcUUR2Wt1WsapF+S/WiA2WmlW0cWAoPccMqne7AxEBhCdFeTPjfv/Axb8V2gyCgY3nRw+ksZ3xSUX+R47iAg==", "dev": true, "dependencies": { "lodash.capitalize": "^4.2.1", @@ -11258,7 +11780,7 @@ "lodash.uniqby": "^4.7.0" }, "engines": { - "node": ">=10.13" + "node": "^18.17 || >=20.6.1" } }, "node_modules/istanbul-lib-coverage": { @@ -11566,12 +12088,6 @@ "integrity": "sha512-Bdboy+l7tA3OGW6FjyFHWkP5LuByj1Tk33Ljyq0axyzdk9//JSi2u3fP1QSmd1KNwq6VOKYGlAu87CisVir6Pw==", "dev": true }, - "node_modules/json-stringify-safe": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz", - "integrity": "sha512-ZClg6AaYvamvYEE82d3Iyd3vSSIjQ+odgjaTzRuO3s7toCdFKczob2i0zCh7JE8kWn17yvAWhUVxvqGwUalsRA==", - "dev": true - }, "node_modules/json5": { "version": "2.2.3", "resolved": "https://registry.npmjs.org/json5/-/json5-2.2.3.tgz", @@ -11585,9 +12101,9 @@ } }, "node_modules/jsonata": { - "version": "1.8.6", - "resolved": "https://registry.npmjs.org/jsonata/-/jsonata-1.8.6.tgz", - "integrity": "sha512-ZH2TPYdNP2JecOl/HvrH47Xc+9imibEMQ4YqKy/F/FrM+2a6vfbGxeCX23dB9Fr6uvGwv+ghf1KxWB3iZk09wA==", + "version": "1.8.7", + "resolved": "https://registry.npmjs.org/jsonata/-/jsonata-1.8.7.tgz", + "integrity": "sha512-tOW2/hZ+nR2bcQZs+0T62LVe5CHaNa3laFFWb/262r39utN6whJGBF7IR2Wq1QXrDbhftolk5gggW8uUJYlBTQ==", "engines": { "node": ">= 8" } @@ -11604,31 +12120,6 @@ "graceful-fs": "^4.1.6" } }, - "node_modules/jsonparse": { - "version": "1.3.1", - "resolved": "https://registry.npmjs.org/jsonparse/-/jsonparse-1.3.1.tgz", - "integrity": "sha512-POQXvpdL69+CluYsillJ7SUhKvytYjW9vG/GKpnf+xP8UWgYEM/RaMzHHofbALDiKbbP1W8UEYmgGl39WkPZsg==", - "dev": true, - "engines": [ - "node >= 0.2.0" - ] - }, - "node_modules/JSONStream": { - "version": "1.3.5", - "resolved": "https://registry.npmjs.org/JSONStream/-/JSONStream-1.3.5.tgz", - "integrity": "sha512-E+iruNOY8VV9s4JEbe1aNEm6MiszPRr/UfcHMz0TQh1BXSxHK+ASV1R6W4HpjBhSeS+54PIsAMCBmwD06LLsqQ==", - "dev": true, - "dependencies": { - "jsonparse": "^1.2.0", - "through": ">=2.2.7 <3" - }, - "bin": { - "JSONStream": "bin.js" - }, - "engines": { - "node": "*" - } - }, "node_modules/just-extend": { "version": "4.2.1", "resolved": "https://registry.npmjs.org/just-extend/-/just-extend-4.2.1.tgz", @@ -11656,15 +12147,6 @@ "json-buffer": "3.0.1" } }, - "node_modules/kind-of": { - "version": "6.0.3", - "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.3.tgz", - "integrity": "sha512-dcS1ul+9tmeD95T+x28/ehLgd9mENa3LsvDTtzm3vyBEO7RPptvAD+t44WVXaUjTBRcrpFeFlC8WCruUR456hw==", - "dev": true, - "engines": { - "node": ">=0.10.0" - } - }, "node_modules/koa": { "version": "2.14.2", "resolved": "https://registry.npmjs.org/koa/-/koa-2.14.2.tgz", @@ -12096,12 +12578,6 @@ "integrity": "sha512-z+Uw/vLuy6gQe8cfaFWD7p0wVv8fJl3mbzXh33RS+0oW2wvUqiRXiQ69gLWSLpgB5/6sU+r6BlQR0MBILadqTQ==", "dev": true }, - "node_modules/lodash.ismatch": { - "version": "4.4.0", - "resolved": "https://registry.npmjs.org/lodash.ismatch/-/lodash.ismatch-4.4.0.tgz", - "integrity": "sha512-fPMfXjGQEV9Xsq/8MTSgUf255gawYRbjwMyDbcvDhXgV7enSZA0hynz6vMPnpAb5iONEzBHBPsT+0zes5Z301g==", - "dev": true - }, "node_modules/lodash.isplainobject": { "version": "4.0.6", "resolved": "https://registry.npmjs.org/lodash.isplainobject/-/lodash.isplainobject-4.0.6.tgz", @@ -12373,18 +12849,6 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/map-obj": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/map-obj/-/map-obj-4.3.0.tgz", - "integrity": "sha512-hdN1wVrZbb29eBGiGjJbeP8JbKjq1urkHJ/LIP/NY48MZ1QVXUsQBV1G1zvYFHn1XE06cwjBsOI2K3Ulnj1YXQ==", - "dev": true, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, "node_modules/markdown-escapes": { "version": "1.0.4", "resolved": "https://registry.npmjs.org/markdown-escapes/-/markdown-escapes-1.0.4.tgz", @@ -12409,102 +12873,77 @@ } }, "node_modules/marked": { - "version": "2.1.3", - "resolved": "https://registry.npmjs.org/marked/-/marked-2.1.3.tgz", - "integrity": "sha512-/Q+7MGzaETqifOMWYEA7HVMaZb4XbcRfaOzcSsHZEith83KGlvaSG33u0SKu89Mj5h+T8V2hM+8O45Qc5XTgwA==", + "version": "12.0.2", + "resolved": "https://registry.npmjs.org/marked/-/marked-12.0.2.tgz", + "integrity": "sha512-qXUm7e/YKFoqFPYPa3Ukg9xlI5cyAtGmyEIzMfW//m6kXwCy2Ps9DYf5ioijFKQ8qyuscrHoY04iJGctu2Kg0Q==", "dev": true, "bin": { - "marked": "bin/marked" + "marked": "bin/marked.js" }, "engines": { - "node": ">= 10" + "node": ">= 18" } }, "node_modules/marked-terminal": { - "version": "4.2.0", - "resolved": "https://registry.npmjs.org/marked-terminal/-/marked-terminal-4.2.0.tgz", - "integrity": "sha512-DQfNRV9svZf0Dm9Cf5x5xaVJ1+XjxQW6XjFJ5HFkVyK52SDpj5PCBzS5X5r2w9nHr3mlB0T5201UMLue9fmhUw==", + "version": "7.1.0", + "resolved": "https://registry.npmjs.org/marked-terminal/-/marked-terminal-7.1.0.tgz", + "integrity": "sha512-+pvwa14KZL74MVXjYdPR3nSInhGhNvPce/3mqLVZT2oUvt654sL1XImFuLZ1pkA866IYZ3ikDTOFUIC7XzpZZg==", "dev": true, "dependencies": { - "ansi-escapes": "^4.3.1", - "cardinal": "^2.1.1", - "chalk": "^4.1.0", - "cli-table3": "^0.6.0", - "node-emoji": "^1.10.0", - "supports-hyperlinks": "^2.1.0" + "ansi-escapes": "^7.0.0", + "chalk": "^5.3.0", + "cli-highlight": "^2.1.11", + "cli-table3": "^0.6.5", + "node-emoji": "^2.1.3", + "supports-hyperlinks": "^3.0.0" + }, + "engines": { + "node": ">=16.0.0" }, "peerDependencies": { - "marked": "^1.0.0 || ^2.0.0" + "marked": ">=1 <14" } }, - "node_modules/marked-terminal/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "node_modules/marked-terminal/node_modules/ansi-escapes": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-7.0.0.tgz", + "integrity": "sha512-GdYO7a61mR0fOlAsvC9/rIHf7L96sBc6dEWzeOu+KAea5bZyQRPIpojrVoI4AXGJS/ycu/fBTdLrUkA4ODrvjw==", "dev": true, "dependencies": { - "color-convert": "^2.0.1" + "environment": "^1.0.0" }, "engines": { - "node": ">=8" + "node": ">=18" }, "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" + "url": "https://github.com/sponsors/sindresorhus" } }, "node_modules/marked-terminal/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "version": "5.3.0", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-5.3.0.tgz", + "integrity": "sha512-dLitG79d+GV1Nb/VYcCDFivJeK1hiukt9QjRNVOsUtTy1rR1YJsmpGGTZ3qJos+uw7WmWF4wUwBd9jxjocFC2w==", "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, "engines": { - "node": ">=10" + "node": "^12.17.0 || ^14.13 || >=16.0.0" }, "funding": { "url": "https://github.com/chalk/chalk?sponsor=1" } }, - "node_modules/marked-terminal/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/marked-terminal/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/marked-terminal/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/marked-terminal/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "node_modules/marked-terminal/node_modules/node-emoji": { + "version": "2.1.3", + "resolved": "https://registry.npmjs.org/node-emoji/-/node-emoji-2.1.3.tgz", + "integrity": "sha512-E2WEOVsgs7O16zsURJ/eH8BqhF029wGpEOnv7Urwdo2wmQanOACwJQh0devF9D9RhoZru0+9JXIS0dBXIAz+lA==", "dev": true, "dependencies": { - "has-flag": "^4.0.0" + "@sindresorhus/is": "^4.6.0", + "char-regex": "^1.0.2", + "emojilib": "^2.4.0", + "skin-tone": "^2.0.0" }, "engines": { - "node": ">=8" + "node": ">=18" } }, "node_modules/marky": { @@ -12719,51 +13158,17 @@ } }, "node_modules/meow": { - "version": "8.1.2", - "resolved": "https://registry.npmjs.org/meow/-/meow-8.1.2.tgz", - "integrity": "sha512-r85E3NdZ+mpYk1C6RjPFEMSE+s1iZMuHtsHAqY0DT3jZczl0diWUZ8g6oU7h0M9cD2EL+PzaYghhCLzR0ZNn5Q==", - "dev": true, - "dependencies": { - "@types/minimist": "^1.2.0", - "camelcase-keys": "^6.2.2", - "decamelize-keys": "^1.1.0", - "hard-rejection": "^2.1.0", - "minimist-options": "4.1.0", - "normalize-package-data": "^3.0.0", - "read-pkg-up": "^7.0.1", - "redent": "^3.0.0", - "trim-newlines": "^3.0.0", - "type-fest": "^0.18.0", - "yargs-parser": "^20.2.3" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/meow/node_modules/type-fest": { - "version": "0.18.1", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.18.1.tgz", - "integrity": "sha512-OIAYXk8+ISY+qTOwkHtKqzAuxchoMiD9Udx+FSGQDuiRR+PJKJHc2NJAXlbhkGwTt/4/nKZxELY1w3ReWOL8mw==", + "version": "13.2.0", + "resolved": "https://registry.npmjs.org/meow/-/meow-13.2.0.tgz", + "integrity": "sha512-pxQJQzB6djGPXh08dacEloMFopsOqGVRKFPYvPOt9XDZ1HasbgDZA74CJGreSU4G3Ak7EFJGoiH2auq+yXISgA==", "dev": true, "engines": { - "node": ">=10" + "node": ">=18" }, "funding": { "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/meow/node_modules/yargs-parser": { - "version": "20.2.9", - "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-20.2.9.tgz", - "integrity": "sha512-y11nGElTIV+CT3Zv9t7VKl+Q3hTQoT9a1Qzezhhl6Rp21gJ/IVTW7Z3y9EWXhuUBC2Shnf+DX0antecpAwSP8w==", - "dev": true, - "engines": { - "node": ">=10" - } - }, "node_modules/merge-stream": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/merge-stream/-/merge-stream-2.0.0.tgz", @@ -12893,15 +13298,18 @@ } }, "node_modules/mime": { - "version": "2.6.0", - "resolved": "https://registry.npmjs.org/mime/-/mime-2.6.0.tgz", - "integrity": "sha512-USPkMeET31rOMiarsBNIHZKLGgvKc/LrjofAnBlOttf5ajRvqiRA8QsenbcooctK6d6Ts6aqZXBA+XbkKthiQg==", + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/mime/-/mime-4.0.3.tgz", + "integrity": "sha512-KgUb15Oorc0NEKPbvfa0wRU+PItIEZmiv+pyAO2i0oTIVTJhlzMclU7w4RXWQrSOVH5ax/p/CkIO7KI4OyFJTQ==", "dev": true, + "funding": [ + "https://github.com/sponsors/broofa" + ], "bin": { - "mime": "cli.js" + "mime": "bin/cli.js" }, "engines": { - "node": ">=4.0.0" + "node": ">=16" } }, "node_modules/mime-db": { @@ -12941,15 +13349,6 @@ "dom-walk": "^0.1.0" } }, - "node_modules/min-indent": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/min-indent/-/min-indent-1.0.1.tgz", - "integrity": "sha512-I9jwMn07Sy/IwOj3zVkVik2JTvgpaykDZEigL6Rx6N9LbMywwUSMtxET+7lVoDLLd3O3IXwJwvuuns8UB/HeAg==", - "dev": true, - "engines": { - "node": ">=4" - } - }, "node_modules/minimatch": { "version": "3.1.2", "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", @@ -12971,20 +13370,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/minimist-options": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/minimist-options/-/minimist-options-4.1.0.tgz", - "integrity": "sha512-Q4r8ghd80yhO/0j1O3B2BjweX3fiHg9cdOwjJd2J76Q135c+NDxGCqdYKQ1SKBuFfgWbAUzBfvYjPUEeNgqN1A==", - "dev": true, - "dependencies": { - "arrify": "^1.0.1", - "is-plain-obj": "^1.1.0", - "kind-of": "^6.0.3" - }, - "engines": { - "node": ">= 6" - } - }, "node_modules/mkdirp": { "version": "1.0.4", "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.4.tgz", @@ -13202,20 +13587,22 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/modify-values": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/modify-values/-/modify-values-1.0.1.tgz", - "integrity": "sha512-xV2bxeN6F7oYjZWTe/YPAy6MN2M+sL4u/Rlm2AHCIVGfo2p1yGmBHQ6vHehl4bRTZBdHu3TSkWdYgkwpYzAGSw==", - "dev": true, - "engines": { - "node": ">=0.10.0" - } - }, "node_modules/ms": { "version": "2.1.2", "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==" }, + "node_modules/mz": { + "version": "2.7.0", + "resolved": "https://registry.npmjs.org/mz/-/mz-2.7.0.tgz", + "integrity": "sha512-z81GNO7nnYMEhrGh9LeymoE4+Yr0Wn5McHIZMK5cfQCl+NDX08sCZgUc9/6MHni9IWuFLm1Z3HTCXu2z9fN62Q==", + "dev": true, + "dependencies": { + "any-promise": "^1.0.0", + "object-assign": "^4.0.1", + "thenify-all": "^1.0.0" + } + }, "node_modules/nanocolors": { "version": "0.2.13", "resolved": "https://registry.npmjs.org/nanocolors/-/nanocolors-0.2.13.tgz", @@ -13363,40 +13750,24 @@ "dev": true }, "node_modules/normalize-package-data": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/normalize-package-data/-/normalize-package-data-3.0.3.tgz", - "integrity": "sha512-p2W1sgqij3zMMyRC067Dg16bfzVH+w7hyegmpIvZ4JNjqtGOVAIvLmjBx3yP7YTe9vKJgkoNOPjwQGogDoMXFA==", - "dev": true, - "dependencies": { - "hosted-git-info": "^4.0.1", - "is-core-module": "^2.5.0", - "semver": "^7.3.4", - "validate-npm-package-license": "^3.0.1" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/normalize-package-data/node_modules/lru-cache": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", - "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", + "version": "6.0.2", + "resolved": "https://registry.npmjs.org/normalize-package-data/-/normalize-package-data-6.0.2.tgz", + "integrity": "sha512-V6gygoYb/5EmNI+MEGrWkC+e6+Rr7mTmfHrxDbLzxQogBkgzo76rkok0Am6thgSF7Mv2nLOajAJj5vDJZEFn7g==", "dev": true, "dependencies": { - "yallist": "^4.0.0" + "hosted-git-info": "^7.0.0", + "semver": "^7.3.5", + "validate-npm-package-license": "^3.0.4" }, "engines": { - "node": ">=10" + "node": "^16.14.0 || >=18.0.0" } }, "node_modules/normalize-package-data/node_modules/semver": { - "version": "7.5.4", - "resolved": "https://registry.npmjs.org/semver/-/semver-7.5.4.tgz", - "integrity": "sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA==", + "version": "7.6.2", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.6.2.tgz", + "integrity": "sha512-FNAIBWCx9qcRhoHcgcJ0gvU7SN1lYU2ZXuSfl04bSC5OpvDHFyJCjdNHomPXxjQlCBU67YW64PzY7/VIEH7F2w==", "dev": true, - "dependencies": { - "lru-cache": "^6.0.0" - }, "bin": { "semver": "bin/semver.js" }, @@ -13404,12 +13775,6 @@ "node": ">=10" } }, - "node_modules/normalize-package-data/node_modules/yallist": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", - "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==", - "dev": true - }, "node_modules/normalize-path": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", @@ -13429,40 +13794,40 @@ } }, "node_modules/normalize-url": { - "version": "6.1.0", - "resolved": "https://registry.npmjs.org/normalize-url/-/normalize-url-6.1.0.tgz", - "integrity": "sha512-DlL+XwOy3NxAQ8xuC0okPgK46iuVNAK01YN7RueYBqqFeGsBjV9XmCAzAdgt+667bCl5kPh9EqKKDwnaPG1I7A==", + "version": "8.0.1", + "resolved": "https://registry.npmjs.org/normalize-url/-/normalize-url-8.0.1.tgz", + "integrity": "sha512-IO9QvjUMWxPQQhs60oOu10CRkWCiZzSUkzbXGGV9pviYl1fXYcvkzQ5jV9z8Y6un8ARoVRl4EtC6v6jNqbaJ/w==", "dev": true, "engines": { - "node": ">=10" + "node": ">=14.16" }, "funding": { "url": "https://github.com/sponsors/sindresorhus" } }, "node_modules/npm": { - "version": "7.24.2", - "resolved": "https://registry.npmjs.org/npm/-/npm-7.24.2.tgz", - "integrity": "sha512-120p116CE8VMMZ+hk8IAb1inCPk4Dj3VZw29/n2g6UI77urJKVYb7FZUDW8hY+EBnfsjI/2yrobBgFyzo7YpVQ==", + "version": "10.8.1", + "resolved": "https://registry.npmjs.org/npm/-/npm-10.8.1.tgz", + "integrity": "sha512-Dp1C6SvSMYQI7YHq/y2l94uvI+59Eqbu1EpuKQHQ8p16txXRuRit5gH3Lnaagk2aXDIjg/Iru9pd05bnneKgdw==", "bundleDependencies": [ "@isaacs/string-locale-compare", "@npmcli/arborist", - "@npmcli/ci-detect", "@npmcli/config", + "@npmcli/fs", "@npmcli/map-workspaces", "@npmcli/package-json", + "@npmcli/promise-spawn", + "@npmcli/redact", "@npmcli/run-script", + "@sigstore/tuf", "abbrev", - "ansicolors", - "ansistyles", "archy", "cacache", "chalk", - "chownr", + "ci-info", "cli-columns", - "cli-table3", - "columnify", "fastest-levenshtein", + "fs-minipass", "glob", "graceful-fs", "hosted-git-info", @@ -13482,13 +13847,13 @@ "libnpmteam", "libnpmversion", "make-fetch-happen", + "minimatch", "minipass", "minipass-pipeline", - "mkdirp", - "mkdirp-infer-owner", "ms", "node-gyp", "nopt", + "normalize-package-data", "npm-audit-report", "npm-install-checks", "npm-package-arg", @@ -13496,18 +13861,16 @@ "npm-profile", "npm-registry-fetch", "npm-user-validate", - "npmlog", - "opener", + "p-map", "pacote", "parse-conflict-json", + "proc-log", "qrcode-terminal", "read", - "read-package-json", - "read-package-json-fast", - "readdir-scoped-modules", - "rimraf", "semver", + "spdx-expression-parse", "ssri", + "supports-color", "tar", "text-table", "tiny-relative-date", @@ -13518,83 +13881,81 @@ ], "dev": true, "dependencies": { - "@isaacs/string-locale-compare": "*", - "@npmcli/arborist": "*", - "@npmcli/ci-detect": "*", - "@npmcli/config": "*", - "@npmcli/map-workspaces": "*", - "@npmcli/package-json": "*", - "@npmcli/run-script": "*", - "abbrev": "*", - "ansicolors": "*", - "ansistyles": "*", - "archy": "*", - "cacache": "*", - "chalk": "*", - "chownr": "*", - "cli-columns": "*", - "cli-table3": "*", - "columnify": "*", - "fastest-levenshtein": "*", - "glob": "*", - "graceful-fs": "*", - "hosted-git-info": "*", - "ini": "*", - "init-package-json": "*", - "is-cidr": "*", - "json-parse-even-better-errors": "*", - "libnpmaccess": "*", - "libnpmdiff": "*", - "libnpmexec": "*", - "libnpmfund": "*", - "libnpmhook": "*", - "libnpmorg": "*", - "libnpmpack": "*", - "libnpmpublish": "*", - "libnpmsearch": "*", - "libnpmteam": "*", - "libnpmversion": "*", - "make-fetch-happen": "*", - "minipass": "*", - "minipass-pipeline": "*", - "mkdirp": "*", - "mkdirp-infer-owner": "*", - "ms": "*", - "node-gyp": "*", - "nopt": "*", - "npm-audit-report": "*", - "npm-install-checks": "*", - "npm-package-arg": "*", - "npm-pick-manifest": "*", - "npm-profile": "*", - "npm-registry-fetch": "*", - "npm-user-validate": "*", - "npmlog": "*", - "opener": "*", - "pacote": "*", - "parse-conflict-json": "*", - "qrcode-terminal": "*", - "read": "*", - "read-package-json": "*", - "read-package-json-fast": "*", - "readdir-scoped-modules": "*", - "rimraf": "*", - "semver": "*", - "ssri": "*", - "tar": "*", - "text-table": "*", - "tiny-relative-date": "*", - "treeverse": "*", - "validate-npm-package-name": "*", - "which": "*", - "write-file-atomic": "*" + "@isaacs/string-locale-compare": "^1.1.0", + "@npmcli/arborist": "^7.5.3", + "@npmcli/config": "^8.3.3", + "@npmcli/fs": "^3.1.1", + "@npmcli/map-workspaces": "^3.0.6", + "@npmcli/package-json": "^5.1.1", + "@npmcli/promise-spawn": "^7.0.2", + "@npmcli/redact": "^2.0.0", + "@npmcli/run-script": "^8.1.0", + "@sigstore/tuf": "^2.3.4", + "abbrev": "^2.0.0", + "archy": "~1.0.0", + "cacache": "^18.0.3", + "chalk": "^5.3.0", + "ci-info": "^4.0.0", + "cli-columns": "^4.0.0", + "fastest-levenshtein": "^1.0.16", + "fs-minipass": "^3.0.3", + "glob": "^10.4.1", + "graceful-fs": "^4.2.11", + "hosted-git-info": "^7.0.2", + "ini": "^4.1.3", + "init-package-json": "^6.0.3", + "is-cidr": "^5.1.0", + "json-parse-even-better-errors": "^3.0.2", + "libnpmaccess": "^8.0.6", + "libnpmdiff": "^6.1.3", + "libnpmexec": "^8.1.2", + "libnpmfund": "^5.0.11", + "libnpmhook": "^10.0.5", + "libnpmorg": "^6.0.6", + "libnpmpack": "^7.0.3", + "libnpmpublish": "^9.0.9", + "libnpmsearch": "^7.0.6", + "libnpmteam": "^6.0.5", + "libnpmversion": "^6.0.3", + "make-fetch-happen": "^13.0.1", + "minimatch": "^9.0.4", + "minipass": "^7.1.1", + "minipass-pipeline": "^1.2.4", + "ms": "^2.1.2", + "node-gyp": "^10.1.0", + "nopt": "^7.2.1", + "normalize-package-data": "^6.0.1", + "npm-audit-report": "^5.0.0", + "npm-install-checks": "^6.3.0", + "npm-package-arg": "^11.0.2", + "npm-pick-manifest": "^9.0.1", + "npm-profile": "^10.0.0", + "npm-registry-fetch": "^17.0.1", + "npm-user-validate": "^2.0.1", + "p-map": "^4.0.0", + "pacote": "^18.0.6", + "parse-conflict-json": "^3.0.1", + "proc-log": "^4.2.0", + "qrcode-terminal": "^0.12.0", + "read": "^3.0.1", + "semver": "^7.6.2", + "spdx-expression-parse": "^4.0.0", + "ssri": "^10.0.6", + "supports-color": "^9.4.0", + "tar": "^6.2.1", + "text-table": "~0.2.0", + "tiny-relative-date": "^1.3.0", + "treeverse": "^3.0.0", + "validate-npm-package-name": "^5.0.1", + "which": "^4.0.0", + "write-file-atomic": "^5.0.1" }, "bin": { "npm": "bin/npm-cli.js", "npx": "bin/npx-cli.js" }, "engines": { - "node": ">=10" + "node": "^18.17.0 || >=20.5.0" } }, "node_modules/npm-run-path": { @@ -13609,500 +13970,572 @@ "node": ">=8" } }, - "node_modules/npm/node_modules/@gar/promisify": { - "version": "1.1.2", + "node_modules/npm/node_modules/@isaacs/cliui": { + "version": "8.0.2", "dev": true, "inBundle": true, - "license": "MIT" + "license": "ISC", + "dependencies": { + "string-width": "^5.1.2", + "string-width-cjs": "npm:string-width@^4.2.0", + "strip-ansi": "^7.0.1", + "strip-ansi-cjs": "npm:strip-ansi@^6.0.1", + "wrap-ansi": "^8.1.0", + "wrap-ansi-cjs": "npm:wrap-ansi@^7.0.0" + }, + "engines": { + "node": ">=12" + } }, - "node_modules/npm/node_modules/@isaacs/string-locale-compare": { - "version": "1.1.0", + "node_modules/npm/node_modules/@isaacs/cliui/node_modules/ansi-regex": { + "version": "6.0.1", "dev": true, "inBundle": true, - "license": "ISC" + "license": "MIT", + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/chalk/ansi-regex?sponsor=1" + } }, - "node_modules/npm/node_modules/@npmcli/arborist": { - "version": "2.9.0", + "node_modules/npm/node_modules/@isaacs/cliui/node_modules/emoji-regex": { + "version": "9.2.2", "dev": true, "inBundle": true, - "license": "ISC", + "license": "MIT" + }, + "node_modules/npm/node_modules/@isaacs/cliui/node_modules/string-width": { + "version": "5.1.2", + "dev": true, + "inBundle": true, + "license": "MIT", "dependencies": { - "@isaacs/string-locale-compare": "^1.0.1", - "@npmcli/installed-package-contents": "^1.0.7", - "@npmcli/map-workspaces": "^1.0.2", - "@npmcli/metavuln-calculator": "^1.1.0", - "@npmcli/move-file": "^1.1.0", - "@npmcli/name-from-folder": "^1.0.1", - "@npmcli/node-gyp": "^1.0.1", - "@npmcli/package-json": "^1.0.1", - "@npmcli/run-script": "^1.8.2", - "bin-links": "^2.2.1", - "cacache": "^15.0.3", - "common-ancestor-path": "^1.0.1", - "json-parse-even-better-errors": "^2.3.1", - "json-stringify-nice": "^1.1.4", - "mkdirp": "^1.0.4", - "mkdirp-infer-owner": "^2.0.0", - "npm-install-checks": "^4.0.0", - "npm-package-arg": "^8.1.5", - "npm-pick-manifest": "^6.1.0", - "npm-registry-fetch": "^11.0.0", - "pacote": "^11.3.5", - "parse-conflict-json": "^1.1.1", - "proc-log": "^1.0.0", - "promise-all-reject-late": "^1.0.0", - "promise-call-limit": "^1.0.1", - "read-package-json-fast": "^2.0.2", - "readdir-scoped-modules": "^1.1.0", - "rimraf": "^3.0.2", - "semver": "^7.3.5", - "ssri": "^8.0.1", - "treeverse": "^1.0.4", - "walk-up-path": "^1.0.0" + "eastasianwidth": "^0.2.0", + "emoji-regex": "^9.2.2", + "strip-ansi": "^7.0.1" }, - "bin": { - "arborist": "bin/index.js" + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/npm/node_modules/@isaacs/cliui/node_modules/strip-ansi": { + "version": "7.1.0", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "ansi-regex": "^6.0.1" }, "engines": { - "node": ">= 10" + "node": ">=12" + }, + "funding": { + "url": "https://github.com/chalk/strip-ansi?sponsor=1" } }, - "node_modules/npm/node_modules/@npmcli/ci-detect": { - "version": "1.3.0", + "node_modules/npm/node_modules/@isaacs/string-locale-compare": { + "version": "1.1.0", "dev": true, "inBundle": true, "license": "ISC" }, - "node_modules/npm/node_modules/@npmcli/config": { - "version": "2.3.0", + "node_modules/npm/node_modules/@npmcli/agent": { + "version": "2.2.2", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "ini": "^2.0.0", - "mkdirp-infer-owner": "^2.0.0", - "nopt": "^5.0.0", - "semver": "^7.3.4", - "walk-up-path": "^1.0.0" + "agent-base": "^7.1.0", + "http-proxy-agent": "^7.0.0", + "https-proxy-agent": "^7.0.1", + "lru-cache": "^10.0.1", + "socks-proxy-agent": "^8.0.3" }, "engines": { - "node": ">=10" + "node": "^16.14.0 || >=18.0.0" } }, - "node_modules/npm/node_modules/@npmcli/disparity-colors": { - "version": "1.0.1", + "node_modules/npm/node_modules/@npmcli/arborist": { + "version": "7.5.3", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "@isaacs/string-locale-compare": "^1.1.0", + "@npmcli/fs": "^3.1.1", + "@npmcli/installed-package-contents": "^2.1.0", + "@npmcli/map-workspaces": "^3.0.2", + "@npmcli/metavuln-calculator": "^7.1.1", + "@npmcli/name-from-folder": "^2.0.0", + "@npmcli/node-gyp": "^3.0.0", + "@npmcli/package-json": "^5.1.0", + "@npmcli/query": "^3.1.0", + "@npmcli/redact": "^2.0.0", + "@npmcli/run-script": "^8.1.0", + "bin-links": "^4.0.4", + "cacache": "^18.0.3", + "common-ancestor-path": "^1.0.1", + "hosted-git-info": "^7.0.2", + "json-parse-even-better-errors": "^3.0.2", + "json-stringify-nice": "^1.1.4", + "lru-cache": "^10.2.2", + "minimatch": "^9.0.4", + "nopt": "^7.2.1", + "npm-install-checks": "^6.2.0", + "npm-package-arg": "^11.0.2", + "npm-pick-manifest": "^9.0.1", + "npm-registry-fetch": "^17.0.1", + "pacote": "^18.0.6", + "parse-conflict-json": "^3.0.0", + "proc-log": "^4.2.0", + "proggy": "^2.0.0", + "promise-all-reject-late": "^1.0.0", + "promise-call-limit": "^3.0.1", + "read-package-json-fast": "^3.0.2", + "semver": "^7.3.7", + "ssri": "^10.0.6", + "treeverse": "^3.0.0", + "walk-up-path": "^3.0.1" + }, + "bin": { + "arborist": "bin/index.js" + }, + "engines": { + "node": "^16.14.0 || >=18.0.0" + } + }, + "node_modules/npm/node_modules/@npmcli/config": { + "version": "8.3.3", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "ansi-styles": "^4.3.0" + "@npmcli/map-workspaces": "^3.0.2", + "ci-info": "^4.0.0", + "ini": "^4.1.2", + "nopt": "^7.2.1", + "proc-log": "^4.2.0", + "read-package-json-fast": "^3.0.2", + "semver": "^7.3.5", + "walk-up-path": "^3.0.1" }, "engines": { - "node": ">=10" + "node": "^16.14.0 || >=18.0.0" } }, "node_modules/npm/node_modules/@npmcli/fs": { - "version": "1.0.0", + "version": "3.1.1", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "@gar/promisify": "^1.0.1", "semver": "^7.3.5" + }, + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/npm/node_modules/@npmcli/git": { - "version": "2.1.0", + "version": "5.0.7", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "@npmcli/promise-spawn": "^1.3.2", - "lru-cache": "^6.0.0", - "mkdirp": "^1.0.4", - "npm-pick-manifest": "^6.1.1", + "@npmcli/promise-spawn": "^7.0.0", + "lru-cache": "^10.0.1", + "npm-pick-manifest": "^9.0.0", + "proc-log": "^4.0.0", "promise-inflight": "^1.0.1", "promise-retry": "^2.0.1", "semver": "^7.3.5", - "which": "^2.0.2" + "which": "^4.0.0" + }, + "engines": { + "node": "^16.14.0 || >=18.0.0" } }, "node_modules/npm/node_modules/@npmcli/installed-package-contents": { - "version": "1.0.7", + "version": "2.1.0", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "npm-bundled": "^1.1.1", - "npm-normalize-package-bin": "^1.0.1" + "npm-bundled": "^3.0.0", + "npm-normalize-package-bin": "^3.0.0" }, "bin": { - "installed-package-contents": "index.js" + "installed-package-contents": "bin/index.js" }, "engines": { - "node": ">= 10" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/npm/node_modules/@npmcli/map-workspaces": { - "version": "1.0.4", + "version": "3.0.6", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "@npmcli/name-from-folder": "^1.0.1", - "glob": "^7.1.6", - "minimatch": "^3.0.4", - "read-package-json-fast": "^2.0.1" + "@npmcli/name-from-folder": "^2.0.0", + "glob": "^10.2.2", + "minimatch": "^9.0.0", + "read-package-json-fast": "^3.0.0" }, "engines": { - "node": ">=10" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/npm/node_modules/@npmcli/metavuln-calculator": { - "version": "1.1.1", + "version": "7.1.1", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "cacache": "^15.0.5", - "pacote": "^11.1.11", - "semver": "^7.3.2" - } - }, - "node_modules/npm/node_modules/@npmcli/move-file": { - "version": "1.1.2", - "dev": true, - "inBundle": true, - "license": "MIT", - "dependencies": { - "mkdirp": "^1.0.4", - "rimraf": "^3.0.2" + "cacache": "^18.0.0", + "json-parse-even-better-errors": "^3.0.0", + "pacote": "^18.0.0", + "proc-log": "^4.1.0", + "semver": "^7.3.5" }, "engines": { - "node": ">=10" + "node": "^16.14.0 || >=18.0.0" } }, "node_modules/npm/node_modules/@npmcli/name-from-folder": { - "version": "1.0.1", + "version": "2.0.0", "dev": true, "inBundle": true, - "license": "ISC" + "license": "ISC", + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + } }, "node_modules/npm/node_modules/@npmcli/node-gyp": { - "version": "1.0.2", + "version": "3.0.0", "dev": true, "inBundle": true, - "license": "ISC" + "license": "ISC", + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + } }, "node_modules/npm/node_modules/@npmcli/package-json": { - "version": "1.0.1", + "version": "5.1.1", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "json-parse-even-better-errors": "^2.3.1" + "@npmcli/git": "^5.0.0", + "glob": "^10.2.2", + "hosted-git-info": "^7.0.0", + "json-parse-even-better-errors": "^3.0.0", + "normalize-package-data": "^6.0.0", + "proc-log": "^4.0.0", + "semver": "^7.5.3" + }, + "engines": { + "node": "^16.14.0 || >=18.0.0" } }, "node_modules/npm/node_modules/@npmcli/promise-spawn": { - "version": "1.3.2", + "version": "7.0.2", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "infer-owner": "^1.0.4" + "which": "^4.0.0" + }, + "engines": { + "node": "^16.14.0 || >=18.0.0" } }, - "node_modules/npm/node_modules/@npmcli/run-script": { - "version": "1.8.6", + "node_modules/npm/node_modules/@npmcli/query": { + "version": "3.1.0", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "@npmcli/node-gyp": "^1.0.2", - "@npmcli/promise-spawn": "^1.3.2", - "node-gyp": "^7.1.0", - "read-package-json-fast": "^2.0.1" + "postcss-selector-parser": "^6.0.10" + }, + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, - "node_modules/npm/node_modules/@tootallnate/once": { - "version": "1.1.2", + "node_modules/npm/node_modules/@npmcli/redact": { + "version": "2.0.0", "dev": true, "inBundle": true, - "license": "MIT", + "license": "ISC", "engines": { - "node": ">= 6" + "node": "^16.14.0 || >=18.0.0" } }, - "node_modules/npm/node_modules/abbrev": { - "version": "1.1.1", - "dev": true, - "inBundle": true, - "license": "ISC" - }, - "node_modules/npm/node_modules/agent-base": { - "version": "6.0.2", + "node_modules/npm/node_modules/@npmcli/run-script": { + "version": "8.1.0", "dev": true, "inBundle": true, - "license": "MIT", + "license": "ISC", "dependencies": { - "debug": "4" + "@npmcli/node-gyp": "^3.0.0", + "@npmcli/package-json": "^5.0.0", + "@npmcli/promise-spawn": "^7.0.0", + "node-gyp": "^10.0.0", + "proc-log": "^4.0.0", + "which": "^4.0.0" }, "engines": { - "node": ">= 6.0.0" + "node": "^16.14.0 || >=18.0.0" } }, - "node_modules/npm/node_modules/agentkeepalive": { - "version": "4.1.4", + "node_modules/npm/node_modules/@pkgjs/parseargs": { + "version": "0.11.0", "dev": true, "inBundle": true, "license": "MIT", - "dependencies": { - "debug": "^4.1.0", - "depd": "^1.1.2", - "humanize-ms": "^1.2.1" - }, + "optional": true, "engines": { - "node": ">= 8.0.0" + "node": ">=14" } }, - "node_modules/npm/node_modules/aggregate-error": { - "version": "3.1.0", + "node_modules/npm/node_modules/@sigstore/bundle": { + "version": "2.3.2", "dev": true, "inBundle": true, - "license": "MIT", + "license": "Apache-2.0", "dependencies": { - "clean-stack": "^2.0.0", - "indent-string": "^4.0.0" + "@sigstore/protobuf-specs": "^0.3.2" }, "engines": { - "node": ">=8" + "node": "^16.14.0 || >=18.0.0" } }, - "node_modules/npm/node_modules/ajv": { - "version": "6.12.6", + "node_modules/npm/node_modules/@sigstore/core": { + "version": "1.1.0", "dev": true, "inBundle": true, - "license": "MIT", - "dependencies": { - "fast-deep-equal": "^3.1.1", - "fast-json-stable-stringify": "^2.0.0", - "json-schema-traverse": "^0.4.1", - "uri-js": "^4.2.2" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/epoberezkin" + "license": "Apache-2.0", + "engines": { + "node": "^16.14.0 || >=18.0.0" } }, - "node_modules/npm/node_modules/ansi-regex": { - "version": "2.1.1", + "node_modules/npm/node_modules/@sigstore/protobuf-specs": { + "version": "0.3.2", "dev": true, "inBundle": true, - "license": "MIT", + "license": "Apache-2.0", "engines": { - "node": ">=0.10.0" + "node": "^16.14.0 || >=18.0.0" } }, - "node_modules/npm/node_modules/ansi-styles": { - "version": "4.3.0", + "node_modules/npm/node_modules/@sigstore/sign": { + "version": "2.3.2", "dev": true, "inBundle": true, - "license": "MIT", + "license": "Apache-2.0", "dependencies": { - "color-convert": "^2.0.1" + "@sigstore/bundle": "^2.3.2", + "@sigstore/core": "^1.0.0", + "@sigstore/protobuf-specs": "^0.3.2", + "make-fetch-happen": "^13.0.1", + "proc-log": "^4.2.0", + "promise-retry": "^2.0.1" }, "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" + "node": "^16.14.0 || >=18.0.0" } }, - "node_modules/npm/node_modules/ansicolors": { - "version": "0.3.2", + "node_modules/npm/node_modules/@sigstore/tuf": { + "version": "2.3.4", "dev": true, "inBundle": true, - "license": "MIT" + "license": "Apache-2.0", + "dependencies": { + "@sigstore/protobuf-specs": "^0.3.2", + "tuf-js": "^2.2.1" + }, + "engines": { + "node": "^16.14.0 || >=18.0.0" + } }, - "node_modules/npm/node_modules/ansistyles": { - "version": "0.1.3", + "node_modules/npm/node_modules/@sigstore/verify": { + "version": "1.2.1", "dev": true, "inBundle": true, - "license": "MIT" + "license": "Apache-2.0", + "dependencies": { + "@sigstore/bundle": "^2.3.2", + "@sigstore/core": "^1.1.0", + "@sigstore/protobuf-specs": "^0.3.2" + }, + "engines": { + "node": "^16.14.0 || >=18.0.0" + } }, - "node_modules/npm/node_modules/aproba": { + "node_modules/npm/node_modules/@tufjs/canonical-json": { "version": "2.0.0", "dev": true, "inBundle": true, - "license": "ISC" - }, - "node_modules/npm/node_modules/archy": { - "version": "1.0.0", - "dev": true, - "inBundle": true, - "license": "MIT" + "license": "MIT", + "engines": { + "node": "^16.14.0 || >=18.0.0" + } }, - "node_modules/npm/node_modules/are-we-there-yet": { - "version": "1.1.6", + "node_modules/npm/node_modules/@tufjs/models": { + "version": "2.0.1", "dev": true, "inBundle": true, - "license": "ISC", + "license": "MIT", "dependencies": { - "delegates": "^1.0.0", - "readable-stream": "^3.6.0" + "@tufjs/canonical-json": "2.0.0", + "minimatch": "^9.0.4" }, "engines": { - "node": ">=10" + "node": "^16.14.0 || >=18.0.0" } }, - "node_modules/npm/node_modules/asap": { - "version": "2.0.6", + "node_modules/npm/node_modules/abbrev": { + "version": "2.0.0", "dev": true, "inBundle": true, - "license": "MIT" + "license": "ISC", + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + } }, - "node_modules/npm/node_modules/asn1": { - "version": "0.2.4", + "node_modules/npm/node_modules/agent-base": { + "version": "7.1.1", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "safer-buffer": "~2.1.0" + "debug": "^4.3.4" + }, + "engines": { + "node": ">= 14" } }, - "node_modules/npm/node_modules/assert-plus": { - "version": "1.0.0", + "node_modules/npm/node_modules/aggregate-error": { + "version": "3.1.0", "dev": true, "inBundle": true, "license": "MIT", + "dependencies": { + "clean-stack": "^2.0.0", + "indent-string": "^4.0.0" + }, "engines": { - "node": ">=0.8" + "node": ">=8" } }, - "node_modules/npm/node_modules/asynckit": { - "version": "0.4.0", + "node_modules/npm/node_modules/ansi-regex": { + "version": "5.0.1", "dev": true, "inBundle": true, - "license": "MIT" + "license": "MIT", + "engines": { + "node": ">=8" + } }, - "node_modules/npm/node_modules/aws-sign2": { - "version": "0.7.0", + "node_modules/npm/node_modules/ansi-styles": { + "version": "6.2.1", "dev": true, "inBundle": true, - "license": "Apache-2.0", + "license": "MIT", "engines": { - "node": "*" + "node": ">=12" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, - "node_modules/npm/node_modules/aws4": { - "version": "1.11.0", + "node_modules/npm/node_modules/aproba": { + "version": "2.0.0", "dev": true, "inBundle": true, - "license": "MIT" + "license": "ISC" }, - "node_modules/npm/node_modules/balanced-match": { - "version": "1.0.2", + "node_modules/npm/node_modules/archy": { + "version": "1.0.0", "dev": true, "inBundle": true, "license": "MIT" }, - "node_modules/npm/node_modules/bcrypt-pbkdf": { + "node_modules/npm/node_modules/balanced-match": { "version": "1.0.2", "dev": true, "inBundle": true, - "license": "BSD-3-Clause", - "dependencies": { - "tweetnacl": "^0.14.3" - } + "license": "MIT" }, "node_modules/npm/node_modules/bin-links": { - "version": "2.2.1", + "version": "4.0.4", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "cmd-shim": "^4.0.1", - "mkdirp": "^1.0.3", - "npm-normalize-package-bin": "^1.0.0", - "read-cmd-shim": "^2.0.0", - "rimraf": "^3.0.0", - "write-file-atomic": "^3.0.3" + "cmd-shim": "^6.0.0", + "npm-normalize-package-bin": "^3.0.0", + "read-cmd-shim": "^4.0.0", + "write-file-atomic": "^5.0.0" }, "engines": { - "node": ">=10" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/npm/node_modules/binary-extensions": { - "version": "2.2.0", + "version": "2.3.0", "dev": true, "inBundle": true, "license": "MIT", "engines": { "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, "node_modules/npm/node_modules/brace-expansion": { - "version": "1.1.11", + "version": "2.0.1", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "balanced-match": "^1.0.0", - "concat-map": "0.0.1" + "balanced-match": "^1.0.0" } }, - "node_modules/npm/node_modules/builtins": { - "version": "1.0.3", - "dev": true, - "inBundle": true, - "license": "MIT" - }, "node_modules/npm/node_modules/cacache": { - "version": "15.3.0", + "version": "18.0.3", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "@npmcli/fs": "^1.0.0", - "@npmcli/move-file": "^1.0.1", - "chownr": "^2.0.0", - "fs-minipass": "^2.0.0", - "glob": "^7.1.4", - "infer-owner": "^1.0.4", - "lru-cache": "^6.0.0", - "minipass": "^3.1.1", - "minipass-collect": "^1.0.2", + "@npmcli/fs": "^3.1.0", + "fs-minipass": "^3.0.0", + "glob": "^10.2.2", + "lru-cache": "^10.0.1", + "minipass": "^7.0.3", + "minipass-collect": "^2.0.1", "minipass-flush": "^1.0.5", - "minipass-pipeline": "^1.2.2", - "mkdirp": "^1.0.3", + "minipass-pipeline": "^1.2.4", "p-map": "^4.0.0", - "promise-inflight": "^1.0.1", - "rimraf": "^3.0.2", - "ssri": "^8.0.1", - "tar": "^6.0.2", - "unique-filename": "^1.1.1" + "ssri": "^10.0.0", + "tar": "^6.1.11", + "unique-filename": "^3.0.0" }, "engines": { - "node": ">= 10" + "node": "^16.14.0 || >=18.0.0" } }, - "node_modules/npm/node_modules/caseless": { - "version": "0.12.0", - "dev": true, - "inBundle": true, - "license": "Apache-2.0" - }, "node_modules/npm/node_modules/chalk": { - "version": "4.1.2", + "version": "5.3.0", "dev": true, "inBundle": true, "license": "MIT", - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, "engines": { - "node": ">=10" + "node": "^12.17.0 || ^14.13 || >=16.0.0" }, "funding": { "url": "https://github.com/chalk/chalk?sponsor=1" @@ -14117,128 +14550,62 @@ "node": ">=10" } }, - "node_modules/npm/node_modules/cidr-regex": { - "version": "3.1.1", - "dev": true, - "inBundle": true, - "license": "BSD-2-Clause", - "dependencies": { - "ip-regex": "^4.1.0" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/npm/node_modules/clean-stack": { - "version": "2.2.0", - "dev": true, - "inBundle": true, - "license": "MIT", - "engines": { - "node": ">=6" - } - }, - "node_modules/npm/node_modules/cli-columns": { - "version": "3.1.2", + "node_modules/npm/node_modules/ci-info": { + "version": "4.0.0", "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/sibiraj-s" + } + ], "inBundle": true, "license": "MIT", - "dependencies": { - "string-width": "^2.0.0", - "strip-ansi": "^3.0.1" - }, "engines": { - "node": ">= 4" + "node": ">=8" } }, - "node_modules/npm/node_modules/cli-table3": { - "version": "0.6.0", + "node_modules/npm/node_modules/cidr-regex": { + "version": "4.1.1", "dev": true, "inBundle": true, - "license": "MIT", + "license": "BSD-2-Clause", "dependencies": { - "object-assign": "^4.1.0", - "string-width": "^4.2.0" + "ip-regex": "^5.0.0" }, "engines": { - "node": "10.* || >= 12.*" - }, - "optionalDependencies": { - "colors": "^1.1.2" - } - }, - "node_modules/npm/node_modules/cli-table3/node_modules/ansi-regex": { - "version": "5.0.0", - "dev": true, - "inBundle": true, - "license": "MIT", - "engines": { - "node": ">=8" - } - }, - "node_modules/npm/node_modules/cli-table3/node_modules/is-fullwidth-code-point": { - "version": "3.0.0", - "dev": true, - "inBundle": true, - "license": "MIT", - "engines": { - "node": ">=8" + "node": ">=14" } }, - "node_modules/npm/node_modules/cli-table3/node_modules/string-width": { - "version": "4.2.2", + "node_modules/npm/node_modules/clean-stack": { + "version": "2.2.0", "dev": true, "inBundle": true, "license": "MIT", - "dependencies": { - "emoji-regex": "^8.0.0", - "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.0" - }, "engines": { - "node": ">=8" + "node": ">=6" } }, - "node_modules/npm/node_modules/cli-table3/node_modules/strip-ansi": { - "version": "6.0.0", + "node_modules/npm/node_modules/cli-columns": { + "version": "4.0.0", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "ansi-regex": "^5.0.0" + "string-width": "^4.2.3", + "strip-ansi": "^6.0.1" }, "engines": { - "node": ">=8" - } - }, - "node_modules/npm/node_modules/clone": { - "version": "1.0.4", - "dev": true, - "inBundle": true, - "license": "MIT", - "engines": { - "node": ">=0.8" + "node": ">= 10" } }, "node_modules/npm/node_modules/cmd-shim": { - "version": "4.1.0", + "version": "6.0.3", "dev": true, "inBundle": true, "license": "ISC", - "dependencies": { - "mkdirp-infer-owner": "^2.0.0" - }, "engines": { - "node": ">=10" - } - }, - "node_modules/npm/node_modules/code-point-at": { - "version": "1.1.0", - "dev": true, - "inBundle": true, - "license": "MIT", - "engines": { - "node": ">=0.10.0" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/npm/node_modules/color-convert": { @@ -14259,85 +14626,55 @@ "inBundle": true, "license": "MIT" }, - "node_modules/npm/node_modules/color-support": { - "version": "1.1.3", - "dev": true, - "inBundle": true, - "license": "ISC", - "bin": { - "color-support": "bin.js" - } - }, - "node_modules/npm/node_modules/colors": { - "version": "1.4.0", + "node_modules/npm/node_modules/common-ancestor-path": { + "version": "1.0.1", "dev": true, "inBundle": true, - "license": "MIT", - "optional": true, - "engines": { - "node": ">=0.1.90" - } + "license": "ISC" }, - "node_modules/npm/node_modules/columnify": { - "version": "1.5.4", + "node_modules/npm/node_modules/cross-spawn": { + "version": "7.0.3", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "strip-ansi": "^3.0.0", - "wcwidth": "^1.0.0" + "path-key": "^3.1.0", + "shebang-command": "^2.0.0", + "which": "^2.0.1" + }, + "engines": { + "node": ">= 8" } }, - "node_modules/npm/node_modules/combined-stream": { - "version": "1.0.8", + "node_modules/npm/node_modules/cross-spawn/node_modules/which": { + "version": "2.0.2", "dev": true, "inBundle": true, - "license": "MIT", + "license": "ISC", "dependencies": { - "delayed-stream": "~1.0.0" + "isexe": "^2.0.0" + }, + "bin": { + "node-which": "bin/node-which" }, "engines": { - "node": ">= 0.8" + "node": ">= 8" } }, - "node_modules/npm/node_modules/common-ancestor-path": { - "version": "1.0.1", - "dev": true, - "inBundle": true, - "license": "ISC" - }, - "node_modules/npm/node_modules/concat-map": { - "version": "0.0.1", - "dev": true, - "inBundle": true, - "license": "MIT" - }, - "node_modules/npm/node_modules/console-control-strings": { - "version": "1.1.0", - "dev": true, - "inBundle": true, - "license": "ISC" - }, - "node_modules/npm/node_modules/core-util-is": { - "version": "1.0.2", - "dev": true, - "inBundle": true, - "license": "MIT" - }, - "node_modules/npm/node_modules/dashdash": { - "version": "1.14.1", + "node_modules/npm/node_modules/cssesc": { + "version": "3.0.0", "dev": true, "inBundle": true, "license": "MIT", - "dependencies": { - "assert-plus": "^1.0.0" + "bin": { + "cssesc": "bin/cssesc" }, "engines": { - "node": ">=0.10" + "node": ">=4" } }, "node_modules/npm/node_modules/debug": { - "version": "4.3.2", + "version": "4.3.4", "dev": true, "inBundle": true, "license": "MIT", @@ -14359,60 +14696,8 @@ "inBundle": true, "license": "MIT" }, - "node_modules/npm/node_modules/debuglog": { - "version": "1.0.1", - "dev": true, - "inBundle": true, - "license": "MIT", - "engines": { - "node": "*" - } - }, - "node_modules/npm/node_modules/defaults": { - "version": "1.0.3", - "dev": true, - "inBundle": true, - "license": "MIT", - "dependencies": { - "clone": "^1.0.2" - } - }, - "node_modules/npm/node_modules/delayed-stream": { - "version": "1.0.0", - "dev": true, - "inBundle": true, - "license": "MIT", - "engines": { - "node": ">=0.4.0" - } - }, - "node_modules/npm/node_modules/delegates": { - "version": "1.0.0", - "dev": true, - "inBundle": true, - "license": "MIT" - }, - "node_modules/npm/node_modules/depd": { - "version": "1.1.2", - "dev": true, - "inBundle": true, - "license": "MIT", - "engines": { - "node": ">= 0.6" - } - }, - "node_modules/npm/node_modules/dezalgo": { - "version": "1.0.3", - "dev": true, - "inBundle": true, - "license": "ISC", - "dependencies": { - "asap": "^2.0.0", - "wrappy": "1" - } - }, "node_modules/npm/node_modules/diff": { - "version": "5.0.0", + "version": "5.2.0", "dev": true, "inBundle": true, "license": "BSD-3-Clause", @@ -14420,15 +14705,11 @@ "node": ">=0.3.1" } }, - "node_modules/npm/node_modules/ecc-jsbn": { - "version": "0.1.2", + "node_modules/npm/node_modules/eastasianwidth": { + "version": "0.2.0", "dev": true, "inBundle": true, - "license": "MIT", - "dependencies": { - "jsbn": "~0.1.0", - "safer-buffer": "^2.1.0" - } + "license": "MIT" }, "node_modules/npm/node_modules/emoji-regex": { "version": "8.0.0", @@ -14447,257 +14728,154 @@ } }, "node_modules/npm/node_modules/env-paths": { - "version": "2.2.1", - "dev": true, - "inBundle": true, - "license": "MIT", - "engines": { - "node": ">=6" - } - }, - "node_modules/npm/node_modules/err-code": { - "version": "2.0.3", - "dev": true, - "inBundle": true, - "license": "MIT" - }, - "node_modules/npm/node_modules/extend": { - "version": "3.0.2", - "dev": true, - "inBundle": true, - "license": "MIT" - }, - "node_modules/npm/node_modules/extsprintf": { - "version": "1.3.0", - "dev": true, - "engines": [ - "node >=0.6.0" - ], - "inBundle": true, - "license": "MIT" - }, - "node_modules/npm/node_modules/fast-deep-equal": { - "version": "3.1.3", + "version": "2.2.1", "dev": true, "inBundle": true, - "license": "MIT" + "license": "MIT", + "engines": { + "node": ">=6" + } }, - "node_modules/npm/node_modules/fast-json-stable-stringify": { - "version": "2.1.0", + "node_modules/npm/node_modules/err-code": { + "version": "2.0.3", "dev": true, "inBundle": true, "license": "MIT" }, - "node_modules/npm/node_modules/fastest-levenshtein": { - "version": "1.0.12", + "node_modules/npm/node_modules/exponential-backoff": { + "version": "3.1.1", "dev": true, "inBundle": true, - "license": "MIT" + "license": "Apache-2.0" }, - "node_modules/npm/node_modules/forever-agent": { - "version": "0.6.1", + "node_modules/npm/node_modules/fastest-levenshtein": { + "version": "1.0.16", "dev": true, "inBundle": true, - "license": "Apache-2.0", + "license": "MIT", "engines": { - "node": "*" + "node": ">= 4.9.1" } }, - "node_modules/npm/node_modules/fs-minipass": { - "version": "2.1.0", + "node_modules/npm/node_modules/foreground-child": { + "version": "3.1.1", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "minipass": "^3.0.0" + "cross-spawn": "^7.0.0", + "signal-exit": "^4.0.1" }, "engines": { - "node": ">= 8" + "node": ">=14" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" } }, - "node_modules/npm/node_modules/fs.realpath": { - "version": "1.0.0", - "dev": true, - "inBundle": true, - "license": "ISC" - }, - "node_modules/npm/node_modules/function-bind": { - "version": "1.1.1", - "dev": true, - "inBundle": true, - "license": "MIT" - }, - "node_modules/npm/node_modules/gauge": { - "version": "3.0.1", + "node_modules/npm/node_modules/fs-minipass": { + "version": "3.0.3", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "aproba": "^1.0.3 || ^2.0.0", - "color-support": "^1.1.2", - "console-control-strings": "^1.0.0", - "has-unicode": "^2.0.1", - "object-assign": "^4.1.1", - "signal-exit": "^3.0.0", - "string-width": "^1.0.1 || ^2.0.0", - "strip-ansi": "^3.0.1 || ^4.0.0", - "wide-align": "^1.1.2" + "minipass": "^7.0.3" }, "engines": { - "node": ">=10" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, - "node_modules/npm/node_modules/getpass": { - "version": "0.1.7", + "node_modules/npm/node_modules/function-bind": { + "version": "1.1.2", "dev": true, "inBundle": true, "license": "MIT", - "dependencies": { - "assert-plus": "^1.0.0" + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, "node_modules/npm/node_modules/glob": { - "version": "7.2.0", + "version": "10.4.1", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "fs.realpath": "^1.0.0", - "inflight": "^1.0.4", - "inherits": "2", - "minimatch": "^3.0.4", - "once": "^1.3.0", - "path-is-absolute": "^1.0.0" + "foreground-child": "^3.1.0", + "jackspeak": "^3.1.2", + "minimatch": "^9.0.4", + "minipass": "^7.1.2", + "path-scurry": "^1.11.1" + }, + "bin": { + "glob": "dist/esm/bin.mjs" }, "engines": { - "node": "*" + "node": ">=16 || 14 >=14.18" }, "funding": { "url": "https://github.com/sponsors/isaacs" } }, "node_modules/npm/node_modules/graceful-fs": { - "version": "4.2.8", + "version": "4.2.11", "dev": true, "inBundle": true, "license": "ISC" }, - "node_modules/npm/node_modules/har-schema": { - "version": "2.0.0", - "dev": true, - "inBundle": true, - "license": "ISC", - "engines": { - "node": ">=4" - } - }, - "node_modules/npm/node_modules/har-validator": { - "version": "5.1.5", - "dev": true, - "inBundle": true, - "license": "MIT", - "dependencies": { - "ajv": "^6.12.3", - "har-schema": "^2.0.0" - }, - "engines": { - "node": ">=6" - } - }, - "node_modules/npm/node_modules/has": { - "version": "1.0.3", + "node_modules/npm/node_modules/hasown": { + "version": "2.0.2", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "function-bind": "^1.1.1" + "function-bind": "^1.1.2" }, "engines": { - "node": ">= 0.4.0" - } - }, - "node_modules/npm/node_modules/has-flag": { - "version": "4.0.0", - "dev": true, - "inBundle": true, - "license": "MIT", - "engines": { - "node": ">=8" + "node": ">= 0.4" } }, - "node_modules/npm/node_modules/has-unicode": { - "version": "2.0.1", - "dev": true, - "inBundle": true, - "license": "ISC" - }, "node_modules/npm/node_modules/hosted-git-info": { - "version": "4.0.2", + "version": "7.0.2", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "lru-cache": "^6.0.0" + "lru-cache": "^10.0.1" }, "engines": { - "node": ">=10" + "node": "^16.14.0 || >=18.0.0" } }, "node_modules/npm/node_modules/http-cache-semantics": { - "version": "4.1.0", + "version": "4.1.1", "dev": true, "inBundle": true, "license": "BSD-2-Clause" }, "node_modules/npm/node_modules/http-proxy-agent": { - "version": "4.0.1", - "dev": true, - "inBundle": true, - "license": "MIT", - "dependencies": { - "@tootallnate/once": "1", - "agent-base": "6", - "debug": "4" - }, - "engines": { - "node": ">= 6" - } - }, - "node_modules/npm/node_modules/http-signature": { - "version": "1.2.0", + "version": "7.0.2", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "assert-plus": "^1.0.0", - "jsprim": "^1.2.2", - "sshpk": "^1.7.0" + "agent-base": "^7.1.0", + "debug": "^4.3.4" }, "engines": { - "node": ">=0.8", - "npm": ">=1.3.7" + "node": ">= 14" } }, "node_modules/npm/node_modules/https-proxy-agent": { - "version": "5.0.0", + "version": "7.0.4", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "agent-base": "6", + "agent-base": "^7.0.2", "debug": "4" }, "engines": { - "node": ">= 6" - } - }, - "node_modules/npm/node_modules/humanize-ms": { - "version": "1.2.1", - "dev": true, - "inBundle": true, - "license": "MIT", - "dependencies": { - "ms": "^2.0.0" + "node": ">= 14" } }, "node_modules/npm/node_modules/iconv-lite": { @@ -14714,12 +14892,15 @@ } }, "node_modules/npm/node_modules/ignore-walk": { - "version": "3.0.4", + "version": "6.0.5", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "minimatch": "^3.0.4" + "minimatch": "^9.0.0" + }, + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/npm/node_modules/imurmurhash": { @@ -14740,101 +14921,89 @@ "node": ">=8" } }, - "node_modules/npm/node_modules/infer-owner": { - "version": "1.0.4", - "dev": true, - "inBundle": true, - "license": "ISC" - }, - "node_modules/npm/node_modules/inflight": { - "version": "1.0.6", - "dev": true, - "inBundle": true, - "license": "ISC", - "dependencies": { - "once": "^1.3.0", - "wrappy": "1" - } - }, - "node_modules/npm/node_modules/inherits": { - "version": "2.0.4", - "dev": true, - "inBundle": true, - "license": "ISC" - }, "node_modules/npm/node_modules/ini": { - "version": "2.0.0", + "version": "4.1.3", "dev": true, "inBundle": true, "license": "ISC", "engines": { - "node": ">=10" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/npm/node_modules/init-package-json": { - "version": "2.0.5", + "version": "6.0.3", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "npm-package-arg": "^8.1.5", - "promzard": "^0.3.0", - "read": "~1.0.1", - "read-package-json": "^4.1.1", + "@npmcli/package-json": "^5.0.0", + "npm-package-arg": "^11.0.0", + "promzard": "^1.0.0", + "read": "^3.0.1", "semver": "^7.3.5", "validate-npm-package-license": "^3.0.4", - "validate-npm-package-name": "^3.0.0" + "validate-npm-package-name": "^5.0.0" }, "engines": { - "node": ">=10" + "node": "^16.14.0 || >=18.0.0" } }, - "node_modules/npm/node_modules/ip": { - "version": "1.1.5", + "node_modules/npm/node_modules/ip-address": { + "version": "9.0.5", "dev": true, "inBundle": true, - "license": "MIT" + "license": "MIT", + "dependencies": { + "jsbn": "1.1.0", + "sprintf-js": "^1.1.3" + }, + "engines": { + "node": ">= 12" + } }, "node_modules/npm/node_modules/ip-regex": { - "version": "4.3.0", + "version": "5.0.0", "dev": true, "inBundle": true, "license": "MIT", "engines": { - "node": ">=8" + "node": "^12.20.0 || ^14.13.1 || >=16.0.0" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, "node_modules/npm/node_modules/is-cidr": { - "version": "4.0.2", + "version": "5.1.0", "dev": true, "inBundle": true, "license": "BSD-2-Clause", "dependencies": { - "cidr-regex": "^3.1.1" + "cidr-regex": "^4.1.1" }, "engines": { - "node": ">=10" + "node": ">=14" } }, "node_modules/npm/node_modules/is-core-module": { - "version": "2.7.0", + "version": "2.13.1", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "has": "^1.0.3" + "hasown": "^2.0.0" }, "funding": { "url": "https://github.com/sponsors/ljharb" } }, "node_modules/npm/node_modules/is-fullwidth-code-point": { - "version": "2.0.0", + "version": "3.0.0", "dev": true, "inBundle": true, "license": "MIT", "engines": { - "node": ">=4" + "node": ">=8" } }, "node_modules/npm/node_modules/is-lambda": { @@ -14843,46 +15012,44 @@ "inBundle": true, "license": "MIT" }, - "node_modules/npm/node_modules/is-typedarray": { - "version": "1.0.0", - "dev": true, - "inBundle": true, - "license": "MIT" - }, "node_modules/npm/node_modules/isexe": { "version": "2.0.0", "dev": true, "inBundle": true, "license": "ISC" }, - "node_modules/npm/node_modules/isstream": { - "version": "0.1.2", + "node_modules/npm/node_modules/jackspeak": { + "version": "3.1.2", "dev": true, "inBundle": true, - "license": "MIT" + "license": "BlueOak-1.0.0", + "dependencies": { + "@isaacs/cliui": "^8.0.2" + }, + "engines": { + "node": ">=14" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + }, + "optionalDependencies": { + "@pkgjs/parseargs": "^0.11.0" + } }, "node_modules/npm/node_modules/jsbn": { - "version": "0.1.1", + "version": "1.1.0", "dev": true, "inBundle": true, "license": "MIT" }, "node_modules/npm/node_modules/json-parse-even-better-errors": { - "version": "2.3.1", - "dev": true, - "inBundle": true, - "license": "MIT" - }, - "node_modules/npm/node_modules/json-schema": { - "version": "0.2.3", - "dev": true, - "inBundle": true - }, - "node_modules/npm/node_modules/json-schema-traverse": { - "version": "0.4.1", + "version": "3.0.2", "dev": true, "inBundle": true, - "license": "MIT" + "license": "MIT", + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + } }, "node_modules/npm/node_modules/json-stringify-nice": { "version": "1.1.4", @@ -14893,12 +15060,6 @@ "url": "https://github.com/sponsors/isaacs" } }, - "node_modules/npm/node_modules/json-stringify-safe": { - "version": "5.0.1", - "dev": true, - "inBundle": true, - "license": "ISC" - }, "node_modules/npm/node_modules/jsonparse": { "version": "1.3.1", "dev": true, @@ -14908,303 +15069,267 @@ "inBundle": true, "license": "MIT" }, - "node_modules/npm/node_modules/jsprim": { - "version": "1.4.1", - "dev": true, - "engines": [ - "node >=0.6.0" - ], - "inBundle": true, - "license": "MIT", - "dependencies": { - "assert-plus": "1.0.0", - "extsprintf": "1.3.0", - "json-schema": "0.2.3", - "verror": "1.10.0" - } - }, "node_modules/npm/node_modules/just-diff": { - "version": "3.1.1", + "version": "6.0.2", "dev": true, "inBundle": true, "license": "MIT" }, "node_modules/npm/node_modules/just-diff-apply": { - "version": "3.0.0", + "version": "5.5.0", "dev": true, "inBundle": true, "license": "MIT" }, "node_modules/npm/node_modules/libnpmaccess": { - "version": "4.0.3", + "version": "8.0.6", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "aproba": "^2.0.0", - "minipass": "^3.1.1", - "npm-package-arg": "^8.1.2", - "npm-registry-fetch": "^11.0.0" + "npm-package-arg": "^11.0.2", + "npm-registry-fetch": "^17.0.1" }, "engines": { - "node": ">=10" + "node": "^16.14.0 || >=18.0.0" } }, "node_modules/npm/node_modules/libnpmdiff": { - "version": "2.0.4", + "version": "6.1.3", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "@npmcli/disparity-colors": "^1.0.1", - "@npmcli/installed-package-contents": "^1.0.7", - "binary-extensions": "^2.2.0", - "diff": "^5.0.0", - "minimatch": "^3.0.4", - "npm-package-arg": "^8.1.4", - "pacote": "^11.3.4", - "tar": "^6.1.0" + "@npmcli/arborist": "^7.5.3", + "@npmcli/installed-package-contents": "^2.1.0", + "binary-extensions": "^2.3.0", + "diff": "^5.1.0", + "minimatch": "^9.0.4", + "npm-package-arg": "^11.0.2", + "pacote": "^18.0.6", + "tar": "^6.2.1" }, "engines": { - "node": ">=10" + "node": "^16.14.0 || >=18.0.0" } }, "node_modules/npm/node_modules/libnpmexec": { - "version": "2.0.1", + "version": "8.1.2", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "@npmcli/arborist": "^2.3.0", - "@npmcli/ci-detect": "^1.3.0", - "@npmcli/run-script": "^1.8.4", - "chalk": "^4.1.0", - "mkdirp-infer-owner": "^2.0.0", - "npm-package-arg": "^8.1.2", - "pacote": "^11.3.1", - "proc-log": "^1.0.0", - "read": "^1.0.7", - "read-package-json-fast": "^2.0.2", - "walk-up-path": "^1.0.0" + "@npmcli/arborist": "^7.5.3", + "@npmcli/run-script": "^8.1.0", + "ci-info": "^4.0.0", + "npm-package-arg": "^11.0.2", + "pacote": "^18.0.6", + "proc-log": "^4.2.0", + "read": "^3.0.1", + "read-package-json-fast": "^3.0.2", + "semver": "^7.3.7", + "walk-up-path": "^3.0.1" }, "engines": { - "node": ">=10" + "node": "^16.14.0 || >=18.0.0" } }, "node_modules/npm/node_modules/libnpmfund": { - "version": "1.1.0", + "version": "5.0.11", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "@npmcli/arborist": "^2.5.0" + "@npmcli/arborist": "^7.5.3" + }, + "engines": { + "node": "^16.14.0 || >=18.0.0" } }, "node_modules/npm/node_modules/libnpmhook": { - "version": "6.0.3", + "version": "10.0.5", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { "aproba": "^2.0.0", - "npm-registry-fetch": "^11.0.0" + "npm-registry-fetch": "^17.0.1" }, "engines": { - "node": ">=10" + "node": "^16.14.0 || >=18.0.0" } }, "node_modules/npm/node_modules/libnpmorg": { - "version": "2.0.3", + "version": "6.0.6", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { "aproba": "^2.0.0", - "npm-registry-fetch": "^11.0.0" + "npm-registry-fetch": "^17.0.1" }, "engines": { - "node": ">=10" + "node": "^16.14.0 || >=18.0.0" } }, "node_modules/npm/node_modules/libnpmpack": { - "version": "2.0.1", + "version": "7.0.3", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "@npmcli/run-script": "^1.8.3", - "npm-package-arg": "^8.1.0", - "pacote": "^11.2.6" + "@npmcli/arborist": "^7.5.3", + "@npmcli/run-script": "^8.1.0", + "npm-package-arg": "^11.0.2", + "pacote": "^18.0.6" }, "engines": { - "node": ">=10" + "node": "^16.14.0 || >=18.0.0" } }, "node_modules/npm/node_modules/libnpmpublish": { - "version": "4.0.2", + "version": "9.0.9", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "normalize-package-data": "^3.0.2", - "npm-package-arg": "^8.1.2", - "npm-registry-fetch": "^11.0.0", - "semver": "^7.1.3", - "ssri": "^8.0.1" + "ci-info": "^4.0.0", + "normalize-package-data": "^6.0.1", + "npm-package-arg": "^11.0.2", + "npm-registry-fetch": "^17.0.1", + "proc-log": "^4.2.0", + "semver": "^7.3.7", + "sigstore": "^2.2.0", + "ssri": "^10.0.6" }, "engines": { - "node": ">=10" + "node": "^16.14.0 || >=18.0.0" } }, "node_modules/npm/node_modules/libnpmsearch": { - "version": "3.1.2", + "version": "7.0.6", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "npm-registry-fetch": "^11.0.0" + "npm-registry-fetch": "^17.0.1" }, "engines": { - "node": ">=10" + "node": "^16.14.0 || >=18.0.0" } }, "node_modules/npm/node_modules/libnpmteam": { - "version": "2.0.4", + "version": "6.0.5", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { "aproba": "^2.0.0", - "npm-registry-fetch": "^11.0.0" + "npm-registry-fetch": "^17.0.1" }, "engines": { - "node": ">=10" + "node": "^16.14.0 || >=18.0.0" } }, "node_modules/npm/node_modules/libnpmversion": { - "version": "1.2.1", + "version": "6.0.3", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "@npmcli/git": "^2.0.7", - "@npmcli/run-script": "^1.8.4", - "json-parse-even-better-errors": "^2.3.1", - "semver": "^7.3.5", - "stringify-package": "^1.0.1" + "@npmcli/git": "^5.0.7", + "@npmcli/run-script": "^8.1.0", + "json-parse-even-better-errors": "^3.0.2", + "proc-log": "^4.2.0", + "semver": "^7.3.7" + }, + "engines": { + "node": "^16.14.0 || >=18.0.0" } }, "node_modules/npm/node_modules/lru-cache": { - "version": "6.0.0", + "version": "10.2.2", "dev": true, "inBundle": true, "license": "ISC", - "dependencies": { - "yallist": "^4.0.0" - }, "engines": { - "node": ">=10" + "node": "14 || >=16.14" } }, "node_modules/npm/node_modules/make-fetch-happen": { - "version": "9.1.0", + "version": "13.0.1", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "agentkeepalive": "^4.1.3", - "cacache": "^15.2.0", - "http-cache-semantics": "^4.1.0", - "http-proxy-agent": "^4.0.1", - "https-proxy-agent": "^5.0.0", + "@npmcli/agent": "^2.0.0", + "cacache": "^18.0.0", + "http-cache-semantics": "^4.1.1", "is-lambda": "^1.0.1", - "lru-cache": "^6.0.0", - "minipass": "^3.1.3", - "minipass-collect": "^1.0.2", - "minipass-fetch": "^1.3.2", + "minipass": "^7.0.2", + "minipass-fetch": "^3.0.0", "minipass-flush": "^1.0.5", "minipass-pipeline": "^1.2.4", - "negotiator": "^0.6.2", + "negotiator": "^0.6.3", + "proc-log": "^4.2.0", "promise-retry": "^2.0.1", - "socks-proxy-agent": "^6.0.0", - "ssri": "^8.0.0" - }, - "engines": { - "node": ">= 10" - } - }, - "node_modules/npm/node_modules/mime-db": { - "version": "1.49.0", - "dev": true, - "inBundle": true, - "license": "MIT", - "engines": { - "node": ">= 0.6" - } - }, - "node_modules/npm/node_modules/mime-types": { - "version": "2.1.32", - "dev": true, - "inBundle": true, - "license": "MIT", - "dependencies": { - "mime-db": "1.49.0" + "ssri": "^10.0.0" }, "engines": { - "node": ">= 0.6" + "node": "^16.14.0 || >=18.0.0" } }, "node_modules/npm/node_modules/minimatch": { - "version": "3.0.4", + "version": "9.0.4", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "brace-expansion": "^1.1.7" + "brace-expansion": "^2.0.1" }, "engines": { - "node": "*" + "node": ">=16 || 14 >=14.17" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" } }, "node_modules/npm/node_modules/minipass": { - "version": "3.1.5", + "version": "7.1.2", "dev": true, "inBundle": true, "license": "ISC", - "dependencies": { - "yallist": "^4.0.0" - }, "engines": { - "node": ">=8" + "node": ">=16 || 14 >=14.17" } }, "node_modules/npm/node_modules/minipass-collect": { - "version": "1.0.2", + "version": "2.0.1", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "minipass": "^3.0.0" + "minipass": "^7.0.3" }, "engines": { - "node": ">= 8" + "node": ">=16 || 14 >=14.17" } }, "node_modules/npm/node_modules/minipass-fetch": { - "version": "1.4.1", + "version": "3.0.5", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "minipass": "^3.1.0", + "minipass": "^7.0.3", "minipass-sized": "^1.0.3", - "minizlib": "^2.0.0" + "minizlib": "^2.1.2" }, "engines": { - "node": ">=8" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" }, "optionalDependencies": { - "encoding": "^0.1.12" + "encoding": "^0.1.13" } }, "node_modules/npm/node_modules/minipass-flush": { @@ -15219,6 +15344,18 @@ "node": ">= 8" } }, + "node_modules/npm/node_modules/minipass-flush/node_modules/minipass": { + "version": "3.3.6", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "yallist": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, "node_modules/npm/node_modules/minipass-json-stream": { "version": "1.0.1", "dev": true, @@ -15229,6 +15366,18 @@ "minipass": "^3.0.0" } }, + "node_modules/npm/node_modules/minipass-json-stream/node_modules/minipass": { + "version": "3.3.6", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "yallist": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, "node_modules/npm/node_modules/minipass-pipeline": { "version": "1.2.4", "dev": true, @@ -15241,6 +15390,18 @@ "node": ">=8" } }, + "node_modules/npm/node_modules/minipass-pipeline/node_modules/minipass": { + "version": "3.3.6", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "yallist": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, "node_modules/npm/node_modules/minipass-sized": { "version": "1.0.3", "dev": true, @@ -15253,6 +15414,18 @@ "node": ">=8" } }, + "node_modules/npm/node_modules/minipass-sized/node_modules/minipass": { + "version": "3.3.6", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "yallist": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, "node_modules/npm/node_modules/minizlib": { "version": "2.1.2", "dev": true, @@ -15266,27 +15439,25 @@ "node": ">= 8" } }, - "node_modules/npm/node_modules/mkdirp": { - "version": "1.0.4", + "node_modules/npm/node_modules/minizlib/node_modules/minipass": { + "version": "3.3.6", "dev": true, "inBundle": true, - "license": "MIT", - "bin": { - "mkdirp": "bin/cmd.js" + "license": "ISC", + "dependencies": { + "yallist": "^4.0.0" }, "engines": { - "node": ">=10" + "node": ">=8" } }, - "node_modules/npm/node_modules/mkdirp-infer-owner": { - "version": "2.0.0", + "node_modules/npm/node_modules/mkdirp": { + "version": "1.0.4", "dev": true, "inBundle": true, - "license": "ISC", - "dependencies": { - "chownr": "^2.0.0", - "infer-owner": "^1.0.4", - "mkdirp": "^1.0.3" + "license": "MIT", + "bin": { + "mkdirp": "bin/cmd.js" }, "engines": { "node": ">=10" @@ -15299,13 +15470,16 @@ "license": "MIT" }, "node_modules/npm/node_modules/mute-stream": { - "version": "0.0.8", + "version": "1.0.0", "dev": true, "inBundle": true, - "license": "ISC" + "license": "ISC", + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + } }, "node_modules/npm/node_modules/negotiator": { - "version": "0.6.2", + "version": "0.6.3", "dev": true, "inBundle": true, "license": "MIT", @@ -15314,142 +15488,91 @@ } }, "node_modules/npm/node_modules/node-gyp": { - "version": "7.1.2", + "version": "10.1.0", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { "env-paths": "^2.2.0", - "glob": "^7.1.4", - "graceful-fs": "^4.2.3", - "nopt": "^5.0.0", - "npmlog": "^4.1.2", - "request": "^2.88.2", - "rimraf": "^3.0.2", - "semver": "^7.3.2", - "tar": "^6.0.2", - "which": "^2.0.2" + "exponential-backoff": "^3.1.1", + "glob": "^10.3.10", + "graceful-fs": "^4.2.6", + "make-fetch-happen": "^13.0.0", + "nopt": "^7.0.0", + "proc-log": "^3.0.0", + "semver": "^7.3.5", + "tar": "^6.1.2", + "which": "^4.0.0" }, "bin": { "node-gyp": "bin/node-gyp.js" }, "engines": { - "node": ">= 10.12.0" - } - }, - "node_modules/npm/node_modules/node-gyp/node_modules/aproba": { - "version": "1.2.0", - "dev": true, - "inBundle": true, - "license": "ISC" - }, - "node_modules/npm/node_modules/node-gyp/node_modules/gauge": { - "version": "2.7.4", - "dev": true, - "inBundle": true, - "license": "ISC", - "dependencies": { - "aproba": "^1.0.3", - "console-control-strings": "^1.0.0", - "has-unicode": "^2.0.0", - "object-assign": "^4.1.0", - "signal-exit": "^3.0.0", - "string-width": "^1.0.1", - "strip-ansi": "^3.0.1", - "wide-align": "^1.1.0" - } - }, - "node_modules/npm/node_modules/node-gyp/node_modules/is-fullwidth-code-point": { - "version": "1.0.0", - "dev": true, - "inBundle": true, - "license": "MIT", - "dependencies": { - "number-is-nan": "^1.0.0" - }, - "engines": { - "node": ">=0.10.0" + "node": "^16.14.0 || >=18.0.0" } }, - "node_modules/npm/node_modules/node-gyp/node_modules/npmlog": { - "version": "4.1.2", + "node_modules/npm/node_modules/node-gyp/node_modules/proc-log": { + "version": "3.0.0", "dev": true, "inBundle": true, "license": "ISC", - "dependencies": { - "are-we-there-yet": "~1.1.2", - "console-control-strings": "~1.1.0", - "gauge": "~2.7.3", - "set-blocking": "~2.0.0" - } - }, - "node_modules/npm/node_modules/node-gyp/node_modules/string-width": { - "version": "1.0.2", - "dev": true, - "inBundle": true, - "license": "MIT", - "dependencies": { - "code-point-at": "^1.0.0", - "is-fullwidth-code-point": "^1.0.0", - "strip-ansi": "^3.0.0" - }, "engines": { - "node": ">=0.10.0" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/npm/node_modules/nopt": { - "version": "5.0.0", + "version": "7.2.1", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "abbrev": "1" + "abbrev": "^2.0.0" }, "bin": { "nopt": "bin/nopt.js" }, "engines": { - "node": ">=6" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/npm/node_modules/normalize-package-data": { - "version": "3.0.3", + "version": "6.0.1", "dev": true, "inBundle": true, "license": "BSD-2-Clause", "dependencies": { - "hosted-git-info": "^4.0.1", - "is-core-module": "^2.5.0", - "semver": "^7.3.4", - "validate-npm-package-license": "^3.0.1" + "hosted-git-info": "^7.0.0", + "is-core-module": "^2.8.1", + "semver": "^7.3.5", + "validate-npm-package-license": "^3.0.4" }, "engines": { - "node": ">=10" + "node": "^16.14.0 || >=18.0.0" } }, "node_modules/npm/node_modules/npm-audit-report": { - "version": "2.1.5", + "version": "5.0.0", "dev": true, "inBundle": true, "license": "ISC", - "dependencies": { - "chalk": "^4.0.0" - }, "engines": { - "node": ">=10" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/npm/node_modules/npm-bundled": { - "version": "1.1.2", + "version": "3.0.1", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "npm-normalize-package-bin": "^1.0.1" + "npm-normalize-package-bin": "^3.0.0" + }, + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/npm/node_modules/npm-install-checks": { - "version": "4.0.0", + "version": "6.3.0", "dev": true, "inBundle": true, "license": "BSD-2-Clause", @@ -15457,162 +15580,99 @@ "semver": "^7.1.1" }, "engines": { - "node": ">=10" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/npm/node_modules/npm-normalize-package-bin": { - "version": "1.0.1", - "dev": true, - "inBundle": true, - "license": "ISC" - }, - "node_modules/npm/node_modules/npm-package-arg": { - "version": "8.1.5", - "dev": true, - "inBundle": true, - "license": "ISC", - "dependencies": { - "hosted-git-info": "^4.0.1", - "semver": "^7.3.4", - "validate-npm-package-name": "^3.0.0" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/npm/node_modules/npm-packlist": { - "version": "2.2.2", - "dev": true, - "inBundle": true, - "license": "ISC", - "dependencies": { - "glob": "^7.1.6", - "ignore-walk": "^3.0.3", - "npm-bundled": "^1.1.1", - "npm-normalize-package-bin": "^1.0.1" - }, - "bin": { - "npm-packlist": "bin/index.js" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/npm/node_modules/npm-pick-manifest": { - "version": "6.1.1", - "dev": true, - "inBundle": true, - "license": "ISC", - "dependencies": { - "npm-install-checks": "^4.0.0", - "npm-normalize-package-bin": "^1.0.1", - "npm-package-arg": "^8.1.2", - "semver": "^7.3.4" - } - }, - "node_modules/npm/node_modules/npm-profile": { - "version": "5.0.4", + "version": "3.0.1", "dev": true, "inBundle": true, "license": "ISC", - "dependencies": { - "npm-registry-fetch": "^11.0.0" - }, "engines": { - "node": ">=10" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, - "node_modules/npm/node_modules/npm-registry-fetch": { - "version": "11.0.0", + "node_modules/npm/node_modules/npm-package-arg": { + "version": "11.0.2", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "make-fetch-happen": "^9.0.1", - "minipass": "^3.1.3", - "minipass-fetch": "^1.3.0", - "minipass-json-stream": "^1.0.1", - "minizlib": "^2.0.0", - "npm-package-arg": "^8.0.0" + "hosted-git-info": "^7.0.0", + "proc-log": "^4.0.0", + "semver": "^7.3.5", + "validate-npm-package-name": "^5.0.0" }, "engines": { - "node": ">=10" - } - }, - "node_modules/npm/node_modules/npm-user-validate": { - "version": "1.0.1", - "dev": true, - "inBundle": true, - "license": "BSD-2-Clause" - }, - "node_modules/npm/node_modules/npmlog": { - "version": "5.0.1", - "dev": true, - "inBundle": true, - "license": "ISC", - "dependencies": { - "are-we-there-yet": "^2.0.0", - "console-control-strings": "^1.1.0", - "gauge": "^3.0.0", - "set-blocking": "^2.0.0" + "node": "^16.14.0 || >=18.0.0" } }, - "node_modules/npm/node_modules/npmlog/node_modules/are-we-there-yet": { - "version": "2.0.0", + "node_modules/npm/node_modules/npm-packlist": { + "version": "8.0.2", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "delegates": "^1.0.0", - "readable-stream": "^3.6.0" + "ignore-walk": "^6.0.4" }, "engines": { - "node": ">=10" - } - }, - "node_modules/npm/node_modules/number-is-nan": { - "version": "1.0.1", - "dev": true, - "inBundle": true, - "license": "MIT", - "engines": { - "node": ">=0.10.0" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, - "node_modules/npm/node_modules/oauth-sign": { - "version": "0.9.0", + "node_modules/npm/node_modules/npm-pick-manifest": { + "version": "9.0.1", "dev": true, "inBundle": true, - "license": "Apache-2.0", + "license": "ISC", + "dependencies": { + "npm-install-checks": "^6.0.0", + "npm-normalize-package-bin": "^3.0.0", + "npm-package-arg": "^11.0.0", + "semver": "^7.3.5" + }, "engines": { - "node": "*" + "node": "^16.14.0 || >=18.0.0" } }, - "node_modules/npm/node_modules/object-assign": { - "version": "4.1.1", + "node_modules/npm/node_modules/npm-profile": { + "version": "10.0.0", "dev": true, "inBundle": true, - "license": "MIT", + "license": "ISC", + "dependencies": { + "npm-registry-fetch": "^17.0.1", + "proc-log": "^4.0.0" + }, "engines": { - "node": ">=0.10.0" + "node": ">=18.0.0" } }, - "node_modules/npm/node_modules/once": { - "version": "1.4.0", + "node_modules/npm/node_modules/npm-registry-fetch": { + "version": "17.0.1", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "wrappy": "1" + "@npmcli/redact": "^2.0.0", + "make-fetch-happen": "^13.0.0", + "minipass": "^7.0.2", + "minipass-fetch": "^3.0.0", + "minipass-json-stream": "^1.0.1", + "minizlib": "^2.1.2", + "npm-package-arg": "^11.0.0", + "proc-log": "^4.0.0" + }, + "engines": { + "node": "^16.14.0 || >=18.0.0" } }, - "node_modules/npm/node_modules/opener": { - "version": "1.5.2", + "node_modules/npm/node_modules/npm-user-validate": { + "version": "2.0.1", "dev": true, "inBundle": true, - "license": "(WTFPL OR MIT)", - "bin": { - "opener": "bin/opener-bin.js" + "license": "BSD-2-Clause", + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/npm/node_modules/p-map": { @@ -15631,69 +15691,105 @@ } }, "node_modules/npm/node_modules/pacote": { - "version": "11.3.5", + "version": "18.0.6", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "@npmcli/git": "^2.1.0", - "@npmcli/installed-package-contents": "^1.0.6", - "@npmcli/promise-spawn": "^1.2.0", - "@npmcli/run-script": "^1.8.2", - "cacache": "^15.0.5", - "chownr": "^2.0.0", - "fs-minipass": "^2.1.0", - "infer-owner": "^1.0.4", - "minipass": "^3.1.3", - "mkdirp": "^1.0.3", - "npm-package-arg": "^8.0.1", - "npm-packlist": "^2.1.4", - "npm-pick-manifest": "^6.0.0", - "npm-registry-fetch": "^11.0.0", + "@npmcli/git": "^5.0.0", + "@npmcli/installed-package-contents": "^2.0.1", + "@npmcli/package-json": "^5.1.0", + "@npmcli/promise-spawn": "^7.0.0", + "@npmcli/run-script": "^8.0.0", + "cacache": "^18.0.0", + "fs-minipass": "^3.0.0", + "minipass": "^7.0.2", + "npm-package-arg": "^11.0.0", + "npm-packlist": "^8.0.0", + "npm-pick-manifest": "^9.0.0", + "npm-registry-fetch": "^17.0.0", + "proc-log": "^4.0.0", "promise-retry": "^2.0.1", - "read-package-json-fast": "^2.0.1", - "rimraf": "^3.0.2", - "ssri": "^8.0.1", - "tar": "^6.1.0" + "sigstore": "^2.2.0", + "ssri": "^10.0.0", + "tar": "^6.1.11" }, "bin": { - "pacote": "lib/bin.js" + "pacote": "bin/index.js" }, "engines": { - "node": ">=10" + "node": "^16.14.0 || >=18.0.0" } }, "node_modules/npm/node_modules/parse-conflict-json": { - "version": "1.1.1", + "version": "3.0.1", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "json-parse-even-better-errors": "^2.3.0", - "just-diff": "^3.0.1", - "just-diff-apply": "^3.0.0" + "json-parse-even-better-errors": "^3.0.0", + "just-diff": "^6.0.0", + "just-diff-apply": "^5.2.0" + }, + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, - "node_modules/npm/node_modules/path-is-absolute": { - "version": "1.0.1", + "node_modules/npm/node_modules/path-key": { + "version": "3.1.1", "dev": true, "inBundle": true, "license": "MIT", "engines": { - "node": ">=0.10.0" + "node": ">=8" } }, - "node_modules/npm/node_modules/performance-now": { - "version": "2.1.0", + "node_modules/npm/node_modules/path-scurry": { + "version": "1.11.1", "dev": true, "inBundle": true, - "license": "MIT" + "license": "BlueOak-1.0.0", + "dependencies": { + "lru-cache": "^10.2.0", + "minipass": "^5.0.0 || ^6.0.2 || ^7.0.0" + }, + "engines": { + "node": ">=16 || 14 >=14.18" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "node_modules/npm/node_modules/postcss-selector-parser": { + "version": "6.1.0", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "cssesc": "^3.0.0", + "util-deprecate": "^1.0.2" + }, + "engines": { + "node": ">=4" + } }, "node_modules/npm/node_modules/proc-log": { - "version": "1.0.0", + "version": "4.2.0", "dev": true, "inBundle": true, - "license": "ISC" + "license": "ISC", + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + } + }, + "node_modules/npm/node_modules/proggy": { + "version": "2.0.0", + "dev": true, + "inBundle": true, + "license": "ISC", + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + } }, "node_modules/npm/node_modules/promise-all-reject-late": { "version": "1.0.1", @@ -15705,7 +15801,7 @@ } }, "node_modules/npm/node_modules/promise-call-limit": { - "version": "1.0.1", + "version": "3.0.1", "dev": true, "inBundle": true, "license": "ISC", @@ -15733,27 +15829,15 @@ } }, "node_modules/npm/node_modules/promzard": { - "version": "0.3.0", + "version": "1.0.2", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "read": "1" - } - }, - "node_modules/npm/node_modules/psl": { - "version": "1.8.0", - "dev": true, - "inBundle": true, - "license": "MIT" - }, - "node_modules/npm/node_modules/punycode": { - "version": "2.1.1", - "dev": true, - "inBundle": true, - "license": "MIT", + "read": "^3.0.1" + }, "engines": { - "node": ">=6" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/npm/node_modules/qrcode-terminal": { @@ -15764,222 +15848,118 @@ "qrcode-terminal": "bin/qrcode-terminal.js" } }, - "node_modules/npm/node_modules/qs": { - "version": "6.5.2", - "dev": true, - "inBundle": true, - "license": "BSD-3-Clause", - "engines": { - "node": ">=0.6" - } - }, "node_modules/npm/node_modules/read": { - "version": "1.0.7", + "version": "3.0.1", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "mute-stream": "~0.0.4" + "mute-stream": "^1.0.0" }, "engines": { - "node": ">=0.8" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/npm/node_modules/read-cmd-shim": { - "version": "2.0.0", - "dev": true, - "inBundle": true, - "license": "ISC" - }, - "node_modules/npm/node_modules/read-package-json": { - "version": "4.1.1", + "version": "4.0.0", "dev": true, "inBundle": true, "license": "ISC", - "dependencies": { - "glob": "^7.1.1", - "json-parse-even-better-errors": "^2.3.0", - "normalize-package-data": "^3.0.0", - "npm-normalize-package-bin": "^1.0.0" - }, "engines": { - "node": ">=10" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/npm/node_modules/read-package-json-fast": { - "version": "2.0.3", + "version": "3.0.2", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "json-parse-even-better-errors": "^2.3.0", - "npm-normalize-package-bin": "^1.0.1" + "json-parse-even-better-errors": "^3.0.0", + "npm-normalize-package-bin": "^3.0.0" }, "engines": { - "node": ">=10" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, - "node_modules/npm/node_modules/readable-stream": { - "version": "3.6.0", + "node_modules/npm/node_modules/retry": { + "version": "0.12.0", "dev": true, "inBundle": true, "license": "MIT", - "dependencies": { - "inherits": "^2.0.3", - "string_decoder": "^1.1.1", - "util-deprecate": "^1.0.1" - }, "engines": { - "node": ">= 6" + "node": ">= 4" } }, - "node_modules/npm/node_modules/readdir-scoped-modules": { - "version": "1.1.0", + "node_modules/npm/node_modules/safer-buffer": { + "version": "2.1.2", "dev": true, "inBundle": true, - "license": "ISC", - "dependencies": { - "debuglog": "^1.0.1", - "dezalgo": "^1.0.0", - "graceful-fs": "^4.1.2", - "once": "^1.3.0" - } + "license": "MIT", + "optional": true }, - "node_modules/npm/node_modules/request": { - "version": "2.88.2", + "node_modules/npm/node_modules/semver": { + "version": "7.6.2", "dev": true, "inBundle": true, - "license": "Apache-2.0", - "dependencies": { - "aws-sign2": "~0.7.0", - "aws4": "^1.8.0", - "caseless": "~0.12.0", - "combined-stream": "~1.0.6", - "extend": "~3.0.2", - "forever-agent": "~0.6.1", - "form-data": "~2.3.2", - "har-validator": "~5.1.3", - "http-signature": "~1.2.0", - "is-typedarray": "~1.0.0", - "isstream": "~0.1.2", - "json-stringify-safe": "~5.0.1", - "mime-types": "~2.1.19", - "oauth-sign": "~0.9.0", - "performance-now": "^2.1.0", - "qs": "~6.5.2", - "safe-buffer": "^5.1.2", - "tough-cookie": "~2.5.0", - "tunnel-agent": "^0.6.0", - "uuid": "^3.3.2" + "license": "ISC", + "bin": { + "semver": "bin/semver.js" }, "engines": { - "node": ">= 6" + "node": ">=10" } }, - "node_modules/npm/node_modules/request/node_modules/form-data": { - "version": "2.3.3", + "node_modules/npm/node_modules/shebang-command": { + "version": "2.0.0", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "asynckit": "^0.4.0", - "combined-stream": "^1.0.6", - "mime-types": "^2.1.12" - }, - "engines": { - "node": ">= 0.12" - } - }, - "node_modules/npm/node_modules/request/node_modules/tough-cookie": { - "version": "2.5.0", - "dev": true, - "inBundle": true, - "license": "BSD-3-Clause", - "dependencies": { - "psl": "^1.1.28", - "punycode": "^2.1.1" + "shebang-regex": "^3.0.0" }, "engines": { - "node": ">=0.8" + "node": ">=8" } }, - "node_modules/npm/node_modules/retry": { - "version": "0.12.0", + "node_modules/npm/node_modules/shebang-regex": { + "version": "3.0.0", "dev": true, "inBundle": true, "license": "MIT", "engines": { - "node": ">= 4" + "node": ">=8" } }, - "node_modules/npm/node_modules/rimraf": { - "version": "3.0.2", + "node_modules/npm/node_modules/signal-exit": { + "version": "4.1.0", "dev": true, "inBundle": true, "license": "ISC", - "dependencies": { - "glob": "^7.1.3" - }, - "bin": { - "rimraf": "bin.js" + "engines": { + "node": ">=14" }, "funding": { "url": "https://github.com/sponsors/isaacs" } }, - "node_modules/npm/node_modules/safe-buffer": { - "version": "5.2.1", - "dev": true, - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ], - "inBundle": true, - "license": "MIT" - }, - "node_modules/npm/node_modules/safer-buffer": { - "version": "2.1.2", - "dev": true, - "inBundle": true, - "license": "MIT" - }, - "node_modules/npm/node_modules/semver": { - "version": "7.3.5", + "node_modules/npm/node_modules/sigstore": { + "version": "2.3.1", "dev": true, "inBundle": true, - "license": "ISC", + "license": "Apache-2.0", "dependencies": { - "lru-cache": "^6.0.0" - }, - "bin": { - "semver": "bin/semver.js" + "@sigstore/bundle": "^2.3.2", + "@sigstore/core": "^1.0.0", + "@sigstore/protobuf-specs": "^0.3.2", + "@sigstore/sign": "^2.3.2", + "@sigstore/tuf": "^2.3.4", + "@sigstore/verify": "^1.2.1" }, "engines": { - "node": ">=10" + "node": "^16.14.0 || >=18.0.0" } }, - "node_modules/npm/node_modules/set-blocking": { - "version": "2.0.0", - "dev": true, - "inBundle": true, - "license": "ISC" - }, - "node_modules/npm/node_modules/signal-exit": { - "version": "3.0.3", - "dev": true, - "inBundle": true, - "license": "ISC" - }, "node_modules/npm/node_modules/smart-buffer": { "version": "4.2.0", "dev": true, @@ -15991,35 +15971,35 @@ } }, "node_modules/npm/node_modules/socks": { - "version": "2.6.1", + "version": "2.8.3", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "ip": "^1.1.5", - "smart-buffer": "^4.1.0" + "ip-address": "^9.0.5", + "smart-buffer": "^4.2.0" }, "engines": { - "node": ">= 10.13.0", + "node": ">= 10.0.0", "npm": ">= 3.0.0" } }, "node_modules/npm/node_modules/socks-proxy-agent": { - "version": "6.1.0", + "version": "8.0.3", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "agent-base": "^6.0.2", - "debug": "^4.3.1", - "socks": "^2.6.1" + "agent-base": "^7.1.1", + "debug": "^4.3.4", + "socks": "^2.7.1" }, "engines": { - "node": ">= 10" + "node": ">= 14" } }, "node_modules/npm/node_modules/spdx-correct": { - "version": "3.1.1", + "version": "3.2.0", "dev": true, "inBundle": true, "license": "Apache-2.0", @@ -16028,14 +16008,24 @@ "spdx-license-ids": "^3.0.0" } }, + "node_modules/npm/node_modules/spdx-correct/node_modules/spdx-expression-parse": { + "version": "3.0.1", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "spdx-exceptions": "^2.1.0", + "spdx-license-ids": "^3.0.0" + } + }, "node_modules/npm/node_modules/spdx-exceptions": { - "version": "2.3.0", + "version": "2.5.0", "dev": true, "inBundle": true, "license": "CC-BY-3.0" }, "node_modules/npm/node_modules/spdx-expression-parse": { - "version": "3.0.1", + "version": "4.0.0", "dev": true, "inBundle": true, "license": "MIT", @@ -16045,136 +16035,143 @@ } }, "node_modules/npm/node_modules/spdx-license-ids": { - "version": "3.0.10", + "version": "3.0.18", "dev": true, "inBundle": true, "license": "CC0-1.0" }, - "node_modules/npm/node_modules/sshpk": { - "version": "1.16.1", + "node_modules/npm/node_modules/sprintf-js": { + "version": "1.1.3", "dev": true, "inBundle": true, - "license": "MIT", + "license": "BSD-3-Clause" + }, + "node_modules/npm/node_modules/ssri": { + "version": "10.0.6", + "dev": true, + "inBundle": true, + "license": "ISC", "dependencies": { - "asn1": "~0.2.3", - "assert-plus": "^1.0.0", - "bcrypt-pbkdf": "^1.0.0", - "dashdash": "^1.12.0", - "ecc-jsbn": "~0.1.1", - "getpass": "^0.1.1", - "jsbn": "~0.1.0", - "safer-buffer": "^2.0.2", - "tweetnacl": "~0.14.0" + "minipass": "^7.0.3" }, - "bin": { - "sshpk-conv": "bin/sshpk-conv", - "sshpk-sign": "bin/sshpk-sign", - "sshpk-verify": "bin/sshpk-verify" + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + } + }, + "node_modules/npm/node_modules/string-width": { + "version": "4.2.3", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "emoji-regex": "^8.0.0", + "is-fullwidth-code-point": "^3.0.0", + "strip-ansi": "^6.0.1" }, "engines": { - "node": ">=0.10.0" + "node": ">=8" } }, - "node_modules/npm/node_modules/ssri": { - "version": "8.0.1", + "node_modules/npm/node_modules/string-width-cjs": { + "name": "string-width", + "version": "4.2.3", "dev": true, "inBundle": true, - "license": "ISC", + "license": "MIT", "dependencies": { - "minipass": "^3.1.1" + "emoji-regex": "^8.0.0", + "is-fullwidth-code-point": "^3.0.0", + "strip-ansi": "^6.0.1" }, "engines": { - "node": ">= 8" + "node": ">=8" } }, - "node_modules/npm/node_modules/string_decoder": { - "version": "1.3.0", + "node_modules/npm/node_modules/strip-ansi": { + "version": "6.0.1", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "safe-buffer": "~5.2.0" + "ansi-regex": "^5.0.1" + }, + "engines": { + "node": ">=8" } }, - "node_modules/npm/node_modules/string-width": { - "version": "2.1.1", + "node_modules/npm/node_modules/strip-ansi-cjs": { + "name": "strip-ansi", + "version": "6.0.1", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "is-fullwidth-code-point": "^2.0.0", - "strip-ansi": "^4.0.0" + "ansi-regex": "^5.0.1" }, "engines": { - "node": ">=4" + "node": ">=8" } }, - "node_modules/npm/node_modules/string-width/node_modules/ansi-regex": { - "version": "3.0.0", + "node_modules/npm/node_modules/supports-color": { + "version": "9.4.0", "dev": true, "inBundle": true, "license": "MIT", "engines": { - "node": ">=4" + "node": ">=12" + }, + "funding": { + "url": "https://github.com/chalk/supports-color?sponsor=1" } }, - "node_modules/npm/node_modules/string-width/node_modules/strip-ansi": { - "version": "4.0.0", + "node_modules/npm/node_modules/tar": { + "version": "6.2.1", "dev": true, "inBundle": true, - "license": "MIT", + "license": "ISC", "dependencies": { - "ansi-regex": "^3.0.0" + "chownr": "^2.0.0", + "fs-minipass": "^2.0.0", + "minipass": "^5.0.0", + "minizlib": "^2.1.1", + "mkdirp": "^1.0.3", + "yallist": "^4.0.0" }, "engines": { - "node": ">=4" + "node": ">=10" } }, - "node_modules/npm/node_modules/stringify-package": { - "version": "1.0.1", - "dev": true, - "inBundle": true, - "license": "ISC" - }, - "node_modules/npm/node_modules/strip-ansi": { - "version": "3.0.1", + "node_modules/npm/node_modules/tar/node_modules/fs-minipass": { + "version": "2.1.0", "dev": true, "inBundle": true, - "license": "MIT", + "license": "ISC", "dependencies": { - "ansi-regex": "^2.0.0" + "minipass": "^3.0.0" }, "engines": { - "node": ">=0.10.0" + "node": ">= 8" } }, - "node_modules/npm/node_modules/supports-color": { - "version": "7.2.0", + "node_modules/npm/node_modules/tar/node_modules/fs-minipass/node_modules/minipass": { + "version": "3.3.6", "dev": true, "inBundle": true, - "license": "MIT", + "license": "ISC", "dependencies": { - "has-flag": "^4.0.0" + "yallist": "^4.0.0" }, "engines": { "node": ">=8" } }, - "node_modules/npm/node_modules/tar": { - "version": "6.1.11", + "node_modules/npm/node_modules/tar/node_modules/minipass": { + "version": "5.0.0", "dev": true, "inBundle": true, "license": "ISC", - "dependencies": { - "chownr": "^2.0.0", - "fs-minipass": "^2.0.0", - "minipass": "^3.0.0", - "minizlib": "^2.1.1", - "mkdirp": "^1.0.3", - "yallist": "^4.0.0" - }, "engines": { - "node": ">= 10" + "node": ">=8" } }, "node_modules/npm/node_modules/text-table": { @@ -16190,63 +16187,50 @@ "license": "MIT" }, "node_modules/npm/node_modules/treeverse": { - "version": "1.0.4", - "dev": true, - "inBundle": true, - "license": "ISC" - }, - "node_modules/npm/node_modules/tunnel-agent": { - "version": "0.6.0", + "version": "3.0.0", "dev": true, "inBundle": true, - "license": "Apache-2.0", - "dependencies": { - "safe-buffer": "^5.0.1" - }, + "license": "ISC", "engines": { - "node": "*" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, - "node_modules/npm/node_modules/tweetnacl": { - "version": "0.14.5", - "dev": true, - "inBundle": true, - "license": "Unlicense" - }, - "node_modules/npm/node_modules/typedarray-to-buffer": { - "version": "3.1.5", + "node_modules/npm/node_modules/tuf-js": { + "version": "2.2.1", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "is-typedarray": "^1.0.0" + "@tufjs/models": "2.0.1", + "debug": "^4.3.4", + "make-fetch-happen": "^13.0.1" + }, + "engines": { + "node": "^16.14.0 || >=18.0.0" } }, "node_modules/npm/node_modules/unique-filename": { - "version": "1.1.1", + "version": "3.0.0", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "unique-slug": "^2.0.0" + "unique-slug": "^4.0.0" + }, + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/npm/node_modules/unique-slug": { - "version": "2.0.2", + "version": "4.0.0", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { "imurmurhash": "^0.1.4" - } - }, - "node_modules/npm/node_modules/uri-js": { - "version": "4.4.1", - "dev": true, - "inBundle": true, - "license": "BSD-2-Clause", - "dependencies": { - "punycode": "^2.1.0" + }, + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/npm/node_modules/util-deprecate": { @@ -16255,15 +16239,6 @@ "inBundle": true, "license": "MIT" }, - "node_modules/npm/node_modules/uuid": { - "version": "3.4.0", - "dev": true, - "inBundle": true, - "license": "MIT", - "bin": { - "uuid": "bin/uuid" - } - }, "node_modules/npm/node_modules/validate-npm-package-license": { "version": "3.0.4", "dev": true, @@ -16274,84 +16249,166 @@ "spdx-expression-parse": "^3.0.0" } }, - "node_modules/npm/node_modules/validate-npm-package-name": { - "version": "3.0.0", + "node_modules/npm/node_modules/validate-npm-package-license/node_modules/spdx-expression-parse": { + "version": "3.0.1", "dev": true, "inBundle": true, - "license": "ISC", + "license": "MIT", "dependencies": { - "builtins": "^1.0.3" + "spdx-exceptions": "^2.1.0", + "spdx-license-ids": "^3.0.0" } }, - "node_modules/npm/node_modules/verror": { - "version": "1.10.0", + "node_modules/npm/node_modules/validate-npm-package-name": { + "version": "5.0.1", "dev": true, - "engines": [ - "node >=0.6.0" - ], "inBundle": true, - "license": "MIT", - "dependencies": { - "assert-plus": "^1.0.0", - "core-util-is": "1.0.2", - "extsprintf": "^1.2.0" + "license": "ISC", + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/npm/node_modules/walk-up-path": { - "version": "1.0.0", + "version": "3.0.1", "dev": true, "inBundle": true, "license": "ISC" }, - "node_modules/npm/node_modules/wcwidth": { - "version": "1.0.1", + "node_modules/npm/node_modules/which": { + "version": "4.0.0", "dev": true, "inBundle": true, - "license": "MIT", + "license": "ISC", "dependencies": { - "defaults": "^1.0.3" + "isexe": "^3.1.1" + }, + "bin": { + "node-which": "bin/which.js" + }, + "engines": { + "node": "^16.13.0 || >=18.0.0" } }, - "node_modules/npm/node_modules/which": { - "version": "2.0.2", + "node_modules/npm/node_modules/which/node_modules/isexe": { + "version": "3.1.1", "dev": true, "inBundle": true, "license": "ISC", + "engines": { + "node": ">=16" + } + }, + "node_modules/npm/node_modules/wrap-ansi": { + "version": "8.1.0", + "dev": true, + "inBundle": true, + "license": "MIT", "dependencies": { - "isexe": "^2.0.0" + "ansi-styles": "^6.1.0", + "string-width": "^5.0.1", + "strip-ansi": "^7.0.1" }, - "bin": { - "node-which": "bin/node-which" + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/chalk/wrap-ansi?sponsor=1" + } + }, + "node_modules/npm/node_modules/wrap-ansi-cjs": { + "name": "wrap-ansi", + "version": "7.0.0", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "ansi-styles": "^4.0.0", + "string-width": "^4.1.0", + "strip-ansi": "^6.0.0" }, "engines": { - "node": ">= 8" + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/wrap-ansi?sponsor=1" } }, - "node_modules/npm/node_modules/wide-align": { - "version": "1.1.3", + "node_modules/npm/node_modules/wrap-ansi-cjs/node_modules/ansi-styles": { + "version": "4.3.0", "dev": true, "inBundle": true, - "license": "ISC", + "license": "MIT", "dependencies": { - "string-width": "^1.0.2 || 2" + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, - "node_modules/npm/node_modules/wrappy": { - "version": "1.0.2", + "node_modules/npm/node_modules/wrap-ansi/node_modules/ansi-regex": { + "version": "6.0.1", "dev": true, "inBundle": true, - "license": "ISC" + "license": "MIT", + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/chalk/ansi-regex?sponsor=1" + } + }, + "node_modules/npm/node_modules/wrap-ansi/node_modules/emoji-regex": { + "version": "9.2.2", + "dev": true, + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/wrap-ansi/node_modules/string-width": { + "version": "5.1.2", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "eastasianwidth": "^0.2.0", + "emoji-regex": "^9.2.2", + "strip-ansi": "^7.0.1" + }, + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/npm/node_modules/wrap-ansi/node_modules/strip-ansi": { + "version": "7.1.0", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "ansi-regex": "^6.0.1" + }, + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/chalk/strip-ansi?sponsor=1" + } }, "node_modules/npm/node_modules/write-file-atomic": { - "version": "3.0.3", + "version": "5.0.1", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { "imurmurhash": "^0.1.4", - "is-typedarray": "^1.0.0", - "signal-exit": "^3.0.2", - "typedarray-to-buffer": "^3.1.5" + "signal-exit": "^4.0.1" + }, + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/npm/node_modules/yallist": { @@ -16377,6 +16434,15 @@ "resolved": "https://registry.npmjs.org/nwsapi/-/nwsapi-2.2.7.tgz", "integrity": "sha512-ub5E4+FBPKwAZx0UwIQOjYWGHTEq5sPqHQNRN8Z9e4A7u3Tj1weLJsL59yH9vmvqEtBHaOmT6cYQKIZOxp35FQ==" }, + "node_modules/object-assign": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", + "integrity": "sha512-rJgTQnkUnH1sFw8yT6VSU3zD3sWmu6sZhIseY8VX+GRu3P6F7Fu+JNDoXfklElbLJSnc3FUQHVe4cU5hj+BcUg==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, "node_modules/object-hash": { "version": "2.2.0", "resolved": "https://registry.npmjs.org/object-hash/-/object-hash-2.2.0.tgz", @@ -16587,36 +16653,42 @@ } }, "node_modules/p-each-series": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/p-each-series/-/p-each-series-2.2.0.tgz", - "integrity": "sha512-ycIL2+1V32th+8scbpTvyHNaHe02z0sjgh91XXjAk+ZeXoPN4Z46DVUnzdso0aX4KckKw0FNNFHdjZ2UsZvxiA==", + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/p-each-series/-/p-each-series-3.0.0.tgz", + "integrity": "sha512-lastgtAdoH9YaLyDa5i5z64q+kzOcQHsQ5SsZJD3q0VEyI8mq872S3geuNbRUQLVAE9siMfgKrpj7MloKFHruw==", "dev": true, "engines": { - "node": ">=8" + "node": ">=12" }, "funding": { "url": "https://github.com/sponsors/sindresorhus" } }, "node_modules/p-filter": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/p-filter/-/p-filter-2.1.0.tgz", - "integrity": "sha512-ZBxxZ5sL2HghephhpGAQdoskxplTwr7ICaehZwLIlfL6acuVgZPm8yBNuRAFBGEqtD/hmUeq9eqLg2ys9Xr/yw==", + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/p-filter/-/p-filter-4.1.0.tgz", + "integrity": "sha512-37/tPdZ3oJwHaS3gNJdenCDB3Tz26i9sjhnguBtvN0vYlRIiDNnvTWkuh+0hETV9rLPdJ3rlL3yVOYPIAnM8rw==", "dev": true, "dependencies": { - "p-map": "^2.0.0" + "p-map": "^7.0.1" }, "engines": { - "node": ">=8" + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, "node_modules/p-filter/node_modules/p-map": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/p-map/-/p-map-2.1.0.tgz", - "integrity": "sha512-y3b8Kpd8OAN444hxfBbFfj1FY/RjtTd8tzYwhUqNYXx0fXx2iX4maP4Qr6qhIKbQXI02wTLAda4fYUbDagTUFw==", + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/p-map/-/p-map-7.0.2.tgz", + "integrity": "sha512-z4cYYMMdKHzw4O5UkWJImbZynVIo0lSGTXc7bzB1e/rrDqkgGUNysK/o4bTr+0+xKvvLoTyGqYC4Fgljy9qe1Q==", "dev": true, "engines": { - "node": ">=6" + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, "node_modules/p-is-promise": { @@ -16671,25 +16743,15 @@ } }, "node_modules/p-reduce": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/p-reduce/-/p-reduce-2.1.0.tgz", - "integrity": "sha512-2USApvnsutq8uoxZBGbbWM0JIYLiEMJ9RlaN7fAzVNb9OZN0SHjjTTfIcb667XynS5Y1VhwDJVDa72TnPzAYWw==", + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/p-reduce/-/p-reduce-3.0.0.tgz", + "integrity": "sha512-xsrIUgI0Kn6iyDYm9StOpOeK29XM1aboGji26+QEortiFST1hGZaUQOLhtEbqHErPpGW/aSz6allwK2qcptp0Q==", "dev": true, "engines": { - "node": ">=8" - } - }, - "node_modules/p-retry": { - "version": "4.6.2", - "resolved": "https://registry.npmjs.org/p-retry/-/p-retry-4.6.2.tgz", - "integrity": "sha512-312Id396EbJdvRONlngUx0NydfrIQ5lsYu0znKVUzVvArzEIt08V1qhtyESbGVd1FGX7UKtiFp5uwKZdM8wIuQ==", - "dev": true, - "dependencies": { - "@types/retry": "0.12.0", - "retry": "^0.13.1" + "node": ">=12" }, - "engines": { - "node": ">=8" + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, "node_modules/p-try": { @@ -16764,6 +16826,18 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/parse-ms": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/parse-ms/-/parse-ms-4.0.0.tgz", + "integrity": "sha512-TXfryirbmq34y8QBwgqCVLi+8oA3oWx2eAnSn62ITyEhEYaWRlVZ2DvMM9eZbMs/RfxPu/PK/aBLyGj4IrqMHw==", + "dev": true, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/parse5": { "version": "6.0.1", "resolved": "https://registry.npmjs.org/parse5/-/parse5-6.0.1.tgz", @@ -17345,6 +17419,21 @@ "node": ">= 0.8" } }, + "node_modules/pretty-ms": { + "version": "9.0.0", + "resolved": "https://registry.npmjs.org/pretty-ms/-/pretty-ms-9.0.0.tgz", + "integrity": "sha512-E9e9HJ9R9NasGOgPaPE8VMeiPKAyWR5jcFpNnwIejslIhWqdqOrb2wShBsncMPUb+BcCd2OPYfh7p2W6oemTng==", + "dev": true, + "dependencies": { + "parse-ms": "^4.0.0" + }, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/prismjs": { "version": "1.29.0", "resolved": "https://registry.npmjs.org/prismjs/-/prismjs-1.29.0.tgz", @@ -17391,6 +17480,12 @@ "url": "https://github.com/sponsors/wooorm" } }, + "node_modules/proto-list": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/proto-list/-/proto-list-1.2.4.tgz", + "integrity": "sha512-vtK/94akxsTMhe0/cbfpR+syPuszcuwhqVjJq26CuNDgFGj682oRBXOP5MJpv2r7JtE8MsiepGIqvvOTBwn2vA==", + "dev": true + }, "node_modules/proxy-from-env": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/proxy-from-env/-/proxy-from-env-1.1.0.tgz", @@ -17636,16 +17731,6 @@ "node": ">= 12" } }, - "node_modules/q": { - "version": "1.5.1", - "resolved": "https://registry.npmjs.org/q/-/q-1.5.1.tgz", - "integrity": "sha512-kV/CThkXo6xyFEZUugw/+pIOywXcDbFYgSct5cT3gqlbkBE1SJdwy6UQoZvodiWF/ckQLZyDE/Bu1M6gVu5lVw==", - "dev": true, - "engines": { - "node": ">=0.6.0", - "teleport": ">=0.2.0" - } - }, "node_modules/qrjs": { "version": "0.2.0", "resolved": "https://registry.npmjs.org/qrjs/-/qrjs-0.2.0.tgz", @@ -17691,15 +17776,6 @@ } ] }, - "node_modules/quick-lru": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/quick-lru/-/quick-lru-4.0.1.tgz", - "integrity": "sha512-ARhCpm70fzdcvNQfPoy49IaanKkTlRWF2JMzqhcJbhSFRZv7nPTvZJdcY7301IPmvW+/p0RgIWnQDLJxifsQ7g==", - "dev": true, - "engines": { - "node": ">=8" - } - }, "node_modules/randombytes": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/randombytes/-/randombytes-2.1.0.tgz", @@ -17773,127 +17849,81 @@ "node": ">=0.10.0" } }, - "node_modules/read-pkg": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/read-pkg/-/read-pkg-5.2.0.tgz", - "integrity": "sha512-Ug69mNOpfvKDAc2Q8DRpMjjzdtrnv9HcSMX+4VsZxD1aZ6ZzrIE7rlzXBtWTyhULSMKg076AW6WR5iZpD0JiOg==", + "node_modules/read-package-up": { + "version": "11.0.0", + "resolved": "https://registry.npmjs.org/read-package-up/-/read-package-up-11.0.0.tgz", + "integrity": "sha512-MbgfoNPANMdb4oRBNg5eqLbB2t2r+o5Ua1pNt8BqGp4I0FJZhuVSOj3PaBPni4azWuSzEdNn2evevzVmEk1ohQ==", "dev": true, "dependencies": { - "@types/normalize-package-data": "^2.4.0", - "normalize-package-data": "^2.5.0", - "parse-json": "^5.0.0", - "type-fest": "^0.6.0" + "find-up-simple": "^1.0.0", + "read-pkg": "^9.0.0", + "type-fest": "^4.6.0" }, "engines": { - "node": ">=8" + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/read-pkg-up": { - "version": "7.0.1", - "resolved": "https://registry.npmjs.org/read-pkg-up/-/read-pkg-up-7.0.1.tgz", - "integrity": "sha512-zK0TB7Xd6JpCLmlLmufqykGE+/TlOePD6qKClNW7hHDKFh/J7/7gCWGR7joEQEW1bKq3a3yUZSObOoWLFQ4ohg==", + "node_modules/read-package-up/node_modules/type-fest": { + "version": "4.20.1", + "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-4.20.1.tgz", + "integrity": "sha512-R6wDsVsoS9xYOpy8vgeBlqpdOyzJ12HNfQhC/aAKWM3YoCV9TtunJzh/QpkMgeDhkoynDcw5f1y+qF9yc/HHyg==", "dev": true, - "dependencies": { - "find-up": "^4.1.0", - "read-pkg": "^5.2.0", - "type-fest": "^0.8.1" - }, "engines": { - "node": ">=8" + "node": ">=16" }, "funding": { "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/read-pkg-up/node_modules/find-up": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-4.1.0.tgz", - "integrity": "sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw==", + "node_modules/read-pkg": { + "version": "9.0.1", + "resolved": "https://registry.npmjs.org/read-pkg/-/read-pkg-9.0.1.tgz", + "integrity": "sha512-9viLL4/n1BJUCT1NXVTdS1jtm80yDEgR5T4yCelII49Mbj0v1rZdKqj7zCiYdbB0CuCgdrvHcNogAKTFPBocFA==", "dev": true, "dependencies": { - "locate-path": "^5.0.0", - "path-exists": "^4.0.0" + "@types/normalize-package-data": "^2.4.3", + "normalize-package-data": "^6.0.0", + "parse-json": "^8.0.0", + "type-fest": "^4.6.0", + "unicorn-magic": "^0.1.0" }, "engines": { - "node": ">=8" - } - }, - "node_modules/read-pkg-up/node_modules/locate-path": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-5.0.0.tgz", - "integrity": "sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g==", - "dev": true, - "dependencies": { - "p-locate": "^4.1.0" + "node": ">=18" }, - "engines": { - "node": ">=8" + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/read-pkg-up/node_modules/p-locate": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-4.1.0.tgz", - "integrity": "sha512-R79ZZ/0wAxKGu3oYMlz8jy/kbhsNrS7SKZ7PxEHBgJ5+F2mtFW2fK2cOtBh1cHYkQsbzFV7I+EoRKe6Yt0oK7A==", + "node_modules/read-pkg/node_modules/parse-json": { + "version": "8.1.0", + "resolved": "https://registry.npmjs.org/parse-json/-/parse-json-8.1.0.tgz", + "integrity": "sha512-rum1bPifK5SSar35Z6EKZuYPJx85pkNaFrxBK3mwdfSJ1/WKbYrjoW/zTPSjRRamfmVX1ACBIdFAO0VRErW/EA==", "dev": true, "dependencies": { - "p-limit": "^2.2.0" + "@babel/code-frame": "^7.22.13", + "index-to-position": "^0.1.2", + "type-fest": "^4.7.1" }, "engines": { - "node": ">=8" - } - }, - "node_modules/read-pkg-up/node_modules/path-exists": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", - "integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/read-pkg-up/node_modules/type-fest": { - "version": "0.8.1", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.8.1.tgz", - "integrity": "sha512-4dbzIzqvjtgiM5rw1k5rEHtBANKmdudhGyBEajN01fEyhaAIhsoKNy6y7+IN93IfpFtwY9iqi7kD+xwKhQsNJA==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/read-pkg/node_modules/hosted-git-info": { - "version": "2.8.9", - "resolved": "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-2.8.9.tgz", - "integrity": "sha512-mxIDAb9Lsm6DoOJ7xH+5+X4y1LU/4Hi50L9C5sIswK3JzULS4bwk1FvjdBgvYR4bzT4tuUQiC15FE2f5HbLvYw==", - "dev": true - }, - "node_modules/read-pkg/node_modules/normalize-package-data": { - "version": "2.5.0", - "resolved": "https://registry.npmjs.org/normalize-package-data/-/normalize-package-data-2.5.0.tgz", - "integrity": "sha512-/5CMN3T0R4XTj4DcGaexo+roZSdSFW/0AOOTROrjxzCG1wrWXEsGbRKevjlIL+ZDE4sZlJr5ED4YW0yqmkK+eA==", - "dev": true, - "dependencies": { - "hosted-git-info": "^2.1.4", - "resolve": "^1.10.0", - "semver": "2 || 3 || 4 || 5", - "validate-npm-package-license": "^3.0.1" - } - }, - "node_modules/read-pkg/node_modules/semver": { - "version": "5.7.2", - "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.2.tgz", - "integrity": "sha512-cBznnQ9KjJqU67B52RMC65CMarK2600WFnbkcaiwWq3xy/5haFJlshgnpjovMVJ+Hff49d8GEn0b87C5pDQ10g==", - "dev": true, - "bin": { - "semver": "bin/semver" + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, "node_modules/read-pkg/node_modules/type-fest": { - "version": "0.6.0", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.6.0.tgz", - "integrity": "sha512-q+MB8nYR1KDLrgr4G5yemftpMC7/QLqVndBmEEdqzmNj5dcFOO4Oo8qlwZE3ULT3+Zim1F8Kq4cBnikNhlCMlg==", + "version": "4.20.1", + "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-4.20.1.tgz", + "integrity": "sha512-R6wDsVsoS9xYOpy8vgeBlqpdOyzJ12HNfQhC/aAKWM3YoCV9TtunJzh/QpkMgeDhkoynDcw5f1y+qF9yc/HHyg==", "dev": true, "engines": { - "node": ">=8" + "node": ">=16" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, "node_modules/readable-stream": { @@ -17935,28 +17965,6 @@ "node": ">=8.10.0" } }, - "node_modules/redent": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/redent/-/redent-3.0.0.tgz", - "integrity": "sha512-6tDA8g98We0zd0GvVeMT9arEOnTw9qM03L9cJXaCjrip1OO764RDBLBfrB4cwzNGDj5OA5ioymC9GkizgWJDUg==", - "dev": true, - "dependencies": { - "indent-string": "^4.0.0", - "strip-indent": "^3.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/redeyed": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/redeyed/-/redeyed-2.1.1.tgz", - "integrity": "sha512-FNpGGo1DycYAdnrKFxCMmKYgo/mILAqtRYbkdQD8Ep/Hk2PQ5+aEAEx+IU713RTDmuBaH0c8P5ZozurNu5ObRQ==", - "dev": true, - "dependencies": { - "esprima": "~4.0.0" - } - }, "node_modules/reduce-css-calc": { "version": "2.1.8", "resolved": "https://registry.npmjs.org/reduce-css-calc/-/reduce-css-calc-2.1.8.tgz", @@ -18062,15 +18070,15 @@ } }, "node_modules/registry-auth-token": { - "version": "4.2.2", - "resolved": "https://registry.npmjs.org/registry-auth-token/-/registry-auth-token-4.2.2.tgz", - "integrity": "sha512-PC5ZysNb42zpFME6D/XlIgtNGdTl8bBOCw90xQLVMpzuuubJKYDWFAEuUNc+Cn8Z8724tg2SDhDRrkVEsqfDMg==", + "version": "5.0.2", + "resolved": "https://registry.npmjs.org/registry-auth-token/-/registry-auth-token-5.0.2.tgz", + "integrity": "sha512-o/3ikDxtXaA59BmZuZrJZDJv8NMDGSj+6j6XaeBmHw8eY1i1qd9+6H+LjVvQXx3HN6aRCGa1cUdJ9RaJZUugnQ==", "dev": true, "dependencies": { - "rc": "1.2.8" + "@pnpm/npm-conf": "^2.1.0" }, "engines": { - "node": ">=6.0.0" + "node": ">=14" } }, "node_modules/regjsparser": { @@ -18679,15 +18687,6 @@ "node": ">=8" } }, - "node_modules/retry": { - "version": "0.13.1", - "resolved": "https://registry.npmjs.org/retry/-/retry-0.13.1.tgz", - "integrity": "sha512-XQBQ3I8W1Cge0Seh+6gjj03LbmRFWuoszgK9ooCpwYIrhhoO80pfq4cUkU5DkknwfOfFteRwlZ56PYOGYyFWdg==", - "dev": true, - "engines": { - "node": ">= 4" - } - }, "node_modules/reusify": { "version": "1.0.4", "resolved": "https://registry.npmjs.org/reusify/-/reusify-1.0.4.tgz", @@ -18982,88 +18981,250 @@ } }, "node_modules/semantic-release": { - "version": "17.4.7", - "resolved": "https://registry.npmjs.org/semantic-release/-/semantic-release-17.4.7.tgz", - "integrity": "sha512-3Ghu8mKCJgCG3QzE5xphkYWM19lGE3XjFdOXQIKBM2PBpBvgFQ/lXv31oX0+fuN/UjNFO/dqhNs8ATLBhg6zBg==", - "dev": true, - "dependencies": { - "@semantic-release/commit-analyzer": "^8.0.0", - "@semantic-release/error": "^2.2.0", - "@semantic-release/github": "^7.0.0", - "@semantic-release/npm": "^7.0.0", - "@semantic-release/release-notes-generator": "^9.0.0", - "aggregate-error": "^3.0.0", - "cosmiconfig": "^7.0.0", + "version": "24.0.0", + "resolved": "https://registry.npmjs.org/semantic-release/-/semantic-release-24.0.0.tgz", + "integrity": "sha512-v46CRPw+9eI3ZuYGF2oAjqPqsfbnfFTwLBgQsv/lch4goD09ytwOTESMN4QIrx/wPLxUGey60/NMx+ANQtWRsA==", + "dev": true, + "dependencies": { + "@semantic-release/commit-analyzer": "^13.0.0-beta.1", + "@semantic-release/error": "^4.0.0", + "@semantic-release/github": "^10.0.0", + "@semantic-release/npm": "^12.0.0", + "@semantic-release/release-notes-generator": "^14.0.0-beta.1", + "aggregate-error": "^5.0.0", + "cosmiconfig": "^9.0.0", "debug": "^4.0.0", - "env-ci": "^5.0.0", - "execa": "^5.0.0", - "figures": "^3.0.0", - "find-versions": "^4.0.0", + "env-ci": "^11.0.0", + "execa": "^9.0.0", + "figures": "^6.0.0", + "find-versions": "^6.0.0", "get-stream": "^6.0.0", "git-log-parser": "^1.2.0", - "hook-std": "^2.0.0", - "hosted-git-info": "^4.0.0", - "lodash": "^4.17.21", - "marked": "^2.0.0", - "marked-terminal": "^4.1.1", + "hook-std": "^3.0.0", + "hosted-git-info": "^7.0.0", + "import-from-esm": "^1.3.1", + "lodash-es": "^4.17.21", + "marked": "^12.0.0", + "marked-terminal": "^7.0.0", "micromatch": "^4.0.2", - "p-each-series": "^2.1.0", - "p-reduce": "^2.0.0", - "read-pkg-up": "^7.0.0", + "p-each-series": "^3.0.0", + "p-reduce": "^3.0.0", + "read-package-up": "^11.0.0", "resolve-from": "^5.0.0", "semver": "^7.3.2", - "semver-diff": "^3.1.1", + "semver-diff": "^4.0.0", "signale": "^1.2.1", - "yargs": "^16.2.0" + "yargs": "^17.5.1" }, "bin": { "semantic-release": "bin/semantic-release.js" }, "engines": { - "node": ">=10.19" + "node": ">=20.8.1" + } + }, + "node_modules/semantic-release/node_modules/@sindresorhus/merge-streams": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/@sindresorhus/merge-streams/-/merge-streams-4.0.0.tgz", + "integrity": "sha512-tlqY9xq5ukxTUZBmoOp+m61cqwQD5pHJtFY3Mn8CA8ps6yghLH/Hw8UPdqg4OLmFW3IFlcXnQNmo/dh8HzXYIQ==", + "dev": true, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/semantic-release/node_modules/aggregate-error": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/aggregate-error/-/aggregate-error-5.0.0.tgz", + "integrity": "sha512-gOsf2YwSlleG6IjRYG2A7k0HmBMEo6qVNk9Bp/EaLgAJT5ngH6PXbqa4ItvnEwCm/velL5jAnQgsHsWnjhGmvw==", + "dev": true, + "dependencies": { + "clean-stack": "^5.2.0", + "indent-string": "^5.0.0" + }, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/semantic-release/node_modules/argparse": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz", + "integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==", + "dev": true + }, + "node_modules/semantic-release/node_modules/clean-stack": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/clean-stack/-/clean-stack-5.2.0.tgz", + "integrity": "sha512-TyUIUJgdFnCISzG5zu3291TAsE77ddchd0bepon1VVQrKLGKFED4iXFEDQ24mIPdPBbyE16PK3F8MYE1CmcBEQ==", + "dev": true, + "dependencies": { + "escape-string-regexp": "5.0.0" + }, + "engines": { + "node": ">=14.16" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, "node_modules/semantic-release/node_modules/cliui": { - "version": "7.0.4", - "resolved": "https://registry.npmjs.org/cliui/-/cliui-7.0.4.tgz", - "integrity": "sha512-OcRE68cOsVMXp1Yvonl/fzkQOyjLSu/8bhPDfQt0e0/Eb283TKP20Fs2MqoPsr9SwA595rRCA+QMzYc9nBP+JQ==", + "version": "8.0.1", + "resolved": "https://registry.npmjs.org/cliui/-/cliui-8.0.1.tgz", + "integrity": "sha512-BSeNnyus75C4//NQ9gQt1/csTXyo/8Sb+afLAkzAptFuMsod9HFokGNudZpi/oQV73hnVK+sR+5PVRMd+Dr7YQ==", "dev": true, "dependencies": { "string-width": "^4.2.0", - "strip-ansi": "^6.0.0", + "strip-ansi": "^6.0.1", "wrap-ansi": "^7.0.0" + }, + "engines": { + "node": ">=12" + } + }, + "node_modules/semantic-release/node_modules/cosmiconfig": { + "version": "9.0.0", + "resolved": "https://registry.npmjs.org/cosmiconfig/-/cosmiconfig-9.0.0.tgz", + "integrity": "sha512-itvL5h8RETACmOTFc4UfIyB2RfEHi71Ax6E/PivVxq9NseKbOWpeyHEOIbmAw1rs8Ak0VursQNww7lf7YtUwzg==", + "dev": true, + "dependencies": { + "env-paths": "^2.2.1", + "import-fresh": "^3.3.0", + "js-yaml": "^4.1.0", + "parse-json": "^5.2.0" + }, + "engines": { + "node": ">=14" + }, + "funding": { + "url": "https://github.com/sponsors/d-fischer" + }, + "peerDependencies": { + "typescript": ">=4.9.5" + }, + "peerDependenciesMeta": { + "typescript": { + "optional": true + } + } + }, + "node_modules/semantic-release/node_modules/escape-string-regexp": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-5.0.0.tgz", + "integrity": "sha512-/veY75JbMK4j1yjvuUxuVsiS/hr/4iHs9FTT6cgTexxdE0Ly/glccBAkloH/DofkjRbZU3bnoj38mOmhkZ0lHw==", + "dev": true, + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/semantic-release/node_modules/execa": { + "version": "9.3.0", + "resolved": "https://registry.npmjs.org/execa/-/execa-9.3.0.tgz", + "integrity": "sha512-l6JFbqnHEadBoVAVpN5dl2yCyfX28WoBAGaoQcNmLLSedOxTxcn2Qa83s8I/PA5i56vWru2OHOtrwF7Om2vqlg==", + "dev": true, + "dependencies": { + "@sindresorhus/merge-streams": "^4.0.0", + "cross-spawn": "^7.0.3", + "figures": "^6.1.0", + "get-stream": "^9.0.0", + "human-signals": "^7.0.0", + "is-plain-obj": "^4.1.0", + "is-stream": "^4.0.1", + "npm-run-path": "^5.2.0", + "pretty-ms": "^9.0.0", + "signal-exit": "^4.1.0", + "strip-final-newline": "^4.0.0", + "yoctocolors": "^2.0.0" + }, + "engines": { + "node": "^18.19.0 || >=20.5.0" + }, + "funding": { + "url": "https://github.com/sindresorhus/execa?sponsor=1" + } + }, + "node_modules/semantic-release/node_modules/execa/node_modules/get-stream": { + "version": "9.0.1", + "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-9.0.1.tgz", + "integrity": "sha512-kVCxPF3vQM/N0B1PmoqVUqgHP+EeVjmZSQn+1oCRPxd2P21P2F19lIgbR3HBosbB1PUhOAoctJnfEn2GbN2eZA==", + "dev": true, + "dependencies": { + "@sec-ant/readable-stream": "^0.4.1", + "is-stream": "^4.0.1" + }, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/semantic-release/node_modules/find-versions": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/find-versions/-/find-versions-6.0.0.tgz", + "integrity": "sha512-2kCCtc+JvcZ86IGAz3Z2Y0A1baIz9fL31pH/0S1IqZr9Iwnjq8izfPtrCyQKO6TLMPELLsQMre7VDqeIKCsHkA==", + "dev": true, + "dependencies": { + "semver-regex": "^4.0.5", + "super-regex": "^1.0.0" + }, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/semantic-release/node_modules/human-signals": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-7.0.0.tgz", + "integrity": "sha512-74kytxOUSvNbjrT9KisAbaTZ/eJwD/LrbM/kh5j0IhPuJzwuA19dWvniFGwBzN9rVjg+O/e+F310PjObDXS+9Q==", + "dev": true, + "engines": { + "node": ">=18.18.0" + } + }, + "node_modules/semantic-release/node_modules/indent-string": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/indent-string/-/indent-string-5.0.0.tgz", + "integrity": "sha512-m6FAo/spmsW2Ab2fU35JTYwtOKa2yAwXSwgjSv1TJzh4Mh7mC3lzAOVLBprb72XsTrgkEIsl7YrFNAiDiRhIGg==", + "dev": true, + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/semantic-release/node_modules/execa": { - "version": "5.1.1", - "resolved": "https://registry.npmjs.org/execa/-/execa-5.1.1.tgz", - "integrity": "sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg==", + "node_modules/semantic-release/node_modules/is-stream": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-4.0.1.tgz", + "integrity": "sha512-Dnz92NInDqYckGEUJv689RbRiTSEHCQ7wOVeALbkOz999YpqT46yMRIGtSNl2iCL1waAZSx40+h59NV/EwzV/A==", "dev": true, - "dependencies": { - "cross-spawn": "^7.0.3", - "get-stream": "^6.0.0", - "human-signals": "^2.1.0", - "is-stream": "^2.0.0", - "merge-stream": "^2.0.0", - "npm-run-path": "^4.0.1", - "onetime": "^5.1.2", - "signal-exit": "^3.0.3", - "strip-final-newline": "^2.0.0" - }, "engines": { - "node": ">=10" + "node": ">=18" }, "funding": { - "url": "https://github.com/sindresorhus/execa?sponsor=1" + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/semantic-release/node_modules/human-signals": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-2.1.0.tgz", - "integrity": "sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw==", + "node_modules/semantic-release/node_modules/js-yaml": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz", + "integrity": "sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==", "dev": true, - "engines": { - "node": ">=10.17.0" + "dependencies": { + "argparse": "^2.0.1" + }, + "bin": { + "js-yaml": "bin/js-yaml.js" } }, "node_modules/semantic-release/node_modules/lru-cache": { @@ -19078,6 +19239,33 @@ "node": ">=10" } }, + "node_modules/semantic-release/node_modules/npm-run-path": { + "version": "5.3.0", + "resolved": "https://registry.npmjs.org/npm-run-path/-/npm-run-path-5.3.0.tgz", + "integrity": "sha512-ppwTtiJZq0O/ai0z7yfudtBpWIoxM8yE6nHi1X47eFR2EWORqfbu6CnPlNsjeN683eT0qG6H/Pyf9fCcvjnnnQ==", + "dev": true, + "dependencies": { + "path-key": "^4.0.0" + }, + "engines": { + "node": "^12.20.0 || ^14.13.1 || >=16.0.0" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/semantic-release/node_modules/path-key": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/path-key/-/path-key-4.0.0.tgz", + "integrity": "sha512-haREypq7xkM7ErfgIyA0z+Bj4AGKlMSdlQE2jvJo6huWD1EdkKYV+G/T4nq0YEF2vgTT8kqMFKo1uHn950r4SQ==", + "dev": true, + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/semantic-release/node_modules/resolve-from": { "version": "5.0.0", "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-5.0.0.tgz", @@ -19102,6 +19290,42 @@ "node": ">=10" } }, + "node_modules/semantic-release/node_modules/semver-regex": { + "version": "4.0.5", + "resolved": "https://registry.npmjs.org/semver-regex/-/semver-regex-4.0.5.tgz", + "integrity": "sha512-hunMQrEy1T6Jr2uEVjrAIqjwWcQTgOAcIM52C8MY1EZSD3DDNft04XzvYKPqjED65bNVVko0YI38nYeEHCX3yw==", + "dev": true, + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/semantic-release/node_modules/signal-exit": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-4.1.0.tgz", + "integrity": "sha512-bzyZ1e88w9O1iNJbKnOlvYTrWPDl46O1bG0D3XInv+9tkPrxrN8jUUTiFlDkkmKWgn1M6CfIA13SuGqOa9Korw==", + "dev": true, + "engines": { + "node": ">=14" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "node_modules/semantic-release/node_modules/strip-final-newline": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/strip-final-newline/-/strip-final-newline-4.0.0.tgz", + "integrity": "sha512-aulFJcD6YK8V1G7iRB5tigAP4TsHBZZrOV8pjV++zdUwmeV8uzbY7yn6h9MswN62adStNZFuCIx4haBnRuMDaw==", + "dev": true, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/semantic-release/node_modules/y18n": { "version": "5.0.8", "resolved": "https://registry.npmjs.org/y18n/-/y18n-5.0.8.tgz", @@ -19118,30 +19342,30 @@ "dev": true }, "node_modules/semantic-release/node_modules/yargs": { - "version": "16.2.0", - "resolved": "https://registry.npmjs.org/yargs/-/yargs-16.2.0.tgz", - "integrity": "sha512-D1mvvtDG0L5ft/jGWkLpG1+m0eQxOfaBvTNELraWj22wSVUMWxZUvYgJYcKh6jGGIkJFhH4IZPQhR4TKpc8mBw==", + "version": "17.7.2", + "resolved": "https://registry.npmjs.org/yargs/-/yargs-17.7.2.tgz", + "integrity": "sha512-7dSzzRQ++CKnNI/krKnYRV7JKKPUXMEh61soaHKg9mrWEhzFWhFnxPxGl+69cD1Ou63C13NUPCnmIcrvqCuM6w==", "dev": true, "dependencies": { - "cliui": "^7.0.2", + "cliui": "^8.0.1", "escalade": "^3.1.1", "get-caller-file": "^2.0.5", "require-directory": "^2.1.1", - "string-width": "^4.2.0", + "string-width": "^4.2.3", "y18n": "^5.0.5", - "yargs-parser": "^20.2.2" + "yargs-parser": "^21.1.1" }, "engines": { - "node": ">=10" + "node": ">=12" } }, "node_modules/semantic-release/node_modules/yargs-parser": { - "version": "20.2.9", - "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-20.2.9.tgz", - "integrity": "sha512-y11nGElTIV+CT3Zv9t7VKl+Q3hTQoT9a1Qzezhhl6Rp21gJ/IVTW7Z3y9EWXhuUBC2Shnf+DX0antecpAwSP8w==", + "version": "21.1.1", + "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-21.1.1.tgz", + "integrity": "sha512-tVpsJW7DdjecAiFpbIB1e3qxIQsE6NoPc5/eTdrbbIC4h0LVsWhnoa3g+m2HclBIujHzsxZ4VJVA+GUuc2/LBw==", "dev": true, "engines": { - "node": ">=10" + "node": ">=12" } }, "node_modules/semver": { @@ -19160,15 +19384,30 @@ "dev": true }, "node_modules/semver-diff": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/semver-diff/-/semver-diff-3.1.1.tgz", - "integrity": "sha512-GX0Ix/CJcHyB8c4ykpHGIAvLyOwOobtM/8d+TQkAd81/bEjgPHrfba41Vpesr7jX/t8Uh+R3EX9eAS5be+jQYg==", + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/semver-diff/-/semver-diff-4.0.0.tgz", + "integrity": "sha512-0Ju4+6A8iOnpL/Thra7dZsSlOHYAHIeMxfhWQRI1/VLcT3WDBZKKtQt/QkBOsiIN9ZpuvHE6cGZ0x4glCMmfiA==", "dev": true, "dependencies": { - "semver": "^6.3.0" + "semver": "^7.3.5" }, "engines": { - "node": ">=8" + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/semver-diff/node_modules/semver": { + "version": "7.6.2", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.6.2.tgz", + "integrity": "sha512-FNAIBWCx9qcRhoHcgcJ0gvU7SN1lYU2ZXuSfl04bSC5OpvDHFyJCjdNHomPXxjQlCBU67YW64PzY7/VIEH7F2w==", + "dev": true, + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" } }, "node_modules/semver-regex": { @@ -19383,6 +19622,18 @@ "node": ">=8" } }, + "node_modules/skin-tone": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/skin-tone/-/skin-tone-2.0.0.tgz", + "integrity": "sha512-kUMbT1oBJCpgrnKoSr0o6wPtvRWT9W9UKvGLwfJYO2WuahZRHOpEyL1ckyMGgMWh0UdpmaoFqKKD29WTomNEGA==", + "dev": true, + "dependencies": { + "unicode-emoji-modifier-base": "^1.0.0" + }, + "engines": { + "node": ">=8" + } + }, "node_modules/slash": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/slash/-/slash-3.0.0.tgz", @@ -19520,9 +19771,9 @@ } }, "node_modules/spdx-exceptions": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/spdx-exceptions/-/spdx-exceptions-2.3.0.tgz", - "integrity": "sha512-/tTrYOC7PPI1nUAgx34hUpqXuyJG+DTHJTnIULG4rDygi4xu/tfgmq1e1cIRwRzwZgo4NLySi+ricLkZkw4i5A==", + "version": "2.5.0", + "resolved": "https://registry.npmjs.org/spdx-exceptions/-/spdx-exceptions-2.5.0.tgz", + "integrity": "sha512-PiU42r+xO4UbUS1buo3LPJkjlO7430Xn5SVAhdpzzsPHsjbYVflnnFdATgabnLude+Cqu25p6N+g2lw/PFsa4w==", "dev": true }, "node_modules/spdx-expression-parse": { @@ -19536,46 +19787,11 @@ } }, "node_modules/spdx-license-ids": { - "version": "3.0.16", - "resolved": "https://registry.npmjs.org/spdx-license-ids/-/spdx-license-ids-3.0.16.tgz", - "integrity": "sha512-eWN+LnM3GR6gPu35WxNgbGl8rmY1AEmoMDvL/QD6zYmPWgywxWqJWNdLGT+ke8dKNWrcYgYjPpG5gbTfghP8rw==", + "version": "3.0.18", + "resolved": "https://registry.npmjs.org/spdx-license-ids/-/spdx-license-ids-3.0.18.tgz", + "integrity": "sha512-xxRs31BqRYHwiMzudOrpSiHtZ8i/GeionCBDSilhYRj+9gIcI8wCZTlXZKu9vZIVqViP3dcp9qE5G6AlIaD+TQ==", "dev": true }, - "node_modules/split": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/split/-/split-1.0.1.tgz", - "integrity": "sha512-mTyOoPbrivtXnwnIxZRFYRrPNtEFKlpB2fvjSnCQUiAA6qAZzqwna5envK4uk6OIeP17CsdF3rSBGYVBsU0Tkg==", - "dev": true, - "dependencies": { - "through": "2" - }, - "engines": { - "node": "*" - } - }, - "node_modules/split2": { - "version": "3.2.2", - "resolved": "https://registry.npmjs.org/split2/-/split2-3.2.2.tgz", - "integrity": "sha512-9NThjpgZnifTkJpzTZ7Eue85S49QwpNhZTq6GRJwObb6jnLFNGB7Qm73V5HewTROPyxD0C29xqmaI68bQtV+hg==", - "dev": true, - "dependencies": { - "readable-stream": "^3.0.0" - } - }, - "node_modules/split2/node_modules/readable-stream": { - "version": "3.6.2", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", - "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", - "dev": true, - "dependencies": { - "inherits": "^2.0.3", - "string_decoder": "^1.1.1", - "util-deprecate": "^1.0.1" - }, - "engines": { - "node": ">= 6" - } - }, "node_modules/sprintf-js": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", @@ -19835,18 +20051,6 @@ "node": ">=6" } }, - "node_modules/strip-indent": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/strip-indent/-/strip-indent-3.0.0.tgz", - "integrity": "sha512-laJTa3Jb+VQpaC6DseHhF7dXVqHTfJPCRDaEbid/drOhgitgYku/letMUqOXFoWV0zIIUbjpdH2t+tYj4bQMRQ==", - "dev": true, - "dependencies": { - "min-indent": "^1.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/strip-json-comments": { "version": "3.1.1", "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.1.1.tgz", @@ -19868,6 +20072,22 @@ "inline-style-parser": "0.1.1" } }, + "node_modules/super-regex": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/super-regex/-/super-regex-1.0.0.tgz", + "integrity": "sha512-CY8u7DtbvucKuquCmOFEKhr9Besln7n9uN8eFbwcoGYWXOMW07u2o8njWaiXt11ylS3qoGF55pILjRmPlbodyg==", + "dev": true, + "dependencies": { + "function-timeout": "^1.0.1", + "time-span": "^5.1.0" + }, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/supports-color": { "version": "5.5.0", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", @@ -19881,16 +20101,16 @@ } }, "node_modules/supports-hyperlinks": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/supports-hyperlinks/-/supports-hyperlinks-2.3.0.tgz", - "integrity": "sha512-RpsAZlpWcDwOPQA22aCH4J0t7L8JmAvsCxfOSEwm7cQs3LshN36QaTkwd70DnBOXDWGssw2eUoc8CaRWT0XunA==", + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/supports-hyperlinks/-/supports-hyperlinks-3.0.0.tgz", + "integrity": "sha512-QBDPHyPQDRTy9ku4URNGY5Lah8PAaXs6tAAwp55sL5WCsSW7GIfdf6W5ixfziW+t7wh3GVvHyHHyQ1ESsoRvaA==", "dev": true, "dependencies": { "has-flag": "^4.0.0", "supports-color": "^7.0.0" }, "engines": { - "node": ">=8" + "node": ">=14.18" } }, "node_modules/supports-hyperlinks/node_modules/has-flag": { @@ -20266,40 +20486,51 @@ } }, "node_modules/temp-dir": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/temp-dir/-/temp-dir-2.0.0.tgz", - "integrity": "sha512-aoBAniQmmwtcKp/7BzsH8Cxzv8OL736p7v1ihGb5e9DJ9kTwGWHrQrVB5+lfVDzfGrdRzXch+ig7LHaY1JTOrg==", + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/temp-dir/-/temp-dir-3.0.0.tgz", + "integrity": "sha512-nHc6S/bwIilKHNRgK/3jlhDoIHcp45YgyiwcAk46Tr0LfEqGBVpmiAyuiuxeVE44m3mXnEeVhaipLOEWmH+Njw==", "dev": true, "engines": { - "node": ">=8" + "node": ">=14.16" } }, "node_modules/tempy": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/tempy/-/tempy-1.0.1.tgz", - "integrity": "sha512-biM9brNqxSc04Ee71hzFbryD11nX7VPhQQY32AdDmjFvodsRFz/3ufeoTZ6uYkRFfGo188tENcASNs3vTdsM0w==", + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/tempy/-/tempy-3.1.0.tgz", + "integrity": "sha512-7jDLIdD2Zp0bDe5r3D2qtkd1QOCacylBuL7oa4udvN6v2pqr4+LcCr67C8DR1zkpaZ8XosF5m1yQSabKAW6f2g==", "dev": true, "dependencies": { - "del": "^6.0.0", - "is-stream": "^2.0.0", - "temp-dir": "^2.0.0", - "type-fest": "^0.16.0", - "unique-string": "^2.0.0" + "is-stream": "^3.0.0", + "temp-dir": "^3.0.0", + "type-fest": "^2.12.2", + "unique-string": "^3.0.0" }, "engines": { - "node": ">=10" + "node": ">=14.16" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/tempy/node_modules/is-stream": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-3.0.0.tgz", + "integrity": "sha512-LnQR4bZ9IADDRSkvpqMGvt/tEJWclzklNgSw48V5EAaAeDd6qGvN8ei6k5p0tvxSR171VmGyHuTiAOfxAbr8kA==", + "dev": true, + "engines": { + "node": "^12.20.0 || ^14.13.1 || >=16.0.0" }, "funding": { "url": "https://github.com/sponsors/sindresorhus" } }, "node_modules/tempy/node_modules/type-fest": { - "version": "0.16.0", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.16.0.tgz", - "integrity": "sha512-eaBzG6MxNzEn9kiwvtre90cXaNLkmadMWa1zQMs3XORCXNbsH/OewwbxC5ia9dCxIxnTAsSxXJaa/p5y8DlvJg==", + "version": "2.19.0", + "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-2.19.0.tgz", + "integrity": "sha512-RAH822pAdBgcNMAfWnCBU3CFZcfZ/i1eZjwFU/dsLKumyuuP3niueg2UAukXYF0E2AAoc82ZSSf9J0WQBinzHA==", "dev": true, "engines": { - "node": ">=10" + "node": ">=12.20" }, "funding": { "url": "https://github.com/sponsors/sindresorhus" @@ -20341,48 +20572,52 @@ "integrity": "sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==", "dev": true }, - "node_modules/text-extensions": { - "version": "1.9.0", - "resolved": "https://registry.npmjs.org/text-extensions/-/text-extensions-1.9.0.tgz", - "integrity": "sha512-wiBrwC1EhBelW12Zy26JeOUkQ5mRu+5o8rpsJk5+2t+Y5vE7e842qtZDQ2g1NpX/29HdyFeJ4nSIhI47ENSxlQ==", - "dev": true, - "engines": { - "node": ">=0.10" - } - }, "node_modules/text-table": { "version": "0.2.0", "resolved": "https://registry.npmjs.org/text-table/-/text-table-0.2.0.tgz", "integrity": "sha512-N+8UisAXDGk8PFXP4HAzVR9nbfmVJ3zYLAWiTIoqC5v5isinhr+r5uaO8+7r3BMfuNIufIsA7RdpVgacC2cSpw==", "dev": true }, + "node_modules/thenify": { + "version": "3.3.1", + "resolved": "https://registry.npmjs.org/thenify/-/thenify-3.3.1.tgz", + "integrity": "sha512-RVZSIV5IG10Hk3enotrhvz0T9em6cyHBLkH/YAZuKqd8hRkKhSfCGIcP2KUY0EPxndzANBmNllzWPwak+bheSw==", + "dev": true, + "dependencies": { + "any-promise": "^1.0.0" + } + }, + "node_modules/thenify-all": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/thenify-all/-/thenify-all-1.6.0.tgz", + "integrity": "sha512-RNxQH/qI8/t3thXJDwcstUO4zeqo64+Uy/+sNVRBx4Xn2OX+OZ9oP+iJnNFqplFra2ZUVeKCSa2oVWi3T4uVmA==", + "dev": true, + "dependencies": { + "thenify": ">= 3.1.0 < 4" + }, + "engines": { + "node": ">=0.8" + } + }, "node_modules/through": { "version": "2.3.8", "resolved": "https://registry.npmjs.org/through/-/through-2.3.8.tgz", "integrity": "sha512-w89qg7PI8wAdvX60bMDP+bFoD5Dvhm9oLheFp5O4a2QF0cSBGsBX4qZmadPMvVqlLJBBci+WqGGOAPvcDeNSVg==", "dev": true }, - "node_modules/through2": { - "version": "4.0.2", - "resolved": "https://registry.npmjs.org/through2/-/through2-4.0.2.tgz", - "integrity": "sha512-iOqSav00cVxEEICeD7TjLB1sueEL+81Wpzp2bY17uZjZN0pWZPuo4suZ/61VujxmqSGFfgOcNuTZ85QJwNZQpw==", - "dev": true, - "dependencies": { - "readable-stream": "3" - } - }, - "node_modules/through2/node_modules/readable-stream": { - "version": "3.6.2", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", - "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", + "node_modules/time-span": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/time-span/-/time-span-5.1.0.tgz", + "integrity": "sha512-75voc/9G4rDIJleOo4jPvN4/YC4GRZrY8yy1uU4lwrB3XEQbWve8zXoO5No4eFrGcTAMYyoY67p8jRQdtA1HbA==", "dev": true, "dependencies": { - "inherits": "^2.0.3", - "string_decoder": "^1.1.1", - "util-deprecate": "^1.0.1" + "convert-hrtime": "^5.0.0" }, "engines": { - "node": ">= 6" + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, "node_modules/tmp": { @@ -20476,15 +20711,6 @@ "deprecated": "Use String.prototype.trim() instead", "dev": true }, - "node_modules/trim-newlines": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/trim-newlines/-/trim-newlines-3.0.1.tgz", - "integrity": "sha512-c1PTsA3tYrIsLGkJkzHF+w9F2EyxfXGo4UyJc4pFL++FMjnq0HJS69T3M7d//gKrFKwy429bouPescbjecU+Zw==", - "dev": true, - "engines": { - "node": ">=8" - } - }, "node_modules/trim-trailing-lines": { "version": "1.1.4", "resolved": "https://registry.npmjs.org/trim-trailing-lines/-/trim-trailing-lines-1.1.4.tgz", @@ -20759,9 +20985,9 @@ "integrity": "sha512-0xUC7BSZEE2JgBdEJdteGqfwndlUUFoCE6dAp8lEAd+1KHFPOmC+VJ6z/50OFoWHBL5ePRw4NZjen1RlQ62dKQ==" }, "node_modules/uglify-js": { - "version": "3.17.4", - "resolved": "https://registry.npmjs.org/uglify-js/-/uglify-js-3.17.4.tgz", - "integrity": "sha512-T9q82TJI9e/C1TAxYvfb16xO120tMVFZrGA3f9/P4424DNu6ypK103y0GPFVa17yotwSyZW5iYXgjYHkGrJW/g==", + "version": "3.18.0", + "resolved": "https://registry.npmjs.org/uglify-js/-/uglify-js-3.18.0.tgz", + "integrity": "sha512-SyVVbcNBCk0dzr9XL/R/ySrmYf0s372K6/hFklzgcp2lBFyXtw4I7BOdDjlLhE1aVqaI/SHWXWmYdlZxuyF38A==", "dev": true, "optional": true, "bin": { @@ -20819,6 +21045,15 @@ "node": ">=4" } }, + "node_modules/unicode-emoji-modifier-base": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/unicode-emoji-modifier-base/-/unicode-emoji-modifier-base-1.0.0.tgz", + "integrity": "sha512-yLSH4py7oFH3oG/9K+XWrz1pSi3dfUrWEnInbxMfArOfc1+33BlGPQtLsOYwvdMy11AwUBetYuaRxSPqgkq+8g==", + "dev": true, + "engines": { + "node": ">=4" + } + }, "node_modules/unicode-match-property-ecmascript": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/unicode-match-property-ecmascript/-/unicode-match-property-ecmascript-2.0.0.tgz", @@ -20850,6 +21085,18 @@ "node": ">=4" } }, + "node_modules/unicorn-magic": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/unicorn-magic/-/unicorn-magic-0.1.0.tgz", + "integrity": "sha512-lRfVq8fE8gz6QMBuDM6a+LO3IAzTi05H6gCVaUpir2E1Rwpo4ZUog45KpNXKC/Mn3Yb9UDuHumeFTo9iV/D9FQ==", + "dev": true, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/unified": { "version": "9.2.0", "resolved": "https://registry.npmjs.org/unified/-/unified-9.2.0.tgz", @@ -20878,15 +21125,18 @@ } }, "node_modules/unique-string": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/unique-string/-/unique-string-2.0.0.tgz", - "integrity": "sha512-uNaeirEPvpZWSgzwsPGtU2zVSTrn/8L5q/IexZmH0eH6SA73CmAA5U4GwORTxQAZs95TAXLNqeLoPPNO5gZfWg==", + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/unique-string/-/unique-string-3.0.0.tgz", + "integrity": "sha512-VGXBUVwxKMBUznyffQweQABPRRW1vHZAbadFZud4pLFAqRGvv/96vafgjWFqzourzr8YonlQiPgH0YCJfawoGQ==", "dev": true, "dependencies": { - "crypto-random-string": "^2.0.0" + "crypto-random-string": "^4.0.0" }, "engines": { - "node": ">=8" + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, "node_modules/unist-builder": { @@ -21024,9 +21274,9 @@ } }, "node_modules/universal-user-agent": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/universal-user-agent/-/universal-user-agent-6.0.0.tgz", - "integrity": "sha512-isyNax3wXoKaulPDZWHQqbmIx1k2tb9fb3GGDBRxCscfYV2Ch7WxPArBsFEG8s/safwXTT7H4QGhaIkTp9447w==", + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/universal-user-agent/-/universal-user-agent-7.0.2.tgz", + "integrity": "sha512-0JCqzSKnStlRRQfCdowvqy3cy0Dvtlb8xecj/H8JFZuCze4rwjPZQOgvFvn0Ws/usCHQFGpyr+pB9adaGwXn4Q==", "dev": true }, "node_modules/universalify": { @@ -21105,10 +21355,13 @@ } }, "node_modules/url-join": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/url-join/-/url-join-4.0.1.tgz", - "integrity": "sha512-jk1+QP6ZJqyOiuEI9AEWQfju/nB2Pw466kbA0LEZljHwKeMgd9WrAEgEGxjPDD2+TNbbb37rTyhEfrCXfuKXnA==", - "dev": true + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/url-join/-/url-join-5.0.0.tgz", + "integrity": "sha512-n2huDr9h9yzd6exQVnH/jU5mr+Pfx08LRXXZhkLLetAMESRj+anQsTAh940iMrIetKAmry9coFuZQ2jY8/p3WA==", + "dev": true, + "engines": { + "node": "^12.20.0 || ^14.13.1 || >=16.0.0" + } }, "node_modules/url-parse": { "version": "1.5.10", @@ -21890,6 +22143,18 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/yoctocolors": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/yoctocolors/-/yoctocolors-2.0.2.tgz", + "integrity": "sha512-Ct97huExsu7cWeEjmrXlofevF8CvzUglJ4iGUet5B8xn1oumtAZBpHU4GzYuoE6PVqcZ5hghtBrSlhwHuR1Jmw==", + "dev": true, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/zwitch": { "version": "1.0.5", "resolved": "https://registry.npmjs.org/zwitch/-/zwitch-1.0.5.tgz", diff --git a/package.json b/package.json index 470774016..5a6badf29 100644 --- a/package.json +++ b/package.json @@ -13,7 +13,6 @@ "types": "dist/index.d.ts", "scripts": { "wca": "wca analyze \"src/elements/public/*/index.ts\" --outFile custom-elements.json --format json", - "generate-schemas": "node \"./.scripts/generate-schemas.js\" && prettier \"./src/static/schemas/*.json\" \"./.vscode/settings.json\" --write", "generate-groups": "node \"./.scripts/generate-groups.js\" && prettier \"./web-test-runner.groups.js\" --write", "storybook": "wds --watch", "storybook:build": "NODE_OPTIONS=--openssl-legacy-provider build-storybook", @@ -106,7 +105,7 @@ "rollup-plugin-copy": "^3.4.0", "rollup-plugin-multi-input": "^1.1.1", "rollup-plugin-terser": "^7.0.1", - "semantic-release": "^17.2.2", + "semantic-release": "^24.0.0", "sinon": "^9.0.2", "tailwindcss": "^2.0.4", "tslib": "2.1.0", @@ -148,4 +147,4 @@ "publishConfig": { "access": "public" } -} +} \ No newline at end of file diff --git a/src/elements/internal/InternalAsyncResourceLinkListControl/InternalAsyncResourceLinkListControl.ts b/src/elements/internal/InternalAsyncResourceLinkListControl/InternalAsyncResourceLinkListControl.ts index 135cc8646..8db3c4321 100644 --- a/src/elements/internal/InternalAsyncResourceLinkListControl/InternalAsyncResourceLinkListControl.ts +++ b/src/elements/internal/InternalAsyncResourceLinkListControl/InternalAsyncResourceLinkListControl.ts @@ -84,7 +84,7 @@ export class InternalAsyncResourceLinkListControl extends InternalEditableContro
${content}
`; - if (ctx.href.startsWith('foxy://')) return wrap(render(ctx)); + if (!ctx.href || ctx.href.startsWith('foxy://')) return wrap(render(ctx)); let linkHref: string | undefined; const id = getResourceId(ctx.data?._links.self.href ?? ''); diff --git a/src/elements/internal/InternalCreateControl/InternalCreateControl.ts b/src/elements/internal/InternalCreateControl/InternalCreateControl.ts deleted file mode 100644 index be610ba2c..000000000 --- a/src/elements/internal/InternalCreateControl/InternalCreateControl.ts +++ /dev/null @@ -1,64 +0,0 @@ -import type { TemplateResult, PropertyDeclarations } from 'lit-element'; - -import { InternalControl } from '../InternalControl/InternalControl'; -import { html } from 'lit-element'; - -/** - * Internal control displaying a "Create" button that triggers Nucleon form - * submission on click. The button is disabled if the form is invalid. - * - * @since 1.17.0 - * @element foxy-internal-create-control - */ -export class InternalCreateControl extends InternalControl { - static get properties(): PropertyDeclarations { - return { - ...super.properties, - theme: { type: String }, - }; - } - - /** Same as the "theme" attribute of the `vaadin-button` element. */ - theme = 'primary success'; - - renderControl(): TemplateResult { - return html` - this.nucleon?.submit()} - > - - - `; - } - - private get __isCleanTemplateInvalid() { - return !!this.nucleon?.in({ idle: { template: { clean: 'invalid' } } }); - } - - private get __isDirtyTemplateInvalid() { - return !!this.nucleon?.in({ idle: { template: { dirty: 'invalid' } } }); - } - - private get __isCleanSnapshotInvalid() { - return !!this.nucleon?.in({ idle: { snapshot: { clean: 'invalid' } } }); - } - - private get __isDirtySnapshotInvalid() { - return !!this.nucleon?.in({ idle: { snapshot: { dirty: 'invalid' } } }); - } - - private get __isTemplateInvalid() { - return this.__isCleanTemplateInvalid || this.__isDirtyTemplateInvalid; - } - - private get __isSnapshotInvalid() { - return this.__isCleanSnapshotInvalid || this.__isDirtySnapshotInvalid; - } - - private get __isInvalid() { - return this.__isSnapshotInvalid || this.__isTemplateInvalid; - } -} diff --git a/src/elements/internal/InternalCreateControl/index.ts b/src/elements/internal/InternalCreateControl/index.ts deleted file mode 100644 index 53d0f3737..000000000 --- a/src/elements/internal/InternalCreateControl/index.ts +++ /dev/null @@ -1,10 +0,0 @@ -import '@vaadin/vaadin-button'; - -import '../../public/I18n/index'; -import '../InternalControl/index'; - -import { InternalCreateControl } from './InternalCreateControl'; - -customElements.define('foxy-internal-create-control', InternalCreateControl); - -export { InternalCreateControl }; diff --git a/src/elements/internal/InternalForm/InternalForm.test.ts b/src/elements/internal/InternalForm/InternalForm.test.ts index a2c0382f1..144483070 100644 --- a/src/elements/internal/InternalForm/InternalForm.test.ts +++ b/src/elements/internal/InternalForm/InternalForm.test.ts @@ -15,8 +15,12 @@ describe('InternalForm', () => { expect(customElements.get('foxy-internal-timestamps-control')).to.exist; }); - it('imports and registers foxy-internal-create-control', () => { - expect(customElements.get('foxy-internal-create-control')).to.exist; + it('imports and registers foxy-internal-submit-control', () => { + expect(customElements.get('foxy-internal-submit-control')).to.exist; + }); + + it('imports and registers foxy-internal-undo-control', () => { + expect(customElements.get('foxy-internal-undo-control')).to.exist; }); it('imports and registers foxy-internal-delete-control', () => { @@ -61,35 +65,80 @@ describe('InternalForm', () => { expect(element.renderHeaderActions(data)).to.equal(null); }); - it('has a .renderHeader() method rendering an optional header', async () => { + it('renders a configurable title in the optional header', async () => { const root = document.createElement('div'); const element = await fixture>( html`` ); render(element.renderHeader(), root); + let title = root.querySelector(`foxy-i18n[infer="header"][key="${element.headerTitleKey}"]`); - expect(root.querySelector('foxy-i18n[infer="header"][key="title_new"]')).to.exist; - expect(root.querySelector('foxy-i18n[infer="header"][key="title_existing"]')).to.not.exist; - expect(root.querySelector('foxy-i18n[infer="header"][key="subtitle"]')).to.not.exist; - expect(root.querySelector('foxy-copy-to-clipboard')).to.not.exist; + expect(title).to.exist; + expect(title).to.have.deep.property('options', element.headerTitleOptions); element.data = await getTestData('./hapi/customers/0'); render(element.renderHeader(), root); - expect(root.querySelector('foxy-i18n[infer="header"][key="title_new"]')).to.not.exist; - - const title = root.querySelector('foxy-i18n[infer="header"][key="title_existing"]'); + title = root.querySelector(`foxy-i18n[infer="header"][key="${element.headerTitleKey}"]`); expect(title).to.exist; - expect(title).to.have.deep.property('options', { id: 0 }); + expect(title).to.have.deep.property('options', element.headerTitleOptions); + }); + + it('when loaded, renders a configurable subtitle in the optional header', async () => { + const root = document.createElement('div'); + const element = await fixture>( + html`` + ); - const subtitle = root.querySelector('foxy-i18n[infer="header"][key="subtitle"]'); + render(element.renderHeader(), root); + + let subtitle = root.querySelector( + `foxy-i18n[infer="header"][key="${element.headerSubtitleKey}"]` + ); + + expect(subtitle).to.not.exist; + + element.data = await getTestData('./hapi/customers/0'); + render(element.renderHeader(), root); + + subtitle = root.querySelector(`foxy-i18n[infer="header"][key="${element.headerSubtitleKey}"]`); expect(subtitle).to.exist; - expect(subtitle).to.have.deep.property('options', element.data); + expect(subtitle).to.have.deep.property('options', element.headerSubtitleOptions); + }); + + it('when loaded, renders a Copy ID button in the optional header', async () => { + const root = document.createElement('div'); + const element = await fixture>( + html`` + ); + + render(element.renderHeader(), root); + let copyButton = root.querySelector('foxy-copy-to-clipboard[infer="header copy-id"]'); + expect(copyButton).to.not.exist; + + element.data = await getTestData('./hapi/customers/0'); + render(element.renderHeader(), root); + copyButton = root.querySelector('foxy-copy-to-clipboard[infer="header copy-id"]'); + expect(copyButton).to.exist; + expect(copyButton).to.have.attribute('text', String(element.headerCopyIdValue)); + }); + + it('when loaded, renders a Copy JSON button in the optional header', async () => { + const root = document.createElement('div'); + const element = await fixture>( + html`` + ); + + render(element.renderHeader(), root); + let copyButton = root.querySelector('foxy-copy-to-clipboard[infer="header copy-json"]'); + expect(copyButton).to.not.exist; - const copyButton = root.querySelector('foxy-copy-to-clipboard'); + element.data = await getTestData('./hapi/customers/0'); + render(element.renderHeader(), root); + copyButton = root.querySelector('foxy-copy-to-clipboard[infer="header copy-json"]'); expect(copyButton).to.exist; - expect(copyButton).to.have.property('text', '0'); + expect(copyButton).to.have.attribute('text', JSON.stringify(element.data, null, 2)); }); it('has a .renderBody() method rendering timestamps and an appropriate action control', async () => { @@ -100,15 +149,19 @@ describe('InternalForm', () => { render(element.renderBody(), root); - expect(root.querySelector('foxy-internal-create-control[infer="create"]')).to.exist; + expect(root.querySelector('foxy-internal-submit-control[infer="submit"]')).to.not.exist; + expect(root.querySelector('foxy-internal-submit-control[infer="create"]')).to.exist; expect(root.querySelector('foxy-internal-delete-control[infer="delete"]')).to.not.exist; + expect(root.querySelector('foxy-internal-undo-control[infer="undo"]')).to.not.exist; expect(root.querySelector('foxy-internal-timestamps-control[infer="timestamps"]')).to.not.exist; element.data = await getTestData('./hapi/customers/0'); render(element.renderBody(), root); - expect(root.querySelector('foxy-internal-create-control[infer="create"]')).to.not.exist; + expect(root.querySelector('foxy-internal-submit-control[infer="submit"]')).to.exist; + expect(root.querySelector('foxy-internal-submit-control[infer="create"]')).to.not.exist; expect(root.querySelector('foxy-internal-delete-control[infer="delete"]')).to.exist; + expect(root.querySelector('foxy-internal-undo-control[infer="undo"]')).to.exist; expect(root.querySelector('foxy-internal-timestamps-control[infer="timestamps"]')).to.exist; }); @@ -123,7 +176,7 @@ describe('InternalForm', () => { await element.requestUpdate(); expect(renderBodyMethod).to.have.been.called; - expect(root.querySelector('foxy-internal-create-control[infer="create"]')).to.exist; + expect(root.querySelector('foxy-internal-submit-control[infer="create"]')).to.exist; expect(root.querySelector('foxy-internal-delete-control[infer="delete"]')).to.not.exist; expect(root.querySelector('foxy-internal-timestamps-control[infer="timestamps"]')).to.not.exist; @@ -132,7 +185,7 @@ describe('InternalForm', () => { await element.requestUpdate(); expect(renderBodyMethod).to.have.been.called; - expect(root.querySelector('foxy-internal-create-control[infer="create"]')).to.not.exist; + expect(root.querySelector('foxy-internal-submit-control[infer="create"]')).to.not.exist; expect(root.querySelector('foxy-internal-delete-control[infer="delete"]')).to.exist; expect(root.querySelector('foxy-internal-timestamps-control[infer="timestamps"]')).to.exist; diff --git a/src/elements/internal/InternalForm/InternalForm.ts b/src/elements/internal/InternalForm/InternalForm.ts index 5f358972e..f9dfc6098 100644 --- a/src/elements/internal/InternalForm/InternalForm.ts +++ b/src/elements/internal/InternalForm/InternalForm.ts @@ -42,40 +42,100 @@ export class InternalForm extends Base { return null; } + /** Getter that returns a i18n key for the optional form header title. */ + get headerTitleKey(): string { + return 'title'; + } + + /** I18next options to pass to the header title translation function. */ + get headerTitleOptions(): Record { + return { + ...this.data, + context: this.data ? 'existing' : 'new', + id: this.data ? getResourceId(this.data._links.self.href) : null, + }; + } + + /** Getter that returns a i18n key for the optional form header subtitle. Note that subtitle is shown only when data is avaiable. */ + get headerSubtitleKey(): string { + return 'subtitle'; + } + + /** I18next options to pass to the header subtitle translation function. Note that subtitle is shown only when data is avaiable. */ + get headerSubtitleOptions(): Record { + return this.data ?? {}; + } + + /** ID that will be written to clipboard when Copy ID button in header is clicked. */ + get headerCopyIdValue(): string | number { + return this.data ? getResourceId(this.data._links.self.href) ?? '' : ''; + } + /** - * Renders optional form header with ID, last update timestamp and actions list (snapshot-only). - * Customize which actions are rendered with `.renderHeaderActions()` method. + * Renders optional form header. + * - Customize which actions are rendered with `.renderHeaderActions()` method. + * - Customize the header title and subtitle with `.headerTitleKey` and `.headerSubtitleKey` getters. + * - Customize the header title and subtitle options with `.headerTitleOptions` and `.headerSubtitleOptions` getters. + * - To hide the header completely, add `header` to `hidden-controls` attribute. */ renderHeader(): TemplateResult { + if (this.hiddenSelector.matches('header', true)) return html``; + const data = this.data; const actions = data ? this.renderHeaderActions(data) : null; - const id = data ? getResourceId(data._links.self.href) : ''; return html` -

- - - +
+ ${this.renderTemplateOrSlot('header:before')} +

+ + + + ${data + ? html` + ${this.hiddenSelector.matches('header:copy-id', true) + ? '' + : html` + + + `} + ${this.hiddenSelector.matches('header:copy-json', true) + ? '' + : html` + + + `} + ` + : ''} + ${data ? html` - - + + + ${actions ? html`
${actions}
` : ''} ` : ''} - - ${data - ? html` - - - ${actions ? html`
${actions}
` : ''} - ` - : ''} -

+

+ ${this.renderTemplateOrSlot('header:after')} + `; } @@ -85,12 +145,34 @@ export class InternalForm extends Base { * don't forget to add `super.renderBody()` to your template. */ renderBody(): TemplateResult { - return this.data - ? html` - - - ` - : html``; + if (this.data) { + const isSnapshotDirty = this.in({ idle: { snapshot: 'dirty' } }); + const isDeleteHidden = this.hiddenSelector.matches('delete', true); + const actionClass = classMap({ 'transition-opacity': true, 'opacity-0': !isSnapshotDirty }); + + return html` + + ${!isDeleteHidden || isSnapshotDirty + ? html` +
+ +
+ + + + +
+ ` + : ''} + `; + } else { + return html` +
+ + +
+ `; + } } /** diff --git a/src/elements/internal/InternalForm/index.ts b/src/elements/internal/InternalForm/index.ts index 01a07e22e..b76cdac03 100644 --- a/src/elements/internal/InternalForm/index.ts +++ b/src/elements/internal/InternalForm/index.ts @@ -1,8 +1,9 @@ import '@vaadin/vaadin-button'; import '../InternalTimestampsControl/index'; -import '../InternalCreateControl/index'; +import '../InternalSubmitControl/index'; import '../InternalDeleteControl/index'; +import '../InternalUndoControl/index'; import '../../public/CopyToClipboard/index'; import '../../public/Spinner/index'; diff --git a/src/elements/internal/InternalCreateControl/InternalCreateControl.test.ts b/src/elements/internal/InternalSubmitControl/InternalSubmitControl.test.ts similarity index 58% rename from src/elements/internal/InternalCreateControl/InternalCreateControl.test.ts rename to src/elements/internal/InternalSubmitControl/InternalSubmitControl.test.ts index 491e64ddb..a276b20c8 100644 --- a/src/elements/internal/InternalCreateControl/InternalCreateControl.test.ts +++ b/src/elements/internal/InternalSubmitControl/InternalSubmitControl.test.ts @@ -1,7 +1,7 @@ import { expect, fixture } from '@open-wc/testing'; import { html } from 'lit-html'; -import { InternalCreateControl as Control } from './index'; +import { InternalSubmitControl as Control } from './index'; import { InternalControl } from '../InternalControl/InternalControl'; import { NucleonElement } from '../../public/NucleonElement/index'; import { stub } from 'sinon'; @@ -12,9 +12,9 @@ class TestControl extends Control { nucleon = nucleon; } -customElements.define('test-internal-create-control', TestControl); +customElements.define('test-internal-submit-control', TestControl); -describe('InternalCreateControl', () => { +describe('InternalSubmitControl', () => { before(() => document.body.appendChild(nucleon)); beforeEach(() => nucleon.undo()); after(() => nucleon.remove()); @@ -31,13 +31,13 @@ describe('InternalCreateControl', () => { expect(customElements.get('foxy-internal-control')).to.equal(InternalControl); }); - it('imports and defines itself as foxy-internal-create-control', () => { - expect(customElements.get('foxy-internal-create-control')).to.equal(Control); + it('imports and defines itself as foxy-internal-submit-control', () => { + expect(customElements.get('foxy-internal-submit-control')).to.equal(Control); }); it('defines a reactive property for "theme" (String)', () => { expect(Control).to.have.nested.property('properties.theme.type', String); - expect(new Control()).to.have.property('theme', 'primary success'); + expect(new Control()).to.have.property('theme', 'primary'); }); it('extends InternalControl', () => { @@ -45,26 +45,26 @@ describe('InternalCreateControl', () => { }); it('renders vaadin-button element', async () => { - const layout = html``; + const layout = html``; const control = await fixture(layout); const button = control.renderRoot.querySelector('vaadin-button'); expect(button).to.not.be.null; }); - it('renders translatable label "create" within vaadin-button element', async () => { - const layout = html``; + it('renders translatable label "caption" within vaadin-button element', async () => { + const layout = html``; const control = await fixture(layout); const button = control.renderRoot.querySelector('vaadin-button'); const label = button?.querySelector('foxy-i18n'); expect(label).to.not.be.null; - expect(label).to.have.property('key', 'create'); + expect(label).to.have.property('key', 'caption'); expect(label).to.have.property('infer', ''); }); it('sets "disabled" on vaadin-button from "disabled" on itself', async () => { - const layout = html``; + const layout = html``; const control = await fixture(layout); const button = control.renderRoot.querySelector('vaadin-button')!; @@ -77,32 +77,8 @@ describe('InternalCreateControl', () => { expect(button).to.have.property('disabled', false); }); - it('sets "disabled" on vaadin-button if nucleon form is in invalid state', async () => { - const layout = html``; - const control = await fixture(layout); - const button = control.renderRoot.querySelector('vaadin-button')!; - - const stateValues = [ - JSON.stringify({ idle: { template: { clean: 'invalid' } } }), - JSON.stringify({ idle: { template: { dirty: 'invalid' } } }), - JSON.stringify({ idle: { snapshot: { clean: 'invalid' } } }), - JSON.stringify({ idle: { snapshot: { dirty: 'invalid' } } }), - ]; - - for (const expectedStateValue of stateValues) { - const inMethod = stub(control.nucleon, 'in').callsFake(stateValue => { - return JSON.stringify(stateValue) === expectedStateValue; - }); - - await control.requestUpdate(); - expect(button).to.have.property('disabled', true); - - inMethod.restore(); - } - }); - it('submits the host nucleon form on click', async () => { - const layout = html``; + const layout = html``; const control = await fixture(layout); const button = control.renderRoot.querySelector('vaadin-button')!; const submitMethod = stub(control.nucleon, 'submit'); diff --git a/src/elements/internal/InternalSubmitControl/InternalSubmitControl.ts b/src/elements/internal/InternalSubmitControl/InternalSubmitControl.ts new file mode 100644 index 000000000..bd05bb155 --- /dev/null +++ b/src/elements/internal/InternalSubmitControl/InternalSubmitControl.ts @@ -0,0 +1,35 @@ +import type { TemplateResult, PropertyDeclarations } from 'lit-element'; + +import { InternalControl } from '../InternalControl/InternalControl'; +import { html } from 'lit-element'; + +/** + * Internal control displaying a "Create" button that triggers Nucleon form + * submission on click. The button is disabled if the form is invalid. + * + * @since 1.28.0 + * @element foxy-internal-submit-control + */ +export class InternalSubmitControl extends InternalControl { + static get properties(): PropertyDeclarations { + return { + ...super.properties, + theme: { type: String }, + }; + } + + /** Same as the "theme" attribute of the `vaadin-button` element. */ + theme = 'primary'; + + renderControl(): TemplateResult { + return html` + this.nucleon?.submit()} + > + + + `; + } +} diff --git a/src/elements/internal/InternalSubmitControl/index.ts b/src/elements/internal/InternalSubmitControl/index.ts new file mode 100644 index 000000000..6956c8002 --- /dev/null +++ b/src/elements/internal/InternalSubmitControl/index.ts @@ -0,0 +1,10 @@ +import '@vaadin/vaadin-button'; + +import '../../public/I18n/index'; +import '../InternalControl/index'; + +import { InternalSubmitControl } from './InternalSubmitControl'; + +customElements.define('foxy-internal-submit-control', InternalSubmitControl); + +export { InternalSubmitControl as InternalSubmitControl }; diff --git a/src/elements/internal/InternalUndoControl/InternalUndoControl.test.ts b/src/elements/internal/InternalUndoControl/InternalUndoControl.test.ts new file mode 100644 index 000000000..957b40ca1 --- /dev/null +++ b/src/elements/internal/InternalUndoControl/InternalUndoControl.test.ts @@ -0,0 +1,91 @@ +import { expect, fixture } from '@open-wc/testing'; +import { html } from 'lit-html'; + +import { InternalUndoControl as Control } from './index'; +import { InternalControl } from '../InternalControl/InternalControl'; +import { NucleonElement } from '../../public/NucleonElement/index'; +import { stub } from 'sinon'; + +const nucleon = new NucleonElement(); + +class TestControl extends Control { + nucleon = nucleon; +} + +customElements.define('test-internal-undo-control', TestControl); + +describe('InternalUndoControl', () => { + before(() => document.body.appendChild(nucleon)); + beforeEach(() => nucleon.undo()); + after(() => nucleon.remove()); + + it('imports and defines vaadin-button', () => { + expect(customElements.get('vaadin-button')).to.not.be.undefined; + }); + + it('imports and defines foxy-i18n', () => { + expect(customElements.get('foxy-i18n')).to.not.be.undefined; + }); + + it('imports and defines foxy-internal-control', () => { + expect(customElements.get('foxy-internal-control')).to.equal(InternalControl); + }); + + it('imports and defines itself as foxy-internal-undo-control', () => { + expect(customElements.get('foxy-internal-undo-control')).to.equal(Control); + }); + + it('defines a reactive property for "theme" (String)', () => { + expect(Control).to.have.nested.property('properties.theme.type', String); + expect(new Control()).to.have.property('theme', 'secondary'); + }); + + it('extends InternalControl', () => { + expect(new Control()).to.be.instanceOf(InternalControl); + }); + + it('renders vaadin-button element', async () => { + const layout = html``; + const control = await fixture(layout); + const button = control.renderRoot.querySelector('vaadin-button'); + + expect(button).to.not.be.null; + }); + + it('renders translatable label "caption" within vaadin-button element', async () => { + const layout = html``; + const control = await fixture(layout); + const button = control.renderRoot.querySelector('vaadin-button'); + const label = button?.querySelector('foxy-i18n'); + + expect(label).to.not.be.null; + expect(label).to.have.property('key', 'caption'); + expect(label).to.have.property('infer', ''); + }); + + it('sets "disabled" on vaadin-button from "disabled" on itself', async () => { + const layout = html``; + const control = await fixture(layout); + const button = control.renderRoot.querySelector('vaadin-button')!; + + control.disabled = true; + await control.requestUpdate(); + expect(button).to.have.property('disabled', true); + + control.disabled = false; + await control.requestUpdate(); + expect(button).to.have.property('disabled', false); + }); + + it('clears edits in the host nucleon form on click', async () => { + const layout = html``; + const control = await fixture(layout); + const button = control.renderRoot.querySelector('vaadin-button')!; + const undoMethod = stub(control.nucleon, 'undo'); + + button.dispatchEvent(new MouseEvent('click')); + expect(undoMethod).to.have.been.calledOnce; + + undoMethod.restore(); + }); +}); diff --git a/src/elements/internal/InternalUndoControl/InternalUndoControl.ts b/src/elements/internal/InternalUndoControl/InternalUndoControl.ts new file mode 100644 index 000000000..0649fbb82 --- /dev/null +++ b/src/elements/internal/InternalUndoControl/InternalUndoControl.ts @@ -0,0 +1,35 @@ +import type { TemplateResult, PropertyDeclarations } from 'lit-element'; + +import { InternalControl } from '../InternalControl/InternalControl'; +import { html } from 'lit-element'; + +/** + * Internal control displaying an "Undo" button that triggers Nucleon undo() + * method on click. + * + * @since 1.28.0 + * @element foxy-internal-undo-control + */ +export class InternalUndoControl extends InternalControl { + static get properties(): PropertyDeclarations { + return { + ...super.properties, + theme: { type: String }, + }; + } + + /** Same as the "theme" attribute of the `vaadin-button` element. */ + theme = 'secondary'; + + renderControl(): TemplateResult { + return html` + this.nucleon?.undo()} + > + + + `; + } +} diff --git a/src/elements/internal/InternalUndoControl/index.ts b/src/elements/internal/InternalUndoControl/index.ts new file mode 100644 index 000000000..a18525a7b --- /dev/null +++ b/src/elements/internal/InternalUndoControl/index.ts @@ -0,0 +1,10 @@ +import '@vaadin/vaadin-button'; + +import '../../public/I18n/index'; +import '../InternalControl/index'; + +import { InternalUndoControl } from './InternalUndoControl'; + +customElements.define('foxy-internal-undo-control', InternalUndoControl); + +export { InternalUndoControl }; diff --git a/src/elements/public/AccessRecoveryForm/AccessRecoveryForm.ts b/src/elements/public/AccessRecoveryForm/AccessRecoveryForm.ts index 745cfd5fc..b5dbc4975 100644 --- a/src/elements/public/AccessRecoveryForm/AccessRecoveryForm.ts +++ b/src/elements/public/AccessRecoveryForm/AccessRecoveryForm.ts @@ -1,4 +1,4 @@ -import { Data, Templates } from './types'; +import { Data } from './types'; import { TemplateResult, html } from 'lit-element'; import { ConfigurableMixin } from '../../../mixins/configurable'; @@ -17,15 +17,6 @@ const Base = ThemeableMixin(ConfigurableMixin(TranslatableMixin(NucleonElement, /** * Email-based "forgot password" form. * - * @slot email:before - * @slot email:after - * - * @slot message:before - * @slot message:after - * - * @slot submit:before - * @slot submit:after - * * @element foxy-access-recovery-form * @since 1.4.0 */ @@ -37,8 +28,6 @@ export class AccessRecoveryForm extends Base { ]; } - templates: Templates = {}; - private readonly __checkEmailValidity = () => { return !this.errors.some(err => err.startsWith('email')); }; diff --git a/src/elements/public/AccessRecoveryForm/types.ts b/src/elements/public/AccessRecoveryForm/types.ts index 6eb48a659..827733a31 100644 --- a/src/elements/public/AccessRecoveryForm/types.ts +++ b/src/elements/public/AccessRecoveryForm/types.ts @@ -1,6 +1,4 @@ import { Resource } from '@foxy.io/sdk/core'; -import { Renderer } from '../../../mixins/configurable'; -import { AccessRecoveryForm } from './AccessRecoveryForm'; type Rel = { links: { self: Rel }; @@ -11,11 +9,3 @@ type Rel = { }; export type Data = Resource; -export type Templates = { - 'email:before'?: Renderer; - 'email:after'?: Renderer; - 'message:before'?: Renderer; - 'message:after'?: Renderer; - 'submit:before'?: Renderer; - 'submit:after'?: Renderer; -}; diff --git a/src/elements/public/AddressCard/AddressCard.ts b/src/elements/public/AddressCard/AddressCard.ts index f653b3b1f..dcff1d8a8 100644 --- a/src/elements/public/AddressCard/AddressCard.ts +++ b/src/elements/public/AddressCard/AddressCard.ts @@ -1,4 +1,4 @@ -import { Data, Templates } from './types'; +import { Data } from './types'; import { TemplateResult, html } from 'lit-html'; import { ConfigurableMixin } from '../../../mixins/configurable'; @@ -13,27 +13,10 @@ const Base = ConfigurableMixin(ThemeableMixin(TranslatableMixin(NucleonElement, /** * Card element displaying a customer address. * - * @slot address-name:before - **new in v1.4.0** - * @slot address-name:after - **new in v1.4.0** - * - * @slot full-name:before - **new in v1.4.0** - * @slot full-name:after - **new in v1.4.0** - * - * @slot full-address:before - **new in v1.4.0** - * @slot full-address:after - **new in v1.4.0** - * - * @slot company:before - **new in v1.4.0** - * @slot company:after - **new in v1.4.0** - * - * @slot phone:before - **new in v1.4.0** - * @slot phone:after - **new in v1.4.0** - * * @element foxy-address-card * @since 1.2.0 */ export class AddressCard extends Base { - templates: Templates = {}; - private readonly __renderAddressName = () => { const isDefaultBilling = !!this.data?.is_default_billing; const isDefaultShipping = !!this.data?.is_default_shipping; diff --git a/src/elements/public/AddressCard/types.ts b/src/elements/public/AddressCard/types.ts index f820b278e..1d564a40c 100644 --- a/src/elements/public/AddressCard/types.ts +++ b/src/elements/public/AddressCard/types.ts @@ -1,18 +1,4 @@ import { Rels } from '@foxy.io/sdk/customer'; import { Resource } from '@foxy.io/sdk/core'; -import { AddressCard } from './AddressCard'; -import { Renderer } from '../../../mixins/configurable'; export type Data = Resource; -export type Templates = { - 'address-name:before'?: Renderer; - 'address-name:after'?: Renderer; - 'full-name:before'?: Renderer; - 'full-name:after'?: Renderer; - 'full-address:before'?: Renderer; - 'full-address:after'?: Renderer; - 'company:before'?: Renderer; - 'company:after'?: Renderer; - 'phone:before'?: Renderer; - 'phone:after'?: Renderer; -}; diff --git a/src/elements/public/AddressForm/AddressForm.stories.ts b/src/elements/public/AddressForm/AddressForm.stories.ts index 774539fbc..a563091c0 100644 --- a/src/elements/public/AddressForm/AddressForm.stories.ts +++ b/src/elements/public/AddressForm/AddressForm.stories.ts @@ -11,8 +11,8 @@ const summary: Summary = { localName: 'foxy-address-form', translatable: true, configurable: { - sections: ['timestamps'], - buttons: ['delete', 'create'], + sections: ['timestamps', 'header'], + buttons: ['delete', 'create', 'submit', 'undo', 'header:copy-id', 'header:copy-json'], inputs: [ 'address-name', 'first-name', @@ -25,6 +25,7 @@ const summary: Summary = { 'region', 'city', 'postal-code', + 'ignore-address-restrictions', ], }, }; diff --git a/src/elements/public/AddressForm/AddressForm.test.ts b/src/elements/public/AddressForm/AddressForm.test.ts index c53d6ed6f..5de70fd4c 100644 --- a/src/elements/public/AddressForm/AddressForm.test.ts +++ b/src/elements/public/AddressForm/AddressForm.test.ts @@ -1,15 +1,22 @@ +import type { InternalCheckboxGroupControl } from '../../internal/InternalCheckboxGroupControl/InternalCheckboxGroupControl'; import type { InternalSelectControl } from '../../internal/InternalSelectControl/InternalSelectControl'; +import type { FetchEvent } from '../NucleonElement/FetchEvent'; import type { Data } from './types'; import './index'; -import { expect, html, fixture } from '@open-wc/testing'; +import { expect, html, fixture, waitUntil } from '@open-wc/testing'; import { InternalForm } from '../../internal/InternalForm/InternalForm'; import { AddressForm } from './AddressForm'; import { getTestData } from '../../../testgen/getTestData'; import { countries } from './countries'; +import { stub } from 'sinon'; describe('AddressForm', () => { + it('imports and registers foxy-internal-checkbox-group-control', () => { + expect(customElements.get('foxy-internal-checkbox-group-control')).to.exist; + }); + it('imports and registers foxy-internal-select-control', () => { expect(customElements.get('foxy-internal-select-control')).to.exist; }); @@ -161,60 +168,82 @@ describe('AddressForm', () => { expect(element.errors).to.include('postal-code:v8n_too_long'); }); - it('makes address name readonly for default billing address', async () => { + it('hides address name input for default billing address', async () => { const layout = html``; const element = await fixture(layout); const data = await getTestData('./hapi/customer_addresses/0'); - expect(element.readonlySelector.matches('address-name', true)).to.be.false; + expect(element.hiddenSelector.matches('address-name', true)).to.be.false; data.is_default_billing = true; data.is_default_shipping = false; element.data = data; - expect(element.readonlySelector.matches('address-name', true)).to.be.true; + expect(element.hiddenSelector.matches('address-name', true)).to.be.true; }); - it('makes address name readonly for default shipping address', async () => { + it('hides address name input for default shipping address', async () => { const layout = html``; const element = await fixture(layout); const data = await getTestData('./hapi/customer_addresses/0'); - expect(element.readonlySelector.matches('address-name', true)).to.be.false; + expect(element.hiddenSelector.matches('address-name', true)).to.be.false; data.is_default_billing = false; data.is_default_shipping = true; element.data = data; - expect(element.readonlySelector.matches('address-name', true)).to.be.true; + expect(element.hiddenSelector.matches('address-name', true)).to.be.true; }); - it('makes Delete button disabled for default billing address', async () => { + it('hides Delete button for default billing address', async () => { const layout = html``; const element = await fixture(layout); const data = await getTestData('./hapi/customer_addresses/0'); - expect(element.disabledSelector.matches('delete', true)).to.be.false; + expect(element.hiddenSelector.matches('delete', true)).to.be.false; data.is_default_billing = true; data.is_default_shipping = false; element.data = data; - expect(element.disabledSelector.matches('delete', true)).to.be.true; + expect(element.hiddenSelector.matches('delete', true)).to.be.true; }); - it('makes Delete button disabled for default shipping address', async () => { + it('hides Delete button for default shipping address', async () => { const layout = html``; const element = await fixture(layout); const data = await getTestData('./hapi/customer_addresses/0'); - expect(element.disabledSelector.matches('delete', true)).to.be.false; + expect(element.hiddenSelector.matches('delete', true)).to.be.false; data.is_default_billing = false; data.is_default_shipping = true; element.data = data; - expect(element.disabledSelector.matches('delete', true)).to.be.true; + expect(element.hiddenSelector.matches('delete', true)).to.be.true; + }); + + it('renders a form header', () => { + const form = new AddressForm(); + const renderHeaderMethod = stub(form, 'renderHeader'); + form.render(); + expect(renderHeaderMethod).to.have.been.called; + }); + + it('uses a custom subtitle key for form header', async () => { + const layout = html``; + const element = await fixture(layout); + + element.data = await getTestData('./hapi/customer_addresses/0'); + element.data = { ...element.data, is_default_billing: true, is_default_shipping: false }; + expect(element.headerSubtitleKey).to.equal('subtitle_default_billing'); + + element.data = { ...element.data, is_default_billing: false, is_default_shipping: true }; + expect(element.headerSubtitleKey).to.equal('subtitle_default_shipping'); + + element.data = { ...element.data, is_default_billing: false, is_default_shipping: false }; + expect(element.headerSubtitleKey).to.equal('subtitle_custom'); }); it('renders a text control for address name', async () => { @@ -366,4 +395,69 @@ describe('AddressForm', () => { expect(control).to.exist; }); + + it('renders a checkbox group control for ignoring address restrictions', async () => { + const layout = html``; + const element = await fixture(layout); + const control = element.renderRoot.querySelector( + 'foxy-internal-checkbox-group-control[infer="ignore-address-restrictions"]' + ); + + expect(control).to.exist; + expect(control).to.have.deep.property('options', [{ label: 'option_true', value: 'true' }]); + expect(control?.getValue()).to.deep.equal([]); + + element.edit({ ignore_address_restrictions: true }); + expect(control?.getValue()).to.deep.equal(['true']); + + control?.setValue([]); + expect(element.form).to.have.property('ignore_address_restrictions', false); + + control?.setValue(['true']); + expect(element.form).to.have.property('ignore_address_restrictions', true); + }); + + it('renders "country_banned" general error when selected country is disallowed by store settings', async () => { + const form = await fixture(html``); + + form.data = await getTestData('./hapi/customer_addresses/0'); + form.addEventListener('fetch', (evt: Event) => { + const event = evt as FetchEvent; + const body = JSON.stringify({ + _embedded: { + 'fx:errors': [{ message: 'Country is invalid or disallowed by store configuration' }], + }, + }); + + event.respondWith(Promise.resolve(new Response(body, { status: 400 }))); + }); + + form.edit({ address_name: 'Test Address', address1: 'Foo Bar 123' }); + form.submit(); + + await waitUntil(() => !!form.in('idle')); + expect(form.errors).to.include('error:country_banned'); + }); + + it('renders "address_name_exists" general error when address name is already taken', async () => { + const form = await fixture(html``); + + form.data = await getTestData('./hapi/customer_addresses/0'); + form.addEventListener('fetch', (evt: Event) => { + const event = evt as FetchEvent; + const body = JSON.stringify({ + _embedded: { + 'fx:errors': [{ message: 'this address name already exists for this customer' }], + }, + }); + + event.respondWith(Promise.resolve(new Response(body, { status: 400 }))); + }); + + form.edit({ address_name: 'Test Address', address1: 'Foo Bar 123' }); + form.submit(); + + await waitUntil(() => !!form.in('idle')); + expect(form.errors).to.include('error:address_name_exists'); + }); }); diff --git a/src/elements/public/AddressForm/AddressForm.ts b/src/elements/public/AddressForm/AddressForm.ts index 406eb75b3..f3fd9e40d 100644 --- a/src/elements/public/AddressForm/AddressForm.ts +++ b/src/elements/public/AddressForm/AddressForm.ts @@ -1,4 +1,4 @@ -import type { Data, Templates } from './types'; +import type { Data } from './types'; import type { TemplateResult } from 'lit-html'; import type { NucleonV8N } from '../NucleonElement/types'; @@ -14,48 +14,6 @@ const Base = TranslatableMixin(InternalForm, NS); /** * Basic form displaying customer address. * - * @slot address-name:before - **new in v1.4.0** - * @slot address-name:after - **new in v1.4.0** - * - * @slot first-name:before - **new in v1.4.0** - * @slot first-name:after - **new in v1.4.0** - * - * @slot last-name:before - **new in v1.4.0** - * @slot last-name:after - **new in v1.4.0** - * - * @slot region:before - **new in v1.4.0** - * @slot region:after - **new in v1.4.0** - * - * @slot city:before - **new in v1.4.0** - * @slot city:after - **new in v1.4.0** - * - * @slot phone:before - **new in v1.4.0** - * @slot phone:after - **new in v1.4.0** - * - * @slot company:before - **new in v1.4.0** - * @slot company:after - **new in v1.4.0** - * - * @slot address-one:before - **new in v1.4.0** - * @slot address-one:after - **new in v1.4.0** - * - * @slot address-two:before - **new in v1.4.0** - * @slot address-two:after - **new in v1.4.0** - * - * @slot country:before - **new in v1.4.0** - * @slot country:after - **new in v1.4.0** - * - * @slot postal-code:before - **new in v1.4.0** - * @slot postal-code:after - **new in v1.4.0** - * - * @slot timestamps:before - **new in v1.4.0** - * @slot timestamps:after - **new in v1.4.0** - * - * @slot create:before - **new in v1.4.0** - * @slot create:after - **new in v1.4.0** - * - * @slot delete:before - **new in v1.4.0** - * @slot delete:after - **new in v1.4.0** - * * @element foxy-address-form * @since 1.2.0 */ @@ -77,30 +35,39 @@ export class AddressForm extends Base { ]; } - templates: Templates = {}; + private __ignoreAddressRestrictionsGetValue = () => { + return this.form.ignore_address_restrictions ? ['true'] : []; + }; + + private __ignoreAddressRestrictionsSetValue = (newValue: string[]) => { + this.edit({ ignore_address_restrictions: newValue.includes('true') }); + }; + + private __ignoreAddressRestrictionsOptions = [{ label: 'option_true', value: 'true' }]; private __countrySetValue = (newValue: string) => { this.edit({ country: newValue, region: '' }); }; - get readonlySelector(): BooleanSelector { - const alwaysReadonly = [super.readonlySelector.toString()]; + get hiddenSelector(): BooleanSelector { + const alwaysHidden = [super.hiddenSelector.toString()]; const isDefault = !!this.data?.is_default_shipping || !!this.data?.is_default_billing; - if (isDefault) alwaysReadonly.unshift('address-name'); - return new BooleanSelector(alwaysReadonly.join(' ').trim()); + if (isDefault) alwaysHidden.unshift('delete', 'address-name'); + return new BooleanSelector(alwaysHidden.join(' ').trim()); } - get disabledSelector(): BooleanSelector { - const alwaysDisabled = [super.disabledSelector.toString()]; - const isDefault = !!this.data?.is_default_shipping || !!this.data?.is_default_billing; - if (isDefault) alwaysDisabled.unshift('delete'); - return new BooleanSelector(alwaysDisabled.join(' ').trim()); + get headerSubtitleKey(): string { + if (this.data?.is_default_shipping) return 'subtitle_default_shipping'; + if (this.data?.is_default_billing) return 'subtitle_default_billing'; + return 'subtitle_custom'; } renderBody(): TemplateResult { const regionOptions = this.__regionOptions; return html` + ${this.renderHeader()} +
@@ -132,11 +99,42 @@ export class AddressForm extends Base { + + +
${super.renderBody()} `; } + protected async _fetch(...args: Parameters): Promise { + try { + return await super._fetch(...args); + } catch (err) { + let message; + + try { + message = (await (err as Response).json())._embedded['fx:errors'][0].message; + } catch { + throw err; + } + + if (message.includes('Country is invalid or disallowed by store configuration')) { + throw ['error:country_banned']; + } else if (message.includes('this address name already exists for this customer')) { + throw ['error:address_name_exists']; + } else { + throw err; + } + } + } + private get __countryOptions() { return Object.keys(countries).map(code => ({ label: this.t(`country_${code.toLowerCase()}`), diff --git a/src/elements/public/AddressForm/index.ts b/src/elements/public/AddressForm/index.ts index 377cdd3e1..2808355a9 100644 --- a/src/elements/public/AddressForm/index.ts +++ b/src/elements/public/AddressForm/index.ts @@ -1,3 +1,4 @@ +import '../../internal/InternalCheckboxGroupControl/index'; import '../../internal/InternalSelectControl/index'; import '../../internal/InternalTextControl/index'; import '../../internal/InternalForm/index'; diff --git a/src/elements/public/AddressForm/types.ts b/src/elements/public/AddressForm/types.ts index 725dc813d..f4f258e9d 100644 --- a/src/elements/public/AddressForm/types.ts +++ b/src/elements/public/AddressForm/types.ts @@ -1,35 +1,7 @@ -import type { AddressForm } from './AddressForm'; -import type { Renderer } from '../../../mixins/configurable'; import type { Resource } from '@foxy.io/sdk/core'; import type { Rels } from '@foxy.io/sdk/customer'; -export type Data = Resource; - -export type Templates = { - 'address-name:before'?: Renderer; - 'address-name:after'?: Renderer; - 'first-name:before'?: Renderer; - 'first-name:after'?: Renderer; - 'last-name:before'?: Renderer; - 'last-name:after'?: Renderer; - 'region:before'?: Renderer; - 'region:after'?: Renderer; - 'city:before'?: Renderer; - 'city:after'?: Renderer; - 'phone:before'?: Renderer; - 'phone:after'?: Renderer; - 'company:before'?: Renderer; - 'company:after'?: Renderer; - 'address-one:before'?: Renderer; - 'address-one:after'?: Renderer; - 'address-two:before'?: Renderer; - 'address-two:after'?: Renderer; - 'postal-code:before'?: Renderer; - 'postal-code:after'?: Renderer; - 'timestamps:before'?: Renderer; - 'timestamps:after'?: Renderer; - 'delete:before'?: Renderer; - 'delete:after'?: Renderer; - 'create:before'?: Renderer; - 'create:after'?: Renderer; +export type Data = Resource & { + /** By default, the country value must be valid according to the store's location_filtering value in the template_config. For instance, if your store is configured to only allow shipping and billing to the US, attempting to set the country to CA (Canada) will error. If true is passed in, the country can be any valid values. For customer_address resources that aren't the default shipping or billing, the validation will assume the shipping restrictions. NOTE: This does not currently take the region filtering into account. Defaults to false. */ + ignore_address_restrictions: boolean; }; diff --git a/src/elements/public/ApiBrowser/internal/InternalApiBrowserResourceForm/InternalApiBrowserResourceForm.test.ts b/src/elements/public/ApiBrowser/internal/InternalApiBrowserResourceForm/InternalApiBrowserResourceForm.test.ts index 6eaf9a322..6a4477cc9 100644 --- a/src/elements/public/ApiBrowser/internal/InternalApiBrowserResourceForm/InternalApiBrowserResourceForm.test.ts +++ b/src/elements/public/ApiBrowser/internal/InternalApiBrowserResourceForm/InternalApiBrowserResourceForm.test.ts @@ -24,8 +24,8 @@ describe('ApiBrowser', () => { expect(customElements.get('foxy-internal-delete-control')).to.exist; }); - it('imports and defines foxy-internal-create-control', () => { - expect(customElements.get('foxy-internal-create-control')).to.exist; + it('imports and defines foxy-internal-submit-control', () => { + expect(customElements.get('foxy-internal-submit-control')).to.exist; }); it('imports and defines foxy-internal-form', () => { @@ -154,12 +154,12 @@ describe('ApiBrowser', () => { expect(summary).to.include.text('hapi/customers?email=foo'); }); - it('renders foxy-internal-create-control in idle.snapshot.dirty and idle.template states', async () => { + it('renders foxy-internal-submit-control in idle.snapshot.dirty and idle.template states', async () => { const form = await fixture(html` `); - let control = form.renderRoot.querySelector('foxy-internal-create-control'); + let control = form.renderRoot.querySelector('foxy-internal-submit-control'); expect(control).to.exist; expect(control).to.have.property('infer', 'create'); @@ -167,13 +167,13 @@ describe('ApiBrowser', () => { form.href = 'https://demo.api/hapi/customers/0'; await form.requestUpdate(); - control = form.renderRoot.querySelector('foxy-internal-create-control'); + control = form.renderRoot.querySelector('foxy-internal-submit-control'); expect(control).to.not.exist; form.data = null; await form.requestUpdate(); - control = form.renderRoot.querySelector('foxy-internal-create-control'); + control = form.renderRoot.querySelector('foxy-internal-submit-control'); expect(control).to.exist; }); diff --git a/src/elements/public/ApiBrowser/internal/InternalApiBrowserResourceForm/InternalApiBrowserResourceForm.ts b/src/elements/public/ApiBrowser/internal/InternalApiBrowserResourceForm/InternalApiBrowserResourceForm.ts index 4227a5c50..2a2cc9755 100644 --- a/src/elements/public/ApiBrowser/internal/InternalApiBrowserResourceForm/InternalApiBrowserResourceForm.ts +++ b/src/elements/public/ApiBrowser/internal/InternalApiBrowserResourceForm/InternalApiBrowserResourceForm.ts @@ -103,8 +103,8 @@ export class InternalApiBrowserResourceForm extends TranslatableMixin(InternalFo ${this.in({ idle: { snapshot: 'dirty' } }) || this.in({ idle: 'template' }) ? html` - - + + ` : ''} ${this.in({ idle: { snapshot: 'dirty' } }) || this.in({ idle: { template: 'dirty' } }) diff --git a/src/elements/public/ApiBrowser/internal/InternalApiBrowserResourceForm/index.ts b/src/elements/public/ApiBrowser/internal/InternalApiBrowserResourceForm/index.ts index 4999966c8..b131e85f2 100644 --- a/src/elements/public/ApiBrowser/internal/InternalApiBrowserResourceForm/index.ts +++ b/src/elements/public/ApiBrowser/internal/InternalApiBrowserResourceForm/index.ts @@ -3,7 +3,7 @@ import '@polymer/iron-icons'; import '@polymer/iron-icon'; import '../../../../internal/InternalDeleteControl/index'; -import '../../../../internal/InternalCreateControl/index'; +import '../../../../internal/InternalSubmitControl/index'; import '../../../../internal/InternalSourceControl/index'; import '../../../../internal/InternalForm/index'; import '../../../CopyToClipboard/index'; diff --git a/src/elements/public/AppliedCouponCodeForm/AppliedCouponCodeForm.stories.ts b/src/elements/public/AppliedCouponCodeForm/AppliedCouponCodeForm.stories.ts index 5de882fe4..1424a7128 100644 --- a/src/elements/public/AppliedCouponCodeForm/AppliedCouponCodeForm.stories.ts +++ b/src/elements/public/AppliedCouponCodeForm/AppliedCouponCodeForm.stories.ts @@ -11,7 +11,8 @@ const summary: Summary = { localName: 'foxy-applied-coupon-code-form', translatable: true, configurable: { - buttons: ['create', 'delete'], + sections: ['header'], + buttons: ['delete', 'create', 'submit', 'undo', 'header:copy-id', 'header:copy-json'], inputs: ['code', 'ignore-usage-limits'], }, }; diff --git a/src/elements/public/AppliedCouponCodeForm/AppliedCouponCodeForm.test.ts b/src/elements/public/AppliedCouponCodeForm/AppliedCouponCodeForm.test.ts index 2f8ee0ae6..4eb073a79 100644 --- a/src/elements/public/AppliedCouponCodeForm/AppliedCouponCodeForm.test.ts +++ b/src/elements/public/AppliedCouponCodeForm/AppliedCouponCodeForm.test.ts @@ -10,6 +10,7 @@ import { InternalTextControl } from '../../internal/InternalTextControl/Internal import { InternalForm } from '../../internal/InternalForm/InternalForm'; import { createRouter } from '../../../server'; import { getTestData } from '../../../testgen/getTestData'; +import { stub } from 'sinon'; describe('AppliedCouponCodeForm', () => { it('imports and registers foxy-internal-checkbox-group-control element', () => { @@ -49,6 +50,13 @@ describe('AppliedCouponCodeForm', () => { expect(new Form().hiddenSelector.toString()).to.equal('timestamps'); }); + it('renders a form header', () => { + const form = new Form(); + const renderHeaderMethod = stub(form, 'renderHeader'); + form.render(); + expect(renderHeaderMethod).to.have.been.called; + }); + it('renders a text control for "code" field', async () => { const element = await fixture
( html`` diff --git a/src/elements/public/AppliedCouponCodeForm/AppliedCouponCodeForm.ts b/src/elements/public/AppliedCouponCodeForm/AppliedCouponCodeForm.ts index ee7fddf3c..61f44ccb2 100644 --- a/src/elements/public/AppliedCouponCodeForm/AppliedCouponCodeForm.ts +++ b/src/elements/public/AppliedCouponCodeForm/AppliedCouponCodeForm.ts @@ -1,4 +1,4 @@ -import type { Data, Templates } from './types'; +import type { Data } from './types'; import type { TemplateResult } from 'lit-html'; import type { NucleonV8N } from '../NucleonElement/types'; @@ -13,18 +13,6 @@ const Base = TranslatableMixin(InternalForm, NS); /** * Form element for managing applied coupon codes (`fx:applied_coupon_code`). * - * @slot code:before - * @slot code:after - * - * @slot ignore-usage-limits:before - * @slot ignore-usage-limits:after - * - * @slot create:before - * @slot create:after - * - * @slot delete:before - * @slot delete:after - * * @element foxy-applied-coupon-code-form * @since 1.21.0 */ @@ -33,8 +21,6 @@ export class AppliedCouponCodeForm extends Base { return [({ code: v }) => !!v || 'code:v8n_required']; } - templates: Templates = {}; - private readonly __ignoreUsageLimitsOptions = [{ value: 'checked', label: 'option_checked' }]; private readonly __getIgnoreUsageLimitsValue = () => { @@ -55,6 +41,8 @@ export class AppliedCouponCodeForm extends Base { renderBody(): TemplateResult { return html` + ${this.renderHeader()} + ; - -export type Templates = { - 'code:before'?: Renderer; - 'code:after'?: Renderer; - 'ignore-usage-limits:before'?: Renderer; - 'ignore-usage-limits:after'?: Renderer; - 'create:before'?: Renderer; - 'create:after'?: Renderer; - 'delete:before'?: Renderer; - 'delete:after'?: Renderer; -}; diff --git a/src/elements/public/AppliedTaxCard/AppliedTaxCard.ts b/src/elements/public/AppliedTaxCard/AppliedTaxCard.ts index 45f3a1f33..3b2c707fb 100644 --- a/src/elements/public/AppliedTaxCard/AppliedTaxCard.ts +++ b/src/elements/public/AppliedTaxCard/AppliedTaxCard.ts @@ -9,12 +9,6 @@ import { TwoLineCard } from '../CustomFieldCard/TwoLineCard'; /** * Basic card displaying an applied tax. * - * @slot title:before - * @slot title:after - * - * @slot subtitle:before - * @slot subtitle:after - * * @element foxy-applied-tax-card * @since 1.11.0 */ diff --git a/src/elements/public/AttributeCard/AttributeCard.ts b/src/elements/public/AttributeCard/AttributeCard.ts index f3adb42ee..5c16022ca 100644 --- a/src/elements/public/AttributeCard/AttributeCard.ts +++ b/src/elements/public/AttributeCard/AttributeCard.ts @@ -1,4 +1,4 @@ -import { Data, Templates } from './types'; +import { Data } from './types'; import { TemplateResult, html } from 'lit-html'; import { ConfigurableMixin } from '../../../mixins/configurable'; @@ -16,17 +16,10 @@ const Base = ResponsiveMixin( /** * Basic card displaying an attribute. * - * @slot name:before - **new in v1.4.0** - * @slot name:after - **new in v1.4.0** - * @slot value:before - **new in v1.4.0** - * @slot value:after - **new in v1.4.0** - * * @element foxy-attribute-card * @since 1.2.0 */ export class AttributeCard extends Base { - templates: Templates = {}; - private readonly __renderName = () => { const { data } = this; diff --git a/src/elements/public/AttributeCard/types.ts b/src/elements/public/AttributeCard/types.ts index d6951f190..7f1cd0c3e 100644 --- a/src/elements/public/AttributeCard/types.ts +++ b/src/elements/public/AttributeCard/types.ts @@ -1,12 +1,4 @@ -import { AttributeCard } from './AttributeCard'; -import { Rels } from '@foxy.io/sdk/backend'; -import { Renderer } from '../../../mixins/configurable'; import { Resource } from '@foxy.io/sdk/core'; +import { Rels } from '@foxy.io/sdk/backend'; export type Data = Resource; -export type Templates = { - 'name:before'?: Renderer; - 'name:after'?: Renderer; - 'value:before'?: Renderer; - 'value:after'?: Renderer; -}; diff --git a/src/elements/public/AttributeForm/AttributeForm.stories.ts b/src/elements/public/AttributeForm/AttributeForm.stories.ts index 096387a66..2cf95e761 100644 --- a/src/elements/public/AttributeForm/AttributeForm.stories.ts +++ b/src/elements/public/AttributeForm/AttributeForm.stories.ts @@ -11,8 +11,8 @@ const summary: Summary = { localName: 'foxy-attribute-form', translatable: true, configurable: { - sections: ['timestamps'], - buttons: ['create', 'delete'], + sections: ['timestamps', 'header'], + buttons: ['delete', 'create', 'submit', 'undo', 'header:copy-id', 'header:copy-json'], inputs: ['name', 'value', 'visibility'], }, }; diff --git a/src/elements/public/AttributeForm/AttributeForm.test.ts b/src/elements/public/AttributeForm/AttributeForm.test.ts index 200f7db0e..2a9196b86 100644 --- a/src/elements/public/AttributeForm/AttributeForm.test.ts +++ b/src/elements/public/AttributeForm/AttributeForm.test.ts @@ -1,9 +1,12 @@ import type { InternalRadioGroupControl } from '../../internal/InternalRadioGroupControl/InternalRadioGroupControl'; +import type { Data } from './types'; import './index'; import { expect, fixture, html } from '@open-wc/testing'; import { AttributeForm } from './AttributeForm'; +import { getTestData } from '../../../testgen/getTestData'; +import { stub } from 'sinon'; describe('AttributeForm', () => { it('imports and defines foxy-internal-radio-group-control', () => { @@ -65,12 +68,33 @@ describe('AttributeForm', () => { expect(element.errors).to.include('name:v8n_too_long'); }); - it('makes visibility control readonly when href is set', async () => { + it('hides visibility control readonly when href is set', async () => { const element = new AttributeForm(); - expect(element.readonlySelector.matches('visibility', true)).to.be.false; + expect(element.hiddenSelector.matches('visibility', true)).to.be.false; element.href = 'https://demo.api/hapi/customer_attributes/0'; - expect(element.readonlySelector.matches('visibility', true)).to.be.true; + expect(element.hiddenSelector.matches('visibility', true)).to.be.true; + }); + + it('renders a form header', () => { + const form = new AttributeForm(); + const renderHeaderMethod = stub(form, 'renderHeader'); + form.render(); + expect(renderHeaderMethod).to.have.been.called; + }); + + it('uses a custom header subtitle key', async () => { + const element = await fixture(html``); + const data = await getTestData('./hapi/customer_attributes/0'); + + element.data = { ...data, visibility: 'public' }; + expect(element.headerSubtitleKey).to.equal('subtitle_public'); + + element.data = { ...data, visibility: 'restricted' }; + expect(element.headerSubtitleKey).to.equal('subtitle_restricted'); + + element.data = { ...data, visibility: 'private' }; + expect(element.headerSubtitleKey).to.equal('subtitle_private'); }); it('renders a source control for name', async () => { diff --git a/src/elements/public/AttributeForm/AttributeForm.ts b/src/elements/public/AttributeForm/AttributeForm.ts index 0b3f1a491..33ba924b4 100644 --- a/src/elements/public/AttributeForm/AttributeForm.ts +++ b/src/elements/public/AttributeForm/AttributeForm.ts @@ -1,4 +1,4 @@ -import type { Data, Templates } from './types'; +import type { Data } from './types'; import type { TemplateResult } from 'lit-html'; import type { NucleonV8N } from '../NucleonElement/types'; @@ -13,24 +13,6 @@ const Base = TranslatableMixin(InternalForm, NS); /** * Form element for creating or editing attributes. * - * @slot name:before - **new in v1.4.0** - * @slot name:after - **new in v1.4.0** - * - * @slot value:before - **new in v1.4.0** - * @slot value:after - **new in v1.4.0** - * - * @slot visibility:before - **new in v1.4.0** - * @slot visibility:after - **new in v1.4.0** - * - * @slot timestamps:before - **new in v1.4.0** - * @slot timestamps:after - **new in v1.4.0** - * - * @slot create:before - **new in v1.4.0** - * @slot create:after - **new in v1.4.0** - * - * @slot delete:before - **new in v1.4.0** - * @slot delete:after - **new in v1.4.0** - * * @element foxy-attribute-form * @since 1.2.0 */ @@ -44,8 +26,6 @@ export class AttributeForm extends Base { ]; } - templates: Templates = {}; - private readonly __visibilityGetValue = () => { return this.form.visibility || 'private'; }; @@ -56,14 +36,20 @@ export class AttributeForm extends Base { { label: 'option_private', value: 'private' }, ]; - get readonlySelector(): BooleanSelector { - const alwaysMatch = [super.readonlySelector.toString()]; + get hiddenSelector(): BooleanSelector { + const alwaysMatch = [super.hiddenSelector.toString()]; if (this.href) alwaysMatch.unshift('visibility'); return new BooleanSelector(alwaysMatch.join(' ').trim()); } + get headerSubtitleKey(): string { + return `subtitle_${this.data?.visibility}`; + } + renderBody(): TemplateResult { return html` + ${this.renderHeader()} + ; -export type Templates = { - 'name:before'?: Renderer; - 'name:after'?: Renderer; - 'value:before'?: Renderer; - 'value:after'?: Renderer; - 'visibility:before'?: Renderer; - 'visibility:after'?: Renderer; - 'timestamps:before'?: Renderer; - 'timestamps:after'?: Renderer; - 'delete:before'?: Renderer; - 'delete:after'?: Renderer; - 'create:before'?: Renderer; - 'create:after'?: Renderer; -}; diff --git a/src/elements/public/CancellationForm/CancellationForm.ts b/src/elements/public/CancellationForm/CancellationForm.ts index 609c99ae2..ca4c85b7f 100644 --- a/src/elements/public/CancellationForm/CancellationForm.ts +++ b/src/elements/public/CancellationForm/CancellationForm.ts @@ -1,4 +1,4 @@ -import { Data, Templates } from './types'; +import { Data } from './types'; import { Group, Warning } from '../../private/index'; import { TemplateResult, html } from 'lit-element'; @@ -22,13 +22,6 @@ const Base = ScopedElementsMixin( /** * Form element for canceling subscriptions. * - * @slot warning:before - * @slot warning:after - * @slot end-date:before - * @slot end-date:after - * @slot submit:before - * @slot submit:after - * * @element foxy-cancellation-form * @since 1.4.0 * @deprecated @@ -50,8 +43,6 @@ export class CancellationForm extends Base { return [({ end_date: v }) => !!v || 'end_date_required']; } - templates: Templates = {}; - private readonly __renderWarning = () => { const { lang, ns } = this; diff --git a/src/elements/public/CancellationForm/types.ts b/src/elements/public/CancellationForm/types.ts index 52b19c17a..3d7af1692 100644 --- a/src/elements/public/CancellationForm/types.ts +++ b/src/elements/public/CancellationForm/types.ts @@ -1,14 +1,4 @@ -import { Rels } from '@foxy.io/sdk/customer'; -import { Resource } from '@foxy.io/sdk/core'; -import { Renderer } from '../../../mixins/configurable'; -import { CancellationForm } from './CancellationForm'; +import type { Resource } from '@foxy.io/sdk/core'; +import type { Rels } from '@foxy.io/sdk/customer'; export type Data = Resource; -export type Templates = { - 'warning:before'?: Renderer; - 'warning:after'?: Renderer; - 'end-date:before'?: Renderer; - 'end-date:after'?: Renderer; - 'submit:before'?: Renderer; - 'submit:after'?: Renderer; -}; diff --git a/src/elements/public/CartForm/CartForm.test.ts b/src/elements/public/CartForm/CartForm.test.ts index ea27cf518..54f1e0e65 100644 --- a/src/elements/public/CartForm/CartForm.test.ts +++ b/src/elements/public/CartForm/CartForm.test.ts @@ -12,7 +12,7 @@ import { InternalSelectControl } from '../../internal/InternalSelectControl/Inte import { AppliedCouponCodeCard } from '../AppliedCouponCodeCard/AppliedCouponCodeCard'; import { AppliedCouponCodeForm } from '../AppliedCouponCodeForm/AppliedCouponCodeForm'; import { InternalDeleteControl } from '../../internal/InternalDeleteControl/InternalDeleteControl'; -import { InternalCreateControl } from '../../internal/InternalCreateControl/InternalCreateControl'; +import { InternalSubmitControl } from '../../internal/InternalSubmitControl/InternalSubmitControl'; import { InternalTextControl } from '../../internal/InternalTextControl/InternalTextControl'; import { CartForm as Form } from './CartForm'; import { CustomFieldCard } from '../CustomFieldCard/CustomFieldCard'; @@ -33,7 +33,7 @@ import { ItemCard } from '../ItemCard/ItemCard'; import { ItemForm } from '../ItemForm/ItemForm'; import { spread } from '@open-wc/lit-helpers'; import { I18n } from '../I18n/I18n'; -import { fake } from 'sinon'; +import { fake, stub } from 'sinon'; describe('CartForm', () => { const OriginalResizeObserver = window.ResizeObserver; @@ -62,9 +62,9 @@ describe('CartForm', () => { expect(element).to.equal(InternalDeleteControl); }); - it('imports and defines foxy-internal-create-control', () => { - const element = customElements.get('foxy-internal-create-control'); - expect(element).to.equal(InternalCreateControl); + it('imports and defines foxy-internal-submit-control', () => { + const element = customElements.get('foxy-internal-submit-control'); + expect(element).to.equal(InternalSubmitControl); }); it('imports and defines foxy-internal-text-control', () => { @@ -376,6 +376,13 @@ describe('CartForm', () => { expect(form.errors).to.not.include('shipping-postal-code:v8n_too_long'); }); + it('renders a form header', () => { + const form = new Form(); + const renderHeaderMethod = stub(form, 'renderHeader'); + form.render(); + expect(renderHeaderMethod).to.have.been.called; + }); + it('renders order section title and description', async () => { const element = await fixture(html``); const title = await getByKey(element, 'order_section_title'); @@ -1746,6 +1753,6 @@ describe('CartForm', () => { `); const control = element.renderRoot.querySelector(`[infer="create"]`); - expect(control).to.be.instanceOf(InternalCreateControl); + expect(control).to.be.instanceOf(InternalSubmitControl); }); }); diff --git a/src/elements/public/CartForm/CartForm.ts b/src/elements/public/CartForm/CartForm.ts index b00355ed3..fdab5673f 100644 --- a/src/elements/public/CartForm/CartForm.ts +++ b/src/elements/public/CartForm/CartForm.ts @@ -1,5 +1,5 @@ import type { PropertyDeclarations } from 'lit-element'; -import type { Templates, Data } from './types'; +import type { Data } from './types'; import type { TemplateResult } from 'lit-html'; import type { NucleonElement } from '../NucleonElement/NucleonElement'; import type { FormRenderer } from '../FormDialog/types'; @@ -23,96 +23,6 @@ const Base = ResponsiveMixin(TranslatableMixin(InternalForm, NS)); /** * Form element for creating or editing carts (`fx:cart`). * - * @slot customer-type:before - * @slot customer-type:after - * - * @slot customer:before - * @slot customer:after - * - * @slot template-set-uri:before - * @slot template-set-uri:after - * - * @slot items:before - * @slot items:after - * - * @slot applied-coupon-codes:before - * @slot applied-coupon-codes:after - * - * @slot custom-fields:before - * @slot custom-fields:after - * - * @slot attributes:before - * @slot attributes:after - * - * @slot billing-first-name:before - * @slot billing-first-name:after - * - * @slot billing-last-name:before - * @slot billing-last-name:after - * - * @slot billing-company:before - * @slot billing-company:after - * - * @slot billing-phone:before - * @slot billing-phone:after - * - * @slot billing-address-one:before - * @slot billing-address-one:after - * - * @slot billing-address-two:before - * @slot billing-address-two:after - * - * @slot billing-country:before - * @slot billing-country:after - * - * @slot billing-region:before - * @slot billing-region:after - * - * @slot billing-city:before - * @slot billing-city:after - * - * @slot billing-postal-code:before - * @slot billing-postal-code:after - * - * @slot shipping-first-name:before - * @slot shipping-first-name:after - * - * @slot shipping-last-name:before - * @slot shipping-last-name:after - * - * @slot shipping-company:before - * @slot shipping-company:after - * - * @slot shipping-phone:before - * @slot shipping-phone:after - * - * @slot shipping-address-one:before - * @slot shipping-address-one:after - * - * @slot shipping-address-two:before - * @slot shipping-address-two:after - * - * @slot shipping-country:before - * @slot shipping-country:after - * - * @slot shipping-region:before - * @slot shipping-region:after - * - * @slot shipping-city:before - * @slot shipping-city:after - * - * @slot shipping-postal-code:before - * @slot shipping-postal-code:after - * - * @slot view-as-customer:before - * @slot view-as-customer:after - * - * @slot delete:before - * @slot delete:after - * - * @slot create:before - * @slot create:after - * * @element foxy-cart-form * @since 1.21.0 */ @@ -169,9 +79,6 @@ export class CartForm extends Base { /** URL of the `fx:countries` property helper. */ countries: string | null = null; - /** Template render functions mapped to their name. */ - templates: Templates = {}; - /** URL of the `fx:regions` property helper. */ regions: string | null = null; @@ -301,6 +208,8 @@ export class CartForm extends Base { } return html` + ${this.renderHeader()} +
@@ -503,7 +412,7 @@ export class CartForm extends Base {
` - : html``} + : html``}
; -export type Templates = { - 'customer-type:before'?: Renderer; - 'customer-type:after'?: Renderer; - 'customer:before'?: Renderer; - 'customer:after'?: Renderer; - 'template-set-uri:before'?: Renderer; - 'template-set-uri:after'?: Renderer; - 'items:before'?: Renderer; - 'items:after'?: Renderer; - 'applied-coupon-codes:before'?: Renderer; - 'applied-coupon-codes:after'?: Renderer; - 'custom-fields:before'?: Renderer; - 'custom-fields:after'?: Renderer; - 'attributes:before'?: Renderer; - 'attributes:after'?: Renderer; - 'billing-first-name:before'?: Renderer; - 'billing-first-name:after'?: Renderer; - 'billing-last-name:before'?: Renderer; - 'billing-last-name:after'?: Renderer; - 'billing-company:before'?: Renderer; - 'billing-company:after'?: Renderer; - 'billing-phone:before'?: Renderer; - 'billing-phone:after'?: Renderer; - 'billing-address-one:before'?: Renderer; - 'billing-address-one:after'?: Renderer; - 'billing-address-two:before'?: Renderer; - 'billing-address-two:after'?: Renderer; - 'billing-country:before'?: Renderer; - 'billing-country:after'?: Renderer; - 'billing-region:before'?: Renderer; - 'billing-region:after'?: Renderer; - 'billing-city:before'?: Renderer; - 'billing-city:after'?: Renderer; - 'billing-postal-code:before'?: Renderer; - 'billing-postal-code:after'?: Renderer; - 'shipping-first-name:before'?: Renderer; - 'shipping-first-name:after'?: Renderer; - 'shipping-last-name:before'?: Renderer; - 'shipping-last-name:after'?: Renderer; - 'shipping-company:before'?: Renderer; - 'shipping-company:after'?: Renderer; - 'shipping-phone:before'?: Renderer; - 'shipping-phone:after'?: Renderer; - 'shipping-address-one:before'?: Renderer; - 'shipping-address-one:after'?: Renderer; - 'shipping-address-two:before'?: Renderer; - 'shipping-address-two:after'?: Renderer; - 'shipping-country:before'?: Renderer; - 'shipping-country:after'?: Renderer; - 'shipping-region:before'?: Renderer; - 'shipping-region:after'?: Renderer; - 'shipping-city:before'?: Renderer; - 'shipping-city:after'?: Renderer; - 'shipping-postal-code:before'?: Renderer; - 'shipping-postal-code:after'?: Renderer; - 'view-as-customer:before'?: Renderer; - 'view-as-customer:after'?: Renderer; - 'delete:before'?: Renderer; - 'delete:after'?: Renderer; - 'create:before'?: Renderer; - 'create:after'?: Renderer; -}; diff --git a/src/elements/public/ClientForm/ClientForm.stories.ts b/src/elements/public/ClientForm/ClientForm.stories.ts index 424d31270..4a0528d48 100644 --- a/src/elements/public/ClientForm/ClientForm.stories.ts +++ b/src/elements/public/ClientForm/ClientForm.stories.ts @@ -11,8 +11,8 @@ const summary: Summary = { localName: 'foxy-client-form', translatable: true, configurable: { - sections: ['timestamps'], - buttons: ['create', 'delete'], + sections: ['timestamps', 'header'], + buttons: ['delete', 'create', 'submit', 'undo', 'header:copy-id', 'header:copy-json'], inputs: [], }, }; diff --git a/src/elements/public/ClientForm/ClientForm.test.ts b/src/elements/public/ClientForm/ClientForm.test.ts index 905bd2fac..54bf500cf 100644 --- a/src/elements/public/ClientForm/ClientForm.test.ts +++ b/src/elements/public/ClientForm/ClientForm.test.ts @@ -6,6 +6,7 @@ import { html, expect, fixture } from '@open-wc/testing'; import { createRouter } from '../../../server/index'; import { getTestData } from '../../../testgen/getTestData'; import { ClientForm as Form } from './ClientForm'; +import { stub } from 'sinon'; describe('ClientForm', () => { it('imports and defines foxy-internal-text-area-control', () => { @@ -33,6 +34,13 @@ describe('ClientForm', () => { expect(new Form()).to.have.property('ns', 'client-form'); }); + it('renders a form header', () => { + const form = new Form(); + const renderHeaderMethod = stub(form, 'renderHeader'); + form.render(); + expect(renderHeaderMethod).to.have.been.called; + }); + it('renders a foxy-internal-text-control for client id', async () => { const element = await fixture(html``); const control = element.renderRoot.querySelector('[infer="client-id"]'); diff --git a/src/elements/public/ClientForm/ClientForm.ts b/src/elements/public/ClientForm/ClientForm.ts index f46781d56..7eb59c07f 100644 --- a/src/elements/public/ClientForm/ClientForm.ts +++ b/src/elements/public/ClientForm/ClientForm.ts @@ -1,4 +1,4 @@ -import type { Data, Templates } from './types'; +import type { Data } from './types'; import type { TemplateResult } from 'lit-html'; import { TranslatableMixin } from '../../../mixins/translatable'; @@ -13,54 +13,10 @@ const Base = ResponsiveMixin(TranslatableMixin(InternalForm, NS)); /** * Form element for viewing and deleting clients (`fx:client`). * - * @slot client-id:before - * @slot client-id:after - * - * @slot client-secret:before - * @slot client-secret:after - * - * @slot redirect-uri:before - * @slot redirect-uri:after - * - * @slot project-name:before - * @slot project-name:after - * - * @slot project-description:before - * @slot project-description:after - * - * @slot company-name:before - * @slot company-name:after - * - * @slot company-url:before - * @slot company-url:after - * - * @slot company-logo:before - * @slot company-logo:after - * - * @slot contact-name:before - * @slot contact-name:after - * - * @slot contact-email:before - * @slot contact-email:after - * - * @slot contact-phone:before - * @slot contact-phone:after - * - * @slot timestamps:before - * @slot timestamps:after - * - * @slot create:before - * @slot create:after - * - * @slot delete:before - * @slot delete:after - * * @element foxy-client-form * @since 1.24.0 */ export class ClientForm extends Base { - templates: Templates = {}; - get readonlySelector(): BooleanSelector { const alwaysMatch = ['client-secret']; if (this.data || this.in({ busy: 'fetching' })) alwaysMatch.push('client-id'); @@ -75,6 +31,8 @@ export class ClientForm extends Base { renderBody(): TemplateResult { return html` + ${this.renderHeader()} +
diff --git a/src/elements/public/ClientForm/types.ts b/src/elements/public/ClientForm/types.ts index 6ede9ef1d..d3aa9aebc 100644 --- a/src/elements/public/ClientForm/types.ts +++ b/src/elements/public/ClientForm/types.ts @@ -1,37 +1,4 @@ -import type { ClientForm } from './ClientForm'; -import type { Renderer } from '../../../mixins/configurable'; import type { Resource } from '@foxy.io/sdk/core'; import type { Rels } from '@foxy.io/sdk/backend'; export type Data = Resource; - -export type Templates = { - 'client-id:before'?: Renderer; - 'client-id:after'?: Renderer; - 'client-secret:before'?: Renderer; - 'client-secret:after'?: Renderer; - 'redirect-uri:before'?: Renderer; - 'redirect-uri:after'?: Renderer; - 'project-name:before'?: Renderer; - 'project-name:after'?: Renderer; - 'project-description:before'?: Renderer; - 'project-description:after'?: Renderer; - 'company-name:before'?: Renderer; - 'company-name:after'?: Renderer; - 'company-url:before'?: Renderer; - 'company-url:after'?: Renderer; - 'company-logo:before'?: Renderer; - 'company-logo:after'?: Renderer; - 'contact-name:before'?: Renderer; - 'contact-name:after'?: Renderer; - 'contact-email:before'?: Renderer; - 'contact-email:after'?: Renderer; - 'contact-phone:before'?: Renderer; - 'contact-phone:after'?: Renderer; - 'timestamps:before'?: Renderer; - 'timestamps:after'?: Renderer; - 'create:before'?: Renderer; - 'create:after'?: Renderer; - 'delete:before'?: Renderer; - 'delete:after'?: Renderer; -}; diff --git a/src/elements/public/CollectionPages/CollectionPages.ts b/src/elements/public/CollectionPages/CollectionPages.ts index c85f54a60..aa9192c99 100644 --- a/src/elements/public/CollectionPages/CollectionPages.ts +++ b/src/elements/public/CollectionPages/CollectionPages.ts @@ -148,7 +148,7 @@ export class CollectionPages extends Base { /** URL of the first page in a collection. */ get first(): string { - return this.__service.state.context.first; + return this.__service.state?.context.first ?? ''; } set first(data: string) { @@ -157,7 +157,7 @@ export class CollectionPages extends Base { /** Array of all currently loaded pages in a collection. */ get pages(): TPage[] { - return this.__service.state.context.pages; + return this.__service.state?.context.pages ?? []; } set pages(data: TPage[]) { @@ -177,7 +177,7 @@ export class CollectionPages extends Base { /** If false, will load pages on scroll. If true, will display a button triggering the process. */ get manual(): boolean { - return this.__service.state.context.manual; + return !!this.__service.state?.context.manual; } set manual(data: boolean) { @@ -199,7 +199,7 @@ export class CollectionPages extends Base { * @example element.in({ idle: 'empty' }) */ in(stateValue: State['value']): boolean { - return this.__service.state.matches(stateValue); + return !!this.__service.state?.matches(stateValue); } /** @readonly */ @@ -222,11 +222,11 @@ export class CollectionPages extends Base { href: page._links.self.href, })); - if (this.__service.state.matches('busy')) { + if (this.__service.state?.matches('busy')) { items.push({ key: 'stalled', href: 'foxy://collection-pages/stall' }); - } else if (this.__service.state.matches('fail')) { + } else if (this.__service.state?.matches('fail')) { items.push({ key: 'failed', href: 'foxy://collection-pages/fail' }); - } else if (this.__service.state.matches({ idle: 'empty' })) { + } else if (this.__service.state?.matches({ idle: 'empty' })) { items.push({ key: 'empty', href: '' }); } @@ -340,7 +340,9 @@ export class CollectionPages extends Base { } private __failRequest(event: FetchEvent) { + const error = this.__service.state?.context.error as Response | undefined; + const response = error ?? new Response('Unknown error, details unavailable.', { status: 500 }); event.stopImmediatePropagation(); - event.respondWith(Promise.resolve(this.__service.state.context.error as Response)); + event.respondWith(Promise.resolve(response)); } } diff --git a/src/elements/public/CopyToClipboard/CopyToClipboard.stories.ts b/src/elements/public/CopyToClipboard/CopyToClipboard.stories.ts index 311f33d14..707558e82 100644 --- a/src/elements/public/CopyToClipboard/CopyToClipboard.stories.ts +++ b/src/elements/public/CopyToClipboard/CopyToClipboard.stories.ts @@ -7,6 +7,7 @@ export default { component: 'foxy-copy-to-clipboard', argTypes: { disabled: { control: { type: 'boolean' } }, + icon: { control: { type: 'text' } }, text: { control: { type: 'text' } }, lang: { control: { type: 'text' } }, ns: { control: { type: 'text' } }, @@ -17,6 +18,7 @@ export const Playground = (args: Record): TemplateResult => htm
${args.text} ): TemplateResult => htm > ${args.text} ): TemplateResult => htm > ${new Array(16).fill(args.text).join(' ')} ): TemplateResult => htm Playground.args = { disabled: false, + icon: 'icons:content-copy', text: 'Text to copy', lang: 'en', ns: 'copy-to-clipboard', diff --git a/src/elements/public/CopyToClipboard/CopyToClipboard.test.ts b/src/elements/public/CopyToClipboard/CopyToClipboard.test.ts index 8f60b80e9..b576878a3 100644 --- a/src/elements/public/CopyToClipboard/CopyToClipboard.test.ts +++ b/src/elements/public/CopyToClipboard/CopyToClipboard.test.ts @@ -4,6 +4,10 @@ import { stub } from 'sinon'; import { CopyToClipboard } from './index'; describe('CopyToClipboard', () => { + it('imports and registers vcf-tooltip element', () => { + expect(customElements.get('vcf-tooltip')).to.exist; + }); + it('imports and registers iron-icon element', () => { expect(customElements.get('iron-icon')).to.exist; }); @@ -24,6 +28,10 @@ describe('CopyToClipboard', () => { expect(CopyToClipboard).to.have.nested.property('properties.text.type', String); }); + it('has a reactive property/attribite named "icon" (String)', () => { + expect(CopyToClipboard).to.have.nested.property('properties.icon.type', String); + }); + it('has a default i18next namespace "copy-to-clipboard"', () => { expect(CopyToClipboard).to.have.property('defaultNS', 'copy-to-clipboard'); expect(new CopyToClipboard()).to.have.property('ns', 'copy-to-clipboard'); @@ -32,9 +40,26 @@ describe('CopyToClipboard', () => { it('renders in the idle state by default', async () => { const layout = html``; const element = await fixture(layout); - const button = element.renderRoot.querySelector('button') as HTMLButtonElement; + const tooltip = element.renderRoot.querySelector('vcf-tooltip foxy-i18n') as HTMLElement; + + expect(tooltip).to.have.property('infer', ''); + expect(tooltip).to.have.property('key', 'click_to_copy'); + }); + + it('renders default icon when icon attribute is not set', async () => { + const layout = html``; + const element = await fixture(layout); + const icon = element.renderRoot.querySelector('iron-icon') as HTMLElement; + + expect(icon).to.have.property('icon', 'icons:content-copy'); + }); + + it('renders custom icon when icon attribute is set', async () => { + const layout = html``; + const element = await fixture(layout); + const icon = element.renderRoot.querySelector('iron-icon') as HTMLElement; - expect(button).to.have.property('title', 'click_to_copy'); + expect(icon).to.have.property('icon', 'icons:foo'); }); it('copies text on click', async () => { @@ -69,11 +94,13 @@ describe('CopyToClipboard', () => { const layout = html``; const element = await fixture(layout); const button = element.renderRoot.querySelector('button') as HTMLButtonElement; + const tooltip = element.renderRoot.querySelector('vcf-tooltip foxy-i18n') as HTMLElement; button.click(); await element.requestUpdate(); - expect(button).to.have.property('title', 'copying'); + expect(tooltip).to.have.property('infer', ''); + expect(tooltip).to.have.property('key', 'copying'); writeTextMethod.restore(); }); @@ -82,19 +109,21 @@ describe('CopyToClipboard', () => { const layout = html``; const element = await fixture(layout); const button = element.renderRoot.querySelector('button') as HTMLButtonElement; + const tooltip = element.renderRoot.querySelector('vcf-tooltip foxy-i18n') as HTMLElement; button.click(); await waitUntil( async () => { await element.requestUpdate(); - return button.title === 'click_to_copy'; + return tooltip.getAttribute('key') === 'click_to_copy'; }, undefined, { timeout: 5000 } ); - expect(button).to.have.property('title', 'click_to_copy'); + expect(tooltip).to.have.property('infer', ''); + expect(tooltip).to.have.property('key', 'click_to_copy'); writeTextMethod.restore(); }); @@ -103,19 +132,21 @@ describe('CopyToClipboard', () => { const layout = html``; const element = await fixture(layout); const button = element.renderRoot.querySelector('button') as HTMLButtonElement; + const tooltip = element.renderRoot.querySelector('vcf-tooltip foxy-i18n') as HTMLElement; button.click(); await waitUntil( async () => { await element.requestUpdate(); - return button.title === 'failed_to_copy'; + return tooltip.getAttribute('key') === 'failed_to_copy'; }, undefined, { timeout: 5000 } ); - expect(button).to.have.property('title', 'failed_to_copy'); + expect(tooltip).to.have.property('infer', ''); + expect(tooltip).to.have.property('key', 'failed_to_copy'); writeTextMethod.restore(); }); @@ -124,19 +155,21 @@ describe('CopyToClipboard', () => { const layout = html``; const element = await fixture(layout); const button = element.renderRoot.querySelector('button') as HTMLButtonElement; + const tooltip = element.renderRoot.querySelector('vcf-tooltip foxy-i18n') as HTMLElement; button.click(); await waitUntil( async () => { await element.requestUpdate(); - return button.title === 'click_to_copy'; + return tooltip.getAttribute('key') === 'click_to_copy'; }, undefined, { timeout: 5000 } ); - expect(button).to.have.property('title', 'click_to_copy'); + expect(tooltip).to.have.property('infer', ''); + expect(tooltip).to.have.property('key', 'click_to_copy'); writeTextMethod.restore(); }); }); diff --git a/src/elements/public/CopyToClipboard/CopyToClipboard.ts b/src/elements/public/CopyToClipboard/CopyToClipboard.ts index ce6c19fba..bf6a76ed6 100644 --- a/src/elements/public/CopyToClipboard/CopyToClipboard.ts +++ b/src/elements/public/CopyToClipboard/CopyToClipboard.ts @@ -25,6 +25,7 @@ export class CopyToClipboard extends Base { return { ...super.properties, text: { type: String }, + icon: { type: String }, __state: { attribute: false }, }; } @@ -85,6 +86,9 @@ export class CopyToClipboard extends Base { `; } + /** Default icon. */ + icon: string | null = null; + /** Text to copy. */ text: string | null = null; @@ -105,12 +109,12 @@ export class CopyToClipboard extends Base { icon = 'icons:done'; } else { label = 'click_to_copy'; - icon = 'icons:content-copy'; + icon = this.icon ?? 'icons:content-copy'; } return html` + + + `; } } diff --git a/src/elements/public/CopyToClipboard/index.ts b/src/elements/public/CopyToClipboard/index.ts index 9d7327b6c..421a64063 100644 --- a/src/elements/public/CopyToClipboard/index.ts +++ b/src/elements/public/CopyToClipboard/index.ts @@ -1,3 +1,4 @@ +import '@vaadin-component-factory/vcf-tooltip'; import '@polymer/iron-icons'; import '@polymer/iron-icon'; diff --git a/src/elements/public/CouponCard/CouponCard.ts b/src/elements/public/CouponCard/CouponCard.ts index 9e938c58d..b79c35fe0 100644 --- a/src/elements/public/CouponCard/CouponCard.ts +++ b/src/elements/public/CouponCard/CouponCard.ts @@ -1,4 +1,4 @@ -import { Data, Templates } from './types'; +import { Data } from './types'; import { TemplateResult, html } from 'lit-html'; import { ConfigurableMixin } from '../../../mixins/configurable'; @@ -13,19 +13,10 @@ const Base = ThemeableMixin(ConfigurableMixin(TranslatableMixin(NucleonElement, /** * Basic card displaying a coupon. * - * @slot title:before - * @slot title:after - * @slot description:before - * @slot description:after - * @slot status:before - * @slot status:after - * * @element foxy-coupon-card * @since 1.15.0 */ export class CouponCard extends Base { - templates: Templates = {}; - render(): TemplateResult { const hiddenSelector = this.hiddenSelector; diff --git a/src/elements/public/CouponCard/types.ts b/src/elements/public/CouponCard/types.ts index b92ec1a38..43ddcb067 100644 --- a/src/elements/public/CouponCard/types.ts +++ b/src/elements/public/CouponCard/types.ts @@ -1,17 +1,4 @@ -import { CouponCard } from './CouponCard'; -import { Rels } from '@foxy.io/sdk/backend'; -import { Renderer } from '../../../mixins/configurable'; import { Resource } from '@foxy.io/sdk/core'; +import { Rels } from '@foxy.io/sdk/backend'; export type Data = Resource; - -export type Templates = Partial<{ - 'total:before': Renderer; - 'total:after': Renderer; - 'status:before': Renderer; - 'status:after': Renderer; - 'description:before': Renderer; - 'description:after': Renderer; - 'customer:before': Renderer; - 'customer:after': Renderer; -}>; diff --git a/src/elements/public/CouponCodeForm/CouponCodeForm.stories.ts b/src/elements/public/CouponCodeForm/CouponCodeForm.stories.ts index 45b147fb6..a922b7d3e 100644 --- a/src/elements/public/CouponCodeForm/CouponCodeForm.stories.ts +++ b/src/elements/public/CouponCodeForm/CouponCodeForm.stories.ts @@ -11,9 +11,9 @@ const summary: Summary = { localName: 'foxy-coupon-code-form', translatable: true, configurable: { - sections: ['timestamps'], - buttons: ['create', 'delete', 'transactions'], - inputs: ['code', 'number-of-uses-to-date'], + sections: ['timestamps', 'header'], + buttons: ['delete', 'create', 'submit', 'undo', 'header:copy-id', 'header:copy-json'], + inputs: ['code'], }, }; diff --git a/src/elements/public/CouponCodeForm/CouponCodeForm.test.ts b/src/elements/public/CouponCodeForm/CouponCodeForm.test.ts index fa2f9b80f..de2a40b0c 100644 --- a/src/elements/public/CouponCodeForm/CouponCodeForm.test.ts +++ b/src/elements/public/CouponCodeForm/CouponCodeForm.test.ts @@ -4,16 +4,13 @@ import { expect, fixture, html } from '@open-wc/testing'; import { CouponCodeForm } from './CouponCodeForm'; import { InternalForm } from '../../internal/InternalForm/InternalForm'; import { getTestData } from '../../../testgen/getTestData'; +import { stub } from 'sinon'; describe('foxy-coupon-code-form', () => { it('imports and defines foxy-internal-async-list-control', () => { expect(customElements.get('foxy-internal-async-list-control')).to.exist; }); - it('imports and defines foxy-internal-integer-control', () => { - expect(customElements.get('foxy-internal-integer-control')).to.exist; - }); - it('imports and defines foxy-internal-text-control', () => { expect(customElements.get('foxy-internal-text-control')).to.exist; }); @@ -71,21 +68,19 @@ describe('foxy-coupon-code-form', () => { expect(element.errors).to.include('code:v8n_has_spaces'); }); - it('hides transactions and number of uses when href is not set', () => { + it('hides transactions when href is not set', () => { const element = new CouponCodeForm(); expect(element.hiddenSelector.matches('transactions', true)).to.be.true; - expect(element.hiddenSelector.matches('number-of-uses-to-date', true)).to.be.true; element.href = 'https://demo.api/hapi/coupon_codes/0'; expect(element.hiddenSelector.matches('transactions', true)).to.be.false; - expect(element.hiddenSelector.matches('number-of-uses-to-date', true)).to.be.false; }); - it('always keeps number of uses to date readonly', () => { - const element = new CouponCodeForm(); - expect(element.readonlySelector.matches('number-of-uses-to-date', true)).to.be.true; - element.readonly = false; - expect(element.readonlySelector.matches('number-of-uses-to-date', true)).to.be.true; + it('renders a form header', () => { + const form = new CouponCodeForm(); + const renderHeaderMethod = stub(form, 'renderHeader'); + form.render(); + expect(renderHeaderMethod).to.have.been.called; }); it('renders a text control for code', async () => { @@ -96,16 +91,6 @@ describe('foxy-coupon-code-form', () => { expect(control).to.exist; }); - it('renders an integer control for number of uses', async () => { - const element = await fixture( - html`` - ); - const control = element.renderRoot.querySelector( - 'foxy-internal-integer-control[infer="number-of-uses-to-date"]' - ); - expect(control).to.exist; - }); - it('renders a list of transactions', async () => { const element = await fixture( html`` diff --git a/src/elements/public/CouponCodeForm/CouponCodeForm.ts b/src/elements/public/CouponCodeForm/CouponCodeForm.ts index 162fa51f0..e4e208dd6 100644 --- a/src/elements/public/CouponCodeForm/CouponCodeForm.ts +++ b/src/elements/public/CouponCodeForm/CouponCodeForm.ts @@ -1,4 +1,4 @@ -import type { Data, Templates, TransactionPageHrefGetter } from './types'; +import type { Data, TransactionPageHrefGetter } from './types'; import type { PropertyDeclarations } from 'lit-element'; import type { TemplateResult } from 'lit-html'; import type { NucleonV8N } from '../NucleonElement/types'; @@ -15,24 +15,6 @@ const Base = TranslatableMixin(InternalForm, NS); /** * Form element for creating or editing coupon codes (`fx:coupon_code`). * - * @slot code:before - * @slot code:after - * - * @slot number-of-uses-to-date:before – **new in v1.27.0** - * @slot number-of-uses-to-date:after – **new in v1.27.0** - * - * @slot transactions:before – **new in v1.27.0** - * @slot transactions:after – **new in v1.27.0** - * - * @slot timestamps:before - * @slot timestamps:after - * - * @slot delete:before - * @slot delete:after - * - * @slot create:before - * @slot create:after - * * @element foxy-coupon-code-form * @since 1.15.0 */ @@ -54,15 +36,9 @@ export class CouponCodeForm extends Base { getTransactionPageHref: TransactionPageHrefGetter | null = null; - templates: Templates = {}; - - get readonlySelector(): BooleanSelector { - return new BooleanSelector(`number-of-uses-to-date ${super.readonlySelector}`.trim()); - } - get hiddenSelector(): BooleanSelector { const alwaysMatch: string[] = [super.hiddenSelector.toString()]; - if (!this.href) alwaysMatch.unshift('transactions', 'number-of-uses-to-date'); + if (!this.href) alwaysMatch.unshift('transactions'); return new BooleanSelector(alwaysMatch.join(' ').trim()); } @@ -78,8 +54,9 @@ export class CouponCodeForm extends Base { } return html` + ${this.renderHeader()} + - string | null; export type Data = Resource; - -export type Templates = { - 'code:before'?: Renderer; - 'code:after'?: Renderer; - 'number-of-uses-to-date:before'?: Renderer; - 'number-of-uses-to-date:after'?: Renderer; - 'transactions:before'?: Renderer; - 'transactions:after'?: Renderer; - 'timestamps:before'?: Renderer; - 'timestamps:after'?: Renderer; - 'delete:before'?: Renderer; - 'delete:after'?: Renderer; - 'create:before'?: Renderer; - 'create:after'?: Renderer; -}; diff --git a/src/elements/public/CouponCodesForm/CouponCodesForm.ts b/src/elements/public/CouponCodesForm/CouponCodesForm.ts index 0206345dd..19a2c9240 100644 --- a/src/elements/public/CouponCodesForm/CouponCodesForm.ts +++ b/src/elements/public/CouponCodesForm/CouponCodesForm.ts @@ -1,4 +1,4 @@ -import type { Data, Templates } from './types'; +import type { Data } from './types'; import type { TemplateResult } from 'lit-html'; import type { NucleonV8N } from '../NucleonElement/types'; import type { Item } from '../../internal/InternalEditableListControl/types'; @@ -14,12 +14,6 @@ const Base = TranslatableMixin(InternalForm, NS); /** * Form element for importing coupon codes (`fx:coupon_codes`). * - * @slot coupon-codes:before - **new in v1.27.0** - * @slot coupon-codes:after - **new in v1.27.0** - * - * @slot create:before - **new in v1.27.0** - * @slot create:after - **new in v1.27.0** - * * @element foxy-coupon-codes-form * @since 1.15.0 */ @@ -28,8 +22,6 @@ export class CouponCodesForm extends Base { return [({ coupon_codes: v }) => (v && v.length > 0) || 'coupon-codes:v8n_required']; } - templates: Templates = {}; - private readonly __couponCodesGetValue = () => { return this.form.coupon_codes?.map(value => ({ value })) ?? []; }; diff --git a/src/elements/public/CouponCodesForm/types.ts b/src/elements/public/CouponCodesForm/types.ts index 1b4ca9a51..a44c20cc2 100644 --- a/src/elements/public/CouponCodesForm/types.ts +++ b/src/elements/public/CouponCodesForm/types.ts @@ -1,13 +1,4 @@ -import type { CouponCodesForm } from './CouponCodesForm'; -import type { Renderer } from '../../../mixins/configurable'; import type { Resource } from '@foxy.io/sdk/core'; import type { Rels } from '@foxy.io/sdk/backend'; export type Data = Resource & { _links: { self: { href: string } } }; - -export type Templates = { - 'coupon-codes:before'?: Renderer; - 'coupon-codes:after'?: Renderer; - 'create:before'?: Renderer; - 'create:after'?: Renderer; -}; diff --git a/src/elements/public/CouponDetailCard/CouponDetailCard.ts b/src/elements/public/CouponDetailCard/CouponDetailCard.ts index 4df7640e7..c13eb7219 100644 --- a/src/elements/public/CouponDetailCard/CouponDetailCard.ts +++ b/src/elements/public/CouponDetailCard/CouponDetailCard.ts @@ -12,12 +12,6 @@ const Base = TranslatableMixin(TwoLineCard, NS); /** * Basic card displaying a coupon detail. * - * @slot title:before - * @slot title:after - * - * @slot subtitle:before - * @slot subtitle:after - * * @element foxy-coupon-detail-card * @since 1.17.0 */ diff --git a/src/elements/public/CouponForm/CouponForm.stories.ts b/src/elements/public/CouponForm/CouponForm.stories.ts index d88f09d28..05e0a1222 100644 --- a/src/elements/public/CouponForm/CouponForm.stories.ts +++ b/src/elements/public/CouponForm/CouponForm.stories.ts @@ -29,8 +29,17 @@ const summary: Summary = { 'customer-attribute-restrictions', 'attributes', ], - sections: ['timestamps'], - buttons: ['import', 'generate', 'create', 'delete'], + sections: ['timestamps', 'header'], + buttons: [ + 'import', + 'generate', + 'delete', + 'create', + 'submit', + 'undo', + 'header:copy-id', + 'header:copy-json', + ], }, }; diff --git a/src/elements/public/CouponForm/CouponForm.test.ts b/src/elements/public/CouponForm/CouponForm.test.ts index 48d9b0243..8720b863e 100644 --- a/src/elements/public/CouponForm/CouponForm.test.ts +++ b/src/elements/public/CouponForm/CouponForm.test.ts @@ -286,6 +286,24 @@ describe('CouponForm', () => { expect(element.hiddenSelector.matches('customer-subscription-restrictions', true)).to.be.false; }); + it('renders a form header', () => { + const form = new CouponForm(); + const renderHeaderMethod = stub(form, 'renderHeader'); + form.render(); + expect(renderHeaderMethod).to.have.been.called; + }); + + it('renders header subtitle with custom options', async () => { + const element = await fixture(html` + + `); + + expect(element.headerSubtitleOptions).to.deep.equal({ + ...element.data, + id: element.headerCopyIdValue, + }); + }); + it('renders bulk add control for the Generate Codes header action', async () => { const element = await fixture(html` diff --git a/src/elements/public/CouponForm/CouponForm.ts b/src/elements/public/CouponForm/CouponForm.ts index a23194109..b6b4d189c 100644 --- a/src/elements/public/CouponForm/CouponForm.ts +++ b/src/elements/public/CouponForm/CouponForm.ts @@ -22,70 +22,6 @@ const Base = ResponsiveMixin(TranslatableMixin(InternalForm, NS)); /** * Form element for creating or editing coupons (`fx:coupon`). * - * @slot import:before - * @slot import:after - * - * @slot generate:before - * @slot generate:after - * - * @slot name:before - * @slot name:after - * - * @slot rules:before - * @slot rules:after - * - * @slot coupon-codes:before - * @slot coupon-codes:after - * - * @slot item-option-restrictions:before - * @slot item-option-restrictions:after - * - * @slot product-code-restrictions:before - * @slot product-code-restrictions:after - * - * @slot category-restrictions:before - * @slot category-restrictions:after - * - * @slot number-of-uses-allowed:before - * @slot number-of-uses-allowed:after - * - * @slot number-of-uses-allowed-per-customer:before - * @slot number-of-uses-allowed-per-customer:after - * - * @slot number-of-uses-allowed-per-code:before - * @slot number-of-uses-allowed-per-code:after - * - * @slot start-date:before - * @slot start-date:after - * - * @slot end-date:before - * @slot end-date:after - * - * @slot inclusive-tax-rate:before - * @slot inclusive-tax-rate:after - * - * @slot options:before - * @slot options:after - * - * @slot customer-subscription-restrictions:before - * @slot customer-subscription-restrictions:after - * - * @slot customer-attribute-restrictions:before - * @slot customer-attribute-restrictions:after - * - * @slot attributes:before - * @slot attributes:after - * - * @slot create:before - * @slot create:after - * - * @slot delete:before - * @slot delete:after - * - * @slot timestamps:before - * @slot timestamps:after - * - * * @element foxy-coupon-form * @since 1.15.0 */ @@ -283,6 +219,10 @@ export class CouponForm extends Base { return new BooleanSelector(alwaysMatch.join(' ').trim()); } + get headerSubtitleOptions(): Record { + return { ...super.headerSubtitleOptions, id: this.headerCopyIdValue }; + } + renderHeaderActions(data: Data): TemplateResult { return html` = (data: TData) => TemplateResult; -export type Templates = { - 'title:before'?: Renderer; - 'title:after'?: Renderer; - 'subtitle:before'?: Renderer; - 'subtitle:after'?: Renderer; -}; - export type RenderOptions = { title: TemplateFn; subtitle: TemplateFn; @@ -24,8 +16,6 @@ export type RenderOptions = { const Base = ResponsiveMixin(ConfigurableMixin(InternalCard)); export class TwoLineCard extends Base { - templates: Templates = {}; - private readonly __renderTitle = (content?: TemplateFn) => { return html`
diff --git a/src/elements/public/CustomFieldCard/index.ts b/src/elements/public/CustomFieldCard/index.ts index a13a806fa..1a2f23ab6 100644 --- a/src/elements/public/CustomFieldCard/index.ts +++ b/src/elements/public/CustomFieldCard/index.ts @@ -1,5 +1,5 @@ import '../../internal/InternalSandbox/index'; -import '../Spinner/index'; +import '../../internal/InternalCard/index'; import { CustomFieldCard } from './CustomFieldCard'; diff --git a/src/elements/public/CustomFieldForm/CustomFieldForm.stories.ts b/src/elements/public/CustomFieldForm/CustomFieldForm.stories.ts index d758c18b8..4b833d4a3 100644 --- a/src/elements/public/CustomFieldForm/CustomFieldForm.stories.ts +++ b/src/elements/public/CustomFieldForm/CustomFieldForm.stories.ts @@ -11,9 +11,9 @@ const summary: Summary = { localName: 'foxy-custom-field-form', translatable: true, configurable: { - sections: ['timestamps'], - buttons: ['create', 'delete', 'visibility'], - inputs: ['name', 'value'], + sections: ['timestamps', 'header'], + buttons: ['delete', 'create', 'submit', 'undo', 'header:copy-id', 'header:copy-json'], + inputs: ['name', 'value', 'visibility'], }, }; diff --git a/src/elements/public/CustomFieldForm/CustomFieldForm.test.ts b/src/elements/public/CustomFieldForm/CustomFieldForm.test.ts index 4431c535d..4f54124fc 100644 --- a/src/elements/public/CustomFieldForm/CustomFieldForm.test.ts +++ b/src/elements/public/CustomFieldForm/CustomFieldForm.test.ts @@ -4,6 +4,7 @@ import './index'; import { expect, fixture, html } from '@open-wc/testing'; import { CustomFieldForm } from './CustomFieldForm'; +import { stub } from 'sinon'; describe('CustomFieldForm', () => { it('imports and defines foxy-internal-checkbox-group-control', () => { @@ -65,6 +66,13 @@ describe('CustomFieldForm', () => { expect(element.errors).to.include('name:v8n_too_long'); }); + it('renders a form header', () => { + const form = new CustomFieldForm(); + const renderHeaderMethod = stub(form, 'renderHeader'); + form.render(); + expect(renderHeaderMethod).to.have.been.called; + }); + it('renders a source control for name', async () => { const element = await fixture( html`` diff --git a/src/elements/public/CustomFieldForm/CustomFieldForm.ts b/src/elements/public/CustomFieldForm/CustomFieldForm.ts index 7e0ebf4e3..ed08d1f22 100644 --- a/src/elements/public/CustomFieldForm/CustomFieldForm.ts +++ b/src/elements/public/CustomFieldForm/CustomFieldForm.ts @@ -1,4 +1,4 @@ -import type { Data, Templates } from './types'; +import type { Data } from './types'; import type { TemplateResult } from 'lit-html'; import type { NucleonV8N } from '../NucleonElement/types'; @@ -12,24 +12,6 @@ const Base = TranslatableMixin(InternalForm, NS); /** * Form element for creating or editing custom fields. * - * @slot name:before - **new in v1.4.0** - * @slot name:after - **new in v1.4.0** - * - * @slot value:before - **new in v1.4.0** - * @slot value:after - **new in v1.4.0** - * - * @slot visibility:before - **new in v1.4.0** - * @slot visibility:after - **new in v1.4.0** - * - * @slot timestamps:before - **new in v1.4.0** - * @slot timestamps:after - **new in v1.4.0** - * - * @slot create:before - **new in v1.4.0** - * @slot create:after - **new in v1.4.0** - * - * @slot delete:before - **new in v1.4.0** - * @slot delete:after - **new in v1.4.0** - * * @element foxy-custom-field-form * @since 1.2.0 */ @@ -43,8 +25,6 @@ export class CustomFieldForm extends Base { ]; } - templates: Templates = {}; - private readonly __visibilityGetValue = () => { return this.form.is_hidden ? ['hidden'] : []; }; @@ -57,6 +37,8 @@ export class CustomFieldForm extends Base { renderBody(): TemplateResult { return html` + ${this.renderHeader()} + ; -export type Templates = { - 'name:before'?: Renderer; - 'name:after'?: Renderer; - 'value:before'?: Renderer; - 'value:after'?: Renderer; - 'visibility:before'?: Renderer; - 'visibility:after'?: Renderer; - 'timestamps:before'?: Renderer; - 'timestamps:after'?: Renderer; - 'delete:before'?: Renderer; - 'delete:after'?: Renderer; - 'create:before'?: Renderer; - 'create:after'?: Renderer; -}; diff --git a/src/elements/public/Customer/Customer.ts b/src/elements/public/Customer/Customer.ts index 4d827a4be..ee4d3f4f5 100644 --- a/src/elements/public/Customer/Customer.ts +++ b/src/elements/public/Customer/Customer.ts @@ -1,4 +1,4 @@ -import { Attributes, CustomerAddresses, Data, Settings, Tab, Templates } from './types'; +import { Attributes, CustomerAddresses, Data, Settings, Tab } from './types'; import { CSSResultArray, TemplateResult, html, PropertyDeclarations } from 'lit-element'; import { ScopedElementsMap, ScopedElementsMixin } from '@open-wc/scoped-elements'; @@ -30,42 +30,6 @@ const Base = ScopedElementsMixin( /** * All-in-one element for customer management. * - * @slot header:before - **new in v1.4.0** - * @slot header:after - **new in v1.4.0** - * @slot header:actions:before - **new in v1.4.0** - * @slot header:actions:after - **new in v1.4.0** - * @slot header:actions:edit:before - **new in v1.4.0** - * @slot header:actions:edit:after - **new in v1.4.0** - * - * @slot addresses:before - **new in v1.4.0** - * @slot addresses:after - **new in v1.4.0** - * @slot addresses:actions:before - **new in v1.4.0** - * @slot addresses:actions:after - **new in v1.4.0** - * @slot addresses:actions:create:before - **new in v1.4.0** - * @slot addresses:actions:create:after - **new in v1.4.0** - * @slot addresses:list:before - **new in v1.4.0** - * @slot addresses:list:after - **new in v1.4.0** - * - * @slot payment-methods:before - **new in v1.4.0** - * @slot payment-methods:after - **new in v1.4.0** - * @slot payment-methods:list:before - **new in v1.4.0** - * @slot payment-methods:list:after - **new in v1.4.0** - * - * @slot attributes:before - **new in v1.4.0** - * @slot attributes:after - **new in v1.4.0** - * @slot attributes:actions:before - **new in v1.4.0** - * @slot attributes:actions:after - **new in v1.4.0** - * @slot attributes:actions:create:before - **new in v1.4.0** - * @slot attributes:actions:create:after - **new in v1.4.0** - * @slot attributes:list:before - **new in v1.4.0** - * @slot attributes:list:after - **new in v1.4.0** - * - * @slot transactions:before - **new in v1.4.0** - * @slot transactions:after - **new in v1.4.0** - * - * @slot subscriptions:before - **new in v1.4.0** - * @slot subscriptions:after - **new in v1.4.0** - * * @element foxy-customer * @since 1.2.0 */ @@ -102,8 +66,6 @@ export class Customer extends Base { return [super.styles, styles]; } - templates: Templates = {}; - /** * Configuration URL for the Payment Card Embed. If provided, this element will allow * the customer to update their default payment method using the Payment Card Embed. @@ -141,6 +103,7 @@ export class Customer extends Base { readonlycontrols=${readonlySelector.zoom(formId).toString()} disabledcontrols=${disabledSelector.zoom(formId).toString()} hiddencontrols=${hiddenSelector.zoom(formId).toString()} + alert .templates=${this.getNestedTemplates('header:actions:edit:form')} .props=${{ '.settings': this.settings }} > @@ -241,6 +204,7 @@ export class Customer extends Base { lang=${lang} ns=${ns} id="address-dialog" + alert .templates=${this.getNestedTemplates('addresses:actions:create:form')} > @@ -342,6 +306,7 @@ export class Customer extends Base { lang=${this.lang} ns=${this.ns} id="addresses-list-form" + alert .templates=${this.getNestedTemplates(formId)} > @@ -482,6 +447,7 @@ export class Customer extends Base { form="foxy-attribute-form" lang=${lang} ns=${ns} + alert .templates=${this.getNestedTemplates('attributes:actions:create:form')} > @@ -581,6 +547,7 @@ export class Customer extends Base { lang=${this.lang} ns=${this.ns} id="attributes-list-form" + alert .templates=${this.getNestedTemplates(formId)} > @@ -729,6 +696,7 @@ export class Customer extends Base { lang=${this.lang} ns=${this.ns} id="subscriptions-form" + alert .templates=${this.getNestedTemplates(formId)} .props=${{ '.settings': this.settings }} > diff --git a/src/elements/public/Customer/types.ts b/src/elements/public/Customer/types.ts index a2b9d4286..8670c18c9 100644 --- a/src/elements/public/Customer/types.ts +++ b/src/elements/public/Customer/types.ts @@ -1,185 +1,9 @@ -import { Graph, Rels } from '@foxy.io/sdk/customer'; - -import { Templates as AddressCardTemplates } from '../AddressCard/types'; -import { Templates as AddressFormTemplates } from '../AddressForm/types'; -import { Templates as AttributeCardTemplates } from '../AttributeCard/types'; -import { Templates as AttributeFormTemplates } from '../AttributeForm/types'; -import { Customer } from './Customer'; -import { Templates as CustomerFormTemplates } from '../CustomerForm/types'; -import { Templates as PaymentMethodCardTemplates } from '../PaymentMethodCard/types'; -import { Renderer } from '../../../mixins/configurable'; -import { Resource } from '@foxy.io/sdk/core'; -import { Templates as SubscriptionFormTemplates } from '../SubscriptionForm/types'; -import { Templates as SubscriptionsTableTemplates } from '../SubscriptionsTable/types'; -import { TemplateResult } from 'lit-html'; -import { Templates as TransactionsTableTemplates } from '../TransactionsTable/types'; +import type { TemplateResult } from 'lit-html'; +import type { Graph, Rels } from '@foxy.io/sdk/customer'; +import type { Resource } from '@foxy.io/sdk/core'; export type CustomerAddresses = Resource; export type Attributes = Resource; export type Settings = Resource; export type Data = Resource; export type Tab = { title: string; content: TemplateResult }; - -export type Templates = { - 'header:before'?: Renderer; - 'header:after'?: Renderer; - 'header:actions:before'?: Renderer; - 'header:actions:after'?: Renderer; - 'header:actions:edit:before'?: Renderer; - 'header:actions:edit:after'?: Renderer; - 'header:actions:edit:form:first-name:before'?: CustomerFormTemplates['first-name:before']; - 'header:actions:edit:form:first-name:after'?: CustomerFormTemplates['first-name:after']; - 'header:actions:edit:form:last-name:before'?: CustomerFormTemplates['last-name:before']; - 'header:actions:edit:form:last-name:after'?: CustomerFormTemplates['last-name:after']; - 'header:actions:edit:form:email:before'?: CustomerFormTemplates['email:before']; - 'header:actions:edit:form:email:after'?: CustomerFormTemplates['email:after']; - 'header:actions:edit:form:tax-id:before'?: CustomerFormTemplates['tax-id:before']; - 'header:actions:edit:form:tax-id:after'?: CustomerFormTemplates['tax-id:after']; - 'header:actions:edit:form:timestamps:before'?: CustomerFormTemplates['timestamps:before']; - 'header:actions:edit:form:timestamps:after'?: CustomerFormTemplates['timestamps:after']; - 'header:actions:edit:form:delete:before'?: CustomerFormTemplates['delete:before']; - 'header:actions:edit:form:delete:after'?: CustomerFormTemplates['delete:after']; - 'header:actions:edit:form:create:before'?: CustomerFormTemplates['create:before']; - 'header:actions:edit:form:create:after'?: CustomerFormTemplates['create:after']; - 'default'?: Renderer; - 'addresses:before'?: Renderer; - 'addresses:after'?: Renderer; - 'addresses:actions:before'?: Renderer; - 'addresses:actions:after'?: Renderer; - 'addresses:actions:create:before'?: Renderer; - 'addresses:actions:create:after'?: Renderer; - 'addresses:actions:create:form:address-name:before'?: AddressFormTemplates['address-name:before']; - 'addresses:actions:create:form:address-name:after'?: AddressFormTemplates['address-name:after']; - 'addresses:actions:create:form:first-name:before'?: AddressFormTemplates['first-name:before']; - 'addresses:actions:create:form:first-name:after'?: AddressFormTemplates['first-name:after']; - 'addresses:actions:create:form:last-name:before'?: AddressFormTemplates['last-name:before']; - 'addresses:actions:create:form:last-name:after'?: AddressFormTemplates['last-name:after']; - 'addresses:actions:create:form:region:before'?: AddressFormTemplates['region:before']; - 'addresses:actions:create:form:region:after'?: AddressFormTemplates['region:after']; - 'addresses:actions:create:form:city:before'?: AddressFormTemplates['city:before']; - 'addresses:actions:create:form:city:after'?: AddressFormTemplates['city:after']; - 'addresses:actions:create:form:phone:before'?: AddressFormTemplates['phone:before']; - 'addresses:actions:create:form:phone:after'?: AddressFormTemplates['phone:after']; - 'addresses:actions:create:form:company:before'?: AddressFormTemplates['company:before']; - 'addresses:actions:create:form:company:after'?: AddressFormTemplates['company:after']; - 'addresses:actions:create:form:address-one:before'?: AddressFormTemplates['address-one:before']; - 'addresses:actions:create:form:address-one:after'?: AddressFormTemplates['address-one:after']; - 'addresses:actions:create:form:address-two:before'?: AddressFormTemplates['address-two:before']; - 'addresses:actions:create:form:address-two:after'?: AddressFormTemplates['address-two:after']; - 'addresses:actions:create:form:postal-code:before'?: AddressFormTemplates['postal-code:before']; - 'addresses:actions:create:form:postal-code:after'?: AddressFormTemplates['postal-code:after']; - 'addresses:actions:create:form:timestamps:before'?: AddressFormTemplates['timestamps:before']; - 'addresses:actions:create:form:timestamps:after'?: AddressFormTemplates['timestamps:after']; - 'addresses:actions:create:form:delete:before'?: AddressFormTemplates['delete:before']; - 'addresses:actions:create:form:delete:after'?: AddressFormTemplates['delete:after']; - 'addresses:actions:create:form:create:before'?: AddressFormTemplates['create:before']; - 'addresses:actions:create:form:create:after'?: AddressFormTemplates['create:after']; - 'addresses:list:before'?: Renderer; - 'addresses:list:after'?: Renderer; - 'addresses:list:card:address-name:before'?: AddressCardTemplates['address-name:before']; - 'addresses:list:card:address-name:after'?: AddressCardTemplates['address-name:after']; - 'addresses:list:card:full-name:before'?: AddressCardTemplates['full-name:before']; - 'addresses:list:card:full-name:after'?: AddressCardTemplates['full-name:after']; - 'addresses:list:card:full-address:before'?: AddressCardTemplates['full-address:before']; - 'addresses:list:card:full-address:after'?: AddressCardTemplates['full-address:after']; - 'addresses:list:card:company:before'?: AddressCardTemplates['company:before']; - 'addresses:list:card:company:after'?: AddressCardTemplates['company:after']; - 'addresses:list:card:phone:before'?: AddressCardTemplates['phone:before']; - 'addresses:list:card:phone:after'?: AddressCardTemplates['phone:after']; - 'addresses:list:form:address-name:before'?: AddressFormTemplates['address-name:before']; - 'addresses:list:form:address-name:after'?: AddressFormTemplates['address-name:after']; - 'addresses:list:form:first-name:before'?: AddressFormTemplates['first-name:before']; - 'addresses:list:form:first-name:after'?: AddressFormTemplates['first-name:after']; - 'addresses:list:form:last-name:before'?: AddressFormTemplates['last-name:before']; - 'addresses:list:form:last-name:after'?: AddressFormTemplates['last-name:after']; - 'addresses:list:form:region:before'?: AddressFormTemplates['region:before']; - 'addresses:list:form:region:after'?: AddressFormTemplates['region:after']; - 'addresses:list:form:city:before'?: AddressFormTemplates['city:before']; - 'addresses:list:form:city:after'?: AddressFormTemplates['city:after']; - 'addresses:list:form:phone:before'?: AddressFormTemplates['phone:before']; - 'addresses:list:form:phone:after'?: AddressFormTemplates['phone:after']; - 'addresses:list:form:company:before'?: AddressFormTemplates['company:before']; - 'addresses:list:form:company:after'?: AddressFormTemplates['company:after']; - 'addresses:list:form:address-one:before'?: AddressFormTemplates['address-one:before']; - 'addresses:list:form:address-one:after'?: AddressFormTemplates['address-one:after']; - 'addresses:list:form:address-two:before'?: AddressFormTemplates['address-two:before']; - 'addresses:list:form:address-two:after'?: AddressFormTemplates['address-two:after']; - 'addresses:list:form:postal-code:before'?: AddressFormTemplates['postal-code:before']; - 'addresses:list:form:postal-code:after'?: AddressFormTemplates['postal-code:after']; - 'addresses:list:form:timestamps:before'?: AddressFormTemplates['timestamps:before']; - 'addresses:list:form:timestamps:after'?: AddressFormTemplates['timestamps:after']; - 'addresses:list:form:delete:before'?: AddressFormTemplates['delete:before']; - 'addresses:list:form:delete:after'?: AddressFormTemplates['delete:after']; - 'addresses:list:form:create:before'?: AddressFormTemplates['create:before']; - 'addresses:list:form:create:after'?: AddressFormTemplates['create:after']; - 'payment-methods:before'?: Renderer; - 'payment-methods:after'?: Renderer; - 'payment-methods:list:before'?: Renderer; - 'payment-methods:list:after'?: Renderer; - 'payment-methods:list:card:actions:before'?: PaymentMethodCardTemplates['actions:before']; - 'payment-methods:list:card:actions:after'?: PaymentMethodCardTemplates['actions:after']; - 'payment-methods:list:card:actions:delete:before'?: PaymentMethodCardTemplates['actions:delete:before']; - 'payment-methods:list:card:actions:delete:after'?: PaymentMethodCardTemplates['actions:delete:after']; - 'attributes:before'?: Renderer; - 'attributes:after'?: Renderer; - 'attributes:actions:before'?: Renderer; - 'attributes:actions:after'?: Renderer; - 'attributes:actions:create:before'?: Renderer; - 'attributes:actions:create:after'?: Renderer; - 'attributes:actions:create:form:name:before'?: AttributeFormTemplates['name:before']; - 'attributes:actions:create:form:name:after'?: AttributeFormTemplates['name:after']; - 'attributes:actions:create:form:value:before'?: AttributeFormTemplates['value:before']; - 'attributes:actions:create:form:value:after'?: AttributeFormTemplates['value:after']; - 'attributes:actions:create:form:visibility:before'?: AttributeFormTemplates['visibility:before']; - 'attributes:actions:create:form:visibility:after'?: AttributeFormTemplates['visibility:after']; - 'attributes:actions:create:form:timestamps:before'?: AttributeFormTemplates['timestamps:before']; - 'attributes:actions:create:form:timestamps:after'?: AttributeFormTemplates['timestamps:after']; - 'attributes:actions:create:form:delete:before'?: AttributeFormTemplates['delete:before']; - 'attributes:actions:create:form:delete:after'?: AttributeFormTemplates['delete:after']; - 'attributes:actions:create:form:create:before'?: AttributeFormTemplates['create:before']; - 'attributes:actions:create:form:create:after'?: AttributeFormTemplates['create:after']; - 'attributes:list:before'?: Renderer; - 'attributes:list:after'?: Renderer; - 'attributes:list:card:name:before'?: AttributeCardTemplates['name:before']; - 'attributes:list:card:name:after'?: AttributeCardTemplates['name:after']; - 'attributes:list:card:value:before'?: AttributeCardTemplates['value:before']; - 'attributes:list:card:value:after'?: AttributeCardTemplates['value:after']; - 'attributes:list:form:name:before'?: AttributeFormTemplates['name:before']; - 'attributes:list:form:name:after'?: AttributeFormTemplates['name:after']; - 'attributes:list:form:value:before'?: AttributeFormTemplates['value:before']; - 'attributes:list:form:value:after'?: AttributeFormTemplates['value:after']; - 'attributes:list:form:visibility:before'?: AttributeFormTemplates['visibility:before']; - 'attributes:list:form:visibility:after'?: AttributeFormTemplates['visibility:after']; - 'attributes:list:form:timestamps:before'?: AttributeFormTemplates['timestamps:before']; - 'attributes:list:form:timestamps:after'?: AttributeFormTemplates['timestamps:after']; - 'attributes:list:form:delete:before'?: AttributeFormTemplates['delete:before']; - 'attributes:list:form:delete:after'?: AttributeFormTemplates['delete:after']; - 'attributes:list:form:create:before'?: AttributeFormTemplates['create:before']; - 'attributes:list:form:create:after'?: AttributeFormTemplates['create:after']; - 'transactions:before'?: Renderer; - 'transactions:after'?: Renderer; - 'transactions:table:default'?: Renderer; - 'subscriptions:before'?: Renderer; - 'subscriptions:after'?: Renderer; - 'subscriptions:form:header:before'?: SubscriptionFormTemplates['header:before']; - 'subscriptions:form:header:after'?: SubscriptionFormTemplates['header:after']; - 'subscriptions:form:items:before'?: SubscriptionFormTemplates['items:before']; - 'subscriptions:form:items:after'?: SubscriptionFormTemplates['items:after']; - 'subscriptions:form:items:actions:before'?: SubscriptionFormTemplates['items:actions:before']; - 'subscriptions:form:items:actions:after'?: SubscriptionFormTemplates['items:actions:after']; - 'subscriptions:form:end-date:before'?: SubscriptionFormTemplates['end-date:before']; - 'subscriptions:form:end-date:after'?: SubscriptionFormTemplates['end-date:after']; - 'subscriptions:form:end-date:form:warning:before'?: SubscriptionFormTemplates['end-date:form:warning:before']; - 'subscriptions:form:end-date:form:warning:after'?: SubscriptionFormTemplates['end-date:form:warning:after']; - 'subscriptions:form:end-date:form:end-date:before'?: SubscriptionFormTemplates['end-date:form:end-date:before']; - 'subscriptions:form:end-date:form:end-date:after'?: SubscriptionFormTemplates['end-date:form:end-date:after']; - 'subscriptions:form:end-date:form:submit:before'?: SubscriptionFormTemplates['end-date:form:submit:before']; - 'subscriptions:form:end-date:form:submit:after'?: SubscriptionFormTemplates['end-date:form:submit:after']; - 'subscriptions:form:next-transaction-date:before'?: SubscriptionFormTemplates['next-transaction-date:before']; - 'subscriptions:form:next-transaction-date:after'?: SubscriptionFormTemplates['next-transaction-date:after']; - 'subscriptions:form:frequency:before'?: SubscriptionFormTemplates['frequency:before']; - 'subscriptions:form:frequency:after'?: SubscriptionFormTemplates['frequency:after']; - 'subscriptions:form:transactions:before'?: SubscriptionFormTemplates['transactions:before']; - 'subscriptions:form:transactions:after'?: SubscriptionFormTemplates['transactions:after']; - 'subscriptions:table:default'?: Renderer; -}; diff --git a/src/elements/public/CustomerCard/CustomerCard.ts b/src/elements/public/CustomerCard/CustomerCard.ts index 14e810183..c56b36eba 100644 --- a/src/elements/public/CustomerCard/CustomerCard.ts +++ b/src/elements/public/CustomerCard/CustomerCard.ts @@ -1,4 +1,4 @@ -import { Data, Templates } from './types'; +import { Data } from './types'; import { TemplateResult, html } from 'lit-html'; import { ConfigurableMixin } from '../../../mixins/configurable'; @@ -13,17 +13,10 @@ const Base = ThemeableMixin(ConfigurableMixin(TranslatableMixin(NucleonElement, /** * Basic card displaying a customer record. * - * @slot name:before - * @slot name:after - * @slot email:before - * @slot email:after - * * @element foxy-customer-card * @since 1.12.0 */ class CustomerCard extends Base { - templates: Templates = {}; - render(): TemplateResult { const hiddenSelector = this.hiddenSelector; diff --git a/src/elements/public/CustomerCard/types.ts b/src/elements/public/CustomerCard/types.ts index ea0f5bba5..a69e2b667 100644 --- a/src/elements/public/CustomerCard/types.ts +++ b/src/elements/public/CustomerCard/types.ts @@ -1,13 +1,4 @@ -import { CustomerCard } from './CustomerCard'; -import { Rels } from '@foxy.io/sdk/backend'; -import { Renderer } from '../../../mixins/configurable'; -import { Resource } from '@foxy.io/sdk/core'; +import type { Resource } from '@foxy.io/sdk/core'; +import type { Rels } from '@foxy.io/sdk/backend'; export type Data = Resource; - -export type Templates = Partial<{ - 'name:before': Renderer; - 'name:after': Renderer; - 'email:before': Renderer; - 'email:after': Renderer; -}>; diff --git a/src/elements/public/CustomerForm/CustomerForm.stories.ts b/src/elements/public/CustomerForm/CustomerForm.stories.ts index fe7c97f2e..1705f792f 100644 --- a/src/elements/public/CustomerForm/CustomerForm.stories.ts +++ b/src/elements/public/CustomerForm/CustomerForm.stories.ts @@ -11,8 +11,8 @@ const summary: Summary = { localName: 'foxy-customer-form', translatable: true, configurable: { - sections: ['legal-notice', 'timestamps'], - buttons: ['delete', 'create'], + sections: ['legal-notice', 'timestamps', 'header'], + buttons: ['delete', 'create', 'submit', 'undo', 'header:copy-id', 'header:copy-json'], inputs: [ 'first-name', 'last-name', diff --git a/src/elements/public/CustomerForm/CustomerForm.test.ts b/src/elements/public/CustomerForm/CustomerForm.test.ts index 94c6e3320..c81da8d60 100644 --- a/src/elements/public/CustomerForm/CustomerForm.test.ts +++ b/src/elements/public/CustomerForm/CustomerForm.test.ts @@ -213,6 +213,40 @@ describe('CustomerForm', () => { expect(form.errors).to.not.include('email:v8n_invalid_email'); }); + it('renders a form header', () => { + const form = new CustomerForm(); + const renderHeaderMethod = stub(form, 'renderHeader'); + form.render(); + expect(renderHeaderMethod).to.have.been.called; + }); + + it('uses custom form header title options', async () => { + const form = await fixture(html``); + const data = await getTestData('./hapi/customers/0'); + expect(form.headerTitleOptions).to.have.property('context', 'new'); + + form.data = { ...data, first_name: 'Foo', last_name: 'Bar' }; + expect(form.headerTitleOptions).to.have.property('context', 'existing'); + + form.data = { ...data, first_name: '', last_name: '' }; + expect(form.headerTitleOptions).to.have.property('context', 'no_name'); + }); + + it('uses custom form header subtitle key', async () => { + const form = await fixture(html``); + const data = await getTestData('./hapi/customers/0'); + form.data = { ...data, is_anonymous: false }; + expect(form.headerSubtitleKey).to.equal('subtitle_registered'); + + form.data = { ...data, is_anonymous: true }; + expect(form.headerSubtitleKey).to.equal('subtitle_anonymous'); + }); + + it('uses custom form header subtitle options', async () => { + const form = await fixture(html``); + expect(form.headerSubtitleOptions).to.deep.equal({ id: form.headerCopyIdValue }); + }); + it('renders a text field for first name', async () => { const form = await fixture(html``); const control = form.renderRoot.querySelector('[infer="first-name"]'); diff --git a/src/elements/public/CustomerForm/CustomerForm.ts b/src/elements/public/CustomerForm/CustomerForm.ts index 3e3c99041..1fd9ca2ee 100644 --- a/src/elements/public/CustomerForm/CustomerForm.ts +++ b/src/elements/public/CustomerForm/CustomerForm.ts @@ -1,5 +1,5 @@ import type { VanillaHCaptchaWebComponent } from 'vanilla-hcaptcha'; -import type { Data, Templates, Settings } from './types'; +import type { Data, Settings } from './types'; import type { PropertyDeclarations } from 'lit-element'; import type { ScopedElementsMap } from '@open-wc/scoped-elements'; import type { TemplateResult } from 'lit-html'; @@ -22,42 +22,6 @@ const passwordStrength = checkPasswordStrength.passwordStrength; /** * Form element for creating or editing customers. * - * @slot first-name:before - **new in v1.4.0** - * @slot first-name:after - **new in v1.4.0** - * - * @slot last-name:before - **new in v1.4.0** - * @slot last-name:after - **new in v1.4.0** - * - * @slot email:before - **new in v1.4.0** - * @slot email:after - **new in v1.4.0** - * - * @slot tax-id:before - **new in v1.4.0** - * @slot tax-id:after - **new in v1.4.0** - * - * @slot is-anonymous:before - **new in v1.24.0** - * @slot is-anonymous:after - **new in v1.24.0** - * - * @slot password:before - **new in v1.24.0** - * @slot password:after - **new in v1.24.0** - * - * @slot password-old:before - **new in v1.24.0** - * @slot password-old:after - **new in v1.24.0** - * - * @slot forgot-password:before - **new in v1.24.0** - * @slot forgot-password:after - **new in v1.24.0** - * - * @slot legal-notice:before - **new in v1.24.0** - * @slot legal-notice:after - **new in v1.24.0** - * - * @slot timestamps:before - **new in v1.4.0** - * @slot timestamps:after - **new in v1.4.0** - * - * @slot create:before - **new in v1.4.0** - * @slot create:after - **new in v1.4.0** - * - * @slot delete:before - **new in v1.4.0** - * @slot delete:after - **new in v1.4.0** - * * @element foxy-customer-form * @since 1.2.0 */ @@ -70,10 +34,13 @@ export class CustomerForm extends Base { 'foxy-internal-radio-group-control': customElements.get('foxy-internal-radio-group-control'), 'foxy-internal-timestamps-control': customElements.get('foxy-internal-timestamps-control'), 'foxy-internal-password-control': customElements.get('foxy-internal-password-control'), - 'foxy-internal-create-control': customElements.get('foxy-internal-create-control'), + 'foxy-internal-submit-control': customElements.get('foxy-internal-submit-control'), 'foxy-internal-delete-control': customElements.get('foxy-internal-delete-control'), 'foxy-internal-text-control': customElements.get('foxy-internal-text-control'), + 'foxy-internal-undo-control': customElements.get('foxy-internal-undo-control'), + 'foxy-copy-to-clipboard': customElements.get('foxy-copy-to-clipboard'), 'foxy-spinner': customElements.get('foxy-spinner'), + 'vcf-tooltip': customElements.get('vcf-tooltip'), 'foxy-i18n': customElements.get('foxy-i18n'), 'h-captcha': customElements.get('h-captcha'), 'vaadin-button': customElements.get('vaadin-button'), @@ -113,8 +80,6 @@ export class CustomerForm extends Base { /** If true, won't require password when creating a customer. */ passwordless = false; - templates: Templates = {}; - /** Full `fx:customer_portal_settings` resource from Customer API. If present, switches this element into the Customer API mode, enabling client verification. */ settings: Settings | null = null; @@ -162,6 +127,20 @@ export class CustomerForm extends Base { return new BooleanSelector(Array.from(hidden).join(' ').trim()); } + get headerTitleOptions(): Record { + const data = this.data; + if (!data || data.first_name.trim() || data.last_name.trim()) return super.headerTitleOptions; + return { ...super.headerTitleOptions, context: 'no_name' }; + } + + get headerSubtitleKey(): string { + return this.data?.is_anonymous ? 'subtitle_anonymous' : 'subtitle_registered'; + } + + get headerSubtitleOptions(): Record { + return { ...super.headerSubtitleOptions, id: this.headerCopyIdValue }; + } + disconnectedCallback(): void { super.disconnectedCallback(); const interval = this.__refreshInterval; @@ -179,6 +158,8 @@ export class CustomerForm extends Base { const isLastNameHidden = this.hiddenSelector.matches('last-name', true); return html` + ${this.renderHeader()} +
; @@ -21,38 +19,3 @@ export type Rel = BackendRels.Customer & { }; export type Data = Resource; - -export type Templates = { - 'first-name:before'?: Renderer; - 'first-name:after'?: Renderer; - - 'last-name:before'?: Renderer; - 'last-name:after'?: Renderer; - - 'email:before'?: Renderer; - 'email:after'?: Renderer; - - 'tax-id:before'?: Renderer; - 'tax-id:after'?: Renderer; - - 'is-anonymous:before'?: Renderer; - 'is-anonymous:after'?: Renderer; - - 'password:before'?: Renderer; - 'password:after'?: Renderer; - - 'password-old:before'?: Renderer; - 'password-old:after'?: Renderer; - - 'forgot-password:before'?: Renderer; - 'forgot-password:after'?: Renderer; - - 'timestamps:before'?: Renderer; - 'timestamps:after'?: Renderer; - - 'delete:before'?: Renderer; - 'delete:after'?: Renderer; - - 'create:before'?: Renderer; - 'create:after'?: Renderer; -}; diff --git a/src/elements/public/CustomerPortal/InternalCustomerPortalLoggedInView.test.ts b/src/elements/public/CustomerPortal/InternalCustomerPortalLoggedInView.test.ts index 2cc974ba7..ed251ece2 100644 --- a/src/elements/public/CustomerPortal/InternalCustomerPortalLoggedInView.test.ts +++ b/src/elements/public/CustomerPortal/InternalCustomerPortalLoggedInView.test.ts @@ -61,7 +61,10 @@ describe('InternalCustomerPortalLoggedInViewTest', () => { 'transactions', 'subscriptions', 'addresses:actions:create', + 'addresses:list:form:header', + 'addresses:list:form:ignore-address-restrictions', 'payment-methods:list:card:actions:update:form:template-set', + 'header:actions:edit:form:header', 'header:actions:edit:form:is-anonymous', 'header:actions:edit:form:forgot-password', 'header:actions:edit:form:create', diff --git a/src/elements/public/CustomerPortal/InternalCustomerPortalLoggedInView.ts b/src/elements/public/CustomerPortal/InternalCustomerPortalLoggedInView.ts index 72a17cedd..674f104e6 100644 --- a/src/elements/public/CustomerPortal/InternalCustomerPortalLoggedInView.ts +++ b/src/elements/public/CustomerPortal/InternalCustomerPortalLoggedInView.ts @@ -1,7 +1,5 @@ import type { PropertyDeclarations, TemplateResult } from 'lit-element'; import type { TransactionsTable } from '../TransactionsTable/TransactionsTable'; -import type { Templates as CustomerTemplates } from '../Customer/types'; -import type { Templates } from './types'; import type { Renderer } from '../../../mixins/configurable'; import type { Customer } from '../Customer/Customer'; import type { Resource } from '@foxy.io/sdk/core'; @@ -29,8 +27,6 @@ export class InternalCustomerPortalLoggedInView extends Base { }; } - templates: Templates = {}; - customer = ''; embedUrl: string | null = null; @@ -161,7 +157,10 @@ export class InternalCustomerPortalLoggedInView extends Base { 'transactions', 'subscriptions', 'addresses:actions:create', + 'addresses:list:form:header', + 'addresses:list:form:ignore-address-restrictions', 'payment-methods:list:card:actions:update:form:template-set', + 'header:actions:edit:form:header', 'header:actions:edit:form:is-anonymous', 'header:actions:edit:form:forgot-password', 'header:actions:edit:form:create', @@ -170,7 +169,7 @@ export class InternalCustomerPortalLoggedInView extends Base { ].join(' ') ).toString(); - const templates: CustomerTemplates = this.getNestedTemplates('customer'); + const templates = this.getNestedTemplates('customer'); const originalHeaderActionsAfterTemplate = templates['header:actions:after']; const originalDefaultTemplate = templates['default']; diff --git a/src/elements/public/CustomerPortal/types.ts b/src/elements/public/CustomerPortal/types.ts deleted file mode 100644 index b229f600b..000000000 --- a/src/elements/public/CustomerPortal/types.ts +++ /dev/null @@ -1,201 +0,0 @@ -import { Templates as AccessRecoveryFormTemplates } from '../AccessRecoveryForm/types'; -import { Customer } from '../Customer/Customer'; -import { CustomerPortal } from '.'; -import { Templates as CustomerTemplates } from '../Customer/types'; -import { Renderer } from '../../../mixins/configurable'; -import { Templates as SignInFormTemplates } from '../SignInForm/types'; -import { Templates as SubscriptionCardTemplates } from '../SubscriptionCard/types'; - -export type Templates = { - 'sign-in:before'?: Renderer; - 'sign-in:after'?: Renderer; - 'sign-in:header:before'?: Renderer; - 'sign-in:header:after'?: Renderer; - 'sign-in:form:email:before'?: SignInFormTemplates['email:before']; - 'sign-in:form:email:after'?: SignInFormTemplates['email:after']; - 'sign-in:form:password:before'?: SignInFormTemplates['password:before']; - 'sign-in:form:password:after'?: SignInFormTemplates['password:after']; - 'sign-in:form:error:before'?: SignInFormTemplates['error:before']; - 'sign-in:form:error:after'?: SignInFormTemplates['error:after']; - 'sign-in:form:submit:before'?: SignInFormTemplates['submit:before']; - 'sign-in:form:submit:after'?: SignInFormTemplates['submit:after']; - 'sign-in:recover:before'?: Renderer; - 'sign-in:recover:after'?: Renderer; - - 'access-recovery:before'?: Renderer; - 'access-recovery:after'?: Renderer; - 'access-recovery:header:before'?: Renderer; - 'access-recovery:header:after'?: Renderer; - 'access-recovery:form:email:before'?: AccessRecoveryFormTemplates['email:before']; - 'access-recovery:form:email:after'?: AccessRecoveryFormTemplates['email:after']; - 'access-recovery:form:message:before'?: AccessRecoveryFormTemplates['message:before']; - 'access-recovery:form:message:after'?: AccessRecoveryFormTemplates['message:after']; - 'access-recovery:form:submit:before'?: AccessRecoveryFormTemplates['submit:before']; - 'access-recovery:form:submit:after'?: AccessRecoveryFormTemplates['submit:after']; - 'access-recovery:back:before'?: Renderer; - 'access-recovery:back:after'?: Renderer; - - 'customer:header:before'?: CustomerTemplates['header:before']; - 'customer:header:after'?: CustomerTemplates['header:after']; - 'customer:header:actions:before'?: CustomerTemplates['header:actions:before']; - 'customer:header:actions:after'?: CustomerTemplates['header:actions:after']; - 'customer:header:actions:edit:before'?: CustomerTemplates['header:actions:edit:before']; - 'customer:header:actions:edit:after'?: CustomerTemplates['header:actions:edit:after']; - 'customer:header:actions:edit:form:first-name:before'?: CustomerTemplates['header:actions:edit:form:first-name:before']; - 'customer:header:actions:edit:form:first-name:after'?: CustomerTemplates['header:actions:edit:form:first-name:after']; - 'customer:header:actions:edit:form:last-name:before'?: CustomerTemplates['header:actions:edit:form:last-name:before']; - 'customer:header:actions:edit:form:last-name:after'?: CustomerTemplates['header:actions:edit:form:last-name:after']; - 'customer:header:actions:edit:form:email:before'?: CustomerTemplates['header:actions:edit:form:email:before']; - 'customer:header:actions:edit:form:email:after'?: CustomerTemplates['header:actions:edit:form:email:after']; - 'customer:header:actions:edit:form:tax-id:before'?: CustomerTemplates['header:actions:edit:form:tax-id:before']; - 'customer:header:actions:edit:form:tax-id:after'?: CustomerTemplates['header:actions:edit:form:tax-id:after']; - 'customer:header:actions:edit:form:timestamps:before'?: CustomerTemplates['header:actions:edit:form:timestamps:before']; - 'customer:header:actions:edit:form:timestamps:after'?: CustomerTemplates['header:actions:edit:form:timestamps:after']; - 'customer:header:actions:edit:form:delete:before'?: CustomerTemplates['header:actions:edit:form:delete:before']; - 'customer:header:actions:edit:form:delete:after'?: CustomerTemplates['header:actions:edit:form:delete:after']; - 'customer:header:actions:edit:form:create:before'?: CustomerTemplates['header:actions:edit:form:create:before']; - 'customer:header:actions:edit:form:create:after'?: CustomerTemplates['header:actions:edit:form:create:after']; - 'customer:header:actions:edit:form:change-password:before'?: Renderer; - 'customer:header:actions:edit:form:change-password:after'?: Renderer; - 'customer:default'?: CustomerTemplates['default']; - 'customer:addresses:before'?: CustomerTemplates['addresses:before']; - 'customer:addresses:after'?: CustomerTemplates['addresses:after']; - 'customer:addresses:actions:before'?: CustomerTemplates['addresses:actions:before']; - 'customer:addresses:actions:after'?: CustomerTemplates['addresses:actions:after']; - 'customer:addresses:actions:create:before'?: CustomerTemplates['addresses:actions:create:before']; - 'customer:addresses:actions:create:after'?: CustomerTemplates['addresses:actions:create:after']; - 'customer:addresses:actions:create:form:address-name:before'?: CustomerTemplates['addresses:actions:create:form:address-name:before']; - 'customer:addresses:actions:create:form:address-name:after'?: CustomerTemplates['addresses:actions:create:form:address-name:after']; - 'customer:addresses:actions:create:form:first-name:before'?: CustomerTemplates['addresses:actions:create:form:first-name:before']; - 'customer:addresses:actions:create:form:first-name:after'?: CustomerTemplates['addresses:actions:create:form:first-name:after']; - 'customer:addresses:actions:create:form:last-name:before'?: CustomerTemplates['addresses:actions:create:form:last-name:before']; - 'customer:addresses:actions:create:form:last-name:after'?: CustomerTemplates['addresses:actions:create:form:last-name:after']; - 'customer:addresses:actions:create:form:region:before'?: CustomerTemplates['addresses:actions:create:form:region:before']; - 'customer:addresses:actions:create:form:region:after'?: CustomerTemplates['addresses:actions:create:form:region:after']; - 'customer:addresses:actions:create:form:city:before'?: CustomerTemplates['addresses:actions:create:form:city:before']; - 'customer:addresses:actions:create:form:city:after'?: CustomerTemplates['addresses:actions:create:form:city:after']; - 'customer:addresses:actions:create:form:phone:before'?: CustomerTemplates['addresses:actions:create:form:phone:before']; - 'customer:addresses:actions:create:form:phone:after'?: CustomerTemplates['addresses:actions:create:form:phone:after']; - 'customer:addresses:actions:create:form:company:before'?: CustomerTemplates['addresses:actions:create:form:company:before']; - 'customer:addresses:actions:create:form:company:after'?: CustomerTemplates['addresses:actions:create:form:company:after']; - 'customer:addresses:actions:create:form:address-one:before'?: CustomerTemplates['addresses:actions:create:form:address-one:before']; - 'customer:addresses:actions:create:form:address-one:after'?: CustomerTemplates['addresses:actions:create:form:address-one:after']; - 'customer:addresses:actions:create:form:address-two:before'?: CustomerTemplates['addresses:actions:create:form:address-two:before']; - 'customer:addresses:actions:create:form:address-two:after'?: CustomerTemplates['addresses:actions:create:form:address-two:after']; - 'customer:addresses:actions:create:form:postal-code:before'?: CustomerTemplates['addresses:actions:create:form:postal-code:before']; - 'customer:addresses:actions:create:form:postal-code:after'?: CustomerTemplates['addresses:actions:create:form:postal-code:after']; - 'customer:addresses:actions:create:form:timestamps:before'?: CustomerTemplates['addresses:actions:create:form:timestamps:before']; - 'customer:addresses:actions:create:form:timestamps:after'?: CustomerTemplates['addresses:actions:create:form:timestamps:after']; - 'customer:addresses:actions:create:form:delete:before'?: CustomerTemplates['addresses:actions:create:form:delete:before']; - 'customer:addresses:actions:create:form:delete:after'?: CustomerTemplates['addresses:actions:create:form:delete:after']; - 'customer:addresses:actions:create:form:create:before'?: CustomerTemplates['addresses:actions:create:form:create:before']; - 'customer:addresses:actions:create:form:create:after'?: CustomerTemplates['addresses:actions:create:form:create:after']; - 'customer:addresses:list:before'?: CustomerTemplates['addresses:list:before']; - 'customer:addresses:list:after'?: CustomerTemplates['addresses:list:after']; - 'customer:addresses:list:card:address-name:before'?: CustomerTemplates['addresses:list:card:address-name:before']; - 'customer:addresses:list:card:address-name:after'?: CustomerTemplates['addresses:list:card:address-name:after']; - 'customer:addresses:list:card:full-name:before'?: CustomerTemplates['addresses:list:card:full-name:before']; - 'customer:addresses:list:card:full-name:after'?: CustomerTemplates['addresses:list:card:full-name:after']; - 'customer:addresses:list:card:full-address:before'?: CustomerTemplates['addresses:list:card:full-address:before']; - 'customer:addresses:list:card:full-address:after'?: CustomerTemplates['addresses:list:card:full-address:after']; - 'customer:addresses:list:card:company:before'?: CustomerTemplates['addresses:list:card:company:before']; - 'customer:addresses:list:card:company:after'?: CustomerTemplates['addresses:list:card:company:after']; - 'customer:addresses:list:card:phone:before'?: CustomerTemplates['addresses:list:card:phone:before']; - 'customer:addresses:list:card:phone:after'?: CustomerTemplates['addresses:list:card:phone:after']; - 'customer:addresses:list:form:address-name:before'?: CustomerTemplates['addresses:list:form:address-name:before']; - 'customer:addresses:list:form:address-name:after'?: CustomerTemplates['addresses:list:form:address-name:after']; - 'customer:addresses:list:form:first-name:before'?: CustomerTemplates['addresses:list:form:first-name:before']; - 'customer:addresses:list:form:first-name:after'?: CustomerTemplates['addresses:list:form:first-name:after']; - 'customer:addresses:list:form:last-name:before'?: CustomerTemplates['addresses:list:form:last-name:before']; - 'customer:addresses:list:form:last-name:after'?: CustomerTemplates['addresses:list:form:last-name:after']; - 'customer:addresses:list:form:region:before'?: CustomerTemplates['addresses:list:form:region:before']; - 'customer:addresses:list:form:region:after'?: CustomerTemplates['addresses:list:form:region:after']; - 'customer:addresses:list:form:city:before'?: CustomerTemplates['addresses:list:form:city:before']; - 'customer:addresses:list:form:city:after'?: CustomerTemplates['addresses:list:form:city:after']; - 'customer:addresses:list:form:phone:before'?: CustomerTemplates['addresses:list:form:phone:before']; - 'customer:addresses:list:form:phone:after'?: CustomerTemplates['addresses:list:form:phone:after']; - 'customer:addresses:list:form:company:before'?: CustomerTemplates['addresses:list:form:company:before']; - 'customer:addresses:list:form:company:after'?: CustomerTemplates['addresses:list:form:company:after']; - 'customer:addresses:list:form:address-one:before'?: CustomerTemplates['addresses:list:form:address-one:before']; - 'customer:addresses:list:form:address-one:after'?: CustomerTemplates['addresses:list:form:address-one:after']; - 'customer:addresses:list:form:address-two:before'?: CustomerTemplates['addresses:list:form:address-two:before']; - 'customer:addresses:list:form:address-two:after'?: CustomerTemplates['addresses:list:form:address-two:after']; - 'customer:addresses:list:form:postal-code:before'?: CustomerTemplates['addresses:list:form:postal-code:before']; - 'customer:addresses:list:form:postal-code:after'?: CustomerTemplates['addresses:list:form:postal-code:after']; - 'customer:addresses:list:form:timestamps:before'?: CustomerTemplates['addresses:list:form:timestamps:before']; - 'customer:addresses:list:form:timestamps:after'?: CustomerTemplates['addresses:list:form:timestamps:after']; - 'customer:addresses:list:form:delete:before'?: CustomerTemplates['addresses:list:form:delete:before']; - 'customer:addresses:list:form:delete:after'?: CustomerTemplates['addresses:list:form:delete:after']; - 'customer:addresses:list:form:create:before'?: CustomerTemplates['addresses:list:form:create:before']; - 'customer:addresses:list:form:create:after'?: CustomerTemplates['addresses:list:form:create:after']; - 'customer:payment-methods:before'?: CustomerTemplates['payment-methods:before']; - 'customer:payment-methods:after'?: CustomerTemplates['payment-methods:after']; - 'customer:payment-methods:list:before'?: CustomerTemplates['payment-methods:list:before']; - 'customer:payment-methods:list:after'?: CustomerTemplates['payment-methods:list:after']; - 'customer:payment-methods:list:card:actions:before'?: CustomerTemplates['payment-methods:list:card:actions:before']; - 'customer:payment-methods:list:card:actions:after'?: CustomerTemplates['payment-methods:list:card:actions:after']; - 'customer:payment-methods:list:card:actions:delete:before'?: CustomerTemplates['payment-methods:list:card:actions:delete:before']; - 'customer:payment-methods:list:card:actions:delete:after'?: CustomerTemplates['payment-methods:list:card:actions:delete:after']; - 'customer:attributes:before'?: CustomerTemplates['attributes:before']; - 'customer:attributes:after'?: CustomerTemplates['attributes:after']; - 'customer:attributes:actions:before'?: CustomerTemplates['attributes:actions:before']; - 'customer:attributes:actions:after'?: CustomerTemplates['attributes:actions:after']; - 'customer:attributes:actions:create:before'?: CustomerTemplates['attributes:actions:create:before']; - 'customer:attributes:actions:create:after'?: CustomerTemplates['attributes:actions:create:after']; - 'customer:attributes:actions:create:form:name:before'?: CustomerTemplates['attributes:actions:create:form:name:before']; - 'customer:attributes:actions:create:form:name:after'?: CustomerTemplates['attributes:actions:create:form:name:after']; - 'customer:attributes:actions:create:form:value:before'?: CustomerTemplates['attributes:actions:create:form:value:before']; - 'customer:attributes:actions:create:form:value:after'?: CustomerTemplates['attributes:actions:create:form:value:after']; - 'customer:attributes:actions:create:form:visibility:before'?: CustomerTemplates['attributes:actions:create:form:visibility:before']; - 'customer:attributes:actions:create:form:visibility:after'?: CustomerTemplates['attributes:actions:create:form:visibility:after']; - 'customer:attributes:actions:create:form:timestamps:before'?: CustomerTemplates['attributes:actions:create:form:timestamps:before']; - 'customer:attributes:actions:create:form:timestamps:after'?: CustomerTemplates['attributes:actions:create:form:timestamps:after']; - 'customer:attributes:actions:create:form:delete:before'?: CustomerTemplates['attributes:actions:create:form:delete:before']; - 'customer:attributes:actions:create:form:delete:after'?: CustomerTemplates['attributes:actions:create:form:delete:after']; - 'customer:attributes:actions:create:form:create:before'?: CustomerTemplates['attributes:actions:create:form:create:before']; - 'customer:attributes:actions:create:form:create:after'?: CustomerTemplates['attributes:actions:create:form:create:after']; - 'customer:attributes:list:before'?: CustomerTemplates['attributes:list:before']; - 'customer:attributes:list:after'?: CustomerTemplates['attributes:list:after']; - 'customer:attributes:list:card:name:before'?: CustomerTemplates['attributes:list:card:name:before']; - 'customer:attributes:list:card:name:after'?: CustomerTemplates['attributes:list:card:name:after']; - 'customer:attributes:list:card:value:before'?: CustomerTemplates['attributes:list:card:value:before']; - 'customer:attributes:list:card:value:after'?: CustomerTemplates['attributes:list:card:value:after']; - 'customer:attributes:list:form:name:before'?: CustomerTemplates['attributes:list:form:name:before']; - 'customer:attributes:list:form:name:after'?: CustomerTemplates['attributes:list:form:name:after']; - 'customer:attributes:list:form:value:before'?: CustomerTemplates['attributes:list:form:value:before']; - 'customer:attributes:list:form:value:after'?: CustomerTemplates['attributes:list:form:value:after']; - 'customer:attributes:list:form:visibility:before'?: CustomerTemplates['attributes:list:form:visibility:before']; - 'customer:attributes:list:form:visibility:after'?: CustomerTemplates['attributes:list:form:visibility:after']; - 'customer:attributes:list:form:timestamps:before'?: CustomerTemplates['attributes:list:form:timestamps:before']; - 'customer:attributes:list:form:timestamps:after'?: CustomerTemplates['attributes:list:form:timestamps:after']; - 'customer:attributes:list:form:delete:before'?: CustomerTemplates['attributes:list:form:delete:before']; - 'customer:attributes:list:form:delete:after'?: CustomerTemplates['attributes:list:form:delete:after']; - 'customer:attributes:list:form:create:before'?: CustomerTemplates['attributes:list:form:create:before']; - 'customer:attributes:list:form:create:after'?: CustomerTemplates['attributes:list:form:create:after']; - 'customer:transactions:before'?: CustomerTemplates['transactions:before']; - 'customer:transactions:after'?: CustomerTemplates['transactions:after']; - 'customer:transactions:table:default'?: CustomerTemplates['transactions:table:default']; - 'customer:subscriptions:before'?: CustomerTemplates['subscriptions:before']; - 'customer:subscriptions:after'?: CustomerTemplates['subscriptions:after']; - 'customer:subscriptions:list:card:default'?: SubscriptionCardTemplates['default']; - 'customer:subscriptions:list:form:header:before'?: CustomerTemplates['subscriptions:form:header:before']; - 'customer:subscriptions:list:form:header:after'?: CustomerTemplates['subscriptions:form:header:after']; - 'customer:subscriptions:list:form:items:before'?: CustomerTemplates['subscriptions:form:items:before']; - 'customer:subscriptions:list:form:items:after'?: CustomerTemplates['subscriptions:form:items:after']; - 'customer:subscriptions:list:form:items:actions:before'?: CustomerTemplates['subscriptions:form:items:actions:before']; - 'customer:subscriptions:list:form:items:actions:after'?: CustomerTemplates['subscriptions:form:items:actions:after']; - 'customer:subscriptions:list:form:end-date:before'?: CustomerTemplates['subscriptions:form:end-date:before']; - 'customer:subscriptions:list:form:end-date:after'?: CustomerTemplates['subscriptions:form:end-date:after']; - 'customer:subscriptions:list:form:end-date:form:warning:before'?: CustomerTemplates['subscriptions:form:end-date:form:warning:before']; - 'customer:subscriptions:list:form:end-date:form:warning:after'?: CustomerTemplates['subscriptions:form:end-date:form:warning:after']; - 'customer:subscriptions:list:form:end-date:form:end-date:before'?: CustomerTemplates['subscriptions:form:end-date:form:end-date:before']; - 'customer:subscriptions:list:form:end-date:form:end-date:after'?: CustomerTemplates['subscriptions:form:end-date:form:end-date:after']; - 'customer:subscriptions:list:form:end-date:form:submit:before'?: CustomerTemplates['subscriptions:form:end-date:form:submit:before']; - 'customer:subscriptions:list:form:end-date:form:submit:after'?: CustomerTemplates['subscriptions:form:end-date:form:submit:after']; - 'customer:subscriptions:list:form:next-transaction-date:before'?: CustomerTemplates['subscriptions:form:next-transaction-date:before']; - 'customer:subscriptions:list:form:next-transaction-date:after'?: CustomerTemplates['subscriptions:form:next-transaction-date:after']; - 'customer:subscriptions:list:form:frequency:before'?: CustomerTemplates['subscriptions:form:frequency:before']; - 'customer:subscriptions:list:form:frequency:after'?: CustomerTemplates['subscriptions:form:frequency:after']; - 'customer:subscriptions:list:form:transactions:before'?: CustomerTemplates['subscriptions:form:transactions:before']; - 'customer:subscriptions:list:form:transactions:after'?: CustomerTemplates['subscriptions:form:transactions:after']; -}; diff --git a/src/elements/public/CustomerPortalSettingsForm/CustomerPortalSettingsForm.test.ts b/src/elements/public/CustomerPortalSettingsForm/CustomerPortalSettingsForm.test.ts index 954e1bfe9..1844c88c5 100644 --- a/src/elements/public/CustomerPortalSettingsForm/CustomerPortalSettingsForm.test.ts +++ b/src/elements/public/CustomerPortalSettingsForm/CustomerPortalSettingsForm.test.ts @@ -8,6 +8,7 @@ import './index'; import { CustomerPortalSettingsForm as Form } from './CustomerPortalSettingsForm'; import { expect, fixture, html } from '@open-wc/testing'; +import { stub } from 'sinon'; describe('CustomerPortalSettingsForm', () => { it('imports and defines foxy-internal-checkbox-group-control', () => { @@ -176,6 +177,11 @@ describe('CustomerPortalSettingsForm', () => { expect(form.errors).to.not.include('sign-up-verification-hcaptcha-secret-key:v8n_too_long'); }); + it('always hides Copy ID button', () => { + const form = new Form(); + expect(form.hiddenSelector.matches('header:copy-id', true)).to.be.true; + }); + it('hides sign-up verification settings when sign-up is disabled', () => { const form = new Form(); @@ -243,6 +249,13 @@ describe('CustomerPortalSettingsForm', () => { .false; }); + it('renders a form header', () => { + const form = new Form(); + const renderHeaderMethod = stub(form, 'renderHeader'); + form.render(); + expect(renderHeaderMethod).to.have.been.called; + }); + it('renders editable list control for allowed origins', async () => { const element = await fixture( html`` diff --git a/src/elements/public/CustomerPortalSettingsForm/CustomerPortalSettingsForm.ts b/src/elements/public/CustomerPortalSettingsForm/CustomerPortalSettingsForm.ts index ade048a4a..75b342719 100644 --- a/src/elements/public/CustomerPortalSettingsForm/CustomerPortalSettingsForm.ts +++ b/src/elements/public/CustomerPortalSettingsForm/CustomerPortalSettingsForm.ts @@ -181,7 +181,7 @@ export class CustomerPortalSettingsForm extends Base { }; get hiddenSelector(): BooleanSelector { - const alwaysMatch = [super.hiddenSelector.toString()]; + const alwaysMatch = ['header:copy-id', super.hiddenSelector.toString()]; if (!this.form.signUp?.enabled) { alwaysMatch.push( @@ -203,6 +203,8 @@ export class CustomerPortalSettingsForm extends Base { renderBody(): TemplateResult { return html` + ${this.renderHeader()} + { it('imports and defines foxy-internal-downloadable-form-upload-control', () => { @@ -132,6 +133,13 @@ describe('DownloadableForm', () => { expect(form.errors).to.include('code:v8n_too_long'); }); + it('renders a form header', () => { + const form = new Form(); + const renderHeaderMethod = stub(form, 'renderHeader'); + form.render(); + expect(renderHeaderMethod).to.have.been.called; + }); + it('renders a foxy-internal-async-combo-box-control for item category uri', async () => { const router = createRouter(); diff --git a/src/elements/public/DownloadableForm/DownloadableForm.ts b/src/elements/public/DownloadableForm/DownloadableForm.ts index 9ae7e06b4..b66fb1a5f 100644 --- a/src/elements/public/DownloadableForm/DownloadableForm.ts +++ b/src/elements/public/DownloadableForm/DownloadableForm.ts @@ -21,30 +21,6 @@ const Base = TranslatableMixin(InternalForm, NS); * This element requires an augmented version of hAPI currently limited * only to the new Foxy Admin. * - * @slot item-category-uri:before - * @slot item-category-uri:after - * - * @slot name:before - * @slot name:after - * - * @slot code:before - * @slot code:after - * - * @slot price:before - * @slot price:after - * - * @slot upload:before - * @slot upload:after - * - * @slot timestamps:before - * @slot timestamps:after - * - * @slot create:before - * @slot create:after - * - * @slot delete:before - * @slot delete:after - * * @element foxy-downloadable-form * @since 1.22.0 */ @@ -83,6 +59,8 @@ export class DownloadableForm extends Base { renderBody(): TemplateResult { return html` + ${this.renderHeader()} + { }; } - templates: Templates = {}; - private __templateLanguageOptions = [ { label: 'Nunjucks', value: 'nunjucks' }, { label: 'Handlebars', value: 'handlebars' }, diff --git a/src/elements/public/EmailTemplateForm/types.ts b/src/elements/public/EmailTemplateForm/types.ts index 58c06a11c..45449430d 100644 --- a/src/elements/public/EmailTemplateForm/types.ts +++ b/src/elements/public/EmailTemplateForm/types.ts @@ -1,19 +1,4 @@ -import { EmailTemplateForm } from './EmailTemplateForm'; -import { Rels } from '@foxy.io/sdk/backend'; -import { Renderer } from '../../../mixins/configurable'; -import { Resource } from '@foxy.io/sdk/core'; +import type { Resource } from '@foxy.io/sdk/core'; +import type { Rels } from '@foxy.io/sdk/backend'; export type Data = Resource; - -export type Templates = { - 'description:before'?: Renderer; - 'description:after'?: Renderer; - 'content:before'?: Renderer; - 'content:after'?: Renderer; - 'timestamps:before'?: Renderer; - 'timestamps:after'?: Renderer; - 'create:before'?: Renderer; - 'create:after'?: Renderer; - 'delete:before'?: Renderer; - 'delete:after'?: Renderer; -}; diff --git a/src/elements/public/FilterAttributeForm/FilterAttributeForm.ts b/src/elements/public/FilterAttributeForm/FilterAttributeForm.ts index cd51326c9..fe9e49de0 100644 --- a/src/elements/public/FilterAttributeForm/FilterAttributeForm.ts +++ b/src/elements/public/FilterAttributeForm/FilterAttributeForm.ts @@ -19,13 +19,6 @@ const Base = TranslatableMixin(InternalForm, NS); * to Admin. Bookmark attributes are named `foxy-admin-bookmark` and contain a * relative URL of the bookmarked Admin page in the value. * - * @slot filter-query:before - * @slot filter-query:after - * @slot filter-name:before - * @slot filter-name:after - * @slot action:before - * @slot action:after - * * @element foxy-filter-attribute-form * @since 1.24.0 */ diff --git a/src/elements/public/FilterAttributeForm/types.ts b/src/elements/public/FilterAttributeForm/types.ts index 61e204591..8ae862c05 100644 --- a/src/elements/public/FilterAttributeForm/types.ts +++ b/src/elements/public/FilterAttributeForm/types.ts @@ -1,17 +1,6 @@ -import type { FilterAttributeForm } from './FilterAttributeForm'; -import type { Renderer } from '../../../mixins/configurable'; import type { Resource } from '@foxy.io/sdk/core'; import type { Rels } from '@foxy.io/sdk/backend'; -export type Templates = { - 'filter-query:before': Renderer; - 'filter-query:after': Renderer; - 'filter-name:before': Renderer; - 'filter-name:after': Renderer; - 'action:before': Renderer; - 'action:after': Renderer; -}; - export type Data = Resource; export type { Option } from '../QueryBuilder/types'; diff --git a/src/elements/public/GenerateCodesForm/GenerateCodesForm.ts b/src/elements/public/GenerateCodesForm/GenerateCodesForm.ts index c83d7640b..1a3a95ec8 100644 --- a/src/elements/public/GenerateCodesForm/GenerateCodesForm.ts +++ b/src/elements/public/GenerateCodesForm/GenerateCodesForm.ts @@ -1,4 +1,4 @@ -import type { Data, Templates } from './types'; +import type { Data } from './types'; import type { TemplateResult } from 'lit-html'; import type { NucleonV8N } from '../NucleonElement/types'; @@ -13,21 +13,6 @@ const Base = TranslatableMixin(InternalForm, NS); /** * Form element for generating codes for coupons or gift cards (`fx:generate_codes`). * - * @slot length:before - * @slot length:after - * - * @slot number-of-codes:before - * @slot number-of-codes:after - * - * @slot prefix:before - * @slot prefix:after - * - * @slot current-balance:before - * @slot current-balance:after - * - * @slot create:before - * @slot create:after - * * @element foxy-generate-codes-form * @since 1.15.0 */ @@ -39,8 +24,6 @@ export class GenerateCodesForm extends Base { ]; } - templates: Templates = {}; - private readonly __exampleGetValue = () => { const templates = [ '1V3BJ3USJKSS1BYANMNBT7AJ06R6QQ8RB0VPPL03ATQVY186X2', diff --git a/src/elements/public/GenerateCodesForm/types.ts b/src/elements/public/GenerateCodesForm/types.ts index a2b341143..9ffc2a76a 100644 --- a/src/elements/public/GenerateCodesForm/types.ts +++ b/src/elements/public/GenerateCodesForm/types.ts @@ -1,7 +1,5 @@ -import { GenerateCodesForm } from '.'; -import { Rels } from '@foxy.io/sdk/backend'; -import { Renderer } from '../../../mixins/configurable'; -import { Resource } from '@foxy.io/sdk/core'; +import type { Resource } from '@foxy.io/sdk/core'; +import type { Rels } from '@foxy.io/sdk/backend'; export type Data = Resource & { /** Present only in the response. */ @@ -9,16 +7,3 @@ export type Data = Resource & { /** Present only in the response. */ message: string; }; - -export type Templates = { - 'length:before'?: Renderer; - 'length:after'?: Renderer; - 'number-of-codes:before'?: Renderer; - 'number-of-codes:after'?: Renderer; - 'prefix:before'?: Renderer; - 'prefix:after'?: Renderer; - 'example:before'?: Renderer; - 'example:after'?: Renderer; - 'create:before'?: Renderer; - 'create:after'?: Renderer; -}; diff --git a/src/elements/public/GiftCardCard/GiftCardCard.ts b/src/elements/public/GiftCardCard/GiftCardCard.ts index 3adb5ad0d..4fa41e5e3 100644 --- a/src/elements/public/GiftCardCard/GiftCardCard.ts +++ b/src/elements/public/GiftCardCard/GiftCardCard.ts @@ -1,4 +1,4 @@ -import { Data, Templates } from './types'; +import { Data } from './types'; import { TemplateResult, html } from 'lit-html'; import { ConfigurableMixin } from '../../../mixins/configurable'; @@ -13,17 +13,10 @@ const Base = ThemeableMixin(ConfigurableMixin(TranslatableMixin(NucleonElement, /** * Basic card displaying a gift card. * - * @slot title:before - * @slot title:after - * @slot status:before - * @slot status:after - * * @element foxy-gift-card-card * @since 1.15.0 */ export class GiftCardCard extends Base { - templates: Templates = {}; - render(): TemplateResult { const hiddenSelector = this.hiddenSelector; diff --git a/src/elements/public/GiftCardCard/types.ts b/src/elements/public/GiftCardCard/types.ts index 63203e1cc..c2b550564 100644 --- a/src/elements/public/GiftCardCard/types.ts +++ b/src/elements/public/GiftCardCard/types.ts @@ -1,13 +1,4 @@ -import { GiftCardCard } from './GiftCardCard'; -import { Rels } from '@foxy.io/sdk/backend'; -import { Renderer } from '../../../mixins/configurable'; -import { Resource } from '@foxy.io/sdk/core'; +import type { Resource } from '@foxy.io/sdk/core'; +import type { Rels } from '@foxy.io/sdk/backend'; export type Data = Resource; - -export type Templates = Partial<{ - 'title:before': Renderer; - 'title:after': Renderer; - 'status:before': Renderer; - 'status:after': Renderer; -}>; diff --git a/src/elements/public/GiftCardCodeForm/GiftCardCodeForm.stories.ts b/src/elements/public/GiftCardCodeForm/GiftCardCodeForm.stories.ts index e2c8df410..fb2f0911f 100644 --- a/src/elements/public/GiftCardCodeForm/GiftCardCodeForm.stories.ts +++ b/src/elements/public/GiftCardCodeForm/GiftCardCodeForm.stories.ts @@ -11,8 +11,8 @@ const summary: Summary = { localName: 'foxy-gift-card-code-form', translatable: true, configurable: { - sections: ['timestamps', 'logs'], - buttons: ['create', 'delete'], + sections: ['timestamps', 'header', 'logs'], + buttons: ['delete', 'create', 'submit', 'undo', 'header:copy-id', 'header:copy-json'], inputs: ['code', 'current-balance', 'end-date', 'customer'], }, }; diff --git a/src/elements/public/GiftCardCodeForm/GiftCardCodeForm.test.ts b/src/elements/public/GiftCardCodeForm/GiftCardCodeForm.test.ts index ef6d9435e..618ca0bb4 100644 --- a/src/elements/public/GiftCardCodeForm/GiftCardCodeForm.test.ts +++ b/src/elements/public/GiftCardCodeForm/GiftCardCodeForm.test.ts @@ -9,6 +9,7 @@ import { InternalForm } from '../../internal/InternalForm/InternalForm'; import { createRouter } from '../../../server'; import { getTestData } from '../../../testgen/getTestData'; import { Type } from '../QueryBuilder/types'; +import { stub } from 'sinon'; describe('GiftCardCodeForm', () => { it('imports and defines foxy-internal-resource-picker-control', () => { @@ -110,6 +111,13 @@ describe('GiftCardCodeForm', () => { expect(element.hiddenSelector.matches('logs', true)).to.be.false; }); + it('renders a form header', () => { + const form = new GiftCardCodeForm(); + const renderHeaderMethod = stub(form, 'renderHeader'); + form.render(); + expect(renderHeaderMethod).to.have.been.called; + }); + it('renders a text control for code', async () => { const element = await fixture( html`` diff --git a/src/elements/public/GiftCardCodeForm/GiftCardCodeForm.ts b/src/elements/public/GiftCardCodeForm/GiftCardCodeForm.ts index 26d86ea63..ca719115c 100644 --- a/src/elements/public/GiftCardCodeForm/GiftCardCodeForm.ts +++ b/src/elements/public/GiftCardCodeForm/GiftCardCodeForm.ts @@ -1,5 +1,5 @@ import type { PropertyDeclarations } from 'lit-element'; -import type { Data, Templates } from './types'; +import type { Data } from './types'; import type { TemplateResult } from 'lit-html'; import type { NucleonElement } from '../NucleonElement/NucleonElement'; import type { NucleonV8N } from '../NucleonElement/types'; @@ -19,30 +19,6 @@ const Base = TranslatableMixin(InternalForm, NS); /** * Form element for creating or editing gift card codes (`fx:gift_card_code`). * - * @slot code:before - * @slot code:after - * - * @slot current-balance:before - * @slot current-balance:after - * - * @slot end-date:before - * @slot end-date:after - * - * @slot customer:before – **new in v1.27.0** - * @slot customer:after – **new in v1.27.0** - * - * @slot logs:before - * @slot logs:after - * - * @slot timestamps:before - * @slot timestamps:after - * - * @slot delete:before - * @slot delete:after - * - * @slot create:before - * @slot create:after - * * @element foxy-gift-card-code-form * @since 1.15.0 */ @@ -68,8 +44,6 @@ export class GiftCardCodeForm extends Base { return `https://api.foxycart.com/customers/${id}`; }; - templates: Templates = {}; - private readonly __customerGetValue = () => { const link = this.data?._links?.['fx:customer']?.href; const id = this.form.customer_id; @@ -111,6 +85,8 @@ export class GiftCardCodeForm extends Base { renderBody(): TemplateResult { return html` + ${this.renderHeader()} + diff --git a/src/elements/public/GiftCardCodeForm/types.ts b/src/elements/public/GiftCardCodeForm/types.ts index eb9634d40..61c2376cc 100644 --- a/src/elements/public/GiftCardCodeForm/types.ts +++ b/src/elements/public/GiftCardCodeForm/types.ts @@ -1,27 +1,6 @@ -import type { GiftCardCodeForm } from './GiftCardCodeForm'; -import type { Renderer } from '../../../mixins/configurable'; import type { Resource } from '@foxy.io/sdk/core'; import type { Rels } from '@foxy.io/sdk/backend'; export type Data = Resource & { customer_id?: number | string; }; - -export type Templates = { - 'code:before'?: Renderer; - 'code:after'?: Renderer; - 'current-balance:before'?: Renderer; - 'current-balance:after'?: Renderer; - 'end-date:before'?: Renderer; - 'end-date:after'?: Renderer; - 'customer:before'?: Renderer; - 'customer:after'?: Renderer; - 'logs:before'?: Renderer; - 'logs:after'?: Renderer; - 'timestamps:before'?: Renderer; - 'timestamps:after'?: Renderer; - 'delete:before'?: Renderer; - 'delete:after'?: Renderer; - 'create:before'?: Renderer; - 'create:after'?: Renderer; -}; diff --git a/src/elements/public/GiftCardCodesForm/GiftCardCodesForm.ts b/src/elements/public/GiftCardCodesForm/GiftCardCodesForm.ts index b0d3eb02e..0b3d0bec1 100644 --- a/src/elements/public/GiftCardCodesForm/GiftCardCodesForm.ts +++ b/src/elements/public/GiftCardCodesForm/GiftCardCodesForm.ts @@ -1,4 +1,4 @@ -import type { Data, Templates } from './types'; +import type { Data } from './types'; import type { TemplateResult } from 'lit-html'; import type { NucleonV8N } from '../NucleonElement/types'; import type { Item } from '../../internal/InternalEditableListControl/types'; @@ -14,15 +14,6 @@ const Base = TranslatableMixin(InternalForm, NS); /** * Form element for importing gift card codes (`fx:gift_card_codes`). * - * @slot gift-card-codes:before - **new in v1.27.0** - * @slot gift-card-codes:after - **new in v1.27.0** - * - * @slot current-balance:before - **new in v1.27.0** - * @slot current-balance:after - **new in v1.27.0** - * - * @slot create:before - **new in v1.27.0** - * @slot create:after - **new in v1.27.0** - * * @element foxy-gift-card-codes-form * @since 1.15.0 */ @@ -31,8 +22,6 @@ export class GiftCardCodesForm extends Base { return [({ gift_card_codes: v }) => (v && v.length > 0) || 'gift-card-codes:v8n_required']; } - templates: Templates = {}; - private readonly __giftCardCodesGetValue = () => { return this.form.gift_card_codes?.map(value => ({ value })) ?? []; }; diff --git a/src/elements/public/GiftCardCodesForm/types.ts b/src/elements/public/GiftCardCodesForm/types.ts index c7f37cb84..0961237d5 100644 --- a/src/elements/public/GiftCardCodesForm/types.ts +++ b/src/elements/public/GiftCardCodesForm/types.ts @@ -1,15 +1,4 @@ -import { GiftCardCodesForm } from './GiftCardCodesForm'; -import { Rels } from '@foxy.io/sdk/backend'; -import { Renderer } from '../../../mixins/configurable'; -import { Resource } from '@foxy.io/sdk/core'; +import type { Resource } from '@foxy.io/sdk/core'; +import type { Rels } from '@foxy.io/sdk/backend'; export type Data = Resource & { _links: { self: { href: string } } }; - -export type Templates = { - 'gift-card-codes:before'?: Renderer; - 'gift-card-codes:after'?: Renderer; - 'current-balance:before'?: Renderer; - 'current-balance:after'?: Renderer; - 'create:before'?: Renderer; - 'create:after'?: Renderer; -}; diff --git a/src/elements/public/GiftCardForm/GiftCardForm.stories.ts b/src/elements/public/GiftCardForm/GiftCardForm.stories.ts index 9c49eddac..41b612d90 100644 --- a/src/elements/public/GiftCardForm/GiftCardForm.stories.ts +++ b/src/elements/public/GiftCardForm/GiftCardForm.stories.ts @@ -20,8 +20,8 @@ const summary: Summary = { 'category-restrictions', 'attributes', ], - sections: ['timestamps'], - buttons: ['create', 'delete'], + sections: ['timestamps', 'header'], + buttons: ['delete', 'create', 'submit', 'undo', 'header:copy-id', 'header:copy-json'], }, }; diff --git a/src/elements/public/GiftCardForm/GiftCardForm.test.ts b/src/elements/public/GiftCardForm/GiftCardForm.test.ts index 6c0fffea2..2015cfcc5 100644 --- a/src/elements/public/GiftCardForm/GiftCardForm.test.ts +++ b/src/elements/public/GiftCardForm/GiftCardForm.test.ts @@ -205,6 +205,21 @@ describe('GiftCardForm', () => { expect(element.hiddenSelector.matches('attributes', true)).to.be.false; }); + it('renders a form header', () => { + const form = new GiftCardForm(); + const renderHeaderMethod = stub(form, 'renderHeader'); + form.render(); + expect(renderHeaderMethod).to.have.been.called; + }); + + it('uses custom form header subtitle options', async () => { + const element = await fixture(html` + + `); + + expect(element.headerSubtitleOptions).to.deep.equal({ id: element.headerCopyIdValue }); + }); + it('renders bulk add control for the Generate Codes header action', async () => { const element = await fixture(html` diff --git a/src/elements/public/GiftCardForm/GiftCardForm.ts b/src/elements/public/GiftCardForm/GiftCardForm.ts index 146e0ffa8..a802bb053 100644 --- a/src/elements/public/GiftCardForm/GiftCardForm.ts +++ b/src/elements/public/GiftCardForm/GiftCardForm.ts @@ -23,36 +23,6 @@ const Base = ResponsiveMixin(TranslatableMixin(InternalForm, NS)); /** * Form element for creating or editing gift cards (`fx:gift_card`). * - * @slot name:before - * @slot name:after - * - * @slot currency:before - * @slot currency:after - * - * @slot expires:before - * @slot expires:after - * - * @slot codes:before - * @slot codes:after - * - * @slot product-restrictions:before - * @slot product-restrictions:after - * - * @slot category-restrictions:before - * @slot category-restrictions:after - * - * @slot attributes:before - **new in v1.27.0** - * @slot attributes:after - **new in v1.27.0** - * - * @slot timestamps:before - * @slot timestamps:after - * - * @slot delete:before - * @slot delete:after - * - * @slot create:before - * @slot create:after - * * @element foxy-gift-card-form * @since 1.15.0 */ @@ -169,6 +139,10 @@ export class GiftCardForm extends Base { return new BooleanSelector(alwaysMatch.join(' ').trim()); } + get headerSubtitleOptions(): Record { + return { id: this.headerCopyIdValue }; + } + renderHeaderActions(data: Data): TemplateResult { return html` { expect(constructor).to.equal(InternalDeleteControl); }); - it('imports and registers foxy-internal-create-control element', () => { - const constructor = customElements.get('foxy-internal-create-control'); - expect(constructor).to.equal(InternalCreateControl); + it('imports and registers foxy-internal-submit-control element', () => { + const constructor = customElements.get('foxy-internal-submit-control'); + expect(constructor).to.equal(InternalSubmitControl); }); it('imports and registers foxy-internal-text-control element', () => { @@ -60,6 +60,18 @@ describe('IntegrationForm', () => { expect(new Form()).to.be.instanceOf(InternalForm); }); + it('renders a form header', () => { + const form = new Form(); + const renderHeaderMethod = stub(form, 'renderHeader'); + form.render(); + expect(renderHeaderMethod).to.have.been.called; + }); + + it('always hides Copy ID button in header', () => { + const form = new Form(); + expect(form.hiddenSelector.matches('header:copy-id', true)).to.be.true; + }); + it('renders a textbox for project name in template state', async () => { const router = createRouter(); const element = await fixture(html` @@ -90,62 +102,7 @@ describe('IntegrationForm', () => { `); const control = element.renderRoot.querySelector('[infer="create"]'); - expect(control).to.be.instanceOf(InternalCreateControl); - }); - - it('renders project name and description in snapshot state', async () => { - const router = createRouter(); - const href = 'https://demo.api/hapi/integrations/0'; - const data = await getTestData(href, router); - const element = await fixture(html` - router.handleEvent(evt)}> - - `); - - data.project_name = 'Test project name'; - data.project_description = 'Test project description'; - element.data = data; - await element.requestUpdate(); - - expect(element.renderRoot).to.include.text('Test project name'); - expect(element.renderRoot).to.include.text('Test project description'); - }); - - it('hides project name and description in snapshot state if header is hidden', async () => { - const router = createRouter(); - const href = 'https://demo.api/hapi/integrations/0'; - const data = await getTestData(href, router); - const element = await fixture(html` - router.handleEvent(evt)} - > - - `); - - data.project_name = 'Test project name'; - data.project_description = 'Test project description'; - element.data = data; - await element.requestUpdate(); - - expect(element.renderRoot).to.not.include.text('Test project name'); - expect(element.renderRoot).to.not.include.text('Test project description'); - }); - - it('renders project description in snapshot state', async () => { - const router = createRouter(); - const href = 'https://demo.api/hapi/integrations/0'; - const data = await getTestData(href, router); - const element = await fixture(html` - router.handleEvent(evt)}> - - `); - - data.project_description = 'Test project description'; - element.data = data; - await element.requestUpdate(); - - expect(element.renderRoot).to.include.text('Test project description'); + expect(control).to.be.instanceOf(InternalSubmitControl); }); it('renders slots or templates before and after header in snapshot state', async () => { diff --git a/src/elements/public/IntegrationForm/IntegrationForm.ts b/src/elements/public/IntegrationForm/IntegrationForm.ts index 771a4b7d3..52931330d 100644 --- a/src/elements/public/IntegrationForm/IntegrationForm.ts +++ b/src/elements/public/IntegrationForm/IntegrationForm.ts @@ -4,6 +4,7 @@ import type { TemplateResult } from 'lit-html'; import type { NucleonV8N } from '../NucleonElement/types'; import { TranslatableMixin } from '../../../mixins/translatable'; +import { BooleanSelector } from '@foxy.io/sdk/core'; import { InternalForm } from '../../internal/InternalForm/InternalForm'; import { classMap } from '../../../utils/class-map'; import { html } from 'lit-html'; @@ -14,27 +15,6 @@ const Base = TranslatableMixin(InternalForm, NS); /** * Form element for managing integrations (`fx:integration`). * - * @slot project-name:before - * @slot project-name:after - * - * @slot project-description:before - * @slot project-description:after - * - * @slot create:before - * @slot create:after - * - * @slot header:before - * @slot header:after - * - * @slot message:before - * @slot message:after - * - * @slot table:before - * @slot table:after - * - * @slot delete:before - * @slot delete:after - * * @element foxy-integration-form * @since 1.21.0 */ @@ -52,6 +32,10 @@ export class IntegrationForm extends Base { private __postResponse: PostResponseData | null = null; + get hiddenSelector(): BooleanSelector { + return new BooleanSelector(`header:copy-id ${super.hiddenSelector}`.trimEnd()); + } + renderBody(): TemplateResult { return this.data ? this.__renderSnapshotBody() : this.__renderTemplateBody(); } @@ -75,7 +59,7 @@ export class IntegrationForm extends Base { const postResponse = this.__postResponse; return html` - ${hiddenSelector.matches('header', true) ? '' : this.__renderHeader()} + ${this.renderHeader()} ${hiddenSelector.matches('message', true) || !postResponse ? '' : this.__renderMessage()} ${hiddenSelector.matches('table') ? '' : this.__renderTable()} @@ -84,10 +68,11 @@ export class IntegrationForm extends Base { private __renderTemplateBody() { return html` + ${this.renderHeader()} - + `; } @@ -112,24 +97,6 @@ export class IntegrationForm extends Base { `; } - private __renderHeader() { - const data = this.data as Data; - const noDescription = html``; - - return html` -
- ${this.renderTemplateOrSlot('header:before')} - -
-
${data.project_name}​
-
${data.project_description || noDescription}
-
- - ${this.renderTemplateOrSlot('header:after')} -
- `; - } - private __renderTable() { const data = this.data as Data; const expires = new Date((data.expires ?? 0) * 1000); diff --git a/src/elements/public/IntegrationForm/index.ts b/src/elements/public/IntegrationForm/index.ts index 1fd323e8b..fb641c976 100644 --- a/src/elements/public/IntegrationForm/index.ts +++ b/src/elements/public/IntegrationForm/index.ts @@ -2,7 +2,7 @@ import '@vaadin/vaadin-button'; import '../../internal/InternalTextAreaControl/index'; import '../../internal/InternalDeleteControl/index'; -import '../../internal/InternalCreateControl/index'; +import '../../internal/InternalSubmitControl/index'; import '../../internal/InternalTextControl/index'; import '../../internal/InternalSandbox/index'; import '../../internal/InternalForm/index'; diff --git a/src/elements/public/ItemCategoryCard/ItemCategoryCard.ts b/src/elements/public/ItemCategoryCard/ItemCategoryCard.ts index c3d001ce1..a74c74609 100644 --- a/src/elements/public/ItemCategoryCard/ItemCategoryCard.ts +++ b/src/elements/public/ItemCategoryCard/ItemCategoryCard.ts @@ -11,12 +11,6 @@ const Base = TranslatableMixin(TwoLineCard, NS); /** * Card element representing an item category (`fx:item_category`). * - * @slot title:before - * @slot title:after - * - * @slot subtitle:before - * @slot subtitle:after - * * @element foxy-item-category-card * @since 1.21.0 */ diff --git a/src/elements/public/ItemCategoryForm/ItemCategoryForm.stories.ts b/src/elements/public/ItemCategoryForm/ItemCategoryForm.stories.ts index e5b17dadd..2729ce468 100644 --- a/src/elements/public/ItemCategoryForm/ItemCategoryForm.stories.ts +++ b/src/elements/public/ItemCategoryForm/ItemCategoryForm.stories.ts @@ -11,8 +11,8 @@ const summary: Summary = { localName: 'foxy-item-category-form', translatable: true, configurable: { - sections: ['timestamps'], - buttons: ['create', 'delete'], + sections: ['timestamps', 'header'], + buttons: ['delete', 'create', 'submit', 'undo', 'header:copy-id', 'header:copy-json'], inputs: [ 'name', 'code', @@ -39,12 +39,17 @@ const summary: Summary = { }, }; +const ext = ` + email-templates="https://demo.api/hapi/email_templates" + taxes="https://demo.api/hapi/taxes" +`; + export default getMeta(summary); -export const Playground = getStory({ ...summary, code: true }); -export const Empty = getStory(summary); -export const Error = getStory(summary); -export const Busy = getStory(summary); +export const Playground = getStory({ ...summary, ext, code: true }); +export const Empty = getStory({ ...summary, ext }); +export const Error = getStory({ ...summary, ext }); +export const Busy = getStory({ ...summary, ext }); Empty.args.href = ''; Error.args.href = 'https://demo.api/virtual/empty?status=404'; diff --git a/src/elements/public/ItemCategoryForm/ItemCategoryForm.test.ts b/src/elements/public/ItemCategoryForm/ItemCategoryForm.test.ts index f8bad7650..4a9286432 100644 --- a/src/elements/public/ItemCategoryForm/ItemCategoryForm.test.ts +++ b/src/elements/public/ItemCategoryForm/ItemCategoryForm.test.ts @@ -2,7 +2,7 @@ import type { FetchEvent } from '../NucleonElement/FetchEvent'; import './index'; -import { InternalItemCategoryFormTaxesControl } from './internal/InternalItemCategoryFormTaxesControl/InternalItemCategoryFormTaxesControl'; +import { InternalAsyncResourceLinkListControl } from '../../internal/InternalAsyncResourceLinkListControl/InternalAsyncResourceLinkListControl'; import { expect, fixture, html, waitUntil } from '@open-wc/testing'; import { InternalAsyncComboBoxControl } from '../../internal/InternalAsyncComboBoxControl/InternalAsyncComboBoxControl'; import { ItemCategoryForm as Form } from './ItemCategoryForm'; @@ -14,6 +14,7 @@ import { DiscountBuilder } from '../DiscountBuilder/DiscountBuilder'; import { NucleonElement } from '../NucleonElement/NucleonElement'; import { InternalForm } from '../../internal/InternalForm/InternalForm'; import { createRouter } from '../../../server/index'; +import { stub } from 'sinon'; describe('ItemCategoryForm', () => { const OriginalResizeObserver = window.ResizeObserver; @@ -22,6 +23,11 @@ describe('ItemCategoryForm', () => { before(() => (window.ResizeObserver = undefined)); after(() => (window.ResizeObserver = OriginalResizeObserver)); + it('imports and defines foxy-internal-async-resource-link-list-control', () => { + const element = customElements.get('foxy-internal-async-resource-link-list-control'); + expect(element).to.equal(InternalAsyncResourceLinkListControl); + }); + it('imports and defines foxy-internal-async-combo-box-control', () => { const element = customElements.get('foxy-internal-async-combo-box-control'); expect(element).to.equal(InternalAsyncComboBoxControl); @@ -62,11 +68,6 @@ describe('ItemCategoryForm', () => { expect(element).to.equal(NucleonElement); }); - it('imports and defines foxy-internal-item-category-form-taxes-control', () => { - const element = customElements.get('foxy-internal-item-category-form-taxes-control'); - expect(element).to.equal(InternalItemCategoryFormTaxesControl); - }); - it('imports and defines itself as foxy-item-category-form', () => { const element = customElements.get('foxy-item-category-form'); expect(element).to.equal(Form); @@ -357,6 +358,13 @@ describe('ItemCategoryForm', () => { expect(form.errors).to.not.include('admin-email:v8n_required'); }); + it('renders a form header', () => { + const form = new Form(); + const renderHeaderMethod = stub(form, 'renderHeader'); + form.render(); + expect(renderHeaderMethod).to.have.been.called; + }); + it('renders a text control for category name', async () => { const router = createRouter(); const element = await fixture(html` @@ -808,18 +816,27 @@ describe('ItemCategoryForm', () => { const element = await fixture(html` router.handleEvent(evt)} > `); - expect(element.renderRoot.querySelector('[infer="taxes"]')).to.not.exist; - - element.href = 'https://demo.api/hapi/item_categories/0'; await waitUntil(() => !!element.data, '', { timeout: 5000 }); const control = element.renderRoot.querySelector('[infer="taxes"]'); - expect(control).to.be.instanceOf(InternalItemCategoryFormTaxesControl); - expect(control).to.have.attribute('taxes', 'https://demo.api/hapi/taxes'); + expect(control).to.be.instanceOf(InternalAsyncResourceLinkListControl); + expect(control).to.have.attribute('foreign-key-for-uri', 'tax_uri'); + expect(control).to.have.attribute('foreign-key-for-id', 'tax_id'); + expect(control).to.have.attribute('own-key-for-uri', 'item_category_uri'); + expect(control).to.have.attribute('options-href', 'https://demo.api/hapi/taxes'); + expect(control).to.have.attribute( + 'links-href', + 'https://demo.api/hapi/tax_item_categories?item_category_id=0' + ); + expect(control).to.have.attribute('embed-key', 'fx:tax_item_categories'); + expect(control).to.have.attribute('own-uri', 'https://demo.api/hapi/item_categories/0'); + expect(control).to.have.attribute('limit', '5'); + expect(control).to.have.attribute('item', 'foxy-tax-card'); }); }); diff --git a/src/elements/public/ItemCategoryForm/ItemCategoryForm.ts b/src/elements/public/ItemCategoryForm/ItemCategoryForm.ts index 359ea6e41..35e5b26e5 100644 --- a/src/elements/public/ItemCategoryForm/ItemCategoryForm.ts +++ b/src/elements/public/ItemCategoryForm/ItemCategoryForm.ts @@ -1,6 +1,6 @@ import type { PropertyDeclarations } from 'lit-element'; import type { DiscountBuilder } from '../DiscountBuilder/DiscountBuilder'; -import type { Templates, Data } from './types'; +import type { Data } from './types'; import type { NucleonElement } from '../NucleonElement/NucleonElement'; import type { TemplateResult } from 'lit-html'; import type { ParsedValue } from '../DiscountBuilder/types'; @@ -9,6 +9,7 @@ import type { Resource } from '@foxy.io/sdk/core'; import type { Rels } from '@foxy.io/sdk/backend'; import { TranslatableMixin } from '../../../mixins/translatable'; +import { BooleanSelector } from '@foxy.io/sdk/core'; import { InternalForm } from '../../internal/InternalForm/InternalForm'; import { ifDefined } from 'lit-html/directives/if-defined'; import { html } from 'lit-html'; @@ -16,79 +17,6 @@ import { html } from 'lit-html'; /** * Form element for item categories (`fx:item_category`). * - * @slot name:before - * @slot name:after - * - * @slot code:before - * @slot code:after - * - * @slot handling-fee-type:before - * @slot handling-fee-type:after - * - * @slot handling-fee:before - * @slot handling-fee:after - * - * @slot handling-fee-percentage:before - * @slot handling-fee-percentage:after - * - * @slot handling-fee-minimum:before - * @slot handling-fee-minimum:after - * - * @slot item-delivery-type:before - * @slot item-delivery-type:after - * - * @slot max-downloads-per-customer:before - * @slot max-downloads-per-customer:after - * - * @slot max-downloads-time-period:before - * @slot max-downloads-time-period:after - * - * @slot shipping-flat-rate:before - * @slot shipping-flat-rate:after - * - * @slot shipping-flat-rate-type:before - * @slot shipping-flat-rate-type:after - * - * @slot default-weight:before - * @slot default-weight:after - * - * @slot default-weight-unit:before - * @slot default-weight-unit:after - * - * @slot default-length-unit:before - * @slot default-length-unit:after - * - * @slot customs-value:before - * @slot customs-value:after - * - * @slot discount-name:before - * @slot discount-name:after - * - * @slot discount-builder:before - * @slot discount-builder:after - * - * @slot admin-email-template-uri:before - * @slot admin-email-template-uri:after - * - * @slot customer-email-template-uri:before - * @slot customer-email-template-uri:after - * - * @slot gift-recipient-email-template-uri:before - * @slot gift-recipient-email-template-uri:after - * - * @slot taxes:before - * @slot taxes:after - * - * @slot timestamps:before - * @slot timestamps:after - * - * @slot create:before - * @slot create:after - * - * @slot delete:before - * @slot delete:after - * - * * @since 1.21.0 * @element foxy-item-category-form */ @@ -206,9 +134,6 @@ export class ItemCategoryForm extends TranslatableMixin(InternalForm, 'item-cate /** URL of the `fx:email_templates` collection for a store. */ emailTemplates: string | null = null; - /** Template render functions mapped to their name. */ - templates: Templates = {}; - /** URL of the `fx:taxes` collection for a store. */ taxes: string | null = null; @@ -249,11 +174,19 @@ export class ItemCategoryForm extends TranslatableMixin(InternalForm, 'item-cate private readonly __adminEmailTemplateLoaderId = 'admin-email-template-loader'; + get hiddenSelector(): BooleanSelector { + const alwaysHidden = [super.hiddenSelector.toString()]; + if (!this.data) alwaysHidden.unshift('taxes'); + return new BooleanSelector(alwaysHidden.join(' ').trim()); + } + renderBody(): TemplateResult { const itemDeliveryType = this.form.item_delivery_type; const handlingFeeType = this.form.handling_fee_type ?? 'none'; return html` + ${this.renderHeader()} +
@@ -334,7 +267,20 @@ export class ItemCategoryForm extends TranslatableMixin(InternalForm, 'item-cate > - ${this.data ? this.__renderTaxes() : ''} + +
${super.renderBody()} @@ -485,15 +431,4 @@ export class ItemCategoryForm extends TranslatableMixin(InternalForm, 'item-cate private __renderAdminEmail() { return html` `; } - - private __renderTaxes() { - return html` - - - `; - } } diff --git a/src/elements/public/ItemCategoryForm/index.ts b/src/elements/public/ItemCategoryForm/index.ts index 24ce0873f..c450418c3 100644 --- a/src/elements/public/ItemCategoryForm/index.ts +++ b/src/elements/public/ItemCategoryForm/index.ts @@ -1,3 +1,4 @@ +import '../../internal/InternalAsyncResourceLinkListControl/index'; import '../../internal/InternalAsyncComboBoxControl/index'; import '../../internal/InternalIntegerControl/index'; import '../../internal/InternalNumberControl/index'; @@ -7,8 +8,7 @@ import '../../internal/InternalForm/index'; import '../DiscountBuilder/index'; import '../NucleonElement/index'; - -import './internal/InternalItemCategoryFormTaxesControl/index'; +import '../TaxCard/index'; import { ItemCategoryForm } from './ItemCategoryForm'; diff --git a/src/elements/public/ItemCategoryForm/internal/InternalItemCategoryFormTaxesControl/InternalItemCategoryFormTaxesControl.test.ts b/src/elements/public/ItemCategoryForm/internal/InternalItemCategoryFormTaxesControl/InternalItemCategoryFormTaxesControl.test.ts deleted file mode 100644 index 9ee94b08b..000000000 --- a/src/elements/public/ItemCategoryForm/internal/InternalItemCategoryFormTaxesControl/InternalItemCategoryFormTaxesControl.test.ts +++ /dev/null @@ -1,127 +0,0 @@ -import type { ItemCategoryForm } from '../../ItemCategoryForm'; -import type { FetchEvent } from '../../../NucleonElement/FetchEvent'; - -import '../../index'; -import './index'; - -import { InternalItemCategoryFormTaxesControl as Control } from './InternalItemCategoryFormTaxesControl'; -import { InternalItemCategoryFormTaxesControlItem } from '../InternalItemCategoryFormTaxesControlItem/InternalItemCategoryFormTaxesControlItem'; -import { expect, fixture, html, waitUntil } from '@open-wc/testing'; -import { InternalControl } from '../../../../internal/InternalControl/InternalControl'; -import { CollectionPage } from '../../../CollectionPage/CollectionPage'; -import { createRouter } from '../../../../../server'; -import { Pagination } from '../../../Pagination/Pagination'; -import { getByKey } from '../../../../../testgen/getByKey'; -import { getByTag } from '../../../../../testgen/getByTag'; - -describe('ItemCategoryForm', () => { - describe('InternalItemCategoryFormTaxesControl', () => { - const OriginalResizeObserver = window.ResizeObserver; - - // @ts-expect-error disabling ResizeObserver because it errors in test env - before(() => (window.ResizeObserver = undefined)); - after(() => (window.ResizeObserver = OriginalResizeObserver)); - - it('imports and defines foxy-internal-control', () => { - const element = customElements.get('foxy-internal-control'); - expect(element).to.equal(InternalControl); - }); - - it('imports and defines foxy-collection-page', () => { - const element = customElements.get('foxy-collection-page'); - expect(element).to.equal(CollectionPage); - }); - - it('imports and defines foxy-pagination', () => { - const element = customElements.get('foxy-pagination'); - expect(element).to.equal(Pagination); - }); - - it('imports and defines foxy-internal-item-category-form-taxes-control-item', () => { - const element = customElements.get('foxy-internal-item-category-form-taxes-control-item'); - expect(element).to.equal(InternalItemCategoryFormTaxesControlItem); - }); - - it('imports and defines itself as foxy-internal-item-category-form-taxes-control', () => { - const element = customElements.get('foxy-internal-item-category-form-taxes-control'); - expect(element).to.equal(Control); - }); - - it('extends foxy-internal-control', () => { - expect(new Control()).to.be.instanceOf(InternalControl); - }); - - it('has a reactive property "taxes"', () => { - expect(new Control()).to.have.property('taxes', null); - expect(Control).to.have.nested.property('properties.taxes'); - expect(Control).to.not.have.nested.property('properties.taxes.type'); - expect(Control).to.not.have.nested.property('properties.taxes.attribute'); - }); - - it('renders translatable label', async () => { - const control = await fixture(html` - - `); - - const label = await getByKey(control, 'title'); - - expect(label).to.exist; - expect(label).to.have.attribute('infer', ''); - }); - - it('renders pagination for taxes', async () => { - const control = await fixture(html` - - - `); - - const pagination = await getByTag(control, 'foxy-pagination'); - - expect(pagination).to.exist; - expect(pagination).to.have.attribute('infer', 'pagination'); - expect(pagination).to.have.attribute('first', 'https://demo.api/hapi/taxes?limit=5'); - }); - - it('renders pagination page for taxes', async () => { - const router = createRouter(); - - const element = await fixture(html` - router.handleEvent(evt)} - > - - - - `); - - await waitUntil(() => !!element.data, '', { timeout: 5000 }); - - const control = element.firstElementChild as Control; - const pagination = (await getByTag(control, 'foxy-pagination')) as Pagination; - const page = pagination.firstElementChild as CollectionPage; - - expect(page).to.exist; - expect(page).to.have.attribute('infer', ''); - expect(page).to.have.attribute('item', 'foxy-internal-item-category-form-taxes-control-item'); - expect(page).to.have.deep.property('props', { - 'tax-item-categories': 'https://demo.api/hapi/tax_item_categories?item_category_id=0', - 'item-category': 'https://demo.api/hapi/item_categories/0', - }); - }); - - it('renders translatable helper text', async () => { - const control = await fixture(html` - - `); - - const helperText = await getByKey(control, 'helper_text'); - - expect(helperText).to.exist; - expect(helperText).to.have.attribute('infer', ''); - }); - }); -}); diff --git a/src/elements/public/ItemCategoryForm/internal/InternalItemCategoryFormTaxesControl/InternalItemCategoryFormTaxesControl.ts b/src/elements/public/ItemCategoryForm/internal/InternalItemCategoryFormTaxesControl/InternalItemCategoryFormTaxesControl.ts deleted file mode 100644 index f521956b3..000000000 --- a/src/elements/public/ItemCategoryForm/internal/InternalItemCategoryFormTaxesControl/InternalItemCategoryFormTaxesControl.ts +++ /dev/null @@ -1,56 +0,0 @@ -import type { PropertyDeclarations } from 'lit-element'; -import type { TemplateResult } from 'lit-html'; -import type { NucleonElement } from '../../../NucleonElement/NucleonElement'; -import type { Data } from '../../types'; - -import { InternalControl } from '../../../../internal/InternalControl/InternalControl'; -import { html } from 'lit-html'; - -export class InternalItemCategoryFormTaxesControl extends InternalControl { - static get properties(): PropertyDeclarations { - return { - ...super.properties, - taxes: {}, - }; - } - - taxes: string | null = null; - - renderControl(): TemplateResult { - const nucleon = this.nucleon as NucleonElement | null; - let taxes: string; - - try { - const url = new URL(this.taxes ?? ''); - url.searchParams.set('limit', '5'); - taxes = url.toString(); - } catch { - taxes = this.taxes ?? ''; - } - - return html` - - - - - - - - - - - `; - } -} diff --git a/src/elements/public/ItemCategoryForm/internal/InternalItemCategoryFormTaxesControl/index.ts b/src/elements/public/ItemCategoryForm/internal/InternalItemCategoryFormTaxesControl/index.ts deleted file mode 100644 index a62a59e5f..000000000 --- a/src/elements/public/ItemCategoryForm/internal/InternalItemCategoryFormTaxesControl/index.ts +++ /dev/null @@ -1,15 +0,0 @@ -import '../../../../internal/InternalControl/index'; - -import '../../../CollectionPage/index'; -import '../../../Pagination/index'; - -import '../InternalItemCategoryFormTaxesControlItem/index'; - -import { InternalItemCategoryFormTaxesControl } from './InternalItemCategoryFormTaxesControl'; - -customElements.define( - 'foxy-internal-item-category-form-taxes-control', - InternalItemCategoryFormTaxesControl -); - -export { InternalItemCategoryFormTaxesControl }; diff --git a/src/elements/public/ItemCategoryForm/internal/InternalItemCategoryFormTaxesControlItem/InternalItemCategoryFormTaxesControlItem.test.ts b/src/elements/public/ItemCategoryForm/internal/InternalItemCategoryFormTaxesControlItem/InternalItemCategoryFormTaxesControlItem.test.ts deleted file mode 100644 index f52d1cbfd..000000000 --- a/src/elements/public/ItemCategoryForm/internal/InternalItemCategoryFormTaxesControlItem/InternalItemCategoryFormTaxesControlItem.test.ts +++ /dev/null @@ -1,240 +0,0 @@ -import type { CheckboxElement } from '@vaadin/vaadin-checkbox'; -import type { FetchEvent } from '../../../NucleonElement/FetchEvent'; - -import './index'; - -import { InternalItemCategoryFormTaxesControlItem as Item } from './InternalItemCategoryFormTaxesControlItem'; -import { expect, fixture, html, oneEvent } from '@open-wc/testing'; -import { NucleonElement } from '../../../NucleonElement/NucleonElement'; -import { createRouter } from '../../../../../server'; -import { getByTag } from '../../../../../testgen/getByTag'; -import { TaxCard } from '../../../TaxCard/index'; - -const waitUntilNetworkIsIdle = (element: HTMLElement) => { - return new Promise(resolve => { - let timeout = setTimeout(() => resolve(), 500); - - const handler = () => { - clearTimeout(timeout); - - timeout = setTimeout(() => { - element.removeEventListener('fetch', handler); - resolve(); - }, 500); - }; - - element.addEventListener('fetch', handler); - }); -}; - -describe('ItemCategoryForm', () => { - describe('InternalItemCategoryFormTaxesControlItem', () => { - const OriginalResizeObserver = window.ResizeObserver; - - // @ts-expect-error disabling ResizeObserver because it errors in test env - before(() => (window.ResizeObserver = undefined)); - after(() => (window.ResizeObserver = OriginalResizeObserver)); - - it('imports and defines vaadin-checkbox', () => { - const element = customElements.get('vaadin-checkbox'); - expect(element).to.exist; - }); - - it('imports and defines foxy-nucleon', () => { - const element = customElements.get('foxy-nucleon'); - expect(element).to.equal(NucleonElement); - }); - - it('imports and defines foxy-tax-card', () => { - const element = customElements.get('foxy-tax-card'); - expect(element).to.equal(TaxCard); - }); - - it('imports and defines itself as foxy-internal-item-category-form-taxes-control-item', () => { - const element = customElements.get('foxy-internal-item-category-form-taxes-control-item'); - expect(element).to.equal(Item); - }); - - it('extends foxy-tax-card', () => { - expect(new Item()).to.be.instanceOf(TaxCard); - }); - - it('has a reactive property "taxItemCategories"', () => { - expect(new Item()).to.have.property('taxItemCategories', null); - expect(Item).to.have.nested.property('properties.taxItemCategories'); - expect(Item).to.not.have.nested.property('properties.taxItemCategories.type'); - expect(Item).to.have.nested.property( - 'properties.taxItemCategories.attribute', - 'tax-item-categories' - ); - }); - - it('has a reactive property "itemCategory"', () => { - expect(new Item()).to.have.property('itemCategory', null); - expect(Item).to.have.nested.property('properties.itemCategory'); - expect(Item).to.not.have.nested.property('properties.itemCategory.type'); - expect(Item).to.have.nested.property('properties.itemCategory.attribute', 'item-category'); - }); - - it('renders an unchecked checkbox if tax item category resource does not exist', async () => { - const router = createRouter(); - const item = await fixture(html` - router.handleEvent(evt)} - > - - `); - - await waitUntilNetworkIsIdle(item); - expect(await getByTag(item, 'vaadin-checkbox')).to.not.have.attribute('checked'); - }); - - it('creates a tax item category when checkbox is checked', async () => { - const router = createRouter(); - - const item = await fixture(html` - - - `); - - const handleFetch = (evt: FetchEvent) => router.handleEvent(evt); - item.addEventListener('fetch', handleFetch as (evt: Event) => unknown); - item.href = 'https://demo.api/hapi/taxes/0'; - - await waitUntilNetworkIsIdle(item); - item.removeEventListener('fetch', handleFetch as (evt: Event) => unknown); - const checkbox = (await getByTag(item, 'vaadin-checkbox')) as CheckboxElement; - const whenFetchEventSent = oneEvent(item, 'fetch') as unknown as Promise; - - checkbox.checked = true; - checkbox.dispatchEvent(new CustomEvent('change')); - const fetchEvent = await whenFetchEventSent; - - expect(fetchEvent).to.have.nested.property('request.method', 'POST'); - - expect(fetchEvent).to.have.nested.property( - 'request.url', - 'https://demo.api/hapi/tax_item_categories?i_dont=exist' - ); - - expect(await fetchEvent.request.clone().json()).to.deep.equal({ - item_category_uri: 'https://demo.api/hapi/item_categories/0', - tax_uri: 'https://demo.api/hapi/taxes/0', - }); - }); - - it('renders a checked checkbox if tax item category resource exists', async () => { - const router = createRouter(); - - await router.handleRequest( - new Request('https://demo.api/hapi/tax_item_categories', { - method: 'POST', - body: JSON.stringify({ - item_category_id: 0, - item_category_uri: 'https://demo.api/hapi/item_categories/0', - tax_id: 0, - tax_uri: 'https://demo.api/hapi/taxes/0', - }), - }) - )?.handlerPromise; - - const item = await fixture(html` - router.handleEvent(evt)} - > - - `); - - await waitUntilNetworkIsIdle(item); - expect(await getByTag(item, 'vaadin-checkbox')).to.have.attribute('checked'); - }); - - it('deletes a tax item category when checkbox is unchecked', async () => { - const router = createRouter(); - - const newTICResponse = await router.handleRequest( - new Request('https://demo.api/hapi/tax_item_categories', { - method: 'POST', - body: JSON.stringify({ - item_category_id: 0, - item_category_uri: 'https://demo.api/hapi/item_categories/0', - tax_id: 0, - tax_uri: 'https://demo.api/hapi/taxes/0', - }), - }) - )!.handlerPromise; - - const newTIC = await newTICResponse.json(); - - const item = await fixture(html` - - - `); - - const handleFetch = (evt: FetchEvent) => router.handleEvent(evt); - item.addEventListener('fetch', handleFetch as (evt: Event) => unknown); - item.href = 'https://demo.api/hapi/taxes/0'; - - await waitUntilNetworkIsIdle(item); - item.removeEventListener('fetch', handleFetch as (evt: Event) => unknown); - const checkbox = (await getByTag(item, 'vaadin-checkbox')) as CheckboxElement; - const whenFetchEventSent = oneEvent(item, 'fetch'); - - checkbox.checked = false; - checkbox.dispatchEvent(new CustomEvent('change')); - const fetchEvent = await whenFetchEventSent; - - expect(fetchEvent).to.have.nested.property('request.method', 'DELETE'); - expect(fetchEvent).to.have.nested.property('request.url', newTIC._links.self.href); - }); - - it('disables the checkbox while fetching data', async () => { - const router = createRouter(); - const item = await fixture(html` - router.handleEvent(evt)} - > - - `); - - expect(await getByTag(item, 'vaadin-checkbox')).to.have.attribute('disabled'); - await waitUntilNetworkIsIdle(item); - expect(await getByTag(item, 'vaadin-checkbox')).to.not.have.attribute('disabled'); - }); - - it('disables the checkbox when the entire item is disabled', async () => { - const router = createRouter(); - const item = await fixture(html` - router.handleEvent(evt)} - > - - `); - - await waitUntilNetworkIsIdle(item); - expect(await getByTag(item, 'vaadin-checkbox')).to.not.have.attribute('disabled'); - - item.disabled = true; - await item.requestUpdate(); - expect(await getByTag(item, 'vaadin-checkbox')).to.have.attribute('disabled'); - }); - }); -}); diff --git a/src/elements/public/ItemCategoryForm/internal/InternalItemCategoryFormTaxesControlItem/InternalItemCategoryFormTaxesControlItem.ts b/src/elements/public/ItemCategoryForm/internal/InternalItemCategoryFormTaxesControlItem/InternalItemCategoryFormTaxesControlItem.ts deleted file mode 100644 index fe0534d9e..000000000 --- a/src/elements/public/ItemCategoryForm/internal/InternalItemCategoryFormTaxesControlItem/InternalItemCategoryFormTaxesControlItem.ts +++ /dev/null @@ -1,99 +0,0 @@ -import type { PropertyDeclarations } from 'lit-element'; -import type { CheckboxElement } from '@vaadin/vaadin-checkbox'; -import type { NucleonElement } from '../../../NucleonElement'; -import type { TemplateResult } from 'lit-html'; -import type { Resource } from '@foxy.io/sdk/core'; -import type { Rels } from '@foxy.io/sdk/backend'; - -import { ifDefined } from 'lit-html/directives/if-defined'; -import { TaxCard } from '../../../TaxCard/TaxCard'; -import { html } from 'lit-html'; - -type TaxItemCategories = Resource; -type TaxItemCategory = Resource; - -export class InternalItemCategoryFormTaxesControlItem extends TaxCard { - static get properties(): PropertyDeclarations { - return { - ...super.properties, - taxItemCategories: { attribute: 'tax-item-categories' }, - itemCategory: { attribute: 'item-category' }, - }; - } - - taxItemCategories: string | null = null; - - itemCategory: string | null = null; - - private __resourceElementIsBusy = false; - - private __queryElementData: TaxItemCategories | null = null; - - render(): TemplateResult { - const taxItemCategory = this.__queryElementData?._embedded?.['fx:tax_item_categories']?.[0]; - let taxItemCategories: string | undefined; - - try { - const url = new URL(this.taxItemCategories ?? ''); - const hrefAsUrl = new URL(this.href); - const id = hrefAsUrl.pathname.split('/').pop(); - - if (!id) throw new Error(); - - url.searchParams.set('tax_id', id); - url.searchParams.set('limit', '1'); - taxItemCategories = url.toString(); - } catch { - taxItemCategories = undefined; - } - - return html` - { - const nucleon = evt.currentTarget as NucleonElement; - this.__queryElementData = nucleon.data; - this.requestUpdate(); - }} - > - { - const nucleon = evt.currentTarget as NucleonElement; - this.__resourceElementIsBusy = !nucleon.in('idle'); - this.requestUpdate(); - }} - > - - - - { - type ResourceElement = NucleonElement; - - const checkbox = evt.currentTarget as CheckboxElement; - const resource = this.renderRoot.querySelector('#resource') as ResourceElement; - - if (checkbox.checked) { - resource.edit({ - tax_uri: this.data!._links.self.href, - item_category_uri: this.itemCategory!, - }); - - resource.submit(); - } else { - resource.delete(); - } - }} - > - ${super.render()} - - `; - } -} diff --git a/src/elements/public/ItemCategoryForm/internal/InternalItemCategoryFormTaxesControlItem/index.ts b/src/elements/public/ItemCategoryForm/internal/InternalItemCategoryFormTaxesControlItem/index.ts deleted file mode 100644 index 684b9e163..000000000 --- a/src/elements/public/ItemCategoryForm/internal/InternalItemCategoryFormTaxesControlItem/index.ts +++ /dev/null @@ -1,13 +0,0 @@ -import '@vaadin/vaadin-checkbox'; - -import '../../../NucleonElement/index'; -import '../../../TaxCard/index'; - -import { InternalItemCategoryFormTaxesControlItem } from './InternalItemCategoryFormTaxesControlItem'; - -customElements.define( - 'foxy-internal-item-category-form-taxes-control-item', - InternalItemCategoryFormTaxesControlItem -); - -export { InternalItemCategoryFormTaxesControlItem }; diff --git a/src/elements/public/ItemCategoryForm/types.ts b/src/elements/public/ItemCategoryForm/types.ts index f20efe35d..a46128f2e 100644 --- a/src/elements/public/ItemCategoryForm/types.ts +++ b/src/elements/public/ItemCategoryForm/types.ts @@ -1,56 +1,4 @@ -import type { ItemCategoryForm } from './ItemCategoryForm'; -import type { Renderer } from '../../../mixins/configurable'; import type { Resource } from '@foxy.io/sdk/core'; import type { Rels } from '@foxy.io/sdk/backend'; export type Data = Resource; -export type Templates = { - 'name:before'?: Renderer; - 'name:after'?: Renderer; - 'code:before'?: Renderer; - 'code:after'?: Renderer; - 'handling-fee-type:before'?: Renderer; - 'handling-fee-type:after'?: Renderer; - 'handling-fee:before'?: Renderer; - 'handling-fee:after'?: Renderer; - 'handling-fee-percentage:before'?: Renderer; - 'handling-fee-percentage:after'?: Renderer; - 'handling-fee-minimum:before'?: Renderer; - 'handling-fee-minimum:after'?: Renderer; - 'item-delivery-type:before'?: Renderer; - 'item-delivery-type:after'?: Renderer; - 'max-downloads-per-customer:before'?: Renderer; - 'max-downloads-per-customer:after'?: Renderer; - 'max-downloads-time-period:before'?: Renderer; - 'max-downloads-time-period:after'?: Renderer; - 'shipping-flat-rate:before'?: Renderer; - 'shipping-flat-rate:after'?: Renderer; - 'shipping-flat-rate-type:before'?: Renderer; - 'shipping-flat-rate-type:after'?: Renderer; - 'default-weight:before'?: Renderer; - 'default-weight:after'?: Renderer; - 'default-weight-unit:before'?: Renderer; - 'default-weight-unit:after'?: Renderer; - 'default-length-unit:before'?: Renderer; - 'default-length-unit:after'?: Renderer; - 'customs-value:before'?: Renderer; - 'customs-value:after'?: Renderer; - 'discount-name:before'?: Renderer; - 'discount-name:after'?: Renderer; - 'discount-builder:before'?: Renderer; - 'discount-builder:after'?: Renderer; - 'admin-email-template-uri:before'?: Renderer; - 'admin-email-template-uri:after'?: Renderer; - 'customer-email-template-uri:before'?: Renderer; - 'customer-email-template-uri:after'?: Renderer; - 'gift-recipient-email-template-uri:before'?: Renderer; - 'gift-recipient-email-template-uri:after'?: Renderer; - 'taxes:before'?: Renderer; - 'taxes:after'?: Renderer; - 'timestamps:before'?: Renderer; - 'timestamps:after'?: Renderer; - 'create:before'?: Renderer; - 'create:after'?: Renderer; - 'delete:before'?: Renderer; - 'delete:after'?: Renderer; -}; diff --git a/src/elements/public/ItemForm/ItemForm.stories.ts b/src/elements/public/ItemForm/ItemForm.stories.ts index de797373e..ac66d53ac 100644 --- a/src/elements/public/ItemForm/ItemForm.stories.ts +++ b/src/elements/public/ItemForm/ItemForm.stories.ts @@ -38,17 +38,23 @@ const summary: Summary = { 'attributes', 'item-options', ], - buttons: ['delete', 'create'], - sections: ['timestamps'], + buttons: ['delete', 'create', 'submit', 'undo', 'header:copy-id', 'header:copy-json'], + sections: ['timestamps', 'header'], }, }; +const ext = ` + customer-addresses="https://demo.api/hapi/customer_addresses" + item-categories="https://demo.api/hapi/item_categories" + locale-codes="https://demo.api/hapi/property_helpers/7" +`; + export default getMeta(summary); -export const Playground = getStory({ ...summary, code: true }); -export const Empty = getStory(summary); -export const Error = getStory(summary); -export const Busy = getStory(summary); +export const Playground = getStory({ ...summary, ext, code: true }); +export const Empty = getStory({ ...summary, ext }); +export const Error = getStory({ ...summary, ext }); +export const Busy = getStory({ ...summary, ext }); Empty.args.href = ''; Error.args.href = 'https://demo.api/virtual/empty?status=404'; diff --git a/src/elements/public/ItemForm/ItemForm.test.ts b/src/elements/public/ItemForm/ItemForm.test.ts index 8ca51f23b..4500e3824 100644 --- a/src/elements/public/ItemForm/ItemForm.test.ts +++ b/src/elements/public/ItemForm/ItemForm.test.ts @@ -1,4 +1,5 @@ import type { FetchEvent } from '../NucleonElement/FetchEvent'; +import type { Data } from './types'; import './index'; @@ -8,6 +9,8 @@ import { InternalForm } from '../../internal/InternalForm/InternalForm'; import { ItemForm } from './ItemForm'; import { html } from 'lit-html'; import { DiscountBuilder } from '../DiscountBuilder/DiscountBuilder'; +import { getTestData } from '../../../testgen/getTestData'; +import { stub } from 'sinon'; describe('ItemForm', () => { const OriginalResizeObserver = window.ResizeObserver; @@ -20,8 +23,8 @@ describe('ItemForm', () => { expect(customElements.get('vaadin-details')).to.exist; }); - it('imports and defines foxy-internal-async-combo-box-control', () => { - expect(customElements.get('foxy-internal-async-combo-box-control')).to.exist; + it('imports and defines foxy-internal-resource-picker-control', () => { + expect(customElements.get('foxy-internal-resource-picker-control')).to.exist; }); it('imports and defines foxy-internal-async-list-control', () => { @@ -68,6 +71,10 @@ describe('ItemForm', () => { expect(customElements.get('foxy-discount-builder')).to.exist; }); + it('imports and defines foxy-item-category-card', () => { + expect(customElements.get('foxy-item-category-card')).to.exist; + }); + it('imports and defines foxy-item-option-card', () => { expect(customElements.get('foxy-item-option-card')).to.exist; }); @@ -125,6 +132,24 @@ describe('ItemForm', () => { expect(new ItemForm()).to.have.property('coupons', null); }); + it('renders a form header', () => { + const form = new ItemForm(); + const renderHeaderMethod = stub(form, 'renderHeader'); + form.render(); + expect(renderHeaderMethod).to.have.been.called; + }); + + it('uses custom header subtitle options', async () => { + const element = await fixture(html``); + const data = await getTestData('./hapi/items/0'); + + element.data = { ...data, is_future_line_item: true }; + expect(element.headerSubtitleOptions).to.deep.equal({ context: 'future_line_item' }); + + element.data = { ...data, is_future_line_item: false }; + expect(element.headerSubtitleOptions).to.deep.equal({ context: 'regular' }); + }); + it('renders name as a control', async () => { const element = await fixture(html``); const control = element.renderRoot.querySelector('foxy-internal-text-control[infer="name"]'); @@ -154,14 +179,12 @@ describe('ItemForm', () => { `); const control = element.renderRoot.querySelector( - 'foxy-internal-async-combo-box-control[infer="item-category-uri"]' + 'foxy-internal-resource-picker-control[infer="item-category-uri"]' ); expect(control).to.exist; - expect(control).to.have.property('itemValuePath', '_links.self.href'); - expect(control).to.have.property('itemLabelPath', 'name'); - expect(control).to.have.property('property', 'item_category_uri'); expect(control).to.have.property('first', 'https://demo.api/hapi/item_categories'); + expect(control).to.have.property('item', 'foxy-item-category-card'); }); it('renders item code as a control', async () => { @@ -317,14 +340,8 @@ describe('ItemForm', () => { `); - const control = element.renderRoot.querySelector( - 'foxy-internal-async-combo-box-control[infer="shipto"]' - ); - + const control = element.renderRoot.querySelector('foxy-internal-text-control[infer="shipto"]'); expect(control).to.exist; - expect(control).to.have.property('itemValuePath', 'address_name'); - expect(control).to.have.property('itemLabelPath', 'address_name'); - expect(control).to.have.property('first', 'https://demo.api/hapi/customer_addresses'); }); it('renders expiry date as a control', async () => { diff --git a/src/elements/public/ItemForm/ItemForm.ts b/src/elements/public/ItemForm/ItemForm.ts index b85382cce..6774ae8bb 100644 --- a/src/elements/public/ItemForm/ItemForm.ts +++ b/src/elements/public/ItemForm/ItemForm.ts @@ -1,6 +1,6 @@ import type { PropertyDeclarations } from 'lit-element'; import type { DiscountBuilder } from '../DiscountBuilder/DiscountBuilder'; -import type { Data, Templates } from './types'; +import type { Data } from './types'; import type { TemplateResult } from 'lit-html'; import type { NucleonV8N } from '../NucleonElement/types'; import type { Resource } from '@foxy.io/sdk/core'; @@ -14,90 +14,6 @@ import { html } from 'lit-html'; /** * Form element for creating or editing items (`fx:item`). * - * @slot name:before - * @slot name:after - * - * @slot price:before - * @slot price:after - * - * @slot quantity:before - * @slot quantity:after - * - * @slot subscription-frequency:before – new in 1.25.0 - * @slot subscription-frequency:after – new in 1.25.0 - * - * @slot subscription-start-date:before – new in 1.25.0 - * @slot subscription-start-date:after – new in 1.25.0 - * - * @slot subscription-end-date:before – new in 1.25.0 - * @slot subscription-end-date:after – new in 1.25.0 - * - * @slot discount-name:before – new in 1.25.0 - * @slot discount-name:after – new in 1.25.0 - * - * @slot discount-builder:before – new in 1.25.0 - * @slot discount-builder:after – new in 1.25.0 - * - * @slot expires:before – new in 1.25.0 - * @slot expires:after – new in 1.25.0 - * - * @slot url:before – new in 1.25.0 - * @slot url:after – new in 1.25.0 - * - * @slot image:before – new in 1.25.0 - * @slot image:after – new in 1.25.0 - * - * @slot quantity-min:before – new in 1.25.0 - * @slot quantity-min:after – new in 1.25.0 - * - * @slot quantity-max:before – new in 1.25.0 - * @slot quantity-max:after – new in 1.25.0 - * - * @slot shipto:before – new in 1.25.0 - * @slot shipto:after – new in 1.25.0 - * - * @slot width:before – new in 1.25.0 - * @slot width:after – new in 1.25.0 - * - * @slot height:before – new in 1.25.0 - * @slot height:after – new in 1.25.0 - * - * @slot length:before – new in 1.25.0 - * @slot length:after – new in 1.25.0 - * - * @slot weight:before – new in 1.25.0 - * @slot weight:after – new in 1.25.0 - * - * @slot item-category-uri:before – new in 1.25.0 - * @slot item-category-uri:after – new in 1.25.0 - * - * @slot code:before – new in 1.25.0 - * @slot code:after – new in 1.25.0 - * - * @slot parent-code:before – new in 1.25.0 - * @slot parent-code:after – new in 1.25.0 - * - * @slot discount-details:before – new in 1.25.0 - * @slot discount-details:after – new in 1.25.0 - * - * @slot coupon-details:before – new in 1.25.0 - * @slot coupon-details:after – new in 1.25.0 - * - * @slot attributes:before – new in 1.25.0 - * @slot attributes:after – new in 1.25.0 - * - * @slot item-options:before – new in 1.25.0 - * @slot item-options:after – new in 1.25.0 - * - * @slot timestamps:before - * @slot timestamps:after - * - * @slot delete:before - * @slot delete:after - * - * @slot create:before - * @slot create:after - * * @element foxy-item-form * @since 1.17.0 */ @@ -122,7 +38,7 @@ export class ItemForm extends TranslatableMixin(InternalForm, 'item-form') ]; } - /** Link to the collection of customer addresses that can be used with this item. */ + /** @deprecated Link to the collection of customer addresses that can be used with this item. */ customerAddresses: string | null = null; /** Link to the collection of item categories that can be used with this item. */ @@ -134,12 +50,16 @@ export class ItemForm extends TranslatableMixin(InternalForm, 'item-form') /** @deprecated Link to the collection of coupons that can be used with this item. */ coupons: string | null = null; - templates: Templates = {}; - private __itemsLink = ''; + get headerSubtitleOptions(): Record { + return { context: this.data?.is_future_line_item ? 'future_line_item' : 'regular' }; + } + renderBody(): TemplateResult { return html` + ${this.renderHeader()} +
@@ -147,13 +67,12 @@ export class ItemForm extends TranslatableMixin(InternalForm, 'item-form')
- - + @@ -218,14 +137,7 @@ export class ItemForm extends TranslatableMixin(InternalForm, 'item-form')
- - - + ${this.data diff --git a/src/elements/public/ItemForm/index.ts b/src/elements/public/ItemForm/index.ts index 781e44c02..05267e07a 100644 --- a/src/elements/public/ItemForm/index.ts +++ b/src/elements/public/ItemForm/index.ts @@ -1,6 +1,6 @@ import '@vaadin/vaadin-details'; -import '../../internal/InternalAsyncComboBoxControl/index'; +import '../../internal/InternalResourcePickerControl/index'; import '../../internal/InternalAsyncListControl/index'; import '../../internal/InternalFrequencyControl/index'; import '../../internal/InternalTextAreaControl/index'; @@ -12,6 +12,7 @@ import '../../internal/InternalForm/index'; import '../DiscountDetailCard/index'; import '../CouponDetailCard/index'; +import '../ItemCategoryCard/index'; import '../DiscountBuilder/index'; import '../ItemOptionCard/index'; import '../ItemOptionForm/index'; diff --git a/src/elements/public/ItemForm/types.ts b/src/elements/public/ItemForm/types.ts index 1e8aa36d4..c69251ce4 100644 --- a/src/elements/public/ItemForm/types.ts +++ b/src/elements/public/ItemForm/types.ts @@ -1,92 +1,4 @@ -import type { Renderer } from '../../../mixins/configurable'; -import type { ItemForm } from './ItemForm'; import type { Resource } from '@foxy.io/sdk/core'; import type { Rels } from '@foxy.io/sdk/backend'; export type Data = Resource; - -export type Templates = { - 'name:before'?: Renderer; - 'name:after'?: Renderer; - - 'price:before'?: Renderer; - 'price:after'?: Renderer; - - 'quantity:before'?: Renderer; - 'quantity:after'?: Renderer; - - 'subscription-frequency:before'?: Renderer; - 'subscription:frequency:after'?: Renderer; - - 'subscription-start-date:before'?: Renderer; - 'subscription:start-date:after'?: Renderer; - - 'subscription-end-date:before'?: Renderer; - 'subscription:end-date:after'?: Renderer; - - 'discount-name:before'?: Renderer; - 'discount:name:after'?: Renderer; - - 'discount-builder:before'?: Renderer; - 'discount:builder:after'?: Renderer; - - 'expires:before'?: Renderer; - 'expires:after'?: Renderer; - - 'url:before'?: Renderer; - 'url:after'?: Renderer; - - 'image:before'?: Renderer; - 'image:after'?: Renderer; - - 'quantity-min:before'?: Renderer; - 'quantity:min:after'?: Renderer; - - 'quantity-max:before'?: Renderer; - 'quantity:max:after'?: Renderer; - - 'shipto:before'?: Renderer; - 'shipto:after'?: Renderer; - - 'width:before'?: Renderer; - 'width:after'?: Renderer; - - 'height:before'?: Renderer; - 'height:after'?: Renderer; - - 'length:before'?: Renderer; - 'length:after'?: Renderer; - - 'weight:before'?: Renderer; - 'weight:after'?: Renderer; - - 'item-category-uri:before'?: Renderer; - 'item:category-uri:after'?: Renderer; - - 'code:before'?: Renderer; - 'code:after'?: Renderer; - - 'parent-code:before'?: Renderer; - 'parent:code:after'?: Renderer; - - 'discount-details:before'?: Renderer; - 'discount:details:after'?: Renderer; - - 'coupon-details:before'?: Renderer; - 'coupon:details:after'?: Renderer; - - 'attributes:before'?: Renderer; - 'attributes:after'?: Renderer; - - 'item-options:before'?: Renderer; - 'item:options:after'?: Renderer; - - 'delete:before'?: Renderer; - 'delete:after'?: Renderer; - - 'create:before'?: Renderer; - 'create:after'?: Renderer; - - 'timestamps:before'?: Renderer; - 'timestamps:after'?: Renderer; -}; diff --git a/src/elements/public/ItemOptionCard/ItemOptionCard.ts b/src/elements/public/ItemOptionCard/ItemOptionCard.ts index 039e6e98b..65f91d599 100644 --- a/src/elements/public/ItemOptionCard/ItemOptionCard.ts +++ b/src/elements/public/ItemOptionCard/ItemOptionCard.ts @@ -15,12 +15,6 @@ const Base = TranslatableMixin(TwoLineCard, NS); /** * Basic card displaying an item option. * - * @slot title:before - * @slot title:after - * - * @slot subtitle:before - * @slot subtitle:after - * * @element foxy-item-option-card * @since 1.17.0 */ diff --git a/src/elements/public/ItemOptionCard/types.ts b/src/elements/public/ItemOptionCard/types.ts index 29146e61c..1afe3b448 100644 --- a/src/elements/public/ItemOptionCard/types.ts +++ b/src/elements/public/ItemOptionCard/types.ts @@ -1,12 +1,4 @@ -import { ItemOptionCard } from './ItemOptionCard'; -import { Rels } from '@foxy.io/sdk/backend'; -import { Renderer } from '../../../mixins/configurable'; -import { Resource } from '@foxy.io/sdk/core'; +import type { Resource } from '@foxy.io/sdk/core'; +import type { Rels } from '@foxy.io/sdk/backend'; export type Data = Resource; -export type Templates = { - 'title:before'?: Renderer; - 'title:after'?: Renderer; - 'subtitle:before'?: Renderer; - 'subtitle:after'?: Renderer; -}; diff --git a/src/elements/public/ItemOptionForm/ItemOptionForm.stories.ts b/src/elements/public/ItemOptionForm/ItemOptionForm.stories.ts index 132e1c574..c1d609e67 100644 --- a/src/elements/public/ItemOptionForm/ItemOptionForm.stories.ts +++ b/src/elements/public/ItemOptionForm/ItemOptionForm.stories.ts @@ -12,8 +12,8 @@ const summary: Summary = { translatable: true, configurable: { inputs: ['name', 'value', 'price-mod', 'weight-mod'], - buttons: ['delete', 'create'], - sections: ['timestamps'], + buttons: ['delete', 'create', 'submit', 'undo', 'header:copy-id', 'header:copy-json'], + sections: ['timestamps', 'header'], }, }; diff --git a/src/elements/public/ItemOptionForm/ItemOptionForm.test.ts b/src/elements/public/ItemOptionForm/ItemOptionForm.test.ts index e9632e9ac..24115cddd 100644 --- a/src/elements/public/ItemOptionForm/ItemOptionForm.test.ts +++ b/src/elements/public/ItemOptionForm/ItemOptionForm.test.ts @@ -1,4 +1,5 @@ import { expect, fixture, html } from '@open-wc/testing'; +import { stub } from 'sinon'; import { InternalForm } from '../../internal/InternalForm/InternalForm'; import { InternalNumberControl } from '../../internal/InternalNumberControl/InternalNumberControl'; import { InternalTextControl } from '../../internal/InternalTextControl/InternalTextControl'; @@ -52,6 +53,13 @@ describe('ItemOptionForm', () => { expect(ItemOptionForm.v8n.map(fn => fn({ value }, form))).to.include('value:v8n_too_long'); }); + it('renders a form header', () => { + const form = new ItemOptionForm(); + const renderHeaderMethod = stub(form, 'renderHeader'); + form.render(); + expect(renderHeaderMethod).to.have.been.called; + }); + it('renders item option name as text control', async () => { const element = await fixture( html`` diff --git a/src/elements/public/ItemOptionForm/ItemOptionForm.ts b/src/elements/public/ItemOptionForm/ItemOptionForm.ts index 4e3c33106..cafc6ad27 100644 --- a/src/elements/public/ItemOptionForm/ItemOptionForm.ts +++ b/src/elements/public/ItemOptionForm/ItemOptionForm.ts @@ -9,18 +9,6 @@ import { html } from 'lit-html'; /** * Form element for creating or editing item options (`fx:item_option`). * - * @slot name:before - * @slot name:after - * - * @slot value:before - * @slot value:after - * - * @slot price-mod:before - * @slot price-mod:after - * - * @slot weight-mod:before - * @slot weight-mod:after - * * @element foxy-item-option-form * @since 1.17.0 */ @@ -36,10 +24,15 @@ export class ItemOptionForm extends TranslatableMixin(InternalForm, 'item-option renderBody(): TemplateResult { return html` - - - - + ${this.renderHeader()} + +
+ + + + +
+ ${super.renderBody()} `; } diff --git a/src/elements/public/NativeIntegrationForm/NativeIntegrationForm.stories.ts b/src/elements/public/NativeIntegrationForm/NativeIntegrationForm.stories.ts index ffad5f602..2068229d0 100644 --- a/src/elements/public/NativeIntegrationForm/NativeIntegrationForm.stories.ts +++ b/src/elements/public/NativeIntegrationForm/NativeIntegrationForm.stories.ts @@ -11,8 +11,8 @@ const summary: Summary = { localName: 'foxy-native-integration-form', translatable: true, configurable: { - sections: ['timestamps'], - buttons: ['delete', 'create'], + sections: ['timestamps', 'header'], + buttons: ['delete', 'create', 'submit', 'undo', 'header:copy-id', 'header:copy-json'], inputs: [ 'provider', 'avalara-service-url', diff --git a/src/elements/public/NativeIntegrationForm/NativeIntegrationForm.test.ts b/src/elements/public/NativeIntegrationForm/NativeIntegrationForm.test.ts index 26492cacf..8c34ab734 100644 --- a/src/elements/public/NativeIntegrationForm/NativeIntegrationForm.test.ts +++ b/src/elements/public/NativeIntegrationForm/NativeIntegrationForm.test.ts @@ -16,6 +16,7 @@ import { FetchEvent } from '../NucleonElement/FetchEvent'; import { I18n } from '../I18n'; import * as defaults from './defaults'; +import { stub } from 'sinon'; describe('NativeIntegrationForm', () => { it('imports and defines foxy-internal-checkbox-group-control element', () => { @@ -336,25 +337,30 @@ describe('NativeIntegrationForm', () => { expect(element.errors).to.include('error:already_configured'); }); - it('does not render provider name for webhooks when href is defined', async () => { - const router = createRouter(); + it('renders a form header', () => { + const form = new Form(); + const renderHeaderMethod = stub(form, 'renderHeader'); + form.render(); + expect(renderHeaderMethod).to.have.been.called; + }); + + it('uses custom options for form header title', async () => { const element = await fixture(html` - router.handleEvent(evt)} - > - + `); - await waitUntil(() => element.in('idle')); - element.edit({ provider: 'webhook', config: JSON.stringify(defaults.webhookJson) }); - await element.requestUpdate(); + expect(element.headerTitleOptions).to.deep.equal({ context: 'new', id: '' }); - const control = element.renderRoot.querySelector('[infer="provider"]'); - expect(control).to.not.exist; + const data = await getTestData('./hapi/native_integrations/0'); + element.data = data; + + expect(element.headerTitleOptions).to.deep.equal({ + context: `existing_${data.provider}`, + id: 0, + }); }); - it('renders non-webhook provider name in text control when href is defined', async () => { + it('does not render provider name for webhooks when href is defined', async () => { const router = createRouter(); const element = await fixture(html` { `); await waitUntil(() => element.in('idle')); - const control = element.renderRoot.querySelector('[infer="provider"]') as InternalTextControl; - expect(control).to.be.instanceOf(InternalTextControl); + element.edit({ provider: 'webhook', config: JSON.stringify(defaults.webhookJson) }); + await element.requestUpdate(); + + const control = element.renderRoot.querySelector('[infer="provider"]'); + expect(control).to.not.exist; }); it('renders provider selector when href is not defined', async () => { @@ -384,7 +393,6 @@ describe('NativeIntegrationForm', () => { { value: 'avalara', label: 'option_avalara' }, { value: 'onesource', label: 'option_onesource' }, { value: 'taxjar', label: 'option_taxjar' }, - { value: 'webflow', label: 'option_webflow' }, ]); control.setValue('taxjar'); diff --git a/src/elements/public/NativeIntegrationForm/NativeIntegrationForm.ts b/src/elements/public/NativeIntegrationForm/NativeIntegrationForm.ts index 91727824f..53f029a9d 100644 --- a/src/elements/public/NativeIntegrationForm/NativeIntegrationForm.ts +++ b/src/elements/public/NativeIntegrationForm/NativeIntegrationForm.ts @@ -1,4 +1,4 @@ -import type { Data, Templates } from './types'; +import type { Data } from './types'; import type { TemplateResult } from 'lit-html'; import type { NucleonV8N } from '../NucleonElement/types'; import type { Option } from '../../internal/InternalRadioGroupControl/types'; @@ -18,89 +18,6 @@ const Base = TranslatableMixin(InternalForm, NS); /** * Form element for configuring native integrations (`fx:native_integration`). * - * @slot timestamps:before - * @slot timestamps:after - * @slot delete:before - * @slot delete:after - * @slot create:before - * @slot create:after - * @slot provider:before - * @slot provider:after - * @slot avalara-service-url:before - * @slot avalara-service-url:after - * @slot avalara-id:before - * @slot avalara-id:after - * @slot avalara-key:before - * @slot avalara-key:after - * @slot avalara-company-code:before - * @slot avalara-company-code:after - * @slot avalara-options:before - * @slot avalara-options:after - * @slot avalara-address-validation-countries:before - * @slot avalara-address-validation-countries:after - * @slot avalara-category-to-product-tax-code-mappings:before - * @slot avalara-category-to-product-tax-code-mappings:after - * @slot taxjar-api-token:before - * @slot taxjar-api-token:after - * @slot taxjar-category-to-product-tax-code-mappings:before - * @slot taxjar-category-to-product-tax-code-mappings:after - * @slot taxjar-options:before - * @slot taxjar-options:after - * @slot onesource-service-url:before - * @slot onesource-service-url:after - * @slot onesource-external-company-id:before - * @slot onesource-external-company-id:after - * @slot onesource-calling-system-number:before - * @slot onesource-calling-system-number:after - * @slot onesource-from-city:before - * @slot onesource-from-city:after - * @slot onesource-host-system:before - * @slot onesource-host-system:after - * @slot onesource-company-role:before - * @slot onesource-company-role:after - * @slot onesource-part-number-product-option:before - * @slot onesource-part-number-product-option:after - * @slot onesource-product-order-priority:before - * @slot onesource-product-order-priority:after - * @slot onesource-audit-settings:before - * @slot onesource-audit-settings:after - * @slot webhook-service:before - * @slot webhook-service:after - * @slot webhook-json-title:before - * @slot webhook-json-title:after - * @slot webhook-json-encryption-key:before - * @slot webhook-json-encryption-key:after - * @slot webhook-json-url:before - * @slot webhook-json-url:after - * @slot webhook-json-events:before - * @slot webhook-json-events:after - * @slot webhook-legacy-xml-title:before - * @slot webhook-legacy-xml-title:after - * @slot webhook-legacy-xml-url:before - * @slot webhook-legacy-xml-url:after - * @slot webflow-site-id:before - * @slot webflow-site-id:after - * @slot webflow-site-name:before - * @slot webflow-site-name:after - * @slot webflow-collection-id:before - * @slot webflow-collection-id:after - * @slot webflow-collection-name:before - * @slot webflow-collection-name:after - * @slot webflow-sku-field-id:before - * @slot webflow-sku-field-id:after - * @slot webflow-sku-field-name:before - * @slot webflow-sku-field-name:after - * @slot webflow-inventory-field-id:before - * @slot webflow-inventory-field-id:after - * @slot webflow-inventory-field-name:before - * @slot webflow-inventory-field-name:after - * @slot webflow-auth:before - * @slot webflow-auth:after - * @slot zapier-event:before - * @slot zapier-event:after - * @slot zapier-url:before - * @slot zapier-url:after - * * @element foxy-native-integration-form * @since 1.25.0 */ @@ -218,8 +135,6 @@ export class NativeIntegrationForm extends Base { ]; } - templates: Templates = {}; - private readonly __createConfigGetterFor = memoize((key: string) => { return () => this.__config?.[key]; }); @@ -241,7 +156,6 @@ export class NativeIntegrationForm extends Base { { value: 'avalara', label: 'option_avalara' }, { value: 'onesource', label: 'option_onesource' }, { value: 'taxjar', label: 'option_taxjar' }, - { value: 'webflow', label: 'option_webflow' }, ]; private readonly __avalaraConfigOptions: Option[] = [ @@ -361,18 +275,23 @@ export class NativeIntegrationForm extends Base { return new BooleanSelector(match.join(' ').trim()); } + get headerTitleOptions(): Record { + return { + context: this.data ? `existing_${this.data.provider}` : 'new', + id: this.headerCopyIdValue, + }; + } + renderBody(): TemplateResult { const provider = this.form.provider ?? 'avalara'; return html` + ${this.renderHeader()} ${this.href - ? provider === 'webhook' - ? '' - : html`` + ? '' : html` ; - -export type Templates = { - 'timestamps:before'?: Renderer; - 'timestamps:after'?: Renderer; - 'delete:before'?: Renderer; - 'delete:after'?: Renderer; - 'create:before'?: Renderer; - 'create:after'?: Renderer; - 'provider:before'?: Renderer; - 'provider:after'?: Renderer; - 'avalara-service-url:before'?: Renderer; - 'avalara-service-url:after'?: Renderer; - 'avalara-id:before'?: Renderer; - 'avalara-id:after'?: Renderer; - 'avalara-key:before'?: Renderer; - 'avalara-key:after'?: Renderer; - 'avalara-company-code:before'?: Renderer; - 'avalara-company-code:after'?: Renderer; - 'avalara-options:before'?: Renderer; - 'avalara-options:after'?: Renderer; - 'avalara-address-validation-countries:before'?: Renderer; - 'avalara-address-validation-countries:after'?: Renderer; - 'avalara-category-to-product-tax-code-mappings:before'?: Renderer; - 'avalara-category-to-product-tax-code-mappings:after'?: Renderer; - 'taxjar-api-token:before'?: Renderer; - 'taxjar-api-token:after'?: Renderer; - 'taxjar-category-to-product-tax-code-mappings:before'?: Renderer; - 'taxjar-category-to-product-tax-code-mappings:after'?: Renderer; - 'taxjar-options:before'?: Renderer; - 'taxjar-options:after'?: Renderer; - 'onesource-service-url:before'?: Renderer; - 'onesource-service-url:after'?: Renderer; - 'onesource-external-company-id:before'?: Renderer; - 'onesource-external-company-id:after'?: Renderer; - 'onesource-calling-system-number:before'?: Renderer; - 'onesource-calling-system-number:after'?: Renderer; - 'onesource-from-city:before'?: Renderer; - 'onesource-from-city:after'?: Renderer; - 'onesource-host-system:before'?: Renderer; - 'onesource-host-system:after'?: Renderer; - 'onesource-company-role:before'?: Renderer; - 'onesource-company-role:after'?: Renderer; - 'onesource-part-number-product-option:before'?: Renderer; - 'onesource-part-number-product-option:after'?: Renderer; - 'onesource-product-order-priority:before'?: Renderer; - 'onesource-product-order-priority:after'?: Renderer; - 'onesource-audit-settings:before'?: Renderer; - 'onesource-audit-settings:after'?: Renderer; - 'webhook-service:before'?: Renderer; - 'webhook-service:after'?: Renderer; - 'webhook-json-title:before'?: Renderer; - 'webhook-json-title:after'?: Renderer; - 'webhook-json-encryption-key:before'?: Renderer; - 'webhook-json-encryption-key:after'?: Renderer; - 'webhook-json-url:before'?: Renderer; - 'webhook-json-url:after'?: Renderer; - 'webhook-json-events:before'?: Renderer; - 'webhook-json-events:after'?: Renderer; - 'webhook-legacy-xml-title:before'?: Renderer; - 'webhook-legacy-xml-title:after'?: Renderer; - 'webhook-legacy-xml-url:before'?: Renderer; - 'webhook-legacy-xml-url:after'?: Renderer; - 'webflow-site-id:before'?: Renderer; - 'webflow-site-id:after'?: Renderer; - 'webflow-site-name:before'?: Renderer; - 'webflow-site-name:after'?: Renderer; - 'webflow-collection-id:before'?: Renderer; - 'webflow-collection-id:after'?: Renderer; - 'webflow-collection-name:before'?: Renderer; - 'webflow-collection-name:after'?: Renderer; - 'webflow-sku-field-id:before'?: Renderer; - 'webflow-sku-field-id:after'?: Renderer; - 'webflow-sku-field-name:before'?: Renderer; - 'webflow-sku-field-name:after'?: Renderer; - 'webflow-inventory-field-id:before'?: Renderer; - 'webflow-inventory-field-id:after'?: Renderer; - 'webflow-inventory-field-name:before'?: Renderer; - 'webflow-inventory-field-name:after'?: Renderer; - 'webflow-auth:before'?: Renderer; - 'webflow-auth:after'?: Renderer; - 'zapier-events:before'?: Renderer; - 'zapier-events:after'?: Renderer; - 'zapier-url:before'?: Renderer; - 'zapier-url:after'?: Renderer; - 'apple-pay-merchant-id:before'?: Renderer; - 'apple-pay-merchant-id:after'?: Renderer; - 'custom-tax-url:before'?: Renderer; - 'custom-tax-url:after'?: Renderer; -}; diff --git a/src/elements/public/NucleonElement/NucleonElement.ts b/src/elements/public/NucleonElement/NucleonElement.ts index b8faf620a..8cb61581b 100644 --- a/src/elements/public/NucleonElement/NucleonElement.ts +++ b/src/elements/public/NucleonElement/NucleonElement.ts @@ -150,7 +150,7 @@ export class NucleonElement extends InferrableMix * @since 1.4.0 */ get failure(): Response | null { - return this.__service.state.context.failure; + return this.__service.state?.context.failure ?? null; } /** @@ -160,7 +160,7 @@ export class NucleonElement extends InferrableMix * not guaranteed to work. NucleonElement does not provide a way to override validity status. */ get errors(): string[] { - return this.__service.state.context.errors; + return this.__service.state?.context.errors ?? []; } /** @@ -171,7 +171,7 @@ export class NucleonElement extends InferrableMix * If you need to replace the entire data object, consider using `element.data`. */ get form(): Partial { - const { data, edits } = this.__service.state.context; + const { data, edits } = this.__service.state?.context ?? {}; return { ...data, ...edits } as Partial; } @@ -183,7 +183,7 @@ export class NucleonElement extends InferrableMix * If you're processing user input, consider using `element.form` and `element.edit()` instead. */ get data(): TData | null { - return this.__service.state.context.data; + return this.__service.state?.context.data ?? null; } set data(data: TData | null) { @@ -232,7 +232,7 @@ export class NucleonElement extends InferrableMix in['value']>( stateValue: TStateValue ): this is this & ComputedElementProperties { - return this.__service.state.matches(stateValue); + return !!this.__service.state?.matches(stateValue); } /** @@ -431,8 +431,8 @@ export class NucleonElement extends InferrableMix // this getter is used by LitElement to set the "state" attribute private get __state(): string { const state = this.__service.state; - const flags = state.toStrings().reduce((p, c) => [...p, ...c.split('.')], [] as string[]); - return [...new Set(flags)].join(' '); + const flags = state?.toStrings().reduce((p, c) => [...p, ...c.split('.')], [] as string[]); + return [...new Set(flags ?? [])].join(' '); } private __createService() { @@ -563,7 +563,7 @@ export class NucleonElement extends InferrableMix if (method === 'GET') { event.preventDefault(); this.__fetchEventQueue.push(event); - if (!this.__service.state.matches('busy')) this.__processFetchEventQueue(); + if (!this.__service.state?.matches('busy')) this.__processFetchEventQueue(); } } } diff --git a/src/elements/public/PasskeyCard/PasskeyCard.ts b/src/elements/public/PasskeyCard/PasskeyCard.ts index 2ba094be0..d54ee9d5c 100644 --- a/src/elements/public/PasskeyCard/PasskeyCard.ts +++ b/src/elements/public/PasskeyCard/PasskeyCard.ts @@ -13,12 +13,6 @@ const Base = TranslatableMixin(TwoLineCard, NS); /** * Basic card displaying a saved passkey. * - * @slot title:before - * @slot title:after - * - * @slot subtitle:before - * @slot subtitle:after - * * @element foxy-passkey-card * @since 1.24.0 */ diff --git a/src/elements/public/PasskeyCard/types.ts b/src/elements/public/PasskeyCard/types.ts index 0a66f4153..11320d6c3 100644 --- a/src/elements/public/PasskeyCard/types.ts +++ b/src/elements/public/PasskeyCard/types.ts @@ -4,8 +4,6 @@ import type { } from '@foxy.io/sdk/dist/types/core/defaults'; import type { Graph, Resource } from '@foxy.io/sdk/core'; -import type { PasskeyCard } from './PasskeyCard'; -import type { Renderer } from '../../../mixins/configurable'; import type { Rels } from '@foxy.io/sdk/backend'; export interface Passkeys extends Graph { @@ -32,10 +30,3 @@ export interface Passkey extends Graph { } export type Data = Resource; - -export type Templates = { - 'title:before'?: Renderer; - 'title:after'?: Renderer; - 'subtitle:before'?: Renderer; - 'subtitle:after'?: Renderer; -}; diff --git a/src/elements/public/PasskeyForm/PasskeyForm.stories.ts b/src/elements/public/PasskeyForm/PasskeyForm.stories.ts index 16da31fcd..1e9319ddc 100644 --- a/src/elements/public/PasskeyForm/PasskeyForm.stories.ts +++ b/src/elements/public/PasskeyForm/PasskeyForm.stories.ts @@ -11,9 +11,9 @@ const summary: Summary = { localName: 'foxy-passkey-form', translatable: true, configurable: { - sections: ['timestamps'], - buttons: ['create', 'delete'], - inputs: [], + sections: ['timestamps', 'header'], + buttons: ['delete', 'create', 'submit', 'undo', 'header:copy-id', 'header:copy-json'], + inputs: ['credential-id', 'last-login-ua'], }, }; diff --git a/src/elements/public/PasskeyForm/PasskeyForm.test.ts b/src/elements/public/PasskeyForm/PasskeyForm.test.ts index 25bbffcf8..03d1e0a32 100644 --- a/src/elements/public/PasskeyForm/PasskeyForm.test.ts +++ b/src/elements/public/PasskeyForm/PasskeyForm.test.ts @@ -3,6 +3,7 @@ import './index'; import { html, expect, fixture } from '@open-wc/testing'; import { PasskeyForm as Form } from './PasskeyForm'; import { getTestData } from '../../../testgen/getTestData'; +import { stub } from 'sinon'; describe('passkeyForm', () => { it('imports and defines foxy-internal-text-area-control', () => { @@ -34,21 +35,20 @@ describe('passkeyForm', () => { expect(new Form()).to.have.property('ns', 'passkey-form'); }); - it('renders a foxy-internal-text-control for credential id', async () => { - const element = await fixture(html``); - element.data = await getTestData('./hapi/passkeys/0'); - await element.requestUpdate(); - - const control = element.renderRoot.querySelector('[infer="credential-id"]'); - expect(control).to.be.instanceOf(customElements.get('foxy-internal-text-control')); + it('renders a form header', async () => { + const form = new Form(); + const renderHeaderMethod = stub(form, 'renderHeader'); + form.data = await getTestData('./hapi/passkeys/0'); + form.render(); + expect(renderHeaderMethod).to.have.been.called; }); - it('renders a foxy-internal-text-control for last login date', async () => { + it('renders a foxy-internal-text-control for credential id', async () => { const element = await fixture(html``); element.data = await getTestData('./hapi/passkeys/0'); await element.requestUpdate(); - const control = element.renderRoot.querySelector('[infer="last-login-date"]'); + const control = element.renderRoot.querySelector('[infer="credential-id"]'); expect(control).to.be.instanceOf(customElements.get('foxy-internal-text-control')); }); diff --git a/src/elements/public/PasskeyForm/PasskeyForm.ts b/src/elements/public/PasskeyForm/PasskeyForm.ts index d45ed1141..e1a6d6e1f 100644 --- a/src/elements/public/PasskeyForm/PasskeyForm.ts +++ b/src/elements/public/PasskeyForm/PasskeyForm.ts @@ -3,9 +3,9 @@ import type { Data } from './types'; import { TranslatableMixin } from '../../../mixins/translatable'; import { ResponsiveMixin } from '../../../mixins/responsive'; +import { BooleanSelector } from '@foxy.io/sdk/core'; import { InternalForm } from '../../internal/InternalForm/InternalForm'; import { html } from 'lit-element'; -import { BooleanSelector } from '@foxy.io/sdk/core'; const NS = 'passkey-form'; const Base = ResponsiveMixin(TranslatableMixin(InternalForm, NS)); @@ -13,24 +13,6 @@ const Base = ResponsiveMixin(TranslatableMixin(InternalForm, NS)); /** * Form element for viewing and deleting passkeys (`fx:passkey`). * - * @slot credential-id:before - * @slot credential-id:after - * - * @slot last-login-date:before - * @slot last-login-date:after - * - * @slot last-login-ua:before - * @slot last-login-ua:after - * - * @slot timestamps:before - * @slot timestamps:after - * - * @slot create:before - * @slot create:after - * - * @slot delete:before - * @slot delete:after - * * @element foxy-passkey-form * @since 1.24.0 */ @@ -51,8 +33,8 @@ export class PasskeyForm extends Base { } return html` + ${this.renderHeader()} - ${super.renderBody()} `; diff --git a/src/elements/public/PasskeyForm/types.ts b/src/elements/public/PasskeyForm/types.ts index 0c99366c7..9b8c8c02e 100644 --- a/src/elements/public/PasskeyForm/types.ts +++ b/src/elements/public/PasskeyForm/types.ts @@ -1,19 +1 @@ -import type { PasskeyForm } from './PasskeyForm'; -import type { Renderer } from '../../../mixins/configurable'; - export type { Data } from '../PasskeyCard/types'; - -export type Templates = { - 'credential-id:before'?: Renderer; - 'credential-id:after'?: Renderer; - 'last-login-date:before'?: Renderer; - 'last-login-date:after'?: Renderer; - 'last-login-ua:before'?: Renderer; - 'last-login-ua:after'?: Renderer; - 'timestamps:before'?: Renderer; - 'timestamps:after'?: Renderer; - 'create:before'?: Renderer; - 'create:after'?: Renderer; - 'delete:before'?: Renderer; - 'delete:after'?: Renderer; -}; diff --git a/src/elements/public/PaymentCardEmbed/PaymentCardEmbed.stories.mdx b/src/elements/public/PaymentCardEmbed/PaymentCardEmbed.stories.mdx index e3af2697e..db7782afc 100644 --- a/src/elements/public/PaymentCardEmbed/PaymentCardEmbed.stories.mdx +++ b/src/elements/public/PaymentCardEmbed/PaymentCardEmbed.stories.mdx @@ -15,8 +15,13 @@ PaymentCardEmbed is a custom element wrapper for the `SDK.Customer.PaymentCardEm + `} isExpanded > @@ -280,3 +285,9 @@ The element supports a demo mode that allows you to see how it works without set - Default form: `https://embed.foxy.io/v1.html?demo=default` - Stripe Card: `https://embed.foxy.io/v1.html?demo=stripe` - Square Card: `https://embed.foxy.io/v1.html?demo=square` + +## Note about Maestro cards + +Stripe and Square mark all Maestro cards as Mastercard. To avoid ambiguity, we require store admins to enable both Maestro and Mastercard in store settings to accept either card type in the embed via the `stripe_connect` or `square_up` gateways. + +We'd also like to take this opportunity to remind you that [Maestro cards are being phased out](https://www.mastercard.com/news/europe/en/perspectives/en/2021/blog-from-valerie-nowak-why-this-maestro-is-retiring-after-30-years). If this is the only card brand you accept, we recommend updating your store settings to make sure your customers can still pay for your products and services in the future. Until then, you can use any other supported payment gateway with the Payment Card Embed element. diff --git a/src/elements/public/PaymentMethodCard/PaymentMethodCard.ts b/src/elements/public/PaymentMethodCard/PaymentMethodCard.ts index f3873e7a5..cf9ddbee0 100644 --- a/src/elements/public/PaymentMethodCard/PaymentMethodCard.ts +++ b/src/elements/public/PaymentMethodCard/PaymentMethodCard.ts @@ -1,5 +1,5 @@ import type { CSSResultArray, PropertyDeclarations } from 'lit-element'; -import type { Data, Templates } from './types'; +import type { Data } from './types'; import type { DialogHideEvent } from '../../private/Dialog/DialogHideEvent'; import type { TemplateResult } from 'lit-html'; import type { FormDialog } from '../FormDialog/FormDialog'; @@ -23,13 +23,6 @@ const Base = ThemeableMixin(ConfigurableMixin(TranslatableMixin(NucleonElement, /** * Basic card displaying a payment method. * - * @slot actions:before - **new in v1.4.0** - * @slot actions:after - **new in v1.4.0** - * @slot actions:delete:before - **new in v1.4.0** - * @slot actions:delete:after - **new in v1.4.0** - * @slot actions:update:before - **new in v1.27.0** - * @slot actions:update:after - **new in v1.27.0** - * * @element foxy-payment-method-card * @since 1.2.0 */ @@ -63,8 +56,6 @@ export class PaymentMethodCard extends Base { ]; } - templates: Templates = {}; - /** * Configuration URL for the Payment Card Embed. If provided, * the card will have an option of updating payment method. diff --git a/src/elements/public/PaymentMethodCard/types.ts b/src/elements/public/PaymentMethodCard/types.ts index 313ac0e01..408823ac8 100644 --- a/src/elements/public/PaymentMethodCard/types.ts +++ b/src/elements/public/PaymentMethodCard/types.ts @@ -1,12 +1,5 @@ -import * as FoxySDK from '@foxy.io/sdk'; -import { Renderer } from '../../../mixins/configurable'; -import { PaymentMethodCard } from './PaymentMethodCard'; +import type { Resource } from '@foxy.io/sdk/core'; +import type { Rels } from '@foxy.io/sdk/backend'; -export type Rel = FoxySDK.Backend.Rels.DefaultPaymentMethod; -export type Data = FoxySDK.Core.Resource; -export type Templates = { - 'actions:before'?: Renderer; - 'actions:after'?: Renderer; - 'actions:delete:before'?: Renderer; - 'actions:delete:after'?: Renderer; -}; +export type Rel = Rels.DefaultPaymentMethod; +export type Data = Resource; diff --git a/src/elements/public/PaymentsApiFraudProtectionCard/PaymentsApiFraudProtectionCard.ts b/src/elements/public/PaymentsApiFraudProtectionCard/PaymentsApiFraudProtectionCard.ts index 48496a001..751aaf53a 100644 --- a/src/elements/public/PaymentsApiFraudProtectionCard/PaymentsApiFraudProtectionCard.ts +++ b/src/elements/public/PaymentsApiFraudProtectionCard/PaymentsApiFraudProtectionCard.ts @@ -17,12 +17,6 @@ const Base = TranslatableMixin(TwoLineCard, NS); * that is currently a bit quirky due to the legacy functionality. To use * this element with hAPI, wrap it into a foxy-payments-api node._ * - * @slot title:before - * @slot title:after - * - * @slot subtitle:before - * @slot subtitle:after - * * @element foxy-payments-api-fraud-protection-card * @since 1.21.0 */ diff --git a/src/elements/public/PaymentsApiFraudProtectionForm/PaymentsApiFraudProtectionForm.stories.ts b/src/elements/public/PaymentsApiFraudProtectionForm/PaymentsApiFraudProtectionForm.stories.ts index 996486ade..ac30330d3 100644 --- a/src/elements/public/PaymentsApiFraudProtectionForm/PaymentsApiFraudProtectionForm.stories.ts +++ b/src/elements/public/PaymentsApiFraudProtectionForm/PaymentsApiFraudProtectionForm.stories.ts @@ -15,8 +15,8 @@ const summary: Summary = { localName: 'foxy-payments-api-fraud-protection-form', translatable: true, configurable: { - sections: ['timestamps'], - buttons: ['create', 'delete'], + sections: ['timestamps', 'header'], + buttons: ['delete', 'create', 'submit', 'undo', 'header:copy-id', 'header:copy-json'], inputs: ['description', 'score-threshold-reject'], }, }; diff --git a/src/elements/public/PaymentsApiFraudProtectionForm/PaymentsApiFraudProtectionForm.test.ts b/src/elements/public/PaymentsApiFraudProtectionForm/PaymentsApiFraudProtectionForm.test.ts index 824e291be..13d76f7f5 100644 --- a/src/elements/public/PaymentsApiFraudProtectionForm/PaymentsApiFraudProtectionForm.test.ts +++ b/src/elements/public/PaymentsApiFraudProtectionForm/PaymentsApiFraudProtectionForm.test.ts @@ -17,6 +17,7 @@ import { getByTestId } from '../../../testgen/getByTestId'; import { getByTag } from '../../../testgen/getByTag'; import { getByKey } from '../../../testgen/getByKey'; import { I18n } from '../I18n/I18n'; +import { stub } from 'sinon'; describe('PaymentsApiFraudProtectionForm', () => { const OriginalResizeObserver = window.ResizeObserver; @@ -175,6 +176,54 @@ describe('PaymentsApiFraudProtectionForm', () => { expect(form.errors).to.not.include('json:v8n_invalid'); }); + it('renders a form header', async () => { + const form = new Form(); + const renderHeaderMethod = stub(form, 'renderHeader'); + form.render(); + expect(renderHeaderMethod).to.have.been.called; + }); + + it('always hides Copy JSON button in the header', () => { + const form = new Form(); + expect(form.hiddenSelector.matches('header:copy-json', true)).to.be.true; + }); + + it('uses custom options for form header title', () => { + const form = new Form(); + expect(form.headerTitleOptions).to.deep.equal({ context: 'new' }); + + form.edit({ type: 'minfraud' }); + expect(form.headerTitleOptions).to.deep.equal({ context: 'minfraud' }); + }); + + it('uses custom options for form header subtitle', async () => { + const router = createRouter(); + + const wrapper = await fixture(html` +
router.handleEvent(evt)}> + + + + +
+ `); + + const element = wrapper.firstElementChild!.firstElementChild as Form; + await waitUntil(() => !!element.data, '', { timeout: 5000 }); + + expect(element.headerSubtitleOptions).to.deep.equal({ id: element.headerCopyIdValue }); + }); + it('renders a fraud protection selector when "type" is not present in form', async () => { const availableProtections: AvailableFraudProtections = { _links: { @@ -209,7 +258,7 @@ describe('PaymentsApiFraudProtectionForm', () => { > `https://example.com/${type}.png`} + .getImageSrc=${(type: string) => `https://example.com?${type}`} @fetch=${(evt: FetchEvent) => { if (evt.request.url.endsWith('/payment_presets/0/available_fraud_protections')) { evt.preventDefault(); @@ -225,35 +274,29 @@ describe('PaymentsApiFraudProtectionForm', () => { `); const element = wrapper.firstElementChild!.firstElementChild as Form; - const title = (await getByKey(element, 'select_protection_title')) as I18n; const listWrapper = (await getByTestId(element, 'select-protection-list')) as HTMLElement; - expect(title).to.exist; - expect(title).to.have.attribute('infer', ''); - - await waitUntil(() => !!listWrapper.querySelector('li'), '', { timeout: 5000 }); - const list = listWrapper.querySelector('ul') as HTMLElement; - const items = list.querySelectorAll('li'); + await waitUntil(() => !!listWrapper.querySelector('button'), '', { timeout: 5000 }); + const items = listWrapper.querySelectorAll('button'); expect(listWrapper).to.exist; - expect(list).to.exist; expect(items).to.have.length(2); - const item0Button = items[0].querySelector('button') as HTMLButtonElement; - const item1Button = items[1].querySelector('button') as HTMLButtonElement; + const item0Button = items[0] as HTMLButtonElement; + const item1Button = items[1] as HTMLButtonElement; expect(item0Button).to.exist; expect(item0Button).to.include.text('Minfraud'); expect(await getByTag(item0Button, 'img')).to.have.attribute( 'src', - 'https://example.com/minfraud.png' + 'https://example.com?minfraud' ); expect(item1Button).to.exist; expect(item1Button).to.include.text('Google reCaptcha'); expect(await getByTag(item1Button, 'img')).to.have.attribute( 'src', - 'https://example.com/google_recaptcha.png' + 'https://example.com?google_recaptcha' ); item0Button.click(); @@ -264,40 +307,6 @@ describe('PaymentsApiFraudProtectionForm', () => { expect(await getByTestId(element, 'select-method-list')).to.not.exist; }); - it('renders a fraud protection logo and name when "type" is selected', async () => { - const router = createRouter(); - - const wrapper = await fixture(html` -
router.handleEvent(evt)}> - - `https://example.com/${type}.png`} - > - - -
- `); - - const element = wrapper.firstElementChild!.firstElementChild as Form; - await waitUntil(() => !!element.data, '', { timeout: 5000 }); - - const figure = (await getByTestId(element, 'logo')) as HTMLElement; - const img = (await getByTag(figure, 'img')) as HTMLImageElement; - const caption = (await getByTag(figure, 'figcaption')) as HTMLElement; - - expect(img).to.have.attribute('src', `https://example.com/${element.form.type}.png`); - expect(caption).to.include.text(element.form.helper!.name); - }); - it('renders a checkbox control for a "checkbox" block in json if present', async () => { const router = createRouter(); diff --git a/src/elements/public/PaymentsApiFraudProtectionForm/PaymentsApiFraudProtectionForm.ts b/src/elements/public/PaymentsApiFraudProtectionForm/PaymentsApiFraudProtectionForm.ts index cd05f3dbc..4c0a76e4a 100644 --- a/src/elements/public/PaymentsApiFraudProtectionForm/PaymentsApiFraudProtectionForm.ts +++ b/src/elements/public/PaymentsApiFraudProtectionForm/PaymentsApiFraudProtectionForm.ts @@ -1,11 +1,12 @@ -import type { AvailableFraudProtections } from '../PaymentsApi/api/types'; -import type { Templates, Block, Data } from './types'; +import type { AvailableFraudProtections, FraudProtection } from '../PaymentsApi/api/types'; +import type { Block, Data } from './types'; import type { PropertyDeclarations } from 'lit-element'; import type { NucleonElement } from '../NucleonElement/NucleonElement'; import type { TemplateResult } from 'lit-html'; import type { NucleonV8N } from '../NucleonElement/types'; import { TranslatableMixin } from '../../../mixins/translatable'; +import { BooleanSelector } from '@foxy.io/sdk/core'; import { InternalForm } from '../../internal/InternalForm/InternalForm'; import { ifDefined } from 'lit-html/directives/if-defined'; import { html } from 'lit-html'; @@ -25,24 +26,6 @@ const Base = TranslatableMixin(InternalForm, NS); * that is currently a bit quirky due to the legacy functionality. To use * this element with hAPI, wrap it into a foxy-payments-api node._ * - * @slot description:before - * @slot description:after - * - * @slot score-threshold-reject:before - * @slot score-threshold-reject:after - * - * @slot json-[field-name-in-kebab-case]:before - * @slot json-[field-name-in-kebab-case]:after - * - * @slot timestamps:before - * @slot timestamps:after - * - * @slot create:before - * @slot create:after - * - * @slot delete:before - * @slot delete:after - * * @element foxy-payments-api-fraud-protection-form * @since 1.21.0 */ @@ -98,14 +81,42 @@ export class PaymentsApiFraudProtectionForm extends Base { /** A function that returns a URL of a fraud protection icon based on the given type. */ getImageSrc: ((type: string) => string) | null = null; - /** Template render functions mapped to their name. */ - templates: Templates = {}; - private readonly __availableFraudProtectionsLoaderId = 'availableFraudProtections'; + get hiddenSelector(): BooleanSelector { + return new BooleanSelector(`header:copy-json ${super.hiddenSelector}`.trimEnd()); + } + + get headerTitleOptions(): Record { + return { ...this.data, context: this.form.type ?? 'new' }; + } + + get headerSubtitleOptions(): Record { + return { id: this.headerCopyIdValue }; + } + + renderHeader(...params: Parameters['renderHeader']>): TemplateResult { + return html` +
+ ${super.renderHeader(...params)} + ${this.data?.type || !this.form.type + ? html`` + : html` + this.undo()} + > + + + `} +
+ `; + } + renderBody(): TemplateResult { return this.form.type - ? this.__renderFraudProtectionConfig(this.form.type) + ? this.__renderFraudProtectionConfig() : this.__renderFraudProtectionSelector(); } @@ -135,9 +146,15 @@ export class PaymentsApiFraudProtectionForm extends Base { } private __renderFraudProtectionSelector() { - const defaultSrc = PaymentsApiFraudProtectionForm.defaultImageSrc; - return html` + ${this.renderHeader()} + +
+ ${Object.entries(this.__availableFraudProtections ?? {}).map(([type, helper]) => { + return this.__renderFraudProtectionButton({ type, helper } as FraudProtection); + })} +
+ - - - - -
-
    - ${Object.entries(this.__availableFraudProtections ?? {}).map(([type, helper]) => { - return html` -
  • - -
  • - `; - })} -
-
`; } - private __renderFraudProtectionConfig(type: string) { + private __renderFraudProtectionButton({ type, helper }: FraudProtection) { const defaultSrc = PaymentsApiFraudProtectionForm.defaultImageSrc; + const src = this.getImageSrc?.(type) ?? defaultSrc; + const onError = (evt: Event) => ((evt.currentTarget as HTMLImageElement).src = defaultSrc); return html` -
+
+
+ + +
+
${helper.name}​
+
${type}
+
+
+ + `; + } + private __renderFraudProtectionConfig() { + return html` + ${this.renderHeader()} ${this.form.helper?.uses_rejection_threshold ? html` @@ -211,17 +212,6 @@ export class PaymentsApiFraudProtectionForm extends Base { ` : ''} ${this.form.helper?.json?.blocks.map(block => this.__renderBlock(block))} - ${this.data?.type - ? '' - : html` - this.undo()} - > - - - `} ${super.renderBody()} `; } diff --git a/src/elements/public/PaymentsApiFraudProtectionForm/types.ts b/src/elements/public/PaymentsApiFraudProtectionForm/types.ts index 62550785b..5a6695c92 100644 --- a/src/elements/public/PaymentsApiFraudProtectionForm/types.ts +++ b/src/elements/public/PaymentsApiFraudProtectionForm/types.ts @@ -1,20 +1,4 @@ -import type { PaymentsApiFraudProtectionForm } from './PaymentsApiFraudProtectionForm'; import type { FraudProtection } from '../PaymentsApi/api/types'; -import type { Renderer } from '../../../mixins/configurable'; export type Data = FraudProtection; export type Block = NonNullable['blocks'][number]; -export type Templates = { - 'description:before'?: Renderer; - 'description:after'?: Renderer; - 'score-threshold-reject:before'?: Renderer; - 'score-threshold-reject:after'?: Renderer; - 'timestamps:before'?: Renderer; - 'timestamps:after'?: Renderer; - 'create:before'?: Renderer; - 'create:after'?: Renderer; - 'delete:before'?: Renderer; - 'delete:after'?: Renderer; - - [key: string]: Renderer | undefined; -}; diff --git a/src/elements/public/PaymentsApiPaymentMethodCard/PaymentsApiPaymentMethodCard.ts b/src/elements/public/PaymentsApiPaymentMethodCard/PaymentsApiPaymentMethodCard.ts index d16c544d3..7c8a6a4de 100644 --- a/src/elements/public/PaymentsApiPaymentMethodCard/PaymentsApiPaymentMethodCard.ts +++ b/src/elements/public/PaymentsApiPaymentMethodCard/PaymentsApiPaymentMethodCard.ts @@ -17,12 +17,6 @@ const Base = TranslatableMixin(TwoLineCard, NS); * that is currently a bit quirky due to the legacy functionality. To use * this element with hAPI, wrap it into a foxy-payments-api node._ * - * @slot title:before - * @slot title:after - * - * @slot subtitle:before - * @slot subtitle:after - * * @element foxy-payments-api-payment-method-card * @since 1.21.0 */ diff --git a/src/elements/public/PaymentsApiPaymentMethodForm/PaymentsApiPaymentMethodForm.stories.ts b/src/elements/public/PaymentsApiPaymentMethodForm/PaymentsApiPaymentMethodForm.stories.ts index c40459c64..b2f0367c1 100644 --- a/src/elements/public/PaymentsApiPaymentMethodForm/PaymentsApiPaymentMethodForm.stories.ts +++ b/src/elements/public/PaymentsApiPaymentMethodForm/PaymentsApiPaymentMethodForm.stories.ts @@ -15,8 +15,8 @@ const summary: Summary = { localName: 'foxy-payments-api-payment-method-form', translatable: true, configurable: { - sections: ['timestamps'], - buttons: ['create', 'delete'], + sections: ['timestamps', 'header'], + buttons: ['delete', 'create', 'submit', 'undo', 'header:copy-id', 'header:copy-json'], inputs: [ 'description', 'account-id', diff --git a/src/elements/public/PaymentsApiPaymentMethodForm/PaymentsApiPaymentMethodForm.test.ts b/src/elements/public/PaymentsApiPaymentMethodForm/PaymentsApiPaymentMethodForm.test.ts index a6da4eb49..15ef78ad0 100644 --- a/src/elements/public/PaymentsApiPaymentMethodForm/PaymentsApiPaymentMethodForm.test.ts +++ b/src/elements/public/PaymentsApiPaymentMethodForm/PaymentsApiPaymentMethodForm.test.ts @@ -18,6 +18,7 @@ import { getByKey } from '../../../testgen/getByKey'; import { I18n } from '../I18n/I18n'; import { AvailablePaymentMethods } from '../PaymentsApi/api/types'; import { getByTag } from '../../../testgen/getByTag'; +import { stub } from 'sinon'; describe('PaymentsApiPaymentMethodForm', () => { const OriginalResizeObserver = window.ResizeObserver; @@ -193,6 +194,65 @@ describe('PaymentsApiPaymentMethodForm', () => { expect(form.errors).to.not.include('additional-fields:v8n_invalid'); }); + it('renders a form header', async () => { + const form = new Form(); + const renderHeaderMethod = stub(form, 'renderHeader'); + form.render(); + expect(renderHeaderMethod).to.have.been.called; + }); + + it('always hides Copy JSON button in the header', () => { + const form = new Form(); + expect(form.hiddenSelector.matches('header:copy-json', true)).to.be.true; + }); + + it('uses custom options for form header title', () => { + const form = new Form(); + + expect(form.headerTitleOptions).to.deep.equal({ context: 'new', name: undefined }); + + form.edit({ + type: 'bar_one', + helper: { + name: 'Bar One', + test_id: '', + test_key: '', + test_third_party_key: '', + third_party_key_description: '', + id_description: '', + key_description: '', + supports_3d_secure: 0, + supports_auth_only: 0, + is_deprecated: false, + additional_fields: null, + }, + }); + + expect(form.headerTitleOptions).to.deep.equal({ context: 'selected', name: 'Bar One' }); + }); + + it('uses custom options for form header subtitle', () => { + const form = new Form(); + expect(form.headerSubtitleOptions).to.deep.equal({}); + + form.href = 'https://foxy-payments-api.element/payment_presets/0/payment_methods/R0'; + expect(form.headerSubtitleOptions).to.deep.equal({ context: 'regular', id: '0' }); + + form.href = 'https://foxy-payments-api.element/payment_presets/0/payment_methods/H1C2'; + expect(form.headerSubtitleOptions).to.deep.equal({ context: 'hosted', id: '1' }); + }); + + it('uses custom Copy ID value', () => { + const form = new Form(); + expect(form.headerCopyIdValue).to.equal(''); + + form.href = 'https://foxy-payments-api.element/payment_presets/0/payment_methods/R0'; + expect(form.headerCopyIdValue).to.equal('0'); + + form.href = 'https://foxy-payments-api.element/payment_presets/0/payment_methods/H1C2'; + expect(form.headerCopyIdValue).to.equal('1'); + }); + it('renders a payment method selector when "type" is not present in form', async () => { const availableMethods: AvailablePaymentMethods = { _links: { @@ -271,13 +331,13 @@ describe('PaymentsApiPaymentMethodForm', () => { `); const element = wrapper.firstElementChild!.firstElementChild as Form; - const title = (await getByKey(element, 'select_method_title')) as I18n; - const list = (await getByTestId(element, 'select-method-list')) as HTMLElement; - - expect(title).to.exist; - expect(title).to.have.attribute('infer', ''); + await waitUntil( + () => !!element.renderRoot.querySelector('[data-testid="select-method-list"]'), + '', + { timeout: 5000 } + ); - await waitUntil(() => !!list.querySelector('li'), '', { timeout: 5000 }); + const list = (await getByTestId(element, 'select-method-list')) as HTMLElement; const groups = list.querySelectorAll('ul'); const headers = list.querySelectorAll('p'); @@ -411,13 +471,13 @@ describe('PaymentsApiPaymentMethodForm', () => { `); const element = wrapper.firstElementChild!.firstElementChild as Form; - const title = (await getByKey(element, 'select_method_title')) as I18n; - const list = (await getByTestId(element, 'select-method-list')) as HTMLElement; - - expect(title).to.exist; - expect(title).to.have.attribute('infer', ''); + await waitUntil( + () => !!element.renderRoot.querySelector('[data-testid="select-method-list"]'), + '', + { timeout: 5000 } + ); - await waitUntil(() => !!list.querySelector('li'), '', { timeout: 5000 }); + const list = (await getByTestId(element, 'select-method-list')) as HTMLElement; const groups = list.querySelectorAll('ul'); const headers = list.querySelectorAll('p'); @@ -443,40 +503,6 @@ describe('PaymentsApiPaymentMethodForm', () => { expect(group1Item1Button).to.not.exist; }); - it('renders a payment method logo and name when "type" is selected', async () => { - const router = createRouter(); - - const wrapper = await fixture(html` -
router.handleEvent(evt)}> - - `https://example.com/${type}.png`} - > - - -
- `); - - const element = wrapper.firstElementChild!.firstElementChild as Form; - await waitUntil(() => !!element.data, '', { timeout: 5000 }); - - const figure = (await getByTestId(element, 'logo')) as HTMLElement; - const img = (await getByTag(figure, 'img')) as HTMLImageElement; - const caption = (await getByTag(figure, 'figcaption')) as HTMLElement; - - expect(img).to.have.attribute('src', `https://example.com/${element.form.type}.png`); - expect(caption).to.include.text(element.form.helper!.name); - }); - it('renders tabs for live and test credentials', async () => { const router = createRouter(); diff --git a/src/elements/public/PaymentsApiPaymentMethodForm/PaymentsApiPaymentMethodForm.ts b/src/elements/public/PaymentsApiPaymentMethodForm/PaymentsApiPaymentMethodForm.ts index c9cdaea2c..56683ccd5 100644 --- a/src/elements/public/PaymentsApiPaymentMethodForm/PaymentsApiPaymentMethodForm.ts +++ b/src/elements/public/PaymentsApiPaymentMethodForm/PaymentsApiPaymentMethodForm.ts @@ -1,11 +1,12 @@ import type { AvailablePaymentMethods } from '../PaymentsApi/api/types'; -import type { Templates, Block, Data } from './types'; +import type { Block, Data } from './types'; import type { PropertyDeclarations } from 'lit-element'; import type { NucleonElement } from '../NucleonElement/NucleonElement'; import type { TemplateResult } from 'lit-html'; import type { TabsElement } from '@vaadin/vaadin-tabs'; import type { NucleonV8N } from '../NucleonElement/types'; +import { BooleanSelector, getResourceId } from '@foxy.io/sdk/core'; import { TranslatableMixin } from '../../../mixins/translatable'; import { InternalForm } from '../../internal/InternalForm/InternalForm'; import { ifDefined } from 'lit-html/directives/if-defined'; @@ -32,45 +33,6 @@ const Base = TranslatableMixin(InternalForm, NS); * that is currently a bit quirky due to the legacy functionality. To use * this element with hAPI, wrap it into a foxy-payments-api node._ * - * @slot description:before - * @slot description:after - * - * @slot account-id:before - * @slot account-id:after - * - * @slot account-key:before - * @slot account-key:after - * - * @slot third-party-key:before - * @slot third-party-key:after - * - * @slot test-account-id:before - * @slot test-account-id:after - * - * @slot test-account-key:before - * @slot test-account-key:after - * - * @slot test-third-party-key:before - * @slot test-third-party-key:after - * - * @slot additional-fields-[field-name-in-kebab-case]:before - * @slot additional-fields-[field-name-in-kebab-case]:after - * - * @slot three-d-secure-toggle:before - * @slot three-d-secure-toggle:after - * - * @slot three-d-secure-response:before - * @slot three-d-secure-response:after - * - * @slot timestamps:before - * @slot timestamps:after - * - * @slot create:before - * @slot create:after - * - * @slot delete:before - * @slot delete:after - * * @element foxy-payments-api-payment-method-form * @since 1.21.0 */ @@ -124,9 +86,6 @@ export class PaymentsApiPaymentMethodForm extends Base { /** A function that returns a URL of a payment method icon based on the given type. */ getImageSrc: ((type: string) => string) | null = null; - /** Template render functions mapped to their name. */ - templates: Templates = {}; - private readonly __availablePaymentMethodsLoaderId = 'availablePaymentMethodsLoader'; private readonly __threeDSecureResponseGetValue = () => { @@ -181,10 +140,71 @@ export class PaymentsApiPaymentMethodForm extends Base { private __tab = 0; + get hiddenSelector(): BooleanSelector { + return new BooleanSelector(`header:copy-json ${super.hiddenSelector}`.trimEnd()); + } + + renderHeader(...params: Parameters['renderHeader']>): TemplateResult { + return html` +
+ ${super.renderHeader(...params)} + ${this.data?.type || !this.form.type + ? html`` + : html` + this.undo()} + > + + + `} +
+ `; + } + + get headerTitleOptions(): Record { + return { + context: this.form.type ? 'selected' : 'new', + name: this.form.helper?.name, + }; + } + + get headerSubtitleOptions(): Record { + if (this.href) { + const vId = getResourceId(this.href) as string; + const id = this.headerCopyIdValue; + if (vId.startsWith('R')) return { context: 'regular', id }; + return { context: 'hosted', id }; + } + + return {}; + } + + get headerCopyIdValue(): string | number { + if (this.href) { + const id = getResourceId(this.href) as string; + return id.startsWith('R') ? id.slice(1) : id.slice(1).split('C')[0]; + } else { + return ''; + } + } + renderBody(): TemplateResult { - return this.form.type - ? this.__renderPaymentMethodConfig(this.form.type) - : this.__renderPaymentMethodSelector(); + const paymentMethodsLoader = html` + + `; + + return html`${this.renderHeader()}${this.form.type + ? this.__renderPaymentMethodConfig() + : this.__renderPaymentMethodSelector()}${paymentMethodsLoader}`; } private get __groupedAvailablePaymentMethods() { @@ -242,71 +262,34 @@ export class PaymentsApiPaymentMethodForm extends Base { } private __renderPaymentMethodSelector() { - return html` -
- + const loader = this.__availablePaymentMethodsLoader; -
- -
-
- -
- ${this.__groupedAvailablePaymentMethods.map(({ name, items }) => { - return html` -

${name}

-
    - ${items.map(item => html`
  • ${this.__renderPaymentMethodButton(item)}
  • `)} -
- `; - })} -
+ if (!loader?.data) { + return html` + + + `; + } - + return html` +
+
+ ${this.__groupedAvailablePaymentMethods.map(({ name, items }) => { + return html` +

${name}

+
    + ${items.map(item => html`
  • ${this.__renderPaymentMethodButton(item)}
  • `)} +
+ `; + })} +
+
`; } - private __renderPaymentMethodConfig(type: string) { - const defaultSrc = PaymentsApiPaymentMethodForm.defaultImageSrc; - + private __renderPaymentMethodConfig() { return html` -
- ((evt.currentTarget as HTMLImageElement).src = defaultSrc)} - /> - -
-
${this.form.helper?.name ?? this.form.type}​
- ${this.data?.type - ? '' - : html` - this.undo()} - > - - - `} -
-
- -
+
{ -
+
['blocks'][number]; - -export type Templates = { - 'description:before'?: Renderer; - 'description:after'?: Renderer; - 'account-id:before'?: Renderer; - 'account-id:after'?: Renderer; - 'account-key:before'?: Renderer; - 'account-key:after'?: Renderer; - 'third-party-key:before'?: Renderer; - 'third-party-key:after'?: Renderer; - 'test-account-id:before'?: Renderer; - 'test-account-id:after'?: Renderer; - 'test-account-key:before'?: Renderer; - 'test-account-key:after'?: Renderer; - 'test-third-party-key:before'?: Renderer; - 'test-third-party-key:after'?: Renderer; - 'three-d-secure-toggle:before'?: Renderer; - 'three-d-secure-toggle:after'?: Renderer; - 'three-d-secure-response:before'?: Renderer; - 'three-d-secure-response:after'?: Renderer; - 'timestamps:before'?: Renderer; - 'timestamps:after'?: Renderer; - 'create:before'?: Renderer; - 'create:after'?: Renderer; - 'delete:before'?: Renderer; - 'delete:after'?: Renderer; - - [key: string]: Renderer | undefined; -}; diff --git a/src/elements/public/PaymentsApiPaymentPresetCard/PaymentsApiPaymentPresetCard.ts b/src/elements/public/PaymentsApiPaymentPresetCard/PaymentsApiPaymentPresetCard.ts index 45ac894ec..0c9d39fbb 100644 --- a/src/elements/public/PaymentsApiPaymentPresetCard/PaymentsApiPaymentPresetCard.ts +++ b/src/elements/public/PaymentsApiPaymentPresetCard/PaymentsApiPaymentPresetCard.ts @@ -17,12 +17,6 @@ const Base = TranslatableMixin(TwoLineCard, NS); * that is currently a bit quirky due to the legacy functionality. To use * this element with hAPI, wrap it into a foxy-payments-api node._ * - * @slot title:before - * @slot title:after - * - * @slot subtitle:before - * @slot subtitle:after - * * @element foxy-payments-api-payment-preset-card * @since 1.21.0 */ diff --git a/src/elements/public/PaymentsApiPaymentPresetForm/PaymentsApiPaymentPresetForm.stories.ts b/src/elements/public/PaymentsApiPaymentPresetForm/PaymentsApiPaymentPresetForm.stories.ts index 838470484..a13440768 100644 --- a/src/elements/public/PaymentsApiPaymentPresetForm/PaymentsApiPaymentPresetForm.stories.ts +++ b/src/elements/public/PaymentsApiPaymentPresetForm/PaymentsApiPaymentPresetForm.stories.ts @@ -15,8 +15,8 @@ const summary: Summary = { localName: 'foxy-payments-api-payment-preset-form', translatable: true, configurable: { - sections: ['timestamps'], - buttons: ['create', 'delete'], + sections: ['timestamps', 'header'], + buttons: ['delete', 'create', 'submit', 'undo', 'header:copy-id', 'header:copy-json'], inputs: [ 'description', 'is-live', diff --git a/src/elements/public/PaymentsApiPaymentPresetForm/PaymentsApiPaymentPresetForm.test.ts b/src/elements/public/PaymentsApiPaymentPresetForm/PaymentsApiPaymentPresetForm.test.ts index 0ed23cdc9..1fba3ac95 100644 --- a/src/elements/public/PaymentsApiPaymentPresetForm/PaymentsApiPaymentPresetForm.test.ts +++ b/src/elements/public/PaymentsApiPaymentPresetForm/PaymentsApiPaymentPresetForm.test.ts @@ -19,7 +19,7 @@ import { InternalForm } from '../../internal/InternalForm/InternalForm'; import { createRouter } from '../../../server/index'; import { FormDialog } from '../FormDialog'; import { spread } from '@open-wc/lit-helpers'; -import { fake } from 'sinon'; +import { fake, stub } from 'sinon'; describe('PaymentsApiPaymentPresetForm', () => { const OriginalResizeObserver = window.ResizeObserver; @@ -114,6 +114,18 @@ describe('PaymentsApiPaymentPresetForm', () => { expect(form.errors).to.not.include('description:v8n_too_long'); }); + it('renders a form header', async () => { + const form = new Form(); + const renderHeaderMethod = stub(form, 'renderHeader'); + form.render(); + expect(renderHeaderMethod).to.have.been.called; + }); + + it('always hides Copy JSON button in the header', () => { + const form = new Form(); + expect(form.hiddenSelector.matches('header:copy-json', true)).to.be.true; + }); + it('renders a text control for description', async () => { const router = createRouter(); const wrapper = await fixture(html` diff --git a/src/elements/public/PaymentsApiPaymentPresetForm/PaymentsApiPaymentPresetForm.ts b/src/elements/public/PaymentsApiPaymentPresetForm/PaymentsApiPaymentPresetForm.ts index 1775feec9..4b8a1e5fe 100644 --- a/src/elements/public/PaymentsApiPaymentPresetForm/PaymentsApiPaymentPresetForm.ts +++ b/src/elements/public/PaymentsApiPaymentPresetForm/PaymentsApiPaymentPresetForm.ts @@ -2,11 +2,12 @@ import type { InternalCheckboxGroupControl } from '../../internal/InternalCheckb import type { PropertyDeclarations } from 'lit-element'; import type { FormRendererContext } from '../FormDialog/types'; import type { ItemRendererContext } from '../CollectionPage/types'; -import type { Data, Templates } from './types'; +import type { Data } from './types'; import type { TemplateResult } from 'lit-html'; import type { NucleonV8N } from '../NucleonElement/types'; import { TranslatableMixin } from '../../../mixins/translatable'; +import { BooleanSelector } from '@foxy.io/sdk/core'; import { InternalForm } from '../../internal/InternalForm/InternalForm'; import { html } from 'lit-html'; @@ -21,30 +22,6 @@ const Base = TranslatableMixin(InternalForm, NS); * that is currently a bit quirky due to the legacy functionality. To use * this element with hAPI, wrap it into a foxy-payments-api node._ * - * @slot description:before - * @slot description:after - * - * @slot is-live:before - * @slot is-live:after - * - * @slot is-purchase-order-enabled:before - * @slot is-purchase-order-enabled:after - * - * @slot payment-methods:before - * @slot payment-methods:after - * - * @slot fraud-protections:before - * @slot fraud-protections:after - * - * @slot timestamps:before - * @slot timestamps:after - * - * @slot create:before - * @slot create:after - * - * @slot delete:before - * @slot delete:after - * * @element foxy-payments-api-payment-preset-form * @since 1.21.0 */ @@ -70,9 +47,6 @@ export class PaymentsApiPaymentPresetForm extends Base { /** A function that returns image URL for given payment method `type`. */ getPaymentMethodImageSrc: ((type: string) => string) | null = null; - /** Template render functions mapped to their name. */ - templates: Templates = {}; - private static readonly __isPOEnabledOptions = [{ label: 'option_true', value: 'true' }]; private static readonly __isLiveOptions = [{ label: 'option_live', value: 'live' }]; @@ -93,10 +67,16 @@ export class PaymentsApiPaymentPresetForm extends Base { this.edit({ is_live: (newValue as string[]).includes('live') }); }; + get hiddenSelector(): BooleanSelector { + return new BooleanSelector(`header:copy-json ${super.hiddenSelector}`.trimEnd()); + } + renderBody(): TemplateResult { const constructor = this.constructor as typeof PaymentsApiPaymentPresetForm; return html` + ${this.renderHeader()} +
@@ -152,6 +132,7 @@ export class PaymentsApiPaymentPresetForm extends Base { infer="fraud-protections" first=${this.data._links['fx:fraud_protections'].href} limit="5" + alert .item=${(ctx: ItemRendererContext) => html` ; - 'description:after'?: Renderer; - 'is-live:before'?: Renderer; - 'is-live:after'?: Renderer; - 'is-purchase-order-enabled:before'?: Renderer; - 'is-purchase-order-enabled:after'?: Renderer; - 'payment-methods:before'?: Renderer; - 'payment-methods:after'?: Renderer; - 'fraud-protections:before'?: Renderer; - 'fraud-protections:after'?: Renderer; -}; diff --git a/src/elements/public/ReportForm/ReportForm.ts b/src/elements/public/ReportForm/ReportForm.ts index ba2272b92..e77344d64 100644 --- a/src/elements/public/ReportForm/ReportForm.ts +++ b/src/elements/public/ReportForm/ReportForm.ts @@ -1,5 +1,5 @@ import { Choice, Group, Metadata } from '../../private/index'; -import { Data, Templates } from './types'; +import { Data } from './types'; import { PropertyDeclarations, TemplateResult, html } from 'lit-element'; import { ScopedElementsMap, ScopedElementsMixin } from '@open-wc/scoped-elements'; import { @@ -43,21 +43,6 @@ const Base = ScopedElementsMixin( /** * Form element for creating or editing reports (`fx:report`). * - * @slot name:before - * @slot name:after - * - * @slot range:before - * @slot range:after - * - * @slot timestamps:before - * @slot timestamps:after - * - * @slot delete:before - * @slot delete:after - * - * @slot create:before - * @slot create:after - * * @element foxy-report-form * @since 1.16.0 */ @@ -96,8 +81,6 @@ export class ReportForm extends Base { ]; } - templates: Templates = {}; - private __showRangeTime = false; render(): TemplateResult { diff --git a/src/elements/public/ReportForm/types.ts b/src/elements/public/ReportForm/types.ts index 2f0ef477f..70fc146db 100644 --- a/src/elements/public/ReportForm/types.ts +++ b/src/elements/public/ReportForm/types.ts @@ -1,19 +1,4 @@ -import { Rels } from '@foxy.io/sdk/backend'; -import { Renderer } from '../../../mixins/configurable'; -import { ReportForm } from './ReportForm'; -import { Resource } from '@foxy.io/sdk/core'; +import type { Resource } from '@foxy.io/sdk/core'; +import type { Rels } from '@foxy.io/sdk/backend'; export type Data = Resource; - -export type Templates = { - 'name:before'?: Renderer; - 'name:after'?: Renderer; - 'range:before'?: Renderer; - 'range:after'?: Renderer; - 'timestamps:before'?: Renderer; - 'timestamps:after'?: Renderer; - 'delete:before'?: Renderer; - 'delete:after'?: Renderer; - 'create:before'?: Renderer; - 'create:after'?: Renderer; -}; diff --git a/src/elements/public/ShippingContainerCard/ShippingContainerCard.stories.ts b/src/elements/public/ShippingContainerCard/ShippingContainerCard.stories.ts new file mode 100644 index 000000000..0aa08c158 --- /dev/null +++ b/src/elements/public/ShippingContainerCard/ShippingContainerCard.stories.ts @@ -0,0 +1,24 @@ +import './index'; + +import { Summary } from '../../../storygen/Summary'; +import { getMeta } from '../../../storygen/getMeta'; +import { getStory } from '../../../storygen/getStory'; + +const summary: Summary = { + href: 'https://demo.api/hapi/shipping_containers/0', + parent: 'https://demo.api/hapi/shipping_containers', + nucleon: true, + localName: 'foxy-shipping-container-card', + translatable: true, +}; + +export default getMeta(summary); + +export const Playground = getStory({ ...summary, code: true }); +export const Empty = getStory(summary); +export const Error = getStory(summary); +export const Busy = getStory(summary); + +Empty.args.href = ''; +Error.args.href = 'https://demo.api/virtual/empty?status=404'; +Busy.args.href = 'https://demo.api/virtual/stall'; diff --git a/src/elements/public/ShippingContainerCard/ShippingContainerCard.test.ts b/src/elements/public/ShippingContainerCard/ShippingContainerCard.test.ts new file mode 100644 index 000000000..616eca1fa --- /dev/null +++ b/src/elements/public/ShippingContainerCard/ShippingContainerCard.test.ts @@ -0,0 +1,62 @@ +import type { FetchEvent } from '../NucleonElement/FetchEvent'; + +import './index'; + +import { expect, fixture, waitUntil } from '@open-wc/testing'; +import { createRouter } from '../../../server/index'; +import { ShippingContainerCard } from './ShippingContainerCard'; +import { TwoLineCard } from '../CustomFieldCard/TwoLineCard'; +import { getByTestId } from '../../../testgen/getByTestId'; +import { getByKey } from '../../../testgen/getByKey'; +import { html } from 'lit-html'; + +const router = createRouter(); + +describe('ShippingContainerCard', () => { + const OriginalResizeObserver = window.ResizeObserver; + + // @ts-expect-error disabling ResizeObserver because it errors in test env + before(() => (window.ResizeObserver = undefined)); + after(() => (window.ResizeObserver = OriginalResizeObserver)); + + it('extends TwoLineCard', () => { + expect(new ShippingContainerCard()).to.be.instanceOf(TwoLineCard); + }); + + it('registers as foxy-shipping-container-card', () => { + expect(customElements.get('foxy-shipping-container-card')).to.equal(ShippingContainerCard); + }); + + it('has a default i18next namespace of "shipping-container-card"', () => { + expect(new ShippingContainerCard()).to.have.property('ns', 'shipping-container-card'); + }); + + it('renders name in the title', async () => { + const handleFetch = (evt: FetchEvent) => router.handleEvent(evt); + const element = await fixture(html` + + `); + + element.href = 'https://demo.api/hapi/shipping_containers/0'; + await waitUntil(() => !!element.data, undefined, { timeout: 5000 }); + + const title = await getByTestId(element, 'title'); + expect(title).to.include.text(element.data!.name); + }); + + it('renders code in the subtitle', async () => { + const handleFetch = (evt: FetchEvent) => router.handleEvent(evt); + const element = await fixture(html` + + `); + + element.href = 'https://demo.api/hapi/shipping_containers/0'; + await waitUntil(() => !!element.data, undefined, { timeout: 5000 }); + + const subtitle = (await getByTestId(element, 'subtitle')) as HTMLElement; + const text = await getByKey(subtitle, 'subtitle'); + + expect(text).to.have.attribute('infer', ''); + expect(text).to.have.deep.property('options', { code: element.data!.code }); + }); +}); diff --git a/src/elements/public/ShippingContainerCard/ShippingContainerCard.ts b/src/elements/public/ShippingContainerCard/ShippingContainerCard.ts new file mode 100644 index 000000000..6fa5eba59 --- /dev/null +++ b/src/elements/public/ShippingContainerCard/ShippingContainerCard.ts @@ -0,0 +1,26 @@ +import type { TemplateResult } from 'lit-html'; +import type { Data } from './types'; + +import { TranslatableMixin } from '../../../mixins/translatable'; +import { TwoLineCard } from '../CustomFieldCard/TwoLineCard'; +import { html } from 'lit-html'; + +const NS = 'shipping-container-card'; +const Base = TranslatableMixin(TwoLineCard, NS); + +/** + * Basic card displaying a shipping container (`fx:shipping_container`). + * + * @element foxy-shipping-container-card + * @since 1.28.0 + */ +export class ShippingContainerCard extends Base { + renderBody(): TemplateResult { + return super.renderBody({ + title: data => html`${data.name}`, + subtitle: ({ code }) => html` + + `, + }); + } +} diff --git a/src/elements/public/ShippingContainerCard/index.ts b/src/elements/public/ShippingContainerCard/index.ts new file mode 100644 index 000000000..02b050ed9 --- /dev/null +++ b/src/elements/public/ShippingContainerCard/index.ts @@ -0,0 +1,9 @@ +import '../../internal/InternalSandbox/index'; +import '../../internal/InternalCard/index'; +import '../I18n/index'; + +import { ShippingContainerCard } from './ShippingContainerCard'; + +customElements.define('foxy-shipping-container-card', ShippingContainerCard); + +export { ShippingContainerCard }; diff --git a/src/elements/public/ShippingContainerCard/types.ts b/src/elements/public/ShippingContainerCard/types.ts new file mode 100644 index 000000000..4bc9aaf23 --- /dev/null +++ b/src/elements/public/ShippingContainerCard/types.ts @@ -0,0 +1,4 @@ +import type { Resource } from '@foxy.io/sdk/core'; +import type { Rels } from '@foxy.io/sdk/backend'; + +export type Data = Resource; diff --git a/src/elements/public/ShippingDropTypeCard/ShippingDropTypeCard.stories.ts b/src/elements/public/ShippingDropTypeCard/ShippingDropTypeCard.stories.ts new file mode 100644 index 000000000..01bedec9a --- /dev/null +++ b/src/elements/public/ShippingDropTypeCard/ShippingDropTypeCard.stories.ts @@ -0,0 +1,24 @@ +import './index'; + +import { Summary } from '../../../storygen/Summary'; +import { getMeta } from '../../../storygen/getMeta'; +import { getStory } from '../../../storygen/getStory'; + +const summary: Summary = { + href: 'https://demo.api/hapi/shipping_drop_types/0', + parent: 'https://demo.api/hapi/shipping_drop_types', + nucleon: true, + localName: 'foxy-shipping-drop-type-card', + translatable: true, +}; + +export default getMeta(summary); + +export const Playground = getStory({ ...summary, code: true }); +export const Empty = getStory(summary); +export const Error = getStory(summary); +export const Busy = getStory(summary); + +Empty.args.href = ''; +Error.args.href = 'https://demo.api/virtual/empty?status=404'; +Busy.args.href = 'https://demo.api/virtual/stall'; diff --git a/src/elements/public/ShippingDropTypeCard/ShippingDropTypeCard.test.ts b/src/elements/public/ShippingDropTypeCard/ShippingDropTypeCard.test.ts new file mode 100644 index 000000000..71c305740 --- /dev/null +++ b/src/elements/public/ShippingDropTypeCard/ShippingDropTypeCard.test.ts @@ -0,0 +1,62 @@ +import type { FetchEvent } from '../NucleonElement/FetchEvent'; + +import './index'; + +import { expect, fixture, waitUntil } from '@open-wc/testing'; +import { createRouter } from '../../../server/index'; +import { ShippingDropTypeCard } from './ShippingDropTypeCard'; +import { TwoLineCard } from '../CustomFieldCard/TwoLineCard'; +import { getByTestId } from '../../../testgen/getByTestId'; +import { getByKey } from '../../../testgen/getByKey'; +import { html } from 'lit-html'; + +const router = createRouter(); + +describe('ShippingDropTypeCard', () => { + const OriginalResizeObserver = window.ResizeObserver; + + // @ts-expect-error disabling ResizeObserver because it errors in test env + before(() => (window.ResizeObserver = undefined)); + after(() => (window.ResizeObserver = OriginalResizeObserver)); + + it('extends TwoLineCard', () => { + expect(new ShippingDropTypeCard()).to.be.instanceOf(TwoLineCard); + }); + + it('registers as foxy-shipping-drop-type-card', () => { + expect(customElements.get('foxy-shipping-drop-type-card')).to.equal(ShippingDropTypeCard); + }); + + it('has a default i18next namespace of "shipping-drop-type-card"', () => { + expect(new ShippingDropTypeCard()).to.have.property('ns', 'shipping-drop-type-card'); + }); + + it('renders name in the title', async () => { + const handleFetch = (evt: FetchEvent) => router.handleEvent(evt); + const element = await fixture(html` + + `); + + element.href = 'https://demo.api/hapi/shipping_containers/0'; + await waitUntil(() => !!element.data, undefined, { timeout: 5000 }); + + const title = await getByTestId(element, 'title'); + expect(title).to.include.text(element.data!.name); + }); + + it('renders code in the subtitle', async () => { + const handleFetch = (evt: FetchEvent) => router.handleEvent(evt); + const element = await fixture(html` + + `); + + element.href = 'https://demo.api/hapi/shipping_containers/0'; + await waitUntil(() => !!element.data, undefined, { timeout: 5000 }); + + const subtitle = (await getByTestId(element, 'subtitle')) as HTMLElement; + const text = await getByKey(subtitle, 'subtitle'); + + expect(text).to.have.attribute('infer', ''); + expect(text).to.have.deep.property('options', { code: element.data!.code }); + }); +}); diff --git a/src/elements/public/ShippingDropTypeCard/ShippingDropTypeCard.ts b/src/elements/public/ShippingDropTypeCard/ShippingDropTypeCard.ts new file mode 100644 index 000000000..c207a9e01 --- /dev/null +++ b/src/elements/public/ShippingDropTypeCard/ShippingDropTypeCard.ts @@ -0,0 +1,26 @@ +import type { TemplateResult } from 'lit-html'; +import type { Data } from './types'; + +import { TranslatableMixin } from '../../../mixins/translatable'; +import { TwoLineCard } from '../CustomFieldCard/TwoLineCard'; +import { html } from 'lit-html'; + +const NS = 'shipping-drop-type-card'; +const Base = TranslatableMixin(TwoLineCard, NS); + +/** + * Basic card displaying a shipping drop type (`fx:shipping_drop_type`). + * + * @element foxy-shipping-drop-type-card + * @since 1.28.0 + */ +export class ShippingDropTypeCard extends Base { + renderBody(): TemplateResult { + return super.renderBody({ + title: data => html`${data.name}`, + subtitle: ({ code }) => html` + + `, + }); + } +} diff --git a/src/elements/public/ShippingDropTypeCard/index.ts b/src/elements/public/ShippingDropTypeCard/index.ts new file mode 100644 index 000000000..fb85a2d45 --- /dev/null +++ b/src/elements/public/ShippingDropTypeCard/index.ts @@ -0,0 +1,9 @@ +import '../../internal/InternalSandbox/index'; +import '../../internal/InternalCard/index'; +import '../I18n/index'; + +import { ShippingDropTypeCard } from './ShippingDropTypeCard'; + +customElements.define('foxy-shipping-drop-type-card', ShippingDropTypeCard); + +export { ShippingDropTypeCard }; diff --git a/src/elements/public/ShippingDropTypeCard/types.ts b/src/elements/public/ShippingDropTypeCard/types.ts new file mode 100644 index 000000000..2b82b5751 --- /dev/null +++ b/src/elements/public/ShippingDropTypeCard/types.ts @@ -0,0 +1,4 @@ +import type { Resource } from '@foxy.io/sdk/core'; +import type { Rels } from '@foxy.io/sdk/backend'; + +export type Data = Resource; diff --git a/src/elements/public/ShippingMethodCard/ShippingMethodCard.ts b/src/elements/public/ShippingMethodCard/ShippingMethodCard.ts index 061449024..1ca29eaa4 100644 --- a/src/elements/public/ShippingMethodCard/ShippingMethodCard.ts +++ b/src/elements/public/ShippingMethodCard/ShippingMethodCard.ts @@ -51,16 +51,7 @@ export class ShippingMethodCard extends Base { const data = this.data; return html` - - -
+
{ @error=${(evt: Event) => ((evt.currentTarget as HTMLImageElement).src = defaultSrc)} /> -
- ${data?.name}​ - ${isActive - ? html` - - ` - : ''} +
+

${data?.name}

+

+ +

+ + `; } diff --git a/src/elements/public/ShippingServiceCard/ShippingServiceCard.stories.ts b/src/elements/public/ShippingServiceCard/ShippingServiceCard.stories.ts new file mode 100644 index 000000000..85e656595 --- /dev/null +++ b/src/elements/public/ShippingServiceCard/ShippingServiceCard.stories.ts @@ -0,0 +1,24 @@ +import './index'; + +import { Summary } from '../../../storygen/Summary'; +import { getMeta } from '../../../storygen/getMeta'; +import { getStory } from '../../../storygen/getStory'; + +const summary: Summary = { + href: 'https://demo.api/hapi/shipping_services/0', + parent: 'https://demo.api/hapi/shipping_services', + nucleon: true, + localName: 'foxy-shipping-service-card', + translatable: true, +}; + +export default getMeta(summary); + +export const Playground = getStory({ ...summary, code: true }); +export const Empty = getStory(summary); +export const Error = getStory(summary); +export const Busy = getStory(summary); + +Empty.args.href = ''; +Error.args.href = 'https://demo.api/virtual/empty?status=404'; +Busy.args.href = 'https://demo.api/virtual/stall'; diff --git a/src/elements/public/ShippingServiceCard/ShippingServiceCard.test.ts b/src/elements/public/ShippingServiceCard/ShippingServiceCard.test.ts new file mode 100644 index 000000000..e38b5403f --- /dev/null +++ b/src/elements/public/ShippingServiceCard/ShippingServiceCard.test.ts @@ -0,0 +1,71 @@ +import type { FetchEvent } from '../NucleonElement/FetchEvent'; + +import './index'; + +import { expect, fixture, waitUntil } from '@open-wc/testing'; +import { createRouter } from '../../../server/index'; +import { ShippingServiceCard } from './ShippingServiceCard'; +import { TwoLineCard } from '../CustomFieldCard/TwoLineCard'; +import { getByTestId } from '../../../testgen/getByTestId'; +import { getByKey } from '../../../testgen/getByKey'; +import { html } from 'lit-html'; + +const router = createRouter(); + +describe('ShippingServiceCard', () => { + const OriginalResizeObserver = window.ResizeObserver; + + // @ts-expect-error disabling ResizeObserver because it errors in test env + before(() => (window.ResizeObserver = undefined)); + after(() => (window.ResizeObserver = OriginalResizeObserver)); + + it('extends TwoLineCard', () => { + expect(new ShippingServiceCard()).to.be.instanceOf(TwoLineCard); + }); + + it('registers as foxy-shipping-service-card', () => { + expect(customElements.get('foxy-shipping-service-card')).to.equal(ShippingServiceCard); + }); + + it('has a default i18next namespace of "shipping-service-card"', () => { + expect(new ShippingServiceCard()).to.have.property('ns', 'shipping-service-card'); + }); + + it('renders name in the title', async () => { + const handleFetch = (evt: FetchEvent) => router.handleEvent(evt); + const element = await fixture(html` + + `); + + element.href = 'https://demo.api/hapi/shipping_containers/0'; + await waitUntil(() => !!element.data, undefined, { timeout: 5000 }); + + const title = await getByTestId(element, 'title'); + expect(title).to.include.text(element.data!.name); + }); + + it('renders code and international-only usage hint in the subtitle', async () => { + const handleFetch = (evt: FetchEvent) => router.handleEvent(evt); + const element = await fixture(html` + + `); + + element.href = 'https://demo.api/hapi/shipping_containers/0'; + await waitUntil(() => !!element.data, undefined, { timeout: 5000 }); + + const subtitle = (await getByTestId(element, 'subtitle')) as HTMLElement; + const text = await getByKey(subtitle, 'subtitle'); + expect(text).to.have.attribute('infer', ''); + + element.data = { ...element.data!, is_international: false }; + await element.requestUpdate(); + expect(text).to.have.deep.property('options', { code: element.data!.code, context: '' }); + + element.data = { ...element.data!, is_international: true }; + await element.requestUpdate(); + expect(text).to.have.deep.property('options', { + code: element.data!.code, + context: 'international_only', + }); + }); +}); diff --git a/src/elements/public/ShippingServiceCard/ShippingServiceCard.ts b/src/elements/public/ShippingServiceCard/ShippingServiceCard.ts new file mode 100644 index 000000000..1d6ec21e3 --- /dev/null +++ b/src/elements/public/ShippingServiceCard/ShippingServiceCard.ts @@ -0,0 +1,34 @@ +import type { TemplateResult } from 'lit-html'; +import type { Data } from './types'; + +import { TranslatableMixin } from '../../../mixins/translatable'; +import { TwoLineCard } from '../CustomFieldCard/TwoLineCard'; +import { html } from 'lit-html'; + +const NS = 'shipping-service-card'; +const Base = TranslatableMixin(TwoLineCard, NS); + +/** + * Basic card displaying a shipping service (`fx:shipping_service`). + * + * @element foxy-shipping-service-card + * @since 1.28.0 + */ +export class ShippingServiceCard extends Base { + renderBody(): TemplateResult { + return super.renderBody({ + title: data => html`${data.name}`, + subtitle: data => html` + + + `, + }); + } +} diff --git a/src/elements/public/ShippingServiceCard/index.ts b/src/elements/public/ShippingServiceCard/index.ts new file mode 100644 index 000000000..0f0eb30df --- /dev/null +++ b/src/elements/public/ShippingServiceCard/index.ts @@ -0,0 +1,9 @@ +import '../../internal/InternalSandbox/index'; +import '../../internal/InternalCard/index'; +import '../I18n/index'; + +import { ShippingServiceCard } from './ShippingServiceCard'; + +customElements.define('foxy-shipping-service-card', ShippingServiceCard); + +export { ShippingServiceCard }; diff --git a/src/elements/public/ShippingServiceCard/types.ts b/src/elements/public/ShippingServiceCard/types.ts new file mode 100644 index 000000000..274fea6f5 --- /dev/null +++ b/src/elements/public/ShippingServiceCard/types.ts @@ -0,0 +1,4 @@ +import type { Resource } from '@foxy.io/sdk/core'; +import type { Rels } from '@foxy.io/sdk/backend'; + +export type Data = Resource; diff --git a/src/elements/public/SignInForm/SignInForm.ts b/src/elements/public/SignInForm/SignInForm.ts index 00cde5f58..b1c6a13bc 100644 --- a/src/elements/public/SignInForm/SignInForm.ts +++ b/src/elements/public/SignInForm/SignInForm.ts @@ -1,4 +1,4 @@ -import { Data, Templates } from './types'; +import { Data } from './types'; import { PropertyDeclarations, TemplateResult, html } from 'lit-element'; import { CheckboxElement } from '@vaadin/vaadin-checkbox'; @@ -19,23 +19,6 @@ const Base = ThemeableMixin(ConfigurableMixin(TranslatableMixin(NucleonElement, /** * Form element for email/password sign in. * - * @slot email:before - * @slot email:after - * @slot password:before - * @slot password:after - * @slot new-password:before - * @slot new-password:after - * @slot mfa-secret-code:before - * @slot mfa-secret-code:after - * @slot mfa-totp-code:before - * @slot mfa-totp-code:after - * @slot mfa-remember-device:before - * @slot mfa-remember-device:after - * @slot error:before - * @slot error:after - * @slot submit:before - * @slot submit:after - * * @element foxy-sign-in-form * @since 1.4.0 */ @@ -57,8 +40,6 @@ export class SignInForm extends Base { ]; } - templates: Templates = {}; - issuer = 'Unknown'; private readonly __emailValidator = () => !this.errors.some(err => err.startsWith('email')); diff --git a/src/elements/public/SignInForm/types.ts b/src/elements/public/SignInForm/types.ts index cdc459e74..4bd5147c5 100644 --- a/src/elements/public/SignInForm/types.ts +++ b/src/elements/public/SignInForm/types.ts @@ -1,6 +1,4 @@ import { Core } from '@foxy.io/sdk'; -import { Renderer } from '../../../mixins/configurable'; -import { SignInForm } from './SignInForm'; export type Rel = { links: { self: Rel }; @@ -18,21 +16,3 @@ export type Rel = { }; export type Data = Core.Resource; -export type Templates = { - 'email:before'?: Renderer; - 'email:after'?: Renderer; - 'password:before'?: Renderer; - 'password:after'?: Renderer; - 'new-password:before'?: Renderer; - 'new-password:after'?: Renderer; - 'mfa-totp-code:before'?: Renderer; - 'mfa-totp-code:after'?: Renderer; - 'mfa-secret-code:before'?: Renderer; - 'mfa-secret-code:after'?: Renderer; - 'mfa-remember-device:before'?: Renderer; - 'mfa-remember-device:after'?: Renderer; - 'error:before'?: Renderer; - 'error:after'?: Renderer; - 'submit:before'?: Renderer; - 'submit:after'?: Renderer; -}; diff --git a/src/elements/public/StoreCard/StoreCard.ts b/src/elements/public/StoreCard/StoreCard.ts index a5f9a3e21..4ce2a0274 100644 --- a/src/elements/public/StoreCard/StoreCard.ts +++ b/src/elements/public/StoreCard/StoreCard.ts @@ -12,12 +12,6 @@ const Base = TranslatableMixin(TwoLineCard, NS); /** * Card element representing a `fx:store` resource. * - * @slot title:before - * @slot title:after - * - * @slot subtitle:before - * @slot subtitle:after - * * @element foxy-store-card * @since 1.22.0 */ diff --git a/src/elements/public/StoreForm/StoreForm.stories.ts b/src/elements/public/StoreForm/StoreForm.stories.ts index 9a3475363..2156b1888 100644 --- a/src/elements/public/StoreForm/StoreForm.stories.ts +++ b/src/elements/public/StoreForm/StoreForm.stories.ts @@ -11,8 +11,16 @@ const summary: Summary = { localName: 'foxy-store-form', translatable: true, configurable: { - sections: ['timestamps'], - buttons: ['is-maintenance-mode', 'create', 'delete'], + sections: ['timestamps', 'header'], + buttons: [ + 'is-maintenance-mode', + 'create', + 'delete', + 'undo', + 'submit', + 'header:copy-id', + 'header:copy-json', + ], inputs: [ 'store-name', 'logo-url', diff --git a/src/elements/public/StoreForm/StoreForm.test.ts b/src/elements/public/StoreForm/StoreForm.test.ts index dd0af4b22..920161d38 100644 --- a/src/elements/public/StoreForm/StoreForm.test.ts +++ b/src/elements/public/StoreForm/StoreForm.test.ts @@ -496,6 +496,13 @@ describe('StoreForm', () => { expect(form.errors).to.not.include('custom-display-id-config-enabled:v8n_too_long'); }); + it('renders a form header', () => { + const form = new Form(); + const renderHeaderMethod = stub(form, 'renderHeader'); + form.render(); + expect(renderHeaderMethod).to.have.been.called; + }); + it('renders a text control for store name', async () => { const router = createRouter(); const element = await fixture(html` diff --git a/src/elements/public/StoreForm/StoreForm.ts b/src/elements/public/StoreForm/StoreForm.ts index cf6b11227..8e0bcd524 100644 --- a/src/elements/public/StoreForm/StoreForm.ts +++ b/src/elements/public/StoreForm/StoreForm.ts @@ -1,6 +1,6 @@ import type { PropertyDeclarations } from 'lit-element'; import type { Resource, Graph } from '@foxy.io/sdk/core'; -import type { Data, Templates } from './types'; +import type { Data } from './types'; import type { TemplateResult } from 'lit-html'; import type { NucleonElement } from '../NucleonElement'; import type { NucleonV8N } from '../NucleonElement/types'; @@ -22,141 +22,6 @@ const Base = ResponsiveMixin(TranslatableMixin(InternalForm, NS)); /** * Form element for store settings (`fx:store`). * - * @slot store-name:before - * @slot store-name:after - * - * @slot logo-url:before - * @slot logo-url:after - * - * @slot store-domain:before - * @slot store-domain:after - * - * @slot store-url:before - * @slot store-url:after - * - * @slot store-email:before - * @slot store-email:after - * - * @slot timezone:before - * @slot timezone:after - * - * @slot store-version-uri:before - * @slot store-version-uri:after - * - * @slot from-email:before - * @slot from-email:after - * - * @slot bcc-on-receipt-email:before - * @slot bcc-on-receipt-email:after - * - * @slot use-email-dns:before - * @slot use-email-dns:after - * - * @slot use-smtp-config:before - * @slot use-smtp-config:after - * - * @slot smtp-config:before - * @slot smtp-config:after - * - * @slot smtp-config-host:before - * @slot smtp-config-host:after - * - * @slot smtp-config-port:before - * @slot smtp-config-port:after - * - * @slot smtp-config-username:before - * @slot smtp-config-username:after - * - * @slot smtp-config-password:before - * @slot smtp-config-password:after - * - * @slot smtp-config-security:before - * @slot smtp-config-security:after - * - * @slot country:before - * @slot country:after - * - * @slot region:before - * @slot region:after - * - * @slot postal-code:before - * @slot postal-code:after - * - * @slot shipping-address-type:before - * @slot shipping-address-type:after - * - * @slot features-multiship:before - * @slot features-multiship:after - * - * @slot require-signed-shipping-rates:before - * @slot require-signed-shipping-rates:after - * - * @slot language:before - * @slot language:after - * - * @slot locale-code:before - * @slot locale-code:after - * - * @slot currency-style:before - * @slot currency-style:after - * - * @slot custom-display-id-config:before - * @slot custom-display-id-config:after - * - * @slot receipt-continue-url:before - * @slot receipt-continue-url:after - * - * @slot app-session-time:before - * @slot app-session-time:after - * - * @slot products-require-expires-property:before - * @slot products-require-expires-property:after - * - * @slot use-cart-validation:before - * @slot use-cart-validation:after - * - * @slot checkout-type:before - * @slot checkout-type:after - * - * @slot customer-password-hash-type:before - * @slot customer-password-hash-type:after - * - * @slot customer-password-hash-config:before - * @slot customer-password-hash-config:after - * - * @slot unified-order-entry-password:before - * @slot unified-order-entry-password:after - * - * @slot single-sign-on-url:before - * @slot single-sign-on-url:after - * - * @slot webhook-url:before - * @slot webhook-url:after - * - * @slot webhook-key-cart-signing:before - * @slot webhook-key-cart-signing:after - * - * @slot webhook-key-xml-datafeed:before - * @slot webhook-key-xml-datafeed:after - * - * @slot webhook-key-api-legacy:before - * @slot webhook-key-api-legacy:after - * - * @slot webhook-key-sso:before - * @slot webhook-key-sso:after - * - * @slot is-maintenance-mode:before - * @slot is-maintenance-mode:after - * - * @slot timestamps:before - * @slot timestamps:after - * - * @slot create:before - * @slot create:after - * - * @slot delete:before - * @slot delete:after - * * @element foxy-store-form * @since 1.21.0 */ @@ -275,9 +140,6 @@ export class StoreForm extends Base { /** URL of the `fx:regions` property helper resource. */ regions: string | null = null; - /** Template render functions mapped to their name. */ - templates: Templates = {}; - private __singleCheckboxGroupOptions = [{ label: 'option_checked', value: 'checked' }]; private __appSessionTimeOptions = [ @@ -498,6 +360,8 @@ export class StoreForm extends Base { } return html` + ${this.renderHeader()} +
diff --git a/src/elements/public/StoreForm/types.ts b/src/elements/public/StoreForm/types.ts index d9f2bed49..84ca9fa20 100644 --- a/src/elements/public/StoreForm/types.ts +++ b/src/elements/public/StoreForm/types.ts @@ -1,99 +1,4 @@ -import type { StoreForm } from './StoreForm'; -import type { Renderer } from '../../../mixins/configurable'; import type { Resource } from '@foxy.io/sdk/core'; import type { Rels } from '@foxy.io/sdk/backend'; export type Data = Resource; - -export type Templates = { - 'store-name:before'?: Renderer; - 'store-name:after'?: Renderer; - 'logo-url:before'?: Renderer; - 'logo-url:after'?: Renderer; - 'store-domain:before'?: Renderer; - 'store-domain:after'?: Renderer; - 'store-url:before'?: Renderer; - 'store-url:after'?: Renderer; - 'store-email:before'?: Renderer; - 'store-email:after'?: Renderer; - 'timezone:before'?: Renderer; - 'timezone:after'?: Renderer; - 'store-version-uri:before'?: Renderer; - 'store-version-uri:after'?: Renderer; - 'from-email:before'?: Renderer; - 'from-email:after'?: Renderer; - 'bcc-on-receipt-email:before'?: Renderer; - 'bcc-on-receipt-email:after'?: Renderer; - 'use-email-dns:before'?: Renderer; - 'use-email-dns:after'?: Renderer; - 'use-smtp-config:before'?: Renderer; - 'use-smtp-config:after'?: Renderer; - 'smtp-config:before'?: Renderer; - 'smtp-config:after'?: Renderer; - 'smtp-config-host:before'?: Renderer; - 'smtp-config-host:after'?: Renderer; - 'smtp-config-port:before'?: Renderer; - 'smtp-config-port:after'?: Renderer; - 'smtp-config-username:before'?: Renderer; - 'smtp-config-username:after'?: Renderer; - 'smtp-config-password:before'?: Renderer; - 'smtp-config-password:after'?: Renderer; - 'smtp-config-security:before'?: Renderer; - 'smtp-config-security:after'?: Renderer; - 'country:before'?: Renderer; - 'country:after'?: Renderer; - 'region:before'?: Renderer; - 'region:after'?: Renderer; - 'postal-code:before'?: Renderer; - 'postal-code:after'?: Renderer; - 'shipping-address-type:before'?: Renderer; - 'shipping-address-type:after'?: Renderer; - 'features-multiship:before'?: Renderer; - 'features-multiship:after'?: Renderer; - 'require-signed-shipping-rates:before'?: Renderer; - 'require-signed-shipping-rates:after'?: Renderer; - 'language:before'?: Renderer; - 'language:after'?: Renderer; - 'locale-code:before'?: Renderer; - 'locale-code:after'?: Renderer; - 'currency-style:before'?: Renderer; - 'currency-style:after'?: Renderer; - 'custom-display-id-config:before'?: Renderer; - 'custom-display-id-config:after'?: Renderer; - 'receipt-continue-url:before'?: Renderer; - 'receipt-continue-url:after'?: Renderer; - 'app-session-time:before'?: Renderer; - 'app-session-time:after'?: Renderer; - 'products-require-expires-property:before'?: Renderer; - 'products-require-expires-property:after'?: Renderer; - 'use-cart-validation:before'?: Renderer; - 'use-cart-validation:after'?: Renderer; - 'checkout-type:before'?: Renderer; - 'checkout-type:after'?: Renderer; - 'customer-password-hash-type:before'?: Renderer; - 'customer-password-hash-type:after'?: Renderer; - 'customer-password-hash-config:before'?: Renderer; - 'customer-password-hash-config:after'?: Renderer; - 'unified-order-entry-password:before'?: Renderer; - 'unified-order-entry-password:after'?: Renderer; - 'single-sign-on-url:before'?: Renderer; - 'single-sign-on-url:after'?: Renderer; - 'webhook-url:before'?: Renderer; - 'webhook-url:after'?: Renderer; - 'webhook-key-cart-signing:before'?: Renderer; - 'webhook-key-cart-signing:after'?: Renderer; - 'webhook-key-xml-datafeed:before'?: Renderer; - 'webhook-key-xml-datafeed:after'?: Renderer; - 'webhook-key-api-legacy:before'?: Renderer; - 'webhook-key-api-legacy:after'?: Renderer; - 'webhook-key-sso:before'?: Renderer; - 'webhook-key-sso:after'?: Renderer; - 'is-maintenance-mode:before'?: Renderer; - 'is-maintenance-mode:after'?: Renderer; - 'timestamps:before'?: Renderer; - 'timestamps:after'?: Renderer; - 'create:before'?: Renderer; - 'create:after'?: Renderer; - 'delete:before'?: Renderer; - 'delete:after'?: Renderer; -}; diff --git a/src/elements/public/StoreShippingMethodForm/StoreShippingMethodForm.stories.ts b/src/elements/public/StoreShippingMethodForm/StoreShippingMethodForm.stories.ts index 3a5a3f126..2c367f313 100644 --- a/src/elements/public/StoreShippingMethodForm/StoreShippingMethodForm.stories.ts +++ b/src/elements/public/StoreShippingMethodForm/StoreShippingMethodForm.stories.ts @@ -4,16 +4,15 @@ import { Summary } from '../../../storygen/Summary'; import { getMeta } from '../../../storygen/getMeta'; import { getStory } from '../../../storygen/getStory'; -const zoom = 'shipping_method,shipping_container,shipping_drop_type'; const summary: Summary = { - href: `https://demo.api/hapi/store_shipping_methods/0?zoom=${zoom}`, - parent: `https://demo.api/hapi/store_shipping_methods?zoom=${zoom}`, + href: 'https://demo.api/hapi/store_shipping_methods/0?zoom=shipping_method', + parent: 'https://demo.api/hapi/store_shipping_methods?zoom=shipping_method', nucleon: true, localName: 'foxy-store-shipping-method-form', translatable: true, configurable: { - sections: ['timestamps'], - buttons: ['create', 'delete'], + sections: ['timestamps', 'header'], + buttons: ['delete', 'create', 'submit', 'undo', 'header:copy-id', 'header:copy-json'], inputs: [ 'shipping-method-uri', 'shipping-container-uri', @@ -30,13 +29,15 @@ const summary: Summary = { }, }; +const ext = `shipping-methods="https://demo.api/hapi/shipping_methods"`; + export default getMeta(summary); -export const Playground = getStory({ ...summary, code: true }); -export const CustomCode = getStory(summary); -export const Empty = getStory(summary); -export const Error = getStory(summary); -export const Busy = getStory(summary); +export const Playground = getStory({ ...summary, ext, code: true }); +export const CustomCode = getStory({ ...summary, ext }); +export const Empty = getStory({ ...summary, ext }); +export const Error = getStory({ ...summary, ext }); +export const Busy = getStory({ ...summary, ext }); CustomCode.args.href = `https://demo.api/hapi/store_shipping_methods/1?zoom=shipping_method`; Empty.args.href = ''; diff --git a/src/elements/public/StoreShippingMethodForm/StoreShippingMethodForm.test.ts b/src/elements/public/StoreShippingMethodForm/StoreShippingMethodForm.test.ts index 1afba78cf..82650bc22 100644 --- a/src/elements/public/StoreShippingMethodForm/StoreShippingMethodForm.test.ts +++ b/src/elements/public/StoreShippingMethodForm/StoreShippingMethodForm.test.ts @@ -1,22 +1,23 @@ import type { FetchEvent } from '../NucleonElement/FetchEvent'; -import type { Resource } from '@foxy.io/sdk/core'; -import type { Rels } from '@foxy.io/sdk/backend'; import type { Data } from './types'; import './index'; -import { InternalStoreShippingMethodFormServicesControl } from './internal/InternalStoreShippingMethodFormServicesControl/InternalStoreShippingMethodFormServicesControl'; +import { InternalAsyncResourceLinkListControl } from '../../internal/InternalAsyncResourceLinkListControl/InternalAsyncResourceLinkListControl'; import { expect, fixture, html, waitUntil } from '@open-wc/testing'; import { StoreShippingMethodForm as Form } from './StoreShippingMethodForm'; -import { InternalAsyncComboBoxControl } from '../../internal/InternalAsyncComboBoxControl/InternalAsyncComboBoxControl'; +import { InternalResourcePickerControl } from '../../internal/InternalResourcePickerControl/InternalResourcePickerControl'; import { InternalCheckboxGroupControl } from '../../internal/InternalCheckboxGroupControl/InternalCheckboxGroupControl'; -import { InternalTextAreaControl } from '../../internal/InternalTextAreaControl/InternalTextAreaControl'; import { InternalPasswordControl } from '../../internal/InternalPasswordControl/InternalPasswordControl'; +import { InternalSourceControl } from '../../internal/InternalSourceControl/InternalSourceControl'; import { InternalTextControl } from '../../internal/InternalTextControl/InternalTextControl'; import { NucleonElement } from '../NucleonElement/NucleonElement'; import { InternalForm } from '../../internal/InternalForm/InternalForm'; import { createRouter } from '../../../server/index'; import { getTestData } from '../../../testgen/getTestData'; +import { stub } from 'sinon'; +import { Resource } from '@foxy.io/sdk/core'; +import { Rels } from '@foxy.io/sdk/backend'; describe('StoreShippingMethodForm', () => { const OriginalResizeObserver = window.ResizeObserver; @@ -25,9 +26,14 @@ describe('StoreShippingMethodForm', () => { before(() => (window.ResizeObserver = undefined)); after(() => (window.ResizeObserver = OriginalResizeObserver)); - it('imports and defines foxy-internal-async-combo-box-control', () => { - const element = customElements.get('foxy-internal-async-combo-box-control'); - expect(element).to.equal(InternalAsyncComboBoxControl); + it('imports and defines foxy-internal-async-resource-link-list-control', () => { + const element = customElements.get('foxy-internal-async-resource-link-list-control'); + expect(element).to.equal(InternalAsyncResourceLinkListControl); + }); + + it('imports and defines foxy-internal-resource-picker-control', () => { + const element = customElements.get('foxy-internal-resource-picker-control'); + expect(element).to.equal(InternalResourcePickerControl); }); it('imports and defines foxy-internal-checkbox-group-control', () => { @@ -35,9 +41,9 @@ describe('StoreShippingMethodForm', () => { expect(element).to.equal(InternalCheckboxGroupControl); }); - it('imports and defines foxy-internal-text-area-control', () => { - const element = customElements.get('foxy-internal-text-area-control'); - expect(element).to.equal(InternalTextAreaControl); + it('imports and defines foxy-internal-source-control', () => { + const element = customElements.get('foxy-internal-source-control'); + expect(element).to.equal(InternalSourceControl); }); it('imports and defines foxy-internal-password-control', () => { @@ -60,11 +66,6 @@ describe('StoreShippingMethodForm', () => { expect(element).to.equal(NucleonElement); }); - it('imports and defines foxy-internal-store-shipping-method-form-services-control', () => { - const element = customElements.get('foxy-internal-store-shipping-method-form-services-control'); - expect(element).to.equal(InternalStoreShippingMethodFormServicesControl); - }); - it('imports and defines itself as foxy-store-shipping-method-form', () => { const element = customElements.get('foxy-store-shipping-method-form'); expect(element).to.equal(Form); @@ -243,7 +244,7 @@ describe('StoreShippingMethodForm', () => { it('hides everything except for shipping method uri, timestamps, create and delete buttons by default', () => { const form = new Form(); expect(form.hiddenSelector.toString()).to.equal( - 'not=shipping-method-uri,timestamps,create,delete' + 'shipping-container-uri shipping-drop-type-uri destinations authentication-key meter-number accountid password endpoint custom-code services' ); }); @@ -270,7 +271,7 @@ describe('StoreShippingMethodForm', () => { }); expect(form.hiddenSelector.toString()).to.equal( - 'not=shipping-method-uri,endpoint,timestamps,delete,create' + 'shipping-container-uri shipping-drop-type-uri destinations authentication-key meter-number accountid password custom-code services' ); }); @@ -297,7 +298,7 @@ describe('StoreShippingMethodForm', () => { }); expect(form.hiddenSelector.toString()).to.equal( - 'not=shipping-method-uri,custom-code,timestamps,delete,create' + 'shipping-container-uri shipping-drop-type-uri destinations authentication-key meter-number accountid password endpoint services' ); }); @@ -324,7 +325,7 @@ describe('StoreShippingMethodForm', () => { }); expect(form.hiddenSelector.toString()).to.equal( - 'not=shipping-method-uri,destinations,services,timestamps,delete,create' + 'shipping-container-uri shipping-drop-type-uri authentication-key meter-number accountid password endpoint custom-code services' ); }); @@ -350,9 +351,7 @@ describe('StoreShippingMethodForm', () => { } as Data['_embedded'], }); - expect(form.hiddenSelector.toString()).to.equal( - 'not=shipping-method-uri,shipping-container-uri,shipping-drop-type-uri,destinations,authentication-key,meter-number,accountid,password,services,timestamps,delete,create' - ); + expect(form.hiddenSelector.toString()).to.equal('endpoint custom-code services'); }); it('hides everything except for shipping method uri, shipping container uri, shipping drop type uri, destinations, services, timestamps, create and delete buttons for USPS method', () => { @@ -378,7 +377,7 @@ describe('StoreShippingMethodForm', () => { }); expect(form.hiddenSelector.toString()).to.equal( - 'not=shipping-method-uri,shipping-container-uri,shipping-drop-type-uri,destinations,services,timestamps,delete,create' + 'authentication-key meter-number accountid password endpoint custom-code services' ); }); @@ -404,12 +403,35 @@ describe('StoreShippingMethodForm', () => { } as Data['_embedded'], }); - expect(form.hiddenSelector.toString()).to.equal( - 'not=shipping-method-uri,shipping-container-uri,shipping-drop-type-uri,destinations,authentication-key,meter-number,accountid,password,services,timestamps,delete,create' - ); + expect(form.hiddenSelector.toString()).to.equal('endpoint custom-code services'); + }); + + it('renders a form header', async () => { + const form = new Form(); + const renderHeaderMethod = stub(form, 'renderHeader'); + form.render(); + expect(renderHeaderMethod).to.have.been.called; + }); + + it('uses custom header title options', async () => { + const form = new Form(); + form.data = await getTestData('./hapi/store_shipping_methods/0?zoom=shipping_method'); + type Embed = { 'fx:shipping_method': Resource }; + const shippingMethod = (form.data!._embedded as Embed)['fx:shipping_method']; + expect(form.headerTitleOptions).to.deep.equal({ + ...form.data!, + context: 'existing', + provider: shippingMethod.name, + }); + }); + + it('uses custom header subtitle options', async () => { + const form = new Form(); + form.data = await getTestData('./hapi/store_shipping_methods/0?zoom=shipping_method'); + expect(form.headerSubtitleOptions).to.deep.equal({ id: form.headerCopyIdValue }); }); - it('renders async combo box control for shipping method uri', async () => { + it('renders resource picker control for shipping method uri', async () => { const router = createRouter(); const element = await fixture(html` @@ -422,36 +444,14 @@ describe('StoreShippingMethodForm', () => { const control = element.renderRoot.querySelector( '[infer="shipping-method-uri"]' - ) as InternalAsyncComboBoxControl; + ) as InternalResourcePickerControl; - expect(control).to.be.instanceOf(InternalAsyncComboBoxControl); - expect(control).to.have.attribute('item-value-path', '_links.self.href'); - expect(control).to.have.attribute('item-label-path', 'name'); + expect(control).to.be.instanceOf(InternalResourcePickerControl); expect(control).to.have.attribute('first', 'https://demo.api/hapi/shipping_methods'); - expect(control).to.have.property('selectedItem', null); - - element.edit({ shipping_method_uri: 'https://demo.api/hapi/shipping_methods/0' }); - await waitUntil(() => !!control.selectedItem, '', { timeout: 5000 }); - - const method = await getTestData('https://demo.api/hapi/shipping_methods/0', router); - expect(control).to.have.deep.property('selectedItem', method); - expect(element).to.have.deep.nested.property('form._embedded.fx:shipping_method', method); - - element.undo(); - await element.requestUpdate(); - control.selectedItem = method; - control.dispatchEvent(new CustomEvent('selected-item-changed')); - - expect(element).to.have.deep.nested.property('form._embedded.fx:shipping_method', method); - expect(element).to.have.nested.property('form.shipping_container_uri', ''); - expect(element).to.have.nested.property('form.shipping_drop_type_uri', ''); - expect(element).to.have.nested.property( - 'form.shipping_method_uri', - 'https://demo.api/hapi/shipping_methods/0' - ); + expect(control).to.have.attribute('item', 'foxy-shipping-method-card'); }); - it('renders async combo box control for shipping container uri', async () => { + it('renders resource picker control for shipping container uri', async () => { const router = createRouter(); const element = await fixture(html` @@ -462,51 +462,27 @@ describe('StoreShippingMethodForm', () => { `); - const control = element.renderRoot.querySelector( - '[infer="shipping-container-uri"]' - ) as InternalAsyncComboBoxControl; - - expect(control).to.be.instanceOf(InternalAsyncComboBoxControl); - expect(control).to.have.attribute('item-value-path', '_links.self.href'); - expect(control).to.have.attribute('item-label-path', 'name'); - expect(control).to.not.have.attribute('first'); - expect(control).to.have.property('selectedItem', null); - - element.edit({ shipping_method_uri: 'https://demo.api/hapi/shipping_methods/0' }); - await waitUntil(() => !!element.form._embedded?.['fx:shipping_method'], '', { timeout: 5000 }); - - const method = element.form._embedded!['fx:shipping_method']; - const containersHref = method._links['fx:shipping_containers'].href; - const containers = await getTestData>(containersHref, router); - const firstContainer = containers._embedded['fx:shipping_containers'][0]; - - expect(control).to.have.attribute('first', containersHref); - - element.edit({ shipping_container_uri: firstContainer._links.self.href }); - await waitUntil(() => !!control.selectedItem, '', { timeout: 5000 }); - - expect(control).to.have.deep.property('selectedItem', firstContainer); - expect(element).to.have.deep.nested.property( - 'form._embedded.fx:shipping_container', - firstContainer - ); + element.edit({ + _embedded: { + 'fx:shipping_method': await getTestData('./hapi/shipping_methods/0', router), + }, + }); - element.undo(); await element.requestUpdate(); - control.selectedItem = firstContainer; - control.dispatchEvent(new CustomEvent('selected-item-changed')); - expect(element).to.have.deep.nested.property( - 'form._embedded.fx:shipping_container', - firstContainer - ); - expect(element).to.have.nested.property( - 'form.shipping_container_uri', - firstContainer._links.self.href + const control = element.renderRoot.querySelector( + '[infer="shipping-container-uri"]' + ) as InternalResourcePickerControl; + + expect(control).to.be.instanceOf(InternalResourcePickerControl); + expect(control).to.have.attribute('item', 'foxy-shipping-container-card'); + expect(control).to.have.attribute( + 'first', + 'https://demo.api/hapi/shipping_containers?shipping_method_id=0' ); }); - it('renders async combo box control for shipping drop type uri', async () => { + it('renders resource picker control for shipping drop type uri', async () => { const router = createRouter(); const element = await fixture(html` @@ -517,47 +493,23 @@ describe('StoreShippingMethodForm', () => { `); - const control = element.renderRoot.querySelector( - '[infer="shipping-drop-type-uri"]' - ) as InternalAsyncComboBoxControl; - - expect(control).to.be.instanceOf(InternalAsyncComboBoxControl); - expect(control).to.have.attribute('item-value-path', '_links.self.href'); - expect(control).to.have.attribute('item-label-path', 'name'); - expect(control).to.not.have.attribute('first'); - expect(control).to.have.property('selectedItem', null); - - element.edit({ shipping_method_uri: 'https://demo.api/hapi/shipping_methods/0' }); - await waitUntil(() => !!element.form._embedded?.['fx:shipping_method'], '', { timeout: 5000 }); - - const method = element.form._embedded!['fx:shipping_method']; - const dropTypesHref = method._links['fx:shipping_drop_types'].href; - const containers = await getTestData>(dropTypesHref, router); - const firstDropType = containers._embedded['fx:shipping_drop_types'][0]; - - expect(control).to.have.attribute('first', dropTypesHref); - - element.edit({ shipping_drop_type_uri: firstDropType._links.self.href }); - await waitUntil(() => !!control.selectedItem, '', { timeout: 5000 }); - - expect(control).to.have.deep.property('selectedItem', firstDropType); - expect(element).to.have.deep.nested.property( - 'form._embedded.fx:shipping_drop_type', - firstDropType - ); + element.edit({ + _embedded: { + 'fx:shipping_method': await getTestData('./hapi/shipping_methods/0', router), + }, + }); - element.undo(); await element.requestUpdate(); - control.selectedItem = firstDropType; - control.dispatchEvent(new CustomEvent('selected-item-changed')); - expect(element).to.have.deep.nested.property( - 'form._embedded.fx:shipping_drop_type', - firstDropType - ); - expect(element).to.have.nested.property( - 'form.shipping_drop_type_uri', - firstDropType._links.self.href + const control = element.renderRoot.querySelector( + '[infer="shipping-drop-type-uri"]' + ) as InternalResourcePickerControl; + + expect(control).to.be.instanceOf(InternalResourcePickerControl); + expect(control).to.have.attribute('item', 'foxy-shipping-drop-type-card'); + expect(control).to.have.attribute( + 'first', + 'https://demo.api/hapi/shipping_drop_types?shipping_method_id=0' ); }); @@ -649,6 +601,7 @@ describe('StoreShippingMethodForm', () => { expect(element.renderRoot.querySelector('[infer="accountid"]')).to.exist; element.edit({ shipping_method_uri: 'https://demo.api/hapi/shipping_methods/0' }); + // @ts-expect-error type is not resolved for some reason await waitUntil(() => !!element.form._embedded?.['fx:shipping_method'], '', { timeout: 5000 }); const control = element.renderRoot.querySelector('[infer="endpoint"]') as InternalTextControl; @@ -681,7 +634,7 @@ describe('StoreShippingMethodForm', () => { ); }); - it('renders textarea control for custom code', async () => { + it('renders source control for custom code', async () => { const router = createRouter(); const element = await fixture(html` router.handleEvent(evt)}> @@ -689,19 +642,42 @@ describe('StoreShippingMethodForm', () => { `); expect(element.renderRoot.querySelector('[infer="custom-code"]')).to.be.instanceOf( - InternalTextAreaControl + InternalSourceControl ); }); - it('renders internal control for services', async () => { + it('renders resource link list control for services', async () => { const router = createRouter(); + const element = await fixture(html` - router.handleEvent(evt)}> + router.handleEvent(evt)} + > `); - expect(element.renderRoot.querySelector('[infer="services"]')).to.be.instanceOf( - InternalStoreShippingMethodFormServicesControl + await waitUntil(() => !!element.data); + + const control = element.renderRoot.querySelector( + '[infer="services"]' + ) as InternalAsyncResourceLinkListControl; + + expect(control).to.be.instanceOf(InternalAsyncResourceLinkListControl); + expect(control).to.have.attribute('foreign-key-for-uri', 'shipping_service_uri'); + expect(control).to.have.attribute('foreign-key-for-id', 'shipping_service_id'); + expect(control).to.have.attribute('own-key-for-uri', 'shipping_method_uri'); + expect(control).to.have.attribute('embed-key', 'fx:store_shipping_services'); + expect(control).to.have.attribute('infer', 'services'); + expect(control).to.have.attribute('item', 'foxy-shipping-service-card'); + expect(control).to.have.attribute( + 'options-href', + 'https://demo.api/hapi/shipping_services?shipping_method_id=0' + ); + expect(control).to.have.attribute( + 'links-href', + 'https://demo.api/hapi/store_shipping_services?shipping_method_id=0' ); }); }); diff --git a/src/elements/public/StoreShippingMethodForm/StoreShippingMethodForm.ts b/src/elements/public/StoreShippingMethodForm/StoreShippingMethodForm.ts index 6e767a9bf..fb8889079 100644 --- a/src/elements/public/StoreShippingMethodForm/StoreShippingMethodForm.ts +++ b/src/elements/public/StoreShippingMethodForm/StoreShippingMethodForm.ts @@ -1,9 +1,11 @@ -import type { InternalAsyncComboBoxControl } from '../../internal/InternalAsyncComboBoxControl/InternalAsyncComboBoxControl'; import type { PropertyDeclarations } from 'lit-element'; -import type { Templates, Data } from './types'; import type { NucleonElement } from '../NucleonElement/NucleonElement'; import type { TemplateResult } from 'lit-html'; +import type { UpdateEvent } from '../NucleonElement/UpdateEvent'; import type { NucleonV8N } from '../NucleonElement/types'; +import type { Resource } from '@foxy.io/sdk/core'; +import type { Rels } from '@foxy.io/sdk/backend'; +import type { Data } from './types'; import { TranslatableMixin } from '../../../mixins/translatable'; import { BooleanSelector } from '@foxy.io/sdk/core'; @@ -11,6 +13,8 @@ import { InternalForm } from '../../internal/InternalForm/InternalForm'; import { ifDefined } from 'lit-html/directives/if-defined'; import { html } from 'lit-html'; +type Embed = { 'fx:shipping_method': Resource } | undefined; + const NS = 'store-shipping-method-form'; const Base = TranslatableMixin(InternalForm, NS); const getKbSize = (value: string) => new Blob([value]).size / 1024; @@ -26,48 +30,6 @@ const isURL = (value: string) => { /** * Form element for creating and editing store shipping methods (`fx:store_shipping_method`). * - * @slot shipping-method-uri:before - * @slot shipping-method-uri:after - * - * @slot shipping-container-uri:before - * @slot shipping-container-uri:after - * - * @slot shipping-drop-type-uri:before - * @slot shipping-drop-type-uri:after - * - * @slot destinations:before - * @slot destinations:after - * - * @slot authentication-key:before - * @slot authentication-key:after - * - * @slot meter-number:before - * @slot meter-number:after - * - * @slot endpoint:before - * @slot endpoint:after - * - * @slot accountid:before - * @slot accountid:after - * - * @slot password:before - * @slot password:after - * - * @slot custom-code:before - * @slot custom-code:after - * - * @slot services:before - * @slot services:after - * - * @slot timestamps:before - * @slot timestamps:after - * - * @slot create:before - * @slot create:after - * - * @slot delete:before - * @slot delete:after - * * @element foxy-store-shipping-method-form * @since 1.21.0 */ @@ -89,7 +51,7 @@ export class StoreShippingMethodForm extends Base { ({ custom_code: v }) => !v || getKbSize(v) <= 64 || 'custom-code:v8n_too_long', form => { - if (form._embedded?.['fx:shipping_method']?.code === 'CUSTOM-ENDPOINT-POST') { + if ((form._embedded as Embed)?.['fx:shipping_method']?.code === 'CUSTOM-ENDPOINT-POST') { return (form.accountid && isURL(form.accountid)) || 'endpoint:v8n_required'; } else { return true; @@ -98,7 +60,7 @@ export class StoreShippingMethodForm extends Base { form => { const url = form.shipping_container_uri; - const code = form._embedded?.['fx:shipping_method']?.code; + const code = (form._embedded as Embed)?.['fx:shipping_method']?.code; const codes = ['USPS', 'FedEx', 'UPS']; if (code && codes.includes(code)) { @@ -110,7 +72,7 @@ export class StoreShippingMethodForm extends Base { form => { const url = form.shipping_drop_type_uri; - const code = form._embedded?.['fx:shipping_method']?.code; + const code = (form._embedded as Embed)?.['fx:shipping_method']?.code; const codes = ['FedEx', 'UPS']; if (code && codes.includes(code)) { @@ -125,152 +87,112 @@ export class StoreShippingMethodForm extends Base { /** URL of the `fx:shipping_methods` property helper. */ shippingMethods: string | null = null; - /** Template render functions mapped to their name. */ - templates: Templates = {}; + private readonly __shippingMethodLoaderId = 'shippingMethodLoader'; - private __destinations = [ - { value: 'domestic', label: 'domestic' }, - { value: 'international', label: 'international' }, - ]; + private readonly __shippingMethodUriSetValue = (newValue: string) => { + this.undo(); + this.edit({ shipping_method_uri: newValue }); + }; - private __getDestinations = () => { + private readonly __destinationsGetValue = () => { const value: string[] = []; if (this.form.use_for_domestic) value.push('domestic'); if (this.form.use_for_international) value.push('international'); return value; }; - private __setDestinations = (newValue: string[]) => { + private readonly __destinationsSetValue = (newValue: string[]) => { this.edit({ use_for_domestic: newValue.includes('domestic'), use_for_international: newValue.includes('international'), }); }; - get hiddenSelector(): BooleanSelector { - const code = this.form._embedded?.['fx:shipping_method'].code; - if (!code) return new BooleanSelector('not=shipping-method-uri,timestamps,create,delete'); - - const orgControls = ['shipping-container-uri', 'shipping-drop-type-uri', 'destinations']; - const authControls = ['authentication-key', 'meter-number', 'accountid', 'password']; - const codeToControls: Record = { - 'CUSTOM-ENDPOINT-POST': ['endpoint'], - 'CUSTOM-CODE': ['custom-code'], - 'CUSTOM': ['destinations', 'services'], - 'FedEx': [...orgControls, ...authControls, 'services'], - 'USPS': [...orgControls, 'services'], - 'UPS': [...orgControls, ...authControls, 'services'], - }; + private readonly __destinationsOptions = [ + { value: 'domestic', label: 'domestic' }, + { value: 'international', label: 'international' }, + ]; - if (codeToControls[code]) { - const controls = codeToControls[code]; - const set = ['shipping-method-uri', ...controls, 'timestamps', 'delete', 'create']; - return new BooleanSelector(`not=${set.join()} ${super.hiddenSelector}`); - } else { - return super.hiddenSelector; + get hiddenSelector(): BooleanSelector { + const hasData = !!this.data; + const code = this.__shippingMethod?.code; + + // prettier-ignore + let hiddenControls = 'shipping-container-uri shipping-drop-type-uri destinations authentication-key meter-number accountid password endpoint custom-code'; + + if (code) { + const codeToHiddenControls: Record = { + // prettier-ignore + 'CUSTOM-ENDPOINT-POST': 'shipping-container-uri shipping-drop-type-uri destinations authentication-key meter-number accountid password custom-code', + // prettier-ignore + 'CUSTOM-CODE': 'shipping-container-uri shipping-drop-type-uri destinations authentication-key meter-number accountid password endpoint', + // prettier-ignore + 'CUSTOM': 'shipping-container-uri shipping-drop-type-uri authentication-key meter-number accountid password endpoint custom-code', + // prettier-ignore + 'FedEx': 'endpoint custom-code', + // prettier-ignore + 'USPS': 'authentication-key meter-number accountid password endpoint custom-code', + // prettier-ignore + 'UPS': 'endpoint custom-code', + }; + + if (codeToHiddenControls[code]) hiddenControls = codeToHiddenControls[code]; } + + if (!hasData || code?.startsWith('CUSTOM')) hiddenControls += ' services'; + if (hasData) hiddenControls = `shipping-method-uri ${hiddenControls}`; + + return new BooleanSelector(`${hiddenControls} ${super.hiddenSelector}`.trim()); + } + + get headerSubtitleOptions(): Record { + return { id: this.headerCopyIdValue }; + } + + get headerTitleOptions(): Record { + return { ...super.headerTitleOptions, provider: this.__shippingMethod?.name }; } renderBody(): TemplateResult { - const method = this.form._embedded?.['fx:shipping_method']; + const shippingMethod = this.__shippingMethod; return html` - ${['method', 'container', 'drop_type'].map(tgt => { - const curie = `fx:shipping_${tgt}` as keyof Data['_embedded']; - const prop = `shipping_${tgt}_uri` as keyof Data; - - if (this.form._embedded?.[curie] || !this.form[prop]) return; - - return html` - - `; - })} - - { - const { selectedItem } = evt.currentTarget as InternalAsyncComboBoxControl; - const newEmbeds = { 'fx:shipping_method': selectedItem }; - type ShippingMethod = Data['_embedded']['fx:shipping_method']; - - this.edit({ - _embedded: newEmbeds as Data['_embedded'], - shipping_container_uri: '', - shipping_drop_type_uri: '', - shipping_method_uri: (selectedItem as ShippingMethod)?._links.self.href ?? '', - }); - }} + first=${ifDefined(this.shippingMethods ?? this.form._links?.['fx:shipping_methods'].href)} + item="foxy-shipping-method-card" + .setValue=${this.__shippingMethodUriSetValue} > - + - { - const { selectedItem } = evt.currentTarget as InternalAsyncComboBoxControl; - const newEmbeds = { ...this.form._embedded, 'fx:shipping_container': selectedItem }; - type ShippingContainer = Data['_embedded']['fx:shipping_container']; - - this.edit({ - shipping_container_uri: (selectedItem as ShippingContainer)?._links.self.href ?? '', - _embedded: newEmbeds as Data['_embedded'], - }); - }} + first=${ifDefined(shippingMethod?._links['fx:shipping_containers'].href)} + item="foxy-shipping-container-card" > - + - { - const { selectedItem } = evt.currentTarget as InternalAsyncComboBoxControl; - const newEmbeds = { ...this.form._embedded, 'fx:shipping_drop_type': selectedItem }; - type DropType = Data['_embedded']['fx:shipping_drop_type']; - - this.edit({ - shipping_drop_type_uri: (selectedItem as DropType)?._links.self.href ?? '', - _embedded: newEmbeds as Data['_embedded'], - }); - }} + first=${ifDefined(shippingMethod?._links['fx:shipping_drop_types'].href)} + item="foxy-shipping-drop-type-card" > - + - ${method?.code === 'CUSTOM-ENDPOINT-POST' + ${shippingMethod?.code === 'CUSTOM-ENDPOINT-POST' ? html` @@ -278,12 +200,46 @@ export class StoreShippingMethodForm extends Base { : html``} - - - - + + + + + + ${super.renderBody()} `; } + + private get __shippingMethodLoader() { + type Loader = NucleonElement>; + return this.renderRoot.querySelector(`#${this.__shippingMethodLoaderId}`); + } + + private get __shippingMethod() { + return ( + this.__shippingMethodLoader?.data ?? (this.form._embedded as Embed)?.['fx:shipping_method'] + ); + } } diff --git a/src/elements/public/StoreShippingMethodForm/index.ts b/src/elements/public/StoreShippingMethodForm/index.ts index fc80950a4..1d8a123cc 100644 --- a/src/elements/public/StoreShippingMethodForm/index.ts +++ b/src/elements/public/StoreShippingMethodForm/index.ts @@ -1,14 +1,17 @@ -import '../../internal/InternalAsyncComboBoxControl/index'; +import '../../internal/InternalAsyncResourceLinkListControl/index'; +import '../../internal/InternalResourcePickerControl/index'; import '../../internal/InternalCheckboxGroupControl/index'; -import '../../internal/InternalTextAreaControl/index'; import '../../internal/InternalPasswordControl/index'; +import '../../internal/InternalSourceControl/index'; import '../../internal/InternalTextControl/index'; import '../../internal/InternalForm/index'; +import '../ShippingContainerCard/index'; +import '../ShippingDropTypeCard/index'; +import '../ShippingServiceCard/index'; +import '../ShippingMethodCard/index'; import '../NucleonElement/index'; -import './internal/InternalStoreShippingMethodFormServicesControl/index'; - import { StoreShippingMethodForm } from './StoreShippingMethodForm'; customElements.define('foxy-store-shipping-method-form', StoreShippingMethodForm); diff --git a/src/elements/public/StoreShippingMethodForm/internal/InternalStoreShippingMethodFormServicesControl/InternalStoreShippingMethodFormServicesControl.test.ts b/src/elements/public/StoreShippingMethodForm/internal/InternalStoreShippingMethodFormServicesControl/InternalStoreShippingMethodFormServicesControl.test.ts deleted file mode 100644 index 0d1598027..000000000 --- a/src/elements/public/StoreShippingMethodForm/internal/InternalStoreShippingMethodFormServicesControl/InternalStoreShippingMethodFormServicesControl.test.ts +++ /dev/null @@ -1,177 +0,0 @@ -import type { StoreShippingMethodForm } from '../../StoreShippingMethodForm'; -import type { FetchEvent } from '../../../NucleonElement/FetchEvent'; - -import '../../index'; -import './index'; - -import { InternalStoreShippingMethodFormServicesControl as Control } from './InternalStoreShippingMethodFormServicesControl'; -import { InternalStoreShippingMethodFormServicesPage } from '../InternalStoreShippingMethodFormServicesPage/InternalStoreShippingMethodFormServicesPage'; -import { expect, fixture, html, waitUntil } from '@open-wc/testing'; -import { InternalControl } from '../../../../internal/InternalControl/InternalControl'; -import { CollectionPage } from '../../../CollectionPage/CollectionPage'; -import { createRouter } from '../../../../../server'; -import { Pagination } from '../../../Pagination/Pagination'; -import { getByKey } from '../../../../../testgen/getByKey'; -import { getByTag } from '../../../../../testgen/getByTag'; -import { I18n } from '../../../I18n/I18n'; - -describe('StoreShippingMethodForm', () => { - describe('InternalStoreShippingMethodFormServicesControl', () => { - const OriginalResizeObserver = window.ResizeObserver; - - // @ts-expect-error disabling ResizeObserver because it errors in test env - before(() => (window.ResizeObserver = undefined)); - after(() => (window.ResizeObserver = OriginalResizeObserver)); - - it('imports and defines foxy-internal-control', () => { - const element = customElements.get('foxy-internal-control'); - expect(element).to.equal(InternalControl); - }); - - it('imports and defines foxy-pagination', () => { - const element = customElements.get('foxy-pagination'); - expect(element).to.equal(Pagination); - }); - - it('imports and defines foxy-i18n', () => { - const element = customElements.get('foxy-i18n'); - expect(element).to.equal(I18n); - }); - - it('imports and defines foxy-internal-store-shipping-method-form-services-page', () => { - const element = customElements.get('foxy-internal-store-shipping-method-form-services-page'); - expect(element).to.equal(InternalStoreShippingMethodFormServicesPage); - }); - - it('imports and defines itself as foxy-internal-store-shipping-method-form-services-control', () => { - const localName = 'foxy-internal-store-shipping-method-form-services-control'; - const element = customElements.get(localName); - expect(element).to.equal(Control); - }); - - it('extends foxy-internal-control', () => { - expect(new Control()).to.be.instanceOf(InternalControl); - }); - - it('renders translatable label', async () => { - const router = createRouter(); - - const element = await fixture(html` - router.handleEvent(evt)} - > - - - - `); - - const control = element.firstElementChild as Control; - const root = control.renderRoot; - - await waitUntil( - async () => { - await control.requestUpdate(); - return !!root.querySelector('foxy-pagination'); - }, - '', - { timeout: 5000 } - ); - - const label = await getByKey(control, 'label'); - - expect(label).to.exist; - expect(label).to.have.attribute('infer', ''); - }); - - it('renders pagination for services', async () => { - const router = createRouter(); - - const element = await fixture(html` - router.handleEvent(evt)} - > - - - - `); - - const control = element.firstElementChild as Control; - const root = control.renderRoot; - - await waitUntil( - async () => { - await control.requestUpdate(); - return !!root.querySelector('foxy-pagination'); - }, - '', - { timeout: 5000 } - ); - - const pagination = (await getByTag(control, 'foxy-pagination')) as Pagination; - - expect(pagination).to.exist; - expect(pagination).to.have.attribute('infer', ''); - expect(pagination).to.have.attribute( - 'first', - 'https://demo.api/hapi/shipping_services?shipping_method_id=0&limit=10' - ); - }); - - it('renders pagination page for services', async () => { - const router = createRouter(); - - const element = await fixture(html` - router.handleEvent(evt)} - > - - - - `); - - const control = element.firstElementChild as Control; - const root = control.renderRoot; - - await waitUntil( - async () => { - await control.requestUpdate(); - return !!root.querySelector('foxy-pagination'); - }, - '', - { timeout: 5000 } - ); - - const pagination = (await getByTag(control, 'foxy-pagination')) as Pagination; - const page = pagination.lastElementChild as CollectionPage; - - expect(page).to.exist; - - expect(page).to.have.attribute('infer', ''); - - expect(page).to.have.attribute( - 'store-shipping-services-uri', - element.data!._links['fx:store_shipping_services'].href - ); - - expect(page).to.have.attribute( - 'shipping-method-uri', - element.data!._links['fx:shipping_method'].href - ); - - element.edit({ use_for_international: true }); - await element.requestUpdate(); - await control.requestUpdate(); - - expect(page).to.have.attribute('international-allowed'); - - element.edit({ use_for_international: false }); - await element.requestUpdate(); - await control.requestUpdate(); - - expect(page).to.not.have.attribute('international-allowed'); - }); - }); -}); diff --git a/src/elements/public/StoreShippingMethodForm/internal/InternalStoreShippingMethodFormServicesControl/InternalStoreShippingMethodFormServicesControl.ts b/src/elements/public/StoreShippingMethodForm/internal/InternalStoreShippingMethodFormServicesControl/InternalStoreShippingMethodFormServicesControl.ts deleted file mode 100644 index 3f139ddb7..000000000 --- a/src/elements/public/StoreShippingMethodForm/internal/InternalStoreShippingMethodFormServicesControl/InternalStoreShippingMethodFormServicesControl.ts +++ /dev/null @@ -1,37 +0,0 @@ -import type { TemplateResult } from 'lit-html'; -import type { Data } from '../../types'; - -import { InternalControl } from '../../../../internal/InternalControl/InternalControl'; -import { html } from 'lit-html'; - -export class InternalStoreShippingMethodFormServicesControl extends InternalControl { - renderControl(): TemplateResult { - const data = this.nucleon?.data as Data; - const form = this.nucleon?.form as Partial; - - if (!data) return html``; - - const firstURL = new URL(data._links['fx:shipping_services'].href); - firstURL.searchParams.set('limit', '10'); - - return html` - - - - - - - - `; - } -} diff --git a/src/elements/public/StoreShippingMethodForm/internal/InternalStoreShippingMethodFormServicesControl/index.ts b/src/elements/public/StoreShippingMethodForm/internal/InternalStoreShippingMethodFormServicesControl/index.ts deleted file mode 100644 index 00f16ffe8..000000000 --- a/src/elements/public/StoreShippingMethodForm/internal/InternalStoreShippingMethodFormServicesControl/index.ts +++ /dev/null @@ -1,15 +0,0 @@ -import '../../../../internal/InternalControl/index'; - -import '../../../Pagination/index'; -import '../../../I18n/index'; - -import '../InternalStoreShippingMethodFormServicesPage/index'; - -import { InternalStoreShippingMethodFormServicesControl } from './InternalStoreShippingMethodFormServicesControl'; - -customElements.define( - 'foxy-internal-store-shipping-method-form-services-control', - InternalStoreShippingMethodFormServicesControl -); - -export { InternalStoreShippingMethodFormServicesControl }; diff --git a/src/elements/public/StoreShippingMethodForm/internal/InternalStoreShippingMethodFormServicesPage/InternalStoreShippingMethodFormServicesPage.test.ts b/src/elements/public/StoreShippingMethodForm/internal/InternalStoreShippingMethodFormServicesPage/InternalStoreShippingMethodFormServicesPage.test.ts deleted file mode 100644 index 9583929b3..000000000 --- a/src/elements/public/StoreShippingMethodForm/internal/InternalStoreShippingMethodFormServicesPage/InternalStoreShippingMethodFormServicesPage.test.ts +++ /dev/null @@ -1,311 +0,0 @@ -import type { FetchEvent } from '../../../NucleonElement/FetchEvent'; - -import '../../index'; -import './index'; - -import { InternalStoreShippingMethodFormServicesPageItem as Item } from '../InternalStoreShippingMethodFormServicesPageItem/InternalStoreShippingMethodFormServicesPageItem'; -import { InternalStoreShippingMethodFormServicesPage as Page } from './InternalStoreShippingMethodFormServicesPage'; -import { expect, fixture, html, waitUntil } from '@open-wc/testing'; -import { NucleonElement } from '../../../NucleonElement/NucleonElement'; -import { getByTestClass } from '../../../../../testgen/getByTestClass'; -import { createRouter } from '../../../../../server/index'; -import { getByTestId } from '../../../../../testgen/getByTestId'; -import { Spinner } from '../../../Spinner/Spinner'; -import { I18n } from '../../../I18n/I18n'; - -describe('StoreShippingMethodForm', () => { - describe('InternalStoreShippingMethodFormServicesPage', () => { - it('imports and defines foxy-spinner', () => { - const element = customElements.get('foxy-spinner'); - expect(element).to.equal(Spinner); - }); - - it('imports and defines foxy-i18n', () => { - const element = customElements.get('foxy-i18n'); - expect(element).to.equal(I18n); - }); - - it('imports and defines foxy-internal-store-shipping-method-form-services-page-item', () => { - const localName = 'foxy-internal-store-shipping-method-form-services-page-item'; - const element = customElements.get(localName); - expect(element).to.equal(Item); - }); - - it('imports and defines itself as foxy-internal-store-shipping-method-form-services-page', () => { - const localName = 'foxy-internal-store-shipping-method-form-services-page'; - const element = customElements.get(localName); - expect(element).to.equal(Page); - }); - - it('extends NucleonElement', () => { - expect(new Page()).to.be.instanceOf(NucleonElement); - }); - - it('has a reactive property "storeShippingServicesUri"', () => { - expect(new Page()).to.have.property('storeShippingServicesUri', null); - expect(Page).to.have.nested.property('properties.storeShippingServicesUri'); - expect(Page).to.not.have.nested.property('properties.storeShippingServicesUri.type'); - expect(Page).to.have.nested.property( - 'properties.storeShippingServicesUri.attribute', - 'store-shipping-services-uri' - ); - }); - - it('has a reactive property "shippingMethodUri"', () => { - expect(new Page()).to.have.property('shippingMethodUri', null); - expect(Page).to.have.nested.property('properties.shippingMethodUri'); - expect(Page).to.not.have.nested.property('properties.shippingMethodUri.type'); - expect(Page).to.have.nested.property( - 'properties.shippingMethodUri.attribute', - 'shipping-method-uri' - ); - }); - - it('has a reactive property "internationalAllowed"', () => { - expect(new Page()).to.have.property('internationalAllowed', false); - expect(Page).to.have.nested.property('properties.internationalAllowed'); - expect(Page).to.have.nested.property('properties.internationalAllowed.type', Boolean); - expect(Page).to.have.nested.property( - 'properties.internationalAllowed.attribute', - 'international-allowed' - ); - }); - - it('has an empty default i18n namespace', () => { - expect(Page).to.have.property('defaultNS', ''); - expect(new Page()).to.have.property('ns', ''); - }); - - it('renders InternalStoreShippingMethodFormServicesPageItem element for each service', async () => { - const router = createRouter(); - - const element = await fixture(html` - router.handleEvent(evt)} - > - - `); - - await waitUntil(() => element.in({ idle: 'snapshot' })); - const items = await getByTestClass(element, 'item'); - const services = element.data!._embedded['fx:shipping_services']; - - expect(items.length).to.equal(services.length); - - services.forEach((service, index) => { - const storeShippingServiceURL = new URL('https://demo.api/hapi/store_shipping_services'); - const shippingServiceURL = new URL(service._links.self.href); - const shippingServiceID = shippingServiceURL.pathname.split('/').pop() as string; - - storeShippingServiceURL.searchParams.set('shipping_service_id', shippingServiceID); - storeShippingServiceURL.searchParams.set('limit', '1'); - - expect(items[index]).to.be.instanceOf(Item); - expect(items[index]).to.have.attribute('shipping-service-uri', service._links.self.href); - expect(items[index]).to.have.attribute('infer', ''); - expect(items[index]).to.have.attribute('href', storeShippingServiceURL.toString()); - expect(items[index]).to.include.text(service.name); - }); - }); - - it('passes shipping-method-uri value to item elements', async () => { - const router = createRouter(); - - const element = await fixture(html` - router.handleEvent(evt)} - > - - `); - - await waitUntil(() => element.in({ idle: 'snapshot' })); - const items = await getByTestClass(element, 'item'); - - element.data!._embedded['fx:shipping_services'].forEach((_, index) => { - expect(items[index]).to.not.have.attribute('shipping-method-uri'); - }); - - element.shippingMethodUri = 'https://demo.api/hapi/shipping_methods/0'; - await element.requestUpdate(); - - element.data!._embedded['fx:shipping_services'].forEach((_, index) => { - expect(items[index]).to.have.attribute( - 'shipping-method-uri', - 'https://demo.api/hapi/shipping_methods/0' - ); - }); - }); - - it('passes international-allowed value to item elements', async () => { - const router = createRouter(); - - const element = await fixture(html` - router.handleEvent(evt)} - > - - `); - - await waitUntil(() => element.in({ idle: 'snapshot' })); - const items = await getByTestClass(element, 'item'); - - element.data!._embedded['fx:shipping_services'].forEach((_, index) => { - expect(items[index]).to.not.have.attribute('international-allowed'); - }); - - element.internationalAllowed = true; - await element.requestUpdate(); - - element.data!._embedded['fx:shipping_services'].forEach((_, index) => { - expect(items[index]).to.have.attribute('international-allowed'); - }); - }); - - it('is enabled by default', async () => { - const router = createRouter(); - const element = await fixture(html` - router.handleEvent(evt)} - > - - `); - - await waitUntil(() => element.in({ idle: 'snapshot' })); - const items = await getByTestClass(element, 'item'); - items.forEach(item => expect(item).to.not.have.attribute('disabled')); - }); - - it('is disabled when element is disabled', async () => { - const router = createRouter(); - const element = await fixture(html` - router.handleEvent(evt)} - > - - `); - - await waitUntil(() => element.in({ idle: 'snapshot' })); - const items = await getByTestClass(element, 'item'); - items.forEach(item => expect(item).to.have.attribute('disabled')); - }); - - it('is editable by default', async () => { - const router = createRouter(); - const element = await fixture(html` - router.handleEvent(evt)} - > - - `); - - await waitUntil(() => element.in({ idle: 'snapshot' })); - const items = await getByTestClass(element, 'item'); - items.forEach(item => expect(item).to.not.have.attribute('readonly')); - }); - - it('is readonly when element is readonly', async () => { - const router = createRouter(); - const element = await fixture(html` - router.handleEvent(evt)} - > - - `); - - await waitUntil(() => element.in({ idle: 'snapshot' })); - const items = await getByTestClass(element, 'item'); - items.forEach(item => expect(item).to.have.attribute('readonly')); - }); - - it('renders foxy-spinner in "busy" state while loading data', async () => { - const router = createRouter(); - const element = await fixture(html` - router.handleEvent(evt)} - > - - `); - - await waitUntil(() => element.in({ busy: 'fetching' })); - const spinnerWrapper = await getByTestId(element, 'spinner'); - const spinner = spinnerWrapper!.firstElementChild; - - expect(spinnerWrapper).not.to.have.class('opacity-0'); - expect(spinner).to.have.attribute('state', 'busy'); - expect(spinner).to.have.attribute('infer', ''); - }); - - it('renders foxy-spinner in "error" state if loading data fails', async () => { - const router = createRouter(); - const element = await fixture(html` - router.handleEvent(evt)} - > - - `); - - await waitUntil(() => element.in('fail')); - const spinnerWrapper = await getByTestId(element, 'spinner'); - const spinner = spinnerWrapper!.firstElementChild; - - expect(spinnerWrapper).not.to.have.class('opacity-0'); - expect(spinner).to.have.attribute('state', 'error'); - expect(spinner).to.have.attribute('infer', ''); - }); - - it('hides spinner once loaded', async () => { - const router = createRouter(); - const element = await fixture(html` - router.handleEvent(evt)} - > - - `); - - await waitUntil(() => element.in({ idle: 'snapshot' })); - const spinnerWrapper = await getByTestId(element, 'spinner'); - const spinner = spinnerWrapper!.firstElementChild; - - expect(spinnerWrapper).to.have.class('opacity-0'); - expect(spinner).to.have.attribute('state', 'busy'); - expect(spinner).to.have.attribute('infer', ''); - }); - }); -}); diff --git a/src/elements/public/StoreShippingMethodForm/internal/InternalStoreShippingMethodFormServicesPage/InternalStoreShippingMethodFormServicesPage.ts b/src/elements/public/StoreShippingMethodForm/internal/InternalStoreShippingMethodFormServicesPage/InternalStoreShippingMethodFormServicesPage.ts deleted file mode 100644 index 6e557243d..000000000 --- a/src/elements/public/StoreShippingMethodForm/internal/InternalStoreShippingMethodFormServicesPage/InternalStoreShippingMethodFormServicesPage.ts +++ /dev/null @@ -1,105 +0,0 @@ -import type { PropertyDeclarations } from 'lit-element'; -import type { TemplateResult } from 'lit-html'; -import type { Resource } from '@foxy.io/sdk/core'; -import type { Rels } from '@foxy.io/sdk/backend'; - -import { ConfigurableMixin } from '../../../../../mixins/configurable'; -import { TranslatableMixin } from '../../../../../mixins/translatable'; -import { ThemeableMixin } from '../../../../../mixins/themeable'; -import { NucleonElement } from '../../../NucleonElement/NucleonElement'; -import { ifDefined } from 'lit-html/directives/if-defined'; -import { classMap } from '../../../../../utils/class-map'; -import { html } from 'lit-html'; - -type Data = Resource; -const Base = ConfigurableMixin(ThemeableMixin(TranslatableMixin(NucleonElement))); - -export class InternalStoreShippingMethodFormServicesPage extends Base { - static get properties(): PropertyDeclarations { - return { - ...super.properties, - storeShippingServicesUri: { attribute: 'store-shipping-services-uri' }, - internationalAllowed: { type: Boolean, attribute: 'international-allowed' }, - shippingMethodUri: { attribute: 'shipping-method-uri' }, - }; - } - - storeShippingServicesUri: string | null = null; - - internationalAllowed = false; - - shippingMethodUri: string | null = null; - - render(): TemplateResult { - const services = this.data?._embedded['fx:shipping_services'] ?? []; - let limit = 20; - - try { - const limitFromHref = parseInt(new URL(this.href).searchParams.get('limit') ?? ''); - if (!isNaN(limitFromHref)) limit = limitFromHref; - } catch { - // invalid URL, use the default - } - - return html` -
-
- ${new Array(limit).fill(0).map((_, index) => { - const service = services[index]; - let href: string | undefined = undefined; - - if (service) { - try { - const storeShippingServiceURL = new URL(this.storeShippingServicesUri ?? ''); - const shippingServiceURL = new URL(service._links.self.href); - const shippingServiceID = shippingServiceURL.pathname.split('/').pop() as string; - - storeShippingServiceURL.searchParams.set('shipping_service_id', shippingServiceID); - storeShippingServiceURL.searchParams.set('limit', '1'); - - href = storeShippingServiceURL.toString(); - } catch { - // invalid URL, ignore - } - } - - if (!href) return html`
`; - - return html` - - ${service?.name} - ${service.is_international - ? html`` - : ''} - - `; - })} -
- -
- - -
-
- `; - } -} diff --git a/src/elements/public/StoreShippingMethodForm/internal/InternalStoreShippingMethodFormServicesPage/index.ts b/src/elements/public/StoreShippingMethodForm/internal/InternalStoreShippingMethodFormServicesPage/index.ts deleted file mode 100644 index 917a4b606..000000000 --- a/src/elements/public/StoreShippingMethodForm/internal/InternalStoreShippingMethodFormServicesPage/index.ts +++ /dev/null @@ -1,13 +0,0 @@ -import '../../../Spinner/index'; -import '../../../I18n/index'; - -import '../InternalStoreShippingMethodFormServicesPageItem/index'; - -import { InternalStoreShippingMethodFormServicesPage } from './InternalStoreShippingMethodFormServicesPage'; - -customElements.define( - 'foxy-internal-store-shipping-method-form-services-page', - InternalStoreShippingMethodFormServicesPage -); - -export { InternalStoreShippingMethodFormServicesPage }; diff --git a/src/elements/public/StoreShippingMethodForm/internal/InternalStoreShippingMethodFormServicesPageItem/InternalStoreShippingMethodFormServicesPageItem.test.ts b/src/elements/public/StoreShippingMethodForm/internal/InternalStoreShippingMethodFormServicesPageItem/InternalStoreShippingMethodFormServicesPageItem.test.ts deleted file mode 100644 index 592c41063..000000000 --- a/src/elements/public/StoreShippingMethodForm/internal/InternalStoreShippingMethodFormServicesPageItem/InternalStoreShippingMethodFormServicesPageItem.test.ts +++ /dev/null @@ -1,130 +0,0 @@ -import type { FetchEvent } from '../../../NucleonElement/FetchEvent'; - -import '../../index'; -import './index'; - -import { InternalStoreShippingMethodFormServicesPageItemContent as Content } from '../InternalStoreShippingMethodFormServicesPageItemContent/InternalStoreShippingMethodFormServicesPageItemContent'; -import { InternalStoreShippingMethodFormServicesPageItem as Item } from './InternalStoreShippingMethodFormServicesPageItem'; -import { expect, fixture, html, waitUntil } from '@open-wc/testing'; -import { NucleonElement } from '../../../NucleonElement/NucleonElement'; -import { createRouter } from '../../../../../server/index'; -import { getByTestId } from '../../../../../testgen/getByTestId'; - -describe('StoreShippingMethodForm', () => { - describe('InternalStoreShippingMethodFormServicesPage', () => { - describe('InternalStoreShippingMethodFormServicesPageItem', () => { - it('imports and defines foxy-internal-store-shipping-method-form-services-page-item-content', () => { - const localName = 'foxy-internal-store-shipping-method-form-services-page-item-content'; - const element = customElements.get(localName); - expect(element).to.equal(Content); - }); - - it('imports and defines itself as foxy-internal-store-shipping-method-form-services-page-item', () => { - const localName = 'foxy-internal-store-shipping-method-form-services-page-item'; - const element = customElements.get(localName); - expect(element).to.equal(Item); - }); - - it('extends NucleonElement', () => { - expect(new Item()).to.be.instanceOf(NucleonElement); - }); - - it('has a reactive property "internationalAllowed"', () => { - expect(new Item()).to.have.property('internationalAllowed', false); - expect(Item).to.have.nested.property('properties.internationalAllowed'); - expect(Item).to.have.nested.property('properties.internationalAllowed.type', Boolean); - expect(Item).to.have.nested.property( - 'properties.internationalAllowed.attribute', - 'international-allowed' - ); - }); - - it('has a reactive property "shippingServiceUri"', () => { - expect(new Item()).to.have.property('shippingServiceUri', null); - expect(Item).to.have.nested.property('properties.shippingServiceUri'); - expect(Item).to.not.have.nested.property('properties.shippingServiceUri.type'); - expect(Item).to.have.nested.property( - 'properties.shippingServiceUri.attribute', - 'shipping-service-uri' - ); - }); - - it('has a reactive property "shippingMethodUri"', () => { - expect(new Item()).to.have.property('shippingMethodUri', null); - expect(Item).to.have.nested.property('properties.shippingMethodUri'); - expect(Item).to.not.have.nested.property('properties.shippingMethodUri.type'); - expect(Item).to.have.nested.property( - 'properties.shippingMethodUri.attribute', - 'shipping-method-uri' - ); - }); - - it('renders InternalStoreShippingMethodFormServicesPageItemContent element when loaded (match found)', async () => { - const router = createRouter(); - const createMatchRequest = new Request('https://demo.api/hapi/store_shipping_services', { - method: 'POST', - headers: { 'Content-Type': 'application/json' }, - body: JSON.stringify({ foo: 'bar' }), - }); - - await router.handleRequest(createMatchRequest)?.handlerPromise; - - const element = await fixture(html` - router.handleEvent(evt)} - > - - `); - - await waitUntil(() => element.in({ idle: 'snapshot' })); - const content = (await getByTestId(element, 'content')) as HTMLElement; - const match = element.data!._embedded['fx:store_shipping_services'][0]; - const defaultSlot = content.querySelector('slot:not([name])'); - const suffixSlot = content.querySelector('slot[name="suffix"]'); - - expect(content).to.be.instanceOf(Content); - - expect(content).to.have.attribute('shipping-service-uri', element.shippingServiceUri!); - expect(content).to.have.attribute('shipping-method-uri', element.shippingMethodUri!); - expect(content).to.have.attribute('infer', ''); - expect(content).to.have.attribute('href', match._links.self.href); - - expect(defaultSlot).to.exist; - expect(suffixSlot).to.exist; - }); - - it('renders InternalStoreShippingMethodFormServicesPageItemContent element when loaded (match not found)', async () => { - const router = createRouter(); - - const element = await fixture(html` - router.handleEvent(evt)} - > - - `); - - await waitUntil(() => element.in({ idle: 'snapshot' })); - const content = (await getByTestId(element, 'content')) as HTMLElement; - const defaultSlot = content.querySelector('slot:not([name])'); - const suffixSlot = content.querySelector('slot[name="suffix"]'); - - expect(content).to.be.instanceOf(Content); - - expect(content).to.have.attribute('shipping-service-uri', element.shippingServiceUri!); - expect(content).to.have.attribute('shipping-method-uri', element.shippingMethodUri!); - expect(content).to.have.attribute('parent', element.href); - expect(content).to.have.attribute('infer', ''); - expect(content).to.not.have.attribute('href'); - - expect(defaultSlot).to.exist; - expect(suffixSlot).to.exist; - }); - }); - }); -}); diff --git a/src/elements/public/StoreShippingMethodForm/internal/InternalStoreShippingMethodFormServicesPageItem/InternalStoreShippingMethodFormServicesPageItem.ts b/src/elements/public/StoreShippingMethodForm/internal/InternalStoreShippingMethodFormServicesPageItem/InternalStoreShippingMethodFormServicesPageItem.ts deleted file mode 100644 index e3674d64f..000000000 --- a/src/elements/public/StoreShippingMethodForm/internal/InternalStoreShippingMethodFormServicesPageItem/InternalStoreShippingMethodFormServicesPageItem.ts +++ /dev/null @@ -1,53 +0,0 @@ -import type { PropertyDeclarations } from 'lit-element'; -import type { TemplateResult } from 'lit-html'; -import type { Resource } from '@foxy.io/sdk/core'; -import type { Rels } from '@foxy.io/sdk/backend'; - -import { ConfigurableMixin } from '../../../../../mixins/configurable'; -import { NucleonElement } from '../../../NucleonElement/NucleonElement'; -import { ThemeableMixin } from '../../../../../mixins/themeable'; -import { ifDefined } from 'lit-html/directives/if-defined'; -import { html } from 'lit-html'; - -type Data = Resource; -const Base = ConfigurableMixin(ThemeableMixin(NucleonElement)); - -export class InternalStoreShippingMethodFormServicesPageItem extends Base { - static get properties(): PropertyDeclarations { - return { - ...super.properties, - internationalAllowed: { type: Boolean, attribute: 'international-allowed' }, - shippingServiceUri: { attribute: 'shipping-service-uri' }, - shippingMethodUri: { attribute: 'shipping-method-uri' }, - }; - } - - internationalAllowed = false; - - shippingServiceUri: string | null = null; - - shippingMethodUri: string | null = null; - - render(): TemplateResult { - const service = this.data?._embedded['fx:store_shipping_services'][0]; - const parent = service ? undefined : this.href; - const href = service ? service._links.self.href : undefined; - - return html` - - - - - - - `; - } -} diff --git a/src/elements/public/StoreShippingMethodForm/internal/InternalStoreShippingMethodFormServicesPageItem/index.ts b/src/elements/public/StoreShippingMethodForm/internal/InternalStoreShippingMethodFormServicesPageItem/index.ts deleted file mode 100644 index 478f0a4f7..000000000 --- a/src/elements/public/StoreShippingMethodForm/internal/InternalStoreShippingMethodFormServicesPageItem/index.ts +++ /dev/null @@ -1,10 +0,0 @@ -import '../InternalStoreShippingMethodFormServicesPageItemContent/index'; - -import { InternalStoreShippingMethodFormServicesPageItem } from './InternalStoreShippingMethodFormServicesPageItem'; - -customElements.define( - 'foxy-internal-store-shipping-method-form-services-page-item', - InternalStoreShippingMethodFormServicesPageItem -); - -export { InternalStoreShippingMethodFormServicesPageItem }; diff --git a/src/elements/public/StoreShippingMethodForm/internal/InternalStoreShippingMethodFormServicesPageItemContent/InternalStoreShippingMethodFormServicesPageItemContent.test.ts b/src/elements/public/StoreShippingMethodForm/internal/InternalStoreShippingMethodFormServicesPageItemContent/InternalStoreShippingMethodFormServicesPageItemContent.test.ts deleted file mode 100644 index be94e534d..000000000 --- a/src/elements/public/StoreShippingMethodForm/internal/InternalStoreShippingMethodFormServicesPageItemContent/InternalStoreShippingMethodFormServicesPageItemContent.test.ts +++ /dev/null @@ -1,236 +0,0 @@ -import type { CheckboxElement } from '@vaadin/vaadin-checkbox'; -import type { FetchEvent } from '../../../NucleonElement/FetchEvent'; - -import '../../index'; -import './index'; - -import { InternalStoreShippingMethodFormServicesPageItemContent as Content } from './InternalStoreShippingMethodFormServicesPageItemContent'; -import { expect, fixture, html, waitUntil } from '@open-wc/testing'; -import { NucleonElement } from '../../../NucleonElement/NucleonElement'; -import { createRouter } from '../../../../../server/index'; -import { getByTestId } from '../../../../../testgen/getByTestId'; -import { stub } from 'sinon'; - -describe('StoreShippingMethodForm', () => { - describe('InternalStoreShippingMethodFormServicesPage', () => { - describe('InternalStoreShippingMethodFormServicesPageItem', () => { - describe('InternalStoreShippingMethodFormServicesPageItemContent', () => { - it('imports and defines vaadin-checkbox', () => { - expect(customElements.get('vaadin-checkbox')).to.exist; - }); - - it('imports and defines itself as foxy-internal-store-shipping-method-form-services-page-item-content', () => { - const localName = 'foxy-internal-store-shipping-method-form-services-page-item-content'; - const element = customElements.get(localName); - expect(element).to.equal(Content); - }); - - it('extends NucleonElement', () => { - expect(new Content()).to.be.instanceOf(NucleonElement); - }); - - it('has a reactive property "shippingServiceUri"', () => { - expect(new Content()).to.have.property('shippingServiceUri', null); - expect(Content).to.have.nested.property('properties.shippingServiceUri'); - expect(Content).to.not.have.nested.property('properties.shippingServiceUri.type'); - expect(Content).to.have.nested.property( - 'properties.shippingServiceUri.attribute', - 'shipping-service-uri' - ); - }); - - it('has a reactive property "shippingMethodUri"', () => { - expect(new Content()).to.have.property('shippingMethodUri', null); - expect(Content).to.have.nested.property('properties.shippingMethodUri'); - expect(Content).to.not.have.nested.property('properties.shippingMethodUri.type'); - expect(Content).to.have.nested.property( - 'properties.shippingMethodUri.attribute', - 'shipping-method-uri' - ); - }); - - it("renders unchecked vaadin-checkbox element if store shipping service doesn't exist", async () => { - const router = createRouter(); - const element = await fixture(html` - router.handleEvent(evt)} - > - - `); - - await waitUntil(() => element.in({ idle: 'template' })); - const checkbox = (await getByTestId(element, 'checkbox')) as HTMLElement; - const slot = checkbox.querySelector('slot:not([name])'); - - expect(checkbox).to.be.instanceOf(customElements.get('vaadin-checkbox')); - expect(checkbox).to.not.have.attribute('checked'); - expect(slot).to.exist; - }); - - it('renders checked vaadin-checkbox element if store shipping service exists', async () => { - const router = createRouter(); - const createMatchRequest = new Request('https://demo.api/hapi/store_shipping_services', { - headers: { 'Content-Type': 'application/json' }, - method: 'POST', - body: JSON.stringify({}), - }); - - const matchResponse = await router.handleRequest(createMatchRequest)?.handlerPromise; - const matchLink = (await matchResponse.json())._links.self.href; - const element = await fixture(html` - router.handleEvent(evt)} - > - - `); - - await waitUntil(() => element.in({ idle: 'snapshot' })); - const checkbox = (await getByTestId(element, 'checkbox')) as HTMLElement; - const slot = checkbox.querySelector('slot:not([name])'); - - expect(checkbox).to.be.instanceOf(customElements.get('vaadin-checkbox')); - expect(checkbox).to.have.attribute('checked'); - expect(slot).to.exist; - }); - - it('deletes store shipping service once unchecked', async () => { - const router = createRouter(); - const createMatchRequest = new Request('https://demo.api/hapi/store_shipping_services', { - headers: { 'Content-Type': 'application/json' }, - method: 'POST', - body: JSON.stringify({}), - }); - - const matchResponse = await router.handleRequest(createMatchRequest)?.handlerPromise; - const matchLink = (await matchResponse.json())._links.self.href; - const element = await fixture(html` - router.handleEvent(evt)} - > - - `); - - await waitUntil(() => element.in({ idle: 'snapshot' })); - const checkbox = (await getByTestId(element, 'checkbox')) as CheckboxElement; - const deleteMethod = stub(element, 'delete'); - - checkbox.checked = false; - checkbox.dispatchEvent(new CustomEvent('change')); - - expect(deleteMethod).to.have.been.called; - - deleteMethod.restore(); - }); - - it('creates store shipping service once checked', async () => { - const router = createRouter(); - const element = await fixture(html` - router.handleEvent(evt)} - > - - `); - - await waitUntil(() => element.in({ idle: 'template' })); - const checkbox = (await getByTestId(element, 'checkbox')) as CheckboxElement; - const submitMethod = stub(element, 'submit'); - - checkbox.checked = true; - checkbox.dispatchEvent(new CustomEvent('change')); - - expect(element).to.have.nested.property( - 'form.shipping_service_uri', - element.shippingServiceUri - ); - - expect(element).to.have.nested.property( - 'form.shipping_method_uri', - element.shippingMethodUri - ); - - expect(submitMethod).to.have.been.called; - - submitMethod.restore(); - }); - - it('is enabled by default', async () => { - const router = createRouter(); - const element = await fixture(html` - router.handleEvent(evt)} - > - - `); - - await waitUntil(() => element.in({ idle: 'template' })); - const checkbox = (await getByTestId(element, 'checkbox')) as HTMLElement; - expect(checkbox).to.not.have.attribute('disabled'); - }); - - it('is disabled when element is disabled', async () => { - const router = createRouter(); - const element = await fixture(html` - router.handleEvent(evt)} - > - - `); - - await waitUntil(() => element.in({ idle: 'template' })); - const checkbox = (await getByTestId(element, 'checkbox')) as HTMLElement; - expect(checkbox).to.have.attribute('disabled'); - }); - - it('is disabled when element is loading data', async () => { - const router = createRouter(); - const element = await fixture(html` - router.handleEvent(evt)} - > - - `); - - await waitUntil(() => element.in({ busy: 'fetching' })); - const checkbox = (await getByTestId(element, 'checkbox')) as HTMLElement; - expect(checkbox).to.have.attribute('disabled'); - }); - - it('is editable by default', async () => { - const router = createRouter(); - const element = await fixture(html` - router.handleEvent(evt)} - > - - `); - - await waitUntil(() => element.in({ idle: 'template' })); - const checkbox = (await getByTestId(element, 'checkbox')) as HTMLElement; - expect(checkbox).to.not.have.attribute('readonly'); - }); - - it('is readonly when element is readonly', async () => { - const router = createRouter(); - const element = await fixture(html` - router.handleEvent(evt)} - > - - `); - - await waitUntil(() => element.in({ idle: 'template' })); - const checkbox = (await getByTestId(element, 'checkbox')) as HTMLElement; - expect(checkbox).to.have.attribute('readonly'); - }); - }); - }); - }); -}); diff --git a/src/elements/public/StoreShippingMethodForm/internal/InternalStoreShippingMethodFormServicesPageItemContent/InternalStoreShippingMethodFormServicesPageItemContent.ts b/src/elements/public/StoreShippingMethodForm/internal/InternalStoreShippingMethodFormServicesPageItemContent/InternalStoreShippingMethodFormServicesPageItemContent.ts deleted file mode 100644 index 9c652ea58..000000000 --- a/src/elements/public/StoreShippingMethodForm/internal/InternalStoreShippingMethodFormServicesPageItemContent/InternalStoreShippingMethodFormServicesPageItemContent.ts +++ /dev/null @@ -1,57 +0,0 @@ -import type { PropertyDeclarations } from 'lit-element'; -import type { CheckboxElement } from '@vaadin/vaadin-checkbox'; -import type { TemplateResult } from 'lit-html'; -import type { Resource } from '@foxy.io/sdk/core'; -import type { Rels } from '@foxy.io/sdk/backend'; - -import { ConfigurableMixin } from '../../../../../mixins/configurable'; -import { NucleonElement } from '../../../NucleonElement/NucleonElement'; -import { ThemeableMixin } from '../../../../../mixins/themeable'; -import { html } from 'lit-html'; - -type Data = Resource; -const Base = ConfigurableMixin(ThemeableMixin(NucleonElement)); - -export class InternalStoreShippingMethodFormServicesPageItemContent extends Base { - static get properties(): PropertyDeclarations { - return { - ...super.properties, - shippingServiceUri: { attribute: 'shipping-service-uri' }, - shippingMethodUri: { attribute: 'shipping-method-uri' }, - }; - } - - shippingServiceUri: string | null = null; - - shippingMethodUri: string | null = null; - - render(): TemplateResult { - return html` -
- { - const checkbox = evt.currentTarget as CheckboxElement; - - if (checkbox.checked) { - this.edit({ - shipping_service_uri: this.shippingServiceUri ?? '', - shipping_method_uri: this.shippingMethodUri ?? '', - }); - - this.submit(); - } else { - this.delete(); - } - }} - > - - -
- `; - } -} diff --git a/src/elements/public/StoreShippingMethodForm/internal/InternalStoreShippingMethodFormServicesPageItemContent/index.ts b/src/elements/public/StoreShippingMethodForm/internal/InternalStoreShippingMethodFormServicesPageItemContent/index.ts deleted file mode 100644 index c48c07724..000000000 --- a/src/elements/public/StoreShippingMethodForm/internal/InternalStoreShippingMethodFormServicesPageItemContent/index.ts +++ /dev/null @@ -1,10 +0,0 @@ -import '@vaadin/vaadin-checkbox'; - -import { InternalStoreShippingMethodFormServicesPageItemContent } from './InternalStoreShippingMethodFormServicesPageItemContent'; - -customElements.define( - 'foxy-internal-store-shipping-method-form-services-page-item-content', - InternalStoreShippingMethodFormServicesPageItemContent -); - -export { InternalStoreShippingMethodFormServicesPageItemContent }; diff --git a/src/elements/public/StoreShippingMethodForm/types.ts b/src/elements/public/StoreShippingMethodForm/types.ts index 65f75ef6f..4e86b9a3a 100644 --- a/src/elements/public/StoreShippingMethodForm/types.ts +++ b/src/elements/public/StoreShippingMethodForm/types.ts @@ -1,42 +1,6 @@ -import type { StoreShippingMethodForm } from './StoreShippingMethodForm'; -import type { Renderer } from '../../../mixins/configurable'; import type { Resource } from '@foxy.io/sdk/core'; import type { Rels } from '@foxy.io/sdk/backend'; -export type Data = Resource< - Rels.StoreShippingMethod, - { - zoom: ['shipping_method', 'shipping_container', 'shipping_drop_type']; - } ->; - -export type Templates = { - 'shipping-method-uri:before'?: Renderer; - 'shipping-method-uri:after'?: Renderer; - 'shipping-container-uri:before'?: Renderer; - 'shipping-container-uri:after'?: Renderer; - 'shipping-drop-type-uri:before'?: Renderer; - 'shipping-drop-type-uri:after'?: Renderer; - 'destinations:before'?: Renderer; - 'destinations:after'?: Renderer; - 'authentication-key:before'?: Renderer; - 'authentication-key:after'?: Renderer; - 'meter-number:before'?: Renderer; - 'meter-number:after'?: Renderer; - 'endpoint:before'?: Renderer; - 'endpoint:after'?: Renderer; - 'accountid:before'?: Renderer; - 'accountid:after'?: Renderer; - 'password:before'?: Renderer; - 'password:after'?: Renderer; - 'custom-code:before'?: Renderer; - 'custom-code:after'?: Renderer; - 'services:before'?: Renderer; - 'services:after'?: Renderer; - 'timestamps:before'?: Renderer; - 'timestamps:after'?: Renderer; - 'create:before'?: Renderer; - 'create:after'?: Renderer; - 'delete:before'?: Renderer; - 'delete:after'?: Renderer; -}; +export type Data = + | Resource + | Resource; diff --git a/src/elements/public/SubscriptionCard/types.ts b/src/elements/public/SubscriptionCard/types.ts index 026d5cd5f..3aa77b0d1 100644 --- a/src/elements/public/SubscriptionCard/types.ts +++ b/src/elements/public/SubscriptionCard/types.ts @@ -1,8 +1,5 @@ -import { Rels } from '@foxy.io/sdk/backend'; -import { Renderer } from '../../../mixins/configurable'; -import { Resource } from '@foxy.io/sdk/core'; -import { SubscriptionCard } from './SubscriptionCard'; +import type { Resource } from '@foxy.io/sdk/core'; +import type { Rels } from '@foxy.io/sdk/backend'; export type Rel = Rels.Subscription; export type Data = Resource; -export type Templates = { default?: Renderer }; diff --git a/src/elements/public/SubscriptionForm/SubscriptionForm.stories.ts b/src/elements/public/SubscriptionForm/SubscriptionForm.stories.ts index 12877be4b..01d0b552b 100644 --- a/src/elements/public/SubscriptionForm/SubscriptionForm.stories.ts +++ b/src/elements/public/SubscriptionForm/SubscriptionForm.stories.ts @@ -12,7 +12,7 @@ const summary: Summary = { translatable: true, configurable: { sections: ['header', 'customer', 'items', 'items:actions', 'transactions', 'timestamps'], - buttons: [], + buttons: ['header:copy-id', 'header:copy-json'], inputs: [ 'end-date', 'next-transaction-date', diff --git a/src/elements/public/SubscriptionForm/SubscriptionForm.test.ts b/src/elements/public/SubscriptionForm/SubscriptionForm.test.ts index 65b9214fd..a0d371922 100644 --- a/src/elements/public/SubscriptionForm/SubscriptionForm.test.ts +++ b/src/elements/public/SubscriptionForm/SubscriptionForm.test.ts @@ -34,6 +34,7 @@ import { ItemCard } from '../ItemCard/ItemCard'; import { Choice } from '../../private/Choice/Choice'; import { links } from '../../../server/hapi/links'; import { I18n } from '../I18n/I18n'; +import { stub } from 'sinon'; const fromDefaults = (key: string, overrides: Record) => { return { ...defaults[key](new URLSearchParams(), {}), ...overrides }; @@ -183,6 +184,13 @@ describe('SubscriptionForm', () => { }); describe('header', () => { + it('renders a form header', () => { + const form = new Form(); + const renderHeaderMethod = stub(form, 'renderHeader'); + form.render(); + expect(renderHeaderMethod).to.have.been.called; + }); + it('once loaded, renders price and frequency in title (intl currency symbol: true)', async () => { const router = createBaseRouter({ defaults, @@ -203,23 +211,15 @@ describe('SubscriptionForm', () => { `); - await waitUntil( - () => !!element.renderRoot.querySelector('[data-testid="header-title"]'), - '', - { timeout: 10000 } - ); - - const control = (await getByTestId(element, 'header-title'))!; - const options = { count: 3, units: 'weekly', amount: '25.99 EUR', currencyDisplay: 'code' }; - const strOptions = JSON.stringify(options); - - await waitUntil(() => control.getAttribute('options') === strOptions); + await waitUntil(() => !!element.headerTitleOptions.context, '', { timeout: 10000 }); - expect(control).to.have.property('localName', 'foxy-i18n'); - expect(control).to.have.attribute('options', strOptions); - expect(control).to.have.attribute('lang', 'es'); - expect(control).to.have.attribute('key', 'price_recurring'); - expect(control).to.have.attribute('ns', 'subscription-form'); + expect(element.headerTitleOptions).to.deep.equal({ + currencyDisplay: 'code', + context: 'recurring', + amount: '25.99 EUR', + units: 'weekly', + count: 3, + }); }); it('once loaded, renders price and frequency in title (intl currency symbol: false)', async () => { @@ -242,23 +242,15 @@ describe('SubscriptionForm', () => { `); - await waitUntil( - () => !!element.renderRoot.querySelector('[data-testid="header-title"]'), - '', - { timeout: 10000 } - ); - - const control = (await getByTestId(element, 'header-title'))!; - const options = { count: 3, units: 'weekly', amount: '25.99 EUR', currencyDisplay: 'symbol' }; - const strOptions = JSON.stringify(options); + await waitUntil(() => !!element.headerTitleOptions.context, '', { timeout: 10000 }); - await waitUntil(() => control.getAttribute('options') === strOptions); - - expect(control).to.have.property('localName', 'foxy-i18n'); - expect(control).to.have.attribute('options', JSON.stringify(options)); - expect(control).to.have.attribute('lang', 'es'); - expect(control).to.have.attribute('key', 'price_recurring'); - expect(control).to.have.attribute('ns', 'subscription-form'); + expect(element.headerTitleOptions).to.deep.equal({ + currencyDisplay: 'symbol', + context: 'recurring', + amount: '25.99 EUR', + units: 'weekly', + count: 3, + }); }); it('once loaded, renders price and frequency in title (frequency: .5m)', async () => { @@ -281,28 +273,15 @@ describe('SubscriptionForm', () => { `); - await waitUntil( - () => !!element.renderRoot.querySelector('[data-testid="header-title"]'), - '', - { timeout: 10000 } - ); + await waitUntil(() => !!element.headerTitleOptions.context, '', { timeout: 10000 }); - const control = (await getByTestId(element, 'header-title'))!; - const options = { - count: 0.5, - units: 'monthly', - amount: '25.99 EUR', + expect(element.headerTitleOptions).to.deep.equal({ currencyDisplay: 'symbol', - }; - - const strOptions = JSON.stringify(options); - await waitUntil(() => control.getAttribute('options') === strOptions); - - expect(control).to.have.property('localName', 'foxy-i18n'); - expect(control).to.have.attribute('options', JSON.stringify(options)); - expect(control).to.have.attribute('lang', 'es'); - expect(control).to.have.attribute('key', 'price_twice_a_month'); - expect(control).to.have.attribute('ns', 'subscription-form'); + context: 'twice_a_month', + amount: '25.99 EUR', + units: 'monthly', + count: 0.5, + }); }); it('once loaded, renders price and frequency in title (currency in custom template set)', async () => { @@ -341,22 +320,15 @@ describe('SubscriptionForm', () => { `); - await waitUntil( - () => !!element.renderRoot.querySelector('[data-testid="header-title"]'), - '', - { timeout: 10000 } - ); + await waitUntil(() => !!element.headerTitleOptions.context, '', { timeout: 10000 }); - const control = (await getByTestId(element, 'header-title'))!; - const options = { count: 3, units: 'weekly', amount: '25.99 AUD', currencyDisplay: 'code' }; - const strOptions = JSON.stringify(options); - await waitUntil(() => control.getAttribute('options') === strOptions); - - expect(control).to.have.property('localName', 'foxy-i18n'); - expect(control).to.have.attribute('options', JSON.stringify(options)); - expect(control).to.have.attribute('lang', 'es'); - expect(control).to.have.attribute('key', 'price_recurring'); - expect(control).to.have.attribute('ns', 'subscription-form'); + expect(element.headerTitleOptions).to.deep.equal({ + currencyDisplay: 'code', + context: 'recurring', + amount: '25.99 AUD', + units: 'weekly', + count: 3, + }); }); it('once loaded, renders price and frequency in title (currency in default template set)', async () => { @@ -390,22 +362,15 @@ describe('SubscriptionForm', () => { `); - await waitUntil( - () => !!element.renderRoot.querySelector('[data-testid="header-title"]'), - '', - { timeout: 10000 } - ); - - const control = (await getByTestId(element, 'header-title'))!; - const options = { count: 3, units: 'weekly', amount: '25.99 AUD', currencyDisplay: 'code' }; - const strOptions = JSON.stringify(options); - await waitUntil(() => control.getAttribute('options') === strOptions); + await waitUntil(() => !!element.headerTitleOptions.context, '', { timeout: 10000 }); - expect(control).to.have.property('localName', 'foxy-i18n'); - expect(control).to.have.attribute('options', JSON.stringify(options)); - expect(control).to.have.attribute('lang', 'es'); - expect(control).to.have.attribute('key', 'price_recurring'); - expect(control).to.have.attribute('ns', 'subscription-form'); + expect(element.headerTitleOptions).to.deep.equal({ + currencyDisplay: 'code', + context: 'recurring', + amount: '25.99 AUD', + units: 'weekly', + count: 3, + }); }); it('once loaded, renders a special status for failed subscriptions in subtitle', async () => { @@ -416,13 +381,8 @@ describe('SubscriptionForm', () => { `); - const control = await getByTestId(element, 'header-subtitle'); - - expect(control).to.have.property('localName', 'foxy-i18n'); - expect(control).to.have.attribute('options', JSON.stringify({ date })); - expect(control).to.have.attribute('lang', 'es'); - expect(control).to.have.attribute('key', 'subscription_failed'); - expect(control).to.have.attribute('ns', 'subscription-form'); + await waitUntil(() => !!element.headerSubtitleOptions.context, '', { timeout: 10000 }); + expect(element.headerSubtitleOptions).to.deep.equal({ context: 'failed', date }); }); it('once loaded, renders a special status for subscriptions that are about to end in subtitle', async () => { @@ -436,13 +396,11 @@ describe('SubscriptionForm', () => { `); - const control = await getByTestId(element, 'header-subtitle'); - - expect(control).to.have.property('localName', 'foxy-i18n'); - expect(control).to.have.attribute('options', JSON.stringify({ date: data.end_date })); - expect(control).to.have.attribute('lang', 'es'); - expect(control).to.have.attribute('key', 'subscription_will_be_cancelled'); - expect(control).to.have.attribute('ns', 'subscription-form'); + await waitUntil(() => !!element.headerSubtitleOptions.context, '', { timeout: 10000 }); + expect(element.headerSubtitleOptions).to.deep.equal({ + context: 'will_be_cancelled', + date: data.end_date, + }); }); it('once loaded, renders a special status for subscriptions that have ended in subtitle', async () => { @@ -456,13 +414,11 @@ describe('SubscriptionForm', () => { `); - const control = await getByTestId(element, 'header-subtitle'); - - expect(control).to.have.property('localName', 'foxy-i18n'); - expect(control).to.have.attribute('options', JSON.stringify({ date: data.end_date })); - expect(control).to.have.attribute('lang', 'es'); - expect(control).to.have.attribute('key', 'subscription_cancelled'); - expect(control).to.have.attribute('ns', 'subscription-form'); + await waitUntil(() => !!element.headerSubtitleOptions.context, '', { timeout: 10000 }); + expect(element.headerSubtitleOptions).to.deep.equal({ + context: 'cancelled', + date: data.end_date, + }); }); it('once loaded, renders a special status for active subscriptions in subtitle', async () => { @@ -476,17 +432,14 @@ describe('SubscriptionForm', () => { `); - const control = await getByTestId(element, 'header-subtitle'); - const options = { date: data.next_transaction_date }; - - expect(control).to.have.property('localName', 'foxy-i18n'); - expect(control).to.have.attribute('options', JSON.stringify(options)); - expect(control).to.have.attribute('lang', 'es'); - expect(control).to.have.attribute('key', 'subscription_active'); - expect(control).to.have.attribute('ns', 'subscription-form'); + await waitUntil(() => !!element.headerSubtitleOptions.context, '', { timeout: 10000 }); + expect(element.headerSubtitleOptions).to.deep.equal({ + context: 'active', + date: data.next_transaction_date, + }); }); - it('once loaded, renders a special status for active subscriptions in subtitle', async () => { + it('once loaded, renders a special status for subscriptions with future start date in subtitle', async () => { const href = './hapi/subscriptions/0?zoom=last_transaction,transaction_template:items'; const data = await getTestData(href); @@ -498,14 +451,11 @@ describe('SubscriptionForm', () => { `); - const control = await getByTestId(element, 'header-subtitle'); - const options = { date: data.start_date }; - - expect(control).to.have.property('localName', 'foxy-i18n'); - expect(control).to.have.attribute('options', JSON.stringify(options)); - expect(control).to.have.attribute('lang', 'es'); - expect(control).to.have.attribute('key', 'subscription_will_be_active'); - expect(control).to.have.attribute('ns', 'subscription-form'); + await waitUntil(() => !!element.headerSubtitleOptions.context, '', { timeout: 10000 }); + expect(element.headerSubtitleOptions).to.deep.equal({ + context: 'will_be_active', + date: data.start_date, + }); }); it('once loaded, renders a special status for inactive subscriptions in subtitle', async () => { @@ -520,78 +470,11 @@ describe('SubscriptionForm', () => { `); - const control = await getByTestId(element, 'header-subtitle'); - - expect(control).to.have.property('localName', 'foxy-i18n'); - expect(control).to.have.attribute('lang', 'es'); - expect(control).to.have.attribute('key', 'subscription_inactive'); - expect(control).to.have.attribute('ns', 'subscription-form'); - }); - - it('is visible by default', async () => { - const layout = html``; - const element = await fixture(layout); - - expect(await getByTestId(element, 'header')).to.exist; - }); - - it('is hidden when form is hidden', async () => { - const layout = html``; - const element = await fixture(layout); - - expect(await getByTestId(element, 'header')).not.to.exist; - }); - - it('is hidden when hiddencontrols includes "header"', async () => { - const element = await fixture(html` - - `); - - expect(await getByTestId(element, 'header')).not.to.exist; - }); - - it('renders "header:before" slot by default', async () => { - const layout = html``; - const element = await fixture(layout); - expect(await getByName(element, 'header:before')).to.have.property('localName', 'slot'); - }); - - it('replaces "header:before" slot with template "header:before" if available', async () => { - const name = 'header:before'; - const value = `

Value of the "${name}" template.

`; - const element = await fixture(html` - - - - `); - - const slot = await getByName(element, name); - const sandbox = (await getByTestId(element, name))!.renderRoot; - - expect(slot).to.not.exist; - expect(sandbox).to.contain.html(value); - }); - - it('renders "header:after" slot by default', async () => { - const layout = html``; - const element = await fixture(layout); - expect(await getByName(element, 'header:after')).to.have.property('localName', 'slot'); - }); - - it('replaces "header:after" slot with template "header:after" if available', async () => { - const name = 'header:after'; - const value = `

Value of the "${name}" template.

`; - const element = await fixture(html` - - - - `); - - const slot = await getByName(element, name); - const sandbox = (await getByTestId(element, name))!.renderRoot; - - expect(slot).to.not.exist; - expect(sandbox).to.contain.html(value); + await waitUntil(() => !!element.headerSubtitleOptions.context, '', { timeout: 10000 }); + expect(element.headerSubtitleOptions).to.deep.equal({ + context: 'inactive', + date: null, + }); }); }); diff --git a/src/elements/public/SubscriptionForm/SubscriptionForm.ts b/src/elements/public/SubscriptionForm/SubscriptionForm.ts index 9c4735579..325e41b70 100644 --- a/src/elements/public/SubscriptionForm/SubscriptionForm.ts +++ b/src/elements/public/SubscriptionForm/SubscriptionForm.ts @@ -1,4 +1,4 @@ -import type { CustomerPageGetter, Data, Settings, Templates, TransactionPageGetter } from './types'; +import type { CustomerPageGetter, Data, Settings, TransactionPageGetter } from './types'; import type { PropertyDeclarations } from 'lit-element'; import type { ScopedElementsMap } from '@open-wc/scoped-elements'; import type { InternalCalendar } from '../../internal/InternalCalendar/InternalCalendar'; @@ -30,38 +30,6 @@ const Base = ScopedElementsMixin(ResponsiveMixin(TranslatableMixin(InternalForm, /** * Form element for creating or editing subscriptions. * - * @slot header:before - **new in v1.4.0** - * @slot header:after - **new in v1.4.0** - * - * @slot items:before - **new in v1.4.0** - * @slot items:after - **new in v1.4.0** - * @slot items:actions:before - **new in v1.4.0** - * @slot items:actions:after - **new in v1.4.0** - * - * @slot end-date:before - **new in v1.4.0** - * @slot end-date:after - **new in v1.4.0** - * - * @slot next-transaction-date:before - **new in v1.4.0** - * @slot next-transaction-date:after - **new in v1.4.0** - * - * @slot frequency:before - **new in v1.4.0** - * @slot frequency:after - **new in v1.4.0** - * - * @slot transactions:before - **new in v1.4.0** - * @slot transactions:after - **new in v1.4.0** - * - * @slot attributes:before - **new in v1.20.0** - * @slot attributes:after - **new in v1.20.0** - * - * @slot timestamps:before - **new in v1.20.0** - * @slot timestamps:after - **new in v1.20.0** - * - * @slot past-due-amount:before - **new in v1.20.0** - * @slot past-due-amount:after - **new in v1.20.0** - * - * @slot start-date:before - **new in v1.20.0** - * @slot start-date:after - **new in v1.20.0** - * * @element foxy-subscription-form * @since 1.2.0 */ @@ -71,6 +39,10 @@ export class SubscriptionForm extends Base { 'foxy-internal-timestamps-control': customElements.get('foxy-internal-timestamps-control'), 'foxy-internal-async-list-control': customElements.get('foxy-internal-async-list-control'), 'foxy-internal-number-control': customElements.get('foxy-internal-number-control'), + 'foxy-internal-submit-control': customElements.get('foxy-internal-submit-control'), + 'foxy-internal-delete-control': customElements.get('foxy-internal-delete-control'), + 'foxy-internal-undo-control': customElements.get('foxy-internal-undo-control'), + 'foxy-copy-to-clipboard': customElements.get('foxy-copy-to-clipboard'), 'foxy-internal-calendar': customElements.get('foxy-internal-calendar'), 'foxy-internal-sandbox': customElements.get('foxy-internal-sandbox'), 'foxy-customer-card': customElements.get('foxy-customer-card'), @@ -111,8 +83,6 @@ export class SubscriptionForm extends Base { localeCodes: string | null = null; - templates: Templates = {}; - settings: Settings | null = null; coupons: string | null = null; @@ -127,110 +97,6 @@ export class SubscriptionForm extends Base { private readonly __storeLoaderId = 'storeLoader'; - private readonly __renderHeaderSubtitle = () => { - const { data, lang, ns } = this; - - if (data) { - let color = 'text-secondary'; - let date: string; - let key: string; - - if (data.first_failed_transaction_date) { - color = 'text-error'; - date = data.first_failed_transaction_date; - key = 'subscription_failed'; - } else if (data.end_date) { - date = data.end_date; - const hasEnded = new Date(data.end_date).getTime() > Date.now(); - key = hasEnded ? 'subscription_will_be_cancelled' : 'subscription_cancelled'; - } else if (!data.is_active) { - date = ''; - key = 'subscription_inactive'; - } else if (new Date(data.start_date) > new Date()) { - date = data.start_date; - key = 'subscription_will_be_active'; - } else { - date = data.next_transaction_date; - key = 'subscription_active'; - } - - const text = html` - - - `; - - if (data.first_failed_transaction_date) { - return html` - - ${text} - - - ${data.error_message} - - `; - } - - return text; - } - - return html` `; - }; - - private readonly __renderHeaderTitle = ( - currency: string | undefined, - currencyDisplay: string | undefined - ) => { - const { data, lang, ns } = this; - - if (data) { - const frequency = parseFrequency(data.frequency); - const transactionTemplate = this.__transactionTemplate; - const total = transactionTemplate?.total_order; - - if (typeof currency !== 'string') return html`--`; - - return html` - - - `; - } - - return html` `; - }; - - private readonly __renderHeader = ( - currencyCode: string | undefined, - currencyDisplay: string | undefined - ) => { - return html` -
- ${this.renderTemplateOrSlot('header:before')} -
- ${this.__renderHeaderTitle(currencyCode, currencyDisplay)} -
-
${this.__renderHeaderSubtitle()}
- ${this.renderTemplateOrSlot('header:after')} -
- `; - }; - private readonly __renderItemsActions = () => { return html`
@@ -497,6 +363,49 @@ export class SubscriptionForm extends Base { return new BooleanSelector(`items:pagination:card:autorenew-icon ${super.hiddenSelector}`); } + get headerTitleOptions(): Record { + if (this.data && this.__currencyCode) { + const frequency = parseFrequency(this.data.frequency); + const transactionTemplate = this.__transactionTemplate; + const total = transactionTemplate?.total_order; + const amount = `${total} ${this.__currencyCode}`; + const currencyDisplay = this.__currencyDisplay; + const context = this.__currencyCode + ? this.data.frequency === '.5m' + ? 'twice_a_month' + : 'recurring' + : 'existing'; + + return { ...frequency, amount, currencyDisplay, context }; + } else { + return {}; + } + } + + get headerSubtitleOptions(): Record { + let context: string; + let date: string | null = null; + + if (this.data?.first_failed_transaction_date) { + context = 'failed'; + date = this.data.first_failed_transaction_date; + } else if (this.data?.end_date) { + const hasEnded = new Date(this.data.end_date).getTime() > Date.now(); + context = hasEnded ? 'will_be_cancelled' : 'cancelled'; + date = this.data.end_date; + } else if (!this.data?.is_active) { + context = 'inactive'; + } else if (new Date(this.data.start_date) > new Date()) { + context = 'will_be_active'; + date = this.data.start_date; + } else { + context = 'active'; + date = this.data.next_transaction_date; + } + + return { date, context }; + } + renderBody(): TemplateResult { let transactionsHref: string | undefined; @@ -509,22 +418,9 @@ export class SubscriptionForm extends Base { transactionsHref = undefined; } - const currencyDisplay = this.__store?.use_international_currency_symbol ? 'code' : 'symbol'; - const cart = this.__transactionTemplate; - - let currencyCode: string | null = null; - - if (cart?.currency_code) { - currencyCode = cart.currency_code; - } else { - const allLocaleCodes = this.__localeCodesHelper; - const localeCode = (this.__templateSet ?? this.__defaultTemplateSet)?.locale_code; - const localeInfo = localeCode ? allLocaleCodes?.values[localeCode] : void 0; - - if (localeInfo) currencyCode = /Currency: ([A-Z]{3})/g.exec(localeInfo)?.[1] ?? null; - } - return html` + ${this.renderHeader()} +
- ${this.hiddenSelector.matches('header', true) - ? '' - : this.__renderHeader(currencyCode ?? void 0, currencyDisplay)} ${this.hiddenSelector.matches('customer', true) ? '' : this.__renderCustomer()} ${this.hiddenSelector.matches('items', true) ? '' : this.__renderItems()} ${this.__isFrequencyVisible ? this.__renderFrequency() : ''} @@ -582,7 +475,7 @@ export class SubscriptionForm extends Base { ${this.__isEndDateVisible ? this.__renderEndDate() : ''} { return Array.from(allowedFrequencies); } + + private get __currencyCode() { + const cart = this.__transactionTemplate; + if (cart?.currency_code) return cart.currency_code; + + const allLocaleCodes = this.__localeCodesHelper; + const localeCode = (this.__templateSet ?? this.__defaultTemplateSet)?.locale_code; + const localeInfo = localeCode ? allLocaleCodes?.values[localeCode] : void 0; + if (localeInfo) return /Currency: ([A-Z]{3})/g.exec(localeInfo)?.[1] ?? null; + + return null; + } + + private get __currencyDisplay() { + return this.__store?.use_international_currency_symbol ? 'code' : 'symbol'; + } } diff --git a/src/elements/public/SubscriptionForm/types.ts b/src/elements/public/SubscriptionForm/types.ts index 5bba42783..c525c931d 100644 --- a/src/elements/public/SubscriptionForm/types.ts +++ b/src/elements/public/SubscriptionForm/types.ts @@ -1,9 +1,6 @@ import { Rels as BackendRels } from '@foxy.io/sdk/backend'; -import { Rels } from '@foxy.io/sdk/customer'; import { Resource } from '@foxy.io/sdk/core'; -import { Renderer } from '../../../mixins/configurable'; -import { SubscriptionForm } from '.'; -import { CancellationForm } from '../CancellationForm/CancellationForm'; +import { Rels } from '@foxy.io/sdk/customer'; export type TransactionPageGetter = ( href: string, @@ -15,26 +12,3 @@ export type CustomerPageGetter = (href: string) => string; export type Settings = Resource; export type Item = Resource; export type Data = Resource; - -export type Templates = { - 'header:before'?: Renderer; - 'header:after'?: Renderer; - 'items:before'?: Renderer; - 'items:after'?: Renderer; - 'items:actions:before'?: Renderer; - 'items:actions:after'?: Renderer; - 'end-date:before'?: Renderer; - 'end-date:after'?: Renderer; - 'end-date:form:warning:before'?: Renderer; - 'end-date:form:warning:after'?: Renderer; - 'end-date:form:end-date:before'?: Renderer; - 'end-date:form:end-date:after'?: Renderer; - 'end-date:form:submit:before'?: Renderer; - 'end-date:form:submit:after'?: Renderer; - 'next-transaction-date:before'?: Renderer; - 'next-transaction-date:after'?: Renderer; - 'frequency:before'?: Renderer; - 'frequency:after'?: Renderer; - 'transactions:before'?: Renderer; - 'transactions:after'?: Renderer; -}; diff --git a/src/elements/public/SubscriptionSettingsForm/SubscriptionSettingsForm.stories.ts b/src/elements/public/SubscriptionSettingsForm/SubscriptionSettingsForm.stories.ts index 4e2b279c8..dddcc107e 100644 --- a/src/elements/public/SubscriptionSettingsForm/SubscriptionSettingsForm.stories.ts +++ b/src/elements/public/SubscriptionSettingsForm/SubscriptionSettingsForm.stories.ts @@ -11,8 +11,8 @@ const summary: Summary = { localName: 'foxy-subscription-settings-form', translatable: true, configurable: { - sections: ['timestamps'], - buttons: ['create', 'delete'], + sections: ['timestamps', 'header'], + buttons: ['delete', 'create', 'submit', 'undo', 'header:copy-id', 'header:copy-json'], inputs: [ 'past-due-amount-handling', 'automatically-charge-past-due-amount', diff --git a/src/elements/public/SubscriptionSettingsForm/SubscriptionSettingsForm.test.ts b/src/elements/public/SubscriptionSettingsForm/SubscriptionSettingsForm.test.ts index 25f888a0c..8448326fc 100644 --- a/src/elements/public/SubscriptionSettingsForm/SubscriptionSettingsForm.test.ts +++ b/src/elements/public/SubscriptionSettingsForm/SubscriptionSettingsForm.test.ts @@ -14,6 +14,7 @@ import { InternalTextControl } from '../../internal/InternalTextControl/Internal import { InternalForm } from '../../internal/InternalForm/InternalForm'; import { createRouter } from '../../../server'; import { getTestData } from '../../../testgen/getTestData'; +import { stub } from 'sinon'; describe('SubscriptionSettingsForm', () => { it('imports and defines foxy-internal-checkbox-group-control', () => { @@ -118,6 +119,18 @@ describe('SubscriptionSettingsForm', () => { expect(form.errors).to.include('reattempt-schedule:v8n_too_long'); }); + it('renders a form header', async () => { + const form = new Form(); + const renderHeaderMethod = stub(form, 'renderHeader'); + form.render(); + expect(renderHeaderMethod).to.have.been.called; + }); + + it('always hides Copy ID button', () => { + const form = new Form(); + expect(form.hiddenSelector.matches('header:copy-id', true)).to.be.true; + }); + it('renders radio group with past due amount handling options', async () => { const router = createRouter(); const element = await fixture(html` diff --git a/src/elements/public/SubscriptionSettingsForm/SubscriptionSettingsForm.ts b/src/elements/public/SubscriptionSettingsForm/SubscriptionSettingsForm.ts index bceb25f25..6831df852 100644 --- a/src/elements/public/SubscriptionSettingsForm/SubscriptionSettingsForm.ts +++ b/src/elements/public/SubscriptionSettingsForm/SubscriptionSettingsForm.ts @@ -1,10 +1,11 @@ -import type { Data, Templates } from './types'; +import type { Data } from './types'; import type { TemplateResult } from 'lit-html'; import type { NucleonV8N } from '../NucleonElement/types'; import type { Option } from '../../internal/InternalCheckboxGroupControl/types'; import type { Item } from '../../internal/InternalEditableListControl/types'; import { TranslatableMixin } from '../../../mixins/translatable'; +import { BooleanSelector } from '@foxy.io/sdk/core'; import { InternalForm } from '../../internal/InternalForm/InternalForm'; import { html } from 'lit-html'; @@ -14,48 +15,6 @@ const Base = TranslatableMixin(InternalForm, NS); /** * Form element for managing `fx:subscription_settings` resources. * - * @slot past-due-amount-handling:before - * @slot past-due-amount-handling:after - * - * @slot automatically-charge-past-due-amount:before - * @slot automatically-charge-past-due-amount:after - * - * @slot clear-past-due-amounts-on-success:before – only if `form.automatically_charge_past_due_amount` is `false` - * @slot clear-past-due-amounts-on-success:after – only if `form.automatically_charge_past_due_amount` is `false` - * - * @slot reset-nextdate-on-makeup-payment:before – only if `form.automatically_charge_past_due_amount` is `false` - * @slot reset-nextdate-on-makeup-payment:after – only if `form.automatically_charge_past_due_amount` is `false` - * - * @slot reattempt-bypass:before - * @slot reattempt-bypass:after - * - * @slot reattempt-schedule:before - * @slot reattempt-schedule:after - * - * @slot reminder-email-schedule:before - * @slot reminder-email-schedule:after - * - * @slot expiring-soon-payment-reminder-schedule:before - * @slot expiring-soon-payment-reminder-schedule:after - * - * @slot send-email-receipts-for-automated-billing:before - * @slot send-email-receipts-for-automated-billing:after - * - * @slot cancellation-schedule:before - * @slot cancellation-schedule:after - * - * @slot modification-url:before - * @slot modification-url:after - * - * @slot timestamps:before - * @slot timestamps:after - * - * @slot create:before - * @slot create:after - * - * @slot delete:before - * @slot delete:after - * * @element foxy-subscription-settings-form * @since 1.21.0 */ @@ -77,8 +36,6 @@ export class SubscriptionSettingsForm extends Base { ]; } - templates: Templates = {}; - private __sendEmailReceiptsForAutomatedBillingOptions: Option[] = [ { label: 'option_checked', value: 'checked' }, ]; @@ -188,8 +145,14 @@ export class SubscriptionSettingsForm extends Base { this.edit({ reattempt_schedule: newItems.map(({ value }) => value).join() }); }; + get hiddenSelector(): BooleanSelector { + return new BooleanSelector(`header:copy-id ${super.hiddenSelector}`.trim()); + } + renderBody(): TemplateResult { return html` + ${this.renderHeader()} + ; -export type Templates = { - 'past-due-amount-handling:before'?: Renderer; - 'past-due-amount-handling:after'?: Renderer; - 'automatically-charge-past-due-amount:before'?: Renderer; - 'automatically-charge-past-due-amount:after'?: Renderer; - 'clear-past-due-amounts-on-success:before'?: Renderer; - 'clear-past-due-amounts-on-success:after'?: Renderer; - 'reset-nextdate-on-makeup-payment:before'?: Renderer; - 'reset-nextdate-on-makeup-payment:after'?: Renderer; - 'reattempt-bypass:before'?: Renderer; - 'reattempt-bypass:after'?: Renderer; - 'reattempt-schedule:before'?: Renderer; - 'reattempt-schedule:after'?: Renderer; - 'reminder-email-schedule:before'?: Renderer; - 'reminder-email-schedule:after'?: Renderer; - 'expiring-soon-payment-reminder-schedule:before'?: Renderer; - 'expiring-soon-payment-reminder-schedule:after'?: Renderer; - 'send-email-receipts-for-automated-billing:before'?: Renderer; - 'send-email-receipts-for-automated-billing:after'?: Renderer; - 'cancellation-schedule:before'?: Renderer; - 'cancellation-schedule:after'?: Renderer; - 'modification-url:before'?: Renderer; - 'modification-url:after'?: Renderer; - 'timestamps:before'?: Renderer; - 'timestamps:after'?: Renderer; - 'create:before'?: Renderer; - 'create:after'?: Renderer; - 'delete:before'?: Renderer; - 'delete:after'?: Renderer; -}; diff --git a/src/elements/public/SubscriptionsTable/types.ts b/src/elements/public/SubscriptionsTable/types.ts index f6ca76bcd..72c149a35 100644 --- a/src/elements/public/SubscriptionsTable/types.ts +++ b/src/elements/public/SubscriptionsTable/types.ts @@ -1,7 +1,4 @@ import type * as FoxySDK from '@foxy.io/sdk'; -import { Templates as TableTemplates } from '../Table/types'; - export type Rel = FoxySDK.Backend.Rels.Subscriptions; export type Data = FoxySDK.Core.Resource; -export type Templates = TableTemplates; diff --git a/src/elements/public/Table/Table.ts b/src/elements/public/Table/Table.ts index d93824c83..5180e0bf5 100644 --- a/src/elements/public/Table/Table.ts +++ b/src/elements/public/Table/Table.ts @@ -1,4 +1,4 @@ -import { Collection, Column, Templates } from './types'; +import { Collection, Column } from './types'; import { TemplateResult, html } from 'lit-html'; import { ConfigurableMixin } from '../../../mixins/configurable'; @@ -26,8 +26,6 @@ export class Table extends Base { }; } - templates: Templates = {}; - /** Array of column templates. See `Column` type for more details. */ columns: Column[] = []; diff --git a/src/elements/public/Table/types.ts b/src/elements/public/Table/types.ts index 4c3eb8601..7de736075 100644 --- a/src/elements/public/Table/types.ts +++ b/src/elements/public/Table/types.ts @@ -1,8 +1,6 @@ import { TemplateResult, html } from 'lit-html'; import { Primitive } from 'lit-html/lib/parts'; -import { Renderer } from '../../../mixins/configurable'; -import { Table } from './Table'; export type Collection = { readonly _links: Record<'next' | 'self', { href: string }>; @@ -34,7 +32,3 @@ export type Column = { header?: (context: HeaderContext) => TemplateResult | Primitive; cell?: (context: CellContext) => TemplateResult | Primitive; }; - -export type Templates = { - default?: Renderer>; -}; diff --git a/src/elements/public/TaxCard/TaxCard.test.ts b/src/elements/public/TaxCard/TaxCard.test.ts index 6eb3c32d7..fa3582556 100644 --- a/src/elements/public/TaxCard/TaxCard.test.ts +++ b/src/elements/public/TaxCard/TaxCard.test.ts @@ -14,6 +14,12 @@ import { InternalCard } from '../../internal/InternalCard/InternalCard'; const router = createRouter(); describe('TaxCard', () => { + const OriginalResizeObserver = window.ResizeObserver; + + // @ts-expect-error disabling ResizeObserver because it errors in test env + before(() => (window.ResizeObserver = undefined)); + after(() => (window.ResizeObserver = OriginalResizeObserver)); + it('extends InternalCard', () => { expect(new TaxCard()).to.be.instanceOf(InternalCard); }); diff --git a/src/elements/public/TaxCard/TaxCard.ts b/src/elements/public/TaxCard/TaxCard.ts index 905fb2f21..45f6c878c 100644 --- a/src/elements/public/TaxCard/TaxCard.ts +++ b/src/elements/public/TaxCard/TaxCard.ts @@ -1,41 +1,25 @@ -import { TemplateResult, html } from 'lit-html'; +import type { TemplateResult } from 'lit-html'; +import type { Data } from './types'; -import { Data } from './types'; import { TranslatableMixin } from '../../../mixins/translatable'; -import { ConfigurableMixin } from '../../../mixins/configurable'; -import { InternalCard } from '../../internal/InternalCard/InternalCard'; +import { TwoLineCard } from '../CustomFieldCard/TwoLineCard'; +import { html } from 'lit-html'; /** * Basic card displaying a tax. * - * @slot title:before - * @slot title:after - * - * @slot subtitle:before - * @slot subtitle:after - * * @element foxy-tax-card * @since 1.13.0 */ -export class TaxCard extends TranslatableMixin(ConfigurableMixin(InternalCard), 'tax-card') { +export class TaxCard extends TranslatableMixin(TwoLineCard, 'tax-card') { renderBody(): TemplateResult { - const data = this.data; - - return html` -
-
- ${data?.name}​ -
-
- ${this.__typeLabel} • ${this.__rateLabel} -
-
- `; + return super.renderBody({ + title: data => html`${data.name}`, + subtitle: data => html`${this.getTypeLabel(data)} • ${this.getRateLabel(data)}`, + }); } - private get __typeLabel() { - const { type, country, region, city } = this.data ?? {}; - + private getTypeLabel({ type, country, region, city }: Data) { if (type === 'global') return this.t('tax_global'); if (type === 'union') return this.t('tax_union'); if (type === 'country') return country; @@ -43,13 +27,10 @@ export class TaxCard extends TranslatableMixin(ConfigurableMixin(InternalCard), if (type === 'local') return `${country}, ${region}, ${city}`; } - private get __rateLabel() { - if (this.data?.is_live === false) { - return this.t('percent', { fraction: this.data.rate / 100 }); - } + private getRateLabel({ is_live, rate }: Data) { + if (!is_live) return this.t('percent', { fraction: rate / 100 }); const provider = this.data?.service_provider as string | undefined; - if (provider === 'onesource') return 'Thomson Reuters ONESOURCE'; if (provider === 'avalara') return 'Avalara AvaTax 15'; if (provider === 'taxjar') return 'TaxJar'; diff --git a/src/elements/public/TaxCard/index.ts b/src/elements/public/TaxCard/index.ts index 89b2ebba3..b7b37516b 100644 --- a/src/elements/public/TaxCard/index.ts +++ b/src/elements/public/TaxCard/index.ts @@ -1,4 +1,6 @@ -import '../../internal/InternalCard/index'; +import '../../internal/InternalSandbox/index'; + +import '../Spinner/index'; import { TaxCard } from './TaxCard'; diff --git a/src/elements/public/TaxForm/TaxForm.ts b/src/elements/public/TaxForm/TaxForm.ts index 29c8658ff..41ed2ea3b 100644 --- a/src/elements/public/TaxForm/TaxForm.ts +++ b/src/elements/public/TaxForm/TaxForm.ts @@ -1,6 +1,6 @@ import { Checkbox, Dropdown, Metadata } from '../../private/index'; import { CheckboxChangeEvent, DropdownChangeEvent } from '../../private/events'; -import { Data, Templates } from './types'; +import { Data } from './types'; import { Nucleon, Resource } from '@foxy.io/sdk/core'; import { ScopedElementsMap, ScopedElementsMixin } from '@open-wc/scoped-elements'; import { TemplateResult, html } from 'lit-html'; @@ -34,45 +34,6 @@ const Base = ConfigurableMixin( /** * Form element for creating or editing taxes (`fx:tax`). * - * @slot name:before - * @slot name:after - * - * @slot type:before - * @slot type:after - * - * @slot country:before - * @slot country:after - * - * @slot region:before - * @slot region:after - * - * @slot city:before - * @slot city:after - * - * @slot provider:before - * @slot provider:after - * - * @slot rate:before - * @slot rate:after - * - * @slot apply-to-shipping:before - * @slot apply-to-shipping:after - * - * @slot use-origin-rates:before - * @slot use-origin-rates:after - * - * @slot exempt-all-customer-tax-ids:before - * @slot exempt-all-customer-tax-ids:after - * - * @slot timestamps:before - * @slot timestamps:after - * - * @slot delete:before - * @slot delete:after - * - * @slot create:before - * @slot create:after - * * @element foxy-tax-form * @since 1.13.0 */ @@ -117,8 +78,6 @@ export class TaxForm extends Base { ]; } - templates: Templates = {}; - private __previousCountry: string | undefined = undefined; private __countries = ''; @@ -391,11 +350,15 @@ export class TaxForm extends Base { } private __renderCountry(): TemplateResult { - const isLoadingItems = this.__countriesService.state.matches('busy'); + const isLoadingItems = !!this.__countriesService.state?.matches('busy'); const isLoadingData = this.in('busy'); const isLoading = isLoadingItems || isLoadingData; const isFail = this.in('fail'); - const json = this.__countriesService.state.context.data as Resource | null; + const json = this.__countriesService.state?.context.data as + | Resource + | undefined + | null; + const items = Object.values(json?.values ?? {}); return html` @@ -438,11 +401,15 @@ export class TaxForm extends Base { } private __renderRegion(): TemplateResult { - const isLoadingItems = this.__regionsService.state.matches('busy'); + const isLoadingItems = !!this.__regionsService.state?.matches('busy'); const isLoadingData = this.in('busy'); const isLoading = isLoadingItems || isLoadingData; const isFail = this.in('fail'); - const json = this.__regionsService.state.context.data as Resource | null; + const json = this.__regionsService.state?.context.data as + | Resource + | undefined + | null; + const items = Object.values(json?.values ?? {}); return html` diff --git a/src/elements/public/TaxForm/types.ts b/src/elements/public/TaxForm/types.ts index 455f8585e..4300bf272 100644 --- a/src/elements/public/TaxForm/types.ts +++ b/src/elements/public/TaxForm/types.ts @@ -1,35 +1,4 @@ -import { Rels } from '@foxy.io/sdk/backend'; -import { Renderer } from '../../../mixins/configurable'; -import { Resource } from '@foxy.io/sdk/core'; -import { TaxForm } from './TaxForm'; +import type { Resource } from '@foxy.io/sdk/core'; +import type { Rels } from '@foxy.io/sdk/backend'; export type Data = Resource; - -export type Templates = { - 'name:before'?: Renderer; - 'name:after'?: Renderer; - 'type:before'?: Renderer; - 'type:after'?: Renderer; - 'country:before'?: Renderer; - 'country:after'?: Renderer; - 'region:before'?: Renderer; - 'region:after'?: Renderer; - 'city:before'?: Renderer; - 'city:after'?: Renderer; - 'provider:before'?: Renderer; - 'provider:after'?: Renderer; - 'rate:before'?: Renderer; - 'rate:after'?: Renderer; - 'apply-to-shipping:before'?: Renderer; - 'apply-to-shipping:after'?: Renderer; - 'use-origin-rates:before'?: Renderer; - 'use-origin-rates:after'?: Renderer; - 'exempt-all-customer-tax-ids:before'?: Renderer; - 'exempt-all-customer-tax-ids:after'?: Renderer; - 'timestamps:before'?: Renderer; - 'timestamps:after'?: Renderer; - 'delete:before'?: Renderer; - 'delete:after'?: Renderer; - 'create:before'?: Renderer; - 'create:after'?: Renderer; -}; diff --git a/src/elements/public/TemplateConfigForm/TemplateConfigForm.ts b/src/elements/public/TemplateConfigForm/TemplateConfigForm.ts index 100b1b1f0..d1e693160 100644 --- a/src/elements/public/TemplateConfigForm/TemplateConfigForm.ts +++ b/src/elements/public/TemplateConfigForm/TemplateConfigForm.ts @@ -1,7 +1,7 @@ import * as logos from '../PaymentMethodCard/logos'; import { CheckboxChangeEvent, ChoiceChangeEvent } from '../../private/events'; -import { Data, TemplateConfigJSON, Templates } from './types'; +import { Data, TemplateConfigJSON } from './types'; import { ScopedElementsMap, ScopedElementsMixin } from '@open-wc/scoped-elements'; import { TemplateResult, html } from 'lit-html'; @@ -29,50 +29,6 @@ const Base = ScopedElementsMixin( /** * Form element for creating or editing template configs (`fx:template_config`). * - * @slot cart-type:before - * @slot cart-type:after - * - * @slot foxycomplete:before - * @slot foxycomplete:after - * - * @slot locations:before - * @slot locations:after - * - * @slot hidden-fields:before - * @slot hidden-fields:after - * - * @slot cards:before - * @slot cards:after - * - * @slot checkout-type:before - * @slot checkout-type:after - * - * @slot consent:before - * @slot consent:after - * - * @slot fields:before - * @slot fields:after - * - * @slot google-analytics:before - * @slot google-analytics:after - * - * @slot google-tag:before - * @slot google-tag:after - * - * @slot troubleshooting:before - * @slot troubleshooting:after - * - * @slot custom-config:before - * @slot custom-config:after - * - * @slot header:before - * @slot header:after - * - * @slot custom-fields:before - * @slot custom-fields:after - * - * @slot footer:before - * @slot footer:after * * @element foxy-template-config-form * @since 1.14.0 @@ -102,8 +58,6 @@ export class TemplateConfigForm extends Base { }; } - templates: Templates = {}; - /** URI of the `fx:countries` hAPI resource. */ countries = ''; diff --git a/src/elements/public/TemplateConfigForm/types.ts b/src/elements/public/TemplateConfigForm/types.ts index 2d7ac3f11..e249c35f2 100644 --- a/src/elements/public/TemplateConfigForm/types.ts +++ b/src/elements/public/TemplateConfigForm/types.ts @@ -1,60 +1,8 @@ -import { Rels } from '@foxy.io/sdk/backend'; -import { Renderer } from '../../../mixins/configurable'; -import { Resource } from '@foxy.io/sdk/core'; -import { TemplateConfigForm } from './TemplateConfigForm'; +import type { Resource } from '@foxy.io/sdk/core'; +import type { Rels } from '@foxy.io/sdk/backend'; export type Data = Resource; -export type Templates = { - 'cart-type:before'?: Renderer; - 'cart-type:after'?: Renderer; - - 'foxycomplete:before'?: Renderer; - 'foxycomplete:after'?: Renderer; - - 'locations:before'?: Renderer; - 'locations:after'?: Renderer; - - 'hidden-fields:before'?: Renderer; - 'hidden-fields:after'?: Renderer; - - 'cards:before'?: Renderer; - 'cards:after'?: Renderer; - - 'checkout-type:before'?: Renderer; - 'checkout-type:after'?: Renderer; - - 'consent:before'?: Renderer; - 'consent:after'?: Renderer; - - 'fields:before'?: Renderer; - 'fields:after'?: Renderer; - - 'google-analytics:before'?: Renderer; - 'google-analytics:after'?: Renderer; - - 'google-tag:before'?: Renderer; - 'google-tag:after'?: Renderer; - - 'segment-io:before'?: Renderer; - 'segment-io:after'?: Renderer; - - 'troubleshooting:before'?: Renderer; - 'troubleshooting:after'?: Renderer; - - 'custom-config:before'?: Renderer; - 'custom-config:after'?: Renderer; - - 'header:before'?: Renderer; - 'header:after'?: Renderer; - - 'custom-fields:before'?: Renderer; - 'custom-fields:after'?: Renderer; - - 'footer:before'?: Renderer; - 'footer:after'?: Renderer; -}; - export type TemplateConfigJSON = { /** Controls how your cart functions. */ cart_type: 'default' | 'fullpage' | 'custom'; diff --git a/src/elements/public/TemplateForm/TemplateForm.ts b/src/elements/public/TemplateForm/TemplateForm.ts index f8c84ee2e..498a3429f 100644 --- a/src/elements/public/TemplateForm/TemplateForm.ts +++ b/src/elements/public/TemplateForm/TemplateForm.ts @@ -1,6 +1,6 @@ import { PropertyDeclarations, TemplateResult, html } from 'lit-element'; import { Choice, Group, Metadata } from '../../private/index'; -import { Data, Templates } from './types'; +import { Data } from './types'; import { ScopedElementsMap, ScopedElementsMixin } from '@open-wc/scoped-elements'; import { ChoiceChangeEvent } from '../../private/events'; @@ -21,21 +21,6 @@ const Base = ScopedElementsMixin( /** * Form element for creating or editing templates (`fx:cart_include_template`, `fx:checkout_template`, `fx:cart_template`). * - * @slot description:before - * @slot description:after - * - * @slot content:before - * @slot content:after - * - * @slot timestamps:before - * @slot timestamps:after - * - * @slot create:before - * @slot create:after - * - * @slot delete:before - * @slot delete:after - * * @element foxy-template-form * @since 1.14.0 */ @@ -63,8 +48,6 @@ export class TemplateForm extends Base { }; } - templates: Templates = {}; - private __cacheState: 'idle' | 'busy' | 'fail' = 'idle'; private __contentChoice: 'default' | 'url' | 'clipboard' = 'default'; diff --git a/src/elements/public/TemplateForm/types.ts b/src/elements/public/TemplateForm/types.ts index 64f95152f..1b4bdc582 100644 --- a/src/elements/public/TemplateForm/types.ts +++ b/src/elements/public/TemplateForm/types.ts @@ -1,22 +1,7 @@ -import { Rels } from '@foxy.io/sdk/backend'; -import { Renderer } from '../../../mixins/configurable'; -import { Resource } from '@foxy.io/sdk/core'; -import { TemplateForm } from './TemplateForm'; +import type { Resource } from '@foxy.io/sdk/core'; +import type { Rels } from '@foxy.io/sdk/backend'; export type Data = | Resource | Resource | Resource; - -export type Templates = { - 'description:before'?: Renderer; - 'description:after'?: Renderer; - 'content:before'?: Renderer; - 'content:after'?: Renderer; - 'timestamps:before'?: Renderer; - 'timestamps:after'?: Renderer; - 'create:before'?: Renderer; - 'create:after'?: Renderer; - 'delete:before'?: Renderer; - 'delete:after'?: Renderer; -}; diff --git a/src/elements/public/TemplateSetCard/TemplateSetCard.ts b/src/elements/public/TemplateSetCard/TemplateSetCard.ts index 5ebb27d13..4abe19c09 100644 --- a/src/elements/public/TemplateSetCard/TemplateSetCard.ts +++ b/src/elements/public/TemplateSetCard/TemplateSetCard.ts @@ -11,12 +11,6 @@ const Base = TranslatableMixin(TwoLineCard, NS); /** * Card element representing a template set (`fx:template_set`). * - * @slot title:before - * @slot title:after - * - * @slot subtitle:before - * @slot subtitle:after - * * @element foxy-template-set-card * @since 1.21.0 */ diff --git a/src/elements/public/TemplateSetForm/TemplateSetForm.stories.ts b/src/elements/public/TemplateSetForm/TemplateSetForm.stories.ts index 7ea84ee22..0a8a76a64 100644 --- a/src/elements/public/TemplateSetForm/TemplateSetForm.stories.ts +++ b/src/elements/public/TemplateSetForm/TemplateSetForm.stories.ts @@ -11,8 +11,8 @@ const summary: Summary = { localName: 'foxy-template-set-form', translatable: true, configurable: { - sections: ['timestamps'], - buttons: ['create', 'delete'], + sections: ['timestamps', 'header'], + buttons: ['delete', 'create', 'submit', 'undo', 'header:copy-id', 'header:copy-json'], inputs: [ 'description', 'code', diff --git a/src/elements/public/TemplateSetForm/TemplateSetForm.test.ts b/src/elements/public/TemplateSetForm/TemplateSetForm.test.ts index 8e149c043..167dcce22 100644 --- a/src/elements/public/TemplateSetForm/TemplateSetForm.test.ts +++ b/src/elements/public/TemplateSetForm/TemplateSetForm.test.ts @@ -6,7 +6,7 @@ import type { Data } from './types'; import './index'; import { expect, fixture, html, waitUntil } from '@open-wc/testing'; -import { InternalAsyncComboBoxControl } from '../../internal/InternalAsyncComboBoxControl/InternalAsyncComboBoxControl'; +import { InternalResourcePickerControl } from '../../internal/InternalResourcePickerControl/InternalResourcePickerControl'; import { TemplateSetForm as Form } from './TemplateSetForm'; import { InternalSelectControl } from '../../internal/InternalSelectControl/InternalSelectControl'; import { InternalTextControl } from '../../internal/InternalTextControl/InternalTextControl'; @@ -26,9 +26,9 @@ describe('TemplateSetForm', () => { before(() => (window.ResizeObserver = undefined)); after(() => (window.ResizeObserver = OriginalResizeObserver)); - it('imports and registers foxy-internal-async-combo-box-control element', () => { - const constructor = customElements.get('foxy-internal-async-combo-box-control'); - expect(constructor).to.equal(InternalAsyncComboBoxControl); + it('imports and registers foxy-internal-resource-picker-control element', () => { + const constructor = customElements.get('foxy-internal-resource-picker-control'); + expect(constructor).to.equal(InternalResourcePickerControl); }); it('imports and registers foxy-internal-select-control element', () => { @@ -97,6 +97,24 @@ describe('TemplateSetForm', () => { expect(Form).to.have.nested.property('properties.languages'); }); + it('renders a form header', async () => { + const form = new Form(); + const renderHeaderMethod = stub(form, 'renderHeader'); + form.render(); + expect(renderHeaderMethod).to.have.been.called; + }); + + it('renders a custom header subtitle for default template set', async () => { + const form = new Form(); + const data = await getTestData('./hapi/template_sets/0'); + + form.data = { ...data, code: 'DEFAULT' }; + expect(form.headerSubtitleOptions).to.have.property('context', 'default'); + + form.data = { ...data, code: 'CUSTOM' }; + expect(form.headerSubtitleOptions).to.have.property('context', ''); + }); + it('renders a textbox for code', async () => { const router = createRouter(); const element = await fixture(html` @@ -183,7 +201,7 @@ describe('TemplateSetForm', () => { expect(control).to.have.deep.property('options', options); }); - it('renders a combobox dropdown for payment method set', async () => { + it('renders a resource picker control for payment method set', async () => { const router = createRouter(); const data = await getTestData('https://demo.api/hapi/template_sets/0', router); const element = await fixture(html` @@ -199,21 +217,14 @@ describe('TemplateSetForm', () => { await element.requestUpdate(); const root = element.renderRoot; - const control = root.querySelector( + const control = root.querySelector( '[infer="payment-method-set-uri"]' )!; - await waitUntil(() => !!control.selectedItem); - expect(control).to.exist; - expect(control).to.be.instanceOf(InternalAsyncComboBoxControl); - expect(control).to.have.attribute('item-label-path', 'description'); - expect(control).to.have.attribute('item-id-path', '_links.self.href'); + expect(control).to.be.instanceOf(InternalResourcePickerControl); expect(control).to.have.attribute('first', element.paymentMethodSets as string); - expect(control).to.have.deep.property( - 'selectedItem', - await getTestData(data.payment_method_set_uri, router) - ); + expect(control).to.have.attribute('item', 'foxy-payments-api-payment-preset-card'); }); it('renders i18n editor in snapshot state', async () => { diff --git a/src/elements/public/TemplateSetForm/TemplateSetForm.ts b/src/elements/public/TemplateSetForm/TemplateSetForm.ts index a67619bed..7aca68ed9 100644 --- a/src/elements/public/TemplateSetForm/TemplateSetForm.ts +++ b/src/elements/public/TemplateSetForm/TemplateSetForm.ts @@ -1,5 +1,5 @@ import type { PropertyDeclarations } from 'lit-element'; -import type { Data, Templates } from './types'; +import type { Data } from './types'; import type { NucleonElement } from '../NucleonElement/NucleonElement'; import type { TemplateResult } from 'lit-html'; import type { NucleonV8N } from '../NucleonElement/types'; @@ -19,33 +19,6 @@ const Base = ResponsiveMixin(TranslatableMixin(InternalForm, NS)); /** * Form element for creating and editing template sets (`fx:template_set`). * - * @slot description:before - * @slot description:after - * - * @slot code:before - * @slot code:after - * - * @slot language:before - * @slot language:after - * - * @slot locale-code:before - * @slot locale-code:after - * - * @slot payment-method-set-uri:before - * @slot payment-method-set-uri:after - * - * @slot language-overrides:before - * @slot language-overrides:after - * - * @slot timestamps:before - * @slot timestamps:after - * - * @slot create:before - * @slot create:after - * - * @slot delete:before - * @slot delete:after - * * @element foxy-template-set-form * @since 1.21.0 */ @@ -83,36 +56,27 @@ export class TemplateSetForm extends Base { /** URL of the `fx:languages` property helper (used to fill the relevant dropdown with options). */ languages: string | null = null; - /** Template render functions mapped to their name. */ - templates: Templates = {}; - - private readonly __paymentMethodSetLoaderId = 'paymentMethodSetLoader'; - private readonly __localeCodesLoaderId = 'localeCodesLoader'; private readonly __languagesLoaderId = 'languagesLoader'; + get headerSubtitleOptions(): Record { + return { + ...super.headerSubtitleOptions, + context: this.data?.code === 'DEFAULT' ? 'default' : '', + }; + } + get disabledSelector(): BooleanSelector { const alwaysDisabled: string[] = []; - if (!this.__languagesLoader?.data) alwaysDisabled.push('language'); if (!this.__localeCodesLoader?.data) alwaysDisabled.push('locale-code'); - if (!this.__paymentMethodSetLoader?.data && this.form.payment_method_set_uri) { - alwaysDisabled.push('payment-method-set-uri'); - } - return new BooleanSelector(`${alwaysDisabled.join(' ')} ${super.disabledSelector}`); } - get readonlySelector(): BooleanSelector { - const alwaysReadonly: string[] = []; - if (this.data?.code === 'DEFAULT') alwaysReadonly.push('code', 'description'); - return new BooleanSelector(`${alwaysReadonly.join(' ')} ${super.readonlySelector}`); - } - get hiddenSelector(): BooleanSelector { const alwaysHidden: string[] = []; - if (this.data?.code === 'DEFAULT') alwaysHidden.push('delete'); + if (this.data?.code === 'DEFAULT') alwaysHidden.push('delete', 'code', 'description'); return new BooleanSelector(`${alwaysHidden.join(' ')} ${super.hiddenSelector}`); } @@ -124,6 +88,8 @@ export class TemplateSetForm extends Base { const languages = languageEntries.map(([value, label]) => ({ value, label })); return html` + ${this.renderHeader()} +
@@ -136,30 +102,30 @@ export class TemplateSetForm extends Base {
- - + ${this.data && this.languageStrings && !this.hiddenSelector.matches('language-overrides', true) ? html` - ${this.renderTemplateOrSlot('language-overrides:before')} - - - - - ${this.renderTemplateOrSlot('language-overrides:after')} +
+ ${this.renderTemplateOrSlot('language-overrides:before')} + + + + + ${this.renderTemplateOrSlot('language-overrides:after')} +
` : ''} @@ -184,23 +150,9 @@ export class TemplateSetForm extends Base { @update=${() => this.requestUpdate()} > - - `; } - private get __paymentMethodSetLoader() { - type Loader = NucleonElement>; - return this.renderRoot.querySelector(`#${this.__paymentMethodSetLoaderId}`); - } - private get __localeCodesLoader() { type Loader = NucleonElement>; return this.renderRoot.querySelector(`#${this.__localeCodesLoaderId}`); diff --git a/src/elements/public/TemplateSetForm/index.ts b/src/elements/public/TemplateSetForm/index.ts index e906768cc..23e6ab5fc 100644 --- a/src/elements/public/TemplateSetForm/index.ts +++ b/src/elements/public/TemplateSetForm/index.ts @@ -1,9 +1,10 @@ -import '../../internal/InternalAsyncComboBoxControl/index'; +import '../../internal/InternalResourcePickerControl/index'; import '../../internal/InternalSelectControl/index'; import '../../internal/InternalTextControl/index'; import '../../internal/InternalSandbox/index'; import '../../internal/InternalForm/index'; +import '../PaymentsApiPaymentPresetCard/index'; import '../NucleonElement/index'; import '../I18nEditor/index'; diff --git a/src/elements/public/TemplateSetForm/types.ts b/src/elements/public/TemplateSetForm/types.ts index bf8e518bc..e53a46c28 100644 --- a/src/elements/public/TemplateSetForm/types.ts +++ b/src/elements/public/TemplateSetForm/types.ts @@ -1,27 +1,4 @@ -import type { TemplateSetForm } from './TemplateSetForm'; -import type { Renderer } from '../../../mixins/configurable'; import type { Resource } from '@foxy.io/sdk/core'; import type { Rels } from '@foxy.io/sdk/backend'; export type Data = Resource; - -export type Templates = { - 'description:before'?: Renderer; - 'description:after'?: Renderer; - 'code:before'?: Renderer; - 'code:after'?: Renderer; - 'language:before'?: Renderer; - 'language:after'?: Renderer; - 'locale-code:before'?: Renderer; - 'locale-code:after'?: Renderer; - 'payment-method-set-uri:before'?: Renderer; - 'payment-method-set-uri:after'?: Renderer; - 'language-overrides:before'?: Renderer; - 'language-overrides:after'?: Renderer; - 'timestamps:before'?: Renderer; - 'timestamps:after'?: Renderer; - 'create:before'?: Renderer; - 'create:after'?: Renderer; - 'delete:before'?: Renderer; - 'delete:after'?: Renderer; -}; diff --git a/src/elements/public/Transaction/Transaction.test.ts b/src/elements/public/Transaction/Transaction.test.ts index 1c5cb11f0..5af3b5038 100644 --- a/src/elements/public/Transaction/Transaction.test.ts +++ b/src/elements/public/Transaction/Transaction.test.ts @@ -4,7 +4,7 @@ import { InternalForm } from '../../internal/InternalForm/InternalForm'; import { html } from 'lit-html'; import { createRouter } from '../../../server/index'; import { FetchEvent } from '../NucleonElement/FetchEvent'; -import { getByKey } from '../../../testgen/getByKey'; +import { stub } from 'sinon'; describe('Transaction', () => { const OriginalResizeObserver = window.ResizeObserver; @@ -118,42 +118,11 @@ describe('Transaction', () => { expect(new Transaction()).to.be.instanceOf(InternalForm); }); - it('renders translatable title in header', async () => { - const router = createRouter(); - const element = await fixture(html` - router.handleEvent(evt)} - > - - `); - - await waitUntil(() => element.in({ idle: 'snapshot' })); - await element.requestUpdate(); - const title = await getByKey(element, 'title'); - - expect(title).to.exist; - expect(title).to.have.attribute('infer', 'header'); - expect(title).to.have.property('options', element.data); - }); - - it('renders a copy-to-clipboard button in header', async () => { - const router = createRouter(); - const element = await fixture(html` - router.handleEvent(evt)} - > - - `); - - await waitUntil(() => element.in({ idle: 'snapshot' })); - await element.requestUpdate(); - const button = element.renderRoot.querySelector('foxy-copy-to-clipboard'); - - expect(button).to.exist; - expect(button).to.have.attribute('infer', 'header'); - expect(button).to.have.attribute('text', String(element.data!.display_id)); + it('renders a form header', () => { + const form = new Transaction(); + const renderHeaderMethod = stub(form, 'renderHeader'); + form.render(); + expect(renderHeaderMethod).to.have.been.called; }); it('renders a special subtitle for payment method changes initiated by customer', async () => { @@ -170,12 +139,17 @@ describe('Transaction', () => { element.data = { ...element.data!, type: 'updateinfo', source: 'cit_ecommerce' }; await element.requestUpdate(); - const subtitle = element.renderRoot.querySelectorAll('foxy-i18n[infer="header"]')[1]; - expect(subtitle).to.have.attribute('key', 'subtitle_customer_changed_payment_method'); + expect(element.headerSubtitleOptions).to.have.property( + 'context', + 'customer_changed_payment_method' + ); element.data = { ...element.data!, source: 'mit_api' }; await element.requestUpdate(); - expect(subtitle).to.not.have.attribute('key', 'subtitle_customer_changed_payment_method'); + expect(element.headerSubtitleOptions).to.not.have.property( + 'context', + 'customer_changed_payment_method' + ); }); it('renders a special subtitle for payment method changes made with UOE password', async () => { @@ -192,14 +166,16 @@ describe('Transaction', () => { element.data = { ...element.data!, type: 'updateinfo', source: 'mit_uoe' }; await element.requestUpdate(); - const subtitle = element.renderRoot.querySelectorAll('foxy-i18n[infer="header"]')[1]; - expect(subtitle).to.have.attribute('key', 'subtitle_admin_changed_payment_method_with_uoe'); + expect(element.headerSubtitleOptions).to.have.property( + 'context', + 'admin_changed_payment_method_with_uoe' + ); element.data = { ...element.data!, source: 'cit_ecommerce' }; await element.requestUpdate(); - expect(subtitle).to.not.have.attribute( - 'key', - 'subtitle_customer_changed_payment_method_with_uoe' + expect(element.headerSubtitleOptions).to.not.have.property( + 'context', + 'admin_changed_payment_method_with_uoe' ); }); @@ -217,12 +193,17 @@ describe('Transaction', () => { element.data = { ...element.data!, type: 'updateinfo', source: 'mit_api' }; await element.requestUpdate(); - const subtitle = element.renderRoot.querySelectorAll('foxy-i18n[infer="header"]')[1]; - expect(subtitle).to.have.attribute('key', 'subtitle_integration_changed_payment_method'); + expect(element.headerSubtitleOptions).to.have.property( + 'context', + 'integration_changed_payment_method' + ); element.data = { ...element.data!, source: 'cit_ecommerce' }; await element.requestUpdate(); - expect(subtitle).to.not.have.attribute('key', 'subtitle_integration_changed_payment_method'); + expect(element.headerSubtitleOptions).to.not.have.property( + 'context', + 'integration_changed_payment_method' + ); }); it('renders a special subtitle for subscription changes initiated by customer', async () => { @@ -239,12 +220,17 @@ describe('Transaction', () => { element.data = { ...element.data!, type: 'subscription_modification', source: 'cit_ecommerce' }; await element.requestUpdate(); - const subtitle = element.renderRoot.querySelectorAll('foxy-i18n[infer="header"]')[1]; - expect(subtitle).to.have.attribute('key', 'subtitle_customer_changed_subscription'); + expect(element.headerSubtitleOptions).to.have.property( + 'context', + 'customer_changed_subscription' + ); element.data = { ...element.data!, source: 'mit_api' }; await element.requestUpdate(); - expect(subtitle).to.not.have.attribute('key', 'subtitle_customer_changed_subscription'); + expect(element.headerSubtitleOptions).to.not.have.property( + 'context', + 'customer_changed_subscription' + ); }); it('renders a special subtitle for subscription changes made with UOE password', async () => { @@ -261,14 +247,16 @@ describe('Transaction', () => { element.data = { ...element.data!, type: 'subscription_modification', source: 'mit_uoe' }; await element.requestUpdate(); - const subtitle = element.renderRoot.querySelectorAll('foxy-i18n[infer="header"]')[1]; - expect(subtitle).to.have.attribute('key', 'subtitle_admin_changed_subscription_with_uoe'); + expect(element.headerSubtitleOptions).to.have.property( + 'context', + 'admin_changed_subscription_with_uoe' + ); element.data = { ...element.data!, source: 'cit_ecommerce' }; await element.requestUpdate(); - expect(subtitle).to.not.have.attribute( - 'key', - 'subtitle_customer_changed_subscription_with_uoe' + expect(element.headerSubtitleOptions).to.not.have.property( + 'context', + 'admin_changed_subscription_with_uoe' ); }); @@ -286,12 +274,17 @@ describe('Transaction', () => { element.data = { ...element.data!, type: 'subscription_modification', source: 'mit_api' }; await element.requestUpdate(); - const subtitle = element.renderRoot.querySelectorAll('foxy-i18n[infer="header"]')[1]; - expect(subtitle).to.have.attribute('key', 'subtitle_integration_changed_subscription'); + expect(element.headerSubtitleOptions).to.have.property( + 'context', + 'integration_changed_subscription' + ); element.data = { ...element.data!, source: 'cit_ecommerce' }; await element.requestUpdate(); - expect(subtitle).to.not.have.attribute('key', 'subtitle_integration_changed_subscription'); + expect(element.headerSubtitleOptions).to.not.have.property( + 'context', + 'integration_changed_subscription' + ); }); it('renders a special subtitle for subscription renewal attempts', async () => { @@ -308,12 +301,17 @@ describe('Transaction', () => { element.data = { ...element.data!, type: 'subscription_renewal', source: 'mit_recurring' }; await element.requestUpdate(); - const subtitle = element.renderRoot.querySelectorAll('foxy-i18n[infer="header"]')[1]; - expect(subtitle).to.have.attribute('key', 'subtitle_subscription_renewal_attempt'); + expect(element.headerSubtitleOptions).to.have.property( + 'context', + 'subscription_renewal_attempt' + ); element.data = { ...element.data!, source: 'cit_ecommerce' }; await element.requestUpdate(); - expect(subtitle).to.not.have.attribute('key', 'subtitle_subscription_renewal_attempt'); + expect(element.headerSubtitleOptions).to.not.have.property( + 'context', + 'subscription_renewal_attempt' + ); }); it('renders a special subtitle for automated subscription renewal reattempts', async () => { @@ -334,14 +332,16 @@ describe('Transaction', () => { }; await element.requestUpdate(); - const subtitle = element.renderRoot.querySelectorAll('foxy-i18n[infer="header"]')[1]; - expect(subtitle).to.have.attribute('key', 'subtitle_subscription_renewal_automated_reattempt'); + expect(element.headerSubtitleOptions).to.have.property( + 'context', + 'subscription_renewal_automated_reattempt' + ); element.data = { ...element.data!, source: 'cit_ecommerce' }; await element.requestUpdate(); - expect(subtitle).to.not.have.attribute( - 'key', - 'subtitle_subscription_renewal_automated_reattempt' + expect(element.headerSubtitleOptions).to.not.have.property( + 'context', + 'subscription_renewal_automated_reattempt' ); }); @@ -363,12 +363,17 @@ describe('Transaction', () => { }; await element.requestUpdate(); - const subtitle = element.renderRoot.querySelectorAll('foxy-i18n[infer="header"]')[1]; - expect(subtitle).to.have.attribute('key', 'subtitle_subscription_renewal_manual_reattempt'); + expect(element.headerSubtitleOptions).to.have.property( + 'context', + 'subscription_renewal_manual_reattempt' + ); element.data = { ...element.data!, source: 'cit_ecommerce' }; await element.requestUpdate(); - expect(subtitle).to.not.have.attribute('key', 'subtitle_subscription_renewal_manual_reattempt'); + expect(element.headerSubtitleOptions).to.not.have.property( + 'context', + 'subscription_renewal_manual_reattempt' + ); }); it('renders a special subtitle for subscription cancellations initiated by customer', async () => { @@ -389,12 +394,17 @@ describe('Transaction', () => { }; await element.requestUpdate(); - const subtitle = element.renderRoot.querySelectorAll('foxy-i18n[infer="header"]')[1]; - expect(subtitle).to.have.attribute('key', 'subtitle_customer_canceled_subscription'); + expect(element.headerSubtitleOptions).to.have.property( + 'context', + 'customer_canceled_subscription' + ); element.data = { ...element.data!, source: 'mit_recurring_cancellation' }; await element.requestUpdate(); - expect(subtitle).to.not.have.attribute('key', 'subtitle_customer_canceled_subscription'); + expect(element.headerSubtitleOptions).to.not.have.property( + 'context', + 'customer_canceled_subscription' + ); }); it('renders a special subtitle for subscription cancellations initiated by merchant', async () => { @@ -415,12 +425,17 @@ describe('Transaction', () => { }; await element.requestUpdate(); - const subtitle = element.renderRoot.querySelectorAll('foxy-i18n[infer="header"]')[1]; - expect(subtitle).to.have.attribute('key', 'subtitle_admin_canceled_subscription'); + expect(element.headerSubtitleOptions).to.have.property( + 'context', + 'admin_canceled_subscription' + ); element.data = { ...element.data!, source: 'cit_recurring_cancellation' }; await element.requestUpdate(); - expect(subtitle).to.not.have.attribute('key', 'subtitle_admin_canceled_subscription'); + expect(element.headerSubtitleOptions).to.not.have.property( + 'context', + 'admin_canceled_subscription' + ); }); it('renders a special subtitle for new subscriptions', async () => { @@ -447,16 +462,15 @@ describe('Transaction', () => { await element.requestUpdate(); - const subtitle = element.renderRoot.querySelectorAll('foxy-i18n[infer="header"]')[1]; - expect(subtitle).to.have.attribute('key', 'subtitle_customer_subscribed'); + expect(element.headerSubtitleOptions).to.have.property('context', 'customer_subscribed'); element.data = { ...element.data!, source: 'mit_uoe' }; await element.requestUpdate(); - expect(subtitle).to.have.attribute('key', 'subtitle_admin_subscribed_with_uoe'); + expect(element.headerSubtitleOptions).to.have.property('context', 'admin_subscribed_with_uoe'); element.data = { ...element.data!, source: 'mit_api' }; await element.requestUpdate(); - expect(subtitle).to.have.attribute('key', 'subtitle_integration_subscribed'); + expect(element.headerSubtitleOptions).to.have.property('context', 'integration_subscribed'); }); it('renders a special subtitle for new orders', async () => { @@ -478,16 +492,34 @@ describe('Transaction', () => { await element.requestUpdate(); - const subtitle = element.renderRoot.querySelectorAll('foxy-i18n[infer="header"]')[1]; - expect(subtitle).to.have.attribute('key', 'subtitle_customer_placed_order'); + expect(element.headerSubtitleOptions).to.have.property('context', 'customer_placed_order'); element.data = { ...element.data!, source: 'mit_uoe' }; await element.requestUpdate(); - expect(subtitle).to.have.attribute('key', 'subtitle_admin_placed_order_with_uoe'); + expect(element.headerSubtitleOptions).to.have.property( + 'context', + 'admin_placed_order_with_uoe' + ); element.data = { ...element.data!, source: 'mit_api' }; await element.requestUpdate(); - expect(subtitle).to.have.attribute('key', 'subtitle_integration_placed_order'); + expect(element.headerSubtitleOptions).to.have.property('context', 'integration_placed_order'); + }); + + it('uses display_id as ID copied by Copy ID button', async () => { + const router = createRouter(); + const element = await fixture(html` + router.handleEvent(evt)} + > + + `); + + await waitUntil(() => element.in({ idle: 'snapshot' })); + element.data = { ...element.data!, display_id: '123' }; + + expect(element.headerCopyIdValue).to.equal('123'); }); it('renders transaction actions as control', async () => { diff --git a/src/elements/public/Transaction/Transaction.ts b/src/elements/public/Transaction/Transaction.ts index 254c5534f..e90fcb337 100644 --- a/src/elements/public/Transaction/Transaction.ts +++ b/src/elements/public/Transaction/Transaction.ts @@ -65,70 +65,91 @@ export class Transaction extends Base { return new BooleanSelector(`${super.hiddenSelector} ${hidden.join(' ')}`.trim()); } - renderBody(): TemplateResult { - let shipmentsLink: string | undefined = undefined; - let subtitleKey = 'subtitle'; - let itemsLink: string | undefined = undefined; - - const alertStatuses = ['problem', 'pending_fraud_review', 'rejected', 'declined']; - const hidden = this.hiddenSelector; + get headerSubtitleOptions(): Record { const source = this.data?.source; const type = this.data?.type; + let context = ''; + if (type === 'updateinfo') { if (!source || source?.startsWith('cit_')) { - subtitleKey = 'subtitle_customer_changed_payment_method'; + context = 'customer_changed_payment_method'; } else if (source === 'mit_uoe') { - subtitleKey = 'subtitle_admin_changed_payment_method_with_uoe'; + context = 'admin_changed_payment_method_with_uoe'; } else if (source === 'mit_api') { - subtitleKey = 'subtitle_integration_changed_payment_method'; + context = 'integration_changed_payment_method'; } else { - subtitleKey = 'subtitle_admin_changed_payment_method'; + context = 'admin_changed_payment_method'; } } else if (type === 'subscription_modification') { if (!source || source?.startsWith('cit_')) { - subtitleKey = 'subtitle_customer_changed_subscription'; + context = 'customer_changed_subscription'; } else if (source === 'mit_uoe') { - subtitleKey = 'subtitle_admin_changed_subscription_with_uoe'; + context = 'admin_changed_subscription_with_uoe'; } else if (source === 'mit_api') { - subtitleKey = 'subtitle_integration_changed_subscription'; + context = 'integration_changed_subscription'; } else { - subtitleKey = 'subtitle_admin_changed_subscription'; + context = 'admin_changed_subscription'; } } else if (type === 'subscription_renewal') { if (source === 'mit_recurring') { - subtitleKey = 'subtitle_subscription_renewal_attempt'; + context = 'subscription_renewal_attempt'; } else if (source === 'mit_recurring_reattempt_automated') { - subtitleKey = 'subtitle_subscription_renewal_automated_reattempt'; + context = 'subscription_renewal_automated_reattempt'; } else if (source === 'mit_recurring_reattempt_manual') { - subtitleKey = 'subtitle_subscription_renewal_manual_reattempt'; + context = 'subscription_renewal_manual_reattempt'; } } else if (type === 'subscription_cancellation') { if (source === 'cit_recurring_cancellation') { - subtitleKey = 'subtitle_customer_canceled_subscription'; + context = 'customer_canceled_subscription'; } else if (source === 'mit_recurring_cancellation') { - subtitleKey = 'subtitle_admin_canceled_subscription'; + context = 'admin_canceled_subscription'; } } else { if (this.data?._links['fx:subscription']) { if (source?.startsWith('cit_')) { - subtitleKey = 'subtitle_customer_subscribed'; + context = 'customer_subscribed'; } else if (source === 'mit_uoe') { - subtitleKey = 'subtitle_admin_subscribed_with_uoe'; + context = 'admin_subscribed_with_uoe'; } else if (source === 'mit_api') { - subtitleKey = 'subtitle_integration_subscribed'; + context = 'integration_subscribed'; } } else { if (source?.startsWith('cit_')) { - subtitleKey = 'subtitle_customer_placed_order'; + context = 'customer_placed_order'; } else if (source === 'mit_uoe') { - subtitleKey = 'subtitle_admin_placed_order_with_uoe'; + context = 'admin_placed_order_with_uoe'; } else if (source === 'mit_api') { - subtitleKey = 'subtitle_integration_placed_order'; + context = 'integration_placed_order'; } } } + return { + transaction_date: this.data?.transaction_date, + ip_country: this.data?.ip_country, + context, + }; + } + + get headerCopyIdValue(): string { + return this.data?.display_id?.toString() ?? ''; + } + + renderHeaderActions(): TemplateResult { + return html` + + + `; + } + + renderBody(): TemplateResult { + let shipmentsLink: string | undefined = undefined; + let itemsLink: string | undefined = undefined; + + const alertStatuses = ['problem', 'pending_fraud_review', 'rejected', 'declined']; + const hidden = this.hiddenSelector; + if (this.data) { try { const shipmentsUrl = new URL(this.data._links['fx:shipments'].href); @@ -143,32 +164,7 @@ export class Transaction extends Base { } return html` -

-
- - - -
- - - - - - -

- + ${this.renderHeader()} ${alertStatuses.includes(this.data?.status ?? '') ? html`

{ await control.requestUpdate(); const value = control.renderRoot.querySelector('foxy-i18n[key="price"]'); + // @ts-expect-error using private property for testing purposes + await waitUntil(() => !!control.__store); + expect(value).to.exist; expect(value).to.have.deep.property('options', { - currencyDisplay: 'symbol', + currencyDisplay: 'code', signDisplay: 'auto', amount: '10 USD', }); + expect(value).to.have.property('infer', ''); }); @@ -100,13 +104,16 @@ describe('Transaction', () => { const label = control.renderRoot.querySelector('foxy-i18n[key="total"]')!; const value = label.nextElementSibling!; + // @ts-expect-error using private property for testing purposes + await waitUntil(() => !!control.__store); + expect(label).to.exist; expect(label).to.have.property('infer', ''); expect(value).to.exist; expect(value).to.have.property('infer', ''); expect(value).to.have.deep.property('options', { - currencyDisplay: 'symbol', + currencyDisplay: 'code', signDisplay: 'auto', amount: '11.9 USD', }); @@ -131,13 +138,16 @@ describe('Transaction', () => { const label = control.renderRoot.querySelector('foxy-i18n[key="total_shipping"]')!; const value = label.parentElement!.nextElementSibling!.firstElementChild; + // @ts-expect-error using private property for testing purposes + await waitUntil(() => !!control.__store); + expect(label).to.exist; expect(label).to.have.property('infer', ''); expect(value).to.exist; expect(value).to.have.property('infer', ''); expect(value).to.have.deep.property('options', { - currencyDisplay: 'symbol', + currencyDisplay: 'code', signDisplay: 'exceptZero', amount: '0 USD', }); @@ -162,13 +172,16 @@ describe('Transaction', () => { const label = control.renderRoot.querySelector('foxy-i18n[key="total_tax"]')!; const value = label.parentElement!.nextElementSibling!.firstElementChild; + // @ts-expect-error using private property for testing purposes + await waitUntil(() => !!control.__store); + expect(label).to.exist; expect(label).to.have.property('infer', ''); expect(value).to.exist; expect(value).to.have.property('infer', ''); expect(value).to.have.deep.property('options', { - currencyDisplay: 'symbol', + currencyDisplay: 'code', signDisplay: 'exceptZero', amount: '1.9 USD', }); @@ -266,6 +279,9 @@ describe('Transaction', () => { const label1 = control.renderRoot.querySelectorAll('[data-testclass="discount"]')[0]; const value1 = label1.nextElementSibling!.firstElementChild; + // @ts-expect-error using private property for testing purposes + await waitUntil(() => !!control.__store); + expect(label1).to.exist; expect(label1).to.include.text('Test1'); @@ -274,7 +290,7 @@ describe('Transaction', () => { expect(value1).to.have.property('infer', ''); expect(value1).to.have.deep.property('options', { amount: '-1 USD', - currencyDisplay: 'symbol', + currencyDisplay: 'code', signDisplay: 'exceptZero', }); @@ -289,7 +305,7 @@ describe('Transaction', () => { expect(value2).to.have.property('infer', ''); expect(value2).to.have.deep.property('options', { amount: '-2 USD', - currencyDisplay: 'symbol', + currencyDisplay: 'code', signDisplay: 'exceptZero', }); }); diff --git a/src/elements/public/TransactionCard/TransactionCard.ts b/src/elements/public/TransactionCard/TransactionCard.ts index c44d47602..d49d37fcf 100644 --- a/src/elements/public/TransactionCard/TransactionCard.ts +++ b/src/elements/public/TransactionCard/TransactionCard.ts @@ -1,4 +1,4 @@ -import type { Data, Templates } from './types'; +import type { Data } from './types'; import type { TemplateResult } from 'lit-html'; import type { Rels } from '@foxy.io/sdk/backend'; @@ -15,21 +15,10 @@ const Base = ConfigurableMixin(TranslatableMixin(InternalCard, NS)); /** * Basic card displaying a transaction. * - * @slot total:before - * @slot total:after - * @slot status:before - * @slot status:after - * @slot description:before - * @slot description:after - * @slot customer:before - * @slot customer:after - * * @element foxy-transaction-card * @since 1.12.0 */ class TransactionCard extends Base { - templates: Templates = {}; - private __currencyDisplay = ''; renderBody(): TemplateResult { diff --git a/src/elements/public/TransactionCard/types.ts b/src/elements/public/TransactionCard/types.ts index 82e6850dd..3a908b79a 100644 --- a/src/elements/public/TransactionCard/types.ts +++ b/src/elements/public/TransactionCard/types.ts @@ -1,7 +1,5 @@ -import { Rels } from '@foxy.io/sdk/backend'; -import { Renderer } from '../../../mixins/configurable'; -import { Resource } from '@foxy.io/sdk/core'; -import { TransactionCard } from './TransactionCard'; +import type { Resource } from '@foxy.io/sdk/core'; +import type { Rels } from '@foxy.io/sdk/backend'; export type Data = Resource & { _links?: { 'fx:subscription'?: { href: string } }; @@ -9,14 +7,3 @@ export type Data = Resource & { user_agent: string; source: string; }; - -export type Templates = Partial<{ - 'total:before': Renderer; - 'total:after': Renderer; - 'status:before': Renderer; - 'status:after': Renderer; - 'description:before': Renderer; - 'description:after': Renderer; - 'customer:before': Renderer; - 'customer:after': Renderer; -}>; diff --git a/src/elements/public/TransactionsTable/types.ts b/src/elements/public/TransactionsTable/types.ts index 4ba1b1fc6..062a2cc85 100644 --- a/src/elements/public/TransactionsTable/types.ts +++ b/src/elements/public/TransactionsTable/types.ts @@ -1,7 +1,4 @@ import * as FoxySDK from '@foxy.io/sdk'; -import { Templates as TableTemplates } from '../Table/types'; - export type Rel = FoxySDK.Backend.Rels.Transactions; export type Data = FoxySDK.Core.Resource; -export type Templates = TableTemplates; diff --git a/src/elements/public/UpdatePaymentMethodForm/UpdatePaymentMethodForm.stories.ts b/src/elements/public/UpdatePaymentMethodForm/UpdatePaymentMethodForm.stories.ts index b6cb8be74..17477fd79 100644 --- a/src/elements/public/UpdatePaymentMethodForm/UpdatePaymentMethodForm.stories.ts +++ b/src/elements/public/UpdatePaymentMethodForm/UpdatePaymentMethodForm.stories.ts @@ -10,7 +10,7 @@ const summary: Summary = { nucleon: true, localName: 'foxy-update-payment-method-form', translatable: true, - configurable: { inputs: ['template-set', 'cc-token'] }, + configurable: { sections: ['header'], inputs: ['template-set', 'cc-token'] }, }; const demoExt = 'embed-url="https://embed.foxy.io/v1.html?demo=default"'; diff --git a/src/elements/public/UpdatePaymentMethodForm/UpdatePaymentMethodForm.test.ts b/src/elements/public/UpdatePaymentMethodForm/UpdatePaymentMethodForm.test.ts index 508ee274d..fa55353e3 100644 --- a/src/elements/public/UpdatePaymentMethodForm/UpdatePaymentMethodForm.test.ts +++ b/src/elements/public/UpdatePaymentMethodForm/UpdatePaymentMethodForm.test.ts @@ -8,6 +8,8 @@ import { expect, fixture, html, waitUntil } from '@open-wc/testing'; import { UpdatePaymentMethodForm as Form } from './UpdatePaymentMethodForm'; import { InternalResourcePickerControl } from '../../internal/InternalResourcePickerControl/InternalResourcePickerControl'; import { createRouter } from '../../../server/index'; +import { stub } from 'sinon'; +import { getTestData } from '../../../testgen/getTestData'; describe('UpdatePaymentMethodForm', () => { it('imports and defines foxy-internal-resource-picker-control', () => { @@ -90,6 +92,20 @@ describe('UpdatePaymentMethodForm', () => { expect(form.hiddenSelector.matches('cc-token', true)).to.be.false; }); + it('always hides Copy ID and Copy JSON buttons', () => { + const form = new Form(); + expect(form.hiddenSelector.matches('header:copy-id', true)).to.be.true; + expect(form.hiddenSelector.matches('header:copy-json', true)).to.be.true; + }); + + it('renders a form header', async () => { + const form = new Form(); + const renderHeaderMethod = stub(form, 'renderHeader'); + form.data = await getTestData('./hapi/payment_methods/0'); + form.render(); + expect(renderHeaderMethod).to.have.been.called; + }); + it('renders a spinner in empty state when href is not set', async () => { const layout = html``; const form = await fixture(layout); diff --git a/src/elements/public/UpdatePaymentMethodForm/UpdatePaymentMethodForm.ts b/src/elements/public/UpdatePaymentMethodForm/UpdatePaymentMethodForm.ts index a0146a7e2..5d3bd4025 100644 --- a/src/elements/public/UpdatePaymentMethodForm/UpdatePaymentMethodForm.ts +++ b/src/elements/public/UpdatePaymentMethodForm/UpdatePaymentMethodForm.ts @@ -18,12 +18,6 @@ const Base = TranslatableMixin(InternalForm, NS); * Form element for updating customer's default payment method (`fx:default_payment_method`) * using the Payment Card Embed. Works only with existing payment methods. * - * @slot template-set:before - * @slot template-set:after - * - * @slot cc-token:before - * @slot cc-token:after - * * @element foxy-update-payment-method-form * @since 1.27.0 */ @@ -47,7 +41,7 @@ export class UpdatePaymentMethodForm extends Base { get hiddenSelector(): BooleanSelector { const formEmbedUrlParams = this.__formEmbedUrl?.searchParams; - const alwaysMatch = [super.hiddenSelector.toString()]; + const alwaysMatch = ['header:copy-id', 'header:copy-json', super.hiddenSelector.toString()]; const isDemo = formEmbedUrlParams?.has('demo'); if (this.__isPreConfigured || isDemo) alwaysMatch.unshift('template-set'); @@ -72,6 +66,8 @@ export class UpdatePaymentMethodForm extends Base { const storeLoader = this.renderRoot.querySelector('#store-loader'); return html` + ${this.renderHeader()} + { protected async _fetch(...args: Parameters): Promise { try { const response = await super._fetch(...args); - this.status = { key: 'cc_token_success' }; + const method = new UpdatePaymentMethodForm.API.WHATWGRequest(...args).method; + if (method === 'PATCH') this.status = { key: 'cc_token_success' }; return response; } catch (err) { let message; diff --git a/src/elements/public/UpdatePaymentMethodForm/types.ts b/src/elements/public/UpdatePaymentMethodForm/types.ts index f1d3dd3d6..59f5a7d8c 100644 --- a/src/elements/public/UpdatePaymentMethodForm/types.ts +++ b/src/elements/public/UpdatePaymentMethodForm/types.ts @@ -1,14 +1,6 @@ -import type { UpdatePaymentMethodForm } from './UpdatePaymentMethodForm'; import type { Rels as CustomerRels } from '@foxy.io/sdk/customer'; import type { Rels as BackendRels } from '@foxy.io/sdk/backend'; -import type { Renderer } from '../../../mixins/configurable'; import type { Resource } from '@foxy.io/sdk/core'; export type Rel = BackendRels.DefaultPaymentMethod | CustomerRels.DefaultPaymentMethod; export type Data = Resource; -export type Templates = { - 'template-set:before'?: Renderer; - 'template-set:after'?: Renderer; - 'cc-token:before'?: Renderer; - 'cc-token:after'?: Renderer; -}; diff --git a/src/elements/public/UserCard/UserCard.ts b/src/elements/public/UserCard/UserCard.ts index 814cf3c81..7cd292768 100644 --- a/src/elements/public/UserCard/UserCard.ts +++ b/src/elements/public/UserCard/UserCard.ts @@ -11,12 +11,6 @@ const Base = TranslatableMixin(TwoLineCard, NS); /** * Card element representing a `fx:user` resource. * - * @slot title:before - * @slot title:after - * - * @slot subtitle:before - * @slot subtitle:after - * * @element foxy-user-card * @since 1.22.0 */ diff --git a/src/elements/public/UserForm/UserForm.stories.ts b/src/elements/public/UserForm/UserForm.stories.ts index d1c76dfde..b5fc0fea5 100644 --- a/src/elements/public/UserForm/UserForm.stories.ts +++ b/src/elements/public/UserForm/UserForm.stories.ts @@ -11,8 +11,8 @@ const summary: Summary = { localName: 'foxy-user-form', translatable: true, configurable: { - sections: ['timestamps'], - buttons: ['create', 'delete'], + sections: ['timestamps', 'header'], + buttons: ['delete', 'create', 'submit', 'undo', 'header:copy-id', 'header:copy-json'], inputs: ['first-name', 'last-name', 'email', 'phone', 'role'], }, }; diff --git a/src/elements/public/UserForm/UserForm.test.ts b/src/elements/public/UserForm/UserForm.test.ts index ff48b8dca..d9edacc28 100644 --- a/src/elements/public/UserForm/UserForm.test.ts +++ b/src/elements/public/UserForm/UserForm.test.ts @@ -4,6 +4,9 @@ import './index'; import { expect, fixture, html } from '@open-wc/testing'; import { UserForm } from './UserForm'; +import { stub } from 'sinon'; +import { getTestData } from '../../../testgen/getTestData'; +import { Data } from './types'; describe('UserForm', () => { it('imports and defines foxy-internal-checkbox-group-control', () => { @@ -14,10 +17,6 @@ describe('UserForm', () => { expect(customElements.get('foxy-internal-text-control')).to.exist; }); - it('imports and defines foxy-internal-integer-control', () => { - expect(customElements.get('foxy-internal-integer-control')).to.exist; - }); - it('imports and defines foxy-internal-form', () => { expect(customElements.get('foxy-internal-form')).to.exist; }); @@ -113,12 +112,20 @@ describe('UserForm', () => { expect(element.errors).to.include('phone:v8n_too_long'); }); - it('makes affiliate-id control readonly when href is set', () => { - const element = new UserForm(); - expect(element.readonlySelector.matches('affiliate-id', true)).to.be.false; + it('renders a form header', () => { + const form = new UserForm(); + const renderHeaderMethod = stub(form, 'renderHeader'); + form.render(); + expect(renderHeaderMethod).to.have.been.called; + }); + + it('renders a special subtitle for affiliates', async () => { + const form = new UserForm(); + form.data = { ...(await getTestData('./hapi/users/0')), affiliate_id: 123 }; + expect(form.headerSubtitleOptions).to.have.property('context', 'affiliate'); - element.href = 'https://demo.api/hapi/users/0'; - expect(element.readonlySelector.matches('affiliate-id', true)).to.be.true; + form.data = { ...(await getTestData('./hapi/users/0')), affiliate_id: 0 }; + expect(form.headerSubtitleOptions).to.have.property('context', ''); }); it('renders a text control for first name', async () => { @@ -147,14 +154,6 @@ describe('UserForm', () => { expect(control).to.exist; }); - it('renders an integer control for affiliate id', async () => { - const element = await fixture(html``); - const control = element.renderRoot.querySelector( - 'foxy-internal-integer-control[infer=affiliate-id]' - ); - expect(control).to.exist; - }); - it('renders a checkbox group control for role', async () => { const element = await fixture(html``); const control = element.renderRoot.querySelector( diff --git a/src/elements/public/UserForm/UserForm.ts b/src/elements/public/UserForm/UserForm.ts index cb0d2f13f..28d59e895 100644 --- a/src/elements/public/UserForm/UserForm.ts +++ b/src/elements/public/UserForm/UserForm.ts @@ -1,10 +1,9 @@ -import type { Data, Templates } from './types'; +import type { Data } from './types'; import type { TemplateResult } from 'lit-html'; import type { NucleonV8N } from '../NucleonElement/types'; import { validate as isEmail } from 'email-validator'; import { TranslatableMixin } from '../../../mixins/translatable'; -import { BooleanSelector } from '@foxy.io/sdk/core'; import { InternalForm } from '../../internal/InternalForm/InternalForm'; import { html } from 'lit-html'; @@ -14,30 +13,6 @@ const Base = TranslatableMixin(InternalForm, NS); /** * Form element for `fx:user` resources. * - * @slot first-name:before – new in v1.22.0 - * @slot first-name:after – new in v1.22.0 - * - * @slot last-name:before – new in v1.22.0 - * @slot last-name:after – new in v1.22.0 - * - * @slot email:before – new in v1.22.0 - * @slot email:after – new in v1.22.0 - * - * @slot phone:before – new in v1.22.0 - * @slot phone:after – new in v1.22.0 - * - * @slot role:before – new in v1.22.0 - * @slot role:after – new in v1.22.0 - * - * @slot timestamps:before – new in v1.27.0 - * @slot timestamps:after – new in v1.27.0 - * - * @slot create:before – new in v1.22.0 - * @slot create:after – new in v1.22.0 - * - * @slot delete:before – new in v1.22.0 - * @slot delete:after – new in v1.22.0 - * * @element foxy-user-form * @since 1.3.0 */ @@ -55,8 +30,6 @@ export class UserForm extends Base { ]; } - templates: Templates = {}; - private readonly __roleGetValue = () => { const value: string[] = []; @@ -84,21 +57,22 @@ export class UserForm extends Base { { label: 'option_designer', value: 'designer' }, ]; - get readonlySelector(): BooleanSelector { - const alwaysMatch = [super.readonlySelector.toString()]; - if (this.href) alwaysMatch.unshift('affiliate-id'); - return new BooleanSelector(alwaysMatch.join(' ').trim()); + get headerSubtitleOptions(): Record { + return { + ...super.headerSubtitleOptions, + context: this.data?.affiliate_id ? 'affiliate' : '', + }; } renderBody(): TemplateResult { return html` + ${this.renderHeader()} + - - ; -export type Templates = { - 'first-name:before'?: Renderer; - 'first-name:after'?: Renderer; - 'last-name:before'?: Renderer; - 'last-name:after'?: Renderer; - 'email:before'?: Renderer; - 'email:after'?: Renderer; - 'phone:before'?: Renderer; - 'phone:after'?: Renderer; - 'role:before'?: Renderer; - 'role:after'?: Renderer; - 'timestamps:before'?: Renderer; - 'timestamps:after'?: Renderer; - 'create:before'?: Renderer; - 'create:after'?: Renderer; - 'delete:before'?: Renderer; - 'delete:after'?: Renderer; -}; diff --git a/src/elements/public/WebhookForm/WebhookForm.stories.ts b/src/elements/public/WebhookForm/WebhookForm.stories.ts index ca8acbfb2..4f40fb009 100644 --- a/src/elements/public/WebhookForm/WebhookForm.stories.ts +++ b/src/elements/public/WebhookForm/WebhookForm.stories.ts @@ -11,9 +11,9 @@ const summary: Summary = { localName: 'foxy-webhook-form', translatable: true, configurable: { - sections: ['timestamps'], + sections: ['timestamps', 'header'], inputs: ['name', 'format', 'version', 'url', 'query', 'encryption-key', 'event-resource'], - buttons: ['create', 'delete'], + buttons: ['delete', 'create', 'submit', 'undo', 'header:copy-id', 'header:copy-json'], }, }; diff --git a/src/elements/public/WebhookForm/WebhookForm.test.ts b/src/elements/public/WebhookForm/WebhookForm.test.ts index fa766e9e8..e6a689847 100644 --- a/src/elements/public/WebhookForm/WebhookForm.test.ts +++ b/src/elements/public/WebhookForm/WebhookForm.test.ts @@ -1,6 +1,7 @@ import { expect, fixture, html } from '@open-wc/testing'; +import { stub } from 'sinon'; import { getTestData } from '../../../testgen/getTestData'; -import { InternalAsyncDetailsControl } from '../../internal/InternalAsyncDetailsControl/InternalAsyncDetailsControl'; +import { InternalAsyncListControl } from '../../internal/InternalAsyncListControl/InternalAsyncListControl'; import { InternalForm } from '../../internal/InternalForm/InternalForm'; import { InternalRadioGroupControl } from '../../internal/InternalRadioGroupControl/InternalRadioGroupControl'; import { InternalTextControl } from '../../internal/InternalTextControl/InternalTextControl'; @@ -8,8 +9,8 @@ import { WebhookForm } from './index'; import { Data } from './types'; describe('WebhookForm', () => { - it('imports and defines foxy-internal-async-details-control element', () => { - expect(customElements.get('foxy-internal-async-details-control')).to.exist; + it('imports and defines foxy-internal-async-list-control element', () => { + expect(customElements.get('foxy-internal-async-list-control')).to.exist; }); it('imports and defines foxy-internal-radio-group-control element', () => { @@ -85,6 +86,19 @@ describe('WebhookForm', () => { expect(errors).to.include('encryption-key:v8n_too_long'); }); + it('renders a form header', () => { + const form = new WebhookForm(); + const renderHeaderMethod = stub(form, 'renderHeader'); + form.render(); + expect(renderHeaderMethod).to.have.been.called; + }); + + it('uses event resource as context for header subtitle', async () => { + const form = new WebhookForm(); + form.data = await getTestData('./hapi/webhooks/0'); + expect(form.headerSubtitleOptions).to.have.property('context', form.data?.event_resource); + }); + it('renders webhook name as text control', async () => { const element = await fixture(html``); const control = element.renderRoot.querySelector('[infer="name"]'); @@ -163,7 +177,7 @@ describe('WebhookForm', () => { const control = element.renderRoot.querySelector('[infer="statuses"]'); expect(control).to.exist; - expect(control).to.be.instanceOf(InternalAsyncDetailsControl); + expect(control).to.be.instanceOf(InternalAsyncListControl); expect(control).to.have.property('first', webhook._links['fx:statuses'].href); expect(control).to.have.property('item', 'foxy-webhook-status-card'); }); @@ -178,17 +192,17 @@ describe('WebhookForm', () => { const control = element.renderRoot.querySelector('[infer="logs"]'); expect(control).to.exist; - expect(control).to.be.instanceOf(InternalAsyncDetailsControl); + expect(control).to.be.instanceOf(InternalAsyncListControl); expect(control).to.have.property('first', webhook._links['fx:logs'].href); expect(control).to.have.property('item', 'foxy-webhook-log-card'); }); - it('makes event resource selector readonly when loaded', async () => { + it('hides event resource selector when loaded', async () => { const webhook = await getTestData('./hapi/webhooks/0'); const element = await fixture(html``); - expect(element.readonlySelector.matches('event-resource', true)).to.be.false; + expect(element.hiddenSelector.matches('event-resource', true)).to.be.false; element.data = webhook; - expect(element.readonlySelector.matches('event-resource', true)).to.be.true; + expect(element.hiddenSelector.matches('event-resource', true)).to.be.true; }); }); diff --git a/src/elements/public/WebhookForm/WebhookForm.ts b/src/elements/public/WebhookForm/WebhookForm.ts index a4faa24ca..7477bc67e 100644 --- a/src/elements/public/WebhookForm/WebhookForm.ts +++ b/src/elements/public/WebhookForm/WebhookForm.ts @@ -10,33 +10,6 @@ import { html } from 'lit-html'; /** * Form element for creating or editing webhooks (`fx:webhook`). * - * @slot name:before - * @slot name:after - * - * @slot event-resource:before - * @slot event-resource:after - * - * @slot query:before - * @slot query:after - * - * @slot url:before - * @slot url:after - * - * @slot format:before - * @slot format:after - * - * @slot encryption-key:before - * @slot encryption-key:after - * - * @slot version:before - * @slot version:after - * - * @slot statuses:before - * @slot statuses:after - * - * @slot logs:before - * @slot logs:after - * * @element foxy-webhook-form * @since 1.17.0 */ @@ -65,14 +38,20 @@ export class WebhookForm extends TranslatableMixin(InternalForm, 'webhook-form') { value: 'customer', label: 'event_resource_customer' }, ]; - get readonlySelector(): BooleanSelector { + get hiddenSelector(): BooleanSelector { const alwaysMatch: string[] = []; if (this.data) alwaysMatch.push('event-resource'); return new BooleanSelector(`${super.readonlySelector} ${alwaysMatch.join(' ')}`.trim()); } + get headerSubtitleOptions(): Record { + return { context: this.data?.event_resource }; + } + renderBody(): TemplateResult { return html` + ${this.renderHeader()} + @@ -89,21 +68,21 @@ export class WebhookForm extends TranslatableMixin(InternalForm, 'webhook-form') ${this.data ? html` - - + - - + ` : ''} ${super.renderBody()} diff --git a/src/elements/public/WebhookForm/index.ts b/src/elements/public/WebhookForm/index.ts index 7fd95c6c2..0d0678529 100644 --- a/src/elements/public/WebhookForm/index.ts +++ b/src/elements/public/WebhookForm/index.ts @@ -1,5 +1,5 @@ -import '../../internal/InternalAsyncDetailsControl/index'; import '../../internal/InternalRadioGroupControl/index'; +import '../../internal/InternalAsyncListControl/index'; import '../../internal/InternalTextControl/index'; import '../../internal/InternalForm/index'; diff --git a/src/elements/public/WebhookLogCard/WebhookLogCard.ts b/src/elements/public/WebhookLogCard/WebhookLogCard.ts index 0f493ed3d..b639377b9 100644 --- a/src/elements/public/WebhookLogCard/WebhookLogCard.ts +++ b/src/elements/public/WebhookLogCard/WebhookLogCard.ts @@ -17,14 +17,13 @@ export class WebhookLogCard extends TranslatableMixin(InternalCard, 'webhook-log return html`

-

- - - ${response_code}​ - +

+ + + ${response_code}​

-

${response_body}​

+

${response_body}​

`; } diff --git a/src/elements/public/WebhookStatusCard/WebhookStatusCard.ts b/src/elements/public/WebhookStatusCard/WebhookStatusCard.ts index bbfff783a..341254c7d 100644 --- a/src/elements/public/WebhookStatusCard/WebhookStatusCard.ts +++ b/src/elements/public/WebhookStatusCard/WebhookStatusCard.ts @@ -20,7 +20,7 @@ export class WebhookStatusCard extends Base { const status = this.data?.status; return html` -

+

{ ( super.updated(changedProperties); const I18nElement = customElements.get('foxy-i18n') as typeof I18n | undefined; + const namespaces = this.ns.split(' ').filter(v => v.length > 0); + const i18next = I18nElement?.i18next; - if (!I18nElement) return; - - if (changedProperties.has('lang')) I18nElement.i18next.loadLanguages(this.lang); - - if (changedProperties.has('ns')) { - const namespaces = this.ns.split(' ').filter(v => v.length > 0); - - if (this.simplifyNsLoading) { - if (namespaces[0]) I18nElement.i18next.loadNamespaces(namespaces[0]); - } else { - I18nElement.i18next.loadNamespaces(namespaces); - } - } + i18next?.loadNamespaces(this.simplifyNsLoading ? namespaces[0] ?? [] : namespaces); + i18next?.loadLanguages(this.lang); } disconnectedCallback(): void { diff --git a/src/server/hapi/createDataset.ts b/src/server/hapi/createDataset.ts index 7e4e4a72d..4f8384f2d 100644 --- a/src/server/hapi/createDataset.ts +++ b/src/server/hapi/createDataset.ts @@ -637,7 +637,7 @@ export const createDataset: () => Dataset = () => ({ transaction_id: id > 4 ? 1 : 0, subscription_id: 0, item_category_id: 0, - item_category_uri: '', + item_category_uri: `https://demo.api/hapi/item_categories/${id}`, name: `Basic Product #${id}`, price: 10, quantity: Math.ceil(Math.random() * 10), diff --git a/src/static/schemas/access-recovery-form.json b/src/static/schemas/access-recovery-form.json deleted file mode 100644 index 7c7af87b7..000000000 --- a/src/static/schemas/access-recovery-form.json +++ /dev/null @@ -1,43 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "back": { "type": "string", "default": "Go back" }, - "email": { "type": "string", "default": "Email" }, - "recover_access": { "type": "string", "default": "Get temporary password" }, - "recover_access_hint": { - "type": "string", - "default": "Enter your email to get a temporary password" - }, - "recover_access_success": { - "type": "string", - "default": "Done! Please check your email for further instructions." - }, - "unknown_error": { - "type": "string", - "default": "We can't issue a one-time code for this account at the moment. If you've already requested the code, please wait a few minutes before trying again." - }, - "v8n_invalid_email": { "type": "string", "default": "Invalid email" }, - "v8n_required": { "type": "string", "default": "Required" }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "back", - "email", - "recover_access", - "recover_access_hint", - "recover_access_success", - "unknown_error", - "v8n_invalid_email", - "v8n_required", - "spinner" - ] -} diff --git a/src/static/schemas/address-card.json b/src/static/schemas/address-card.json deleted file mode 100644 index d70b456fb..000000000 --- a/src/static/schemas/address-card.json +++ /dev/null @@ -1,29 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "default_billing_address": { "type": "string", "default": "Default billing address" }, - "default_shipping_address": { "type": "string", "default": "Default shipping address" }, - "full_address": { - "type": "string", - "default": "{{address1}} {{address2}} {{city}} {{region}} {{postal_code}}" - }, - "full_name": { "type": "string", "default": "{{first_name}} {{last_name}}" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "default_billing_address", - "default_shipping_address", - "full_address", - "full_name", - "spinner" - ] -} diff --git a/src/static/schemas/address-form.json b/src/static/schemas/address-form.json deleted file mode 100644 index 86ff759c9..000000000 --- a/src/static/schemas/address-form.json +++ /dev/null @@ -1,1356 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "address-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Address name" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_required": { "type": "string", "default": "Please enter address name" }, - "v8n_too_long": { - "type": "string", - "default": "Please shorten address name to 100 characters or less" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_too_long"] - }, - "first-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "First name" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we can't store first names longer than 50 characters" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "last-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Last name" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we can't store last names longer than 50 characters" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "company": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Company" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we can't store company names longer than 50 characters" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "phone": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Phone" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { "type": "string", "default": "This phone number appears to be too long" } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "address-one": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Address Line 1" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "Street address, P.O. box, company name, c/o" - }, - "v8n_required": { "type": "string", "default": "Please enter address line 1" }, - "v8n_too_long": { - "type": "string", - "default": "Please shorten address line 1 to 100 characters or less" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_too_long"] - }, - "address-two": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Address Line 2" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { - "type": "string", - "default": "Apartment, suite, unit, building, floor, etc." - }, - "v8n_too_long": { - "type": "string", - "default": "Please shorten address line 2 to 100 characters or less" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "city": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "City" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we can't store city names longer than 50 characters" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "postal-code": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Postal code" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { "type": "string", "default": "This postal code appears to be too long" } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "country": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Country" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "region": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Region" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we can't store region names longer than 50 characters" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date": { "type": "string", "default": "{{value, date}}" }, - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" } - }, - "required": ["date", "date_created", "date_modified"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove this address? You won't be able to bring it back." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - }, - "country_af": { "type": "string", "default": "Afghanistan" }, - "country_ax": { "type": "string", "default": "Åland Islands" }, - "country_al": { "type": "string", "default": "Albania" }, - "country_dz": { "type": "string", "default": "Algeria" }, - "country_as": { "type": "string", "default": "American Samoa" }, - "country_ad": { "type": "string", "default": "Andorra" }, - "country_ao": { "type": "string", "default": "Angola" }, - "country_ai": { "type": "string", "default": "Anguilla" }, - "country_aq": { "type": "string", "default": "Antarctica" }, - "country_ag": { "type": "string", "default": "Antigua and Barbuda" }, - "country_ar": { "type": "string", "default": "Argentina" }, - "country_am": { "type": "string", "default": "Armenia" }, - "country_aw": { "type": "string", "default": "Aruba" }, - "country_au": { "type": "string", "default": "Australia" }, - "country_au_region_act": { "type": "string", "default": "Australian Capital Territory" }, - "country_au_region_nsw": { "type": "string", "default": "New South Wales" }, - "country_au_region_nt": { "type": "string", "default": "Northern Territory" }, - "country_au_region_qld": { "type": "string", "default": "Queensland" }, - "country_au_region_sa": { "type": "string", "default": "South Australia" }, - "country_au_region_tas": { "type": "string", "default": "Tasmania" }, - "country_au_region_vic": { "type": "string", "default": "Victoria" }, - "country_au_region_wa": { "type": "string", "default": "Western Australia" }, - "country_at": { "type": "string", "default": "Austria" }, - "country_at_region_bl": { "type": "string", "default": "Burgenland" }, - "country_at_region_kn": { "type": "string", "default": "Kaernten" }, - "country_at_region_no": { "type": "string", "default": "Niederoesterreich" }, - "country_at_region_oo": { "type": "string", "default": "Oberoesterreich" }, - "country_at_region_sb": { "type": "string", "default": "Salzburg" }, - "country_at_region_st": { "type": "string", "default": "Steiermark" }, - "country_at_region_ti": { "type": "string", "default": "Tirol" }, - "country_at_region_vb": { "type": "string", "default": "Voralberg" }, - "country_at_region_wi": { "type": "string", "default": "Wien" }, - "country_az": { "type": "string", "default": "Azerbaijan" }, - "country_bs": { "type": "string", "default": "Bahamas" }, - "country_bh": { "type": "string", "default": "Bahrain" }, - "country_bd": { "type": "string", "default": "Bangladesh" }, - "country_bb": { "type": "string", "default": "Barbados" }, - "country_by": { "type": "string", "default": "Belarus" }, - "country_be": { "type": "string", "default": "Belgium" }, - "country_bz": { "type": "string", "default": "Belize" }, - "country_bj": { "type": "string", "default": "Benin" }, - "country_bm": { "type": "string", "default": "Bermuda" }, - "country_bt": { "type": "string", "default": "Bhutan" }, - "country_bo": { "type": "string", "default": "Bolivia" }, - "country_bq": { "type": "string", "default": "Bonaire, Sint Eustatius and Saba" }, - "country_bq_region_bo": { "type": "string", "default": "Bonaire" }, - "country_bq_region_sa": { "type": "string", "default": "Saba" }, - "country_bq_region_se": { "type": "string", "default": "Sint Eustatius" }, - "country_ba": { "type": "string", "default": "Bosnia and Herzegovina" }, - "country_bw": { "type": "string", "default": "Botswana" }, - "country_bv": { "type": "string", "default": "Bouvet Island" }, - "country_br": { "type": "string", "default": "Brazil" }, - "country_io": { "type": "string", "default": "British Indian Ocean Territory" }, - "country_bn": { "type": "string", "default": "Brunei Darussalam" }, - "country_bg": { "type": "string", "default": "Bulgaria" }, - "country_bf": { "type": "string", "default": "Burkina Faso" }, - "country_bi": { "type": "string", "default": "Burundi" }, - "country_kh": { "type": "string", "default": "Cambodia" }, - "country_cm": { "type": "string", "default": "Cameroon" }, - "country_ca": { "type": "string", "default": "Canada" }, - "country_ca_region_ab": { "type": "string", "default": "Alberta" }, - "country_ca_region_bc": { "type": "string", "default": "British Columbia" }, - "country_ca_region_mb": { "type": "string", "default": "Manitoba" }, - "country_ca_region_nb": { "type": "string", "default": "New Brunswick" }, - "country_ca_region_nl": { "type": "string", "default": "Newfoundland and Labrador" }, - "country_ca_region_nt": { "type": "string", "default": "Northwest Territories" }, - "country_ca_region_ns": { "type": "string", "default": "Nova Scotia" }, - "country_ca_region_nu": { "type": "string", "default": "Nunavut" }, - "country_ca_region_on": { "type": "string", "default": "Ontario" }, - "country_ca_region_pe": { "type": "string", "default": "Prince Edward Island" }, - "country_ca_region_qc": { "type": "string", "default": "Quebec" }, - "country_ca_region_sk": { "type": "string", "default": "Saskatchewan" }, - "country_ca_region_yt": { "type": "string", "default": "Yukon" }, - "country_cv": { "type": "string", "default": "Cape Verde" }, - "country_cw": { "type": "string", "default": "Curaçao" }, - "country_ky": { "type": "string", "default": "Cayman Islands" }, - "country_cf": { "type": "string", "default": "Central African Republic" }, - "country_td": { "type": "string", "default": "Chad" }, - "country_cl": { "type": "string", "default": "Chile" }, - "country_cn": { "type": "string", "default": "China" }, - "country_cx": { "type": "string", "default": "Christmas Island" }, - "country_cc": { "type": "string", "default": "Cocos (Keeling) Islands" }, - "country_co": { "type": "string", "default": "Colombia" }, - "country_km": { "type": "string", "default": "Comoros" }, - "country_cg": { "type": "string", "default": "Congo" }, - "country_cd": { "type": "string", "default": "Congo, the Democratic Republic of the" }, - "country_ck": { "type": "string", "default": "Cook Islands" }, - "country_cr": { "type": "string", "default": "Costa Rica" }, - "country_ci": { "type": "string", "default": "Cote DIvoire" }, - "country_hr": { "type": "string", "default": "Croatia" }, - "country_cu": { "type": "string", "default": "Cuba" }, - "country_cy": { "type": "string", "default": "Cyprus" }, - "country_cz": { "type": "string", "default": "Czech Republic" }, - "country_dk": { "type": "string", "default": "Denmark" }, - "country_dj": { "type": "string", "default": "Djibouti" }, - "country_dm": { "type": "string", "default": "Dominica" }, - "country_do": { "type": "string", "default": "Dominican Republic" }, - "country_ec": { "type": "string", "default": "Ecuador" }, - "country_eg": { "type": "string", "default": "Egypt" }, - "country_sv": { "type": "string", "default": "El Salvador" }, - "country_sx": { "type": "string", "default": "Sint Maarten" }, - "country_gq": { "type": "string", "default": "Equatorial Guinea" }, - "country_er": { "type": "string", "default": "Eritrea" }, - "country_ee": { "type": "string", "default": "Estonia" }, - "country_et": { "type": "string", "default": "Ethiopia" }, - "country_fk": { "type": "string", "default": "Falkland Islands (Malvinas)" }, - "country_fo": { "type": "string", "default": "Faroe Islands" }, - "country_fj": { "type": "string", "default": "Fiji" }, - "country_fi": { "type": "string", "default": "Finland" }, - "country_fr": { "type": "string", "default": "France" }, - "country_gf": { "type": "string", "default": "French Guiana" }, - "country_pf": { "type": "string", "default": "French Polynesia" }, - "country_tf": { "type": "string", "default": "French Southern Territories" }, - "country_ga": { "type": "string", "default": "Gabon" }, - "country_gm": { "type": "string", "default": "Gambia" }, - "country_ge": { "type": "string", "default": "Georgia" }, - "country_de": { "type": "string", "default": "Germany" }, - "country_de_region_bw": { "type": "string", "default": "Baden-Wuerttemberg" }, - "country_de_region_by": { "type": "string", "default": "Bayern" }, - "country_de_region_be": { "type": "string", "default": "Berlin" }, - "country_de_region_bb": { "type": "string", "default": "Brandenburg" }, - "country_de_region_hb": { "type": "string", "default": "Bremen" }, - "country_de_region_hh": { "type": "string", "default": "Hamburg" }, - "country_de_region_he": { "type": "string", "default": "Hessen" }, - "country_de_region_mv": { "type": "string", "default": "Mecklenburg-Vorpommern" }, - "country_de_region_ni": { "type": "string", "default": "Niedersachsen" }, - "country_de_region_nw": { "type": "string", "default": "Nordrhein-Westfalen" }, - "country_de_region_rp": { "type": "string", "default": "Rheinland-Pfalz" }, - "country_de_region_sl": { "type": "string", "default": "Saarland" }, - "country_de_region_sn": { "type": "string", "default": "Sachsen" }, - "country_de_region_st": { "type": "string", "default": "Sachsen-Anhalt" }, - "country_de_region_sh": { "type": "string", "default": "Schleswig-Holstein" }, - "country_de_region_th": { "type": "string", "default": "Thueringen" }, - "country_gh": { "type": "string", "default": "Ghana" }, - "country_gi": { "type": "string", "default": "Gibraltar" }, - "country_gr": { "type": "string", "default": "Greece" }, - "country_gl": { "type": "string", "default": "Greenland" }, - "country_gd": { "type": "string", "default": "Grenada" }, - "country_gp": { "type": "string", "default": "Guadeloupe" }, - "country_gu": { "type": "string", "default": "Guam" }, - "country_gt": { "type": "string", "default": "Guatemala" }, - "country_gg": { "type": "string", "default": "Guernsey" }, - "country_gn": { "type": "string", "default": "Guinea" }, - "country_gw": { "type": "string", "default": "Guinea-bissau" }, - "country_gy": { "type": "string", "default": "Guyana" }, - "country_ht": { "type": "string", "default": "Haiti" }, - "country_hm": { "type": "string", "default": "Heard Island and McDonald Island" }, - "country_va": { "type": "string", "default": "Holy See (Vatican City State)" }, - "country_hn": { "type": "string", "default": "Honduras" }, - "country_hk": { "type": "string", "default": "Hong Kong" }, - "country_hu": { "type": "string", "default": "Hungary" }, - "country_is": { "type": "string", "default": "Iceland" }, - "country_in": { "type": "string", "default": "India" }, - "country_in_region_an": { "type": "string", "default": "Andaman and Nicobar Islands" }, - "country_in_region_ap": { "type": "string", "default": "Andhra Pradesh" }, - "country_in_region_ar": { "type": "string", "default": "Arunachal Pradesh" }, - "country_in_region_as": { "type": "string", "default": "Assam" }, - "country_in_region_br": { "type": "string", "default": "Bihar" }, - "country_in_region_ch": { "type": "string", "default": "Chandigarh" }, - "country_in_region_ct": { "type": "string", "default": "Chhattisgarh" }, - "country_in_region_dn": { "type": "string", "default": "Dadra and Nagar Haveli" }, - "country_in_region_dd": { "type": "string", "default": "Daman and Diu" }, - "country_in_region_dl": { "type": "string", "default": "Delhi" }, - "country_in_region_ga": { "type": "string", "default": "Goa" }, - "country_in_region_gj": { "type": "string", "default": "Gujarat" }, - "country_in_region_hr": { "type": "string", "default": "Haryana" }, - "country_in_region_hp": { "type": "string", "default": "Himachal Pradesh" }, - "country_in_region_jk": { "type": "string", "default": "Jammu and Kashmir" }, - "country_in_region_jh": { "type": "string", "default": "Jharkhand" }, - "country_in_region_ka": { "type": "string", "default": "Karnataka" }, - "country_in_region_kl": { "type": "string", "default": "Kerala" }, - "country_in_region_ld": { "type": "string", "default": "Lakshadweep" }, - "country_in_region_mp": { "type": "string", "default": "Madhya Pradesh" }, - "country_in_region_mh": { "type": "string", "default": "Maharashtra" }, - "country_in_region_mn": { "type": "string", "default": "Manipur" }, - "country_in_region_ml": { "type": "string", "default": "Meghalaya" }, - "country_in_region_mz": { "type": "string", "default": "Mizoram" }, - "country_in_region_nl": { "type": "string", "default": "Nagaland" }, - "country_in_region_or": { "type": "string", "default": "Odisha" }, - "country_in_region_py": { "type": "string", "default": "Puducherry" }, - "country_in_region_pb": { "type": "string", "default": "Punjab" }, - "country_in_region_rj": { "type": "string", "default": "Rajasthan" }, - "country_in_region_sk": { "type": "string", "default": "Sikkim" }, - "country_in_region_tn": { "type": "string", "default": "Tamil Nadu" }, - "country_in_region_tg": { "type": "string", "default": "Telangana" }, - "country_in_region_tr": { "type": "string", "default": "Tripura" }, - "country_in_region_ut": { "type": "string", "default": "Uttarakhand" }, - "country_in_region_up": { "type": "string", "default": "Uttar Pradesh" }, - "country_in_region_wb": { "type": "string", "default": "West Bengal" }, - "country_id": { "type": "string", "default": "Indonesia" }, - "country_ir": { "type": "string", "default": "Iran, Islamic Republic of" }, - "country_iq": { "type": "string", "default": "Iraq" }, - "country_ie": { "type": "string", "default": "Ireland" }, - "country_ie_region_cw": { "type": "string", "default": "Carlow" }, - "country_ie_region_cn": { "type": "string", "default": "Cavan" }, - "country_ie_region_ce": { "type": "string", "default": "Clare" }, - "country_ie_region_co": { "type": "string", "default": "Cork" }, - "country_ie_region_dl": { "type": "string", "default": "Donegal" }, - "country_ie_region_d": { "type": "string", "default": "Dublin" }, - "country_ie_region_g": { "type": "string", "default": "Galway" }, - "country_ie_region_ky": { "type": "string", "default": "Kerry" }, - "country_ie_region_ke": { "type": "string", "default": "Kildare" }, - "country_ie_region_kk": { "type": "string", "default": "Kilkenny" }, - "country_ie_region_ls": { "type": "string", "default": "Laois" }, - "country_ie_region_lm": { "type": "string", "default": "Leitrim" }, - "country_ie_region_lk": { "type": "string", "default": "Limerick" }, - "country_ie_region_ld": { "type": "string", "default": "Longford" }, - "country_ie_region_lh": { "type": "string", "default": "Louth" }, - "country_ie_region_mo": { "type": "string", "default": "Mayo" }, - "country_ie_region_mh": { "type": "string", "default": "Meath" }, - "country_ie_region_mn": { "type": "string", "default": "Monaghan" }, - "country_ie_region_oy": { "type": "string", "default": "Offaly" }, - "country_ie_region_rn": { "type": "string", "default": "Roscommon" }, - "country_ie_region_so": { "type": "string", "default": "Sligo" }, - "country_ie_region_ta": { "type": "string", "default": "Tipperary" }, - "country_ie_region_wd": { "type": "string", "default": "Waterford" }, - "country_ie_region_wh": { "type": "string", "default": "Westmeath" }, - "country_ie_region_wx": { "type": "string", "default": "Wexford" }, - "country_ie_region_ww": { "type": "string", "default": "Wicklow" }, - "country_im": { "type": "string", "default": "Isle of Man" }, - "country_il": { "type": "string", "default": "Israel" }, - "country_it": { "type": "string", "default": "Italy" }, - "country_jm": { "type": "string", "default": "Jamaica" }, - "country_jp": { "type": "string", "default": "Japan" }, - "country_jp_region_10": { "type": "string", "default": "Gunma" }, - "country_jp_region_11": { "type": "string", "default": "Saitama" }, - "country_jp_region_12": { "type": "string", "default": "Chiba" }, - "country_jp_region_13": { "type": "string", "default": "Tokyo" }, - "country_jp_region_14": { "type": "string", "default": "Kanagawa" }, - "country_jp_region_15": { "type": "string", "default": "Niigata" }, - "country_jp_region_16": { "type": "string", "default": "Toyama" }, - "country_jp_region_17": { "type": "string", "default": "Ishikawa" }, - "country_jp_region_18": { "type": "string", "default": "Fukui" }, - "country_jp_region_19": { "type": "string", "default": "Yamanashi" }, - "country_jp_region_20": { "type": "string", "default": "Nagano" }, - "country_jp_region_21": { "type": "string", "default": "Gifu" }, - "country_jp_region_22": { "type": "string", "default": "Shizuoka" }, - "country_jp_region_23": { "type": "string", "default": "Aichi" }, - "country_jp_region_24": { "type": "string", "default": "Mie" }, - "country_jp_region_25": { "type": "string", "default": "Shiga" }, - "country_jp_region_26": { "type": "string", "default": "Kyoto" }, - "country_jp_region_27": { "type": "string", "default": "Osaka" }, - "country_jp_region_28": { "type": "string", "default": "Hyogo" }, - "country_jp_region_29": { "type": "string", "default": "Nara" }, - "country_jp_region_30": { "type": "string", "default": "Wakayama" }, - "country_jp_region_31": { "type": "string", "default": "Tottori" }, - "country_jp_region_32": { "type": "string", "default": "Shimane" }, - "country_jp_region_33": { "type": "string", "default": "Okayama" }, - "country_jp_region_34": { "type": "string", "default": "Hiroshima" }, - "country_jp_region_35": { "type": "string", "default": "Yamaguchi" }, - "country_jp_region_36": { "type": "string", "default": "Tokushima" }, - "country_jp_region_37": { "type": "string", "default": "Kagawa" }, - "country_jp_region_38": { "type": "string", "default": "Ehime" }, - "country_jp_region_39": { "type": "string", "default": "Kochi" }, - "country_jp_region_40": { "type": "string", "default": "Fukuoka" }, - "country_jp_region_41": { "type": "string", "default": "Saga" }, - "country_jp_region_42": { "type": "string", "default": "Nagasaki" }, - "country_jp_region_43": { "type": "string", "default": "Kumamoto" }, - "country_jp_region_44": { "type": "string", "default": "Oita" }, - "country_jp_region_45": { "type": "string", "default": "Miyazaki" }, - "country_jp_region_46": { "type": "string", "default": "Kagoshima" }, - "country_jp_region_47": { "type": "string", "default": "Okinawa" }, - "country_jp_region_05": { "type": "string", "default": "Akita" }, - "country_jp_region_02": { "type": "string", "default": "Aomori" }, - "country_jp_region_07": { "type": "string", "default": "Fukushima" }, - "country_jp_region_01": { "type": "string", "default": "Hokkaido" }, - "country_jp_region_08": { "type": "string", "default": "Ibaraki" }, - "country_jp_region_03": { "type": "string", "default": "Iwate" }, - "country_jp_region_04": { "type": "string", "default": "Miyagi" }, - "country_jp_region_09": { "type": "string", "default": "Tochigi" }, - "country_jp_region_06": { "type": "string", "default": "Yamagata" }, - "country_je": { "type": "string", "default": "Jersey" }, - "country_jo": { "type": "string", "default": "Jordan" }, - "country_kz": { "type": "string", "default": "Kazakhstan" }, - "country_ke": { "type": "string", "default": "Kenya" }, - "country_ki": { "type": "string", "default": "Kiribati" }, - "country_kp": { "type": "string", "default": "Korea, Democratic People's Republic of" }, - "country_kr": { "type": "string", "default": "Korea, Republic of" }, - "country_kw": { "type": "string", "default": "Kuwait" }, - "country_kg": { "type": "string", "default": "Kyrgyzstan" }, - "country_la": { "type": "string", "default": "Lao People's Democratic Republic" }, - "country_lv": { "type": "string", "default": "Latvia" }, - "country_lb": { "type": "string", "default": "Lebanon" }, - "country_ls": { "type": "string", "default": "Lesotho" }, - "country_lr": { "type": "string", "default": "Liberia" }, - "country_ly": { "type": "string", "default": "Libya" }, - "country_li": { "type": "string", "default": "Liechtenstein" }, - "country_lt": { "type": "string", "default": "Lithuania" }, - "country_lu": { "type": "string", "default": "Luxembourg" }, - "country_mo": { "type": "string", "default": "Macau Special Administrative Region of China" }, - "country_mk": { "type": "string", "default": "North Macedonia" }, - "country_mg": { "type": "string", "default": "Madagascar" }, - "country_mw": { "type": "string", "default": "Malawi" }, - "country_my": { "type": "string", "default": "Malaysia" }, - "country_mv": { "type": "string", "default": "Maldives" }, - "country_ml": { "type": "string", "default": "Mali" }, - "country_mt": { "type": "string", "default": "Malta" }, - "country_mh": { "type": "string", "default": "Marshall Islands" }, - "country_mq": { "type": "string", "default": "Martinique" }, - "country_mr": { "type": "string", "default": "Mauritania" }, - "country_mu": { "type": "string", "default": "Mauritius" }, - "country_yt": { "type": "string", "default": "Mayotte" }, - "country_mx": { "type": "string", "default": "Mexico" }, - "country_fm": { "type": "string", "default": "Micronesia, Federated States of" }, - "country_md": { "type": "string", "default": "Moldova, Republic of" }, - "country_mc": { "type": "string", "default": "Monaco" }, - "country_mn": { "type": "string", "default": "Mongolia" }, - "country_me": { "type": "string", "default": "Montenegro" }, - "country_ms": { "type": "string", "default": "Montserrat" }, - "country_ma": { "type": "string", "default": "Morocco" }, - "country_mz": { "type": "string", "default": "Mozambique" }, - "country_mm": { "type": "string", "default": "Myanmar" }, - "country_na": { "type": "string", "default": "Namibia" }, - "country_nr": { "type": "string", "default": "Nauru" }, - "country_np": { "type": "string", "default": "Nepal" }, - "country_nl": { "type": "string", "default": "Netherlands" }, - "country_nc": { "type": "string", "default": "New Caledonia" }, - "country_nz": { "type": "string", "default": "New Zealand" }, - "country_ni": { "type": "string", "default": "Nicaragua" }, - "country_ne": { "type": "string", "default": "Niger" }, - "country_ng": { "type": "string", "default": "Nigeria" }, - "country_nu": { "type": "string", "default": "Niue" }, - "country_nf": { "type": "string", "default": "Norfolk Island" }, - "country_mp": { "type": "string", "default": "Northern Mariana Islands" }, - "country_no": { "type": "string", "default": "Norway" }, - "country_no_region_10": { "type": "string", "default": "Vest-Agder" }, - "country_no_region_11": { "type": "string", "default": "Rogaland" }, - "country_no_region_12": { "type": "string", "default": "Hordaland" }, - "country_no_region_14": { "type": "string", "default": "Sogn og Fjordane" }, - "country_no_region_15": { "type": "string", "default": "Møre og Romsdal" }, - "country_no_region_16": { "type": "string", "default": "Sør-Trøndelag" }, - "country_no_region_17": { "type": "string", "default": "Nord-Trøndelag" }, - "country_no_region_18": { "type": "string", "default": "Nordland" }, - "country_no_region_19": { "type": "string", "default": "Troms" }, - "country_no_region_20": { "type": "string", "default": "Finnmark" }, - "country_no_region_30": { "type": "string", "default": "Viken" }, - "country_no_region_34": { "type": "string", "default": "Innlandet" }, - "country_no_region_38": { "type": "string", "default": "Vestfold og Telemark" }, - "country_no_region_42": { "type": "string", "default": "Agder" }, - "country_no_region_46": { "type": "string", "default": "Vestland" }, - "country_no_region_50": { "type": "string", "default": "Trøndelag" }, - "country_no_region_54": { "type": "string", "default": "Troms og Finnmark" }, - "country_no_region_01": { "type": "string", "default": "Østfold" }, - "country_no_region_02": { "type": "string", "default": "Akershus" }, - "country_no_region_03": { "type": "string", "default": "Oslo" }, - "country_no_region_04": { "type": "string", "default": "Hedmark" }, - "country_no_region_05": { "type": "string", "default": "Oppland" }, - "country_no_region_06": { "type": "string", "default": "Buskerud" }, - "country_no_region_07": { "type": "string", "default": "Vestfold" }, - "country_no_region_08": { "type": "string", "default": "Telemark" }, - "country_no_region_09": { "type": "string", "default": "Aust-Agder" }, - "country_om": { "type": "string", "default": "Oman" }, - "country_pk": { "type": "string", "default": "Pakistan" }, - "country_pw": { "type": "string", "default": "Palau" }, - "country_ps": { "type": "string", "default": "Palestine, State of" }, - "country_pa": { "type": "string", "default": "Panama" }, - "country_pg": { "type": "string", "default": "Papua New Guinea" }, - "country_py": { "type": "string", "default": "Paraguay" }, - "country_pe": { "type": "string", "default": "Peru" }, - "country_ph": { "type": "string", "default": "Philippines" }, - "country_pn": { "type": "string", "default": "Pitcairn" }, - "country_pl": { "type": "string", "default": "Poland" }, - "country_pt": { "type": "string", "default": "Portugal" }, - "country_pr": { "type": "string", "default": "Puerto Rico" }, - "country_qa": { "type": "string", "default": "Qatar" }, - "country_re": { "type": "string", "default": "Réunion" }, - "country_ro": { "type": "string", "default": "Romania" }, - "country_ru": { "type": "string", "default": "Russian Federation" }, - "country_rw": { "type": "string", "default": "Rwanda" }, - "country_bl": { "type": "string", "default": "Saint Barthélemy" }, - "country_sh": { "type": "string", "default": "Saint Helena, Ascension and Tristan da Cunha" }, - "country_kn": { "type": "string", "default": "Saint Kitts and Nevis" }, - "country_lc": { "type": "string", "default": "Saint Lucia" }, - "country_mf": { "type": "string", "default": "Saint Martin" }, - "country_pm": { "type": "string", "default": "Saint Pierre and Miquelon" }, - "country_vc": { "type": "string", "default": "Saint Vincent and the Grenadines" }, - "country_ws": { "type": "string", "default": "Samoa" }, - "country_sm": { "type": "string", "default": "San Marino" }, - "country_ss": { "type": "string", "default": "South Sudan" }, - "country_st": { "type": "string", "default": "Sao Tome and Principe" }, - "country_sa": { "type": "string", "default": "Saudi Arabia" }, - "country_sn": { "type": "string", "default": "Senegal" }, - "country_rs": { "type": "string", "default": "Serbia" }, - "country_sc": { "type": "string", "default": "Seychelles" }, - "country_sl": { "type": "string", "default": "Sierra Leone" }, - "country_sg": { "type": "string", "default": "Singapore" }, - "country_sk": { "type": "string", "default": "Slovakia" }, - "country_si": { "type": "string", "default": "Slovenia" }, - "country_sb": { "type": "string", "default": "Solomon Islands" }, - "country_so": { "type": "string", "default": "Somalia" }, - "country_za": { "type": "string", "default": "South Africa" }, - "country_gs": { "type": "string", "default": "South Georgia and the South Sandwich Islands" }, - "country_es": { "type": "string", "default": "Spain" }, - "country_es_region_a coruna": { "type": "string", "default": "A Coruna" }, - "country_es_region_alava": { "type": "string", "default": "Alava" }, - "country_es_region_albacete": { "type": "string", "default": "Albacete" }, - "country_es_region_alicante": { "type": "string", "default": "Alicante" }, - "country_es_region_almeria": { "type": "string", "default": "Almeria" }, - "country_es_region_asturias": { "type": "string", "default": "Asturias" }, - "country_es_region_avila": { "type": "string", "default": "Avila" }, - "country_es_region_badajoz": { "type": "string", "default": "Badajoz" }, - "country_es_region_baleares": { "type": "string", "default": "Baleares" }, - "country_es_region_barcelona": { "type": "string", "default": "Barcelona" }, - "country_es_region_burgos": { "type": "string", "default": "Burgos" }, - "country_es_region_caceres": { "type": "string", "default": "Caceres" }, - "country_es_region_cadiz": { "type": "string", "default": "Cadiz" }, - "country_es_region_cn": { "type": "string", "default": "Canarias" }, - "country_es_region_cantabria": { "type": "string", "default": "Cantabria" }, - "country_es_region_castellon": { "type": "string", "default": "Castellon" }, - "country_es_region_ceuta": { "type": "string", "default": "Ceuta" }, - "country_es_region_ciudad real": { "type": "string", "default": "Ciudad Real" }, - "country_es_region_cordoba": { "type": "string", "default": "Cordoba" }, - "country_es_region_cuenca": { "type": "string", "default": "Cuenca" }, - "country_es_region_gipuzkoa": { "type": "string", "default": "Gipuzkoa" }, - "country_es_region_girona": { "type": "string", "default": "Girona" }, - "country_es_region_granada": { "type": "string", "default": "Granada" }, - "country_es_region_guadalajara": { "type": "string", "default": "Guadalajara" }, - "country_es_region_guipuzcoa": { "type": "string", "default": "Guipuzcoa" }, - "country_es_region_huelva": { "type": "string", "default": "Huelva" }, - "country_es_region_huesca": { "type": "string", "default": "Huesca" }, - "country_es_region_jaen": { "type": "string", "default": "Jaen" }, - "country_es_region_la rioja": { "type": "string", "default": "La Rioja" }, - "country_es_region_las palmas": { "type": "string", "default": "Las Palmas" }, - "country_es_region_leon": { "type": "string", "default": "Leon" }, - "country_es_region_lleida": { "type": "string", "default": "Lleida" }, - "country_es_region_lugo": { "type": "string", "default": "Lugo" }, - "country_es_region_madrid": { "type": "string", "default": "Madrid" }, - "country_es_region_malaga": { "type": "string", "default": "Malaga" }, - "country_es_region_melilla": { "type": "string", "default": "Melilla" }, - "country_es_region_murcia": { "type": "string", "default": "Murcia" }, - "country_es_region_navarra": { "type": "string", "default": "Navarra" }, - "country_es_region_ourense": { "type": "string", "default": "Ourense" }, - "country_es_region_palencia": { "type": "string", "default": "Palencia" }, - "country_es_region_pontevedra": { "type": "string", "default": "Pontevedra" }, - "country_es_region_salamanca": { "type": "string", "default": "Salamanca" }, - "country_es_region_santa cruz de tenerife": { - "type": "string", - "default": "Santa Cruz de Tenerife" - }, - "country_es_region_segovia": { "type": "string", "default": "Segovia" }, - "country_es_region_sevilla": { "type": "string", "default": "Sevilla" }, - "country_es_region_soria": { "type": "string", "default": "Soria" }, - "country_es_region_tarragona": { "type": "string", "default": "Tarragona" }, - "country_es_region_teruel": { "type": "string", "default": "Teruel" }, - "country_es_region_toledo": { "type": "string", "default": "Toledo" }, - "country_es_region_valencia": { "type": "string", "default": "Valencia" }, - "country_es_region_valladolid": { "type": "string", "default": "Valladolid" }, - "country_es_region_vizcaya": { "type": "string", "default": "Biscay" }, - "country_es_region_zamora": { "type": "string", "default": "Zamora" }, - "country_es_region_zaragoza": { "type": "string", "default": "Zaragoza" }, - "country_lk": { "type": "string", "default": "Sri Lanka" }, - "country_sd": { "type": "string", "default": "Sudan" }, - "country_sr": { "type": "string", "default": "Suriname" }, - "country_sj": { "type": "string", "default": "Svalbard and Jan Mayen" }, - "country_sz": { "type": "string", "default": "Eswatini" }, - "country_se": { "type": "string", "default": "Sweden" }, - "country_ch": { "type": "string", "default": "Switzerland" }, - "country_ch_region_ag": { "type": "string", "default": "Aargau" }, - "country_ch_region_ar": { "type": "string", "default": "Appenzell Ausserrhoden" }, - "country_ch_region_ai": { "type": "string", "default": "Appenzell Innerrhoden" }, - "country_ch_region_bl": { "type": "string", "default": "Basel-Landschaft" }, - "country_ch_region_bs": { "type": "string", "default": "Basel-Stadt" }, - "country_ch_region_be": { "type": "string", "default": "Bern" }, - "country_ch_region_fr": { "type": "string", "default": "Freiburg" }, - "country_ch_region_ge": { "type": "string", "default": "Genf" }, - "country_ch_region_gl": { "type": "string", "default": "Glarus" }, - "country_ch_region_gr": { "type": "string", "default": "Graubuenden" }, - "country_ch_region_ju": { "type": "string", "default": "Jura" }, - "country_ch_region_lu": { "type": "string", "default": "Luzern" }, - "country_ch_region_ne": { "type": "string", "default": "Neuenburg" }, - "country_ch_region_nw": { "type": "string", "default": "Nidwalden" }, - "country_ch_region_ow": { "type": "string", "default": "Obwalden" }, - "country_ch_region_sh": { "type": "string", "default": "Schaffhausen" }, - "country_ch_region_sz": { "type": "string", "default": "Schwyz" }, - "country_ch_region_so": { "type": "string", "default": "Solothurn" }, - "country_ch_region_sg": { "type": "string", "default": "St. Gallen" }, - "country_ch_region_ti": { "type": "string", "default": "Tessin" }, - "country_ch_region_tg": { "type": "string", "default": "Thurgau" }, - "country_ch_region_ur": { "type": "string", "default": "Uri" }, - "country_ch_region_vs": { "type": "string", "default": "Valais" }, - "country_ch_region_vd": { "type": "string", "default": "Vaud" }, - "country_ch_region_zh": { "type": "string", "default": "Zurich" }, - "country_ch_region_zg": { "type": "string", "default": "Zug" }, - "country_sy": { "type": "string", "default": "Syrian Arab Republic" }, - "country_tw": { "type": "string", "default": "Taiwan" }, - "country_tj": { "type": "string", "default": "Tajikistan" }, - "country_tz": { "type": "string", "default": "Tanzania, United Republic of" }, - "country_th": { "type": "string", "default": "Thailand" }, - "country_tl": { "type": "string", "default": "Timor-Leste" }, - "country_tg": { "type": "string", "default": "Togo" }, - "country_tk": { "type": "string", "default": "Tokelau" }, - "country_to": { "type": "string", "default": "Tonga" }, - "country_tt": { "type": "string", "default": "Trinidad and Tobago" }, - "country_tn": { "type": "string", "default": "Tunisia" }, - "country_tr": { "type": "string", "default": "Turkey" }, - "country_tm": { "type": "string", "default": "Turkmenistan" }, - "country_tc": { "type": "string", "default": "Turks and Caicos Islands" }, - "country_tv": { "type": "string", "default": "Tuvalu" }, - "country_ug": { "type": "string", "default": "Uganda" }, - "country_ua": { "type": "string", "default": "Ukraine" }, - "country_ae": { "type": "string", "default": "United Arab Emirates" }, - "country_gb": { "type": "string", "default": "United Kingdom" }, - "country_us": { "type": "string", "default": "United States" }, - "country_us_region_al": { "type": "string", "default": "Alabama" }, - "country_us_region_ak": { "type": "string", "default": "Alaska" }, - "country_us_region_as": { "type": "string", "default": "American Samoa" }, - "country_us_region_az": { "type": "string", "default": "Arizona" }, - "country_us_region_ar": { "type": "string", "default": "Arkansas" }, - "country_us_region_af": { "type": "string", "default": "Armed Forces Africa" }, - "country_us_region_aa": { "type": "string", "default": "Armed Forces Americas" }, - "country_us_region_ac": { "type": "string", "default": "Armed Forces Canada" }, - "country_us_region_ae": { "type": "string", "default": "Armed Forces Europe" }, - "country_us_region_am": { "type": "string", "default": "Armed Forces Middle East" }, - "country_us_region_ap": { "type": "string", "default": "Armed Forces Pacific" }, - "country_us_region_ca": { "type": "string", "default": "California" }, - "country_us_region_co": { "type": "string", "default": "Colorado" }, - "country_us_region_ct": { "type": "string", "default": "Connecticut" }, - "country_us_region_de": { "type": "string", "default": "Delaware" }, - "country_us_region_dc": { "type": "string", "default": "Washington DC" }, - "country_us_region_fm": { "type": "string", "default": "Federated States Of Micronesia" }, - "country_us_region_fl": { "type": "string", "default": "Florida" }, - "country_us_region_ga": { "type": "string", "default": "Georgia" }, - "country_us_region_gu": { "type": "string", "default": "Guam" }, - "country_us_region_hi": { "type": "string", "default": "Hawaii" }, - "country_us_region_id": { "type": "string", "default": "Idaho" }, - "country_us_region_il": { "type": "string", "default": "Illinois" }, - "country_us_region_in": { "type": "string", "default": "Indiana" }, - "country_us_region_ia": { "type": "string", "default": "Iowa" }, - "country_us_region_ks": { "type": "string", "default": "Kansas" }, - "country_us_region_ky": { "type": "string", "default": "Kentucky" }, - "country_us_region_la": { "type": "string", "default": "Louisiana" }, - "country_us_region_me": { "type": "string", "default": "Maine" }, - "country_us_region_mh": { "type": "string", "default": "Marshall Islands" }, - "country_us_region_md": { "type": "string", "default": "Maryland" }, - "country_us_region_ma": { "type": "string", "default": "Massachusetts" }, - "country_us_region_mi": { "type": "string", "default": "Michigan" }, - "country_us_region_mn": { "type": "string", "default": "Minnesota" }, - "country_us_region_ms": { "type": "string", "default": "Mississippi" }, - "country_us_region_mo": { "type": "string", "default": "Missouri" }, - "country_us_region_mt": { "type": "string", "default": "Montana" }, - "country_us_region_ne": { "type": "string", "default": "Nebraska" }, - "country_us_region_nv": { "type": "string", "default": "Nevada" }, - "country_us_region_nh": { "type": "string", "default": "New Hampshire" }, - "country_us_region_nj": { "type": "string", "default": "New Jersey" }, - "country_us_region_nm": { "type": "string", "default": "New Mexico" }, - "country_us_region_ny": { "type": "string", "default": "New York" }, - "country_us_region_nc": { "type": "string", "default": "North Carolina" }, - "country_us_region_nd": { "type": "string", "default": "North Dakota" }, - "country_us_region_mp": { "type": "string", "default": "Northern Mariana Islands" }, - "country_us_region_oh": { "type": "string", "default": "Ohio" }, - "country_us_region_ok": { "type": "string", "default": "Oklahoma" }, - "country_us_region_or": { "type": "string", "default": "Oregon" }, - "country_us_region_pa": { "type": "string", "default": "Pennsylvania" }, - "country_us_region_pr": { "type": "string", "default": "Puerto Rico" }, - "country_us_region_ri": { "type": "string", "default": "Rhode Island" }, - "country_us_region_sc": { "type": "string", "default": "South Carolina" }, - "country_us_region_sd": { "type": "string", "default": "South Dakota" }, - "country_us_region_tn": { "type": "string", "default": "Tennessee" }, - "country_us_region_tx": { "type": "string", "default": "Texas" }, - "country_us_region_ut": { "type": "string", "default": "Utah" }, - "country_us_region_vt": { "type": "string", "default": "Vermont" }, - "country_us_region_vi": { "type": "string", "default": "Virgin Islands" }, - "country_us_region_va": { "type": "string", "default": "Virginia" }, - "country_us_region_wa": { "type": "string", "default": "Washington" }, - "country_us_region_wv": { "type": "string", "default": "West Virginia" }, - "country_us_region_wi": { "type": "string", "default": "Wisconsin" }, - "country_us_region_wy": { "type": "string", "default": "Wyoming" }, - "country_um": { "type": "string", "default": "United States Minor Outlying Islands" }, - "country_uy": { "type": "string", "default": "Uruguay" }, - "country_uz": { "type": "string", "default": "Uzbekistan" }, - "country_vu": { "type": "string", "default": "Vanuatu" }, - "country_ve": { "type": "string", "default": "Venezuela" }, - "country_vn": { "type": "string", "default": "Vietnam" }, - "country_vg": { "type": "string", "default": "Virgin Islands, British" }, - "country_vi": { "type": "string", "default": "Virgin Islands, U.S." }, - "country_wf": { "type": "string", "default": "Wallis and Futuna Islands" }, - "country_eh": { "type": "string", "default": "Western Sahara" }, - "country_ye": { "type": "string", "default": "Yemen" }, - "country_zm": { "type": "string", "default": "Zambia" }, - "country_zw": { "type": "string", "default": "Zimbabwe" } - }, - "required": [ - "address-name", - "first-name", - "last-name", - "company", - "phone", - "address-one", - "address-two", - "city", - "postal-code", - "country", - "region", - "timestamps", - "delete", - "create", - "spinner", - "country_af", - "country_ax", - "country_al", - "country_dz", - "country_as", - "country_ad", - "country_ao", - "country_ai", - "country_aq", - "country_ag", - "country_ar", - "country_am", - "country_aw", - "country_au", - "country_au_region_act", - "country_au_region_nsw", - "country_au_region_nt", - "country_au_region_qld", - "country_au_region_sa", - "country_au_region_tas", - "country_au_region_vic", - "country_au_region_wa", - "country_at", - "country_at_region_bl", - "country_at_region_kn", - "country_at_region_no", - "country_at_region_oo", - "country_at_region_sb", - "country_at_region_st", - "country_at_region_ti", - "country_at_region_vb", - "country_at_region_wi", - "country_az", - "country_bs", - "country_bh", - "country_bd", - "country_bb", - "country_by", - "country_be", - "country_bz", - "country_bj", - "country_bm", - "country_bt", - "country_bo", - "country_bq", - "country_bq_region_bo", - "country_bq_region_sa", - "country_bq_region_se", - "country_ba", - "country_bw", - "country_bv", - "country_br", - "country_io", - "country_bn", - "country_bg", - "country_bf", - "country_bi", - "country_kh", - "country_cm", - "country_ca", - "country_ca_region_ab", - "country_ca_region_bc", - "country_ca_region_mb", - "country_ca_region_nb", - "country_ca_region_nl", - "country_ca_region_nt", - "country_ca_region_ns", - "country_ca_region_nu", - "country_ca_region_on", - "country_ca_region_pe", - "country_ca_region_qc", - "country_ca_region_sk", - "country_ca_region_yt", - "country_cv", - "country_cw", - "country_ky", - "country_cf", - "country_td", - "country_cl", - "country_cn", - "country_cx", - "country_cc", - "country_co", - "country_km", - "country_cg", - "country_cd", - "country_ck", - "country_cr", - "country_ci", - "country_hr", - "country_cu", - "country_cy", - "country_cz", - "country_dk", - "country_dj", - "country_dm", - "country_do", - "country_ec", - "country_eg", - "country_sv", - "country_sx", - "country_gq", - "country_er", - "country_ee", - "country_et", - "country_fk", - "country_fo", - "country_fj", - "country_fi", - "country_fr", - "country_gf", - "country_pf", - "country_tf", - "country_ga", - "country_gm", - "country_ge", - "country_de", - "country_de_region_bw", - "country_de_region_by", - "country_de_region_be", - "country_de_region_bb", - "country_de_region_hb", - "country_de_region_hh", - "country_de_region_he", - "country_de_region_mv", - "country_de_region_ni", - "country_de_region_nw", - "country_de_region_rp", - "country_de_region_sl", - "country_de_region_sn", - "country_de_region_st", - "country_de_region_sh", - "country_de_region_th", - "country_gh", - "country_gi", - "country_gr", - "country_gl", - "country_gd", - "country_gp", - "country_gu", - "country_gt", - "country_gg", - "country_gn", - "country_gw", - "country_gy", - "country_ht", - "country_hm", - "country_va", - "country_hn", - "country_hk", - "country_hu", - "country_is", - "country_in", - "country_in_region_an", - "country_in_region_ap", - "country_in_region_ar", - "country_in_region_as", - "country_in_region_br", - "country_in_region_ch", - "country_in_region_ct", - "country_in_region_dn", - "country_in_region_dd", - "country_in_region_dl", - "country_in_region_ga", - "country_in_region_gj", - "country_in_region_hr", - "country_in_region_hp", - "country_in_region_jk", - "country_in_region_jh", - "country_in_region_ka", - "country_in_region_kl", - "country_in_region_ld", - "country_in_region_mp", - "country_in_region_mh", - "country_in_region_mn", - "country_in_region_ml", - "country_in_region_mz", - "country_in_region_nl", - "country_in_region_or", - "country_in_region_py", - "country_in_region_pb", - "country_in_region_rj", - "country_in_region_sk", - "country_in_region_tn", - "country_in_region_tg", - "country_in_region_tr", - "country_in_region_ut", - "country_in_region_up", - "country_in_region_wb", - "country_id", - "country_ir", - "country_iq", - "country_ie", - "country_ie_region_cw", - "country_ie_region_cn", - "country_ie_region_ce", - "country_ie_region_co", - "country_ie_region_dl", - "country_ie_region_d", - "country_ie_region_g", - "country_ie_region_ky", - "country_ie_region_ke", - "country_ie_region_kk", - "country_ie_region_ls", - "country_ie_region_lm", - "country_ie_region_lk", - "country_ie_region_ld", - "country_ie_region_lh", - "country_ie_region_mo", - "country_ie_region_mh", - "country_ie_region_mn", - "country_ie_region_oy", - "country_ie_region_rn", - "country_ie_region_so", - "country_ie_region_ta", - "country_ie_region_wd", - "country_ie_region_wh", - "country_ie_region_wx", - "country_ie_region_ww", - "country_im", - "country_il", - "country_it", - "country_jm", - "country_jp", - "country_jp_region_10", - "country_jp_region_11", - "country_jp_region_12", - "country_jp_region_13", - "country_jp_region_14", - "country_jp_region_15", - "country_jp_region_16", - "country_jp_region_17", - "country_jp_region_18", - "country_jp_region_19", - "country_jp_region_20", - "country_jp_region_21", - "country_jp_region_22", - "country_jp_region_23", - "country_jp_region_24", - "country_jp_region_25", - "country_jp_region_26", - "country_jp_region_27", - "country_jp_region_28", - "country_jp_region_29", - "country_jp_region_30", - "country_jp_region_31", - "country_jp_region_32", - "country_jp_region_33", - "country_jp_region_34", - "country_jp_region_35", - "country_jp_region_36", - "country_jp_region_37", - "country_jp_region_38", - "country_jp_region_39", - "country_jp_region_40", - "country_jp_region_41", - "country_jp_region_42", - "country_jp_region_43", - "country_jp_region_44", - "country_jp_region_45", - "country_jp_region_46", - "country_jp_region_47", - "country_jp_region_05", - "country_jp_region_02", - "country_jp_region_07", - "country_jp_region_01", - "country_jp_region_08", - "country_jp_region_03", - "country_jp_region_04", - "country_jp_region_09", - "country_jp_region_06", - "country_je", - "country_jo", - "country_kz", - "country_ke", - "country_ki", - "country_kp", - "country_kr", - "country_kw", - "country_kg", - "country_la", - "country_lv", - "country_lb", - "country_ls", - "country_lr", - "country_ly", - "country_li", - "country_lt", - "country_lu", - "country_mo", - "country_mk", - "country_mg", - "country_mw", - "country_my", - "country_mv", - "country_ml", - "country_mt", - "country_mh", - "country_mq", - "country_mr", - "country_mu", - "country_yt", - "country_mx", - "country_fm", - "country_md", - "country_mc", - "country_mn", - "country_me", - "country_ms", - "country_ma", - "country_mz", - "country_mm", - "country_na", - "country_nr", - "country_np", - "country_nl", - "country_nc", - "country_nz", - "country_ni", - "country_ne", - "country_ng", - "country_nu", - "country_nf", - "country_mp", - "country_no", - "country_no_region_10", - "country_no_region_11", - "country_no_region_12", - "country_no_region_14", - "country_no_region_15", - "country_no_region_16", - "country_no_region_17", - "country_no_region_18", - "country_no_region_19", - "country_no_region_20", - "country_no_region_30", - "country_no_region_34", - "country_no_region_38", - "country_no_region_42", - "country_no_region_46", - "country_no_region_50", - "country_no_region_54", - "country_no_region_01", - "country_no_region_02", - "country_no_region_03", - "country_no_region_04", - "country_no_region_05", - "country_no_region_06", - "country_no_region_07", - "country_no_region_08", - "country_no_region_09", - "country_om", - "country_pk", - "country_pw", - "country_ps", - "country_pa", - "country_pg", - "country_py", - "country_pe", - "country_ph", - "country_pn", - "country_pl", - "country_pt", - "country_pr", - "country_qa", - "country_re", - "country_ro", - "country_ru", - "country_rw", - "country_bl", - "country_sh", - "country_kn", - "country_lc", - "country_mf", - "country_pm", - "country_vc", - "country_ws", - "country_sm", - "country_ss", - "country_st", - "country_sa", - "country_sn", - "country_rs", - "country_sc", - "country_sl", - "country_sg", - "country_sk", - "country_si", - "country_sb", - "country_so", - "country_za", - "country_gs", - "country_es", - "country_es_region_a coruna", - "country_es_region_alava", - "country_es_region_albacete", - "country_es_region_alicante", - "country_es_region_almeria", - "country_es_region_asturias", - "country_es_region_avila", - "country_es_region_badajoz", - "country_es_region_baleares", - "country_es_region_barcelona", - "country_es_region_burgos", - "country_es_region_caceres", - "country_es_region_cadiz", - "country_es_region_cn", - "country_es_region_cantabria", - "country_es_region_castellon", - "country_es_region_ceuta", - "country_es_region_ciudad real", - "country_es_region_cordoba", - "country_es_region_cuenca", - "country_es_region_gipuzkoa", - "country_es_region_girona", - "country_es_region_granada", - "country_es_region_guadalajara", - "country_es_region_guipuzcoa", - "country_es_region_huelva", - "country_es_region_huesca", - "country_es_region_jaen", - "country_es_region_la rioja", - "country_es_region_las palmas", - "country_es_region_leon", - "country_es_region_lleida", - "country_es_region_lugo", - "country_es_region_madrid", - "country_es_region_malaga", - "country_es_region_melilla", - "country_es_region_murcia", - "country_es_region_navarra", - "country_es_region_ourense", - "country_es_region_palencia", - "country_es_region_pontevedra", - "country_es_region_salamanca", - "country_es_region_santa cruz de tenerife", - "country_es_region_segovia", - "country_es_region_sevilla", - "country_es_region_soria", - "country_es_region_tarragona", - "country_es_region_teruel", - "country_es_region_toledo", - "country_es_region_valencia", - "country_es_region_valladolid", - "country_es_region_vizcaya", - "country_es_region_zamora", - "country_es_region_zaragoza", - "country_lk", - "country_sd", - "country_sr", - "country_sj", - "country_sz", - "country_se", - "country_ch", - "country_ch_region_ag", - "country_ch_region_ar", - "country_ch_region_ai", - "country_ch_region_bl", - "country_ch_region_bs", - "country_ch_region_be", - "country_ch_region_fr", - "country_ch_region_ge", - "country_ch_region_gl", - "country_ch_region_gr", - "country_ch_region_ju", - "country_ch_region_lu", - "country_ch_region_ne", - "country_ch_region_nw", - "country_ch_region_ow", - "country_ch_region_sh", - "country_ch_region_sz", - "country_ch_region_so", - "country_ch_region_sg", - "country_ch_region_ti", - "country_ch_region_tg", - "country_ch_region_ur", - "country_ch_region_vs", - "country_ch_region_vd", - "country_ch_region_zh", - "country_ch_region_zg", - "country_sy", - "country_tw", - "country_tj", - "country_tz", - "country_th", - "country_tl", - "country_tg", - "country_tk", - "country_to", - "country_tt", - "country_tn", - "country_tr", - "country_tm", - "country_tc", - "country_tv", - "country_ug", - "country_ua", - "country_ae", - "country_gb", - "country_us", - "country_us_region_al", - "country_us_region_ak", - "country_us_region_as", - "country_us_region_az", - "country_us_region_ar", - "country_us_region_af", - "country_us_region_aa", - "country_us_region_ac", - "country_us_region_ae", - "country_us_region_am", - "country_us_region_ap", - "country_us_region_ca", - "country_us_region_co", - "country_us_region_ct", - "country_us_region_de", - "country_us_region_dc", - "country_us_region_fm", - "country_us_region_fl", - "country_us_region_ga", - "country_us_region_gu", - "country_us_region_hi", - "country_us_region_id", - "country_us_region_il", - "country_us_region_in", - "country_us_region_ia", - "country_us_region_ks", - "country_us_region_ky", - "country_us_region_la", - "country_us_region_me", - "country_us_region_mh", - "country_us_region_md", - "country_us_region_ma", - "country_us_region_mi", - "country_us_region_mn", - "country_us_region_ms", - "country_us_region_mo", - "country_us_region_mt", - "country_us_region_ne", - "country_us_region_nv", - "country_us_region_nh", - "country_us_region_nj", - "country_us_region_nm", - "country_us_region_ny", - "country_us_region_nc", - "country_us_region_nd", - "country_us_region_mp", - "country_us_region_oh", - "country_us_region_ok", - "country_us_region_or", - "country_us_region_pa", - "country_us_region_pr", - "country_us_region_ri", - "country_us_region_sc", - "country_us_region_sd", - "country_us_region_tn", - "country_us_region_tx", - "country_us_region_ut", - "country_us_region_vt", - "country_us_region_vi", - "country_us_region_va", - "country_us_region_wa", - "country_us_region_wv", - "country_us_region_wi", - "country_us_region_wy", - "country_um", - "country_uy", - "country_uz", - "country_vu", - "country_ve", - "country_vn", - "country_vg", - "country_vi", - "country_wf", - "country_eh", - "country_ye", - "country_zm", - "country_zw" - ] -} diff --git a/src/static/schemas/admin-subscription-card.json b/src/static/schemas/admin-subscription-card.json deleted file mode 100644 index 86e651cdd..000000000 --- a/src/static/schemas/admin-subscription-card.json +++ /dev/null @@ -1,72 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "daily": { "type": "string", "default": "/ day" }, - "daily_plural": { "type": "string", "default": "/ {{count}} days" }, - "frequency": { - "type": "string", - "default": "$t({{units}}, { \"count\": {{count}}, \"ns\": \"admin-subscription-card\" })" - }, - "monthly": { "type": "string", "default": "/ month" }, - "monthly_plural": { "type": "string", "default": "/ {{count}} months" }, - "price_recurring": { - "type": "string", - "default": "{{amount, price}} $t(frequency, { \"count\": \"{{count}}\", \"units\": \"{{units}}\", \"ns\": \"admin-subscription-card\" })" - }, - "price_twice_a_month": { - "type": "string", - "default": "{{amount, price}} $t(twice_a_month, { \"ns\": \"admin-subscription-card\" })" - }, - "subscription_active": { "type": "string", "default": "Next payment on {{date, date}}" }, - "subscription_cancelled": { "type": "string", "default": "Ended on {{date, date}}" }, - "subscription_failed": { "type": "string", "default": "Payment failed on {{date, date}}" }, - "subscription_inactive": { "type": "string", "default": "Inactive" }, - "subscription_will_be_cancelled": { "type": "string", "default": "Ends on {{date, date}}" }, - "subscription_will_be_active": { "type": "string", "default": "Starts on {{date, date}}" }, - "summary": { "type": "string", "default": "{{ firstItem.name }}" }, - "summary_plural": { - "type": "string", - "default": "{{ firstItem.name }} + {{ countMinus1 }} more" - }, - "summary_approximate": { "type": "string", "default": "{{ firstItem.name }} + more" }, - "twice_a_month": { "type": "string", "default": "twice a month" }, - "weekly": { "type": "string", "default": "/ week" }, - "weekly_plural": { "type": "string", "default": "/ {{count}} weeks" }, - "yearly": { "type": "string", "default": "/ year" }, - "yearly_plural": { "type": "string", "default": "/ {{count}} years" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "daily", - "daily_plural", - "frequency", - "monthly", - "monthly_plural", - "price_recurring", - "price_twice_a_month", - "subscription_active", - "subscription_cancelled", - "subscription_failed", - "subscription_inactive", - "subscription_will_be_cancelled", - "subscription_will_be_active", - "summary", - "summary_plural", - "summary_approximate", - "twice_a_month", - "weekly", - "weekly_plural", - "yearly", - "yearly_plural", - "spinner" - ] -} diff --git a/src/static/schemas/api-browser.json b/src/static/schemas/api-browser.json deleted file mode 100644 index fa0293293..000000000 --- a/src/static/schemas/api-browser.json +++ /dev/null @@ -1,88 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "go_back": { "type": "string", "default": "Go back" }, - "go_home": { "type": "string", "default": "Go home" }, - "current_url": { "type": "string", "default": "Current URL" }, - "get_mode": { - "type": "string", - "default": "Click to send GET requests to the selected endpoints" - }, - "post_mode": { - "type": "string", - "default": "Click to send POST requests to the selected endpoints" - }, - "navigate": { "type": "string", "default": "Navigate to this URL" }, - "refresh": { "type": "string", "default": "Refresh" }, - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { "type": "string", "default": "{{from}}-{{to}} out of {{total}}" }, - "previous": { "type": "string", "default": "Previous" }, - "undo": { "type": "string", "default": "Undo" }, - "editor": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Resource JSON" }, - "placeholder": { - "type": "string", - "default": "Enter resource JSON here and click Submit to save" - } - }, - "required": ["label", "placeholder"] - }, - "copy-to-clipboard": { - "additionalProperties": false, - "properties": { - "click_to_copy": { "type": "string", "default": "Click to copy" }, - "copying": { "type": "string", "default": "Copying" }, - "done": { "type": "string", "default": "Done" }, - "failed_to_copy": { "type": "string", "default": "Failed to copy" } - }, - "required": ["click_to_copy", "copying", "done", "failed_to_copy"] - }, - "spinner": { - "additionalProperties": false, - "properties": { "loading_busy": { "type": "string", "default": "Loading" } }, - "required": ["loading_busy"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove this resource? You won't be able to bring it back." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Submit" } }, - "required": ["create"] - } - }, - "required": [ - "go_back", - "go_home", - "current_url", - "get_mode", - "post_mode", - "navigate", - "refresh", - "first", - "last", - "next", - "pagination", - "previous", - "undo", - "editor", - "copy-to-clipboard", - "spinner", - "delete", - "create" - ] -} diff --git a/src/static/schemas/applied-coupon-code-card.json b/src/static/schemas/applied-coupon-code-card.json deleted file mode 100644 index 5f175ab78..000000000 --- a/src/static/schemas/applied-coupon-code-card.json +++ /dev/null @@ -1,16 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["spinner"] -} diff --git a/src/static/schemas/applied-coupon-code-form.json b/src/static/schemas/applied-coupon-code-form.json deleted file mode 100644 index 83adfe202..000000000 --- a/src/static/schemas/applied-coupon-code-form.json +++ /dev/null @@ -1,65 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "code": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Coupon code" }, - "placeholder": { "type": "string", "default": "MY-COUPON-123" }, - "helper_text_new": { - "type": "string", - "default": "To find the right code, go to the Coupons page, select a coupon and scroll down to the Codes section." - }, - "helper_text_existing": { - "type": "string", - "default": "Applied codes can't be modified. To replace this code, remove it using the button below and then add a new one." - }, - "v8n_required": { "type": "string", "default": "Please enter a coupon code." } - }, - "required": [ - "label", - "placeholder", - "helper_text_new", - "helper_text_existing", - "v8n_required" - ] - }, - "ignore-usage-limits": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" }, - "option_checked": { "type": "string", "default": "Ignore usage limits" } - }, - "required": ["label", "helper_text", "option_checked"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Remove" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove this coupon code? This might affect the cart total." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Apply" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": ["code", "ignore-usage-limits", "delete", "create", "spinner"] -} diff --git a/src/static/schemas/applied-tax-card.json b/src/static/schemas/applied-tax-card.json deleted file mode 100644 index c2bf774d6..000000000 --- a/src/static/schemas/applied-tax-card.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "percent": { "type": "string", "default": "{{fraction, percent}}" }, - "price": { "type": "string", "default": "{{amount, price}}" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["percent", "price", "spinner"] -} diff --git a/src/static/schemas/attribute-card.json b/src/static/schemas/attribute-card.json deleted file mode 100644 index 5f175ab78..000000000 --- a/src/static/schemas/attribute-card.json +++ /dev/null @@ -1,16 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["spinner"] -} diff --git a/src/static/schemas/attribute-form.json b/src/static/schemas/attribute-form.json deleted file mode 100644 index 658a2bce7..000000000 --- a/src/static/schemas/attribute-form.json +++ /dev/null @@ -1,93 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Name" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "Name of this attribute. It does not have to be unique." - }, - "v8n_required": { "type": "string", "default": "Please name this attribute." }, - "v8n_too_long": { - "type": "string", - "default": "Please choose a name that is 500 characters long or less." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_too_long"] - }, - "value": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Value" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "Value of this attribute. Attribute values are automatically HTML-escaped." - }, - "v8n_required": { - "type": "string", - "default": "Please provide a value for this attribute." - }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we can't store values that are more than 1000 characters long." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_too_long"] - }, - "visibility": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Visibility" }, - "option_public": { "type": "string", "default": "Everyone" }, - "option_restricted": { "type": "string", "default": "Store admins" }, - "option_private": { "type": "string", "default": "Only me" }, - "helper_text": { - "type": "string", - "default": "Controls who can see this attribute. Public attributes can be shown to anyone, including customers. Private attributes are more suitable for configuration or technical details which are irrelevant to the public. Restricted attributes can only be viewed with the OAuth client that created them." - } - }, - "required": ["label", "option_public", "option_restricted", "option_private", "helper_text"] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date": { "type": "string", "default": "{{value, date}}" }, - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" } - }, - "required": ["date", "date_created", "date_modified"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove this attribute? You won't be able to bring it back." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": ["name", "value", "visibility", "timestamps", "delete", "create", "spinner"] -} diff --git a/src/static/schemas/billing-address-card.json b/src/static/schemas/billing-address-card.json deleted file mode 100644 index 0f1cd3d1f..000000000 --- a/src/static/schemas/billing-address-card.json +++ /dev/null @@ -1,21 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "full_address": { - "type": "string", - "default": "{{address1}} {{address2}} {{city}} {{region}} {{country}} {{postal_code}}" - }, - "full_name": { "type": "string", "default": "{{first_name}} {{last_name}}" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["full_address", "full_name", "spinner"] -} diff --git a/src/static/schemas/cancellation-form.json b/src/static/schemas/cancellation-form.json deleted file mode 100644 index 42646f573..000000000 --- a/src/static/schemas/cancellation-form.json +++ /dev/null @@ -1,29 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "end_date": { "type": "string", "default": "End date" }, - "end_subscription": { "type": "string", "default": "End subscription" }, - "end_subscription_explainer": { - "type": "string", - "default": "Your subscription will remain active until the selected end date. You might have to resubscribe if you decide to resume this subscription later." - }, - "v8n_required": { "type": "string", "default": "Required" }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "end_date", - "end_subscription", - "end_subscription_explainer", - "v8n_required", - "spinner" - ] -} diff --git a/src/static/schemas/cart-card.json b/src/static/schemas/cart-card.json deleted file mode 100644 index 164c1a39e..000000000 --- a/src/static/schemas/cart-card.json +++ /dev/null @@ -1,30 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "line_1": { "type": "string", "default": "ID {{ id }} • {{ amount, price }}" }, - "line_2_one": { "type": "string", "default": "{{ name }}" }, - "line_2_many": { "type": "string", "default": "{{ name }} + more" }, - "line_2_empty": { "type": "string", "default": "Empty cart" }, - "no_customer": { "type": "string", "default": "Customer unknown" }, - "status": { "type": "string", "default": "{{ dateCreated, date }}" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "line_1", - "line_2_one", - "line_2_many", - "line_2_empty", - "no_customer", - "status", - "spinner" - ] -} diff --git a/src/static/schemas/cart-form.json b/src/static/schemas/cart-form.json deleted file mode 100644 index e946aad03..000000000 --- a/src/static/schemas/cart-form.json +++ /dev/null @@ -1,1678 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "order_section_title": { "type": "string", "default": "Order" }, - "order_section_description": { - "type": "string", - "default": "Cart items, discounts and metadata" - }, - "billing_section_title": { "type": "string", "default": "Billing" }, - "billing_section_description": { - "type": "string", - "default": "Address associated with the payment method" - }, - "shipping_section_title": { "type": "string", "default": "Shipping" }, - "shipping_section_description": { - "type": "string", - "default": "Location where the ordered items will be delivered" - }, - "customer-type": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Customer type" }, - "placeholder": { "type": "string", "default": "Select type..." }, - "helper_text": { "type": "string", "default": "" }, - "option_new": { "type": "string", "default": "New customer" }, - "option_guest": { "type": "string", "default": "Guest customer" }, - "option_regular": { "type": "string", "default": "Existing customer" } - }, - "required": [ - "label", - "placeholder", - "helper_text", - "option_new", - "option_guest", - "option_regular" - ] - }, - "customer": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Customer email" }, - "placeholder": { "type": "string", "default": "customer@example.com" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "items": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Items" }, - "delete_confirm": { "type": "string", "default": "Delete" }, - "delete_cancel": { "type": "string", "default": "Cancel" }, - "delete_message": { - "type": "string", - "default": "Are you sure you'd like to remove this item? You won't be able to bring it back." - }, - "delete_header": { "type": "string", "default": "Delete item?" }, - "pagination": { - "additionalProperties": false, - "properties": { - "create_button_text": { "type": "string", "default": "Add item +" }, - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { "type": "string", "default": "{{from}}-{{to}} out of {{total}}" }, - "previous": { "type": "string", "default": "Previous" }, - "card": { - "additionalProperties": false, - "properties": { - "delete_button_text": { "type": "string", "default": "Remove" }, - "daily": { "type": "string", "default": "Daily" }, - "daily_plural": { "type": "string", "default": "Every {{count}} days" }, - "frequency": { - "type": "string", - "default": "$t(items.pagination.card.{{units}}, { \"count\": {{count}}, \"ns\": \"cart-form\" })" - }, - "monthly": { "type": "string", "default": "Monthly" }, - "monthly_plural": { "type": "string", "default": "Every {{count}} months" }, - "subinfo_recurring": { - "type": "string", - "default": "$t(items.pagination.card.frequency, { \"count\": \"{{count}}\", \"units\": \"{{units}}\", \"ns\": \"cart-form\" }) from {{startDate, date}}" - }, - "subinfo_twice_a_month": { - "type": "string", - "default": "$t(items.pagination.card.twice_a_month, { \"ns\": \"cart-form\" }) from {{startDate, date}}" - }, - "twice_a_month": { "type": "string", "default": "Twice a month" }, - "no_code": { "type": "string", "default": "No SKU" }, - "weekly": { "type": "string", "default": "Weekly" }, - "weekly_plural": { "type": "string", "default": "Every {{count}} weeks" }, - "yearly": { "type": "string", "default": "Yearly" }, - "yearly_plural": { "type": "string", "default": "Every {{count}} years" }, - "price": { "type": "string", "default": "{{amount, price}}" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No items" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "delete_button_text", - "daily", - "daily_plural", - "frequency", - "monthly", - "monthly_plural", - "subinfo_recurring", - "subinfo_twice_a_month", - "twice_a_month", - "no_code", - "weekly", - "weekly_plural", - "yearly", - "yearly_plural", - "price", - "spinner" - ] - } - }, - "required": [ - "create_button_text", - "first", - "last", - "next", - "pagination", - "previous", - "card" - ] - }, - "dialog": { - "additionalProperties": false, - "properties": { - "close": { "type": "string", "default": "Close" }, - "cancel": { "type": "string", "default": "Cancel" }, - "header_update": { "type": "string", "default": "Item" }, - "header_create": { "type": "string", "default": "New item" }, - "save": { "type": "string", "default": "Save" }, - "undo_header": { "type": "string", "default": "Unsaved changes" }, - "undo_message": { - "type": "string", - "default": "Looks like you didn't save your changes! What would you like to do with them?" - }, - "undo_cancel": { "type": "string", "default": "Review" }, - "undo_confirm": { "type": "string", "default": "Discard" }, - "dimensions": { "type": "string", "default": "Dimensions" }, - "subscriptions": { "type": "string", "default": "Subscriptions" }, - "discount": { "type": "string", "default": "Discount" }, - "name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Name" }, - "helper_text": { "type": "string", "default": "Public name of this item." }, - "placeholder": { "type": "string", "default": "13' Laptop Case" }, - "v8n_required": { "type": "string", "default": "Name is required" }, - "v8n_too_long": { - "type": "string", - "default": "Name mustn't exceed 255 characters" - } - }, - "required": ["label", "helper_text", "placeholder", "v8n_required", "v8n_too_long"] - }, - "price": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Price" }, - "helper_text": { - "type": "string", - "default": "Base price before option modifiers." - }, - "placeholder": { "type": "string", "default": "25" }, - "v8n_required": { "type": "string", "default": "Price is required" }, - "v8n_negative": { "type": "string", "default": "Price can't be negative" } - }, - "required": ["label", "helper_text", "placeholder", "v8n_required", "v8n_negative"] - }, - "quantity": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Quantity" }, - "helper_text": { "type": "string", "default": "Number of items in the cart." }, - "placeholder": { "type": "string", "default": "1 by default" }, - "v8n_less_than_one": { "type": "string", "default": "Quantity must be 1 or more" } - }, - "required": ["label", "helper_text", "placeholder", "v8n_less_than_one"] - }, - "subscription-frequency": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Subscription frequency" }, - "helper_text": { - "type": "string", - "default": "This determines how often this subscription will be processed. To modify this value for an existing subscription, you must modify the subscription directly." - }, - "day": { "type": "string", "default": "Day" }, - "day_plural": { "type": "string", "default": "Days" }, - "week": { "type": "string", "default": "Week" }, - "week_plural": { "type": "string", "default": "Weeks" }, - "month": { "type": "string", "default": "Month" }, - "month_plural": { "type": "string", "default": "Months" }, - "year": { "type": "string", "default": "Year" }, - "year_plural": { "type": "string", "default": "Years" } - }, - "required": [ - "label", - "helper_text", - "day", - "day_plural", - "week", - "week_plural", - "month", - "month_plural", - "year", - "year_plural" - ] - }, - "subscription-start-date": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Subscription start" }, - "helper_text": { - "type": "string", - "default": "The original date this subscription began or will begin if set in the future. To modify this value for an existing subscription, you must modify the subscription directly." - }, - "placeholder": { "type": "string", "default": "01/01/2022" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "subscription-end-date": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Subscription end" }, - "helper_text": { - "type": "string", - "default": "If set, the date this subscription will end. The subscription will not run on this day." - }, - "placeholder": { "type": "string", "default": "01/01/2022" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "discount-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Discount name" }, - "helper_text": { - "type": "string", - "default": "The name of the line item discount if it is included on this item." - }, - "placeholder": { "type": "string", "default": "One-off 10% discount" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "discount-builder": { - "additionalProperties": false, - "properties": { - "tier": { "type": "string", "default": "Tier" }, - "tier_by": { "type": "string", "default": "by" }, - "tier_if": { "type": "string", "default": "if" }, - "tier_allunits": { "type": "string", "default": "price of each item" }, - "tier_incremental": { "type": "string", "default": "price of additional items" }, - "tier_repeat": { "type": "string", "default": "price of next item" }, - "tier_single": { "type": "string", "default": "order total" }, - "tier_then": { "type": "string", "default": "then" }, - "quantity": { "type": "string", "default": "quantity" }, - "total": { "type": "string", "default": "total" }, - "reduce": { "type": "string", "default": "reduce" }, - "increase": { "type": "string", "default": "increase" } - }, - "required": [ - "tier", - "tier_by", - "tier_if", - "tier_allunits", - "tier_incremental", - "tier_repeat", - "tier_single", - "tier_then", - "quantity", - "total", - "reduce", - "increase" - ] - }, - "expires": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Expires" }, - "helper_text": { - "type": "string", - "default": "Date when this item will be removed from the cart (optional)." - }, - "placeholder": { "type": "string", "default": "01/01/2022" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "image": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Image" }, - "helper_text": { - "type": "string", - "default": "URL of the image to display for this item in the cart and checkout." - }, - "placeholder": { "type": "string", "default": "https://picsum.photos/256" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "url": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "URL" }, - "helper_text": { - "type": "string", - "default": "Full URL for the customer to view this item on the store website." - }, - "placeholder": { "type": "string", "default": "https://example.com/products/123" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "quantity-min": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Min quantity" }, - "helper_text": { "type": "string", "default": "Minimum quantity per cart." }, - "placeholder": { "type": "string", "default": "1" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "quantity-max": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Max quantity" }, - "helper_text": { "type": "string", "default": "Maximum quantity per cart." }, - "placeholder": { "type": "string", "default": "25" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "shipto": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Shipping address" }, - "helper_text": { - "type": "string", - "default": "Used for multiship to assign this item to a specific shipment." - }, - "placeholder": { - "type": "string", - "default": "Select address to ship this item to..." - } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "width": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Width" }, - "helper_text": { - "type": "string", - "default": "This is currently a placeholder for future use." - }, - "placeholder": { "type": "string", "default": "16" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "height": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Height" }, - "helper_text": { - "type": "string", - "default": "This is currently a placeholder for future use." - }, - "placeholder": { "type": "string", "default": "8" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "length": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Width" }, - "helper_text": { - "type": "string", - "default": "This is currently a placeholder for future use." - }, - "placeholder": { "type": "string", "default": "32" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "weight": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Weight" }, - "helper_text": { - "type": "string", - "default": "Per-item weight, used for shipping rate requests." - }, - "placeholder": { "type": "string", "default": "24" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "item-category-uri": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Item category" }, - "helper_text": { - "type": "string", - "default": "Item category associated with this item." - }, - "placeholder": { "type": "string", "default": "Select item category..." } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "code": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Code" }, - "helper_text": { - "type": "string", - "default": "Unique item code such as SKU or barcode." - }, - "placeholder": { "type": "string", "default": "MY-PRODUCT-001" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "parent-code": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Parent code" }, - "helper_text": { - "type": "string", - "default": "Used if this should be a child product in a bundle." - }, - "placeholder": { "type": "string", "default": "MY-BUNDLE-001" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "discount-details": { - "additionalProperties": false, - "properties": { - "title": { "type": "string", "default": "Discount details" }, - "pagination": { - "additionalProperties": false, - "properties": { - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { - "type": "string", - "default": "{{from}}-{{to}} out of {{total}}" - }, - "previous": { "type": "string", "default": "Previous" }, - "card": { - "additionalProperties": false, - "properties": { - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["spinner"] - } - }, - "required": ["first", "last", "next", "pagination", "previous", "card"] - } - }, - "required": ["title", "pagination"] - }, - "coupon-details": { - "additionalProperties": false, - "properties": { - "title": { "type": "string", "default": "Coupon details" }, - "pagination": { - "additionalProperties": false, - "properties": { - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { - "type": "string", - "default": "{{from}}-{{to}} out of {{total}}" - }, - "previous": { "type": "string", "default": "Previous" }, - "card": { - "additionalProperties": false, - "properties": { - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["spinner"] - } - }, - "required": ["first", "last", "next", "pagination", "previous", "card"] - } - }, - "required": ["title", "pagination"] - }, - "attributes": { - "additionalProperties": false, - "properties": { - "title": { "type": "string", "default": "Attributes" }, - "delete_header": { "type": "string", "default": "Remove attribute?" }, - "delete_message": { - "type": "string", - "default": "Please confirm that you'd like to remove this attribute from the item." - }, - "delete_confirm": { "type": "string", "default": "Remove" }, - "delete_cancel": { "type": "string", "default": "Cancel" }, - "dialog": { - "additionalProperties": false, - "properties": { - "header_create": { "type": "string", "default": "Create attribute" }, - "header_update": { "type": "string", "default": "Update attribute" }, - "close": { "type": "string", "default": "Close" }, - "save": { "type": "string", "default": "Save" }, - "cancel": { "type": "string", "default": "Cancel" }, - "undo_header": { "type": "string", "default": "Unsaved changes" }, - "undo_message": { - "type": "string", - "default": "Looks like you didn't save your changes! What would you like to do with them?" - }, - "undo_cancel": { "type": "string", "default": "Review" }, - "undo_confirm": { "type": "string", "default": "Discard" }, - "attribute-form": { - "additionalProperties": false, - "properties": { - "name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Name" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "Name of this attribute. It does not have to be unique." - }, - "v8n_required": { - "type": "string", - "default": "Please name this attribute." - }, - "v8n_too_long": { - "type": "string", - "default": "Please choose a name that is 500 characters long or less." - } - }, - "required": [ - "label", - "placeholder", - "helper_text", - "v8n_required", - "v8n_too_long" - ] - }, - "value": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Value" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "Value of this attribute. Attribute values are automatically HTML-escaped." - }, - "v8n_required": { - "type": "string", - "default": "Please provide a value for this attribute." - }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we can't store values that are more than 1000 characters long." - } - }, - "required": [ - "label", - "placeholder", - "helper_text", - "v8n_required", - "v8n_too_long" - ] - }, - "visibility": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Visibility" }, - "option_public": { "type": "string", "default": "Everyone" }, - "option_restricted": { "type": "string", "default": "Store admins" }, - "option_private": { "type": "string", "default": "Only me" }, - "helper_text": { - "type": "string", - "default": "Controls who can see this attribute. Public attributes can be shown to anyone, including customers. Private attributes are more suitable for configuration or technical details which are irrelevant to the public. Restricted attributes can only be viewed with the OAuth client that created them." - } - }, - "required": [ - "label", - "option_public", - "option_restricted", - "option_private", - "helper_text" - ] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date": { "type": "string", "default": "{{value, date}}" }, - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" } - }, - "required": ["date", "date_created", "date_modified"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove this attribute? You won't be able to bring it back." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "name", - "value", - "visibility", - "timestamps", - "delete", - "create", - "spinner" - ] - } - }, - "required": [ - "header_create", - "header_update", - "close", - "save", - "cancel", - "undo_header", - "undo_message", - "undo_cancel", - "undo_confirm", - "attribute-form" - ] - }, - "pagination": { - "additionalProperties": false, - "properties": { - "create_button_text": { "type": "string", "default": "Add attribute +" }, - "card": { - "additionalProperties": false, - "properties": { - "delete_button_text": { "type": "string", "default": "Delete" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["delete_button_text", "spinner"] - }, - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { - "type": "string", - "default": "{{from}}-{{to}} out of {{total}}" - }, - "previous": { "type": "string", "default": "Previous" } - }, - "required": [ - "create_button_text", - "card", - "first", - "last", - "next", - "pagination", - "previous" - ] - } - }, - "required": [ - "title", - "delete_header", - "delete_message", - "delete_confirm", - "delete_cancel", - "dialog", - "pagination" - ] - }, - "item-options": { - "additionalProperties": false, - "properties": { - "title": { "type": "string", "default": "Item options" }, - "delete_header": { "type": "string", "default": "Remove item option?" }, - "delete_message": { - "type": "string", - "default": "Please confirm that you'd like to remove this item option from the item." - }, - "delete_confirm": { "type": "string", "default": "Remove" }, - "delete_cancel": { "type": "string", "default": "Cancel" }, - "dialog": { - "additionalProperties": false, - "properties": { - "header_create": { "type": "string", "default": "Create option" }, - "header_update": { "type": "string", "default": "Update option" }, - "close": { "type": "string", "default": "Close" }, - "save": { "type": "string", "default": "Save" }, - "cancel": { "type": "string", "default": "Cancel" }, - "undo_header": { "type": "string", "default": "Unsaved changes" }, - "undo_message": { - "type": "string", - "default": "Looks like you didn't save your changes! What would you like to do with them?" - }, - "undo_cancel": { "type": "string", "default": "Review" }, - "undo_confirm": { "type": "string", "default": "Discard" }, - "item-option-form": { - "additionalProperties": false, - "properties": { - "name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Name" }, - "helper_text": { "type": "string", "default": "" }, - "placeholder": { "type": "string", "default": "Color" }, - "v8n_required": { "type": "string", "default": "Name is required" }, - "v8n_too_long": { - "type": "string", - "default": "Name mustn't exceed 100 characters" - } - }, - "required": [ - "label", - "helper_text", - "placeholder", - "v8n_required", - "v8n_too_long" - ] - }, - "value": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Value" }, - "helper_text": { "type": "string", "default": "" }, - "placeholder": { "type": "string", "default": "Red" }, - "v8n_required": { "type": "string", "default": "Value is required" }, - "v8n_too_long": { - "type": "string", - "default": "Value mustn't exceed 1024 characters" - } - }, - "required": [ - "label", - "helper_text", - "placeholder", - "v8n_required", - "v8n_too_long" - ] - }, - "price-mod": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Price" }, - "helper_text": { "type": "string", "default": "Same currency as item" }, - "placeholder": { "type": "string", "default": "10" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "weight-mod": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Weight" }, - "helper_text": { "type": "string", "default": "Arbitrary units" }, - "placeholder": { "type": "string", "default": "5" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "date": { "type": "string", "default": "{{value, date}}" } - }, - "required": ["date_created", "date_modified", "date"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove this item option? You won't be able to bring it back." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - } - }, - "required": [ - "name", - "value", - "price-mod", - "weight-mod", - "timestamps", - "spinner", - "delete", - "create" - ] - } - }, - "required": [ - "header_create", - "header_update", - "close", - "save", - "cancel", - "undo_header", - "undo_message", - "undo_cancel", - "undo_confirm", - "item-option-form" - ] - }, - "pagination": { - "additionalProperties": false, - "properties": { - "card": { - "additionalProperties": false, - "properties": { - "delete_button_text": { "type": "string", "default": "Delete" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["delete_button_text", "spinner"] - }, - "create_button_text": { "type": "string", "default": "Add option +" }, - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { - "type": "string", - "default": "{{from}}-{{to}} out of {{total}}" - }, - "previous": { "type": "string", "default": "Previous" } - }, - "required": [ - "card", - "create_button_text", - "first", - "last", - "next", - "pagination", - "previous" - ] - } - }, - "required": [ - "title", - "delete_header", - "delete_message", - "delete_confirm", - "delete_cancel", - "dialog", - "pagination" - ] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "date": { "type": "string", "default": "{{value, date}}" } - }, - "required": ["date_created", "date_modified", "date"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove this item? You won't be able to bring it back." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "close", - "cancel", - "header_update", - "header_create", - "save", - "undo_header", - "undo_message", - "undo_cancel", - "undo_confirm", - "dimensions", - "subscriptions", - "discount", - "name", - "price", - "quantity", - "subscription-frequency", - "subscription-start-date", - "subscription-end-date", - "discount-name", - "discount-builder", - "expires", - "image", - "url", - "quantity-min", - "quantity-max", - "shipto", - "width", - "height", - "length", - "weight", - "item-category-uri", - "code", - "parent-code", - "discount-details", - "coupon-details", - "attributes", - "item-options", - "timestamps", - "delete", - "create", - "spinner" - ] - } - }, - "required": [ - "label", - "delete_confirm", - "delete_cancel", - "delete_message", - "delete_header", - "pagination", - "dialog" - ] - }, - "applied-coupon-codes": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Coupon codes" }, - "delete_confirm": { "type": "string", "default": "Delete" }, - "delete_cancel": { "type": "string", "default": "Cancel" }, - "delete_message": { - "type": "string", - "default": "Are you sure you'd like to remove this coupon code? This might affect the cart total." - }, - "delete_header": { "type": "string", "default": "Delete code?" }, - "pagination": { - "additionalProperties": false, - "properties": { - "create_button_text": { "type": "string", "default": "Apply code +" }, - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { "type": "string", "default": "{{from}}-{{to}} out of {{total}}" }, - "previous": { "type": "string", "default": "Previous" }, - "card": { - "additionalProperties": false, - "properties": { - "delete_button_text": { "type": "string", "default": "Remove" }, - "price": { "type": "string", "default": "{{amount, price}}" }, - "wgt": { "type": "string", "default": "WGT" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No codes" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["delete_button_text", "price", "wgt", "spinner"] - } - }, - "required": [ - "create_button_text", - "first", - "last", - "next", - "pagination", - "previous", - "card" - ] - }, - "dialog": { - "additionalProperties": false, - "properties": { - "close": { "type": "string", "default": "Close" }, - "cancel": { "type": "string", "default": "Cancel" }, - "header_update": { "type": "string", "default": "Coupon code" }, - "header_create": { "type": "string", "default": "Apply code" }, - "save": { "type": "string", "default": "Save" }, - "undo_header": { "type": "string", "default": "Unsaved changes" }, - "undo_message": { - "type": "string", - "default": "Looks like you didn't save your changes! What would you like to do with them?" - }, - "undo_cancel": { "type": "string", "default": "Review" }, - "undo_confirm": { "type": "string", "default": "Discard" } - }, - "required": [ - "close", - "cancel", - "header_update", - "header_create", - "save", - "undo_header", - "undo_message", - "undo_cancel", - "undo_confirm" - ] - } - }, - "required": [ - "label", - "delete_confirm", - "delete_cancel", - "delete_message", - "delete_header", - "pagination", - "dialog" - ] - }, - "totals": { - "additionalProperties": false, - "properties": { - "price": { "type": "string", "default": "{{ amount, price }}" }, - "total_order": { "type": "string", "default": "Total: {{ amount, price }}" }, - "total_item_price": { "type": "string", "default": "Total item price" }, - "total_shipping": { "type": "string", "default": "Total shipping" }, - "total_tax": { "type": "string", "default": "Total tax" } - }, - "required": ["price", "total_order", "total_item_price", "total_shipping", "total_tax"] - }, - "discounts": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Discounts" }, - "pagination": { - "additionalProperties": false, - "properties": { - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { "type": "string", "default": "{{from}}-{{to}} out of {{total}}" }, - "previous": { "type": "string", "default": "Previous" }, - "card": { - "additionalProperties": false, - "properties": { - "price": { "type": "string", "default": "{{amount, price}}" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No discounts" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["price", "spinner"] - } - }, - "required": ["first", "last", "next", "pagination", "previous", "card"] - } - }, - "required": ["label", "pagination"] - }, - "template-set-uri": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Template set" }, - "placeholder": { "type": "string", "default": "Select template set..." }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "billing-first-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "First name" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "We can't store first names that are more than 50 characters long. Please shorten this value." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "billing-last-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Last name" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "We can't store last names that are more than 50 characters long. Please shorten this value." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "billing-company": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Company" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "We can't store company names that are more than 50 characters long. Please shorten this value." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "billing-phone": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Phone" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "This phone number is unusually long. Please use a value below 50 characters." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "billing-address-one": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Address Line 1" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "Please shorten this value to fit 100 characters." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "billing-address-two": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Address Line 2" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "Please shorten this value to fit 100 characters." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "billing-country": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Country" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "Please shorten this value to fit 50 characters." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "billing-region": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Region" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "Please shorten this value to fit 50 characters." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "billing-city": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "City" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "Please shorten this value to fit 50 characters." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "billing-postal-code": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Postal code" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "This postal code is unsually long. Please use a code that fits in 50 characters." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "shipping-first-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "First name" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "We can't store first names that are more than 50 characters long. Please shorten this value." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "shipping-last-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Last name" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "We can't store last names that are more than 50 characters long. Please shorten this value." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "shipping-company": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Company" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "We can't store company names that are more than 50 characters long. Please shorten this value." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "shipping-phone": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Phone" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "This phone number is unusually long. Please use a value below 50 characters." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "shipping-address-one": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Address Line 1" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "Please shorten this value to fit 100 characters." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "shipping-address-two": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Address Line 2" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "Please shorten this value to fit 100 characters." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "shipping-country": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Country" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "Please shorten this value to fit 50 characters." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "shipping-region": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Region" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "Please shorten this value to fit 50 characters." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "shipping-city": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "City" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "Please shorten this value to fit 50 characters." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "shipping-postal-code": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Postal code" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "This postal code is unsually long. Please use a code that fits in 50 characters." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "custom-fields": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Custom fields" }, - "delete_confirm": { "type": "string", "default": "Delete" }, - "delete_cancel": { "type": "string", "default": "Cancel" }, - "delete_message": { - "type": "string", - "default": "Are you sure you'd like to remove this custom field? This action can't be undone." - }, - "delete_header": { "type": "string", "default": "Delete custom field?" }, - "pagination": { - "additionalProperties": false, - "properties": { - "create_button_text": { "type": "string", "default": "Add custom field +" }, - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { "type": "string", "default": "{{from}}-{{to}} out of {{total}}" }, - "previous": { "type": "string", "default": "Previous" }, - "card": { - "additionalProperties": false, - "properties": { - "delete_button_text": { "type": "string", "default": "Remove" }, - "price": { "type": "string", "default": "{{amount, price}}" }, - "wgt": { "type": "string", "default": "WGT" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No custom fields" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["delete_button_text", "price", "wgt", "spinner"] - } - }, - "required": [ - "create_button_text", - "first", - "last", - "next", - "pagination", - "previous", - "card" - ] - }, - "dialog": { - "additionalProperties": false, - "properties": { - "close": { "type": "string", "default": "Close" }, - "cancel": { "type": "string", "default": "Cancel" }, - "header_update": { "type": "string", "default": "Custom field" }, - "header_create": { "type": "string", "default": "New custom field" }, - "save": { "type": "string", "default": "Save" }, - "undo_header": { "type": "string", "default": "Unsaved changes" }, - "undo_message": { - "type": "string", - "default": "Looks like you didn't save your changes! What would you like to do with them?" - }, - "undo_cancel": { "type": "string", "default": "Review" }, - "undo_confirm": { "type": "string", "default": "Discard" } - }, - "required": [ - "close", - "cancel", - "header_update", - "header_create", - "save", - "undo_header", - "undo_message", - "undo_cancel", - "undo_confirm" - ] - } - }, - "required": [ - "label", - "delete_confirm", - "delete_cancel", - "delete_message", - "delete_header", - "pagination", - "dialog" - ] - }, - "attributes": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Attributes" }, - "delete_confirm": { "type": "string", "default": "Delete" }, - "delete_cancel": { "type": "string", "default": "Cancel" }, - "delete_message": { - "type": "string", - "default": "Are you sure you'd like to remove this attribute? This action can't be undone." - }, - "delete_header": { "type": "string", "default": "Delete attribute?" }, - "pagination": { - "additionalProperties": false, - "properties": { - "create_button_text": { "type": "string", "default": "Add attribute +" }, - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { "type": "string", "default": "{{from}}-{{to}} out of {{total}}" }, - "previous": { "type": "string", "default": "Previous" }, - "card": { - "additionalProperties": false, - "properties": { - "delete_button_text": { "type": "string", "default": "Remove" }, - "price": { "type": "string", "default": "{{amount, price}}" }, - "wgt": { "type": "string", "default": "WGT" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No attributes" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["delete_button_text", "price", "wgt", "spinner"] - } - }, - "required": [ - "create_button_text", - "first", - "last", - "next", - "pagination", - "previous", - "card" - ] - }, - "dialog": { - "additionalProperties": false, - "properties": { - "close": { "type": "string", "default": "Close" }, - "cancel": { "type": "string", "default": "Cancel" }, - "header_update": { "type": "string", "default": "Custom field" }, - "header_create": { "type": "string", "default": "New attribute" }, - "save": { "type": "string", "default": "Save" }, - "undo_header": { "type": "string", "default": "Unsaved changes" }, - "undo_message": { - "type": "string", - "default": "Looks like you didn't save your changes! What would you like to do with them?" - }, - "undo_cancel": { "type": "string", "default": "Review" }, - "undo_confirm": { "type": "string", "default": "Discard" } - }, - "required": [ - "close", - "cancel", - "header_update", - "header_create", - "save", - "undo_header", - "undo_message", - "undo_cancel", - "undo_confirm" - ] - } - }, - "required": [ - "label", - "delete_confirm", - "delete_cancel", - "delete_message", - "delete_header", - "pagination", - "dialog" - ] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "date": { "type": "string", "default": "{{value, date}}" } - }, - "required": ["date_created", "date_modified", "date"] - }, - "view-as-customer": { - "additionalProperties": false, - "properties": { - "state_idle": { "type": "string", "default": "View as customer" }, - "state_busy": { "type": "string", "default": "Creating cart link..." }, - "state_fail": { "type": "string", "default": "Failed to create cart link" } - }, - "required": ["state_idle", "state_busy", "state_fail"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove this cart? You won't be able to bring it back." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "order_section_title", - "order_section_description", - "billing_section_title", - "billing_section_description", - "shipping_section_title", - "shipping_section_description", - "customer-type", - "customer", - "items", - "applied-coupon-codes", - "totals", - "discounts", - "template-set-uri", - "billing-first-name", - "billing-last-name", - "billing-company", - "billing-phone", - "billing-address-one", - "billing-address-two", - "billing-country", - "billing-region", - "billing-city", - "billing-postal-code", - "shipping-first-name", - "shipping-last-name", - "shipping-company", - "shipping-phone", - "shipping-address-one", - "shipping-address-two", - "shipping-country", - "shipping-region", - "shipping-city", - "shipping-postal-code", - "custom-fields", - "attributes", - "timestamps", - "view-as-customer", - "delete", - "create", - "spinner" - ] -} diff --git a/src/static/schemas/client-card.json b/src/static/schemas/client-card.json deleted file mode 100644 index 77c00e137..000000000 --- a/src/static/schemas/client-card.json +++ /dev/null @@ -1,19 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "no_project_name": { "type": "string", "default": "Unnamed project" }, - "no_project_description": { "type": "string", "default": "No description provided" }, - "no_company_name": { "type": "string", "default": "Unknown company" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["no_project_name", "no_project_description", "no_company_name", "spinner"] -} diff --git a/src/static/schemas/client-form.json b/src/static/schemas/client-form.json deleted file mode 100644 index 2d39e3932..000000000 --- a/src/static/schemas/client-form.json +++ /dev/null @@ -1,157 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "client-id": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Client ID" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "client-secret": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Client secret" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "project-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Project name" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "project-description": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Project description" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "redirect-uri": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Redirect URI" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "company-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Company name" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "company-url": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Company url" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "company-logo": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Company logo" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "contact-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Contact name" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "contact-email": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Contact email" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "contact-phone": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Contact phone" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "date": { "type": "string", "default": "{{value, date}}" } - }, - "required": ["date_created", "date_modified", "date"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Once deleted, applications using this client will no longer be able to access Foxy stores and users." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "client-id", - "client-secret", - "project-name", - "project-description", - "redirect-uri", - "company-name", - "company-url", - "company-logo", - "contact-name", - "contact-email", - "contact-phone", - "timestamps", - "delete", - "create", - "spinner" - ] -} diff --git a/src/static/schemas/copy-to-clipboard.json b/src/static/schemas/copy-to-clipboard.json deleted file mode 100644 index bcb0a9a86..000000000 --- a/src/static/schemas/copy-to-clipboard.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "click_to_copy": { "type": "string", "default": "Click to copy" }, - "copying": { "type": "string", "default": "Copying" }, - "done": { "type": "string", "default": "Done" }, - "failed_to_copy": { "type": "string", "default": "Failed to copy" } - }, - "required": ["click_to_copy", "copying", "done", "failed_to_copy"] -} diff --git a/src/static/schemas/country.json b/src/static/schemas/country.json deleted file mode 100644 index 4544fc9ae..000000000 --- a/src/static/schemas/country.json +++ /dev/null @@ -1,506 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "AF": { "type": "string", "default": "Afghanistan" }, - "AX": { "type": "string", "default": "Åland Islands" }, - "AL": { "type": "string", "default": "Albania" }, - "DZ": { "type": "string", "default": "Algeria" }, - "AS": { "type": "string", "default": "American Samoa" }, - "AD": { "type": "string", "default": "Andorra" }, - "AO": { "type": "string", "default": "Angola" }, - "AI": { "type": "string", "default": "Anguilla" }, - "AQ": { "type": "string", "default": "Antarctica" }, - "AG": { "type": "string", "default": "Antigua and Barbuda" }, - "AR": { "type": "string", "default": "Argentina" }, - "AM": { "type": "string", "default": "Armenia" }, - "AW": { "type": "string", "default": "Aruba" }, - "AU": { "type": "string", "default": "Australia" }, - "AT": { "type": "string", "default": "Austria" }, - "AZ": { "type": "string", "default": "Azerbaijan" }, - "BS": { "type": "string", "default": "Bahamas" }, - "BH": { "type": "string", "default": "Bahrain" }, - "BD": { "type": "string", "default": "Bangladesh" }, - "BB": { "type": "string", "default": "Barbados" }, - "BY": { "type": "string", "default": "Belarus" }, - "BE": { "type": "string", "default": "Belgium" }, - "BZ": { "type": "string", "default": "Belize" }, - "BJ": { "type": "string", "default": "Benin" }, - "BM": { "type": "string", "default": "Bermuda" }, - "BT": { "type": "string", "default": "Bhutan" }, - "BO": { "type": "string", "default": "Bolivia" }, - "BQ": { "type": "string", "default": "Bonaire, Sint Eustatius and Saba" }, - "BA": { "type": "string", "default": "Bosnia and Herzegovina" }, - "BW": { "type": "string", "default": "Botswana" }, - "BV": { "type": "string", "default": "Bouvet Island" }, - "BR": { "type": "string", "default": "Brazil" }, - "IO": { "type": "string", "default": "British Indian Ocean Territory" }, - "BN": { "type": "string", "default": "Brunei Darussalam" }, - "BG": { "type": "string", "default": "Bulgaria" }, - "BF": { "type": "string", "default": "Burkina Faso" }, - "BI": { "type": "string", "default": "Burundi" }, - "KH": { "type": "string", "default": "Cambodia" }, - "CM": { "type": "string", "default": "Cameroon" }, - "CA": { "type": "string", "default": "Canada" }, - "CV": { "type": "string", "default": "Cape Verde" }, - "CW": { "type": "string", "default": "Curaçao" }, - "KY": { "type": "string", "default": "Cayman Islands" }, - "CF": { "type": "string", "default": "Central African Republic" }, - "TD": { "type": "string", "default": "Chad" }, - "CL": { "type": "string", "default": "Chile" }, - "CN": { "type": "string", "default": "China" }, - "CX": { "type": "string", "default": "Christmas Island" }, - "CC": { "type": "string", "default": "Cocos (Keeling) Islands" }, - "CO": { "type": "string", "default": "Colombia" }, - "KM": { "type": "string", "default": "Comoros" }, - "CG": { "type": "string", "default": "Congo" }, - "CD": { "type": "string", "default": "Congo, the Democratic Republic of the" }, - "CK": { "type": "string", "default": "Cook Islands" }, - "CR": { "type": "string", "default": "Costa Rica" }, - "CI": { "type": "string", "default": "Cote DIvoire" }, - "HR": { "type": "string", "default": "Croatia" }, - "CU": { "type": "string", "default": "Cuba" }, - "CY": { "type": "string", "default": "Cyprus" }, - "CZ": { "type": "string", "default": "Czech Republic" }, - "DK": { "type": "string", "default": "Denmark" }, - "DJ": { "type": "string", "default": "Djibouti" }, - "DM": { "type": "string", "default": "Dominica" }, - "DO": { "type": "string", "default": "Dominican Republic" }, - "EC": { "type": "string", "default": "Ecuador" }, - "EG": { "type": "string", "default": "Egypt" }, - "SV": { "type": "string", "default": "El Salvador" }, - "SX": { "type": "string", "default": "Sint Maarten" }, - "GQ": { "type": "string", "default": "Equatorial Guinea" }, - "ER": { "type": "string", "default": "Eritrea" }, - "EE": { "type": "string", "default": "Estonia" }, - "ET": { "type": "string", "default": "Ethiopia" }, - "FK": { "type": "string", "default": "Falkland Islands (Malvinas)" }, - "FO": { "type": "string", "default": "Faroe Islands" }, - "FJ": { "type": "string", "default": "Fiji" }, - "FI": { "type": "string", "default": "Finland" }, - "FR": { "type": "string", "default": "France" }, - "GF": { "type": "string", "default": "French Guiana" }, - "PF": { "type": "string", "default": "French Polynesia" }, - "TF": { "type": "string", "default": "French Southern Territories" }, - "GA": { "type": "string", "default": "Gabon" }, - "GM": { "type": "string", "default": "Gambia" }, - "GE": { "type": "string", "default": "Georgia" }, - "DE": { "type": "string", "default": "Germany" }, - "GH": { "type": "string", "default": "Ghana" }, - "GI": { "type": "string", "default": "Gibraltar" }, - "GR": { "type": "string", "default": "Greece" }, - "GL": { "type": "string", "default": "Greenland" }, - "GD": { "type": "string", "default": "Grenada" }, - "GP": { "type": "string", "default": "Guadeloupe" }, - "GU": { "type": "string", "default": "Guam" }, - "GT": { "type": "string", "default": "Guatemala" }, - "GG": { "type": "string", "default": "Guernsey" }, - "GN": { "type": "string", "default": "Guinea" }, - "GW": { "type": "string", "default": "Guinea-bissau" }, - "GY": { "type": "string", "default": "Guyana" }, - "HT": { "type": "string", "default": "Haiti" }, - "HM": { "type": "string", "default": "Heard Island and McDonald Island" }, - "VA": { "type": "string", "default": "Holy See (Vatican City State)" }, - "HN": { "type": "string", "default": "Honduras" }, - "HK": { "type": "string", "default": "Hong Kong" }, - "HU": { "type": "string", "default": "Hungary" }, - "IS": { "type": "string", "default": "Iceland" }, - "IN": { "type": "string", "default": "India" }, - "ID": { "type": "string", "default": "Indonesia" }, - "IR": { "type": "string", "default": "Iran, Islamic Republic of" }, - "IQ": { "type": "string", "default": "Iraq" }, - "IE": { "type": "string", "default": "Ireland" }, - "IM": { "type": "string", "default": "Isle of Man" }, - "IL": { "type": "string", "default": "Israel" }, - "IT": { "type": "string", "default": "Italy" }, - "JM": { "type": "string", "default": "Jamaica" }, - "JP": { "type": "string", "default": "Japan" }, - "JE": { "type": "string", "default": "Jersey" }, - "JO": { "type": "string", "default": "Jordan" }, - "KZ": { "type": "string", "default": "Kazakhstan" }, - "KE": { "type": "string", "default": "Kenya" }, - "KI": { "type": "string", "default": "Kiribati" }, - "KP": { "type": "string", "default": "Korea, Democratic People's Republic of" }, - "KR": { "type": "string", "default": "Korea, Republic of" }, - "KW": { "type": "string", "default": "Kuwait" }, - "KG": { "type": "string", "default": "Kyrgyzstan" }, - "LA": { "type": "string", "default": "Lao People's Democratic Republic" }, - "LV": { "type": "string", "default": "Latvia" }, - "LB": { "type": "string", "default": "Lebanon" }, - "LS": { "type": "string", "default": "Lesotho" }, - "LR": { "type": "string", "default": "Liberia" }, - "LY": { "type": "string", "default": "Libya" }, - "LI": { "type": "string", "default": "Liechtenstein" }, - "LT": { "type": "string", "default": "Lithuania" }, - "LU": { "type": "string", "default": "Luxembourg" }, - "MO": { "type": "string", "default": "Macau Special Administrative Region of China" }, - "MK": { "type": "string", "default": "North Macedonia" }, - "MG": { "type": "string", "default": "Madagascar" }, - "MW": { "type": "string", "default": "Malawi" }, - "MY": { "type": "string", "default": "Malaysia" }, - "MV": { "type": "string", "default": "Maldives" }, - "ML": { "type": "string", "default": "Mali" }, - "MT": { "type": "string", "default": "Malta" }, - "MH": { "type": "string", "default": "Marshall Islands" }, - "MQ": { "type": "string", "default": "Martinique" }, - "MR": { "type": "string", "default": "Mauritania" }, - "MU": { "type": "string", "default": "Mauritius" }, - "YT": { "type": "string", "default": "Mayotte" }, - "MX": { "type": "string", "default": "Mexico" }, - "FM": { "type": "string", "default": "Micronesia, Federated States of" }, - "MD": { "type": "string", "default": "Moldova, Republic of" }, - "MC": { "type": "string", "default": "Monaco" }, - "MN": { "type": "string", "default": "Mongolia" }, - "ME": { "type": "string", "default": "Montenegro" }, - "MS": { "type": "string", "default": "Montserrat" }, - "MA": { "type": "string", "default": "Morocco" }, - "MZ": { "type": "string", "default": "Mozambique" }, - "MM": { "type": "string", "default": "Myanmar" }, - "NA": { "type": "string", "default": "Namibia" }, - "NR": { "type": "string", "default": "Nauru" }, - "NP": { "type": "string", "default": "Nepal" }, - "NL": { "type": "string", "default": "Netherlands" }, - "NC": { "type": "string", "default": "New Caledonia" }, - "NZ": { "type": "string", "default": "New Zealand" }, - "NI": { "type": "string", "default": "Nicaragua" }, - "NE": { "type": "string", "default": "Niger" }, - "NG": { "type": "string", "default": "Nigeria" }, - "NU": { "type": "string", "default": "Niue" }, - "NF": { "type": "string", "default": "Norfolk Island" }, - "MP": { "type": "string", "default": "Northern Mariana Islands" }, - "NO": { "type": "string", "default": "Norway" }, - "OM": { "type": "string", "default": "Oman" }, - "PK": { "type": "string", "default": "Pakistan" }, - "PW": { "type": "string", "default": "Palau" }, - "PS": { "type": "string", "default": "Palestine, State of" }, - "PA": { "type": "string", "default": "Panama" }, - "PG": { "type": "string", "default": "Papua New Guinea" }, - "PY": { "type": "string", "default": "Paraguay" }, - "PE": { "type": "string", "default": "Peru" }, - "PH": { "type": "string", "default": "Philippines" }, - "PN": { "type": "string", "default": "Pitcairn" }, - "PL": { "type": "string", "default": "Poland" }, - "PT": { "type": "string", "default": "Portugal" }, - "PR": { "type": "string", "default": "Puerto Rico" }, - "QA": { "type": "string", "default": "Qatar" }, - "RE": { "type": "string", "default": "Réunion" }, - "RO": { "type": "string", "default": "Romania" }, - "RU": { "type": "string", "default": "Russian Federation" }, - "RW": { "type": "string", "default": "Rwanda" }, - "BL": { "type": "string", "default": "Saint Barthélemy" }, - "SH": { "type": "string", "default": "Saint Helena, Ascension and Tristan da Cunha" }, - "KN": { "type": "string", "default": "Saint Kitts and Nevis" }, - "LC": { "type": "string", "default": "Saint Lucia" }, - "MF": { "type": "string", "default": "Saint Martin" }, - "PM": { "type": "string", "default": "Saint Pierre and Miquelon" }, - "VC": { "type": "string", "default": "Saint Vincent and the Grenadines" }, - "WS": { "type": "string", "default": "Samoa" }, - "SM": { "type": "string", "default": "San Marino" }, - "SS": { "type": "string", "default": "South Sudan" }, - "ST": { "type": "string", "default": "Sao Tome and Principe" }, - "SA": { "type": "string", "default": "Saudi Arabia" }, - "SN": { "type": "string", "default": "Senegal" }, - "RS": { "type": "string", "default": "Serbia" }, - "SC": { "type": "string", "default": "Seychelles" }, - "SL": { "type": "string", "default": "Sierra Leone" }, - "SG": { "type": "string", "default": "Singapore" }, - "SK": { "type": "string", "default": "Slovakia" }, - "SI": { "type": "string", "default": "Slovenia" }, - "SB": { "type": "string", "default": "Solomon Islands" }, - "SO": { "type": "string", "default": "Somalia" }, - "ZA": { "type": "string", "default": "South Africa" }, - "GS": { "type": "string", "default": "South Georgia and the South Sandwich Islands" }, - "ES": { "type": "string", "default": "Spain" }, - "LK": { "type": "string", "default": "Sri Lanka" }, - "SD": { "type": "string", "default": "Sudan" }, - "SR": { "type": "string", "default": "Suriname" }, - "SJ": { "type": "string", "default": "Svalbard and Jan Mayen" }, - "SZ": { "type": "string", "default": "Eswatini" }, - "SE": { "type": "string", "default": "Sweden" }, - "CH": { "type": "string", "default": "Switzerland" }, - "SY": { "type": "string", "default": "Syrian Arab Republic" }, - "TW": { "type": "string", "default": "Taiwan" }, - "TJ": { "type": "string", "default": "Tajikistan" }, - "TZ": { "type": "string", "default": "Tanzania, United Republic of" }, - "TH": { "type": "string", "default": "Thailand" }, - "TL": { "type": "string", "default": "Timor-Leste" }, - "TG": { "type": "string", "default": "Togo" }, - "TK": { "type": "string", "default": "Tokelau" }, - "TO": { "type": "string", "default": "Tonga" }, - "TT": { "type": "string", "default": "Trinidad and Tobago" }, - "TN": { "type": "string", "default": "Tunisia" }, - "TR": { "type": "string", "default": "Turkey" }, - "TM": { "type": "string", "default": "Turkmenistan" }, - "TC": { "type": "string", "default": "Turks and Caicos Islands" }, - "TV": { "type": "string", "default": "Tuvalu" }, - "UG": { "type": "string", "default": "Uganda" }, - "UA": { "type": "string", "default": "Ukraine" }, - "AE": { "type": "string", "default": "United Arab Emirates" }, - "GB": { "type": "string", "default": "United Kingdom" }, - "US": { "type": "string", "default": "United States" }, - "UM": { "type": "string", "default": "United States Minor Outlying Islands" }, - "UY": { "type": "string", "default": "Uruguay" }, - "UZ": { "type": "string", "default": "Uzbekistan" }, - "VU": { "type": "string", "default": "Vanuatu" }, - "VE": { "type": "string", "default": "Venezuela" }, - "VN": { "type": "string", "default": "Vietnam" }, - "VG": { "type": "string", "default": "Virgin Islands, British" }, - "VI": { "type": "string", "default": "Virgin Islands, U.S." }, - "WF": { "type": "string", "default": "Wallis and Futuna Islands" }, - "EH": { "type": "string", "default": "Western Sahara" }, - "YE": { "type": "string", "default": "Yemen" }, - "ZM": { "type": "string", "default": "Zambia" }, - "ZW": { "type": "string", "default": "Zimbabwe" } - }, - "required": [ - "AF", - "AX", - "AL", - "DZ", - "AS", - "AD", - "AO", - "AI", - "AQ", - "AG", - "AR", - "AM", - "AW", - "AU", - "AT", - "AZ", - "BS", - "BH", - "BD", - "BB", - "BY", - "BE", - "BZ", - "BJ", - "BM", - "BT", - "BO", - "BQ", - "BA", - "BW", - "BV", - "BR", - "IO", - "BN", - "BG", - "BF", - "BI", - "KH", - "CM", - "CA", - "CV", - "CW", - "KY", - "CF", - "TD", - "CL", - "CN", - "CX", - "CC", - "CO", - "KM", - "CG", - "CD", - "CK", - "CR", - "CI", - "HR", - "CU", - "CY", - "CZ", - "DK", - "DJ", - "DM", - "DO", - "EC", - "EG", - "SV", - "SX", - "GQ", - "ER", - "EE", - "ET", - "FK", - "FO", - "FJ", - "FI", - "FR", - "GF", - "PF", - "TF", - "GA", - "GM", - "GE", - "DE", - "GH", - "GI", - "GR", - "GL", - "GD", - "GP", - "GU", - "GT", - "GG", - "GN", - "GW", - "GY", - "HT", - "HM", - "VA", - "HN", - "HK", - "HU", - "IS", - "IN", - "ID", - "IR", - "IQ", - "IE", - "IM", - "IL", - "IT", - "JM", - "JP", - "JE", - "JO", - "KZ", - "KE", - "KI", - "KP", - "KR", - "KW", - "KG", - "LA", - "LV", - "LB", - "LS", - "LR", - "LY", - "LI", - "LT", - "LU", - "MO", - "MK", - "MG", - "MW", - "MY", - "MV", - "ML", - "MT", - "MH", - "MQ", - "MR", - "MU", - "YT", - "MX", - "FM", - "MD", - "MC", - "MN", - "ME", - "MS", - "MA", - "MZ", - "MM", - "NA", - "NR", - "NP", - "NL", - "NC", - "NZ", - "NI", - "NE", - "NG", - "NU", - "NF", - "MP", - "NO", - "OM", - "PK", - "PW", - "PS", - "PA", - "PG", - "PY", - "PE", - "PH", - "PN", - "PL", - "PT", - "PR", - "QA", - "RE", - "RO", - "RU", - "RW", - "BL", - "SH", - "KN", - "LC", - "MF", - "PM", - "VC", - "WS", - "SM", - "SS", - "ST", - "SA", - "SN", - "RS", - "SC", - "SL", - "SG", - "SK", - "SI", - "SB", - "SO", - "ZA", - "GS", - "ES", - "LK", - "SD", - "SR", - "SJ", - "SZ", - "SE", - "CH", - "SY", - "TW", - "TJ", - "TZ", - "TH", - "TL", - "TG", - "TK", - "TO", - "TT", - "TN", - "TR", - "TM", - "TC", - "TV", - "UG", - "UA", - "AE", - "GB", - "US", - "UM", - "UY", - "UZ", - "VU", - "VE", - "VN", - "VG", - "VI", - "WF", - "EH", - "YE", - "ZM", - "ZW" - ] -} diff --git a/src/static/schemas/coupon-card.json b/src/static/schemas/coupon-card.json deleted file mode 100644 index 8c4657868..000000000 --- a/src/static/schemas/coupon-card.json +++ /dev/null @@ -1,124 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "allunits_price_amount_discount_summary": { - "type": "string", - "default": "{{adjustment}}¤ each after {{from}}" - }, - "allunits_price_percentage_discount_summary": { - "type": "string", - "default": "{{adjustment, percent}} after {{from}}" - }, - "allunits_quantity_amount_discount_summary": { - "type": "string", - "default": "{{adjustment}}¤ each on orders of {{from}}+" - }, - "allunits_quantity_percentage_discount_summary": { - "type": "string", - "default": "{{adjustment, percent}} on orders of {{from}}+" - }, - "date_range_any": { "type": "string", "default": "Ongoing" }, - "date_range_complete": { "type": "string", "default": "{{start, date}} – {{end, date}}" }, - "date_range_from": { "type": "string", "default": "From {{start, date}}" }, - "date_range_until": { "type": "string", "default": "Until {{end, date}}" }, - "discount_summary": { "type": "string", "default": "{{params, discount}}" }, - "incremental_price_amount_discount_summary": { - "type": "string", - "default": "{{adjustment}}¤ each on orders of {{from}}+" - }, - "incremental_price_percentage_discount_summary": { - "type": "string", - "default": "{{adjustment, percent}} on orders of {{from}}+" - }, - "incremental_quantity_amount_discount_summary": { - "type": "string", - "default": "{{adjustment}}¤ each on items {{from}}+" - }, - "incremental_quantity_percentage_discount_summary": { - "type": "string", - "default": "{{adjustment, percent}} on items {{from}}+" - }, - "ordinal_few": { "type": "string", "default": "rd" }, - "ordinal_many": { "type": "string", "default": "th" }, - "ordinal_one": { "type": "string", "default": "st" }, - "ordinal_other": { "type": "string", "default": "th" }, - "ordinal_two": { "type": "string", "default": "nd" }, - "ordinal_zero": { "type": "string", "default": "th" }, - "repeat_price_amount_discount_summary": { - "type": "string", - "default": "for each {{from}}, {{adjustment}}¤ on the next item" - }, - "repeat_price_percentage_discount_summary": { - "type": "string", - "default": "for each {{from}}, {{adjustment, percent}} on the next item" - }, - "repeat_quantity_amount_discount_summary": { - "type": "string", - "default": "{{adjustment}}¤ on each {{from, ordinal}} item" - }, - "repeat_quantity_percentage_discount_summary": { - "type": "string", - "default": "{{adjustment, percent}} on each {{from, ordinal}} item" - }, - "single_price_amount_discount_summary": { - "type": "string", - "default": "{{adjustment}}¤ after {{from}}" - }, - "single_price_percentage_discount_summary": { - "type": "string", - "default": "{{adjustment, percent}} after {{from}}" - }, - "single_quantity_amount_discount_summary": { - "type": "string", - "default": "{{adjustment}}¤ after {{from}} item(s)" - }, - "single_quantity_percentage_discount_summary": { - "type": "string", - "default": "{{adjustment, percent}} after {{from}} item(s)" - }, - "uses_count": { "type": "string", "default": "{{count}} uses" }, - "uses_to_total_count": { "type": "string", "default": "{{count}}/{{total}} uses" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "allunits_price_amount_discount_summary", - "allunits_price_percentage_discount_summary", - "allunits_quantity_amount_discount_summary", - "allunits_quantity_percentage_discount_summary", - "date_range_any", - "date_range_complete", - "date_range_from", - "date_range_until", - "discount_summary", - "incremental_price_amount_discount_summary", - "incremental_price_percentage_discount_summary", - "incremental_quantity_amount_discount_summary", - "incremental_quantity_percentage_discount_summary", - "ordinal_few", - "ordinal_many", - "ordinal_one", - "ordinal_other", - "ordinal_two", - "ordinal_zero", - "repeat_price_amount_discount_summary", - "repeat_price_percentage_discount_summary", - "repeat_quantity_amount_discount_summary", - "repeat_quantity_percentage_discount_summary", - "single_price_amount_discount_summary", - "single_price_percentage_discount_summary", - "single_quantity_amount_discount_summary", - "single_quantity_percentage_discount_summary", - "uses_count", - "uses_to_total_count", - "spinner" - ] -} diff --git a/src/static/schemas/coupon-code-card.json b/src/static/schemas/coupon-code-card.json deleted file mode 100644 index 5f852d7ac..000000000 --- a/src/static/schemas/coupon-code-card.json +++ /dev/null @@ -1,23 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "line_1": { "type": "string", "default": "{{ code }}" }, - "line_2": { - "type": "string", - "default": "Added on {{ date_created, date }} at {{ date_created, time }}" - }, - "uses_count": { "type": "string", "default": "Used {{ count }} time" }, - "uses_count_plural": { "type": "string", "default": "Used {{ count }} times" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["line_1", "line_2", "uses_count", "uses_count_plural", "spinner"] -} diff --git a/src/static/schemas/coupon-code-form.json b/src/static/schemas/coupon-code-form.json deleted file mode 100644 index 08748cb71..000000000 --- a/src/static/schemas/coupon-code-form.json +++ /dev/null @@ -1,197 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "code": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Code" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "The string value of this coupon code which your customer will add to their cart to use this coupon." - }, - "v8n_required": { "type": "string", "default": "Please enter a coupon code" }, - "v8n_too_long": { - "type": "string", - "default": "Coupon code must be 50 characters or less" - }, - "v8n_has_spaces": { - "type": "string", - "default": "Please remove spaces from the coupon code" - } - }, - "required": [ - "label", - "placeholder", - "helper_text", - "v8n_required", - "v8n_too_long", - "v8n_has_spaces" - ] - }, - "number-of-uses-to-date": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Number of uses" }, - "helper_text": { - "type": "string", - "default": "For informational purposes, this shows you how many times this coupon code has already been used." - } - }, - "required": ["label", "helper_text"] - }, - "transactions": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Transactions" }, - "pagination": { - "additionalProperties": false, - "properties": { - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { "type": "string", "default": "{{from}}-{{to}} out of {{total}}" }, - "previous": { "type": "string", "default": "Previous" }, - "card": { - "additionalProperties": false, - "properties": { - "code": { "type": "string", "default": "Code" }, - "customer": { "type": "string", "default": "Customer" }, - "description": { "type": "string", "default": "Description" }, - "price": { "type": "string", "default": "{{amount, price}}" }, - "time": { "type": "string", "default": "{{value, date}}" }, - "status_capturing": { "type": "string", "default": "Capturing" }, - "status_captured": { "type": "string", "default": "Captured" }, - "status_approved": { "type": "string", "default": "Approved" }, - "status_authorized": { "type": "string", "default": "Authorized" }, - "status_pending": { "type": "string", "default": "Pending" }, - "status_completed": { "type": "string", "default": "Completed" }, - "status_problem": { "type": "string", "default": "Problem" }, - "status_pending_fraud_review": { - "type": "string", - "default": "Pending_fraud_review" - }, - "status_rejected": { "type": "string", "default": "Rejected" }, - "status_declined": { "type": "string", "default": "Declined" }, - "status_refunding": { "type": "string", "default": "Refunding" }, - "status_refunded": { "type": "string", "default": "Refunded" }, - "status_voided": { "type": "string", "default": "Voided" }, - "status_verified": { "type": "string", "default": "Verified" }, - "summary": { "type": "string", "default": "{{most_expensive_item.name}}" }, - "summary_plural": { - "type": "string", - "default": "{{most_expensive_item.name}} and {{count_minus_one}} more" - }, - "summary_payment_method_change": { - "type": "string", - "default": "Payment method change" - }, - "summary_subscription_modification": { - "type": "string", - "default": "Subscription modification" - }, - "summary_subscription_cancellation": { - "type": "string", - "default": "Subscription cancellation" - }, - "source_MIT": { - "type": "string", - "default": "This transaction was initiated by the merchant" - }, - "source_CIT": { - "type": "string", - "default": "This transaction was initiated by the customer" - }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No transactions" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "code", - "customer", - "description", - "price", - "time", - "status_capturing", - "status_captured", - "status_approved", - "status_authorized", - "status_pending", - "status_completed", - "status_problem", - "status_pending_fraud_review", - "status_rejected", - "status_declined", - "status_refunding", - "status_refunded", - "status_voided", - "status_verified", - "summary", - "summary_plural", - "summary_payment_method_change", - "summary_subscription_modification", - "summary_subscription_cancellation", - "source_MIT", - "source_CIT", - "spinner" - ] - } - }, - "required": ["first", "last", "next", "pagination", "previous", "card"] - } - }, - "required": ["label", "pagination"] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "date": { "type": "string", "default": "{{value, date}}" } - }, - "required": ["date_created", "date_modified", "date"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove this coupon code? You won't be able to bring it back." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "code", - "number-of-uses-to-date", - "transactions", - "timestamps", - "delete", - "create", - "spinner" - ] -} diff --git a/src/static/schemas/coupon-codes-form.json b/src/static/schemas/coupon-codes-form.json deleted file mode 100644 index f3766e9de..000000000 --- a/src/static/schemas/coupon-codes-form.json +++ /dev/null @@ -1,44 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "status": { - "additionalProperties": false, - "properties": { - "success": { - "type": "string", - "default": "All done! We've imported your codes into the system." - } - }, - "required": ["success"] - }, - "coupon-codes": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Codes" }, - "placeholder": { "type": "string", "default": "Enter or paste codes here..." }, - "helper_text": { - "type": "string", - "default": "Paste multiple space-separated codes in the field above to add all of them at once. Importing duplicate codes clears their usage stats." - }, - "v8n_required": { "type": "string", "default": "Please add at least one code" } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Import" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": ["status", "coupon-codes", "create", "spinner"] -} diff --git a/src/static/schemas/coupon-form.json b/src/static/schemas/coupon-form.json deleted file mode 100644 index 2446b3b50..000000000 --- a/src/static/schemas/coupon-form.json +++ /dev/null @@ -1,1447 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "header": { - "additionalProperties": false, - "properties": { - "title_existing": { "type": "string", "default": "ID {{ id }}" }, - "title_new": { "type": "string", "default": "New coupon" }, - "subtitle": { - "type": "string", - "default": "Used {{ number_of_uses_to_date }} times (see individual codes for more info)" - } - }, - "required": ["title_existing", "title_new", "subtitle"] - }, - "import": { - "additionalProperties": false, - "properties": { - "button_text": { "type": "string", "default": "Import codes" }, - "dialog": { - "additionalProperties": false, - "properties": { - "close": { "type": "string", "default": "Close" }, - "cancel": { "type": "string", "default": "Cancel" }, - "header": { "type": "string", "default": "Import codes" }, - "save": { "type": "string", "default": "Import" }, - "undo_header": { "type": "string", "default": "Unsaved changes" }, - "undo_message": { - "type": "string", - "default": "Looks like you didn't save your changes! What would you like to do with them?" - }, - "undo_cancel": { "type": "string", "default": "Review" }, - "undo_confirm": { "type": "string", "default": "Discard" }, - "coupon-codes-form": { - "additionalProperties": false, - "properties": { - "status": { - "additionalProperties": false, - "properties": { - "success": { - "type": "string", - "default": "All done! We've imported your codes into the system." - } - }, - "required": ["success"] - }, - "coupon-codes": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Codes" }, - "placeholder": { "type": "string", "default": "Enter or paste codes here..." }, - "helper_text": { - "type": "string", - "default": "Paste multiple space-separated codes in the field above to add all of them at once. Importing duplicate codes clears their usage stats." - }, - "v8n_required": { "type": "string", "default": "Please add at least one code" } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Import" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": ["status", "coupon-codes", "create", "spinner"] - } - }, - "required": [ - "close", - "cancel", - "header", - "save", - "undo_header", - "undo_message", - "undo_cancel", - "undo_confirm", - "coupon-codes-form" - ] - } - }, - "required": ["button_text", "dialog"] - }, - "generate": { - "additionalProperties": false, - "properties": { - "button_text": { "type": "string", "default": "Generate codes" }, - "dialog": { - "additionalProperties": false, - "properties": { - "close": { "type": "string", "default": "Close" }, - "cancel": { "type": "string", "default": "Cancel" }, - "header": { "type": "string", "default": "Generate codes" }, - "save": { "type": "string", "default": "Generate" }, - "undo_header": { "type": "string", "default": "Unsaved changes" }, - "undo_message": { - "type": "string", - "default": "Looks like you didn't save your changes! What would you like to do with them?" - }, - "undo_cancel": { "type": "string", "default": "Review" }, - "undo_confirm": { "type": "string", "default": "Discard" }, - "generate-codes-form": { - "additionalProperties": false, - "properties": { - "status": { - "additionalProperties": false, - "properties": { - "success": { "type": "string", "default": "Codes generated successfully." } - }, - "required": ["success"] - }, - "error": { - "additionalProperties": false, - "properties": { - "invalid_form": { - "type": "string", - "default": "These parameters won't generate any codes. Please make sure that the length of the code is greater than the length of the prefix, does not exceed 50 characters in total and that the code itself does not contain spaces." - } - }, - "required": ["invalid_form"] - }, - "length": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Code length" }, - "placeholder": { "type": "string", "default": "6" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "number-of-codes": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Number of codes" }, - "placeholder": { "type": "string", "default": "10" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "prefix": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Prefix" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { - "type": "string", - "default": "The length value is inclusive of this prefix." - } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "current-balance": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Initial balance" }, - "placeholder": { "type": "string", "default": "0" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "example": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Examples" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { - "type": "string", - "default": "This is what the generated codes will look like." - } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Generate" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "status", - "error", - "length", - "number-of-codes", - "prefix", - "current-balance", - "example", - "create", - "spinner" - ] - } - }, - "required": [ - "close", - "cancel", - "header", - "save", - "undo_header", - "undo_message", - "undo_cancel", - "undo_confirm", - "generate-codes-form" - ] - } - }, - "required": ["button_text", "dialog"] - }, - "ordinal_few": { "type": "string", "default": "rd" }, - "ordinal_many": { "type": "string", "default": "th" }, - "ordinal_one": { "type": "string", "default": "st" }, - "ordinal_other": { "type": "string", "default": "th" }, - "ordinal_two": { "type": "string", "default": "nd" }, - "ordinal_zero": { "type": "string", "default": "th" }, - "name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Name" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { "type": "string", "default": "Coupon name is visible to the customers." }, - "v8n_required": { "type": "string", "default": "Please enter a name for this coupon." }, - "v8n_too_long": { - "type": "string", - "default": "Please shorten the name to 50 characters or less." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_too_long"] - }, - "rules": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Rules" }, - "helper_text": { - "type": "string", - "default": "Add rules to define how this coupon will affect order total. You can get started by selecting one of the examples from the dropdown on top right." - }, - "v8n_required": { - "type": "string", - "default": "Please add at least one discount rule in this section." - }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we are unable to store that many discount rules at the moment. Please reduce the number of rules in this section until this message disappears." - }, - "discount-builder": { - "additionalProperties": false, - "properties": { - "tier": { "type": "string", "default": "Tier" }, - "tier_by": { "type": "string", "default": "by" }, - "tier_if": { "type": "string", "default": "if" }, - "tier_allunits": { "type": "string", "default": "price of each item" }, - "tier_incremental": { "type": "string", "default": "price of additional items" }, - "tier_repeat": { "type": "string", "default": "price of next item" }, - "tier_single": { "type": "string", "default": "order total" }, - "tier_then": { "type": "string", "default": "then" }, - "quantity": { "type": "string", "default": "quantity" }, - "total": { "type": "string", "default": "total" }, - "reduce": { "type": "string", "default": "reduce" }, - "increase": { "type": "string", "default": "increase" } - }, - "required": [ - "tier", - "tier_by", - "tier_if", - "tier_allunits", - "tier_incremental", - "tier_repeat", - "tier_single", - "tier_then", - "quantity", - "total", - "reduce", - "increase" - ] - }, - "allunits_price_amount_discount_summary": { - "type": "string", - "default": "{{adjustment}}¤ each after {{from}}" - }, - "allunits_price_percentage_discount_summary": { - "type": "string", - "default": "{{adjustment, percent}} after {{from}}" - }, - "allunits_quantity_amount_discount_summary": { - "type": "string", - "default": "{{adjustment}}¤ each on orders of {{from}}+" - }, - "allunits_quantity_percentage_discount_summary": { - "type": "string", - "default": "{{adjustment, percent}} on orders of {{from}}+" - }, - "incremental_price_amount_discount_summary": { - "type": "string", - "default": "{{adjustment}}¤ each on orders of {{from}}+" - }, - "incremental_price_percentage_discount_summary": { - "type": "string", - "default": "{{adjustment, percent}} on orders of {{from}}+" - }, - "incremental_quantity_amount_discount_summary": { - "type": "string", - "default": "{{adjustment}}¤ each on items {{from}}+" - }, - "incremental_quantity_percentage_discount_summary": { - "type": "string", - "default": "{{adjustment, percent}} on items {{from}}+" - }, - "repeat_price_amount_discount_summary": { - "type": "string", - "default": "for each {{from}}, {{adjustment}}¤ on the next item" - }, - "repeat_price_percentage_discount_summary": { - "type": "string", - "default": "for each {{from}}, {{adjustment, percent}} on the next item" - }, - "repeat_quantity_amount_discount_summary": { - "type": "string", - "default": "{{adjustment}}¤ on each {{from, ordinal}} item" - }, - "single_price_amount_discount_summary": { - "type": "string", - "default": "{{adjustment}}¤ after {{from}}" - }, - "single_price_percentage_discount_summary": { - "type": "string", - "default": "{{adjustment, percent}} after {{from}}" - }, - "single_quantity_amount_discount_summary": { - "type": "string", - "default": "{{adjustment}}¤ after {{from}} items" - }, - "single_quantity_percentage_discount_summary": { - "type": "string", - "default": "{{adjustment, percent}} after {{from}} items" - }, - "repeat_quantity_percentage_discount_summary": { - "type": "string", - "default": "{{adjustment, percent}} on each {{from, ordinal}} item" - }, - "discount_summary": { - "type": "string", - "default": "Applied discount: {{params, discount}}." - }, - "custom_discount": { "type": "string", "default": "Custom discount" }, - "description": { "type": "string", "default": "Description" }, - "url_parameter": { "type": "string", "default": "URL parameter" } - }, - "required": [ - "label", - "helper_text", - "v8n_required", - "v8n_too_long", - "discount-builder", - "allunits_price_amount_discount_summary", - "allunits_price_percentage_discount_summary", - "allunits_quantity_amount_discount_summary", - "allunits_quantity_percentage_discount_summary", - "incremental_price_amount_discount_summary", - "incremental_price_percentage_discount_summary", - "incremental_quantity_amount_discount_summary", - "incremental_quantity_percentage_discount_summary", - "repeat_price_amount_discount_summary", - "repeat_price_percentage_discount_summary", - "repeat_quantity_amount_discount_summary", - "single_price_amount_discount_summary", - "single_price_percentage_discount_summary", - "single_quantity_amount_discount_summary", - "single_quantity_percentage_discount_summary", - "repeat_quantity_percentage_discount_summary", - "discount_summary", - "custom_discount", - "description", - "url_parameter" - ] - }, - "coupon-codes": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Codes" }, - "delete_header": { "type": "string", "default": "Remove code?" }, - "delete_message": { - "type": "string", - "default": "Please confirm that you'd like to remove this code from the item." - }, - "delete_confirm": { "type": "string", "default": "Remove" }, - "delete_cancel": { "type": "string", "default": "Cancel" }, - "search": { "type": "string", "default": "Search" }, - "clear": { "type": "string", "default": "Clear" }, - "dialog": { - "additionalProperties": false, - "properties": { - "header_create": { "type": "string", "default": "Create code" }, - "header_update": { "type": "string", "default": "Update code" }, - "close": { "type": "string", "default": "Close" }, - "save": { "type": "string", "default": "Save" }, - "cancel": { "type": "string", "default": "Cancel" }, - "undo_header": { "type": "string", "default": "Unsaved changes" }, - "undo_message": { - "type": "string", - "default": "Looks like you didn't save your changes! What would you like to do with them?" - }, - "undo_cancel": { "type": "string", "default": "Review" }, - "undo_confirm": { "type": "string", "default": "Discard" }, - "coupon-code-form": { - "additionalProperties": false, - "properties": { - "code": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Code" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "The string value of this coupon code which your customer will add to their cart to use this coupon." - }, - "v8n_required": { "type": "string", "default": "Please enter a coupon code" }, - "v8n_too_long": { - "type": "string", - "default": "Coupon code must be 50 characters or less" - }, - "v8n_has_spaces": { - "type": "string", - "default": "Please remove spaces from the coupon code" - } - }, - "required": [ - "label", - "placeholder", - "helper_text", - "v8n_required", - "v8n_too_long", - "v8n_has_spaces" - ] - }, - "number-of-uses-to-date": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Number of uses" }, - "helper_text": { - "type": "string", - "default": "For informational purposes, this shows you how many times this coupon code has already been used." - } - }, - "required": ["label", "helper_text"] - }, - "transactions": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Transactions" }, - "pagination": { - "additionalProperties": false, - "properties": { - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { - "type": "string", - "default": "{{from}}-{{to}} out of {{total}}" - }, - "previous": { "type": "string", "default": "Previous" }, - "card": { - "additionalProperties": false, - "properties": { - "code": { "type": "string", "default": "Code" }, - "customer": { "type": "string", "default": "Customer" }, - "description": { "type": "string", "default": "Description" }, - "price": { "type": "string", "default": "{{amount, price}}" }, - "time": { "type": "string", "default": "{{value, date}}" }, - "status_capturing": { "type": "string", "default": "Capturing" }, - "status_captured": { "type": "string", "default": "Captured" }, - "status_approved": { "type": "string", "default": "Approved" }, - "status_authorized": { "type": "string", "default": "Authorized" }, - "status_pending": { "type": "string", "default": "Pending" }, - "status_completed": { "type": "string", "default": "Completed" }, - "status_problem": { "type": "string", "default": "Problem" }, - "status_pending_fraud_review": { - "type": "string", - "default": "Pending_fraud_review" - }, - "status_rejected": { "type": "string", "default": "Rejected" }, - "status_declined": { "type": "string", "default": "Declined" }, - "status_refunding": { "type": "string", "default": "Refunding" }, - "status_refunded": { "type": "string", "default": "Refunded" }, - "status_voided": { "type": "string", "default": "Voided" }, - "status_verified": { "type": "string", "default": "Verified" }, - "summary": { - "type": "string", - "default": "{{most_expensive_item.name}}" - }, - "summary_plural": { - "type": "string", - "default": "{{most_expensive_item.name}} and {{count_minus_one}} more" - }, - "summary_payment_method_change": { - "type": "string", - "default": "Payment method change" - }, - "summary_subscription_modification": { - "type": "string", - "default": "Subscription modification" - }, - "summary_subscription_cancellation": { - "type": "string", - "default": "Subscription cancellation" - }, - "source_MIT": { - "type": "string", - "default": "This transaction was initiated by the merchant" - }, - "source_CIT": { - "type": "string", - "default": "This transaction was initiated by the customer" - }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No transactions" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "code", - "customer", - "description", - "price", - "time", - "status_capturing", - "status_captured", - "status_approved", - "status_authorized", - "status_pending", - "status_completed", - "status_problem", - "status_pending_fraud_review", - "status_rejected", - "status_declined", - "status_refunding", - "status_refunded", - "status_voided", - "status_verified", - "summary", - "summary_plural", - "summary_payment_method_change", - "summary_subscription_modification", - "summary_subscription_cancellation", - "source_MIT", - "source_CIT", - "spinner" - ] - } - }, - "required": ["first", "last", "next", "pagination", "previous", "card"] - } - }, - "required": ["label", "pagination"] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "date": { "type": "string", "default": "{{value, date}}" } - }, - "required": ["date_created", "date_modified", "date"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove this coupon code? You won't be able to bring it back." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "code", - "number-of-uses-to-date", - "transactions", - "timestamps", - "delete", - "create", - "spinner" - ] - } - }, - "required": [ - "header_create", - "header_update", - "close", - "save", - "cancel", - "undo_header", - "undo_message", - "undo_cancel", - "undo_confirm", - "coupon-code-form" - ] - }, - "pagination": { - "additionalProperties": false, - "properties": { - "create_button_text": { "type": "string", "default": "Add code +" }, - "search_button_text": { "type": "string", "default": "Search codes" }, - "card": { - "additionalProperties": false, - "properties": { - "delete_button_text": { "type": "string", "default": "Delete" }, - "copy_button_text": { "type": "string", "default": "Copy code" }, - "line_1": { "type": "string", "default": "{{ code }}" }, - "line_2": { - "type": "string", - "default": "Added on {{ date_created, date }} at {{ date_created, time }}" - }, - "uses_count": { "type": "string", "default": "Used {{ count }} time" }, - "uses_count_plural": { "type": "string", "default": "Used {{ count }} times" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No codes" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "delete_button_text", - "copy_button_text", - "line_1", - "line_2", - "uses_count", - "uses_count_plural", - "spinner" - ] - }, - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { "type": "string", "default": "{{from}}-{{to}} out of {{total}}" }, - "previous": { "type": "string", "default": "Previous" } - }, - "required": [ - "create_button_text", - "search_button_text", - "card", - "first", - "last", - "next", - "pagination", - "previous" - ] - }, - "query-builder": { - "additionalProperties": false, - "properties": { - "add_or_clause": { "type": "string", "default": "Add OR clause" }, - "add_value": { "type": "string", "default": "Add value" }, - "code": { "type": "string", "default": "Code" }, - "date": { "type": "string", "default": "{{value, date}}" }, - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "delete": { "type": "string", "default": "Delete" }, - "field": { "type": "string", "default": "Field" }, - "hidden": { "type": "string", "default": "Hidden" }, - "is_defined_false": { "type": "string", "default": "Not defined" }, - "is_defined_true": { "type": "string", "default": "Defined" }, - "name": { "type": "string", "default": "Name" }, - "operator_equal": { "type": "string", "default": "Equal" }, - "operator_greaterthan": { "type": "string", "default": "Greater than" }, - "operator_greaterthanorequal": { "type": "string", "default": "Greater than or equal" }, - "operator_in": { "type": "string", "default": "One of" }, - "operator_isdefined": { "type": "string", "default": "Is defined" }, - "operator_lessthan": { "type": "string", "default": "Less than" }, - "operator_lessthanorequal": { "type": "string", "default": "Less than or equal" }, - "operator_not": { "type": "string", "default": "Not equal" }, - "or": { "type": "string", "default": "Or" }, - "query_builder_group": { "type": "string", "default": "Group of filters" }, - "query_builder_rule": { "type": "string", "default": "Filter" }, - "range_from": { "type": "string", "default": "From" }, - "range_to": { "type": "string", "default": "To" }, - "type": { "type": "string", "default": "Type" }, - "type_any": { "type": "string", "default": "Field of unknown type" }, - "type_attribute": { "type": "string", "default": "Key-value resource" }, - "type_date": { "type": "string", "default": "Date field" }, - "type_here": { "type": "string", "default": "Type here..." }, - "type_number": { "type": "string", "default": "Numeric field" }, - "type_string": { "type": "string", "default": "Text field" }, - "used_codes": { "type": "string", "default": "Codes used" }, - "value": { "type": "string", "default": "Value" } - }, - "required": [ - "add_or_clause", - "add_value", - "code", - "date", - "date_created", - "date_modified", - "delete", - "field", - "hidden", - "is_defined_false", - "is_defined_true", - "name", - "operator_equal", - "operator_greaterthan", - "operator_greaterthanorequal", - "operator_in", - "operator_isdefined", - "operator_lessthan", - "operator_lessthanorequal", - "operator_not", - "or", - "query_builder_group", - "query_builder_rule", - "range_from", - "range_to", - "type", - "type_any", - "type_attribute", - "type_date", - "type_here", - "type_number", - "type_string", - "used_codes", - "value" - ] - } - }, - "required": [ - "label", - "delete_header", - "delete_message", - "delete_confirm", - "delete_cancel", - "search", - "clear", - "dialog", - "pagination", - "query-builder" - ] - }, - "attributes": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Attributes" }, - "delete_header": { "type": "string", "default": "Remove attribute?" }, - "delete_message": { - "type": "string", - "default": "Please confirm that you'd like to remove this attribute from the item." - }, - "delete_confirm": { "type": "string", "default": "Remove" }, - "delete_cancel": { "type": "string", "default": "Cancel" }, - "dialog": { - "additionalProperties": false, - "properties": { - "header_create": { "type": "string", "default": "Create attribute" }, - "header_update": { "type": "string", "default": "Update attribute" }, - "close": { "type": "string", "default": "Close" }, - "save": { "type": "string", "default": "Save" }, - "cancel": { "type": "string", "default": "Cancel" }, - "undo_header": { "type": "string", "default": "Unsaved changes" }, - "undo_message": { - "type": "string", - "default": "Looks like you didn't save your changes! What would you like to do with them?" - }, - "undo_cancel": { "type": "string", "default": "Review" }, - "undo_confirm": { "type": "string", "default": "Discard" }, - "attribute-form": { - "additionalProperties": false, - "properties": { - "name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Name" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "Name of this attribute. It does not have to be unique." - }, - "v8n_required": { "type": "string", "default": "Please name this attribute." }, - "v8n_too_long": { - "type": "string", - "default": "Please choose a name that is 500 characters long or less." - } - }, - "required": [ - "label", - "placeholder", - "helper_text", - "v8n_required", - "v8n_too_long" - ] - }, - "value": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Value" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "Value of this attribute. Attribute values are automatically HTML-escaped." - }, - "v8n_required": { - "type": "string", - "default": "Please provide a value for this attribute." - }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we can't store values that are more than 1000 characters long." - } - }, - "required": [ - "label", - "placeholder", - "helper_text", - "v8n_required", - "v8n_too_long" - ] - }, - "visibility": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Visibility" }, - "option_public": { "type": "string", "default": "Everyone" }, - "option_restricted": { "type": "string", "default": "Store admins" }, - "option_private": { "type": "string", "default": "Only me" }, - "helper_text": { - "type": "string", - "default": "Controls who can see this attribute. Public attributes can be shown to anyone, including customers. Private attributes are more suitable for configuration or technical details which are irrelevant to the public. Restricted attributes can only be viewed with the OAuth client that created them." - } - }, - "required": [ - "label", - "option_public", - "option_restricted", - "option_private", - "helper_text" - ] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date": { "type": "string", "default": "{{value, date}}" }, - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" } - }, - "required": ["date", "date_created", "date_modified"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove this attribute? You won't be able to bring it back." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "name", - "value", - "visibility", - "timestamps", - "delete", - "create", - "spinner" - ] - } - }, - "required": [ - "header_create", - "header_update", - "close", - "save", - "cancel", - "undo_header", - "undo_message", - "undo_cancel", - "undo_confirm", - "attribute-form" - ] - }, - "pagination": { - "additionalProperties": false, - "properties": { - "create_button_text": { "type": "string", "default": "Add attribute +" }, - "card": { - "additionalProperties": false, - "properties": { - "delete_button_text": { "type": "string", "default": "Delete" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No attributes" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["delete_button_text", "spinner"] - }, - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { "type": "string", "default": "{{from}}-{{to}} out of {{total}}" }, - "previous": { "type": "string", "default": "Previous" } - }, - "required": [ - "create_button_text", - "card", - "first", - "last", - "next", - "pagination", - "previous" - ] - } - }, - "required": [ - "label", - "delete_header", - "delete_message", - "delete_confirm", - "delete_cancel", - "dialog", - "pagination" - ] - }, - "number-of-uses-allowed": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Uses per coupon" }, - "placeholder": { "type": "string", "default": "Unlimited" }, - "helper_text": { - "type": "string", - "default": "The maximum number of times this coupon can be used. Leave blank for unlimited uses." - }, - "v8n_too_small": { - "type": "string", - "default": "Please enter a value greater or equal to 0." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_small"] - }, - "number-of-uses-allowed-per-customer": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Uses per customer" }, - "placeholder": { "type": "string", "default": "Unlimited" }, - "helper_text": { - "type": "string", - "default": "The maximum number of times a single customer can use this coupon. Leave blank for unlimited uses." - }, - "v8n_too_small": { - "type": "string", - "default": "Please enter a value greater or equal to 0." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_small"] - }, - "number-of-uses-allowed-per-code": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Uses per code" }, - "placeholder": { "type": "string", "default": "Unlimited" }, - "helper_text": { - "type": "string", - "default": "The maximum number of times a single code can be used. Leave blank for unlimited uses." - }, - "v8n_too_small": { - "type": "string", - "default": "Please enter a value greater or equal to 0." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_small"] - }, - "product-code-restrictions": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Product code restrictions" }, - "placeholder": { "type": "string", "default": "Enter a product code and hit Enter" }, - "helper_text": { - "type": "string", - "default": "We'll apply this coupon only if one of the rules in the list matches the product code. Wildcards are allowed." - }, - "unit_allow": { "type": "string", "default": "Allow" }, - "unit_block": { "type": "string", "default": "Block" }, - "label_allow": { "type": "string", "default": "Allow {{ value }}" }, - "label_block": { "type": "string", "default": "Block {{ value }}" }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we are unable to store that many product code restrictions at the moment. Please reduce the number of rules in this section until this message disappears." - } - }, - "required": [ - "label", - "placeholder", - "helper_text", - "unit_allow", - "unit_block", - "label_allow", - "label_block", - "v8n_too_long" - ] - }, - "options": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Options" }, - "option_multiple_codes_allowed": { - "type": "string", - "default": "Allow multiple codes on the same order" - }, - "option_combinable": { "type": "string", "default": "Allow combining with other coupons" }, - "option_exclude_category_discounts": { - "type": "string", - "default": "Don't apply category discounts with this coupon" - }, - "option_exclude_line_item_discounts": { - "type": "string", - "default": "Don't apply line item discounts with this coupon" - }, - "option_is_taxable": { "type": "string", "default": "Apply taxes before this coupon" }, - "option_shared_codes_allowed": { - "type": "string", - "default": "Enable code sharing between coupons" - }, - "option_customer_auto_apply": { "type": "string", "default": "Enable auto-apply" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": [ - "label", - "option_multiple_codes_allowed", - "option_combinable", - "option_exclude_category_discounts", - "option_exclude_line_item_discounts", - "option_is_taxable", - "option_shared_codes_allowed", - "option_customer_auto_apply", - "helper_text" - ] - }, - "start-date": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Start date" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { - "type": "string", - "default": "The date and time when this coupon will become active. Leave blank to activate immediately." - } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "end-date": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "End date" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { - "type": "string", - "default": "The date and time when this coupon will expire. Leave blank for no expiration." - } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "customer-subscription-restrictions": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Auto-apply: subscription restrictions" }, - "placeholder": { "type": "string", "default": "Enter a product code and hit Enter" }, - "helper_text": { - "type": "string", - "default": "This coupon will be automatically applied when a subscription includes a product with one of the codes in the list. Wildcards are allowed just like in product code restrictions." - }, - "submit": { "type": "string", "default": "Add this code" }, - "delete": { "type": "string", "default": "Delete this code" }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we are unable to store that many subscription restrictions at the moment. Please reduce the number of rules in this section until this message disappears." - } - }, - "required": ["label", "placeholder", "helper_text", "submit", "delete", "v8n_too_long"] - }, - "customer-attribute-restrictions": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Auto-apply: customer restrictions" }, - "helper_text": { - "type": "string", - "default": "This coupon will be automatically applied when a customer record matches this query." - }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we are unable to store that many customer restrictions at the moment. Please reduce the number of rules in this section until this message disappears." - }, - "query-builder": { - "additionalProperties": false, - "properties": { - "add_or_clause": { "type": "string", "default": "Add OR clause" }, - "add_value": { "type": "string", "default": "Add value" }, - "code": { "type": "string", "default": "Code" }, - "date": { "type": "string", "default": "{{value, date}}" }, - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "delete": { "type": "string", "default": "Delete" }, - "field": { "type": "string", "default": "Field" }, - "hidden": { "type": "string", "default": "Hidden" }, - "is_defined_false": { "type": "string", "default": "Not defined" }, - "is_defined_true": { "type": "string", "default": "Defined" }, - "name": { "type": "string", "default": "Name" }, - "operator_equal": { "type": "string", "default": "Equal" }, - "operator_greaterthan": { "type": "string", "default": "Greater than" }, - "operator_greaterthanorequal": { "type": "string", "default": "Greater than or equal" }, - "operator_in": { "type": "string", "default": "One of" }, - "operator_isdefined": { "type": "string", "default": "Is defined" }, - "operator_lessthan": { "type": "string", "default": "Less than" }, - "operator_lessthanorequal": { "type": "string", "default": "Less than or equal" }, - "operator_not": { "type": "string", "default": "Not equal" }, - "or": { "type": "string", "default": "Or" }, - "query_builder_group": { "type": "string", "default": "Group of filters" }, - "query_builder_rule": { "type": "string", "default": "Filter" }, - "range_from": { "type": "string", "default": "From" }, - "range_to": { "type": "string", "default": "To" }, - "type": { "type": "string", "default": "Type" }, - "type_any": { "type": "string", "default": "Field of unknown type" }, - "type_attribute": { "type": "string", "default": "Key-value resource" }, - "type_date": { "type": "string", "default": "Date field" }, - "type_here": { "type": "string", "default": "Type here..." }, - "type_number": { "type": "string", "default": "Numeric field" }, - "type_string": { "type": "string", "default": "Text field" }, - "used_codes": { "type": "string", "default": "Codes used" }, - "value": { "type": "string", "default": "Value" } - }, - "required": [ - "add_or_clause", - "add_value", - "code", - "date", - "date_created", - "date_modified", - "delete", - "field", - "hidden", - "is_defined_false", - "is_defined_true", - "name", - "operator_equal", - "operator_greaterthan", - "operator_greaterthanorequal", - "operator_in", - "operator_isdefined", - "operator_lessthan", - "operator_lessthanorequal", - "operator_not", - "or", - "query_builder_group", - "query_builder_rule", - "range_from", - "range_to", - "type", - "type_any", - "type_attribute", - "type_date", - "type_here", - "type_number", - "type_string", - "used_codes", - "value" - ] - } - }, - "required": ["label", "helper_text", "v8n_too_long", "query-builder"] - }, - "item-option-restrictions": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Item option restrictions" }, - "helper_text": { - "type": "string", - "default": "This restricts the usage of a coupon code based on an item option's name and value. When defined, the coupon will only apply to items with the specified option name and value. Wildcards are allowed." - }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we are unable to store that many item option restrictions at the moment. Please reduce the number of rules in this section until this message disappears." - }, - "query-builder": { - "additionalProperties": false, - "properties": { - "add_or_clause": { "type": "string", "default": "Add OR clause" }, - "add_value": { "type": "string", "default": "Add option value" }, - "code": { "type": "string", "default": "Code" }, - "date": { "type": "string", "default": "{{value, date}}" }, - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "delete": { "type": "string", "default": "Delete" }, - "field": { "type": "string", "default": "Option name" }, - "hidden": { "type": "string", "default": "Hidden" }, - "is_defined_false": { "type": "string", "default": "Not defined" }, - "is_defined_true": { "type": "string", "default": "Defined" }, - "name": { "type": "string", "default": "Name" }, - "operator_equal": { "type": "string", "default": "Equal" }, - "operator_greaterthan": { "type": "string", "default": "Greater than" }, - "operator_greaterthanorequal": { "type": "string", "default": "Greater than or equal" }, - "operator_in": { "type": "string", "default": "One of" }, - "operator_isdefined": { "type": "string", "default": "Is defined" }, - "operator_lessthan": { "type": "string", "default": "Less than" }, - "operator_lessthanorequal": { "type": "string", "default": "Less than or equal" }, - "operator_not": { "type": "string", "default": "Not equal" }, - "or": { "type": "string", "default": "Or" }, - "query_builder_group": { "type": "string", "default": "Group of filters" }, - "query_builder_rule": { "type": "string", "default": "Filter" }, - "range_from": { "type": "string", "default": "From" }, - "range_to": { "type": "string", "default": "To" }, - "type": { "type": "string", "default": "Type" }, - "type_any": { "type": "string", "default": "Field of unknown type" }, - "type_attribute": { "type": "string", "default": "Key-value resource" }, - "type_date": { "type": "string", "default": "Date field" }, - "type_here": { "type": "string", "default": "Type here..." }, - "type_number": { "type": "string", "default": "Numeric field" }, - "type_string": { "type": "string", "default": "Text field" }, - "used_codes": { "type": "string", "default": "Codes used" }, - "value": { "type": "string", "default": "Option value" } - }, - "required": [ - "add_or_clause", - "add_value", - "code", - "date", - "date_created", - "date_modified", - "delete", - "field", - "hidden", - "is_defined_false", - "is_defined_true", - "name", - "operator_equal", - "operator_greaterthan", - "operator_greaterthanorequal", - "operator_in", - "operator_isdefined", - "operator_lessthan", - "operator_lessthanorequal", - "operator_not", - "or", - "query_builder_group", - "query_builder_rule", - "range_from", - "range_to", - "type", - "type_any", - "type_attribute", - "type_date", - "type_here", - "type_number", - "type_string", - "used_codes", - "value" - ] - } - }, - "required": ["label", "helper_text", "v8n_too_long", "query-builder"] - }, - "category-restrictions": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Item category restrictions" }, - "status_saving": { "type": "string", "default": "Saving..." }, - "status_loading": { "type": "string", "default": "Loading..." }, - "pagination": { - "additionalProperties": false, - "properties": { - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { "type": "string", "default": "{{from}}-{{to}} out of {{total}}" }, - "previous": { "type": "string", "default": "Previous" }, - "card": { - "additionalProperties": false, - "properties": { - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No restrictions" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["spinner"] - } - }, - "required": ["first", "last", "next", "pagination", "previous", "card"] - }, - "helper_text": { - "type": "string", - "default": "Limit which categories this coupon applies to. All changes are saved automatically." - } - }, - "required": ["label", "status_saving", "status_loading", "pagination", "helper_text"] - }, - "inclusive-tax-rate": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Tax rate" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { - "type": "string", - "default": "The tax rate to apply to the coupon in tax-inclusive mode. This is a decimal value from 0 to 1." - }, - "v8n_too_small": { - "type": "string", - "default": "Please enter a value greater or equal to 0." - }, - "v8n_too_big": { - "type": "string", - "default": "Please enter a value less than or equal to 1." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_small", "v8n_too_big"] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "date": { "type": "string", "default": "{{value, date}}" } - }, - "required": ["date_created", "date_modified", "date"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "This action is irreversible. Are you sure you want to delete this coupon?" - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "header", - "import", - "generate", - "ordinal_few", - "ordinal_many", - "ordinal_one", - "ordinal_other", - "ordinal_two", - "ordinal_zero", - "name", - "rules", - "coupon-codes", - "attributes", - "number-of-uses-allowed", - "number-of-uses-allowed-per-customer", - "number-of-uses-allowed-per-code", - "product-code-restrictions", - "options", - "start-date", - "end-date", - "customer-subscription-restrictions", - "customer-attribute-restrictions", - "item-option-restrictions", - "category-restrictions", - "inclusive-tax-rate", - "timestamps", - "delete", - "create", - "spinner" - ] -} diff --git a/src/static/schemas/custom-field-card.json b/src/static/schemas/custom-field-card.json deleted file mode 100644 index 5f175ab78..000000000 --- a/src/static/schemas/custom-field-card.json +++ /dev/null @@ -1,16 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["spinner"] -} diff --git a/src/static/schemas/custom-field-form.json b/src/static/schemas/custom-field-form.json deleted file mode 100644 index 6d80702a9..000000000 --- a/src/static/schemas/custom-field-form.json +++ /dev/null @@ -1,85 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Name" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { "type": "string", "default": "Maximum 100 characters." }, - "v8n_required": { "type": "string", "default": "Please name this custom field." }, - "v8n_too_long": { - "type": "string", - "default": "Please choose a name that is 100 characters long or less." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_too_long"] - }, - "value": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Value" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { "type": "string", "default": "Maximum 700 characters." }, - "v8n_required": { - "type": "string", - "default": "Please provide a value for this custom field." - }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we can't store values that are more than 700 characters long." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_too_long"] - }, - "visibility": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Visibility" }, - "option_hidden": { "type": "string", "default": "Hide in receipts" }, - "helper_text": { - "type": "string", - "default": "Whether or not this custom field is visible on the receipt and email receipt. This correlates to custom fields with a \"h:\" prefix when added to the cart." - } - }, - "required": ["label", "option_hidden", "helper_text"] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date": { "type": "string", "default": "{{value, date}}" }, - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" } - }, - "required": ["date", "date_created", "date_modified"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove this custom field? You won't be able to bring it back." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": ["name", "value", "visibility", "timestamps", "delete", "create", "spinner"] -} diff --git a/src/static/schemas/customer-card.json b/src/static/schemas/customer-card.json deleted file mode 100644 index 5f175ab78..000000000 --- a/src/static/schemas/customer-card.json +++ /dev/null @@ -1,16 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["spinner"] -} diff --git a/src/static/schemas/customer-form.json b/src/static/schemas/customer-form.json deleted file mode 100644 index 275faeccd..000000000 --- a/src/static/schemas/customer-form.json +++ /dev/null @@ -1,271 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "legal-notice": { - "additionalProperties": false, - "properties": { - "text": { - "type": "string", - "default": "By creating an account, you agree to our Terms of Service." - }, - "link": { "type": "string", "default": "Click here to open them in a new tab." } - }, - "required": ["text", "link"] - }, - "status": { - "additionalProperties": false, - "properties": { - "password_change_success": { - "type": "string", - "default": "You have successfully set a new password for {{ email }}." - }, - "close": { "type": "string", "default": "Close" } - }, - "required": ["password_change_success", "close"] - }, - "error": { - "additionalProperties": false, - "properties": { - "old_password_incorrect": { - "type": "string", - "default": "The old password you entered is incorrect. Please try again." - }, - "registration_disabled": { - "type": "string", - "default": "Customer registration is disabled for this store. If you're seeing this message as a customer, please contact the store owner." - }, - "verification_failed": { - "type": "string", - "default": "Client verification failed. If you are seeing this message as a customer, please contact the store owner." - }, - "email_already_used": { - "type": "string", - "default": "This email is already in use. Please use a different email." - } - }, - "required": [ - "old_password_incorrect", - "registration_disabled", - "verification_failed", - "email_already_used" - ] - }, - "first-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "First name" }, - "placeholder": { "type": "string", "default": "Not set" }, - "helper_text": { "type": "string", "default": "Customer's given name, optional." }, - "v8n_too_long": { - "type": "string", - "default": "We can't store first names longer than 50 characters." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "last-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Last name" }, - "placeholder": { "type": "string", "default": "Not set" }, - "helper_text": { "type": "string", "default": "Customer's surname, optional." }, - "v8n_too_long": { - "type": "string", - "default": "We can't store last names longer than 50 characters." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "tax-id": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Tax ID" }, - "placeholder": { "type": "string", "default": "Not set" }, - "helper_text": { - "type": "string", - "default": "Tax identification number for this customer, optional." - }, - "v8n_too_long": { - "type": "string", - "default": "We can't store tax IDs longer than 50 characters." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "email": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Email" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "This email will be used as the login to the Checkout and Customer Portal." - }, - "helper_text_last_login_date": { - "type": "string", - "default": "This customer's login to the Checkout and Customer Portal. Last used on {{ date, date }} at {{ date, time }}." - }, - "v8n_too_long": { - "type": "string", - "default": "We can't store emails longer than 100 characters." - }, - "v8n_invalid_email": { "type": "string", "default": "This email is invalid." }, - "v8n_required": { "type": "string", "default": "Please fill out this field." } - }, - "required": [ - "label", - "placeholder", - "helper_text", - "helper_text_last_login_date", - "v8n_too_long", - "v8n_invalid_email", - "v8n_required" - ] - }, - "is-anonymous": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Account type" }, - "helper_text": { - "type": "string", - "default": "Guest customers dont't have access to Customer Portal. Once the account type is set, it can not be changed." - }, - "option_true": { "type": "string", "default": "Guest" }, - "option_false": { "type": "string", "default": "Registered" } - }, - "required": ["label", "helper_text", "option_true", "option_false"] - }, - "password": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Password" }, - "placeholder": { "type": "string", "default": "Required" }, - "placeholder_new": { "type": "string", "default": "Keep current password" }, - "helper_text": { - "type": "string", - "default": "Set a password for this customer. To generate a secure random password for this account, use the ✨ button." - }, - "helper_text_new": { - "type": "string", - "default": "To change this customer's password, enter a new password here. If you leave it blank, their password will remain the same." - }, - "v8n_too_long": { - "type": "string", - "default": "Please use a password that is no longer than 50 characters." - }, - "v8n_too_weak": { - "type": "string", - "default": "Please use a stronger password. To make this password stronger, make it at least 8 characters long and include a few upper and lower case letters, numbers, and special characters." - }, - "v8n_required": { "type": "string", "default": "Please fill out this field." } - }, - "required": [ - "label", - "placeholder", - "placeholder_new", - "helper_text", - "helper_text_new", - "v8n_too_long", - "v8n_too_weak", - "v8n_required" - ] - }, - "password-old": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Old password" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { - "type": "string", - "default": "Enter the old password to set a new password. If you're a store admin, you can leave this field blank." - }, - "v8n_required": { "type": "string", "default": "Please fill out this field." } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "forgot-password": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "One-time code" }, - "placeholder": { "type": "string", "default": "Not set" }, - "helper_text": { - "type": "string", - "default": "Set a one-time code that this customer can use instead of a password to sign in. Keep in mind that this code will expire after 30 minutes." - }, - "helper_text_expired_on": { - "type": "string", - "default": "A one-time code that this customer can use instead of a password to sign in. This code expired on {{ expiresOn, date }} at {{ expiresOn, time }}." - }, - "helper_text_expires_in": { - "type": "string", - "default": "A one-time code that this customer can use instead of a password to sign in. This code will expire in {{ expiresInMin, relative }}." - }, - "v8n_too_long": { - "type": "string", - "default": "Please use a code that is no longer than 50 characters." - } - }, - "required": [ - "label", - "placeholder", - "helper_text", - "helper_text_expired_on", - "helper_text_expires_in", - "v8n_too_long" - ] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "date": { "type": "string", "default": "{{value, date}}" } - }, - "required": ["date_created", "date_modified", "date"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "This action is irreversible. Are you sure you want to delete this customer?" - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "legal-notice", - "status", - "error", - "first-name", - "last-name", - "tax-id", - "email", - "is-anonymous", - "password", - "password-old", - "forgot-password", - "timestamps", - "delete", - "create", - "spinner" - ] -} diff --git a/src/static/schemas/customer-portal-settings-form.json b/src/static/schemas/customer-portal-settings-form.json deleted file mode 100644 index 2a63b1585..000000000 --- a/src/static/schemas/customer-portal-settings-form.json +++ /dev/null @@ -1,777 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "session-lifespan-in-minutes": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Session lifespan" }, - "option_minute": { "type": "string", "default": "Minute" }, - "option_minute_plural": { "type": "string", "default": "Minutes" }, - "option_hour": { "type": "string", "default": "Hour" }, - "option_hour_plural": { "type": "string", "default": "Hours" }, - "option_day": { "type": "string", "default": "Day" }, - "option_day_plural": { "type": "string", "default": "Days" }, - "option_week": { "type": "string", "default": "Week" }, - "option_week_plural": { "type": "string", "default": "Weeks" }, - "helper_text": { - "type": "string", - "default": "The maximum time a customer can be logged in without activity." - }, - "v8n_too_long": { - "type": "string", - "default": "We limit session lifespan to 4 weeks for security reasons. Please select a smaller value." - } - }, - "required": [ - "label", - "option_minute", - "option_minute_plural", - "option_hour", - "option_hour_plural", - "option_day", - "option_day_plural", - "option_week", - "option_week_plural", - "helper_text", - "v8n_too_long" - ] - }, - "allowed-origins": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Allowed origins" }, - "helper_text": { - "type": "string", - "default": "The list of origins that are allowed to access the Customer Portal API. Must be https unless it's localhost. You can add up to 10 origins in this section." - }, - "placeholder": { "type": "string", "default": "Enter an origin and press Enter" }, - "v8n_invalid": { - "type": "string", - "default": "Some of the origins you've entered are invalid. Please check the items marked with ⚠️ and correct them." - }, - "v8n_too_many": { - "type": "string", - "default": "We support up to 10 origins. Please remove some of them." - } - }, - "required": ["label", "helper_text", "placeholder", "v8n_invalid", "v8n_too_many"] - }, - "jwt-shared-secret": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "JWT shared secret" }, - "placeholder": { "type": "string", "default": "Leave empty to generate automatically" }, - "helper_text": { - "type": "string", - "default": "We use this key to sign customer JWTs. Changing it will drop all active sessions." - }, - "v8n_invalid": { - "type": "string", - "default": "Only letters (a-z), numbers (0-9) and dashes (-) are allowed in this field." - }, - "v8n_too_short": { - "type": "string", - "default": "This value must be at least 40 characters long." - }, - "v8n_too_long": { "type": "string", "default": "This value can't exceed 100 characters." } - }, - "required": [ - "label", - "placeholder", - "helper_text", - "v8n_invalid", - "v8n_too_short", - "v8n_too_long" - ] - }, - "features": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Features" }, - "option_sso": { "type": "string", "default": "SSO (single sign-on)" }, - "option_sign_up": { "type": "string", "default": "Customer registration" }, - "option_frequency_modification": { - "type": "string", - "default": "Frequency changes for subscriptions" - }, - "option_next_date_modification": { - "type": "string", - "default": "Next payment date changes for subscriptions" - }, - "helper_text": { "type": "string", "default": "" } - }, - "required": [ - "label", - "option_sso", - "option_sign_up", - "option_frequency_modification", - "option_next_date_modification", - "helper_text" - ] - }, - "sign-up-verification-hcaptcha-site-key": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "hCaptcha site key" }, - "placeholder": { "type": "string", "default": "Provided by Foxy" }, - "helper_text": { - "type": "string", - "default": "By default, we use our own hCaptcha site key for all portal installs. If you have a hCaptcha account and would like to use your own key, enter it here." - }, - "v8n_too_long": { "type": "string", "default": "This value can't exceed 100 characters." } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "sign-up-verification-hcaptcha-secret-key": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "hCaptcha secret key" }, - "placeholder": { "type": "string", "default": "Provided by Foxy" }, - "helper_text": { - "type": "string", - "default": "By default, we use our own hCaptcha secret key for all portal installs. If you have a hCaptcha account and would like to use your own key, enter it here." - }, - "v8n_too_long": { "type": "string", "default": "This value can't exceed 100 characters." } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "subscriptions-allow-frequency-modification": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Frequency options" }, - "helper_text": { - "type": "string", - "default": "Customize how your customers can change the payment schedule of their subscriptions. You can add up to 10 rules in this section." - }, - "delete_header": { "type": "string", "default": "Remove this rule?" }, - "delete_message": { - "type": "string", - "default": "Please confirm that you'd like to remove this rule." - }, - "delete_confirm": { "type": "string", "default": "Remove" }, - "delete_cancel": { "type": "string", "default": "Cancel" }, - "dialog": { - "additionalProperties": false, - "properties": { - "header_create": { "type": "string", "default": "Add rule" }, - "header_update": { "type": "string", "default": "Edit rule" }, - "close": { "type": "string", "default": "Close" }, - "save": { "type": "string", "default": "Save" }, - "cancel": { "type": "string", "default": "Cancel" }, - "undo_header": { "type": "string", "default": "Unsaved changes" }, - "undo_message": { - "type": "string", - "default": "Looks like you didn't save your changes! What would you like to do with them?" - }, - "undo_cancel": { "type": "string", "default": "Review" }, - "undo_confirm": { "type": "string", "default": "Discard" }, - "jsonata-query": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "JSONata query" }, - "placeholder": { - "type": "string", - "default": "Enter * to match all subscriptions" - }, - "helper_text": { - "type": "string", - "default": "This rule will apply only to subscriptions that match this query. We will run this query against the standard fx:subscription object." - }, - "v8n_required": { - "type": "string", - "default": "Please enter a JSONata expression. You can use * to match all subscriptions." - }, - "v8n_too_long": { - "type": "string", - "default": "Please limit your query to 200 characters." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_too_long"] - }, - "values": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Values" }, - "unit_years": { "type": "string", "default": "Years" }, - "unit_months": { "type": "string", "default": "Months" }, - "unit_weeks": { "type": "string", "default": "Weeks" }, - "unit_days": { "type": "string", "default": "Days" }, - "twice_a_week": { "type": "string", "default": "Twice a week" }, - "yearly": { "type": "string", "default": "Yearly" }, - "yearly_plural": { "type": "string", "default": "Every {{ count }} years" }, - "weekly": { "type": "string", "default": "Weekly" }, - "weekly_plural": { "type": "string", "default": "Every {{ count }} weeks" }, - "monthly": { "type": "string", "default": "Monthly" }, - "monthly_plural": { "type": "string", "default": "Every {{ count }} months" }, - "daily": { "type": "string", "default": "Daily" }, - "daily_plural": { "type": "string", "default": "Every {{ count }} days" }, - "placeholder": { "type": "string", "default": "Enter a number" }, - "helper_text": { - "type": "string", - "default": "The frequency options that will be available to the customer. You can add up to 20 options." - }, - "v8n_required": { "type": "string", "default": "Please enter at least one value." }, - "v8n_too_long": { - "type": "string", - "default": "Only up to 20 values are allowed. Please remove some of them to proceed." - } - }, - "required": [ - "label", - "unit_years", - "unit_months", - "unit_weeks", - "unit_days", - "twice_a_week", - "yearly", - "yearly_plural", - "weekly", - "weekly_plural", - "monthly", - "monthly_plural", - "daily", - "daily_plural", - "placeholder", - "helper_text", - "v8n_required", - "v8n_too_long" - ] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Please confirm that you'd like to remove this rule." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "header_create", - "header_update", - "close", - "save", - "cancel", - "undo_header", - "undo_message", - "undo_cancel", - "undo_confirm", - "jsonata-query", - "values", - "delete", - "create", - "spinner" - ] - }, - "pagination": { - "additionalProperties": false, - "properties": { - "create_button_text": { "type": "string", "default": "Add rule +" }, - "card": { - "additionalProperties": false, - "properties": { - "delete_button_text": { "type": "string", "default": "Delete" }, - "title_all": { "type": "string", "default": "All subscriptions" }, - "title_matching": { "type": "string", "default": "Matching {{ query }}" }, - "subtitle_empty": { "type": "string", "default": "No options" }, - "subtitle_list": { "type": "string", "default": "{{ list }}" }, - "twice_a_week": { "type": "string", "default": "Twice a week" }, - "yearly": { "type": "string", "default": "Yearly" }, - "yearly_plural": { "type": "string", "default": "Every {{ count }} years" }, - "weekly": { "type": "string", "default": "Weekly" }, - "weekly_plural": { "type": "string", "default": "Every {{ count }} weeks" }, - "monthly": { "type": "string", "default": "Monthly" }, - "monthly_plural": { "type": "string", "default": "Every {{ count }} months" }, - "daily": { "type": "string", "default": "Daily" }, - "daily_plural": { "type": "string", "default": "Every {{ count }} days" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No rules" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "delete_button_text", - "title_all", - "title_matching", - "subtitle_empty", - "subtitle_list", - "twice_a_week", - "yearly", - "yearly_plural", - "weekly", - "weekly_plural", - "monthly", - "monthly_plural", - "daily", - "daily_plural", - "spinner" - ] - }, - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { "type": "string", "default": "{{from}}-{{to}} out of {{total}}" }, - "previous": { "type": "string", "default": "Previous" } - }, - "required": [ - "create_button_text", - "card", - "first", - "last", - "next", - "pagination", - "previous" - ] - } - }, - "required": [ - "label", - "helper_text", - "delete_header", - "delete_message", - "delete_confirm", - "delete_cancel", - "dialog", - "pagination" - ] - }, - "subscriptions-allow-next-date-modification": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Next payment date options" }, - "helper_text": { - "type": "string", - "default": "Customize how your customers can change the next payment date of their subscriptions. You can add up to 10 rules in this section." - }, - "delete_header": { "type": "string", "default": "Remove this rule?" }, - "delete_message": { - "type": "string", - "default": "Please confirm that you'd like to remove this rule." - }, - "delete_confirm": { "type": "string", "default": "Remove" }, - "delete_cancel": { "type": "string", "default": "Cancel" }, - "dialog": { - "additionalProperties": false, - "properties": { - "header_create": { "type": "string", "default": "Add rule" }, - "header_update": { "type": "string", "default": "Edit rule" }, - "close": { "type": "string", "default": "Close" }, - "save": { "type": "string", "default": "Save" }, - "cancel": { "type": "string", "default": "Cancel" }, - "undo_header": { "type": "string", "default": "Unsaved changes" }, - "undo_message": { - "type": "string", - "default": "Looks like you didn't save your changes! What would you like to do with them?" - }, - "undo_cancel": { "type": "string", "default": "Review" }, - "undo_confirm": { "type": "string", "default": "Discard" }, - "jsonata-query": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "JSONata query" }, - "placeholder": { - "type": "string", - "default": "Enter * to match all subscriptions" - }, - "helper_text": { - "type": "string", - "default": "This rule will apply only to subscriptions that match this query. We will run this query against the standard fx:subscription object." - }, - "v8n_required": { - "type": "string", - "default": "Please enter a JSONata expression. You can use * to match all subscriptions." - }, - "v8n_too_long": { - "type": "string", - "default": "Please limit your query to 200 characters." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_too_long"] - }, - "minmax-restrictions": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Range restrictions" }, - "option_min": { "type": "string", "default": "Minimum" }, - "option_max": { "type": "string", "default": "Maximum" }, - "helper_text": { - "type": "string", - "default": "Prevent customers from setting the next payment date too close to the current date or too far in the future. You will be able to customize the exact values below." - } - }, - "required": ["label", "option_min", "option_max", "helper_text"] - }, - "min": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Minimum" }, - "day": { "type": "string", "default": "Day" }, - "day_plural": { "type": "string", "default": "Days" }, - "week": { "type": "string", "default": "Week" }, - "week_plural": { "type": "string", "default": "Weeks" }, - "month": { "type": "string", "default": "Month" }, - "month_plural": { "type": "string", "default": "Months" }, - "year": { "type": "string", "default": "Year" }, - "year_plural": { "type": "string", "default": "Years" }, - "helper_text": { - "type": "string", - "default": "Select the period during which the next payment date can't be set." - } - }, - "required": [ - "label", - "day", - "day_plural", - "week", - "week_plural", - "month", - "month_plural", - "year", - "year_plural", - "helper_text" - ] - }, - "max": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Maximum" }, - "day": { "type": "string", "default": "Day" }, - "day_plural": { "type": "string", "default": "Days" }, - "week": { "type": "string", "default": "Week" }, - "week_plural": { "type": "string", "default": "Weeks" }, - "month": { "type": "string", "default": "Month" }, - "month_plural": { "type": "string", "default": "Months" }, - "year": { "type": "string", "default": "Year" }, - "year_plural": { "type": "string", "default": "Years" }, - "helper_text": { - "type": "string", - "default": "Select the period after which the next payment date can't be set." - } - }, - "required": [ - "label", - "day", - "day_plural", - "week", - "week_plural", - "month", - "month_plural", - "year", - "year_plural", - "helper_text" - ] - }, - "day-and-date-restrictions": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Day and date restrictions" }, - "option_none": { "type": "string", "default": "None" }, - "option_days": { "type": "string", "default": "Days of week" }, - "option_dates": { "type": "string", "default": "Dates of month" }, - "helper_text": { - "type": "string", - "default": "Opt to restrict the next payment date to a specific day of the week or date of the month. You will be able to customize the exact values below." - } - }, - "required": ["label", "option_none", "option_days", "option_dates", "helper_text"] - }, - "days-of-week": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Allowed days of week" }, - "option_1": { "type": "string", "default": "Monday" }, - "option_2": { "type": "string", "default": "Tuesday" }, - "option_3": { "type": "string", "default": "Wednesday" }, - "option_4": { "type": "string", "default": "Thursday" }, - "option_5": { "type": "string", "default": "Friday" }, - "option_6": { "type": "string", "default": "Saturday" }, - "option_7": { "type": "string", "default": "Sunday" }, - "helper_text": { - "type": "string", - "default": "Select all days of week that the next payment date can be set to." - } - }, - "required": [ - "label", - "option_1", - "option_2", - "option_3", - "option_4", - "option_5", - "option_6", - "option_7", - "helper_text" - ] - }, - "dates-of-month": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Allowed dates of month" }, - "placeholder": { - "type": "string", - "default": "Enter a date (e.g. 14) and press Enter" - }, - "helper_text": { - "type": "string", - "default": "Add all dates of month that the next payment date can be set to." - } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "disallowed-dates": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Disallowed dates" }, - "range_from": { "type": "string", "default": "From" }, - "range_to": { "type": "string", "default": "To" }, - "range": { "type": "string", "default": "{{ from, date }} – {{ to, date }}" }, - "single": { "type": "string", "default": "{{ value, date }}" }, - "placeholder": { "type": "string", "default": "Enter a date" }, - "helper_text": { - "type": "string", - "default": "Prevent customers from setting the next payment date to specific dates or date ranges. You can add up to 10 items in this section." - }, - "v8n_too_long": { - "type": "string", - "default": "Only up to 10 values are allowed. Please remove some of them to proceed." - } - }, - "required": [ - "label", - "range_from", - "range_to", - "range", - "single", - "placeholder", - "helper_text", - "v8n_too_long" - ] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Please confirm that you'd like to remove this rule." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "header_create", - "header_update", - "close", - "save", - "cancel", - "undo_header", - "undo_message", - "undo_cancel", - "undo_confirm", - "jsonata-query", - "minmax-restrictions", - "min", - "max", - "day-and-date-restrictions", - "days-of-week", - "dates-of-month", - "disallowed-dates", - "delete", - "create", - "spinner" - ] - }, - "pagination": { - "additionalProperties": false, - "properties": { - "create_button_text": { "type": "string", "default": "Add rule +" }, - "card": { - "additionalProperties": false, - "properties": { - "delete_button_text": { "type": "string", "default": "Delete" }, - "line_1_all": { "type": "string", "default": "All subscriptions" }, - "line_1_matching": { "type": "string", "default": "Matching {{ query }}" }, - "line_2": { "type": "string", "default": "Range: {{ from }} – {{ to }}" }, - "line_3_month": { "type": "string", "default": "Allowed dates: {{ list }}" }, - "line_3_day": { "type": "string", "default": "Allowed days: {{ list }}" }, - "line_3_any": { "type": "string", "default": "Allowed dates and days: any" }, - "line_4_some": { "type": "string", "default": "Excluded: {{ list }}" }, - "line_4_none": { "type": "string", "default": "Excluded: none" }, - "any": { "type": "string", "default": "any" }, - "unit_y": { "type": "string", "default": "{{ count }} year" }, - "unit_y_plural": { "type": "string", "default": "{{ count }} years" }, - "unit_m": { "type": "string", "default": "{{ count }} month" }, - "unit_m_plural": { "type": "string", "default": "{{ count }} months" }, - "unit_w": { "type": "string", "default": "{{ count }} week" }, - "unit_w_plural": { "type": "string", "default": "{{ count }} weeks" }, - "unit_d": { "type": "string", "default": "{{ count }} day" }, - "unit_d_plural": { "type": "string", "default": "{{ count }} days" }, - "day_1": { "type": "string", "default": "Monday" }, - "day_2": { "type": "string", "default": "Tuesday" }, - "day_3": { "type": "string", "default": "Wednesday" }, - "day_4": { "type": "string", "default": "Thursday" }, - "day_5": { "type": "string", "default": "Friday" }, - "day_6": { "type": "string", "default": "Saturday" }, - "day_7": { "type": "string", "default": "Sunday" }, - "single_date": { "type": "string", "default": "{{ value, date }}" }, - "date_range": { "type": "string", "default": "{{ from, date }} – {{ to, date }}" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No rules" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "delete_button_text", - "line_1_all", - "line_1_matching", - "line_2", - "line_3_month", - "line_3_day", - "line_3_any", - "line_4_some", - "line_4_none", - "any", - "unit_y", - "unit_y_plural", - "unit_m", - "unit_m_plural", - "unit_w", - "unit_w_plural", - "unit_d", - "unit_d_plural", - "day_1", - "day_2", - "day_3", - "day_4", - "day_5", - "day_6", - "day_7", - "single_date", - "date_range", - "spinner" - ] - }, - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { "type": "string", "default": "{{from}}-{{to}} out of {{total}}" }, - "previous": { "type": "string", "default": "Previous" } - }, - "required": [ - "create_button_text", - "card", - "first", - "last", - "next", - "pagination", - "previous" - ] - } - }, - "required": [ - "label", - "helper_text", - "delete_header", - "delete_message", - "delete_confirm", - "delete_cancel", - "dialog", - "pagination" - ] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date_created": { "type": "string", "default": "Enabled on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "date": { "type": "string", "default": "{{value, date}}" } - }, - "required": ["date_created", "date_modified", "date"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Disable" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Disabling Customer Portal will erase the configuration and disable the related APIs. Would you like to proceed?" - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Enable" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "session-lifespan-in-minutes", - "allowed-origins", - "jwt-shared-secret", - "features", - "sign-up-verification-hcaptcha-site-key", - "sign-up-verification-hcaptcha-secret-key", - "subscriptions-allow-frequency-modification", - "subscriptions-allow-next-date-modification", - "timestamps", - "delete", - "create", - "spinner" - ] -} diff --git a/src/static/schemas/customer-portal-settings.json b/src/static/schemas/customer-portal-settings.json deleted file mode 100644 index 5003c9116..000000000 --- a/src/static/schemas/customer-portal-settings.json +++ /dev/null @@ -1,267 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "save_create": { "type": "string", "default": "Save and enable" }, - "save_delete": { "type": "string", "default": "Disable portal" }, - "save_update": { "type": "string", "default": "Save changes" }, - "jsonata": { - "additionalProperties": false, - "properties": { - "all": { "type": "string", "default": "All" }, - "some": { "type": "string", "default": "Some" }, - "hint": { - "type": "string", - "default": "Enter a valid JSONata query selecting the subscriptions these rules will apply to. Please limit your expression to 200 characters. Docs:" - } - }, - "required": ["all", "some", "hint"] - }, - "title": { "type": "string", "default": "Customer Portal" }, - "subtitle": { - "type": "string", - "default": "A dedicated place for your customers to view and manage their subscriptions, payment methods and recent transactions" - }, - "quickstart": { - "additionalProperties": false, - "properties": { - "title": { "type": "string", "default": "Quick start" }, - "subtitle": { - "type": "string", - "default": "Embed customer portal into your website by copying the code snippet below:" - } - }, - "required": ["title", "subtitle"] - }, - "origins": { - "additionalProperties": false, - "properties": { - "title": { "type": "string", "default": "Allowed origins" }, - "subtitle": { - "type": "string", - "default": "Please list below the websites you’re planning to use customer portal on" - }, - "invalid": { "type": "string", "default": "URL is invalid" }, - "https_only": { "type": "string", "default": "Origin is insecure" }, - "add": { "type": "string", "default": "Add origin" }, - "add_hint": { "type": "string", "default": "You can add up to 10 origins" } - }, - "required": ["title", "subtitle", "invalid", "https_only", "add", "add_hint"] - }, - "fmod": { - "additionalProperties": false, - "properties": { - "title": { "type": "string", "default": "Frequency modification" }, - "subtitle": { - "type": "string", - "default": "Customize how your customers can switch to a different payment schedule" - }, - "allTitle": { "type": "string", "default": "All subscriptions" }, - "someTitle": { "type": "string", "default": "Subscriptions matching" }, - "valuesLabel": { "type": "string", "default": "Values: " }, - "valuesList": { "type": "string", "default": "{{values, list lowercase}}" }, - "valuesListEmpty": { "type": "string", "default": "none" }, - "add_option": { "type": "string", "default": "Add option" }, - "add_option_hint": { - "type": "string", - "default": "You can add up to 20 value options for this rule" - }, - "add_rule": { "type": "string", "default": "Add rule" }, - "add_rule_hint": { "type": "string", "default": "You can add up to 10 rules" }, - "options": { "type": "string", "default": "Options" }, - "match": { "type": "string", "default": "Match" } - }, - "required": [ - "title", - "subtitle", - "allTitle", - "someTitle", - "valuesLabel", - "valuesList", - "valuesListEmpty", - "add_option", - "add_option_hint", - "add_rule", - "add_rule_hint", - "options", - "match" - ] - }, - "ndmod": { - "additionalProperties": false, - "properties": { - "title": { "type": "string", "default": "Next payment date modification" }, - "subtitle": { - "type": "string", - "default": "If enabled, your customers will be able to delay or advance the next payment" - }, - "allTitle": { "type": "string", "default": "All subscriptions" }, - "someTitle": { "type": "string", "default": "Subscriptions matching" }, - "range": { "type": "string", "default": "Range" }, - "range_start": { "type": "string", "default": "Start" }, - "range_end": { "type": "string", "default": "End (optional)" }, - "any": { "type": "string", "default": "Any" }, - "add": { "type": "string", "default": "Add rule" }, - "add_hint": { "type": "string", "default": "You can add up to 10 rules" }, - "add_range": { "type": "string", "default": "Add range" }, - "add_range_hint": { "type": "string", "default": "You can add up to 20 exceptions" }, - "add_single": { "type": "string", "default": "Add one date" }, - "match": { "type": "string", "default": "Match" }, - "allowed": { "type": "string", "default": "Allowed dates" }, - "excluded": { "type": "string", "default": "Excluded dates" }, - "month": { "type": "string", "default": "Specific dates" }, - "day": { "type": "string", "default": "Specific days of week" }, - "dayHint": { - "type": "string", - "default": "Your customers will be able to select only {{days, list}} for the next payment date." - }, - "select": { "type": "string", "default": "Select date" }, - "all": { "type": "string", "default": "All" }, - "none": { "type": "string", "default": "No restrictions" }, - "custom": { "type": "string", "default": "Custom offset" }, - "min": { "type": "string", "default": "Minimum" }, - "max": { "type": "string", "default": "Maximum" }, - "minHint": { - "type": "string", - "default": "Requires the new date to be at least {{duration}} into the future." - }, - "minWarning": { - "type": "string", - "default": "The minimum is either too close to the maximum or exceeds it. This may make your customers unable to change next date under certain conditions. Please proceed with caution." - }, - "maxHint": { - "type": "string", - "default": "Requires the new date to be at most {{duration}} into the future." - } - }, - "required": [ - "title", - "subtitle", - "allTitle", - "someTitle", - "range", - "range_start", - "range_end", - "any", - "add", - "add_hint", - "add_range", - "add_range_hint", - "add_single", - "match", - "allowed", - "excluded", - "month", - "day", - "dayHint", - "select", - "all", - "none", - "custom", - "min", - "max", - "minHint", - "minWarning", - "maxHint" - ] - }, - "sso": { - "additionalProperties": false, - "properties": { - "title": { "type": "string", "default": "Enable Single Sign-On (SSO)" }, - "subtitle": { - "type": "string", - "default": "Sync your sessions across your website and our checkout" - } - }, - "required": ["title", "subtitle"] - }, - "sign_up": { - "additionalProperties": false, - "properties": { - "title": { "type": "string", "default": "Enable customer registration" }, - "subtitle": { - "type": "string", - "default": "Add a sign up form to your portal and enable the API" - }, - "hcaptcha_explainer": { - "type": "string", - "default": "By default, Customer Portal uses Foxy's hCaptcha account to protect the sign up form. If you'd like to use your own hCaptcha account, please enter your site key and secret key above." - }, - "site_key_label": { "type": "string", "default": "hCaptcha site key" }, - "site_key_placeholder": { "type": "string", "default": "Use Foxy default" }, - "secret_key_label": { "type": "string", "default": "hCaptcha secret key" }, - "secret_key_placeholder": { "type": "string", "default": "Use Foxy default" } - }, - "required": [ - "title", - "subtitle", - "hcaptcha_explainer", - "site_key_label", - "site_key_placeholder", - "secret_key_label", - "secret_key_placeholder" - ] - }, - "jwt": { - "additionalProperties": false, - "properties": { - "title": { "type": "string", "default": "JWT shared secret" }, - "subtitle": { "type": "string", "default": "Reset this key to drop all active sessions" }, - "invalid": { - "type": "string", - "default": "Only letters (a-z), numbers (0-9) and dashes (-) are allowed in this field" - }, - "required": { "type": "string", "default": "Please fill in this field" }, - "too_short": { - "type": "string", - "default": "This key must be at least 40 characters long" - }, - "too_long": { "type": "string", "default": "This key must be at most 100 characters long" }, - "refresh": { "type": "string", "default": "Reset" } - }, - "required": ["title", "subtitle", "invalid", "required", "too_short", "too_long", "refresh"] - }, - "session": { - "additionalProperties": false, - "properties": { - "title": { "type": "string", "default": "Session duration" }, - "subtitle": { - "type": "string", - "default": "This is how long we'll keep your customers logged in" - }, - "too_short": { "type": "string", "default": "Session must be at least 1 minute long" }, - "too_long": { "type": "string", "default": "Sessions can't last for more than 4 weeks" } - }, - "required": ["title", "subtitle", "too_short", "too_long"] - }, - "advanced": { - "additionalProperties": false, - "properties": { - "title": { "type": "string", "default": "Advanced settings" }, - "subtitle": { - "type": "string", - "default": "Authentication settings for fine-tuning your integration" - } - }, - "required": ["title", "subtitle"] - } - }, - "required": [ - "save_create", - "save_delete", - "save_update", - "jsonata", - "title", - "subtitle", - "quickstart", - "origins", - "fmod", - "ndmod", - "sso", - "sign_up", - "jwt", - "session", - "advanced" - ] -} diff --git a/src/static/schemas/customer-portal.json b/src/static/schemas/customer-portal.json deleted file mode 100644 index b1999f58c..000000000 --- a/src/static/schemas/customer-portal.json +++ /dev/null @@ -1,2796 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "access-recovery-form": { - "additionalProperties": false, - "properties": { - "back": { "type": "string", "default": "Go back" }, - "email": { "type": "string", "default": "Email" }, - "recover_access": { "type": "string", "default": "Get temporary password" }, - "recover_access_hint": { - "type": "string", - "default": "Enter your email to get a temporary password" - }, - "recover_access_success": { - "type": "string", - "default": "Done! Please check your email for further instructions." - }, - "unknown_error": { - "type": "string", - "default": "We can't issue a one-time code for this account at the moment. If you've already requested the code, please wait a few minutes before trying again." - }, - "v8n_invalid_email": { "type": "string", "default": "Invalid email" }, - "v8n_required": { "type": "string", "default": "Required" }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "back", - "email", - "recover_access", - "recover_access_hint", - "recover_access_success", - "unknown_error", - "v8n_invalid_email", - "v8n_required", - "spinner" - ] - }, - "customer": { - "additionalProperties": false, - "properties": { - "address_plural": { "type": "string", "default": "Addresses" }, - "cancel": { "type": "string", "default": "Cancel" }, - "close": { "type": "string", "default": "Close" }, - "payment_method_plural": { "type": "string", "default": "Payment methods" }, - "save": { "type": "string", "default": "Save" }, - "subscription_plural": { "type": "string", "default": "Subscriptions" }, - "transaction_plural": { "type": "string", "default": "Transactions" }, - "undo_cancel": { "type": "string", "default": "Review" }, - "undo_confirm": { "type": "string", "default": "Discard" }, - "undo_header": { "type": "string", "default": "Unsaved changes" }, - "undo_message": { - "type": "string", - "default": "Looks like you didn't save your changes! What would you like to do with them?" - }, - "update": { "type": "string", "default": "Update" }, - "transactions-table": { - "additionalProperties": false, - "properties": { - "date": { "type": "string", "default": "{{value, date}}" }, - "price": { "type": "string", "default": "{{amount, price}}" }, - "receipt": { "type": "string", "default": "Receipt" }, - "transaction_approved": { "type": "string", "default": "Approved" }, - "transaction_authorized": { "type": "string", "default": "Authorized" }, - "transaction_captured": { "type": "string", "default": "Captured" }, - "transaction_completed": { "type": "string", "default": "Completed" }, - "transaction_declined": { "type": "string", "default": "Declined" }, - "transaction_pending": { "type": "string", "default": "Pending" }, - "transaction_refunded": { "type": "string", "default": "Refunded" }, - "transaction_rejected": { "type": "string", "default": "Rejected" }, - "transaction_summary": { "type": "string", "default": "{{most_expensive_item.name}}" }, - "transaction_summary_plural": { - "type": "string", - "default": "{{most_expensive_item.name}} and {{count_minus_one}} more" - }, - "transaction_verified": { "type": "string", "default": "Verified" }, - "transaction_voided": { "type": "string", "default": "Voided" }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "date", - "price", - "receipt", - "transaction_approved", - "transaction_authorized", - "transaction_captured", - "transaction_completed", - "transaction_declined", - "transaction_pending", - "transaction_refunded", - "transaction_rejected", - "transaction_summary", - "transaction_summary_plural", - "transaction_verified", - "transaction_voided", - "spinner" - ] - }, - "address-card": { - "additionalProperties": false, - "properties": { - "default_billing_address": { "type": "string", "default": "Default billing address" }, - "default_shipping_address": { "type": "string", "default": "Default shipping address" }, - "full_address": { - "type": "string", - "default": "{{address1}} {{address2}} {{city}} {{region}} {{postal_code}}" - }, - "full_name": { "type": "string", "default": "{{first_name}} {{last_name}}" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No addresses" }, - "loading_end": { "type": "string", "default": "No more data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_end", "loading_error"] - } - }, - "required": [ - "default_billing_address", - "default_shipping_address", - "full_address", - "full_name", - "spinner" - ] - }, - "address-form": { - "additionalProperties": false, - "properties": { - "address-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Address name" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_required": { "type": "string", "default": "Please enter address name" }, - "v8n_too_long": { - "type": "string", - "default": "Please shorten address name to 100 characters or less" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_too_long"] - }, - "first-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "First name" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we can't store first names longer than 50 characters" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "last-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Last name" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we can't store last names longer than 50 characters" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "company": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Company" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we can't store company names longer than 50 characters" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "phone": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Phone" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "This phone number appears to be too long" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "address-one": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Address Line 1" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "Street address, P.O. box, company name, c/o" - }, - "v8n_required": { "type": "string", "default": "Please enter address line 1" }, - "v8n_too_long": { - "type": "string", - "default": "Please shorten address line 1 to 100 characters or less" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_too_long"] - }, - "address-two": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Address Line 2" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { - "type": "string", - "default": "Apartment, suite, unit, building, floor, etc." - }, - "v8n_too_long": { - "type": "string", - "default": "Please shorten address line 2 to 100 characters or less" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "city": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "City" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we can't store city names longer than 50 characters" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "postal-code": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Postal code" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "This postal code appears to be too long" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "country": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Country" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "region": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Region" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we can't store region names longer than 50 characters" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date": { "type": "string", "default": "{{value, date}}" }, - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" } - }, - "required": ["date", "date_created", "date_modified"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove this address? You won't be able to bring it back." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - }, - "country_af": { "type": "string", "default": "Afghanistan" }, - "country_ax": { "type": "string", "default": "Åland Islands" }, - "country_al": { "type": "string", "default": "Albania" }, - "country_dz": { "type": "string", "default": "Algeria" }, - "country_as": { "type": "string", "default": "American Samoa" }, - "country_ad": { "type": "string", "default": "Andorra" }, - "country_ao": { "type": "string", "default": "Angola" }, - "country_ai": { "type": "string", "default": "Anguilla" }, - "country_aq": { "type": "string", "default": "Antarctica" }, - "country_ag": { "type": "string", "default": "Antigua and Barbuda" }, - "country_ar": { "type": "string", "default": "Argentina" }, - "country_am": { "type": "string", "default": "Armenia" }, - "country_aw": { "type": "string", "default": "Aruba" }, - "country_au": { "type": "string", "default": "Australia" }, - "country_au_region_act": { - "type": "string", - "default": "Australian Capital Territory" - }, - "country_au_region_nsw": { "type": "string", "default": "New South Wales" }, - "country_au_region_nt": { "type": "string", "default": "Northern Territory" }, - "country_au_region_qld": { "type": "string", "default": "Queensland" }, - "country_au_region_sa": { "type": "string", "default": "South Australia" }, - "country_au_region_tas": { "type": "string", "default": "Tasmania" }, - "country_au_region_vic": { "type": "string", "default": "Victoria" }, - "country_au_region_wa": { "type": "string", "default": "Western Australia" }, - "country_at": { "type": "string", "default": "Austria" }, - "country_at_region_bl": { "type": "string", "default": "Burgenland" }, - "country_at_region_kn": { "type": "string", "default": "Kaernten" }, - "country_at_region_no": { "type": "string", "default": "Niederoesterreich" }, - "country_at_region_oo": { "type": "string", "default": "Oberoesterreich" }, - "country_at_region_sb": { "type": "string", "default": "Salzburg" }, - "country_at_region_st": { "type": "string", "default": "Steiermark" }, - "country_at_region_ti": { "type": "string", "default": "Tirol" }, - "country_at_region_vb": { "type": "string", "default": "Voralberg" }, - "country_at_region_wi": { "type": "string", "default": "Wien" }, - "country_az": { "type": "string", "default": "Azerbaijan" }, - "country_bs": { "type": "string", "default": "Bahamas" }, - "country_bh": { "type": "string", "default": "Bahrain" }, - "country_bd": { "type": "string", "default": "Bangladesh" }, - "country_bb": { "type": "string", "default": "Barbados" }, - "country_by": { "type": "string", "default": "Belarus" }, - "country_be": { "type": "string", "default": "Belgium" }, - "country_bz": { "type": "string", "default": "Belize" }, - "country_bj": { "type": "string", "default": "Benin" }, - "country_bm": { "type": "string", "default": "Bermuda" }, - "country_bt": { "type": "string", "default": "Bhutan" }, - "country_bo": { "type": "string", "default": "Bolivia" }, - "country_bq": { "type": "string", "default": "Bonaire, Sint Eustatius and Saba" }, - "country_bq_region_bo": { "type": "string", "default": "Bonaire" }, - "country_bq_region_sa": { "type": "string", "default": "Saba" }, - "country_bq_region_se": { "type": "string", "default": "Sint Eustatius" }, - "country_ba": { "type": "string", "default": "Bosnia and Herzegovina" }, - "country_bw": { "type": "string", "default": "Botswana" }, - "country_bv": { "type": "string", "default": "Bouvet Island" }, - "country_br": { "type": "string", "default": "Brazil" }, - "country_io": { "type": "string", "default": "British Indian Ocean Territory" }, - "country_bn": { "type": "string", "default": "Brunei Darussalam" }, - "country_bg": { "type": "string", "default": "Bulgaria" }, - "country_bf": { "type": "string", "default": "Burkina Faso" }, - "country_bi": { "type": "string", "default": "Burundi" }, - "country_kh": { "type": "string", "default": "Cambodia" }, - "country_cm": { "type": "string", "default": "Cameroon" }, - "country_ca": { "type": "string", "default": "Canada" }, - "country_ca_region_ab": { "type": "string", "default": "Alberta" }, - "country_ca_region_bc": { "type": "string", "default": "British Columbia" }, - "country_ca_region_mb": { "type": "string", "default": "Manitoba" }, - "country_ca_region_nb": { "type": "string", "default": "New Brunswick" }, - "country_ca_region_nl": { "type": "string", "default": "Newfoundland and Labrador" }, - "country_ca_region_nt": { "type": "string", "default": "Northwest Territories" }, - "country_ca_region_ns": { "type": "string", "default": "Nova Scotia" }, - "country_ca_region_nu": { "type": "string", "default": "Nunavut" }, - "country_ca_region_on": { "type": "string", "default": "Ontario" }, - "country_ca_region_pe": { "type": "string", "default": "Prince Edward Island" }, - "country_ca_region_qc": { "type": "string", "default": "Quebec" }, - "country_ca_region_sk": { "type": "string", "default": "Saskatchewan" }, - "country_ca_region_yt": { "type": "string", "default": "Yukon" }, - "country_cv": { "type": "string", "default": "Cape Verde" }, - "country_cw": { "type": "string", "default": "Curaçao" }, - "country_ky": { "type": "string", "default": "Cayman Islands" }, - "country_cf": { "type": "string", "default": "Central African Republic" }, - "country_td": { "type": "string", "default": "Chad" }, - "country_cl": { "type": "string", "default": "Chile" }, - "country_cn": { "type": "string", "default": "China" }, - "country_cx": { "type": "string", "default": "Christmas Island" }, - "country_cc": { "type": "string", "default": "Cocos (Keeling) Islands" }, - "country_co": { "type": "string", "default": "Colombia" }, - "country_km": { "type": "string", "default": "Comoros" }, - "country_cg": { "type": "string", "default": "Congo" }, - "country_cd": { "type": "string", "default": "Congo, the Democratic Republic of the" }, - "country_ck": { "type": "string", "default": "Cook Islands" }, - "country_cr": { "type": "string", "default": "Costa Rica" }, - "country_ci": { "type": "string", "default": "Cote DIvoire" }, - "country_hr": { "type": "string", "default": "Croatia" }, - "country_cu": { "type": "string", "default": "Cuba" }, - "country_cy": { "type": "string", "default": "Cyprus" }, - "country_cz": { "type": "string", "default": "Czech Republic" }, - "country_dk": { "type": "string", "default": "Denmark" }, - "country_dj": { "type": "string", "default": "Djibouti" }, - "country_dm": { "type": "string", "default": "Dominica" }, - "country_do": { "type": "string", "default": "Dominican Republic" }, - "country_ec": { "type": "string", "default": "Ecuador" }, - "country_eg": { "type": "string", "default": "Egypt" }, - "country_sv": { "type": "string", "default": "El Salvador" }, - "country_sx": { "type": "string", "default": "Sint Maarten" }, - "country_gq": { "type": "string", "default": "Equatorial Guinea" }, - "country_er": { "type": "string", "default": "Eritrea" }, - "country_ee": { "type": "string", "default": "Estonia" }, - "country_et": { "type": "string", "default": "Ethiopia" }, - "country_fk": { "type": "string", "default": "Falkland Islands (Malvinas)" }, - "country_fo": { "type": "string", "default": "Faroe Islands" }, - "country_fj": { "type": "string", "default": "Fiji" }, - "country_fi": { "type": "string", "default": "Finland" }, - "country_fr": { "type": "string", "default": "France" }, - "country_gf": { "type": "string", "default": "French Guiana" }, - "country_pf": { "type": "string", "default": "French Polynesia" }, - "country_tf": { "type": "string", "default": "French Southern Territories" }, - "country_ga": { "type": "string", "default": "Gabon" }, - "country_gm": { "type": "string", "default": "Gambia" }, - "country_ge": { "type": "string", "default": "Georgia" }, - "country_de": { "type": "string", "default": "Germany" }, - "country_de_region_bw": { "type": "string", "default": "Baden-Wuerttemberg" }, - "country_de_region_by": { "type": "string", "default": "Bayern" }, - "country_de_region_be": { "type": "string", "default": "Berlin" }, - "country_de_region_bb": { "type": "string", "default": "Brandenburg" }, - "country_de_region_hb": { "type": "string", "default": "Bremen" }, - "country_de_region_hh": { "type": "string", "default": "Hamburg" }, - "country_de_region_he": { "type": "string", "default": "Hessen" }, - "country_de_region_mv": { "type": "string", "default": "Mecklenburg-Vorpommern" }, - "country_de_region_ni": { "type": "string", "default": "Niedersachsen" }, - "country_de_region_nw": { "type": "string", "default": "Nordrhein-Westfalen" }, - "country_de_region_rp": { "type": "string", "default": "Rheinland-Pfalz" }, - "country_de_region_sl": { "type": "string", "default": "Saarland" }, - "country_de_region_sn": { "type": "string", "default": "Sachsen" }, - "country_de_region_st": { "type": "string", "default": "Sachsen-Anhalt" }, - "country_de_region_sh": { "type": "string", "default": "Schleswig-Holstein" }, - "country_de_region_th": { "type": "string", "default": "Thueringen" }, - "country_gh": { "type": "string", "default": "Ghana" }, - "country_gi": { "type": "string", "default": "Gibraltar" }, - "country_gr": { "type": "string", "default": "Greece" }, - "country_gl": { "type": "string", "default": "Greenland" }, - "country_gd": { "type": "string", "default": "Grenada" }, - "country_gp": { "type": "string", "default": "Guadeloupe" }, - "country_gu": { "type": "string", "default": "Guam" }, - "country_gt": { "type": "string", "default": "Guatemala" }, - "country_gg": { "type": "string", "default": "Guernsey" }, - "country_gn": { "type": "string", "default": "Guinea" }, - "country_gw": { "type": "string", "default": "Guinea-bissau" }, - "country_gy": { "type": "string", "default": "Guyana" }, - "country_ht": { "type": "string", "default": "Haiti" }, - "country_hm": { "type": "string", "default": "Heard Island and McDonald Island" }, - "country_va": { "type": "string", "default": "Holy See (Vatican City State)" }, - "country_hn": { "type": "string", "default": "Honduras" }, - "country_hk": { "type": "string", "default": "Hong Kong" }, - "country_hu": { "type": "string", "default": "Hungary" }, - "country_is": { "type": "string", "default": "Iceland" }, - "country_in": { "type": "string", "default": "India" }, - "country_in_region_an": { "type": "string", "default": "Andaman and Nicobar Islands" }, - "country_in_region_ap": { "type": "string", "default": "Andhra Pradesh" }, - "country_in_region_ar": { "type": "string", "default": "Arunachal Pradesh" }, - "country_in_region_as": { "type": "string", "default": "Assam" }, - "country_in_region_br": { "type": "string", "default": "Bihar" }, - "country_in_region_ch": { "type": "string", "default": "Chandigarh" }, - "country_in_region_ct": { "type": "string", "default": "Chhattisgarh" }, - "country_in_region_dn": { "type": "string", "default": "Dadra and Nagar Haveli" }, - "country_in_region_dd": { "type": "string", "default": "Daman and Diu" }, - "country_in_region_dl": { "type": "string", "default": "Delhi" }, - "country_in_region_ga": { "type": "string", "default": "Goa" }, - "country_in_region_gj": { "type": "string", "default": "Gujarat" }, - "country_in_region_hr": { "type": "string", "default": "Haryana" }, - "country_in_region_hp": { "type": "string", "default": "Himachal Pradesh" }, - "country_in_region_jk": { "type": "string", "default": "Jammu and Kashmir" }, - "country_in_region_jh": { "type": "string", "default": "Jharkhand" }, - "country_in_region_ka": { "type": "string", "default": "Karnataka" }, - "country_in_region_kl": { "type": "string", "default": "Kerala" }, - "country_in_region_ld": { "type": "string", "default": "Lakshadweep" }, - "country_in_region_mp": { "type": "string", "default": "Madhya Pradesh" }, - "country_in_region_mh": { "type": "string", "default": "Maharashtra" }, - "country_in_region_mn": { "type": "string", "default": "Manipur" }, - "country_in_region_ml": { "type": "string", "default": "Meghalaya" }, - "country_in_region_mz": { "type": "string", "default": "Mizoram" }, - "country_in_region_nl": { "type": "string", "default": "Nagaland" }, - "country_in_region_or": { "type": "string", "default": "Odisha" }, - "country_in_region_py": { "type": "string", "default": "Puducherry" }, - "country_in_region_pb": { "type": "string", "default": "Punjab" }, - "country_in_region_rj": { "type": "string", "default": "Rajasthan" }, - "country_in_region_sk": { "type": "string", "default": "Sikkim" }, - "country_in_region_tn": { "type": "string", "default": "Tamil Nadu" }, - "country_in_region_tg": { "type": "string", "default": "Telangana" }, - "country_in_region_tr": { "type": "string", "default": "Tripura" }, - "country_in_region_ut": { "type": "string", "default": "Uttarakhand" }, - "country_in_region_up": { "type": "string", "default": "Uttar Pradesh" }, - "country_in_region_wb": { "type": "string", "default": "West Bengal" }, - "country_id": { "type": "string", "default": "Indonesia" }, - "country_ir": { "type": "string", "default": "Iran, Islamic Republic of" }, - "country_iq": { "type": "string", "default": "Iraq" }, - "country_ie": { "type": "string", "default": "Ireland" }, - "country_ie_region_cw": { "type": "string", "default": "Carlow" }, - "country_ie_region_cn": { "type": "string", "default": "Cavan" }, - "country_ie_region_ce": { "type": "string", "default": "Clare" }, - "country_ie_region_co": { "type": "string", "default": "Cork" }, - "country_ie_region_dl": { "type": "string", "default": "Donegal" }, - "country_ie_region_d": { "type": "string", "default": "Dublin" }, - "country_ie_region_g": { "type": "string", "default": "Galway" }, - "country_ie_region_ky": { "type": "string", "default": "Kerry" }, - "country_ie_region_ke": { "type": "string", "default": "Kildare" }, - "country_ie_region_kk": { "type": "string", "default": "Kilkenny" }, - "country_ie_region_ls": { "type": "string", "default": "Laois" }, - "country_ie_region_lm": { "type": "string", "default": "Leitrim" }, - "country_ie_region_lk": { "type": "string", "default": "Limerick" }, - "country_ie_region_ld": { "type": "string", "default": "Longford" }, - "country_ie_region_lh": { "type": "string", "default": "Louth" }, - "country_ie_region_mo": { "type": "string", "default": "Mayo" }, - "country_ie_region_mh": { "type": "string", "default": "Meath" }, - "country_ie_region_mn": { "type": "string", "default": "Monaghan" }, - "country_ie_region_oy": { "type": "string", "default": "Offaly" }, - "country_ie_region_rn": { "type": "string", "default": "Roscommon" }, - "country_ie_region_so": { "type": "string", "default": "Sligo" }, - "country_ie_region_ta": { "type": "string", "default": "Tipperary" }, - "country_ie_region_wd": { "type": "string", "default": "Waterford" }, - "country_ie_region_wh": { "type": "string", "default": "Westmeath" }, - "country_ie_region_wx": { "type": "string", "default": "Wexford" }, - "country_ie_region_ww": { "type": "string", "default": "Wicklow" }, - "country_im": { "type": "string", "default": "Isle of Man" }, - "country_il": { "type": "string", "default": "Israel" }, - "country_it": { "type": "string", "default": "Italy" }, - "country_jm": { "type": "string", "default": "Jamaica" }, - "country_jp": { "type": "string", "default": "Japan" }, - "country_jp_region_10": { "type": "string", "default": "Gunma" }, - "country_jp_region_11": { "type": "string", "default": "Saitama" }, - "country_jp_region_12": { "type": "string", "default": "Chiba" }, - "country_jp_region_13": { "type": "string", "default": "Tokyo" }, - "country_jp_region_14": { "type": "string", "default": "Kanagawa" }, - "country_jp_region_15": { "type": "string", "default": "Niigata" }, - "country_jp_region_16": { "type": "string", "default": "Toyama" }, - "country_jp_region_17": { "type": "string", "default": "Ishikawa" }, - "country_jp_region_18": { "type": "string", "default": "Fukui" }, - "country_jp_region_19": { "type": "string", "default": "Yamanashi" }, - "country_jp_region_20": { "type": "string", "default": "Nagano" }, - "country_jp_region_21": { "type": "string", "default": "Gifu" }, - "country_jp_region_22": { "type": "string", "default": "Shizuoka" }, - "country_jp_region_23": { "type": "string", "default": "Aichi" }, - "country_jp_region_24": { "type": "string", "default": "Mie" }, - "country_jp_region_25": { "type": "string", "default": "Shiga" }, - "country_jp_region_26": { "type": "string", "default": "Kyoto" }, - "country_jp_region_27": { "type": "string", "default": "Osaka" }, - "country_jp_region_28": { "type": "string", "default": "Hyogo" }, - "country_jp_region_29": { "type": "string", "default": "Nara" }, - "country_jp_region_30": { "type": "string", "default": "Wakayama" }, - "country_jp_region_31": { "type": "string", "default": "Tottori" }, - "country_jp_region_32": { "type": "string", "default": "Shimane" }, - "country_jp_region_33": { "type": "string", "default": "Okayama" }, - "country_jp_region_34": { "type": "string", "default": "Hiroshima" }, - "country_jp_region_35": { "type": "string", "default": "Yamaguchi" }, - "country_jp_region_36": { "type": "string", "default": "Tokushima" }, - "country_jp_region_37": { "type": "string", "default": "Kagawa" }, - "country_jp_region_38": { "type": "string", "default": "Ehime" }, - "country_jp_region_39": { "type": "string", "default": "Kochi" }, - "country_jp_region_40": { "type": "string", "default": "Fukuoka" }, - "country_jp_region_41": { "type": "string", "default": "Saga" }, - "country_jp_region_42": { "type": "string", "default": "Nagasaki" }, - "country_jp_region_43": { "type": "string", "default": "Kumamoto" }, - "country_jp_region_44": { "type": "string", "default": "Oita" }, - "country_jp_region_45": { "type": "string", "default": "Miyazaki" }, - "country_jp_region_46": { "type": "string", "default": "Kagoshima" }, - "country_jp_region_47": { "type": "string", "default": "Okinawa" }, - "country_jp_region_05": { "type": "string", "default": "Akita" }, - "country_jp_region_02": { "type": "string", "default": "Aomori" }, - "country_jp_region_07": { "type": "string", "default": "Fukushima" }, - "country_jp_region_01": { "type": "string", "default": "Hokkaido" }, - "country_jp_region_08": { "type": "string", "default": "Ibaraki" }, - "country_jp_region_03": { "type": "string", "default": "Iwate" }, - "country_jp_region_04": { "type": "string", "default": "Miyagi" }, - "country_jp_region_09": { "type": "string", "default": "Tochigi" }, - "country_jp_region_06": { "type": "string", "default": "Yamagata" }, - "country_je": { "type": "string", "default": "Jersey" }, - "country_jo": { "type": "string", "default": "Jordan" }, - "country_kz": { "type": "string", "default": "Kazakhstan" }, - "country_ke": { "type": "string", "default": "Kenya" }, - "country_ki": { "type": "string", "default": "Kiribati" }, - "country_kp": { "type": "string", "default": "Korea, Democratic People's Republic of" }, - "country_kr": { "type": "string", "default": "Korea, Republic of" }, - "country_kw": { "type": "string", "default": "Kuwait" }, - "country_kg": { "type": "string", "default": "Kyrgyzstan" }, - "country_la": { "type": "string", "default": "Lao People's Democratic Republic" }, - "country_lv": { "type": "string", "default": "Latvia" }, - "country_lb": { "type": "string", "default": "Lebanon" }, - "country_ls": { "type": "string", "default": "Lesotho" }, - "country_lr": { "type": "string", "default": "Liberia" }, - "country_ly": { "type": "string", "default": "Libya" }, - "country_li": { "type": "string", "default": "Liechtenstein" }, - "country_lt": { "type": "string", "default": "Lithuania" }, - "country_lu": { "type": "string", "default": "Luxembourg" }, - "country_mo": { - "type": "string", - "default": "Macau Special Administrative Region of China" - }, - "country_mk": { "type": "string", "default": "North Macedonia" }, - "country_mg": { "type": "string", "default": "Madagascar" }, - "country_mw": { "type": "string", "default": "Malawi" }, - "country_my": { "type": "string", "default": "Malaysia" }, - "country_mv": { "type": "string", "default": "Maldives" }, - "country_ml": { "type": "string", "default": "Mali" }, - "country_mt": { "type": "string", "default": "Malta" }, - "country_mh": { "type": "string", "default": "Marshall Islands" }, - "country_mq": { "type": "string", "default": "Martinique" }, - "country_mr": { "type": "string", "default": "Mauritania" }, - "country_mu": { "type": "string", "default": "Mauritius" }, - "country_yt": { "type": "string", "default": "Mayotte" }, - "country_mx": { "type": "string", "default": "Mexico" }, - "country_fm": { "type": "string", "default": "Micronesia, Federated States of" }, - "country_md": { "type": "string", "default": "Moldova, Republic of" }, - "country_mc": { "type": "string", "default": "Monaco" }, - "country_mn": { "type": "string", "default": "Mongolia" }, - "country_me": { "type": "string", "default": "Montenegro" }, - "country_ms": { "type": "string", "default": "Montserrat" }, - "country_ma": { "type": "string", "default": "Morocco" }, - "country_mz": { "type": "string", "default": "Mozambique" }, - "country_mm": { "type": "string", "default": "Myanmar" }, - "country_na": { "type": "string", "default": "Namibia" }, - "country_nr": { "type": "string", "default": "Nauru" }, - "country_np": { "type": "string", "default": "Nepal" }, - "country_nl": { "type": "string", "default": "Netherlands" }, - "country_nc": { "type": "string", "default": "New Caledonia" }, - "country_nz": { "type": "string", "default": "New Zealand" }, - "country_ni": { "type": "string", "default": "Nicaragua" }, - "country_ne": { "type": "string", "default": "Niger" }, - "country_ng": { "type": "string", "default": "Nigeria" }, - "country_nu": { "type": "string", "default": "Niue" }, - "country_nf": { "type": "string", "default": "Norfolk Island" }, - "country_mp": { "type": "string", "default": "Northern Mariana Islands" }, - "country_no": { "type": "string", "default": "Norway" }, - "country_no_region_10": { "type": "string", "default": "Vest-Agder" }, - "country_no_region_11": { "type": "string", "default": "Rogaland" }, - "country_no_region_12": { "type": "string", "default": "Hordaland" }, - "country_no_region_14": { "type": "string", "default": "Sogn og Fjordane" }, - "country_no_region_15": { "type": "string", "default": "Møre og Romsdal" }, - "country_no_region_16": { "type": "string", "default": "Sør-Trøndelag" }, - "country_no_region_17": { "type": "string", "default": "Nord-Trøndelag" }, - "country_no_region_18": { "type": "string", "default": "Nordland" }, - "country_no_region_19": { "type": "string", "default": "Troms" }, - "country_no_region_20": { "type": "string", "default": "Finnmark" }, - "country_no_region_30": { "type": "string", "default": "Viken" }, - "country_no_region_34": { "type": "string", "default": "Innlandet" }, - "country_no_region_38": { "type": "string", "default": "Vestfold og Telemark" }, - "country_no_region_42": { "type": "string", "default": "Agder" }, - "country_no_region_46": { "type": "string", "default": "Vestland" }, - "country_no_region_50": { "type": "string", "default": "Trøndelag" }, - "country_no_region_54": { "type": "string", "default": "Troms og Finnmark" }, - "country_no_region_01": { "type": "string", "default": "Østfold" }, - "country_no_region_02": { "type": "string", "default": "Akershus" }, - "country_no_region_03": { "type": "string", "default": "Oslo" }, - "country_no_region_04": { "type": "string", "default": "Hedmark" }, - "country_no_region_05": { "type": "string", "default": "Oppland" }, - "country_no_region_06": { "type": "string", "default": "Buskerud" }, - "country_no_region_07": { "type": "string", "default": "Vestfold" }, - "country_no_region_08": { "type": "string", "default": "Telemark" }, - "country_no_region_09": { "type": "string", "default": "Aust-Agder" }, - "country_om": { "type": "string", "default": "Oman" }, - "country_pk": { "type": "string", "default": "Pakistan" }, - "country_pw": { "type": "string", "default": "Palau" }, - "country_ps": { "type": "string", "default": "Palestine, State of" }, - "country_pa": { "type": "string", "default": "Panama" }, - "country_pg": { "type": "string", "default": "Papua New Guinea" }, - "country_py": { "type": "string", "default": "Paraguay" }, - "country_pe": { "type": "string", "default": "Peru" }, - "country_ph": { "type": "string", "default": "Philippines" }, - "country_pn": { "type": "string", "default": "Pitcairn" }, - "country_pl": { "type": "string", "default": "Poland" }, - "country_pt": { "type": "string", "default": "Portugal" }, - "country_pr": { "type": "string", "default": "Puerto Rico" }, - "country_qa": { "type": "string", "default": "Qatar" }, - "country_re": { "type": "string", "default": "Réunion" }, - "country_ro": { "type": "string", "default": "Romania" }, - "country_ru": { "type": "string", "default": "Russian Federation" }, - "country_rw": { "type": "string", "default": "Rwanda" }, - "country_bl": { "type": "string", "default": "Saint Barthélemy" }, - "country_sh": { - "type": "string", - "default": "Saint Helena, Ascension and Tristan da Cunha" - }, - "country_kn": { "type": "string", "default": "Saint Kitts and Nevis" }, - "country_lc": { "type": "string", "default": "Saint Lucia" }, - "country_mf": { "type": "string", "default": "Saint Martin" }, - "country_pm": { "type": "string", "default": "Saint Pierre and Miquelon" }, - "country_vc": { "type": "string", "default": "Saint Vincent and the Grenadines" }, - "country_ws": { "type": "string", "default": "Samoa" }, - "country_sm": { "type": "string", "default": "San Marino" }, - "country_ss": { "type": "string", "default": "South Sudan" }, - "country_st": { "type": "string", "default": "Sao Tome and Principe" }, - "country_sa": { "type": "string", "default": "Saudi Arabia" }, - "country_sn": { "type": "string", "default": "Senegal" }, - "country_rs": { "type": "string", "default": "Serbia" }, - "country_sc": { "type": "string", "default": "Seychelles" }, - "country_sl": { "type": "string", "default": "Sierra Leone" }, - "country_sg": { "type": "string", "default": "Singapore" }, - "country_sk": { "type": "string", "default": "Slovakia" }, - "country_si": { "type": "string", "default": "Slovenia" }, - "country_sb": { "type": "string", "default": "Solomon Islands" }, - "country_so": { "type": "string", "default": "Somalia" }, - "country_za": { "type": "string", "default": "South Africa" }, - "country_gs": { - "type": "string", - "default": "South Georgia and the South Sandwich Islands" - }, - "country_es": { "type": "string", "default": "Spain" }, - "country_es_region_a coruna": { "type": "string", "default": "A Coruna" }, - "country_es_region_alava": { "type": "string", "default": "Alava" }, - "country_es_region_albacete": { "type": "string", "default": "Albacete" }, - "country_es_region_alicante": { "type": "string", "default": "Alicante" }, - "country_es_region_almeria": { "type": "string", "default": "Almeria" }, - "country_es_region_asturias": { "type": "string", "default": "Asturias" }, - "country_es_region_avila": { "type": "string", "default": "Avila" }, - "country_es_region_badajoz": { "type": "string", "default": "Badajoz" }, - "country_es_region_baleares": { "type": "string", "default": "Baleares" }, - "country_es_region_barcelona": { "type": "string", "default": "Barcelona" }, - "country_es_region_burgos": { "type": "string", "default": "Burgos" }, - "country_es_region_caceres": { "type": "string", "default": "Caceres" }, - "country_es_region_cadiz": { "type": "string", "default": "Cadiz" }, - "country_es_region_cn": { "type": "string", "default": "Canarias" }, - "country_es_region_cantabria": { "type": "string", "default": "Cantabria" }, - "country_es_region_castellon": { "type": "string", "default": "Castellon" }, - "country_es_region_ceuta": { "type": "string", "default": "Ceuta" }, - "country_es_region_ciudad real": { "type": "string", "default": "Ciudad Real" }, - "country_es_region_cordoba": { "type": "string", "default": "Cordoba" }, - "country_es_region_cuenca": { "type": "string", "default": "Cuenca" }, - "country_es_region_gipuzkoa": { "type": "string", "default": "Gipuzkoa" }, - "country_es_region_girona": { "type": "string", "default": "Girona" }, - "country_es_region_granada": { "type": "string", "default": "Granada" }, - "country_es_region_guadalajara": { "type": "string", "default": "Guadalajara" }, - "country_es_region_guipuzcoa": { "type": "string", "default": "Guipuzcoa" }, - "country_es_region_huelva": { "type": "string", "default": "Huelva" }, - "country_es_region_huesca": { "type": "string", "default": "Huesca" }, - "country_es_region_jaen": { "type": "string", "default": "Jaen" }, - "country_es_region_la rioja": { "type": "string", "default": "La Rioja" }, - "country_es_region_las palmas": { "type": "string", "default": "Las Palmas" }, - "country_es_region_leon": { "type": "string", "default": "Leon" }, - "country_es_region_lleida": { "type": "string", "default": "Lleida" }, - "country_es_region_lugo": { "type": "string", "default": "Lugo" }, - "country_es_region_madrid": { "type": "string", "default": "Madrid" }, - "country_es_region_malaga": { "type": "string", "default": "Malaga" }, - "country_es_region_melilla": { "type": "string", "default": "Melilla" }, - "country_es_region_murcia": { "type": "string", "default": "Murcia" }, - "country_es_region_navarra": { "type": "string", "default": "Navarra" }, - "country_es_region_ourense": { "type": "string", "default": "Ourense" }, - "country_es_region_palencia": { "type": "string", "default": "Palencia" }, - "country_es_region_pontevedra": { "type": "string", "default": "Pontevedra" }, - "country_es_region_salamanca": { "type": "string", "default": "Salamanca" }, - "country_es_region_santa cruz de tenerife": { - "type": "string", - "default": "Santa Cruz de Tenerife" - }, - "country_es_region_segovia": { "type": "string", "default": "Segovia" }, - "country_es_region_sevilla": { "type": "string", "default": "Sevilla" }, - "country_es_region_soria": { "type": "string", "default": "Soria" }, - "country_es_region_tarragona": { "type": "string", "default": "Tarragona" }, - "country_es_region_teruel": { "type": "string", "default": "Teruel" }, - "country_es_region_toledo": { "type": "string", "default": "Toledo" }, - "country_es_region_valencia": { "type": "string", "default": "Valencia" }, - "country_es_region_valladolid": { "type": "string", "default": "Valladolid" }, - "country_es_region_vizcaya": { "type": "string", "default": "Biscay" }, - "country_es_region_zamora": { "type": "string", "default": "Zamora" }, - "country_es_region_zaragoza": { "type": "string", "default": "Zaragoza" }, - "country_lk": { "type": "string", "default": "Sri Lanka" }, - "country_sd": { "type": "string", "default": "Sudan" }, - "country_sr": { "type": "string", "default": "Suriname" }, - "country_sj": { "type": "string", "default": "Svalbard and Jan Mayen" }, - "country_sz": { "type": "string", "default": "Eswatini" }, - "country_se": { "type": "string", "default": "Sweden" }, - "country_ch": { "type": "string", "default": "Switzerland" }, - "country_ch_region_ag": { "type": "string", "default": "Aargau" }, - "country_ch_region_ar": { "type": "string", "default": "Appenzell Ausserrhoden" }, - "country_ch_region_ai": { "type": "string", "default": "Appenzell Innerrhoden" }, - "country_ch_region_bl": { "type": "string", "default": "Basel-Landschaft" }, - "country_ch_region_bs": { "type": "string", "default": "Basel-Stadt" }, - "country_ch_region_be": { "type": "string", "default": "Bern" }, - "country_ch_region_fr": { "type": "string", "default": "Freiburg" }, - "country_ch_region_ge": { "type": "string", "default": "Genf" }, - "country_ch_region_gl": { "type": "string", "default": "Glarus" }, - "country_ch_region_gr": { "type": "string", "default": "Graubuenden" }, - "country_ch_region_ju": { "type": "string", "default": "Jura" }, - "country_ch_region_lu": { "type": "string", "default": "Luzern" }, - "country_ch_region_ne": { "type": "string", "default": "Neuenburg" }, - "country_ch_region_nw": { "type": "string", "default": "Nidwalden" }, - "country_ch_region_ow": { "type": "string", "default": "Obwalden" }, - "country_ch_region_sh": { "type": "string", "default": "Schaffhausen" }, - "country_ch_region_sz": { "type": "string", "default": "Schwyz" }, - "country_ch_region_so": { "type": "string", "default": "Solothurn" }, - "country_ch_region_sg": { "type": "string", "default": "St. Gallen" }, - "country_ch_region_ti": { "type": "string", "default": "Tessin" }, - "country_ch_region_tg": { "type": "string", "default": "Thurgau" }, - "country_ch_region_ur": { "type": "string", "default": "Uri" }, - "country_ch_region_vs": { "type": "string", "default": "Valais" }, - "country_ch_region_vd": { "type": "string", "default": "Vaud" }, - "country_ch_region_zh": { "type": "string", "default": "Zurich" }, - "country_ch_region_zg": { "type": "string", "default": "Zug" }, - "country_sy": { "type": "string", "default": "Syrian Arab Republic" }, - "country_tw": { "type": "string", "default": "Taiwan" }, - "country_tj": { "type": "string", "default": "Tajikistan" }, - "country_tz": { "type": "string", "default": "Tanzania, United Republic of" }, - "country_th": { "type": "string", "default": "Thailand" }, - "country_tl": { "type": "string", "default": "Timor-Leste" }, - "country_tg": { "type": "string", "default": "Togo" }, - "country_tk": { "type": "string", "default": "Tokelau" }, - "country_to": { "type": "string", "default": "Tonga" }, - "country_tt": { "type": "string", "default": "Trinidad and Tobago" }, - "country_tn": { "type": "string", "default": "Tunisia" }, - "country_tr": { "type": "string", "default": "Turkey" }, - "country_tm": { "type": "string", "default": "Turkmenistan" }, - "country_tc": { "type": "string", "default": "Turks and Caicos Islands" }, - "country_tv": { "type": "string", "default": "Tuvalu" }, - "country_ug": { "type": "string", "default": "Uganda" }, - "country_ua": { "type": "string", "default": "Ukraine" }, - "country_ae": { "type": "string", "default": "United Arab Emirates" }, - "country_gb": { "type": "string", "default": "United Kingdom" }, - "country_us": { "type": "string", "default": "United States" }, - "country_us_region_al": { "type": "string", "default": "Alabama" }, - "country_us_region_ak": { "type": "string", "default": "Alaska" }, - "country_us_region_as": { "type": "string", "default": "American Samoa" }, - "country_us_region_az": { "type": "string", "default": "Arizona" }, - "country_us_region_ar": { "type": "string", "default": "Arkansas" }, - "country_us_region_af": { "type": "string", "default": "Armed Forces Africa" }, - "country_us_region_aa": { "type": "string", "default": "Armed Forces Americas" }, - "country_us_region_ac": { "type": "string", "default": "Armed Forces Canada" }, - "country_us_region_ae": { "type": "string", "default": "Armed Forces Europe" }, - "country_us_region_am": { "type": "string", "default": "Armed Forces Middle East" }, - "country_us_region_ap": { "type": "string", "default": "Armed Forces Pacific" }, - "country_us_region_ca": { "type": "string", "default": "California" }, - "country_us_region_co": { "type": "string", "default": "Colorado" }, - "country_us_region_ct": { "type": "string", "default": "Connecticut" }, - "country_us_region_de": { "type": "string", "default": "Delaware" }, - "country_us_region_dc": { "type": "string", "default": "Washington DC" }, - "country_us_region_fm": { - "type": "string", - "default": "Federated States Of Micronesia" - }, - "country_us_region_fl": { "type": "string", "default": "Florida" }, - "country_us_region_ga": { "type": "string", "default": "Georgia" }, - "country_us_region_gu": { "type": "string", "default": "Guam" }, - "country_us_region_hi": { "type": "string", "default": "Hawaii" }, - "country_us_region_id": { "type": "string", "default": "Idaho" }, - "country_us_region_il": { "type": "string", "default": "Illinois" }, - "country_us_region_in": { "type": "string", "default": "Indiana" }, - "country_us_region_ia": { "type": "string", "default": "Iowa" }, - "country_us_region_ks": { "type": "string", "default": "Kansas" }, - "country_us_region_ky": { "type": "string", "default": "Kentucky" }, - "country_us_region_la": { "type": "string", "default": "Louisiana" }, - "country_us_region_me": { "type": "string", "default": "Maine" }, - "country_us_region_mh": { "type": "string", "default": "Marshall Islands" }, - "country_us_region_md": { "type": "string", "default": "Maryland" }, - "country_us_region_ma": { "type": "string", "default": "Massachusetts" }, - "country_us_region_mi": { "type": "string", "default": "Michigan" }, - "country_us_region_mn": { "type": "string", "default": "Minnesota" }, - "country_us_region_ms": { "type": "string", "default": "Mississippi" }, - "country_us_region_mo": { "type": "string", "default": "Missouri" }, - "country_us_region_mt": { "type": "string", "default": "Montana" }, - "country_us_region_ne": { "type": "string", "default": "Nebraska" }, - "country_us_region_nv": { "type": "string", "default": "Nevada" }, - "country_us_region_nh": { "type": "string", "default": "New Hampshire" }, - "country_us_region_nj": { "type": "string", "default": "New Jersey" }, - "country_us_region_nm": { "type": "string", "default": "New Mexico" }, - "country_us_region_ny": { "type": "string", "default": "New York" }, - "country_us_region_nc": { "type": "string", "default": "North Carolina" }, - "country_us_region_nd": { "type": "string", "default": "North Dakota" }, - "country_us_region_mp": { "type": "string", "default": "Northern Mariana Islands" }, - "country_us_region_oh": { "type": "string", "default": "Ohio" }, - "country_us_region_ok": { "type": "string", "default": "Oklahoma" }, - "country_us_region_or": { "type": "string", "default": "Oregon" }, - "country_us_region_pa": { "type": "string", "default": "Pennsylvania" }, - "country_us_region_pr": { "type": "string", "default": "Puerto Rico" }, - "country_us_region_ri": { "type": "string", "default": "Rhode Island" }, - "country_us_region_sc": { "type": "string", "default": "South Carolina" }, - "country_us_region_sd": { "type": "string", "default": "South Dakota" }, - "country_us_region_tn": { "type": "string", "default": "Tennessee" }, - "country_us_region_tx": { "type": "string", "default": "Texas" }, - "country_us_region_ut": { "type": "string", "default": "Utah" }, - "country_us_region_vt": { "type": "string", "default": "Vermont" }, - "country_us_region_vi": { "type": "string", "default": "Virgin Islands" }, - "country_us_region_va": { "type": "string", "default": "Virginia" }, - "country_us_region_wa": { "type": "string", "default": "Washington" }, - "country_us_region_wv": { "type": "string", "default": "West Virginia" }, - "country_us_region_wi": { "type": "string", "default": "Wisconsin" }, - "country_us_region_wy": { "type": "string", "default": "Wyoming" }, - "country_um": { "type": "string", "default": "United States Minor Outlying Islands" }, - "country_uy": { "type": "string", "default": "Uruguay" }, - "country_uz": { "type": "string", "default": "Uzbekistan" }, - "country_vu": { "type": "string", "default": "Vanuatu" }, - "country_ve": { "type": "string", "default": "Venezuela" }, - "country_vn": { "type": "string", "default": "Vietnam" }, - "country_vg": { "type": "string", "default": "Virgin Islands, British" }, - "country_vi": { "type": "string", "default": "Virgin Islands, U.S." }, - "country_wf": { "type": "string", "default": "Wallis and Futuna Islands" }, - "country_eh": { "type": "string", "default": "Western Sahara" }, - "country_ye": { "type": "string", "default": "Yemen" }, - "country_zm": { "type": "string", "default": "Zambia" }, - "country_zw": { "type": "string", "default": "Zimbabwe" } - }, - "required": [ - "address-name", - "first-name", - "last-name", - "company", - "phone", - "address-one", - "address-two", - "city", - "postal-code", - "country", - "region", - "timestamps", - "delete", - "create", - "spinner", - "country_af", - "country_ax", - "country_al", - "country_dz", - "country_as", - "country_ad", - "country_ao", - "country_ai", - "country_aq", - "country_ag", - "country_ar", - "country_am", - "country_aw", - "country_au", - "country_au_region_act", - "country_au_region_nsw", - "country_au_region_nt", - "country_au_region_qld", - "country_au_region_sa", - "country_au_region_tas", - "country_au_region_vic", - "country_au_region_wa", - "country_at", - "country_at_region_bl", - "country_at_region_kn", - "country_at_region_no", - "country_at_region_oo", - "country_at_region_sb", - "country_at_region_st", - "country_at_region_ti", - "country_at_region_vb", - "country_at_region_wi", - "country_az", - "country_bs", - "country_bh", - "country_bd", - "country_bb", - "country_by", - "country_be", - "country_bz", - "country_bj", - "country_bm", - "country_bt", - "country_bo", - "country_bq", - "country_bq_region_bo", - "country_bq_region_sa", - "country_bq_region_se", - "country_ba", - "country_bw", - "country_bv", - "country_br", - "country_io", - "country_bn", - "country_bg", - "country_bf", - "country_bi", - "country_kh", - "country_cm", - "country_ca", - "country_ca_region_ab", - "country_ca_region_bc", - "country_ca_region_mb", - "country_ca_region_nb", - "country_ca_region_nl", - "country_ca_region_nt", - "country_ca_region_ns", - "country_ca_region_nu", - "country_ca_region_on", - "country_ca_region_pe", - "country_ca_region_qc", - "country_ca_region_sk", - "country_ca_region_yt", - "country_cv", - "country_cw", - "country_ky", - "country_cf", - "country_td", - "country_cl", - "country_cn", - "country_cx", - "country_cc", - "country_co", - "country_km", - "country_cg", - "country_cd", - "country_ck", - "country_cr", - "country_ci", - "country_hr", - "country_cu", - "country_cy", - "country_cz", - "country_dk", - "country_dj", - "country_dm", - "country_do", - "country_ec", - "country_eg", - "country_sv", - "country_sx", - "country_gq", - "country_er", - "country_ee", - "country_et", - "country_fk", - "country_fo", - "country_fj", - "country_fi", - "country_fr", - "country_gf", - "country_pf", - "country_tf", - "country_ga", - "country_gm", - "country_ge", - "country_de", - "country_de_region_bw", - "country_de_region_by", - "country_de_region_be", - "country_de_region_bb", - "country_de_region_hb", - "country_de_region_hh", - "country_de_region_he", - "country_de_region_mv", - "country_de_region_ni", - "country_de_region_nw", - "country_de_region_rp", - "country_de_region_sl", - "country_de_region_sn", - "country_de_region_st", - "country_de_region_sh", - "country_de_region_th", - "country_gh", - "country_gi", - "country_gr", - "country_gl", - "country_gd", - "country_gp", - "country_gu", - "country_gt", - "country_gg", - "country_gn", - "country_gw", - "country_gy", - "country_ht", - "country_hm", - "country_va", - "country_hn", - "country_hk", - "country_hu", - "country_is", - "country_in", - "country_in_region_an", - "country_in_region_ap", - "country_in_region_ar", - "country_in_region_as", - "country_in_region_br", - "country_in_region_ch", - "country_in_region_ct", - "country_in_region_dn", - "country_in_region_dd", - "country_in_region_dl", - "country_in_region_ga", - "country_in_region_gj", - "country_in_region_hr", - "country_in_region_hp", - "country_in_region_jk", - "country_in_region_jh", - "country_in_region_ka", - "country_in_region_kl", - "country_in_region_ld", - "country_in_region_mp", - "country_in_region_mh", - "country_in_region_mn", - "country_in_region_ml", - "country_in_region_mz", - "country_in_region_nl", - "country_in_region_or", - "country_in_region_py", - "country_in_region_pb", - "country_in_region_rj", - "country_in_region_sk", - "country_in_region_tn", - "country_in_region_tg", - "country_in_region_tr", - "country_in_region_ut", - "country_in_region_up", - "country_in_region_wb", - "country_id", - "country_ir", - "country_iq", - "country_ie", - "country_ie_region_cw", - "country_ie_region_cn", - "country_ie_region_ce", - "country_ie_region_co", - "country_ie_region_dl", - "country_ie_region_d", - "country_ie_region_g", - "country_ie_region_ky", - "country_ie_region_ke", - "country_ie_region_kk", - "country_ie_region_ls", - "country_ie_region_lm", - "country_ie_region_lk", - "country_ie_region_ld", - "country_ie_region_lh", - "country_ie_region_mo", - "country_ie_region_mh", - "country_ie_region_mn", - "country_ie_region_oy", - "country_ie_region_rn", - "country_ie_region_so", - "country_ie_region_ta", - "country_ie_region_wd", - "country_ie_region_wh", - "country_ie_region_wx", - "country_ie_region_ww", - "country_im", - "country_il", - "country_it", - "country_jm", - "country_jp", - "country_jp_region_10", - "country_jp_region_11", - "country_jp_region_12", - "country_jp_region_13", - "country_jp_region_14", - "country_jp_region_15", - "country_jp_region_16", - "country_jp_region_17", - "country_jp_region_18", - "country_jp_region_19", - "country_jp_region_20", - "country_jp_region_21", - "country_jp_region_22", - "country_jp_region_23", - "country_jp_region_24", - "country_jp_region_25", - "country_jp_region_26", - "country_jp_region_27", - "country_jp_region_28", - "country_jp_region_29", - "country_jp_region_30", - "country_jp_region_31", - "country_jp_region_32", - "country_jp_region_33", - "country_jp_region_34", - "country_jp_region_35", - "country_jp_region_36", - "country_jp_region_37", - "country_jp_region_38", - "country_jp_region_39", - "country_jp_region_40", - "country_jp_region_41", - "country_jp_region_42", - "country_jp_region_43", - "country_jp_region_44", - "country_jp_region_45", - "country_jp_region_46", - "country_jp_region_47", - "country_jp_region_05", - "country_jp_region_02", - "country_jp_region_07", - "country_jp_region_01", - "country_jp_region_08", - "country_jp_region_03", - "country_jp_region_04", - "country_jp_region_09", - "country_jp_region_06", - "country_je", - "country_jo", - "country_kz", - "country_ke", - "country_ki", - "country_kp", - "country_kr", - "country_kw", - "country_kg", - "country_la", - "country_lv", - "country_lb", - "country_ls", - "country_lr", - "country_ly", - "country_li", - "country_lt", - "country_lu", - "country_mo", - "country_mk", - "country_mg", - "country_mw", - "country_my", - "country_mv", - "country_ml", - "country_mt", - "country_mh", - "country_mq", - "country_mr", - "country_mu", - "country_yt", - "country_mx", - "country_fm", - "country_md", - "country_mc", - "country_mn", - "country_me", - "country_ms", - "country_ma", - "country_mz", - "country_mm", - "country_na", - "country_nr", - "country_np", - "country_nl", - "country_nc", - "country_nz", - "country_ni", - "country_ne", - "country_ng", - "country_nu", - "country_nf", - "country_mp", - "country_no", - "country_no_region_10", - "country_no_region_11", - "country_no_region_12", - "country_no_region_14", - "country_no_region_15", - "country_no_region_16", - "country_no_region_17", - "country_no_region_18", - "country_no_region_19", - "country_no_region_20", - "country_no_region_30", - "country_no_region_34", - "country_no_region_38", - "country_no_region_42", - "country_no_region_46", - "country_no_region_50", - "country_no_region_54", - "country_no_region_01", - "country_no_region_02", - "country_no_region_03", - "country_no_region_04", - "country_no_region_05", - "country_no_region_06", - "country_no_region_07", - "country_no_region_08", - "country_no_region_09", - "country_om", - "country_pk", - "country_pw", - "country_ps", - "country_pa", - "country_pg", - "country_py", - "country_pe", - "country_ph", - "country_pn", - "country_pl", - "country_pt", - "country_pr", - "country_qa", - "country_re", - "country_ro", - "country_ru", - "country_rw", - "country_bl", - "country_sh", - "country_kn", - "country_lc", - "country_mf", - "country_pm", - "country_vc", - "country_ws", - "country_sm", - "country_ss", - "country_st", - "country_sa", - "country_sn", - "country_rs", - "country_sc", - "country_sl", - "country_sg", - "country_sk", - "country_si", - "country_sb", - "country_so", - "country_za", - "country_gs", - "country_es", - "country_es_region_a coruna", - "country_es_region_alava", - "country_es_region_albacete", - "country_es_region_alicante", - "country_es_region_almeria", - "country_es_region_asturias", - "country_es_region_avila", - "country_es_region_badajoz", - "country_es_region_baleares", - "country_es_region_barcelona", - "country_es_region_burgos", - "country_es_region_caceres", - "country_es_region_cadiz", - "country_es_region_cn", - "country_es_region_cantabria", - "country_es_region_castellon", - "country_es_region_ceuta", - "country_es_region_ciudad real", - "country_es_region_cordoba", - "country_es_region_cuenca", - "country_es_region_gipuzkoa", - "country_es_region_girona", - "country_es_region_granada", - "country_es_region_guadalajara", - "country_es_region_guipuzcoa", - "country_es_region_huelva", - "country_es_region_huesca", - "country_es_region_jaen", - "country_es_region_la rioja", - "country_es_region_las palmas", - "country_es_region_leon", - "country_es_region_lleida", - "country_es_region_lugo", - "country_es_region_madrid", - "country_es_region_malaga", - "country_es_region_melilla", - "country_es_region_murcia", - "country_es_region_navarra", - "country_es_region_ourense", - "country_es_region_palencia", - "country_es_region_pontevedra", - "country_es_region_salamanca", - "country_es_region_santa cruz de tenerife", - "country_es_region_segovia", - "country_es_region_sevilla", - "country_es_region_soria", - "country_es_region_tarragona", - "country_es_region_teruel", - "country_es_region_toledo", - "country_es_region_valencia", - "country_es_region_valladolid", - "country_es_region_vizcaya", - "country_es_region_zamora", - "country_es_region_zaragoza", - "country_lk", - "country_sd", - "country_sr", - "country_sj", - "country_sz", - "country_se", - "country_ch", - "country_ch_region_ag", - "country_ch_region_ar", - "country_ch_region_ai", - "country_ch_region_bl", - "country_ch_region_bs", - "country_ch_region_be", - "country_ch_region_fr", - "country_ch_region_ge", - "country_ch_region_gl", - "country_ch_region_gr", - "country_ch_region_ju", - "country_ch_region_lu", - "country_ch_region_ne", - "country_ch_region_nw", - "country_ch_region_ow", - "country_ch_region_sh", - "country_ch_region_sz", - "country_ch_region_so", - "country_ch_region_sg", - "country_ch_region_ti", - "country_ch_region_tg", - "country_ch_region_ur", - "country_ch_region_vs", - "country_ch_region_vd", - "country_ch_region_zh", - "country_ch_region_zg", - "country_sy", - "country_tw", - "country_tj", - "country_tz", - "country_th", - "country_tl", - "country_tg", - "country_tk", - "country_to", - "country_tt", - "country_tn", - "country_tr", - "country_tm", - "country_tc", - "country_tv", - "country_ug", - "country_ua", - "country_ae", - "country_gb", - "country_us", - "country_us_region_al", - "country_us_region_ak", - "country_us_region_as", - "country_us_region_az", - "country_us_region_ar", - "country_us_region_af", - "country_us_region_aa", - "country_us_region_ac", - "country_us_region_ae", - "country_us_region_am", - "country_us_region_ap", - "country_us_region_ca", - "country_us_region_co", - "country_us_region_ct", - "country_us_region_de", - "country_us_region_dc", - "country_us_region_fm", - "country_us_region_fl", - "country_us_region_ga", - "country_us_region_gu", - "country_us_region_hi", - "country_us_region_id", - "country_us_region_il", - "country_us_region_in", - "country_us_region_ia", - "country_us_region_ks", - "country_us_region_ky", - "country_us_region_la", - "country_us_region_me", - "country_us_region_mh", - "country_us_region_md", - "country_us_region_ma", - "country_us_region_mi", - "country_us_region_mn", - "country_us_region_ms", - "country_us_region_mo", - "country_us_region_mt", - "country_us_region_ne", - "country_us_region_nv", - "country_us_region_nh", - "country_us_region_nj", - "country_us_region_nm", - "country_us_region_ny", - "country_us_region_nc", - "country_us_region_nd", - "country_us_region_mp", - "country_us_region_oh", - "country_us_region_ok", - "country_us_region_or", - "country_us_region_pa", - "country_us_region_pr", - "country_us_region_ri", - "country_us_region_sc", - "country_us_region_sd", - "country_us_region_tn", - "country_us_region_tx", - "country_us_region_ut", - "country_us_region_vt", - "country_us_region_vi", - "country_us_region_va", - "country_us_region_wa", - "country_us_region_wv", - "country_us_region_wi", - "country_us_region_wy", - "country_um", - "country_uy", - "country_uz", - "country_vu", - "country_ve", - "country_vn", - "country_vg", - "country_vi", - "country_wf", - "country_eh", - "country_ye", - "country_zm", - "country_zw" - ] - }, - "customer-form": { - "additionalProperties": false, - "properties": { - "cancel": { "type": "string", "default": "Cancel" }, - "close": { "type": "string", "default": "Close" }, - "message": { - "additionalProperties": false, - "properties": { - "password_change_success": { - "type": "string", - "default": "You have successfully set a new password for your account." - }, - "close": { "type": "string", "default": "Close" } - }, - "required": ["password_change_success", "close"] - }, - "error": { - "additionalProperties": false, - "properties": { - "old_password_incorrect": { - "type": "string", - "default": "The old password you entered is incorrect. Please try again." - }, - "email_already_used": { - "type": "string", - "default": "This email is already in use. Please use a different email." - } - }, - "required": ["old_password_incorrect", "email_already_used"] - }, - "first-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "First name" }, - "placeholder": { "type": "string", "default": "Not set" }, - "helper_text": { "type": "string", "default": "Your given name, optional." }, - "v8n_too_long": { - "type": "string", - "default": "We can't store first names longer than 50 characters." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "last-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Last name" }, - "placeholder": { "type": "string", "default": "Not set" }, - "helper_text": { "type": "string", "default": "Your surname, optional." }, - "v8n_too_long": { - "type": "string", - "default": "We can't store last names longer than 50 characters." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "tax-id": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Tax ID" }, - "placeholder": { "type": "string", "default": "Not set" }, - "helper_text": { - "type": "string", - "default": "Your tax identification number, optional." - }, - "v8n_too_long": { - "type": "string", - "default": "We can't store tax IDs longer than 50 characters." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "email": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Email" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "We'll use this email as the login to the Checkout and Customer Portal." - }, - "helper_text_last_login_date": { - "type": "string", - "default": "Your login to the Checkout and Customer Portal. Last used on {{ date, date }} at {{ date, time }}." - }, - "v8n_too_long": { - "type": "string", - "default": "We can't store emails longer than 100 characters." - }, - "v8n_invalid_email": { "type": "string", "default": "This email is invalid." }, - "v8n_required": { "type": "string", "default": "Please fill out this field." } - }, - "required": [ - "label", - "placeholder", - "helper_text", - "helper_text_last_login_date", - "v8n_too_long", - "v8n_invalid_email", - "v8n_required" - ] - }, - "password": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Password" }, - "placeholder": { "type": "string", "default": "Required" }, - "placeholder_new": { "type": "string", "default": "Keep current password" }, - "helper_text_new": { - "type": "string", - "default": "To change your password, enter a new password here. If you leave this field blank, your password will remain the same." - }, - "v8n_too_long": { - "type": "string", - "default": "Please use a password that is no longer than 50 characters." - }, - "v8n_too_weak": { - "type": "string", - "default": "Please use a stronger password. To make this password stronger, make it at least 8 characters long and include a few upper and lower case letters, numbers, and special characters." - }, - "v8n_required": { "type": "string", "default": "Please fill out this field." } - }, - "required": [ - "label", - "placeholder", - "placeholder_new", - "helper_text_new", - "v8n_too_long", - "v8n_too_weak", - "v8n_required" - ] - }, - "password-old": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Old password" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { - "type": "string", - "default": "Enter your old password to confirm password change." - }, - "v8n_required": { "type": "string", "default": "Please fill out this field." } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "date": { "type": "string", "default": "{{value, date}}" } - }, - "required": ["date_created", "date_modified", "date"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "cancel", - "close", - "message", - "error", - "first-name", - "last-name", - "tax-id", - "email", - "password", - "password-old", - "timestamps", - "spinner" - ] - }, - "payment-method-card": { - "additionalProperties": false, - "properties": { - "cancel": { "type": "string", "default": "Cancel" }, - "delete": { "type": "string", "default": "Delete" }, - "add": { "type": "string", "default": "Add payment method" }, - "update": { "type": "string", "default": "Update payment method" }, - "delete_prompt": { - "type": "string", - "default": "This payment method will be permanently deleted from your account. Would you like to continue?" - }, - "expires": { "type": "string", "default": "Expires" }, - "last_4_digits": { "type": "string", "default": "Last 4 digits" }, - "unknown": { "type": "string", "default": "Unknown" }, - "dialog": { - "additionalProperties": false, - "properties": { - "close": { "type": "string", "default": "Close" }, - "dialog_header_add": { "type": "string", "default": "Add payment method" }, - "dialog_header_update": { "type": "string", "default": "Update payment method" }, - "update-payment-method-form": { - "additionalProperties": false, - "properties": { - "status": { - "additionalProperties": false, - "properties": { - "cc_token_success": { - "type": "string", - "default": "Card details saved successfully." - }, - "close": { "type": "string", "default": "Close" } - }, - "required": ["cc_token_success", "close"] - }, - "error": { - "additionalProperties": false, - "properties": { - "cc_token_invalid": { - "type": "string", - "default": "Unfortunately, we couldn't save your card details. Please try again later or use a different card." - } - }, - "required": ["cc_token_invalid"] - }, - "template-set": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Template set" }, - "dialog": { - "additionalProperties": false, - "properties": { - "cancel": { "type": "string", "default": "Cancel" }, - "close": { "type": "string", "default": "Close" }, - "header": { "type": "string", "default": "Choose a template set" }, - "selection": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" }, - "search": { "type": "string", "default": "Search" }, - "clear": { "type": "string", "default": "Clear" }, - "pagination": { - "additionalProperties": false, - "properties": { - "search_button_text": { "type": "string", "default": "Search" }, - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { - "type": "string", - "default": "{{from}}-{{to}} out of {{total}}" - }, - "previous": { "type": "string", "default": "Previous" }, - "card": { - "additionalProperties": false, - "properties": { - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { - "type": "string", - "default": "Loading" - }, - "loading_empty": { - "type": "string", - "default": "No template sets found" - }, - "loading_error": { - "type": "string", - "default": "Unknown error" - } - }, - "required": [ - "loading_busy", - "loading_empty", - "loading_error" - ] - } - }, - "required": ["spinner"] - } - }, - "required": [ - "search_button_text", - "first", - "last", - "next", - "pagination", - "previous", - "card" - ] - }, - "query-builder": { - "additionalProperties": false, - "properties": { - "filters": { - "additionalProperties": false, - "properties": {}, - "required": [] - }, - "add_or_clause": { - "type": "string", - "default": "Add OR clause" - }, - "add_value": { "type": "string", "default": "Add value" }, - "code": { "type": "string", "default": "Code" }, - "date": { "type": "string", "default": "{{value, date}}" }, - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { - "type": "string", - "default": "Last updated on" - }, - "delete": { "type": "string", "default": "Delete" }, - "field": { "type": "string", "default": "Field" }, - "hidden": { "type": "string", "default": "Hidden" }, - "is_defined_false": { - "type": "string", - "default": "Not defined" - }, - "is_defined_true": { "type": "string", "default": "Defined" }, - "name": { "type": "string", "default": "Name" }, - "operator_equal": { "type": "string", "default": "Equal" }, - "operator_greaterthan": { - "type": "string", - "default": "Greater than" - }, - "operator_greaterthanorequal": { - "type": "string", - "default": "Greater than or equal" - }, - "operator_in": { "type": "string", "default": "One of" }, - "operator_isdefined": { - "type": "string", - "default": "Is defined" - }, - "operator_lessthan": { - "type": "string", - "default": "Less than" - }, - "operator_lessthanorequal": { - "type": "string", - "default": "Less than or equal" - }, - "operator_not": { "type": "string", "default": "Not equal" }, - "or": { "type": "string", "default": "Or" }, - "query_builder_group": { - "type": "string", - "default": "Group of filters" - }, - "query_builder_rule": { "type": "string", "default": "Filter" }, - "range_from": { "type": "string", "default": "From" }, - "range_to": { "type": "string", "default": "To" }, - "type": { "type": "string", "default": "Type" }, - "type_any": { - "type": "string", - "default": "Field of unknown type" - }, - "type_attribute": { - "type": "string", - "default": "Key-value resource" - }, - "type_date": { "type": "string", "default": "Date field" }, - "type_here": { "type": "string", "default": "Type here..." }, - "type_number": { "type": "string", "default": "Numeric field" }, - "type_string": { "type": "string", "default": "Text field" }, - "used_codes": { "type": "string", "default": "Codes used" }, - "value": { "type": "string", "default": "Value" } - }, - "required": [ - "filters", - "add_or_clause", - "add_value", - "code", - "date", - "date_created", - "date_modified", - "delete", - "field", - "hidden", - "is_defined_false", - "is_defined_true", - "name", - "operator_equal", - "operator_greaterthan", - "operator_greaterthanorequal", - "operator_in", - "operator_isdefined", - "operator_lessthan", - "operator_lessthanorequal", - "operator_not", - "or", - "query_builder_group", - "query_builder_rule", - "range_from", - "range_to", - "type", - "type_any", - "type_attribute", - "type_date", - "type_here", - "type_number", - "type_string", - "used_codes", - "value" - ] - } - }, - "required": [ - "label", - "helper_text", - "search", - "clear", - "pagination", - "query-builder" - ] - } - }, - "required": ["cancel", "close", "header", "selection"] - }, - "card": { - "additionalProperties": false, - "properties": { - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "Click to select" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["spinner"] - }, - "helper_text": { - "type": "string", - "default": "Template set determines which payment gateway and tokenization service will be used to capture card details." - } - }, - "required": ["label", "dialog", "card", "helper_text"] - }, - "cc-token": { - "additionalProperties": false, - "properties": { - "clear": { "type": "string", "default": "Clear" }, - "tokenize": { "type": "string", "default": "Save card" }, - "payment-card-embed": { - "additionalProperties": false, - "properties": { - "stripe": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Card details" }, - "status": { - "additionalProperties": false, - "properties": { - "idle": { - "type": "string", - "default": "Your card details are securely processed by Stripe. Visit https://stripe.com to learn more." - }, - "busy": { - "type": "string", - "default": "Encrypting your card details..." - }, - "fail": { - "type": "string", - "default": "This service is currently unavailable. Please try again later." - }, - "unsupported": { - "type": "string", - "default": "We don't support this card type. Please try another card." - } - }, - "required": ["idle", "busy", "fail", "unsupported"] - } - }, - "required": ["label", "status"] - }, - "square": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Card details" }, - "status": { - "additionalProperties": false, - "properties": { - "idle": { - "type": "string", - "default": "Your card details are securely processed by Square. Visit https://squareup.com to learn more." - }, - "busy": { - "type": "string", - "default": "Encrypting your card details..." - }, - "fail": { - "type": "string", - "default": "This service is currently unavailable. Please try again later." - }, - "unsupported": { - "type": "string", - "default": "We don't support this card type. Please try another card." - } - }, - "required": ["idle", "busy", "fail", "unsupported"] - } - }, - "required": ["label", "status"] - }, - "default": { - "additionalProperties": false, - "properties": { - "cc-number": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Card number" }, - "placeholder": { - "type": "string", - "default": "1234 1234 1234 1234" - }, - "v8n_required": { - "type": "string", - "default": "Enter a card number." - }, - "v8n_invalid": { - "type": "string", - "default": "Check your card number – it doesn't seem to be valid." - }, - "v8n_unsupported": { - "type": "string", - "default": "We don't support this card type." - } - }, - "required": [ - "label", - "placeholder", - "v8n_required", - "v8n_invalid", - "v8n_unsupported" - ] - }, - "cc-exp": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Expires on" }, - "placeholder": { "type": "string", "default": "MM/YYYY" }, - "v8n_required": { - "type": "string", - "default": "Enter an expiry date." - }, - "v8n_invalid": { - "type": "string", - "default": "Enter a date as MM/YYYY." - }, - "v8n_expired": { - "type": "string", - "default": "Your card has expired." - } - }, - "required": [ - "label", - "placeholder", - "v8n_required", - "v8n_invalid", - "v8n_expired" - ] - }, - "cc-csc": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "CSC" }, - "placeholder": { "type": "string", "default": "XXX" }, - "v8n_required": { - "type": "string", - "default": "Enter a security code." - }, - "v8n_invalid": { - "type": "string", - "default": "Enter a 3-4 digits code." - } - }, - "required": [ - "label", - "placeholder", - "v8n_required", - "v8n_invalid" - ] - }, - "status": { - "additionalProperties": false, - "properties": { - "idle": { - "type": "string", - "default": "Your card details are securely processed by Foxy.io. Visit https://foxy.io to learn more." - }, - "busy": { - "type": "string", - "default": "Encrypting your card details..." - }, - "fail": { - "type": "string", - "default": "This service is currently unavailable. Please try again later." - }, - "misconfigured": { - "type": "string", - "default": "This form is not configured correctly. If you are seeing this message as a customer, please report this issue to the store support team." - } - }, - "required": ["idle", "busy", "fail", "misconfigured"] - } - }, - "required": ["cc-number", "cc-exp", "cc-csc", "status"] - } - }, - "required": ["stripe", "square", "default"] - } - }, - "required": ["clear", "tokenize", "payment-card-embed"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" }, - "loading_empty": { - "type": "string", - "default": "This form works only with existing payment methods" - } - }, - "required": ["refresh", "loading_busy", "loading_error", "loading_empty"] - } - }, - "required": ["status", "error", "template-set", "cc-token", "spinner"] - } - }, - "required": [ - "close", - "dialog_header_add", - "dialog_header_update", - "update-payment-method-form" - ] - } - }, - "required": [ - "cancel", - "delete", - "add", - "update", - "delete_prompt", - "expires", - "last_4_digits", - "unknown", - "dialog" - ] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - }, - "subscription-card": { - "additionalProperties": false, - "properties": { - "daily": { "type": "string", "default": "/ day" }, - "daily_plural": { "type": "string", "default": "/ {{count}} days" }, - "frequency": { - "type": "string", - "default": "$t(customer.subscription-card.{{units}}, { \"count\": {{count}}, \"ns\": \"customer-portal\" })" - }, - "monthly": { "type": "string", "default": "/ month" }, - "monthly_plural": { "type": "string", "default": "/ {{count}} months" }, - "price_recurring": { - "type": "string", - "default": "{{amount, price}} $t(customer.subscription-card.frequency, { \"count\": \"{{count}}\", \"units\": \"{{units}}\", \"ns\": \"customer-portal\" })" - }, - "price_twice_a_month": { - "type": "string", - "default": "{{amount, price}} $t(customer.subscription-card.twice_a_month, { \"ns\": \"customer-portal\" })" - }, - "subscription_active": { - "type": "string", - "default": "Next payment on {{date, date}}" - }, - "subscription_cancelled": { "type": "string", "default": "Ended on {{date, date}}" }, - "subscription_failed": { - "type": "string", - "default": "Payment failed on {{date, date}}" - }, - "subscription_inactive": { "type": "string", "default": "Inactive" }, - "subscription_will_be_cancelled": { - "type": "string", - "default": "Ends on {{date, date}}" - }, - "subscription_will_be_active": { - "type": "string", - "default": "Starts on {{date, date}}" - }, - "transaction_summary": { "type": "string", "default": "{{most_expensive_item.name}}" }, - "fees_hint": { "type": "string", "default": "inc. shipping, taxes, etc." }, - "fees_explainer": { - "type": "string", - "default": "Taxes, shipping, and discounts may change the amount charged." - }, - "twice_a_month": { "type": "string", "default": "twice a month" }, - "weekly": { "type": "string", "default": "/ week" }, - "weekly_plural": { "type": "string", "default": "/ {{count}} weeks" }, - "yearly": { "type": "string", "default": "/ year" }, - "yearly_plural": { "type": "string", "default": "/ {{count}} years" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No subscriptions" }, - "loading_end": { "type": "string", "default": "No more data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_end", "loading_error"] - } - }, - "required": [ - "daily", - "daily_plural", - "frequency", - "monthly", - "monthly_plural", - "price_recurring", - "price_twice_a_month", - "subscription_active", - "subscription_cancelled", - "subscription_failed", - "subscription_inactive", - "subscription_will_be_cancelled", - "subscription_will_be_active", - "transaction_summary", - "fees_hint", - "fees_explainer", - "twice_a_month", - "weekly", - "weekly_plural", - "yearly", - "yearly_plural", - "spinner" - ] - }, - "subscription-form": { - "additionalProperties": false, - "properties": { - "day": { "type": "string", "default": "Day" }, - "day_plural": { "type": "string", "default": "Days" }, - "week": { "type": "string", "default": "Week" }, - "week_plural": { "type": "string", "default": "Weeks" }, - "month": { "type": "string", "default": "Month" }, - "month_plural": { "type": "string", "default": "Months" }, - "year": { "type": "string", "default": "Year" }, - "year_plural": { "type": "string", "default": "Years" }, - "cancel": { "type": "string", "default": "Cancel" }, - "close": { "type": "string", "default": "Close" }, - "confirm": { "type": "string", "default": "Confirm" }, - "currency": { "type": "string", "default": "Currency" }, - "daily": { "type": "string", "default": "Daily" }, - "daily_plural": { "type": "string", "default": "Every {{count}} days" }, - "end_subscription": { "type": "string", "default": "End subscription" }, - "frequency": { - "type": "string", - "default": "$t(customer.subscription-form.{{units}}, { \"count\": {{count}}, \"ns\": \"customer-portal\" })" - }, - "frequency_label": { "type": "string", "default": "Frequency" }, - "item_plural": { "type": "string", "default": "Items" }, - "monthly": { "type": "string", "default": "Monthly" }, - "monthly_plural": { "type": "string", "default": "Every {{count}} months" }, - "next_transaction_date": { "type": "string", "default": "Next transaction date" }, - "price_recurring": { - "type": "string", - "default": "{{amount, price}} $t(customer.subscription-form.frequency, { \"count\": \"{{count}}\", \"units\": \"{{units}}\", \"ns\": \"customer-portal\" })" - }, - "price_twice_a_month": { - "type": "string", - "default": "{{amount, price}} $t(customer.subscription-form.twice_a_month, { \"ns\": \"customer-portal\" })" - }, - "subscription_active": { - "type": "string", - "default": "Including shipping, taxes, etc. Next payment on {{date, date}}." - }, - "subscription_cancelled": { - "type": "string", - "default": "Including shipping, taxes, etc. Ended on {{date, date}}." - }, - "subscription_failed": { - "type": "string", - "default": "Including shipping, taxes, etc. Payment failed on {{date, date}}." - }, - "subscription_inactive": { - "type": "string", - "default": "Including shipping, taxes, etc. Inactive." - }, - "subscription_will_be_cancelled": { - "type": "string", - "default": "Including shipping, taxes, etc. Ends on {{date, date}}." - }, - "subscription_will_be_active": { - "type": "string", - "default": "Including shipping, taxes, etc. Starts on {{date, date}}." - }, - "transaction_plural": { "type": "string", "default": "Transactions" }, - "twice_a_month": { "type": "string", "default": "Twice a month" }, - "update_billing": { "type": "string", "default": "Update billing" }, - "update_items": { "type": "string", "default": "Edit" }, - "undo_cancel": { "type": "string", "default": "Review" }, - "undo_confirm": { "type": "string", "default": "Discard" }, - "undo_header": { "type": "string", "default": "Unsaved changes" }, - "undo_message": { - "type": "string", - "default": "Looks like you didn't save your changes! What would you like to do with them?" - }, - "weekly": { "type": "string", "default": "Weekly" }, - "weekly_plural": { "type": "string", "default": "Every {{count}} weeks" }, - "yearly": { "type": "string", "default": "Yearly" }, - "yearly_plural": { "type": "string", "default": "Every {{count}} years" }, - "items": { - "additionalProperties": false, - "properties": { - "pagination": { - "additionalProperties": false, - "properties": { - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { - "type": "string", - "default": "{{from}}-{{to}} out of {{total}}" - }, - "previous": { "type": "string", "default": "Previous" }, - "card": { - "additionalProperties": false, - "properties": { - "daily": { "type": "string", "default": "Daily" }, - "daily_plural": { "type": "string", "default": "Every {{count}} days" }, - "frequency": { - "type": "string", - "default": "$t(customer.subscription-form.items.pagination.card.{{units}}, { \"count\": {{count}}, \"ns\": \"customer-portal\" })" - }, - "monthly": { "type": "string", "default": "Monthly" }, - "monthly_plural": { "type": "string", "default": "Every {{count}} months" }, - "subinfo_recurring": { - "type": "string", - "default": "$t(customer.subscription-form.items.pagination.card.frequency, { \"count\": \"{{count}}\", \"units\": \"{{units}}\", \"ns\": \"customer-portal\" }) from {{startDate, date}}" - }, - "subinfo_twice_a_month": { - "type": "string", - "default": "$t(customer.subscription-form.items.pagination.card.twice_a_month, { \"ns\": \"customer-portal\" }) from {{startDate, date}}" - }, - "twice_a_month": { "type": "string", "default": "Twice a month" }, - "no_code": { "type": "string", "default": "No SKU" }, - "weekly": { "type": "string", "default": "Weekly" }, - "weekly_plural": { "type": "string", "default": "Every {{count}} weeks" }, - "yearly": { "type": "string", "default": "Yearly" }, - "yearly_plural": { "type": "string", "default": "Every {{count}} years" }, - "price": { "type": "string", "default": "{{amount, price}}" }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No items" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "daily", - "daily_plural", - "frequency", - "monthly", - "monthly_plural", - "subinfo_recurring", - "subinfo_twice_a_month", - "twice_a_month", - "no_code", - "weekly", - "weekly_plural", - "yearly", - "yearly_plural", - "price", - "spinner" - ] - } - }, - "required": ["first", "last", "next", "pagination", "previous", "card"] - } - }, - "required": ["pagination"] - }, - "transactions": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Transactions" }, - "pagination": { - "additionalProperties": false, - "properties": { - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { - "type": "string", - "default": "{{from}}-{{to}} out of {{total}}" - }, - "previous": { "type": "string", "default": "Previous" }, - "card": { - "additionalProperties": false, - "properties": { - "code": { "type": "string", "default": "Code" }, - "customer": { "type": "string", "default": "Customer" }, - "description": { "type": "string", "default": "Description" }, - "price": { "type": "string", "default": "{{amount, price}}" }, - "time": { "type": "string", "default": "{{value, date}}" }, - "status_capturing": { "type": "string", "default": "Capturing" }, - "status_captured": { "type": "string", "default": "Captured" }, - "status_approved": { "type": "string", "default": "Approved" }, - "status_authorized": { "type": "string", "default": "Authorized" }, - "status_pending": { "type": "string", "default": "Pending" }, - "status_completed": { "type": "string", "default": "Completed" }, - "status_problem": { "type": "string", "default": "Problem" }, - "status_pending_fraud_review": { - "type": "string", - "default": "Pending_fraud_review" - }, - "status_rejected": { "type": "string", "default": "Rejected" }, - "status_declined": { "type": "string", "default": "Declined" }, - "status_refunding": { "type": "string", "default": "Refunding" }, - "status_refunded": { "type": "string", "default": "Refunded" }, - "status_voided": { "type": "string", "default": "Voided" }, - "status_verified": { "type": "string", "default": "Verified" }, - "summary": { "type": "string", "default": "{{most_expensive_item.name}}" }, - "summary_plural": { - "type": "string", - "default": "{{most_expensive_item.name}} and {{count_minus_one}} more" - }, - "summary_payment_method_change": { - "type": "string", - "default": "Payment method change" - }, - "summary_subscription_modification": { - "type": "string", - "default": "Subscription modification" - }, - "summary_subscription_cancellation": { - "type": "string", - "default": "Subscription cancellation" - }, - "source_MIT": { - "type": "string", - "default": "This transaction was initiated by the merchant" - }, - "source_CIT": { - "type": "string", - "default": "This transaction was initiated by the customer" - }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No transactions" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "code", - "customer", - "description", - "price", - "time", - "status_capturing", - "status_captured", - "status_approved", - "status_authorized", - "status_pending", - "status_completed", - "status_problem", - "status_pending_fraud_review", - "status_rejected", - "status_declined", - "status_refunding", - "status_refunded", - "status_voided", - "status_verified", - "summary", - "summary_plural", - "summary_payment_method_change", - "summary_subscription_modification", - "summary_subscription_cancellation", - "source_MIT", - "source_CIT", - "spinner" - ] - } - }, - "required": ["first", "last", "next", "pagination", "previous", "card"] - } - }, - "required": ["label", "pagination"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "day", - "day_plural", - "week", - "week_plural", - "month", - "month_plural", - "year", - "year_plural", - "cancel", - "close", - "confirm", - "currency", - "daily", - "daily_plural", - "end_subscription", - "frequency", - "frequency_label", - "item_plural", - "monthly", - "monthly_plural", - "next_transaction_date", - "price_recurring", - "price_twice_a_month", - "subscription_active", - "subscription_cancelled", - "subscription_failed", - "subscription_inactive", - "subscription_will_be_cancelled", - "subscription_will_be_active", - "transaction_plural", - "twice_a_month", - "update_billing", - "update_items", - "undo_cancel", - "undo_confirm", - "undo_header", - "undo_message", - "weekly", - "weekly_plural", - "yearly", - "yearly_plural", - "items", - "transactions", - "spinner" - ] - } - }, - "required": [ - "address_plural", - "cancel", - "close", - "payment_method_plural", - "save", - "subscription_plural", - "transaction_plural", - "undo_cancel", - "undo_confirm", - "undo_header", - "undo_message", - "update", - "transactions-table", - "address-card", - "address-form", - "customer-form", - "payment-method-card", - "spinner", - "subscription-card", - "subscription-form" - ] - }, - "sign-in-form": { - "additionalProperties": false, - "properties": { - "email": { "type": "string", "default": "Email" }, - "invalid_credential_error": { - "type": "string", - "default": "Incorrect email or password. Please check your credentials and try again." - }, - "password": { "type": "string", "default": "Password" }, - "recover_access": { "type": "string", "default": "Get temporary password" }, - "sign_in": { "type": "string", "default": "Sign in" }, - "sign_in_hint": { "type": "string", "default": "Please enter your email and password" }, - "sign_up": { "type": "string", "default": "Create account" }, - "unknown_error": { - "type": "string", - "default": "An unknown error has occured. Please try again later." - }, - "v8n_invalid_email": { "type": "string", "default": "Invalid email" }, - "v8n_required": { "type": "string", "default": "Required" }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "email", - "invalid_credential_error", - "password", - "recover_access", - "sign_in", - "sign_in_hint", - "sign_up", - "unknown_error", - "v8n_invalid_email", - "v8n_required", - "spinner" - ] - }, - "sign-up-form": { - "additionalProperties": false, - "properties": { - "sign_up": { "type": "string", "default": "Sign up" }, - "sign_up_hint": { "type": "string", "default": "Create an account to access the portal" }, - "go_back": { "type": "string", "default": "Go back" }, - "error": { - "additionalProperties": false, - "properties": { - "registration_disabled": { - "type": "string", - "default": "Customer registration is disabled for this store. If you're seeing this message as a customer, please contact the store owner." - }, - "verification_failed": { - "type": "string", - "default": "Client verification failed. If you are seeing this message as a customer, please contact the store owner." - }, - "email_already_used": { - "type": "string", - "default": "This email is already in use. Please use a different email or sign in instead." - } - }, - "required": ["registration_disabled", "verification_failed", "email_already_used"] - }, - "first-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "First name" }, - "placeholder": { "type": "string", "default": "Not set" }, - "helper_text": { "type": "string", "default": "Your given name, optional." }, - "v8n_too_long": { - "type": "string", - "default": "We can't store first names longer than 50 characters." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "last-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Last name" }, - "placeholder": { "type": "string", "default": "Not set" }, - "helper_text": { "type": "string", "default": "Your surname, optional." }, - "v8n_too_long": { - "type": "string", - "default": "We can't store last names longer than 50 characters." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "email": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Email" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "We'll use this email as the login to the Checkout and Customer Portal." - }, - "v8n_too_long": { - "type": "string", - "default": "We can't store emails longer than 100 characters." - }, - "v8n_invalid_email": { "type": "string", "default": "This email is invalid." }, - "v8n_required": { "type": "string", "default": "Please fill out this field." } - }, - "required": [ - "label", - "placeholder", - "helper_text", - "v8n_too_long", - "v8n_invalid_email", - "v8n_required" - ] - }, - "password": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Password" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "To generate a secure random password for this account, use the ✨ button." - }, - "v8n_too_long": { - "type": "string", - "default": "Please use a password that is no longer than 50 characters." - }, - "v8n_too_weak": { - "type": "string", - "default": "Please use a stronger password. To make this password stronger, make it at least 8 characters long and include a few upper and lower case letters, numbers, and special characters." - }, - "v8n_required": { "type": "string", "default": "Please fill out this field." } - }, - "required": [ - "label", - "placeholder", - "helper_text", - "v8n_too_long", - "v8n_too_weak", - "v8n_required" - ] - }, - "legal-notice": { - "additionalProperties": false, - "properties": { - "text": { - "type": "string", - "default": "By creating an account, you agree to our Terms of Service." - }, - "link": { "type": "string", "default": "Click here to open them in a new tab." } - }, - "required": ["text", "link"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create account" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "sign_up", - "sign_up_hint", - "go_back", - "error", - "first-name", - "last-name", - "email", - "password", - "legal-notice", - "create", - "spinner" - ] - } - }, - "required": ["access-recovery-form", "customer", "sign-in-form", "sign-up-form"] -} diff --git a/src/static/schemas/customer.json b/src/static/schemas/customer.json deleted file mode 100644 index fd7bedd42..000000000 --- a/src/static/schemas/customer.json +++ /dev/null @@ -1,2863 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "address_plural": { "type": "string", "default": "Addresses" }, - "attribute_plural": { "type": "string", "default": "Attributes" }, - "cancel": { "type": "string", "default": "Cancel" }, - "close": { "type": "string", "default": "Close" }, - "create": { "type": "string", "default": "Create" }, - "customer": { "type": "string", "default": "Customer" }, - "delete_prompt": { - "type": "string", - "default": "This resource will be permanently removed. Are you sure?" - }, - "payment_method_plural": { "type": "string", "default": "Payment methods" }, - "save": { "type": "string", "default": "Save" }, - "subscription_plural": { "type": "string", "default": "Subscriptions" }, - "transaction_plural": { "type": "string", "default": "Transactions" }, - "undo_cancel": { "type": "string", "default": "Review" }, - "undo_confirm": { "type": "string", "default": "Discard" }, - "undo_header": { "type": "string", "default": "Unsaved changes" }, - "undo_message": { - "type": "string", - "default": "Looks like you didn't save your changes! What would you like to do with them?" - }, - "update": { "type": "string", "default": "Update" }, - "address-card": { - "additionalProperties": false, - "properties": { - "default_billing_address": { "type": "string", "default": "Default billing address" }, - "default_shipping_address": { "type": "string", "default": "Default shipping address" }, - "full_address": { - "type": "string", - "default": "{{address1}} {{address2}} {{city}} {{region}} {{postal_code}}" - }, - "full_name": { "type": "string", "default": "{{first_name}} {{last_name}}" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "default_billing_address", - "default_shipping_address", - "full_address", - "full_name", - "spinner" - ] - }, - "address-form": { - "additionalProperties": false, - "properties": { - "address-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Address name" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_required": { "type": "string", "default": "Please enter address name" }, - "v8n_too_long": { - "type": "string", - "default": "Please shorten address name to 100 characters or less" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_too_long"] - }, - "first-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "First name" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we can't store first names longer than 50 characters" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "last-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Last name" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we can't store last names longer than 50 characters" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "company": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Company" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we can't store company names longer than 50 characters" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "phone": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Phone" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "This phone number appears to be too long" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "address-one": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Address Line 1" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "Street address, P.O. box, company name, c/o" - }, - "v8n_required": { "type": "string", "default": "Please enter address line 1" }, - "v8n_too_long": { - "type": "string", - "default": "Please shorten address line 1 to 100 characters or less" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_too_long"] - }, - "address-two": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Address Line 2" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { - "type": "string", - "default": "Apartment, suite, unit, building, floor, etc." - }, - "v8n_too_long": { - "type": "string", - "default": "Please shorten address line 2 to 100 characters or less" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "city": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "City" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we can't store city names longer than 50 characters" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "postal-code": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Postal code" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "This postal code appears to be too long" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "country": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Country" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "region": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Region" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we can't store region names longer than 50 characters" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date": { "type": "string", "default": "{{value, date}}" }, - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" } - }, - "required": ["date", "date_created", "date_modified"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove this address? You won't be able to bring it back." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - }, - "country_af": { "type": "string", "default": "Afghanistan" }, - "country_ax": { "type": "string", "default": "Åland Islands" }, - "country_al": { "type": "string", "default": "Albania" }, - "country_dz": { "type": "string", "default": "Algeria" }, - "country_as": { "type": "string", "default": "American Samoa" }, - "country_ad": { "type": "string", "default": "Andorra" }, - "country_ao": { "type": "string", "default": "Angola" }, - "country_ai": { "type": "string", "default": "Anguilla" }, - "country_aq": { "type": "string", "default": "Antarctica" }, - "country_ag": { "type": "string", "default": "Antigua and Barbuda" }, - "country_ar": { "type": "string", "default": "Argentina" }, - "country_am": { "type": "string", "default": "Armenia" }, - "country_aw": { "type": "string", "default": "Aruba" }, - "country_au": { "type": "string", "default": "Australia" }, - "country_au_region_act": { "type": "string", "default": "Australian Capital Territory" }, - "country_au_region_nsw": { "type": "string", "default": "New South Wales" }, - "country_au_region_nt": { "type": "string", "default": "Northern Territory" }, - "country_au_region_qld": { "type": "string", "default": "Queensland" }, - "country_au_region_sa": { "type": "string", "default": "South Australia" }, - "country_au_region_tas": { "type": "string", "default": "Tasmania" }, - "country_au_region_vic": { "type": "string", "default": "Victoria" }, - "country_au_region_wa": { "type": "string", "default": "Western Australia" }, - "country_at": { "type": "string", "default": "Austria" }, - "country_at_region_bl": { "type": "string", "default": "Burgenland" }, - "country_at_region_kn": { "type": "string", "default": "Kaernten" }, - "country_at_region_no": { "type": "string", "default": "Niederoesterreich" }, - "country_at_region_oo": { "type": "string", "default": "Oberoesterreich" }, - "country_at_region_sb": { "type": "string", "default": "Salzburg" }, - "country_at_region_st": { "type": "string", "default": "Steiermark" }, - "country_at_region_ti": { "type": "string", "default": "Tirol" }, - "country_at_region_vb": { "type": "string", "default": "Voralberg" }, - "country_at_region_wi": { "type": "string", "default": "Wien" }, - "country_az": { "type": "string", "default": "Azerbaijan" }, - "country_bs": { "type": "string", "default": "Bahamas" }, - "country_bh": { "type": "string", "default": "Bahrain" }, - "country_bd": { "type": "string", "default": "Bangladesh" }, - "country_bb": { "type": "string", "default": "Barbados" }, - "country_by": { "type": "string", "default": "Belarus" }, - "country_be": { "type": "string", "default": "Belgium" }, - "country_bz": { "type": "string", "default": "Belize" }, - "country_bj": { "type": "string", "default": "Benin" }, - "country_bm": { "type": "string", "default": "Bermuda" }, - "country_bt": { "type": "string", "default": "Bhutan" }, - "country_bo": { "type": "string", "default": "Bolivia" }, - "country_bq": { "type": "string", "default": "Bonaire, Sint Eustatius and Saba" }, - "country_bq_region_bo": { "type": "string", "default": "Bonaire" }, - "country_bq_region_sa": { "type": "string", "default": "Saba" }, - "country_bq_region_se": { "type": "string", "default": "Sint Eustatius" }, - "country_ba": { "type": "string", "default": "Bosnia and Herzegovina" }, - "country_bw": { "type": "string", "default": "Botswana" }, - "country_bv": { "type": "string", "default": "Bouvet Island" }, - "country_br": { "type": "string", "default": "Brazil" }, - "country_io": { "type": "string", "default": "British Indian Ocean Territory" }, - "country_bn": { "type": "string", "default": "Brunei Darussalam" }, - "country_bg": { "type": "string", "default": "Bulgaria" }, - "country_bf": { "type": "string", "default": "Burkina Faso" }, - "country_bi": { "type": "string", "default": "Burundi" }, - "country_kh": { "type": "string", "default": "Cambodia" }, - "country_cm": { "type": "string", "default": "Cameroon" }, - "country_ca": { "type": "string", "default": "Canada" }, - "country_ca_region_ab": { "type": "string", "default": "Alberta" }, - "country_ca_region_bc": { "type": "string", "default": "British Columbia" }, - "country_ca_region_mb": { "type": "string", "default": "Manitoba" }, - "country_ca_region_nb": { "type": "string", "default": "New Brunswick" }, - "country_ca_region_nl": { "type": "string", "default": "Newfoundland and Labrador" }, - "country_ca_region_nt": { "type": "string", "default": "Northwest Territories" }, - "country_ca_region_ns": { "type": "string", "default": "Nova Scotia" }, - "country_ca_region_nu": { "type": "string", "default": "Nunavut" }, - "country_ca_region_on": { "type": "string", "default": "Ontario" }, - "country_ca_region_pe": { "type": "string", "default": "Prince Edward Island" }, - "country_ca_region_qc": { "type": "string", "default": "Quebec" }, - "country_ca_region_sk": { "type": "string", "default": "Saskatchewan" }, - "country_ca_region_yt": { "type": "string", "default": "Yukon" }, - "country_cv": { "type": "string", "default": "Cape Verde" }, - "country_cw": { "type": "string", "default": "Curaçao" }, - "country_ky": { "type": "string", "default": "Cayman Islands" }, - "country_cf": { "type": "string", "default": "Central African Republic" }, - "country_td": { "type": "string", "default": "Chad" }, - "country_cl": { "type": "string", "default": "Chile" }, - "country_cn": { "type": "string", "default": "China" }, - "country_cx": { "type": "string", "default": "Christmas Island" }, - "country_cc": { "type": "string", "default": "Cocos (Keeling) Islands" }, - "country_co": { "type": "string", "default": "Colombia" }, - "country_km": { "type": "string", "default": "Comoros" }, - "country_cg": { "type": "string", "default": "Congo" }, - "country_cd": { "type": "string", "default": "Congo, the Democratic Republic of the" }, - "country_ck": { "type": "string", "default": "Cook Islands" }, - "country_cr": { "type": "string", "default": "Costa Rica" }, - "country_ci": { "type": "string", "default": "Cote DIvoire" }, - "country_hr": { "type": "string", "default": "Croatia" }, - "country_cu": { "type": "string", "default": "Cuba" }, - "country_cy": { "type": "string", "default": "Cyprus" }, - "country_cz": { "type": "string", "default": "Czech Republic" }, - "country_dk": { "type": "string", "default": "Denmark" }, - "country_dj": { "type": "string", "default": "Djibouti" }, - "country_dm": { "type": "string", "default": "Dominica" }, - "country_do": { "type": "string", "default": "Dominican Republic" }, - "country_ec": { "type": "string", "default": "Ecuador" }, - "country_eg": { "type": "string", "default": "Egypt" }, - "country_sv": { "type": "string", "default": "El Salvador" }, - "country_sx": { "type": "string", "default": "Sint Maarten" }, - "country_gq": { "type": "string", "default": "Equatorial Guinea" }, - "country_er": { "type": "string", "default": "Eritrea" }, - "country_ee": { "type": "string", "default": "Estonia" }, - "country_et": { "type": "string", "default": "Ethiopia" }, - "country_fk": { "type": "string", "default": "Falkland Islands (Malvinas)" }, - "country_fo": { "type": "string", "default": "Faroe Islands" }, - "country_fj": { "type": "string", "default": "Fiji" }, - "country_fi": { "type": "string", "default": "Finland" }, - "country_fr": { "type": "string", "default": "France" }, - "country_gf": { "type": "string", "default": "French Guiana" }, - "country_pf": { "type": "string", "default": "French Polynesia" }, - "country_tf": { "type": "string", "default": "French Southern Territories" }, - "country_ga": { "type": "string", "default": "Gabon" }, - "country_gm": { "type": "string", "default": "Gambia" }, - "country_ge": { "type": "string", "default": "Georgia" }, - "country_de": { "type": "string", "default": "Germany" }, - "country_de_region_bw": { "type": "string", "default": "Baden-Wuerttemberg" }, - "country_de_region_by": { "type": "string", "default": "Bayern" }, - "country_de_region_be": { "type": "string", "default": "Berlin" }, - "country_de_region_bb": { "type": "string", "default": "Brandenburg" }, - "country_de_region_hb": { "type": "string", "default": "Bremen" }, - "country_de_region_hh": { "type": "string", "default": "Hamburg" }, - "country_de_region_he": { "type": "string", "default": "Hessen" }, - "country_de_region_mv": { "type": "string", "default": "Mecklenburg-Vorpommern" }, - "country_de_region_ni": { "type": "string", "default": "Niedersachsen" }, - "country_de_region_nw": { "type": "string", "default": "Nordrhein-Westfalen" }, - "country_de_region_rp": { "type": "string", "default": "Rheinland-Pfalz" }, - "country_de_region_sl": { "type": "string", "default": "Saarland" }, - "country_de_region_sn": { "type": "string", "default": "Sachsen" }, - "country_de_region_st": { "type": "string", "default": "Sachsen-Anhalt" }, - "country_de_region_sh": { "type": "string", "default": "Schleswig-Holstein" }, - "country_de_region_th": { "type": "string", "default": "Thueringen" }, - "country_gh": { "type": "string", "default": "Ghana" }, - "country_gi": { "type": "string", "default": "Gibraltar" }, - "country_gr": { "type": "string", "default": "Greece" }, - "country_gl": { "type": "string", "default": "Greenland" }, - "country_gd": { "type": "string", "default": "Grenada" }, - "country_gp": { "type": "string", "default": "Guadeloupe" }, - "country_gu": { "type": "string", "default": "Guam" }, - "country_gt": { "type": "string", "default": "Guatemala" }, - "country_gg": { "type": "string", "default": "Guernsey" }, - "country_gn": { "type": "string", "default": "Guinea" }, - "country_gw": { "type": "string", "default": "Guinea-bissau" }, - "country_gy": { "type": "string", "default": "Guyana" }, - "country_ht": { "type": "string", "default": "Haiti" }, - "country_hm": { "type": "string", "default": "Heard Island and McDonald Island" }, - "country_va": { "type": "string", "default": "Holy See (Vatican City State)" }, - "country_hn": { "type": "string", "default": "Honduras" }, - "country_hk": { "type": "string", "default": "Hong Kong" }, - "country_hu": { "type": "string", "default": "Hungary" }, - "country_is": { "type": "string", "default": "Iceland" }, - "country_in": { "type": "string", "default": "India" }, - "country_in_region_an": { "type": "string", "default": "Andaman and Nicobar Islands" }, - "country_in_region_ap": { "type": "string", "default": "Andhra Pradesh" }, - "country_in_region_ar": { "type": "string", "default": "Arunachal Pradesh" }, - "country_in_region_as": { "type": "string", "default": "Assam" }, - "country_in_region_br": { "type": "string", "default": "Bihar" }, - "country_in_region_ch": { "type": "string", "default": "Chandigarh" }, - "country_in_region_ct": { "type": "string", "default": "Chhattisgarh" }, - "country_in_region_dn": { "type": "string", "default": "Dadra and Nagar Haveli" }, - "country_in_region_dd": { "type": "string", "default": "Daman and Diu" }, - "country_in_region_dl": { "type": "string", "default": "Delhi" }, - "country_in_region_ga": { "type": "string", "default": "Goa" }, - "country_in_region_gj": { "type": "string", "default": "Gujarat" }, - "country_in_region_hr": { "type": "string", "default": "Haryana" }, - "country_in_region_hp": { "type": "string", "default": "Himachal Pradesh" }, - "country_in_region_jk": { "type": "string", "default": "Jammu and Kashmir" }, - "country_in_region_jh": { "type": "string", "default": "Jharkhand" }, - "country_in_region_ka": { "type": "string", "default": "Karnataka" }, - "country_in_region_kl": { "type": "string", "default": "Kerala" }, - "country_in_region_ld": { "type": "string", "default": "Lakshadweep" }, - "country_in_region_mp": { "type": "string", "default": "Madhya Pradesh" }, - "country_in_region_mh": { "type": "string", "default": "Maharashtra" }, - "country_in_region_mn": { "type": "string", "default": "Manipur" }, - "country_in_region_ml": { "type": "string", "default": "Meghalaya" }, - "country_in_region_mz": { "type": "string", "default": "Mizoram" }, - "country_in_region_nl": { "type": "string", "default": "Nagaland" }, - "country_in_region_or": { "type": "string", "default": "Odisha" }, - "country_in_region_py": { "type": "string", "default": "Puducherry" }, - "country_in_region_pb": { "type": "string", "default": "Punjab" }, - "country_in_region_rj": { "type": "string", "default": "Rajasthan" }, - "country_in_region_sk": { "type": "string", "default": "Sikkim" }, - "country_in_region_tn": { "type": "string", "default": "Tamil Nadu" }, - "country_in_region_tg": { "type": "string", "default": "Telangana" }, - "country_in_region_tr": { "type": "string", "default": "Tripura" }, - "country_in_region_ut": { "type": "string", "default": "Uttarakhand" }, - "country_in_region_up": { "type": "string", "default": "Uttar Pradesh" }, - "country_in_region_wb": { "type": "string", "default": "West Bengal" }, - "country_id": { "type": "string", "default": "Indonesia" }, - "country_ir": { "type": "string", "default": "Iran, Islamic Republic of" }, - "country_iq": { "type": "string", "default": "Iraq" }, - "country_ie": { "type": "string", "default": "Ireland" }, - "country_ie_region_cw": { "type": "string", "default": "Carlow" }, - "country_ie_region_cn": { "type": "string", "default": "Cavan" }, - "country_ie_region_ce": { "type": "string", "default": "Clare" }, - "country_ie_region_co": { "type": "string", "default": "Cork" }, - "country_ie_region_dl": { "type": "string", "default": "Donegal" }, - "country_ie_region_d": { "type": "string", "default": "Dublin" }, - "country_ie_region_g": { "type": "string", "default": "Galway" }, - "country_ie_region_ky": { "type": "string", "default": "Kerry" }, - "country_ie_region_ke": { "type": "string", "default": "Kildare" }, - "country_ie_region_kk": { "type": "string", "default": "Kilkenny" }, - "country_ie_region_ls": { "type": "string", "default": "Laois" }, - "country_ie_region_lm": { "type": "string", "default": "Leitrim" }, - "country_ie_region_lk": { "type": "string", "default": "Limerick" }, - "country_ie_region_ld": { "type": "string", "default": "Longford" }, - "country_ie_region_lh": { "type": "string", "default": "Louth" }, - "country_ie_region_mo": { "type": "string", "default": "Mayo" }, - "country_ie_region_mh": { "type": "string", "default": "Meath" }, - "country_ie_region_mn": { "type": "string", "default": "Monaghan" }, - "country_ie_region_oy": { "type": "string", "default": "Offaly" }, - "country_ie_region_rn": { "type": "string", "default": "Roscommon" }, - "country_ie_region_so": { "type": "string", "default": "Sligo" }, - "country_ie_region_ta": { "type": "string", "default": "Tipperary" }, - "country_ie_region_wd": { "type": "string", "default": "Waterford" }, - "country_ie_region_wh": { "type": "string", "default": "Westmeath" }, - "country_ie_region_wx": { "type": "string", "default": "Wexford" }, - "country_ie_region_ww": { "type": "string", "default": "Wicklow" }, - "country_im": { "type": "string", "default": "Isle of Man" }, - "country_il": { "type": "string", "default": "Israel" }, - "country_it": { "type": "string", "default": "Italy" }, - "country_jm": { "type": "string", "default": "Jamaica" }, - "country_jp": { "type": "string", "default": "Japan" }, - "country_jp_region_10": { "type": "string", "default": "Gunma" }, - "country_jp_region_11": { "type": "string", "default": "Saitama" }, - "country_jp_region_12": { "type": "string", "default": "Chiba" }, - "country_jp_region_13": { "type": "string", "default": "Tokyo" }, - "country_jp_region_14": { "type": "string", "default": "Kanagawa" }, - "country_jp_region_15": { "type": "string", "default": "Niigata" }, - "country_jp_region_16": { "type": "string", "default": "Toyama" }, - "country_jp_region_17": { "type": "string", "default": "Ishikawa" }, - "country_jp_region_18": { "type": "string", "default": "Fukui" }, - "country_jp_region_19": { "type": "string", "default": "Yamanashi" }, - "country_jp_region_20": { "type": "string", "default": "Nagano" }, - "country_jp_region_21": { "type": "string", "default": "Gifu" }, - "country_jp_region_22": { "type": "string", "default": "Shizuoka" }, - "country_jp_region_23": { "type": "string", "default": "Aichi" }, - "country_jp_region_24": { "type": "string", "default": "Mie" }, - "country_jp_region_25": { "type": "string", "default": "Shiga" }, - "country_jp_region_26": { "type": "string", "default": "Kyoto" }, - "country_jp_region_27": { "type": "string", "default": "Osaka" }, - "country_jp_region_28": { "type": "string", "default": "Hyogo" }, - "country_jp_region_29": { "type": "string", "default": "Nara" }, - "country_jp_region_30": { "type": "string", "default": "Wakayama" }, - "country_jp_region_31": { "type": "string", "default": "Tottori" }, - "country_jp_region_32": { "type": "string", "default": "Shimane" }, - "country_jp_region_33": { "type": "string", "default": "Okayama" }, - "country_jp_region_34": { "type": "string", "default": "Hiroshima" }, - "country_jp_region_35": { "type": "string", "default": "Yamaguchi" }, - "country_jp_region_36": { "type": "string", "default": "Tokushima" }, - "country_jp_region_37": { "type": "string", "default": "Kagawa" }, - "country_jp_region_38": { "type": "string", "default": "Ehime" }, - "country_jp_region_39": { "type": "string", "default": "Kochi" }, - "country_jp_region_40": { "type": "string", "default": "Fukuoka" }, - "country_jp_region_41": { "type": "string", "default": "Saga" }, - "country_jp_region_42": { "type": "string", "default": "Nagasaki" }, - "country_jp_region_43": { "type": "string", "default": "Kumamoto" }, - "country_jp_region_44": { "type": "string", "default": "Oita" }, - "country_jp_region_45": { "type": "string", "default": "Miyazaki" }, - "country_jp_region_46": { "type": "string", "default": "Kagoshima" }, - "country_jp_region_47": { "type": "string", "default": "Okinawa" }, - "country_jp_region_05": { "type": "string", "default": "Akita" }, - "country_jp_region_02": { "type": "string", "default": "Aomori" }, - "country_jp_region_07": { "type": "string", "default": "Fukushima" }, - "country_jp_region_01": { "type": "string", "default": "Hokkaido" }, - "country_jp_region_08": { "type": "string", "default": "Ibaraki" }, - "country_jp_region_03": { "type": "string", "default": "Iwate" }, - "country_jp_region_04": { "type": "string", "default": "Miyagi" }, - "country_jp_region_09": { "type": "string", "default": "Tochigi" }, - "country_jp_region_06": { "type": "string", "default": "Yamagata" }, - "country_je": { "type": "string", "default": "Jersey" }, - "country_jo": { "type": "string", "default": "Jordan" }, - "country_kz": { "type": "string", "default": "Kazakhstan" }, - "country_ke": { "type": "string", "default": "Kenya" }, - "country_ki": { "type": "string", "default": "Kiribati" }, - "country_kp": { "type": "string", "default": "Korea, Democratic People's Republic of" }, - "country_kr": { "type": "string", "default": "Korea, Republic of" }, - "country_kw": { "type": "string", "default": "Kuwait" }, - "country_kg": { "type": "string", "default": "Kyrgyzstan" }, - "country_la": { "type": "string", "default": "Lao People's Democratic Republic" }, - "country_lv": { "type": "string", "default": "Latvia" }, - "country_lb": { "type": "string", "default": "Lebanon" }, - "country_ls": { "type": "string", "default": "Lesotho" }, - "country_lr": { "type": "string", "default": "Liberia" }, - "country_ly": { "type": "string", "default": "Libya" }, - "country_li": { "type": "string", "default": "Liechtenstein" }, - "country_lt": { "type": "string", "default": "Lithuania" }, - "country_lu": { "type": "string", "default": "Luxembourg" }, - "country_mo": { - "type": "string", - "default": "Macau Special Administrative Region of China" - }, - "country_mk": { "type": "string", "default": "North Macedonia" }, - "country_mg": { "type": "string", "default": "Madagascar" }, - "country_mw": { "type": "string", "default": "Malawi" }, - "country_my": { "type": "string", "default": "Malaysia" }, - "country_mv": { "type": "string", "default": "Maldives" }, - "country_ml": { "type": "string", "default": "Mali" }, - "country_mt": { "type": "string", "default": "Malta" }, - "country_mh": { "type": "string", "default": "Marshall Islands" }, - "country_mq": { "type": "string", "default": "Martinique" }, - "country_mr": { "type": "string", "default": "Mauritania" }, - "country_mu": { "type": "string", "default": "Mauritius" }, - "country_yt": { "type": "string", "default": "Mayotte" }, - "country_mx": { "type": "string", "default": "Mexico" }, - "country_fm": { "type": "string", "default": "Micronesia, Federated States of" }, - "country_md": { "type": "string", "default": "Moldova, Republic of" }, - "country_mc": { "type": "string", "default": "Monaco" }, - "country_mn": { "type": "string", "default": "Mongolia" }, - "country_me": { "type": "string", "default": "Montenegro" }, - "country_ms": { "type": "string", "default": "Montserrat" }, - "country_ma": { "type": "string", "default": "Morocco" }, - "country_mz": { "type": "string", "default": "Mozambique" }, - "country_mm": { "type": "string", "default": "Myanmar" }, - "country_na": { "type": "string", "default": "Namibia" }, - "country_nr": { "type": "string", "default": "Nauru" }, - "country_np": { "type": "string", "default": "Nepal" }, - "country_nl": { "type": "string", "default": "Netherlands" }, - "country_nc": { "type": "string", "default": "New Caledonia" }, - "country_nz": { "type": "string", "default": "New Zealand" }, - "country_ni": { "type": "string", "default": "Nicaragua" }, - "country_ne": { "type": "string", "default": "Niger" }, - "country_ng": { "type": "string", "default": "Nigeria" }, - "country_nu": { "type": "string", "default": "Niue" }, - "country_nf": { "type": "string", "default": "Norfolk Island" }, - "country_mp": { "type": "string", "default": "Northern Mariana Islands" }, - "country_no": { "type": "string", "default": "Norway" }, - "country_no_region_10": { "type": "string", "default": "Vest-Agder" }, - "country_no_region_11": { "type": "string", "default": "Rogaland" }, - "country_no_region_12": { "type": "string", "default": "Hordaland" }, - "country_no_region_14": { "type": "string", "default": "Sogn og Fjordane" }, - "country_no_region_15": { "type": "string", "default": "Møre og Romsdal" }, - "country_no_region_16": { "type": "string", "default": "Sør-Trøndelag" }, - "country_no_region_17": { "type": "string", "default": "Nord-Trøndelag" }, - "country_no_region_18": { "type": "string", "default": "Nordland" }, - "country_no_region_19": { "type": "string", "default": "Troms" }, - "country_no_region_20": { "type": "string", "default": "Finnmark" }, - "country_no_region_30": { "type": "string", "default": "Viken" }, - "country_no_region_34": { "type": "string", "default": "Innlandet" }, - "country_no_region_38": { "type": "string", "default": "Vestfold og Telemark" }, - "country_no_region_42": { "type": "string", "default": "Agder" }, - "country_no_region_46": { "type": "string", "default": "Vestland" }, - "country_no_region_50": { "type": "string", "default": "Trøndelag" }, - "country_no_region_54": { "type": "string", "default": "Troms og Finnmark" }, - "country_no_region_01": { "type": "string", "default": "Østfold" }, - "country_no_region_02": { "type": "string", "default": "Akershus" }, - "country_no_region_03": { "type": "string", "default": "Oslo" }, - "country_no_region_04": { "type": "string", "default": "Hedmark" }, - "country_no_region_05": { "type": "string", "default": "Oppland" }, - "country_no_region_06": { "type": "string", "default": "Buskerud" }, - "country_no_region_07": { "type": "string", "default": "Vestfold" }, - "country_no_region_08": { "type": "string", "default": "Telemark" }, - "country_no_region_09": { "type": "string", "default": "Aust-Agder" }, - "country_om": { "type": "string", "default": "Oman" }, - "country_pk": { "type": "string", "default": "Pakistan" }, - "country_pw": { "type": "string", "default": "Palau" }, - "country_ps": { "type": "string", "default": "Palestine, State of" }, - "country_pa": { "type": "string", "default": "Panama" }, - "country_pg": { "type": "string", "default": "Papua New Guinea" }, - "country_py": { "type": "string", "default": "Paraguay" }, - "country_pe": { "type": "string", "default": "Peru" }, - "country_ph": { "type": "string", "default": "Philippines" }, - "country_pn": { "type": "string", "default": "Pitcairn" }, - "country_pl": { "type": "string", "default": "Poland" }, - "country_pt": { "type": "string", "default": "Portugal" }, - "country_pr": { "type": "string", "default": "Puerto Rico" }, - "country_qa": { "type": "string", "default": "Qatar" }, - "country_re": { "type": "string", "default": "Réunion" }, - "country_ro": { "type": "string", "default": "Romania" }, - "country_ru": { "type": "string", "default": "Russian Federation" }, - "country_rw": { "type": "string", "default": "Rwanda" }, - "country_bl": { "type": "string", "default": "Saint Barthélemy" }, - "country_sh": { - "type": "string", - "default": "Saint Helena, Ascension and Tristan da Cunha" - }, - "country_kn": { "type": "string", "default": "Saint Kitts and Nevis" }, - "country_lc": { "type": "string", "default": "Saint Lucia" }, - "country_mf": { "type": "string", "default": "Saint Martin" }, - "country_pm": { "type": "string", "default": "Saint Pierre and Miquelon" }, - "country_vc": { "type": "string", "default": "Saint Vincent and the Grenadines" }, - "country_ws": { "type": "string", "default": "Samoa" }, - "country_sm": { "type": "string", "default": "San Marino" }, - "country_ss": { "type": "string", "default": "South Sudan" }, - "country_st": { "type": "string", "default": "Sao Tome and Principe" }, - "country_sa": { "type": "string", "default": "Saudi Arabia" }, - "country_sn": { "type": "string", "default": "Senegal" }, - "country_rs": { "type": "string", "default": "Serbia" }, - "country_sc": { "type": "string", "default": "Seychelles" }, - "country_sl": { "type": "string", "default": "Sierra Leone" }, - "country_sg": { "type": "string", "default": "Singapore" }, - "country_sk": { "type": "string", "default": "Slovakia" }, - "country_si": { "type": "string", "default": "Slovenia" }, - "country_sb": { "type": "string", "default": "Solomon Islands" }, - "country_so": { "type": "string", "default": "Somalia" }, - "country_za": { "type": "string", "default": "South Africa" }, - "country_gs": { - "type": "string", - "default": "South Georgia and the South Sandwich Islands" - }, - "country_es": { "type": "string", "default": "Spain" }, - "country_es_region_a coruna": { "type": "string", "default": "A Coruna" }, - "country_es_region_alava": { "type": "string", "default": "Alava" }, - "country_es_region_albacete": { "type": "string", "default": "Albacete" }, - "country_es_region_alicante": { "type": "string", "default": "Alicante" }, - "country_es_region_almeria": { "type": "string", "default": "Almeria" }, - "country_es_region_asturias": { "type": "string", "default": "Asturias" }, - "country_es_region_avila": { "type": "string", "default": "Avila" }, - "country_es_region_badajoz": { "type": "string", "default": "Badajoz" }, - "country_es_region_baleares": { "type": "string", "default": "Baleares" }, - "country_es_region_barcelona": { "type": "string", "default": "Barcelona" }, - "country_es_region_burgos": { "type": "string", "default": "Burgos" }, - "country_es_region_caceres": { "type": "string", "default": "Caceres" }, - "country_es_region_cadiz": { "type": "string", "default": "Cadiz" }, - "country_es_region_cn": { "type": "string", "default": "Canarias" }, - "country_es_region_cantabria": { "type": "string", "default": "Cantabria" }, - "country_es_region_castellon": { "type": "string", "default": "Castellon" }, - "country_es_region_ceuta": { "type": "string", "default": "Ceuta" }, - "country_es_region_ciudad real": { "type": "string", "default": "Ciudad Real" }, - "country_es_region_cordoba": { "type": "string", "default": "Cordoba" }, - "country_es_region_cuenca": { "type": "string", "default": "Cuenca" }, - "country_es_region_gipuzkoa": { "type": "string", "default": "Gipuzkoa" }, - "country_es_region_girona": { "type": "string", "default": "Girona" }, - "country_es_region_granada": { "type": "string", "default": "Granada" }, - "country_es_region_guadalajara": { "type": "string", "default": "Guadalajara" }, - "country_es_region_guipuzcoa": { "type": "string", "default": "Guipuzcoa" }, - "country_es_region_huelva": { "type": "string", "default": "Huelva" }, - "country_es_region_huesca": { "type": "string", "default": "Huesca" }, - "country_es_region_jaen": { "type": "string", "default": "Jaen" }, - "country_es_region_la rioja": { "type": "string", "default": "La Rioja" }, - "country_es_region_las palmas": { "type": "string", "default": "Las Palmas" }, - "country_es_region_leon": { "type": "string", "default": "Leon" }, - "country_es_region_lleida": { "type": "string", "default": "Lleida" }, - "country_es_region_lugo": { "type": "string", "default": "Lugo" }, - "country_es_region_madrid": { "type": "string", "default": "Madrid" }, - "country_es_region_malaga": { "type": "string", "default": "Malaga" }, - "country_es_region_melilla": { "type": "string", "default": "Melilla" }, - "country_es_region_murcia": { "type": "string", "default": "Murcia" }, - "country_es_region_navarra": { "type": "string", "default": "Navarra" }, - "country_es_region_ourense": { "type": "string", "default": "Ourense" }, - "country_es_region_palencia": { "type": "string", "default": "Palencia" }, - "country_es_region_pontevedra": { "type": "string", "default": "Pontevedra" }, - "country_es_region_salamanca": { "type": "string", "default": "Salamanca" }, - "country_es_region_santa cruz de tenerife": { - "type": "string", - "default": "Santa Cruz de Tenerife" - }, - "country_es_region_segovia": { "type": "string", "default": "Segovia" }, - "country_es_region_sevilla": { "type": "string", "default": "Sevilla" }, - "country_es_region_soria": { "type": "string", "default": "Soria" }, - "country_es_region_tarragona": { "type": "string", "default": "Tarragona" }, - "country_es_region_teruel": { "type": "string", "default": "Teruel" }, - "country_es_region_toledo": { "type": "string", "default": "Toledo" }, - "country_es_region_valencia": { "type": "string", "default": "Valencia" }, - "country_es_region_valladolid": { "type": "string", "default": "Valladolid" }, - "country_es_region_vizcaya": { "type": "string", "default": "Biscay" }, - "country_es_region_zamora": { "type": "string", "default": "Zamora" }, - "country_es_region_zaragoza": { "type": "string", "default": "Zaragoza" }, - "country_lk": { "type": "string", "default": "Sri Lanka" }, - "country_sd": { "type": "string", "default": "Sudan" }, - "country_sr": { "type": "string", "default": "Suriname" }, - "country_sj": { "type": "string", "default": "Svalbard and Jan Mayen" }, - "country_sz": { "type": "string", "default": "Eswatini" }, - "country_se": { "type": "string", "default": "Sweden" }, - "country_ch": { "type": "string", "default": "Switzerland" }, - "country_ch_region_ag": { "type": "string", "default": "Aargau" }, - "country_ch_region_ar": { "type": "string", "default": "Appenzell Ausserrhoden" }, - "country_ch_region_ai": { "type": "string", "default": "Appenzell Innerrhoden" }, - "country_ch_region_bl": { "type": "string", "default": "Basel-Landschaft" }, - "country_ch_region_bs": { "type": "string", "default": "Basel-Stadt" }, - "country_ch_region_be": { "type": "string", "default": "Bern" }, - "country_ch_region_fr": { "type": "string", "default": "Freiburg" }, - "country_ch_region_ge": { "type": "string", "default": "Genf" }, - "country_ch_region_gl": { "type": "string", "default": "Glarus" }, - "country_ch_region_gr": { "type": "string", "default": "Graubuenden" }, - "country_ch_region_ju": { "type": "string", "default": "Jura" }, - "country_ch_region_lu": { "type": "string", "default": "Luzern" }, - "country_ch_region_ne": { "type": "string", "default": "Neuenburg" }, - "country_ch_region_nw": { "type": "string", "default": "Nidwalden" }, - "country_ch_region_ow": { "type": "string", "default": "Obwalden" }, - "country_ch_region_sh": { "type": "string", "default": "Schaffhausen" }, - "country_ch_region_sz": { "type": "string", "default": "Schwyz" }, - "country_ch_region_so": { "type": "string", "default": "Solothurn" }, - "country_ch_region_sg": { "type": "string", "default": "St. Gallen" }, - "country_ch_region_ti": { "type": "string", "default": "Tessin" }, - "country_ch_region_tg": { "type": "string", "default": "Thurgau" }, - "country_ch_region_ur": { "type": "string", "default": "Uri" }, - "country_ch_region_vs": { "type": "string", "default": "Valais" }, - "country_ch_region_vd": { "type": "string", "default": "Vaud" }, - "country_ch_region_zh": { "type": "string", "default": "Zurich" }, - "country_ch_region_zg": { "type": "string", "default": "Zug" }, - "country_sy": { "type": "string", "default": "Syrian Arab Republic" }, - "country_tw": { "type": "string", "default": "Taiwan" }, - "country_tj": { "type": "string", "default": "Tajikistan" }, - "country_tz": { "type": "string", "default": "Tanzania, United Republic of" }, - "country_th": { "type": "string", "default": "Thailand" }, - "country_tl": { "type": "string", "default": "Timor-Leste" }, - "country_tg": { "type": "string", "default": "Togo" }, - "country_tk": { "type": "string", "default": "Tokelau" }, - "country_to": { "type": "string", "default": "Tonga" }, - "country_tt": { "type": "string", "default": "Trinidad and Tobago" }, - "country_tn": { "type": "string", "default": "Tunisia" }, - "country_tr": { "type": "string", "default": "Turkey" }, - "country_tm": { "type": "string", "default": "Turkmenistan" }, - "country_tc": { "type": "string", "default": "Turks and Caicos Islands" }, - "country_tv": { "type": "string", "default": "Tuvalu" }, - "country_ug": { "type": "string", "default": "Uganda" }, - "country_ua": { "type": "string", "default": "Ukraine" }, - "country_ae": { "type": "string", "default": "United Arab Emirates" }, - "country_gb": { "type": "string", "default": "United Kingdom" }, - "country_us": { "type": "string", "default": "United States" }, - "country_us_region_al": { "type": "string", "default": "Alabama" }, - "country_us_region_ak": { "type": "string", "default": "Alaska" }, - "country_us_region_as": { "type": "string", "default": "American Samoa" }, - "country_us_region_az": { "type": "string", "default": "Arizona" }, - "country_us_region_ar": { "type": "string", "default": "Arkansas" }, - "country_us_region_af": { "type": "string", "default": "Armed Forces Africa" }, - "country_us_region_aa": { "type": "string", "default": "Armed Forces Americas" }, - "country_us_region_ac": { "type": "string", "default": "Armed Forces Canada" }, - "country_us_region_ae": { "type": "string", "default": "Armed Forces Europe" }, - "country_us_region_am": { "type": "string", "default": "Armed Forces Middle East" }, - "country_us_region_ap": { "type": "string", "default": "Armed Forces Pacific" }, - "country_us_region_ca": { "type": "string", "default": "California" }, - "country_us_region_co": { "type": "string", "default": "Colorado" }, - "country_us_region_ct": { "type": "string", "default": "Connecticut" }, - "country_us_region_de": { "type": "string", "default": "Delaware" }, - "country_us_region_dc": { "type": "string", "default": "Washington DC" }, - "country_us_region_fm": { "type": "string", "default": "Federated States Of Micronesia" }, - "country_us_region_fl": { "type": "string", "default": "Florida" }, - "country_us_region_ga": { "type": "string", "default": "Georgia" }, - "country_us_region_gu": { "type": "string", "default": "Guam" }, - "country_us_region_hi": { "type": "string", "default": "Hawaii" }, - "country_us_region_id": { "type": "string", "default": "Idaho" }, - "country_us_region_il": { "type": "string", "default": "Illinois" }, - "country_us_region_in": { "type": "string", "default": "Indiana" }, - "country_us_region_ia": { "type": "string", "default": "Iowa" }, - "country_us_region_ks": { "type": "string", "default": "Kansas" }, - "country_us_region_ky": { "type": "string", "default": "Kentucky" }, - "country_us_region_la": { "type": "string", "default": "Louisiana" }, - "country_us_region_me": { "type": "string", "default": "Maine" }, - "country_us_region_mh": { "type": "string", "default": "Marshall Islands" }, - "country_us_region_md": { "type": "string", "default": "Maryland" }, - "country_us_region_ma": { "type": "string", "default": "Massachusetts" }, - "country_us_region_mi": { "type": "string", "default": "Michigan" }, - "country_us_region_mn": { "type": "string", "default": "Minnesota" }, - "country_us_region_ms": { "type": "string", "default": "Mississippi" }, - "country_us_region_mo": { "type": "string", "default": "Missouri" }, - "country_us_region_mt": { "type": "string", "default": "Montana" }, - "country_us_region_ne": { "type": "string", "default": "Nebraska" }, - "country_us_region_nv": { "type": "string", "default": "Nevada" }, - "country_us_region_nh": { "type": "string", "default": "New Hampshire" }, - "country_us_region_nj": { "type": "string", "default": "New Jersey" }, - "country_us_region_nm": { "type": "string", "default": "New Mexico" }, - "country_us_region_ny": { "type": "string", "default": "New York" }, - "country_us_region_nc": { "type": "string", "default": "North Carolina" }, - "country_us_region_nd": { "type": "string", "default": "North Dakota" }, - "country_us_region_mp": { "type": "string", "default": "Northern Mariana Islands" }, - "country_us_region_oh": { "type": "string", "default": "Ohio" }, - "country_us_region_ok": { "type": "string", "default": "Oklahoma" }, - "country_us_region_or": { "type": "string", "default": "Oregon" }, - "country_us_region_pa": { "type": "string", "default": "Pennsylvania" }, - "country_us_region_pr": { "type": "string", "default": "Puerto Rico" }, - "country_us_region_ri": { "type": "string", "default": "Rhode Island" }, - "country_us_region_sc": { "type": "string", "default": "South Carolina" }, - "country_us_region_sd": { "type": "string", "default": "South Dakota" }, - "country_us_region_tn": { "type": "string", "default": "Tennessee" }, - "country_us_region_tx": { "type": "string", "default": "Texas" }, - "country_us_region_ut": { "type": "string", "default": "Utah" }, - "country_us_region_vt": { "type": "string", "default": "Vermont" }, - "country_us_region_vi": { "type": "string", "default": "Virgin Islands" }, - "country_us_region_va": { "type": "string", "default": "Virginia" }, - "country_us_region_wa": { "type": "string", "default": "Washington" }, - "country_us_region_wv": { "type": "string", "default": "West Virginia" }, - "country_us_region_wi": { "type": "string", "default": "Wisconsin" }, - "country_us_region_wy": { "type": "string", "default": "Wyoming" }, - "country_um": { "type": "string", "default": "United States Minor Outlying Islands" }, - "country_uy": { "type": "string", "default": "Uruguay" }, - "country_uz": { "type": "string", "default": "Uzbekistan" }, - "country_vu": { "type": "string", "default": "Vanuatu" }, - "country_ve": { "type": "string", "default": "Venezuela" }, - "country_vn": { "type": "string", "default": "Vietnam" }, - "country_vg": { "type": "string", "default": "Virgin Islands, British" }, - "country_vi": { "type": "string", "default": "Virgin Islands, U.S." }, - "country_wf": { "type": "string", "default": "Wallis and Futuna Islands" }, - "country_eh": { "type": "string", "default": "Western Sahara" }, - "country_ye": { "type": "string", "default": "Yemen" }, - "country_zm": { "type": "string", "default": "Zambia" }, - "country_zw": { "type": "string", "default": "Zimbabwe" } - }, - "required": [ - "address-name", - "first-name", - "last-name", - "company", - "phone", - "address-one", - "address-two", - "city", - "postal-code", - "country", - "region", - "timestamps", - "delete", - "create", - "spinner", - "country_af", - "country_ax", - "country_al", - "country_dz", - "country_as", - "country_ad", - "country_ao", - "country_ai", - "country_aq", - "country_ag", - "country_ar", - "country_am", - "country_aw", - "country_au", - "country_au_region_act", - "country_au_region_nsw", - "country_au_region_nt", - "country_au_region_qld", - "country_au_region_sa", - "country_au_region_tas", - "country_au_region_vic", - "country_au_region_wa", - "country_at", - "country_at_region_bl", - "country_at_region_kn", - "country_at_region_no", - "country_at_region_oo", - "country_at_region_sb", - "country_at_region_st", - "country_at_region_ti", - "country_at_region_vb", - "country_at_region_wi", - "country_az", - "country_bs", - "country_bh", - "country_bd", - "country_bb", - "country_by", - "country_be", - "country_bz", - "country_bj", - "country_bm", - "country_bt", - "country_bo", - "country_bq", - "country_bq_region_bo", - "country_bq_region_sa", - "country_bq_region_se", - "country_ba", - "country_bw", - "country_bv", - "country_br", - "country_io", - "country_bn", - "country_bg", - "country_bf", - "country_bi", - "country_kh", - "country_cm", - "country_ca", - "country_ca_region_ab", - "country_ca_region_bc", - "country_ca_region_mb", - "country_ca_region_nb", - "country_ca_region_nl", - "country_ca_region_nt", - "country_ca_region_ns", - "country_ca_region_nu", - "country_ca_region_on", - "country_ca_region_pe", - "country_ca_region_qc", - "country_ca_region_sk", - "country_ca_region_yt", - "country_cv", - "country_cw", - "country_ky", - "country_cf", - "country_td", - "country_cl", - "country_cn", - "country_cx", - "country_cc", - "country_co", - "country_km", - "country_cg", - "country_cd", - "country_ck", - "country_cr", - "country_ci", - "country_hr", - "country_cu", - "country_cy", - "country_cz", - "country_dk", - "country_dj", - "country_dm", - "country_do", - "country_ec", - "country_eg", - "country_sv", - "country_sx", - "country_gq", - "country_er", - "country_ee", - "country_et", - "country_fk", - "country_fo", - "country_fj", - "country_fi", - "country_fr", - "country_gf", - "country_pf", - "country_tf", - "country_ga", - "country_gm", - "country_ge", - "country_de", - "country_de_region_bw", - "country_de_region_by", - "country_de_region_be", - "country_de_region_bb", - "country_de_region_hb", - "country_de_region_hh", - "country_de_region_he", - "country_de_region_mv", - "country_de_region_ni", - "country_de_region_nw", - "country_de_region_rp", - "country_de_region_sl", - "country_de_region_sn", - "country_de_region_st", - "country_de_region_sh", - "country_de_region_th", - "country_gh", - "country_gi", - "country_gr", - "country_gl", - "country_gd", - "country_gp", - "country_gu", - "country_gt", - "country_gg", - "country_gn", - "country_gw", - "country_gy", - "country_ht", - "country_hm", - "country_va", - "country_hn", - "country_hk", - "country_hu", - "country_is", - "country_in", - "country_in_region_an", - "country_in_region_ap", - "country_in_region_ar", - "country_in_region_as", - "country_in_region_br", - "country_in_region_ch", - "country_in_region_ct", - "country_in_region_dn", - "country_in_region_dd", - "country_in_region_dl", - "country_in_region_ga", - "country_in_region_gj", - "country_in_region_hr", - "country_in_region_hp", - "country_in_region_jk", - "country_in_region_jh", - "country_in_region_ka", - "country_in_region_kl", - "country_in_region_ld", - "country_in_region_mp", - "country_in_region_mh", - "country_in_region_mn", - "country_in_region_ml", - "country_in_region_mz", - "country_in_region_nl", - "country_in_region_or", - "country_in_region_py", - "country_in_region_pb", - "country_in_region_rj", - "country_in_region_sk", - "country_in_region_tn", - "country_in_region_tg", - "country_in_region_tr", - "country_in_region_ut", - "country_in_region_up", - "country_in_region_wb", - "country_id", - "country_ir", - "country_iq", - "country_ie", - "country_ie_region_cw", - "country_ie_region_cn", - "country_ie_region_ce", - "country_ie_region_co", - "country_ie_region_dl", - "country_ie_region_d", - "country_ie_region_g", - "country_ie_region_ky", - "country_ie_region_ke", - "country_ie_region_kk", - "country_ie_region_ls", - "country_ie_region_lm", - "country_ie_region_lk", - "country_ie_region_ld", - "country_ie_region_lh", - "country_ie_region_mo", - "country_ie_region_mh", - "country_ie_region_mn", - "country_ie_region_oy", - "country_ie_region_rn", - "country_ie_region_so", - "country_ie_region_ta", - "country_ie_region_wd", - "country_ie_region_wh", - "country_ie_region_wx", - "country_ie_region_ww", - "country_im", - "country_il", - "country_it", - "country_jm", - "country_jp", - "country_jp_region_10", - "country_jp_region_11", - "country_jp_region_12", - "country_jp_region_13", - "country_jp_region_14", - "country_jp_region_15", - "country_jp_region_16", - "country_jp_region_17", - "country_jp_region_18", - "country_jp_region_19", - "country_jp_region_20", - "country_jp_region_21", - "country_jp_region_22", - "country_jp_region_23", - "country_jp_region_24", - "country_jp_region_25", - "country_jp_region_26", - "country_jp_region_27", - "country_jp_region_28", - "country_jp_region_29", - "country_jp_region_30", - "country_jp_region_31", - "country_jp_region_32", - "country_jp_region_33", - "country_jp_region_34", - "country_jp_region_35", - "country_jp_region_36", - "country_jp_region_37", - "country_jp_region_38", - "country_jp_region_39", - "country_jp_region_40", - "country_jp_region_41", - "country_jp_region_42", - "country_jp_region_43", - "country_jp_region_44", - "country_jp_region_45", - "country_jp_region_46", - "country_jp_region_47", - "country_jp_region_05", - "country_jp_region_02", - "country_jp_region_07", - "country_jp_region_01", - "country_jp_region_08", - "country_jp_region_03", - "country_jp_region_04", - "country_jp_region_09", - "country_jp_region_06", - "country_je", - "country_jo", - "country_kz", - "country_ke", - "country_ki", - "country_kp", - "country_kr", - "country_kw", - "country_kg", - "country_la", - "country_lv", - "country_lb", - "country_ls", - "country_lr", - "country_ly", - "country_li", - "country_lt", - "country_lu", - "country_mo", - "country_mk", - "country_mg", - "country_mw", - "country_my", - "country_mv", - "country_ml", - "country_mt", - "country_mh", - "country_mq", - "country_mr", - "country_mu", - "country_yt", - "country_mx", - "country_fm", - "country_md", - "country_mc", - "country_mn", - "country_me", - "country_ms", - "country_ma", - "country_mz", - "country_mm", - "country_na", - "country_nr", - "country_np", - "country_nl", - "country_nc", - "country_nz", - "country_ni", - "country_ne", - "country_ng", - "country_nu", - "country_nf", - "country_mp", - "country_no", - "country_no_region_10", - "country_no_region_11", - "country_no_region_12", - "country_no_region_14", - "country_no_region_15", - "country_no_region_16", - "country_no_region_17", - "country_no_region_18", - "country_no_region_19", - "country_no_region_20", - "country_no_region_30", - "country_no_region_34", - "country_no_region_38", - "country_no_region_42", - "country_no_region_46", - "country_no_region_50", - "country_no_region_54", - "country_no_region_01", - "country_no_region_02", - "country_no_region_03", - "country_no_region_04", - "country_no_region_05", - "country_no_region_06", - "country_no_region_07", - "country_no_region_08", - "country_no_region_09", - "country_om", - "country_pk", - "country_pw", - "country_ps", - "country_pa", - "country_pg", - "country_py", - "country_pe", - "country_ph", - "country_pn", - "country_pl", - "country_pt", - "country_pr", - "country_qa", - "country_re", - "country_ro", - "country_ru", - "country_rw", - "country_bl", - "country_sh", - "country_kn", - "country_lc", - "country_mf", - "country_pm", - "country_vc", - "country_ws", - "country_sm", - "country_ss", - "country_st", - "country_sa", - "country_sn", - "country_rs", - "country_sc", - "country_sl", - "country_sg", - "country_sk", - "country_si", - "country_sb", - "country_so", - "country_za", - "country_gs", - "country_es", - "country_es_region_a coruna", - "country_es_region_alava", - "country_es_region_albacete", - "country_es_region_alicante", - "country_es_region_almeria", - "country_es_region_asturias", - "country_es_region_avila", - "country_es_region_badajoz", - "country_es_region_baleares", - "country_es_region_barcelona", - "country_es_region_burgos", - "country_es_region_caceres", - "country_es_region_cadiz", - "country_es_region_cn", - "country_es_region_cantabria", - "country_es_region_castellon", - "country_es_region_ceuta", - "country_es_region_ciudad real", - "country_es_region_cordoba", - "country_es_region_cuenca", - "country_es_region_gipuzkoa", - "country_es_region_girona", - "country_es_region_granada", - "country_es_region_guadalajara", - "country_es_region_guipuzcoa", - "country_es_region_huelva", - "country_es_region_huesca", - "country_es_region_jaen", - "country_es_region_la rioja", - "country_es_region_las palmas", - "country_es_region_leon", - "country_es_region_lleida", - "country_es_region_lugo", - "country_es_region_madrid", - "country_es_region_malaga", - "country_es_region_melilla", - "country_es_region_murcia", - "country_es_region_navarra", - "country_es_region_ourense", - "country_es_region_palencia", - "country_es_region_pontevedra", - "country_es_region_salamanca", - "country_es_region_santa cruz de tenerife", - "country_es_region_segovia", - "country_es_region_sevilla", - "country_es_region_soria", - "country_es_region_tarragona", - "country_es_region_teruel", - "country_es_region_toledo", - "country_es_region_valencia", - "country_es_region_valladolid", - "country_es_region_vizcaya", - "country_es_region_zamora", - "country_es_region_zaragoza", - "country_lk", - "country_sd", - "country_sr", - "country_sj", - "country_sz", - "country_se", - "country_ch", - "country_ch_region_ag", - "country_ch_region_ar", - "country_ch_region_ai", - "country_ch_region_bl", - "country_ch_region_bs", - "country_ch_region_be", - "country_ch_region_fr", - "country_ch_region_ge", - "country_ch_region_gl", - "country_ch_region_gr", - "country_ch_region_ju", - "country_ch_region_lu", - "country_ch_region_ne", - "country_ch_region_nw", - "country_ch_region_ow", - "country_ch_region_sh", - "country_ch_region_sz", - "country_ch_region_so", - "country_ch_region_sg", - "country_ch_region_ti", - "country_ch_region_tg", - "country_ch_region_ur", - "country_ch_region_vs", - "country_ch_region_vd", - "country_ch_region_zh", - "country_ch_region_zg", - "country_sy", - "country_tw", - "country_tj", - "country_tz", - "country_th", - "country_tl", - "country_tg", - "country_tk", - "country_to", - "country_tt", - "country_tn", - "country_tr", - "country_tm", - "country_tc", - "country_tv", - "country_ug", - "country_ua", - "country_ae", - "country_gb", - "country_us", - "country_us_region_al", - "country_us_region_ak", - "country_us_region_as", - "country_us_region_az", - "country_us_region_ar", - "country_us_region_af", - "country_us_region_aa", - "country_us_region_ac", - "country_us_region_ae", - "country_us_region_am", - "country_us_region_ap", - "country_us_region_ca", - "country_us_region_co", - "country_us_region_ct", - "country_us_region_de", - "country_us_region_dc", - "country_us_region_fm", - "country_us_region_fl", - "country_us_region_ga", - "country_us_region_gu", - "country_us_region_hi", - "country_us_region_id", - "country_us_region_il", - "country_us_region_in", - "country_us_region_ia", - "country_us_region_ks", - "country_us_region_ky", - "country_us_region_la", - "country_us_region_me", - "country_us_region_mh", - "country_us_region_md", - "country_us_region_ma", - "country_us_region_mi", - "country_us_region_mn", - "country_us_region_ms", - "country_us_region_mo", - "country_us_region_mt", - "country_us_region_ne", - "country_us_region_nv", - "country_us_region_nh", - "country_us_region_nj", - "country_us_region_nm", - "country_us_region_ny", - "country_us_region_nc", - "country_us_region_nd", - "country_us_region_mp", - "country_us_region_oh", - "country_us_region_ok", - "country_us_region_or", - "country_us_region_pa", - "country_us_region_pr", - "country_us_region_ri", - "country_us_region_sc", - "country_us_region_sd", - "country_us_region_tn", - "country_us_region_tx", - "country_us_region_ut", - "country_us_region_vt", - "country_us_region_vi", - "country_us_region_va", - "country_us_region_wa", - "country_us_region_wv", - "country_us_region_wi", - "country_us_region_wy", - "country_um", - "country_uy", - "country_uz", - "country_vu", - "country_ve", - "country_vn", - "country_vg", - "country_vi", - "country_wf", - "country_eh", - "country_ye", - "country_zm", - "country_zw" - ] - }, - "attribute-card": { - "additionalProperties": false, - "properties": { - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["spinner"] - }, - "attribute-form": { - "additionalProperties": false, - "properties": { - "name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Name" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "Name of this attribute. It does not have to be unique." - }, - "v8n_required": { "type": "string", "default": "Please name this attribute." }, - "v8n_too_long": { - "type": "string", - "default": "Please choose a name that is 500 characters long or less." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_too_long"] - }, - "value": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Value" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "Value of this attribute. Attribute values are automatically HTML-escaped." - }, - "v8n_required": { - "type": "string", - "default": "Please provide a value for this attribute." - }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we can't store values that are more than 1000 characters long." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_too_long"] - }, - "visibility": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Visibility" }, - "option_public": { "type": "string", "default": "Everyone" }, - "option_restricted": { "type": "string", "default": "Store admins" }, - "option_private": { "type": "string", "default": "Only me" }, - "helper_text": { - "type": "string", - "default": "Controls who can see this attribute. Public attributes can be shown to anyone, including customers. Private attributes are more suitable for configuration or technical details which are irrelevant to the public. Restricted attributes can only be viewed with the OAuth client that created them." - } - }, - "required": [ - "label", - "option_public", - "option_restricted", - "option_private", - "helper_text" - ] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date": { "type": "string", "default": "{{value, date}}" }, - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" } - }, - "required": ["date", "date_created", "date_modified"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove this attribute? You won't be able to bring it back." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": ["name", "value", "visibility", "timestamps", "delete", "create", "spinner"] - }, - "customer-form": { - "additionalProperties": false, - "properties": { - "status": { - "additionalProperties": false, - "properties": { - "password_change_success": { - "type": "string", - "default": "You have successfully set a new password for {{ email }}." - }, - "close": { "type": "string", "default": "Close" } - }, - "required": ["password_change_success", "close"] - }, - "error": { - "additionalProperties": false, - "properties": { - "email_already_used": { - "type": "string", - "default": "This email is already in use. Please use a different email." - } - }, - "required": ["email_already_used"] - }, - "first-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "First name" }, - "placeholder": { "type": "string", "default": "Not set" }, - "helper_text": { "type": "string", "default": "Customer's given name, optional." }, - "v8n_too_long": { - "type": "string", - "default": "We can't store first names longer than 50 characters." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "last-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Last name" }, - "placeholder": { "type": "string", "default": "Not set" }, - "helper_text": { "type": "string", "default": "Customer's surname, optional." }, - "v8n_too_long": { - "type": "string", - "default": "We can't store last names longer than 50 characters." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "tax-id": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Tax ID" }, - "placeholder": { "type": "string", "default": "Not set" }, - "helper_text": { - "type": "string", - "default": "Tax identification number for this customer, optional." - }, - "v8n_too_long": { - "type": "string", - "default": "We can't store tax IDs longer than 50 characters." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "email": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Email" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "This email will be used as the login to the Checkout and Customer Portal." - }, - "helper_text_last_login_date": { - "type": "string", - "default": "This customer's login to the Checkout and Customer Portal. Last used on {{ date, date }} at {{ date, time }}." - }, - "v8n_too_long": { - "type": "string", - "default": "We can't store emails longer than 100 characters." - }, - "v8n_invalid_email": { "type": "string", "default": "This email is invalid." }, - "v8n_required": { "type": "string", "default": "Please fill out this field." } - }, - "required": [ - "label", - "placeholder", - "helper_text", - "helper_text_last_login_date", - "v8n_too_long", - "v8n_invalid_email", - "v8n_required" - ] - }, - "is-anonymous": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Account type" }, - "helper_text": { - "type": "string", - "default": "Guest customers dont't have access to Customer Portal. Once the account type is set, it can not be changed." - }, - "option_true": { "type": "string", "default": "Guest" }, - "option_false": { "type": "string", "default": "Registered" } - }, - "required": ["label", "helper_text", "option_true", "option_false"] - }, - "password": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Password" }, - "placeholder": { "type": "string", "default": "Required" }, - "placeholder_new": { "type": "string", "default": "Keep current password" }, - "helper_text_new": { - "type": "string", - "default": "To change this customer's password, enter a new password here. If you leave it blank, their password will remain the same." - }, - "v8n_too_long": { - "type": "string", - "default": "Please use a password that is no longer than 50 characters." - }, - "v8n_too_weak": { - "type": "string", - "default": "Please use a stronger password. To make this password stronger, make it at least 8 characters long and include a few upper and lower case letters, numbers, and special characters." - }, - "v8n_required": { "type": "string", "default": "Please fill out this field." } - }, - "required": [ - "label", - "placeholder", - "placeholder_new", - "helper_text_new", - "v8n_too_long", - "v8n_too_weak", - "v8n_required" - ] - }, - "password-old": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Old password" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { - "type": "string", - "default": "Enter the old password to set a new password. If you're a store admin, you can leave this field blank." - }, - "v8n_required": { "type": "string", "default": "Please fill out this field." } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "forgot-password": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "One-time code" }, - "placeholder": { "type": "string", "default": "Not set" }, - "helper_text": { - "type": "string", - "default": "Set a one-time code that this customer can use instead of a password to sign in. Keep in mind that this code will expire after 30 minutes." - }, - "helper_text_expired_on": { - "type": "string", - "default": "A one-time code that this customer can use instead of a password to sign in. This code expired on {{ expiresOn, date }} at {{ expiresOn, time }}." - }, - "helper_text_expires_in": { - "type": "string", - "default": "A one-time code that this customer can use instead of a password to sign in. This code will expire in {{ expiresInMin, relative }}." - }, - "v8n_too_long": { - "type": "string", - "default": "Please use a code that is no longer than 50 characters." - } - }, - "required": [ - "label", - "placeholder", - "helper_text", - "helper_text_expired_on", - "helper_text_expires_in", - "v8n_too_long" - ] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "date": { "type": "string", "default": "{{value, date}}" } - }, - "required": ["date_created", "date_modified", "date"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "This action is irreversible. Are you sure you want to delete this customer?" - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "status", - "error", - "first-name", - "last-name", - "tax-id", - "email", - "is-anonymous", - "password", - "password-old", - "forgot-password", - "timestamps", - "delete", - "create", - "spinner" - ] - }, - "payment-method-card": { - "additionalProperties": false, - "properties": { - "cancel": { "type": "string", "default": "Cancel" }, - "delete": { "type": "string", "default": "Delete" }, - "add": { "type": "string", "default": "Add payment method" }, - "update": { "type": "string", "default": "Update payment method" }, - "delete_prompt": { - "type": "string", - "default": "This payment method will be permanently deleted from your account. Would you like to continue?" - }, - "expires": { "type": "string", "default": "Expires" }, - "last_4_digits": { "type": "string", "default": "Last 4 digits" }, - "unknown": { "type": "string", "default": "Unknown" }, - "dialog": { - "additionalProperties": false, - "properties": { - "close": { "type": "string", "default": "Close" }, - "dialog_header_add": { "type": "string", "default": "Add payment method" }, - "dialog_header_update": { "type": "string", "default": "Update payment method" }, - "update-payment-method-form": { - "additionalProperties": false, - "properties": { - "status": { - "additionalProperties": false, - "properties": { - "cc_token_success": { - "type": "string", - "default": "Card details saved successfully." - }, - "close": { "type": "string", "default": "Close" } - }, - "required": ["cc_token_success", "close"] - }, - "error": { - "additionalProperties": false, - "properties": { - "cc_token_invalid": { - "type": "string", - "default": "Unfortunately, we couldn't save your card details. Please try again later or use a different card." - } - }, - "required": ["cc_token_invalid"] - }, - "template-set": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Template set" }, - "dialog": { - "additionalProperties": false, - "properties": { - "cancel": { "type": "string", "default": "Cancel" }, - "close": { "type": "string", "default": "Close" }, - "header": { "type": "string", "default": "Choose a template set" }, - "selection": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" }, - "search": { "type": "string", "default": "Search" }, - "clear": { "type": "string", "default": "Clear" }, - "pagination": { - "additionalProperties": false, - "properties": { - "search_button_text": { "type": "string", "default": "Search" }, - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { - "type": "string", - "default": "{{from}}-{{to}} out of {{total}}" - }, - "previous": { "type": "string", "default": "Previous" }, - "card": { - "additionalProperties": false, - "properties": { - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { - "type": "string", - "default": "No template sets found" - }, - "loading_error": { - "type": "string", - "default": "Unknown error" - } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["spinner"] - } - }, - "required": [ - "search_button_text", - "first", - "last", - "next", - "pagination", - "previous", - "card" - ] - }, - "query-builder": { - "additionalProperties": false, - "properties": { - "filters": { - "additionalProperties": false, - "properties": {}, - "required": [] - }, - "add_or_clause": { "type": "string", "default": "Add OR clause" }, - "add_value": { "type": "string", "default": "Add value" }, - "code": { "type": "string", "default": "Code" }, - "date": { "type": "string", "default": "{{value, date}}" }, - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "delete": { "type": "string", "default": "Delete" }, - "field": { "type": "string", "default": "Field" }, - "hidden": { "type": "string", "default": "Hidden" }, - "is_defined_false": { "type": "string", "default": "Not defined" }, - "is_defined_true": { "type": "string", "default": "Defined" }, - "name": { "type": "string", "default": "Name" }, - "operator_equal": { "type": "string", "default": "Equal" }, - "operator_greaterthan": { - "type": "string", - "default": "Greater than" - }, - "operator_greaterthanorequal": { - "type": "string", - "default": "Greater than or equal" - }, - "operator_in": { "type": "string", "default": "One of" }, - "operator_isdefined": { "type": "string", "default": "Is defined" }, - "operator_lessthan": { "type": "string", "default": "Less than" }, - "operator_lessthanorequal": { - "type": "string", - "default": "Less than or equal" - }, - "operator_not": { "type": "string", "default": "Not equal" }, - "or": { "type": "string", "default": "Or" }, - "query_builder_group": { - "type": "string", - "default": "Group of filters" - }, - "query_builder_rule": { "type": "string", "default": "Filter" }, - "range_from": { "type": "string", "default": "From" }, - "range_to": { "type": "string", "default": "To" }, - "type": { "type": "string", "default": "Type" }, - "type_any": { - "type": "string", - "default": "Field of unknown type" - }, - "type_attribute": { - "type": "string", - "default": "Key-value resource" - }, - "type_date": { "type": "string", "default": "Date field" }, - "type_here": { "type": "string", "default": "Type here..." }, - "type_number": { "type": "string", "default": "Numeric field" }, - "type_string": { "type": "string", "default": "Text field" }, - "used_codes": { "type": "string", "default": "Codes used" }, - "value": { "type": "string", "default": "Value" } - }, - "required": [ - "filters", - "add_or_clause", - "add_value", - "code", - "date", - "date_created", - "date_modified", - "delete", - "field", - "hidden", - "is_defined_false", - "is_defined_true", - "name", - "operator_equal", - "operator_greaterthan", - "operator_greaterthanorequal", - "operator_in", - "operator_isdefined", - "operator_lessthan", - "operator_lessthanorequal", - "operator_not", - "or", - "query_builder_group", - "query_builder_rule", - "range_from", - "range_to", - "type", - "type_any", - "type_attribute", - "type_date", - "type_here", - "type_number", - "type_string", - "used_codes", - "value" - ] - } - }, - "required": [ - "label", - "helper_text", - "search", - "clear", - "pagination", - "query-builder" - ] - } - }, - "required": ["cancel", "close", "header", "selection"] - }, - "card": { - "additionalProperties": false, - "properties": { - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "Click to select" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["spinner"] - }, - "helper_text": { - "type": "string", - "default": "Template set determines which payment gateway and tokenization service will be used to capture card details." - } - }, - "required": ["label", "dialog", "card", "helper_text"] - }, - "cc-token": { - "additionalProperties": false, - "properties": { - "tokenize": { "type": "string", "default": "Save card" }, - "payment-card-embed": { - "additionalProperties": false, - "properties": { - "stripe": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Card details" }, - "status": { - "additionalProperties": false, - "properties": { - "idle": { - "type": "string", - "default": "Your card details are securely processed by Stripe. Visit https://stripe.com to learn more." - }, - "busy": { - "type": "string", - "default": "Encrypting your card details..." - }, - "fail": { - "type": "string", - "default": "This service is currently unavailable. Please try again later." - }, - "unsupported": { - "type": "string", - "default": "We don't support this card type. Please try another card." - } - }, - "required": ["idle", "busy", "fail", "unsupported"] - } - }, - "required": ["label", "status"] - }, - "square": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Card details" }, - "status": { - "additionalProperties": false, - "properties": { - "idle": { - "type": "string", - "default": "Your card details are securely processed by Square. Visit https://squareup.com to learn more." - }, - "busy": { - "type": "string", - "default": "Encrypting your card details..." - }, - "fail": { - "type": "string", - "default": "This service is currently unavailable. Please try again later." - }, - "unsupported": { - "type": "string", - "default": "We don't support this card type. Please try another card." - } - }, - "required": ["idle", "busy", "fail", "unsupported"] - } - }, - "required": ["label", "status"] - }, - "default": { - "additionalProperties": false, - "properties": { - "cc-number": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Card number" }, - "placeholder": { - "type": "string", - "default": "1234 1234 1234 1234" - }, - "v8n_required": { - "type": "string", - "default": "Enter a card number." - }, - "v8n_invalid": { - "type": "string", - "default": "Check your card number – it doesn't seem to be valid." - }, - "v8n_unsupported": { - "type": "string", - "default": "We don't support this card type." - } - }, - "required": [ - "label", - "placeholder", - "v8n_required", - "v8n_invalid", - "v8n_unsupported" - ] - }, - "cc-exp": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Expires on" }, - "placeholder": { "type": "string", "default": "MM/YYYY" }, - "v8n_required": { - "type": "string", - "default": "Enter an expiry date." - }, - "v8n_invalid": { - "type": "string", - "default": "Enter a date as MM/YYYY." - }, - "v8n_expired": { - "type": "string", - "default": "Your card has expired." - } - }, - "required": [ - "label", - "placeholder", - "v8n_required", - "v8n_invalid", - "v8n_expired" - ] - }, - "cc-csc": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "CSC" }, - "placeholder": { "type": "string", "default": "XXX" }, - "v8n_required": { - "type": "string", - "default": "Enter a security code." - }, - "v8n_invalid": { - "type": "string", - "default": "Enter a 3-4 digits code." - } - }, - "required": ["label", "placeholder", "v8n_required", "v8n_invalid"] - }, - "status": { - "additionalProperties": false, - "properties": { - "idle": { - "type": "string", - "default": "Your card details are securely processed by Foxy.io. Visit https://foxy.io to learn more." - }, - "busy": { - "type": "string", - "default": "Encrypting your card details..." - }, - "fail": { - "type": "string", - "default": "This service is currently unavailable. Please try again later." - }, - "misconfigured": { - "type": "string", - "default": "This form is not configured correctly. If you are seeing this message as a customer, please report this issue to the store support team." - } - }, - "required": ["idle", "busy", "fail", "misconfigured"] - } - }, - "required": ["cc-number", "cc-exp", "cc-csc", "status"] - } - }, - "required": ["stripe", "square", "default"] - } - }, - "required": ["tokenize", "payment-card-embed"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" }, - "loading_empty": { - "type": "string", - "default": "This form works only with existing payment methods" - } - }, - "required": ["refresh", "loading_busy", "loading_error", "loading_empty"] - } - }, - "required": ["status", "error", "template-set", "cc-token", "spinner"] - } - }, - "required": [ - "close", - "dialog_header_add", - "dialog_header_update", - "update-payment-method-form" - ] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No payment method" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "cancel", - "delete", - "add", - "update", - "delete_prompt", - "expires", - "last_4_digits", - "unknown", - "dialog", - "spinner" - ] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - }, - "subscription-form": { - "additionalProperties": false, - "properties": { - "day": { "type": "string", "default": "Day" }, - "day_plural": { "type": "string", "default": "Days" }, - "week": { "type": "string", "default": "Week" }, - "week_plural": { "type": "string", "default": "Weeks" }, - "month": { "type": "string", "default": "Month" }, - "month_plural": { "type": "string", "default": "Months" }, - "year": { "type": "string", "default": "Year" }, - "year_plural": { "type": "string", "default": "Years" }, - "cancel": { "type": "string", "default": "Cancel" }, - "close": { "type": "string", "default": "Close" }, - "confirm": { "type": "string", "default": "Confirm" }, - "currency": { "type": "string", "default": "Currency" }, - "daily": { "type": "string", "default": "Daily" }, - "daily_plural": { "type": "string", "default": "Every {{count}} days" }, - "end_date": { "type": "string", "default": "End date" }, - "frequency": { - "type": "string", - "default": "$t(subscription-form.{{units}}, { \"count\": {{count}}, \"ns\": \"customer\" })" - }, - "frequency_label": { "type": "string", "default": "Frequency" }, - "item_plural": { "type": "string", "default": "Items" }, - "monthly": { "type": "string", "default": "Monthly" }, - "monthly_plural": { "type": "string", "default": "Every {{count}} months" }, - "next_transaction_date": { "type": "string", "default": "Next transaction date" }, - "start_date": { "type": "string", "default": "Start date" }, - "price_recurring": { - "type": "string", - "default": "{{amount, price}} $t(subscription-form.frequency, { \"count\": \"{{count}}\", \"units\": \"{{units}}\", \"ns\": \"customer\" })" - }, - "price_twice_a_month": { - "type": "string", - "default": "{{amount, price}} $t(subscription-form.twice_a_month, { \"ns\": \"customer\" })" - }, - "subscription_active": { - "type": "string", - "default": "Including shipping, taxes, etc. Next payment on {{date, date}}." - }, - "subscription_cancelled": { - "type": "string", - "default": "Including shipping, taxes, etc. Ended on {{date, date}}." - }, - "subscription_failed": { - "type": "string", - "default": "Including shipping, taxes, etc. Payment failed on {{date, date}}." - }, - "subscription_inactive": { - "type": "string", - "default": "Including shipping, taxes, etc. Inactive." - }, - "subscription_will_be_cancelled": { - "type": "string", - "default": "Including shipping, taxes, etc. Ends on {{date, date}}." - }, - "subscription_will_be_active": { - "type": "string", - "default": "Including shipping, taxes, etc. Starts on {{date, date}}." - }, - "transaction_plural": { "type": "string", "default": "Transactions" }, - "twice_a_month": { "type": "string", "default": "Twice a month" }, - "undo_cancel": { "type": "string", "default": "Review" }, - "undo_confirm": { "type": "string", "default": "Discard" }, - "undo_header": { "type": "string", "default": "Unsaved changes" }, - "undo_message": { - "type": "string", - "default": "Looks like you didn't save your changes! What would you like to do with them?" - }, - "weekly": { "type": "string", "default": "Weekly" }, - "weekly_plural": { "type": "string", "default": "Every {{count}} weeks" }, - "yearly": { "type": "string", "default": "Yearly" }, - "yearly_plural": { "type": "string", "default": "Every {{count}} years" }, - "customer": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Customer" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_error"] - } - }, - "required": ["label", "spinner"] - }, - "past-due-amount": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Past due amount" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { - "type": "string", - "default": "If a subscription payment is missed, this amount will be increased by that payment. The next time the subscription runs, it may be charged automatically depending on your store's subscription settings." - } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "attributes": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Attributes" }, - "delete_confirm": { "type": "string", "default": "Delete" }, - "delete_cancel": { "type": "string", "default": "Cancel" }, - "delete_message": { - "type": "string", - "default": "Are you sure you'd like to remove this attribute? You won't be able to bring it back." - }, - "delete_header": { "type": "string", "default": "Delete attribute?" }, - "pagination": { - "additionalProperties": false, - "properties": { - "create_button_text": { "type": "string", "default": "Add attribute +" }, - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { "type": "string", "default": "{{from}}-{{to}} out of {{total}}" }, - "previous": { "type": "string", "default": "Previous" }, - "card": { - "additionalProperties": false, - "properties": { - "delete_button_text": { "type": "string", "default": "Remove" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No attributes" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["delete_button_text", "spinner"] - } - }, - "required": [ - "create_button_text", - "first", - "last", - "next", - "pagination", - "previous", - "card" - ] - }, - "dialog": { - "additionalProperties": false, - "properties": { - "close": { "type": "string", "default": "Close" }, - "header_update": { "type": "string", "default": "Attribute" }, - "header_create": { "type": "string", "default": "New attribute" }, - "save": { "type": "string", "default": "Save" }, - "undo_header": { "type": "string", "default": "Unsaved changes" }, - "undo_message": { - "type": "string", - "default": "Looks like you didn't save your changes! What would you like to do with them?" - }, - "undo_cancel": { "type": "string", "default": "Review" }, - "undo_confirm": { "type": "string", "default": "Discard" }, - "cancel": { "type": "string", "default": "Cancel" }, - "confirm": { "type": "string", "default": "Confirm" }, - "create": { "type": "string", "default": "Create" }, - "date": { "type": "string", "default": "{{value, date}}" }, - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "delete": { "type": "string", "default": "Delete" }, - "delete_prompt": { - "type": "string", - "default": "This attribute will be permanently removed. Are you sure?" - }, - "name": { "type": "string", "default": "Name" }, - "v8n_required": { "type": "string", "default": "Required" }, - "v8n_too_long": { "type": "string", "default": "Too long" }, - "value": { "type": "string", "default": "Value" }, - "visibility": { "type": "string", "default": "Visibility" }, - "visibility_private": { "type": "string", "default": "Only me" }, - "visibility_public": { "type": "string", "default": "Everyone" }, - "visibility_restricted": { "type": "string", "default": "Store admins" }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "close", - "header_update", - "header_create", - "save", - "undo_header", - "undo_message", - "undo_cancel", - "undo_confirm", - "cancel", - "confirm", - "create", - "date", - "date_created", - "date_modified", - "delete", - "delete_prompt", - "name", - "v8n_required", - "v8n_too_long", - "value", - "visibility", - "visibility_private", - "visibility_public", - "visibility_restricted", - "spinner" - ] - } - }, - "required": [ - "label", - "delete_confirm", - "delete_cancel", - "delete_message", - "delete_header", - "pagination", - "dialog" - ] - }, - "items": { - "additionalProperties": false, - "properties": { - "pagination": { - "additionalProperties": false, - "properties": { - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { "type": "string", "default": "{{from}}-{{to}} out of {{total}}" }, - "previous": { "type": "string", "default": "Previous" }, - "card": { - "additionalProperties": false, - "properties": { - "daily": { "type": "string", "default": "Daily" }, - "daily_plural": { "type": "string", "default": "Every {{count}} days" }, - "frequency": { - "type": "string", - "default": "$t(subscription-form.pagination.card.{{units}}, { \"count\": {{count}}, \"ns\": \"customer\" })" - }, - "monthly": { "type": "string", "default": "Monthly" }, - "monthly_plural": { "type": "string", "default": "Every {{count}} months" }, - "subinfo_recurring": { - "type": "string", - "default": "$t(subscription-form.pagination.card.frequency, { \"count\": \"{{count}}\", \"units\": \"{{units}}\", \"ns\": \"customer\" }) from {{startDate, date}}" - }, - "subinfo_twice_a_month": { - "type": "string", - "default": "$t(subscription-form.pagination.card.twice_a_month, { \"ns\": \"customer\" }) from {{startDate, date}}" - }, - "twice_a_month": { "type": "string", "default": "Twice a month" }, - "no_code": { "type": "string", "default": "No SKU" }, - "weekly": { "type": "string", "default": "Weekly" }, - "weekly_plural": { "type": "string", "default": "Every {{count}} weeks" }, - "yearly": { "type": "string", "default": "Yearly" }, - "yearly_plural": { "type": "string", "default": "Every {{count}} years" }, - "price": { "type": "string", "default": "{{amount, price}}" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No items" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "daily", - "daily_plural", - "frequency", - "monthly", - "monthly_plural", - "subinfo_recurring", - "subinfo_twice_a_month", - "twice_a_month", - "no_code", - "weekly", - "weekly_plural", - "yearly", - "yearly_plural", - "price", - "spinner" - ] - } - }, - "required": ["first", "last", "next", "pagination", "previous", "card"] - } - }, - "required": ["pagination"] - }, - "transactions": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Transactions" }, - "pagination": { - "additionalProperties": false, - "properties": { - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { "type": "string", "default": "{{from}}-{{to}} out of {{total}}" }, - "previous": { "type": "string", "default": "Previous" }, - "card": { - "additionalProperties": false, - "properties": { - "code": { "type": "string", "default": "Code" }, - "customer": { "type": "string", "default": "Customer" }, - "description": { "type": "string", "default": "Description" }, - "price": { "type": "string", "default": "{{amount, price}}" }, - "time": { "type": "string", "default": "{{value, date}}" }, - "status_capturing": { "type": "string", "default": "Capturing" }, - "status_captured": { "type": "string", "default": "Captured" }, - "status_approved": { "type": "string", "default": "Approved" }, - "status_authorized": { "type": "string", "default": "Authorized" }, - "status_pending": { "type": "string", "default": "Pending" }, - "status_completed": { "type": "string", "default": "Completed" }, - "status_problem": { "type": "string", "default": "Problem" }, - "status_pending_fraud_review": { - "type": "string", - "default": "Pending_fraud_review" - }, - "status_rejected": { "type": "string", "default": "Rejected" }, - "status_declined": { "type": "string", "default": "Declined" }, - "status_refunding": { "type": "string", "default": "Refunding" }, - "status_refunded": { "type": "string", "default": "Refunded" }, - "status_voided": { "type": "string", "default": "Voided" }, - "status_verified": { "type": "string", "default": "Verified" }, - "summary": { "type": "string", "default": "{{most_expensive_item.name}}" }, - "summary_plural": { - "type": "string", - "default": "{{most_expensive_item.name}} and {{count_minus_one}} more" - }, - "summary_payment_method_change": { - "type": "string", - "default": "Payment method change" - }, - "summary_subscription_modification": { - "type": "string", - "default": "Subscription modification" - }, - "summary_subscription_cancellation": { - "type": "string", - "default": "Subscription cancellation" - }, - "source_MIT": { - "type": "string", - "default": "This transaction was initiated by the merchant" - }, - "source_CIT": { - "type": "string", - "default": "This transaction was initiated by the customer" - }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No transactions" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "code", - "customer", - "description", - "price", - "time", - "status_capturing", - "status_captured", - "status_approved", - "status_authorized", - "status_pending", - "status_completed", - "status_problem", - "status_pending_fraud_review", - "status_rejected", - "status_declined", - "status_refunding", - "status_refunded", - "status_voided", - "status_verified", - "summary", - "summary_plural", - "summary_payment_method_change", - "summary_subscription_modification", - "summary_subscription_cancellation", - "source_MIT", - "source_CIT", - "spinner" - ] - } - }, - "required": ["first", "last", "next", "pagination", "previous", "card"] - } - }, - "required": ["label", "pagination"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "date": { "type": "string", "default": "{{value, date}}" } - }, - "required": ["date_created", "date_modified", "date"] - } - }, - "required": [ - "day", - "day_plural", - "week", - "week_plural", - "month", - "month_plural", - "year", - "year_plural", - "cancel", - "close", - "confirm", - "currency", - "daily", - "daily_plural", - "end_date", - "frequency", - "frequency_label", - "item_plural", - "monthly", - "monthly_plural", - "next_transaction_date", - "start_date", - "price_recurring", - "price_twice_a_month", - "subscription_active", - "subscription_cancelled", - "subscription_failed", - "subscription_inactive", - "subscription_will_be_cancelled", - "subscription_will_be_active", - "transaction_plural", - "twice_a_month", - "undo_cancel", - "undo_confirm", - "undo_header", - "undo_message", - "weekly", - "weekly_plural", - "yearly", - "yearly_plural", - "customer", - "past-due-amount", - "attributes", - "items", - "transactions", - "spinner", - "timestamps" - ] - }, - "subscriptions-table": { - "additionalProperties": false, - "properties": { - "daily": { "type": "string", "default": "Daily" }, - "daily_plural": { "type": "string", "default": "Every {{count}} days" }, - "frequency": { - "type": "string", - "default": "$t(subscriptions-table.{{units}}, { \"count\": {{count}}, \"ns\": \"customer\" })" - }, - "monthly": { "type": "string", "default": "Monthly" }, - "monthly_plural": { "type": "string", "default": "Every {{count}} months" }, - "price_recurring": { - "type": "string", - "default": "{{amount, price}} $t(subscriptions-table.frequency, { \"count\": \"{{count}}\", \"units\": \"{{units}}\", \"ns\": \"customer\" })" - }, - "price_twice_a_month": { - "type": "string", - "default": "{{amount, price}} $t(subscriptions-table.twice_a_month, { \"ns\": \"customer\" })" - }, - "subscription_active": { "type": "string", "default": "Next payment on {{date, date}}" }, - "subscription_cancelled": { "type": "string", "default": "Ended on {{date, date}}" }, - "subscription_failed": { "type": "string", "default": "Payment failed on {{date, date}}" }, - "subscription_inactive": { "type": "string", "default": "Inactive" }, - "subscription_will_be_cancelled": { "type": "string", "default": "Ends on {{date, date}}" }, - "subscription_will_be_active": { "type": "string", "default": "Starts on {{date, date}}" }, - "transaction_summary": { "type": "string", "default": "{{most_expensive_item.name}}" }, - "twice_a_month": { "type": "string", "default": "Twice a month" }, - "update": { "type": "string", "default": "Update" }, - "weekly": { "type": "string", "default": "Weekly" }, - "weekly_plural": { "type": "string", "default": "Every {{count}} weeks" }, - "yearly": { "type": "string", "default": "Yearly" }, - "yearly_plural": { "type": "string", "default": "Every {{count}} years" }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "daily", - "daily_plural", - "frequency", - "monthly", - "monthly_plural", - "price_recurring", - "price_twice_a_month", - "subscription_active", - "subscription_cancelled", - "subscription_failed", - "subscription_inactive", - "subscription_will_be_cancelled", - "subscription_will_be_active", - "transaction_summary", - "twice_a_month", - "update", - "weekly", - "weekly_plural", - "yearly", - "yearly_plural", - "spinner" - ] - }, - "transactions-table": { - "additionalProperties": false, - "properties": { - "date": { "type": "string", "default": "{{value, date}}" }, - "price": { "type": "string", "default": "{{amount, price}}" }, - "receipt": { "type": "string", "default": "Receipt" }, - "transaction_approved": { "type": "string", "default": "Approved" }, - "transaction_authorized": { "type": "string", "default": "Authorized" }, - "transaction_captured": { "type": "string", "default": "Captured" }, - "transaction_completed": { "type": "string", "default": "Completed" }, - "transaction_declined": { "type": "string", "default": "Declined" }, - "transaction_pending": { "type": "string", "default": "Pending" }, - "transaction_refunded": { "type": "string", "default": "Refunded" }, - "transaction_rejected": { "type": "string", "default": "Rejected" }, - "transaction_summary": { "type": "string", "default": "{{most_expensive_item.name}}" }, - "transaction_summary_plural": { - "type": "string", - "default": "{{most_expensive_item.name}} and {{count_minus_one}} more" - }, - "transaction_verified": { "type": "string", "default": "Verified" }, - "transaction_voided": { "type": "string", "default": "Voided" }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "date", - "price", - "receipt", - "transaction_approved", - "transaction_authorized", - "transaction_captured", - "transaction_completed", - "transaction_declined", - "transaction_pending", - "transaction_refunded", - "transaction_rejected", - "transaction_summary", - "transaction_summary_plural", - "transaction_verified", - "transaction_voided", - "spinner" - ] - } - }, - "required": [ - "address_plural", - "attribute_plural", - "cancel", - "close", - "create", - "customer", - "delete_prompt", - "payment_method_plural", - "save", - "subscription_plural", - "transaction_plural", - "undo_cancel", - "undo_confirm", - "undo_header", - "undo_message", - "update", - "address-card", - "address-form", - "attribute-card", - "attribute-form", - "customer-form", - "payment-method-card", - "spinner", - "subscription-form", - "subscriptions-table", - "transactions-table" - ] -} diff --git a/src/static/schemas/customers-table.json b/src/static/schemas/customers-table.json deleted file mode 100644 index 37a460b53..000000000 --- a/src/static/schemas/customers-table.json +++ /dev/null @@ -1,19 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "date": { "type": "string", "default": "{{value, date}}" }, - "date_created": { "type": "string", "default": "Created on" }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" }, - "loading_empty": { "type": "string", "default": "No data" } - }, - "required": ["refresh", "loading_busy", "loading_error", "loading_empty"] - } - }, - "required": ["date", "date_created", "spinner"] -} diff --git a/src/static/schemas/discount-builder.json b/src/static/schemas/discount-builder.json deleted file mode 100644 index 6760d1c21..000000000 --- a/src/static/schemas/discount-builder.json +++ /dev/null @@ -1,32 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "tier": { "type": "string", "default": "Tier" }, - "tier_by": { "type": "string", "default": "by" }, - "tier_if": { "type": "string", "default": "if" }, - "tier_allunits": { "type": "string", "default": "price of each item" }, - "tier_incremental": { "type": "string", "default": "price of additional items" }, - "tier_repeat": { "type": "string", "default": "price of next item" }, - "tier_single": { "type": "string", "default": "order total" }, - "tier_then": { "type": "string", "default": "then" }, - "quantity": { "type": "string", "default": "quantity" }, - "total": { "type": "string", "default": "total" }, - "reduce": { "type": "string", "default": "reduce" }, - "increase": { "type": "string", "default": "increase" } - }, - "required": [ - "tier", - "tier_by", - "tier_if", - "tier_allunits", - "tier_incremental", - "tier_repeat", - "tier_single", - "tier_then", - "quantity", - "total", - "reduce", - "increase" - ] -} diff --git a/src/static/schemas/discount-card.json b/src/static/schemas/discount-card.json deleted file mode 100644 index 753c9f0c9..000000000 --- a/src/static/schemas/discount-card.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "price": { "type": "string", "default": "{{amount, price}}" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["price", "spinner"] -} diff --git a/src/static/schemas/donation.json b/src/static/schemas/donation.json deleted file mode 100644 index 3e2f61305..000000000 --- a/src/static/schemas/donation.json +++ /dev/null @@ -1,25 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "comment_placeholder": { "type": "string", "default": "Anything you'd like to let us know" }, - "comment_label": { "type": "string", "default": "Comment" }, - "designation": { "type": "string", "default": "Designation" }, - "anonymous": { "type": "string", "default": "Remain anonymous" }, - "amount": { "type": "string", "default": "Amount" }, - "donate": { "type": "string", "default": "Donate {{amount}}" }, - "donate_recurrently": { - "type": "string", - "default": "Donate {{amount}} {{frequency, lowercase}}" - } - }, - "required": [ - "comment_placeholder", - "comment_label", - "designation", - "anonymous", - "amount", - "donate", - "donate_recurrently" - ] -} diff --git a/src/static/schemas/downloadable-card.json b/src/static/schemas/downloadable-card.json deleted file mode 100644 index 5f175ab78..000000000 --- a/src/static/schemas/downloadable-card.json +++ /dev/null @@ -1,16 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["spinner"] -} diff --git a/src/static/schemas/downloadable-form.json b/src/static/schemas/downloadable-form.json deleted file mode 100644 index 393146c19..000000000 --- a/src/static/schemas/downloadable-form.json +++ /dev/null @@ -1,160 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "item-category-uri": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Item category" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { - "type": "string", - "default": "The item category this product is part of (only categories with item delivery type of \"downloaded\" are displayed)." - }, - "v8n_required": { "type": "string", "default": "Please select an item category" } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Name" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { - "type": "string", - "default": "The name of this downloadable. This will be shown to the customer in the cart." - }, - "v8n_required": { "type": "string", "default": "Please enter a name" }, - "v8n_too_long": { - "type": "string", - "default": "Please shorten the name to 100 characters or less" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_too_long"] - }, - "code": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Code" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { - "type": "string", - "default": "The code for this downloadable. When adding this item to the cart, this is the code which will be used." - }, - "v8n_required": { "type": "string", "default": "Please enter a code" }, - "v8n_too_long": { - "type": "string", - "default": "Please shorten the code to 50 characters or less" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_too_long"] - }, - "price": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Price" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { - "type": "string", - "default": "The item total for this downloadable. This is the amount the customer will pay to purchase this downloadable item." - }, - "v8n_required": { "type": "string", "default": "Please enter a price" }, - "v8n_negative": { - "type": "string", - "default": "Downloadable products can't have a negative price" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_negative"] - }, - "upload": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "File" }, - "helper_text": { - "type": "string", - "default": "Any file you'd like your customers to have access to after purchasing this item. Maximum size is 500MB." - }, - "drop_label": { "type": "string", "default": "or drag it here" }, - "select_label": { "type": "string", "default": "Select file..." }, - "cancel": { "type": "string", "default": "Cancel" }, - "error_too_many_files": { "type": "string", "default": "Too many files" }, - "error_too_large": { "type": "string", "default": "File is too large" }, - "status_connecting": { "type": "string", "default": "Connecting..." }, - "status_stalled": { "type": "string", "default": "Stalled" }, - "status_processing": { "type": "string", "default": "Processing..." }, - "status_held": { "type": "string", "default": "Save changes to upload" }, - "status_complete": { "type": "string", "default": "Available for download" }, - "remaining_prefix": { "type": "string", "default": "remaining time: " }, - "remaining_unknown": { "type": "string", "default": "unknown remaining time" }, - "error_server_unavailable": { "type": "string", "default": "Server unavailable" }, - "error_unexpected_server_error": { "type": "string", "default": "Unexpected server error" }, - "error_forbidden": { "type": "string", "default": "Forbidden" } - }, - "required": [ - "label", - "helper_text", - "drop_label", - "select_label", - "cancel", - "error_too_many_files", - "error_too_large", - "status_connecting", - "status_stalled", - "status_processing", - "status_held", - "status_complete", - "remaining_prefix", - "remaining_unknown", - "error_server_unavailable", - "error_unexpected_server_error", - "error_forbidden" - ] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "date": { "type": "string", "default": "{{value, date}}" } - }, - "required": ["date_created", "date_modified", "date"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove this downloadable? You won't be able to bring it back." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "item-category-uri", - "name", - "code", - "price", - "upload", - "timestamps", - "delete", - "create", - "spinner" - ] -} diff --git a/src/static/schemas/email-template-card.json b/src/static/schemas/email-template-card.json deleted file mode 100644 index 3dec417f5..000000000 --- a/src/static/schemas/email-template-card.json +++ /dev/null @@ -1,28 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "type_custom_url": { "type": "string", "default": "Custom (URL)" }, - "type_custom_text": { "type": "string", "default": "Custom (Text)" }, - "type_custom_html": { "type": "string", "default": "Custom (HTML)" }, - "type_mixed": { "type": "string", "default": "Mixed" }, - "type_default": { "type": "string", "default": "Default" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "type_custom_url", - "type_custom_text", - "type_custom_html", - "type_mixed", - "type_default", - "spinner" - ] -} diff --git a/src/static/schemas/email-template-form.json b/src/static/schemas/email-template-form.json deleted file mode 100644 index 4a1f25ee6..000000000 --- a/src/static/schemas/email-template-form.json +++ /dev/null @@ -1,89 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "cache": { "type": "string", "default": "Sync" }, - "cancel": { "type": "string", "default": "Cancel" }, - "confirm": { "type": "string", "default": "Confirm" }, - "create": { "type": "string", "default": "Create" }, - "date": { "type": "string", "default": "{{value, date}}" }, - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "default": { "type": "string", "default": "Default" }, - "delete": { "type": "string", "default": "Delete" }, - "delete_prompt": { - "type": "string", - "default": "This resource will be permanently removed. Are you sure?" - }, - "description": { "type": "string", "default": "Description" }, - "html_template": { "type": "string", "default": "HTML template" }, - "template_clipboard": { "type": "string", "default": "Upload source code" }, - "template_default": { "type": "string", "default": "Use default template" }, - "template_url": { "type": "string", "default": "Pull from public URL" }, - "text_template": { "type": "string", "default": "Text template" }, - "url": { "type": "string", "default": "URL" }, - "url_source_label": { "type": "string", "default": "Cached source" }, - "url_source_placeholder": { - "type": "string", - "default": "Template markup will appear here once cached" - }, - "clipboard_source_label": { "type": "string", "default": "Source" }, - "clipboard_source_placeholder": { - "type": "string", - "default": "Enter your template markup here" - }, - "subject": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Subject" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "template-language": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Language" }, - "placeholder": { "type": "string", "default": "Default (Nunjucks)" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "cache", - "cancel", - "confirm", - "create", - "date", - "date_created", - "date_modified", - "default", - "delete", - "delete_prompt", - "description", - "html_template", - "template_clipboard", - "template_default", - "template_url", - "text_template", - "url", - "url_source_label", - "url_source_placeholder", - "clipboard_source_label", - "clipboard_source_placeholder", - "subject", - "template-language", - "spinner" - ] -} diff --git a/src/static/schemas/error-entry-card.json b/src/static/schemas/error-entry-card.json deleted file mode 100644 index 1910b4399..000000000 --- a/src/static/schemas/error-entry-card.json +++ /dev/null @@ -1,26 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "client": { "type": "string", "default": "Client" }, - "customer": { "type": "string", "default": "Customer" }, - "cart": { "type": "string", "default": "Cart" }, - "subscription": { "type": "string", "default": "Subscription" }, - "transaction": { "type": "string", "default": "Transaction" }, - "date": { "type": "string", "default": "{{value, date}}" }, - "error": { "type": "string", "default": "Error" }, - "request": { "type": "string", "default": "Request" }, - "time": { "type": "string", "default": "{{value, time}}" } - }, - "required": [ - "client", - "customer", - "cart", - "subscription", - "transaction", - "date", - "error", - "request", - "time" - ] -} diff --git a/src/static/schemas/filter-attribute-card.json b/src/static/schemas/filter-attribute-card.json deleted file mode 100644 index fa5446e88..000000000 --- a/src/static/schemas/filter-attribute-card.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "no_name": { "type": "string", "default": "Custom filter" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["no_name", "spinner"] -} diff --git a/src/static/schemas/filter-attribute-form.json b/src/static/schemas/filter-attribute-form.json deleted file mode 100644 index f246d36e6..000000000 --- a/src/static/schemas/filter-attribute-form.json +++ /dev/null @@ -1,102 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "filter-query": { - "additionalProperties": false, - "properties": { - "add_or_clause": { "type": "string", "default": "Add OR clause" }, - "add_value": { "type": "string", "default": "Add value" }, - "date": { "type": "string", "default": "{{value, date}}" }, - "delete": { "type": "string", "default": "Delete" }, - "field": { "type": "string", "default": "Field" }, - "hidden": { "type": "string", "default": "Hidden" }, - "is_defined_false": { "type": "string", "default": "Not defined" }, - "is_defined_true": { "type": "string", "default": "Defined" }, - "name": { "type": "string", "default": "Name" }, - "operator_equal": { "type": "string", "default": "Equal" }, - "operator_greaterthan": { "type": "string", "default": "Greater than" }, - "operator_greaterthanorequal": { "type": "string", "default": "Greater than or equal" }, - "operator_in": { "type": "string", "default": "One of" }, - "operator_isdefined": { "type": "string", "default": "Is defined" }, - "operator_lessthan": { "type": "string", "default": "Less than" }, - "operator_lessthanorequal": { "type": "string", "default": "Less than or equal" }, - "operator_not": { "type": "string", "default": "Not equal" }, - "or": { "type": "string", "default": "Or" }, - "query_builder_group": { "type": "string", "default": "Group of filters" }, - "query_builder_rule": { "type": "string", "default": "Filter" }, - "range_from": { "type": "string", "default": "From" }, - "range_to": { "type": "string", "default": "To" }, - "type": { "type": "string", "default": "Type" }, - "type_any": { "type": "string", "default": "Field of unknown type" }, - "type_attribute": { "type": "string", "default": "Key-value resource" }, - "type_date": { "type": "string", "default": "Date field" }, - "type_here": { "type": "string", "default": "Type here..." }, - "type_number": { "type": "string", "default": "Numeric field" }, - "type_string": { "type": "string", "default": "Text field" }, - "value": { "type": "string", "default": "Value" } - }, - "required": [ - "add_or_clause", - "add_value", - "date", - "delete", - "field", - "hidden", - "is_defined_false", - "is_defined_true", - "name", - "operator_equal", - "operator_greaterthan", - "operator_greaterthanorequal", - "operator_in", - "operator_isdefined", - "operator_lessthan", - "operator_lessthanorequal", - "operator_not", - "or", - "query_builder_group", - "query_builder_rule", - "range_from", - "range_to", - "type", - "type_any", - "type_attribute", - "type_date", - "type_here", - "type_number", - "type_string", - "value" - ] - }, - "filter-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Name" }, - "placeholder": { "type": "string", "default": "My custom filter" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "action": { - "additionalProperties": false, - "properties": { - "create": { "type": "string", "default": "Pin to sidebar" }, - "update": { "type": "string", "default": "Save changes" }, - "delete": { "type": "string", "default": "Unpin" }, - "reset": { "type": "string", "default": "Reset" } - }, - "required": ["create", "update", "delete", "reset"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": ["filter-query", "filter-name", "action", "spinner"] -} diff --git a/src/static/schemas/generate-codes-form.json b/src/static/schemas/generate-codes-form.json deleted file mode 100644 index 1ffd393a1..000000000 --- a/src/static/schemas/generate-codes-form.json +++ /dev/null @@ -1,97 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "status": { - "additionalProperties": false, - "properties": { "success": { "type": "string", "default": "Codes generated successfully." } }, - "required": ["success"] - }, - "error": { - "additionalProperties": false, - "properties": { - "invalid_form": { - "type": "string", - "default": "These parameters won't generate any codes. Please make sure that the length of the code is greater than the length of the prefix, does not exceed 50 characters in total and that the code itself does not contain spaces." - } - }, - "required": ["invalid_form"] - }, - "length": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Code length" }, - "placeholder": { "type": "string", "default": "6" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "number-of-codes": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Number of codes" }, - "placeholder": { "type": "string", "default": "10" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "prefix": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Prefix" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { - "type": "string", - "default": "The length value is inclusive of this prefix." - } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "current-balance": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Initial balance" }, - "placeholder": { "type": "string", "default": "0" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "example": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Examples" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { - "type": "string", - "default": "This is what the generated codes will look like." - } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Generate" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "status", - "error", - "length", - "number-of-codes", - "prefix", - "current-balance", - "example", - "create", - "spinner" - ] -} diff --git a/src/static/schemas/gift-card-card.json b/src/static/schemas/gift-card-card.json deleted file mode 100644 index 6eaf7a5c2..000000000 --- a/src/static/schemas/gift-card-card.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "expires_after_value": { "type": "string", "default": "Expires {{value, relative}}" }, - "never_expires": { "type": "string", "default": "Never expires" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["expires_after_value", "never_expires", "spinner"] -} diff --git a/src/static/schemas/gift-card-code-card.json b/src/static/schemas/gift-card-code-card.json deleted file mode 100644 index adc897b62..000000000 --- a/src/static/schemas/gift-card-code-card.json +++ /dev/null @@ -1,19 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "line_1": { "type": "string", "default": "{{ code }}" }, - "line_2": { "type": "string", "default": "End date: {{ end_date, date }}" }, - "current_balance": { "type": "string", "default": "Balance: {{ value, price }}" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["line_1", "line_2", "current_balance", "spinner"] -} diff --git a/src/static/schemas/gift-card-code-form.json b/src/static/schemas/gift-card-code-form.json deleted file mode 100644 index 31ccb6876..000000000 --- a/src/static/schemas/gift-card-code-form.json +++ /dev/null @@ -1,408 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "code": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Code" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "The string value of this gift card code which your customer will add to their cart to use this gift card." - }, - "v8n_required": { "type": "string", "default": "Please enter a code" }, - "v8n_too_long": { - "type": "string", - "default": "Please enter a code with no more than 50 characters" - }, - "v8n_has_spaces": { "type": "string", "default": "Please enter a code without spaces" } - }, - "required": [ - "label", - "placeholder", - "helper_text", - "v8n_required", - "v8n_too_long", - "v8n_has_spaces" - ] - }, - "current-balance": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Current balance" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { "type": "string", "default": "The current balance of this gift card." }, - "v8n_required": { "type": "string", "default": "Please enter a current balance" } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "end-date": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "End date" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { "type": "string", "default": "The date when this gift card will expire." } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "customer": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Customer" }, - "dialog": { - "additionalProperties": false, - "properties": { - "cancel": { "type": "string", "default": "Cancel" }, - "close": { "type": "string", "default": "Close" }, - "header": { "type": "string", "default": "Select a customer" }, - "selection": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Customers" }, - "helper_text": { - "type": "string", - "default": "Select a customer to assign this gift card code to them. You won't be able to clear this selection once saved but you will able able to reassign it to another customer." - }, - "search": { "type": "string", "default": "Search" }, - "clear": { "type": "string", "default": "Clear" }, - "pagination": { - "additionalProperties": false, - "properties": { - "search_button_text": { "type": "string", "default": "Search" }, - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { - "type": "string", - "default": "{{from}}-{{to}} out of {{total}}" - }, - "previous": { "type": "string", "default": "Previous" }, - "card": { - "additionalProperties": false, - "properties": { - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No customers found" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["spinner"] - } - }, - "required": [ - "search_button_text", - "first", - "last", - "next", - "pagination", - "previous", - "card" - ] - }, - "query-builder": { - "additionalProperties": false, - "properties": { - "filters": { - "additionalProperties": false, - "properties": { - "id": { "type": "string", "default": "ID" }, - "tax_id": { "type": "string", "default": "Tax ID" }, - "email": { "type": "string", "default": "Email" }, - "first_name": { "type": "string", "default": "First name" }, - "last_name": { "type": "string", "default": "Last name" }, - "is_anonymous": { "type": "string", "default": "Anonymity" }, - "is_anonymous_true": { "type": "string", "default": "Anonymous" }, - "is_anonymous_false": { "type": "string", "default": "Registered" }, - "last_login_date": { "type": "string", "default": "Last login date" }, - "date_created": { "type": "string", "default": "Creation date" }, - "date_modified": { "type": "string", "default": "Last update date" } - }, - "required": [ - "id", - "tax_id", - "email", - "first_name", - "last_name", - "is_anonymous", - "is_anonymous_true", - "is_anonymous_false", - "last_login_date", - "date_created", - "date_modified" - ] - }, - "add_or_clause": { "type": "string", "default": "Add OR clause" }, - "add_value": { "type": "string", "default": "Add value" }, - "code": { "type": "string", "default": "Code" }, - "date": { "type": "string", "default": "{{value, date}}" }, - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "delete": { "type": "string", "default": "Delete" }, - "field": { "type": "string", "default": "Field" }, - "hidden": { "type": "string", "default": "Hidden" }, - "is_defined_false": { "type": "string", "default": "Not defined" }, - "is_defined_true": { "type": "string", "default": "Defined" }, - "name": { "type": "string", "default": "Name" }, - "operator_equal": { "type": "string", "default": "Equal" }, - "operator_greaterthan": { "type": "string", "default": "Greater than" }, - "operator_greaterthanorequal": { - "type": "string", - "default": "Greater than or equal" - }, - "operator_in": { "type": "string", "default": "One of" }, - "operator_isdefined": { "type": "string", "default": "Is defined" }, - "operator_lessthan": { "type": "string", "default": "Less than" }, - "operator_lessthanorequal": { - "type": "string", - "default": "Less than or equal" - }, - "operator_not": { "type": "string", "default": "Not equal" }, - "or": { "type": "string", "default": "Or" }, - "query_builder_group": { "type": "string", "default": "Group of filters" }, - "query_builder_rule": { "type": "string", "default": "Filter" }, - "range_from": { "type": "string", "default": "From" }, - "range_to": { "type": "string", "default": "To" }, - "type": { "type": "string", "default": "Type" }, - "type_any": { "type": "string", "default": "Field of unknown type" }, - "type_attribute": { "type": "string", "default": "Key-value resource" }, - "type_date": { "type": "string", "default": "Date field" }, - "type_here": { "type": "string", "default": "Type here..." }, - "type_number": { "type": "string", "default": "Numeric field" }, - "type_string": { "type": "string", "default": "Text field" }, - "used_codes": { "type": "string", "default": "Codes used" }, - "value": { "type": "string", "default": "Value" } - }, - "required": [ - "filters", - "add_or_clause", - "add_value", - "code", - "date", - "date_created", - "date_modified", - "delete", - "field", - "hidden", - "is_defined_false", - "is_defined_true", - "name", - "operator_equal", - "operator_greaterthan", - "operator_greaterthanorequal", - "operator_in", - "operator_isdefined", - "operator_lessthan", - "operator_lessthanorequal", - "operator_not", - "or", - "query_builder_group", - "query_builder_rule", - "range_from", - "range_to", - "type", - "type_any", - "type_attribute", - "type_date", - "type_here", - "type_number", - "type_string", - "used_codes", - "value" - ] - } - }, - "required": ["label", "helper_text", "search", "clear", "pagination", "query-builder"] - } - }, - "required": ["cancel", "close", "header", "selection"] - }, - "card": { - "additionalProperties": false, - "properties": { - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "Not assigned – click to select" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["spinner"] - }, - "helper_text": { - "type": "string", - "default": "Select a customer to assign this gift card code to them. You won't be able to clear this selection once saved but you will able able to reassign it to another customer." - } - }, - "required": ["label", "dialog", "card", "helper_text"] - }, - "cart-item": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Cart item" }, - "card": { - "additionalProperties": false, - "properties": { - "daily": { "type": "string", "default": "Daily" }, - "daily_plural": { "type": "string", "default": "Every {{count}} days" }, - "frequency": { - "type": "string", - "default": "$t({{units}}, { \"count\": {{count}}, \"ns\": \"item-card\" })" - }, - "monthly": { "type": "string", "default": "Monthly" }, - "monthly_plural": { "type": "string", "default": "Every {{count}} months" }, - "subinfo_recurring": { - "type": "string", - "default": "$t(frequency, { \"count\": \"{{count}}\", \"units\": \"{{units}}\", \"ns\": \"item-card\" }) from {{startDate, date}}" - }, - "subinfo_twice_a_month": { - "type": "string", - "default": "$t(twice_a_month, { \"ns\": \"item-card\" }) from {{startDate, date}}" - }, - "twice_a_month": { "type": "string", "default": "Twice a month" }, - "no_code": { "type": "string", "default": "No SKU" }, - "weekly": { "type": "string", "default": "Weekly" }, - "weekly_plural": { "type": "string", "default": "Every {{count}} weeks" }, - "yearly": { "type": "string", "default": "Yearly" }, - "yearly_plural": { "type": "string", "default": "Every {{count}} years" }, - "price": { "type": "string", "default": "{{amount, price}}" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No info" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "daily", - "daily_plural", - "frequency", - "monthly", - "monthly_plural", - "subinfo_recurring", - "subinfo_twice_a_month", - "twice_a_month", - "no_code", - "weekly", - "weekly_plural", - "yearly", - "yearly_plural", - "price", - "spinner" - ] - } - }, - "required": ["label", "card"] - }, - "logs": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Timeline" }, - "pagination": { - "additionalProperties": false, - "properties": { - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { "type": "string", "default": "{{from}}-{{to}} out of {{total}}" }, - "previous": { "type": "string", "default": "Previous" }, - "card": { - "additionalProperties": false, - "properties": { - "title_updated_via_api": { "type": "string", "default": "Updated via API" }, - "title_used": { "type": "string", "default": "Used on checkout" }, - "subtitle_transaction": { - "type": "string", - "default": "Transaction #{{ transaction_id }}" - }, - "subtitle_no_transaction": { "type": "string", "default": "No transaction" }, - "date": { - "type": "string", - "default": "{{ date_created, date }} at {{ date_created, time }}" - }, - "adjustment": { "type": "string", "default": "{{ amount, price }}" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No records" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "title_updated_via_api", - "title_used", - "subtitle_transaction", - "subtitle_no_transaction", - "date", - "adjustment", - "spinner" - ] - } - }, - "required": ["first", "last", "next", "pagination", "previous", "card"] - } - }, - "required": ["label", "pagination"] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date": { "type": "string", "default": "{{value, date}}" }, - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" } - }, - "required": ["date", "date_created", "date_modified"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove this gift card code? You won't be able to bring it back." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "code", - "current-balance", - "end-date", - "customer", - "cart-item", - "logs", - "timestamps", - "delete", - "create", - "spinner" - ] -} diff --git a/src/static/schemas/gift-card-code-log-card.json b/src/static/schemas/gift-card-code-log-card.json deleted file mode 100644 index 473455b5a..000000000 --- a/src/static/schemas/gift-card-code-log-card.json +++ /dev/null @@ -1,30 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "title_updated_via_api": { "type": "string", "default": "Updated via API" }, - "title_used": { "type": "string", "default": "Used on checkout" }, - "subtitle_transaction": { "type": "string", "default": "Transaction #{{ transaction_id }}" }, - "subtitle_no_transaction": { "type": "string", "default": "No transaction" }, - "date": { "type": "string", "default": "{{ date_created, date }}" }, - "adjustment": { "type": "string", "default": "{{ amount, price }}" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "title_updated_via_api", - "title_used", - "subtitle_transaction", - "subtitle_no_transaction", - "date", - "adjustment", - "spinner" - ] -} diff --git a/src/static/schemas/gift-card-codes-form.json b/src/static/schemas/gift-card-codes-form.json deleted file mode 100644 index a16d23118..000000000 --- a/src/static/schemas/gift-card-codes-form.json +++ /dev/null @@ -1,54 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "status": { - "additionalProperties": false, - "properties": { - "success": { - "type": "string", - "default": "All done! We've imported your codes into the system." - }, - "close": { "type": "string", "default": "Close" } - }, - "required": ["success", "close"] - }, - "gift-card-codes": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Codes" }, - "placeholder": { "type": "string", "default": "Enter or paste codes here..." }, - "helper_text": { - "type": "string", - "default": "Paste multiple space-separated codes in the field above to add all of them at once. Importing duplicate codes clears their usage stats." - }, - "v8n_required": { "type": "string", "default": "Please add at least one code" } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "current-balance": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Initial balance" }, - "placeholder": { "type": "string", "default": "0" }, - "helper_text": { "type": "string", "default": "All imported codes will have this balance." } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Import" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": ["status", "gift-card-codes", "current-balance", "create", "spinner"] -} diff --git a/src/static/schemas/gift-card-form.json b/src/static/schemas/gift-card-form.json deleted file mode 100644 index cad263b73..000000000 --- a/src/static/schemas/gift-card-form.json +++ /dev/null @@ -1,1672 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "header": { - "additionalProperties": false, - "properties": { - "title_existing": { "type": "string", "default": "ID {{ id }}" }, - "title_new": { "type": "string", "default": "New gift card" }, - "subtitle": { "type": "string", "default": "{{ name }}, {{ currency_code }}" } - }, - "required": ["title_existing", "title_new", "subtitle"] - }, - "import": { - "additionalProperties": false, - "properties": { - "button_text": { "type": "string", "default": "Import codes" }, - "dialog": { - "additionalProperties": false, - "properties": { - "close": { "type": "string", "default": "Close" }, - "cancel": { "type": "string", "default": "Cancel" }, - "header": { "type": "string", "default": "Import codes" }, - "save": { "type": "string", "default": "Import" }, - "undo_header": { "type": "string", "default": "Unsaved changes" }, - "undo_message": { - "type": "string", - "default": "Looks like you didn't save your changes! What would you like to do with them?" - }, - "undo_cancel": { "type": "string", "default": "Review" }, - "undo_confirm": { "type": "string", "default": "Discard" }, - "gift-card-codes-form": { - "additionalProperties": false, - "properties": { - "status": { - "additionalProperties": false, - "properties": { - "success": { - "type": "string", - "default": "All done! We've imported your codes into the system." - }, - "close": { "type": "string", "default": "Close" } - }, - "required": ["success", "close"] - }, - "gift-card-codes": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Codes" }, - "placeholder": { "type": "string", "default": "Enter or paste codes here..." }, - "helper_text": { - "type": "string", - "default": "Paste multiple space-separated codes in the field above to add all of them at once. Importing duplicate codes clears their usage stats." - }, - "v8n_required": { "type": "string", "default": "Please add at least one code" } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "current-balance": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Initial balance" }, - "placeholder": { "type": "string", "default": "0" }, - "helper_text": { - "type": "string", - "default": "All imported codes will have this balance." - } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Import" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": ["status", "gift-card-codes", "current-balance", "create", "spinner"] - } - }, - "required": [ - "close", - "cancel", - "header", - "save", - "undo_header", - "undo_message", - "undo_cancel", - "undo_confirm", - "gift-card-codes-form" - ] - } - }, - "required": ["button_text", "dialog"] - }, - "generate": { - "additionalProperties": false, - "properties": { - "button_text": { "type": "string", "default": "Generate codes" }, - "dialog": { - "additionalProperties": false, - "properties": { - "close": { "type": "string", "default": "Close" }, - "cancel": { "type": "string", "default": "Cancel" }, - "header": { "type": "string", "default": "Generate codes" }, - "save": { "type": "string", "default": "Generate" }, - "undo_header": { "type": "string", "default": "Unsaved changes" }, - "undo_message": { - "type": "string", - "default": "Looks like you didn't save your changes! What would you like to do with them?" - }, - "undo_cancel": { "type": "string", "default": "Review" }, - "undo_confirm": { "type": "string", "default": "Discard" }, - "generate-codes-form": { - "additionalProperties": false, - "properties": { - "status": { - "additionalProperties": false, - "properties": { - "success": { "type": "string", "default": "Codes generated successfully." } - }, - "required": ["success"] - }, - "error": { - "additionalProperties": false, - "properties": { - "invalid_form": { - "type": "string", - "default": "These parameters won't generate any codes. Please make sure that the length of the code is greater than the length of the prefix, does not exceed 50 characters in total and that the code itself does not contain spaces." - } - }, - "required": ["invalid_form"] - }, - "length": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Code length" }, - "placeholder": { "type": "string", "default": "6" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "number-of-codes": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Number of codes" }, - "placeholder": { "type": "string", "default": "10" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "prefix": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Prefix" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { - "type": "string", - "default": "The length value is inclusive of this prefix." - } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "current-balance": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Initial balance" }, - "placeholder": { "type": "string", "default": "0" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "example": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Examples" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { - "type": "string", - "default": "This is what the generated codes will look like." - } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Generate" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "status", - "error", - "length", - "number-of-codes", - "prefix", - "current-balance", - "example", - "create", - "spinner" - ] - } - }, - "required": [ - "close", - "cancel", - "header", - "save", - "undo_header", - "undo_message", - "undo_cancel", - "undo_confirm", - "generate-codes-form" - ] - } - }, - "required": ["button_text", "dialog"] - }, - "name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Name" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "Gift card name is visible to the customers." - }, - "v8n_required": { "type": "string", "default": "Please enter a name for this gift card." }, - "v8n_too_long": { - "type": "string", - "default": "Please shorten the name to 50 characters or less." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_too_long"] - }, - "expires": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Expires after" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { - "type": "string", - "default": "Set to make the gift card codes expire after a certain period of time. Check with your local laws to ensure expiring gift cards is legal, according to your use case." - }, - "year": { "type": "string", "default": "Year" }, - "year_plural": { "type": "string", "default": "Years" }, - "month": { "type": "string", "default": "Month" }, - "month_plural": { "type": "string", "default": "Months" }, - "week": { "type": "string", "default": "Week" }, - "week_plural": { "type": "string", "default": "Weeks" }, - "day": { "type": "string", "default": "Day" }, - "day_plural": { "type": "string", "default": "Days" } - }, - "required": [ - "label", - "placeholder", - "helper_text", - "year", - "year_plural", - "month", - "month_plural", - "week", - "week_plural", - "day", - "day_plural" - ] - }, - "currency": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Currency" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { - "type": "string", - "default": "Currency code for this gift card. Note that gift cards are only usable if the cart's currency matches." - }, - "code_aed": { "type": "string", "default": "United Arab Emirates Dirham (AED)" }, - "code_afn": { "type": "string", "default": "Afghan Afghani (AFN)" }, - "code_all": { "type": "string", "default": "Albanian Lek (ALL)" }, - "code_amd": { "type": "string", "default": "Armenian Dram (AMD)" }, - "code_ang": { "type": "string", "default": "Netherlands Antillean Guilder (ANG)" }, - "code_aoa": { "type": "string", "default": "Angolan Kwanza (AOA)" }, - "code_ars": { "type": "string", "default": "Argentine Peso (ARS)" }, - "code_aud": { "type": "string", "default": "Australian Dollar (AUD)" }, - "code_awg": { "type": "string", "default": "Aruban Florin (AWG)" }, - "code_azn": { "type": "string", "default": "Azerbaijani Manat (AZN)" }, - "code_bam": { "type": "string", "default": "Bosnia-Herzegovina Convertible Mark (BAM)" }, - "code_bbd": { "type": "string", "default": "Barbadian Dollar (BBD)" }, - "code_bdt": { "type": "string", "default": "Bangladeshi Taka (BDT)" }, - "code_bgn": { "type": "string", "default": "Bulgarian Lev (BGN)" }, - "code_bhd": { "type": "string", "default": "Bahraini Dinar (BHD)" }, - "code_bif": { "type": "string", "default": "Burundian Franc (BIF)" }, - "code_bmd": { "type": "string", "default": "Bermudan Dollar (BMD)" }, - "code_bnd": { "type": "string", "default": "Brunei Dollar (BND)" }, - "code_bob": { "type": "string", "default": "Bolivian Boliviano (BOB)" }, - "code_brl": { "type": "string", "default": "Brazilian Real (BRL)" }, - "code_bsd": { "type": "string", "default": "Bahamian Dollar (BSD)" }, - "code_btc": { "type": "string", "default": "Bitcoin (BTC)" }, - "code_btn": { "type": "string", "default": "Bhutanese Ngultrum (BTN)" }, - "code_bwp": { "type": "string", "default": "Botswanan Pula (BWP)" }, - "code_byn": { "type": "string", "default": "Belarusian Ruble (BYN)" }, - "code_bzd": { "type": "string", "default": "Belize Dollar (BZD)" }, - "code_cad": { "type": "string", "default": "Canadian Dollar (CAD)" }, - "code_cdf": { "type": "string", "default": "Congolese Franc (CDF)" }, - "code_chf": { "type": "string", "default": "Swiss Franc (CHF)" }, - "code_clf": { "type": "string", "default": "Chilean Unit of Account (UF) (CLF)" }, - "code_clp": { "type": "string", "default": "Chilean Peso (CLP)" }, - "code_cnh": { "type": "string", "default": "Chinese Yuan (Offshore) (CNH)" }, - "code_cny": { "type": "string", "default": "Chinese Yuan (CNY)" }, - "code_cop": { "type": "string", "default": "Colombian Peso (COP)" }, - "code_crc": { "type": "string", "default": "Costa Rican Colón (CRC)" }, - "code_cuc": { "type": "string", "default": "Cuban Convertible Peso (CUC)" }, - "code_cup": { "type": "string", "default": "Cuban Peso (CUP)" }, - "code_cve": { "type": "string", "default": "Cape Verdean Escudo (CVE)" }, - "code_czk": { "type": "string", "default": "Czech Republic Koruna (CZK)" }, - "code_djf": { "type": "string", "default": "Djiboutian Franc (DJF)" }, - "code_dkk": { "type": "string", "default": "Danish Krone (DKK)" }, - "code_dop": { "type": "string", "default": "Dominican Peso (DOP)" }, - "code_dzd": { "type": "string", "default": "Algerian Dinar (DZD)" }, - "code_egp": { "type": "string", "default": "Egyptian Pound (EGP)" }, - "code_ern": { "type": "string", "default": "Eritrean Nakfa (ERN)" }, - "code_etb": { "type": "string", "default": "Ethiopian Birr (ETB)" }, - "code_eur": { "type": "string", "default": "Euro (EUR)" }, - "code_fjd": { "type": "string", "default": "Fijian Dollar (FJD)" }, - "code_fkp": { "type": "string", "default": "Falkland Islands Pound (FKP)" }, - "code_gbp": { "type": "string", "default": "British Pound Sterling (GBP)" }, - "code_gel": { "type": "string", "default": "Georgian Lari (GEL)" }, - "code_ggp": { "type": "string", "default": "Guernsey Pound (GGP)" }, - "code_ghs": { "type": "string", "default": "Ghanaian Cedi (GHS)" }, - "code_gip": { "type": "string", "default": "Gibraltar Pound (GIP)" }, - "code_gmd": { "type": "string", "default": "Gambian Dalasi (GMD)" }, - "code_gnf": { "type": "string", "default": "Guinean Franc (GNF)" }, - "code_gtq": { "type": "string", "default": "Guatemalan Quetzal (GTQ)" }, - "code_gyd": { "type": "string", "default": "Guyanaese Dollar (GYD)" }, - "code_hkd": { "type": "string", "default": "Hong Kong Dollar (HKD)" }, - "code_hnl": { "type": "string", "default": "Honduran Lempira (HNL)" }, - "code_hrk": { "type": "string", "default": "Croatian Kuna (HRK)" }, - "code_htg": { "type": "string", "default": "Haitian Gourde (HTG)" }, - "code_huf": { "type": "string", "default": "Hungarian Forint (HUF)" }, - "code_idr": { "type": "string", "default": "Indonesian Rupiah (IDR)" }, - "code_ils": { "type": "string", "default": "Israeli New Sheqel (ILS)" }, - "code_imp": { "type": "string", "default": "Manx pound (IMP)" }, - "code_inr": { "type": "string", "default": "Indian Rupee (INR)" }, - "code_iqd": { "type": "string", "default": "Iraqi Dinar (IQD)" }, - "code_irr": { "type": "string", "default": "Iranian Rial (IRR)" }, - "code_isk": { "type": "string", "default": "Icelandic Króna (ISK)" }, - "code_jep": { "type": "string", "default": "Jersey Pound (JEP)" }, - "code_jmd": { "type": "string", "default": "Jamaican Dollar (JMD)" }, - "code_jod": { "type": "string", "default": "Jordanian Dinar (JOD)" }, - "code_jpy": { "type": "string", "default": "Japanese Yen (JPY)" }, - "code_kes": { "type": "string", "default": "Kenyan Shilling (KES)" }, - "code_kgs": { "type": "string", "default": "Kyrgystani Som (KGS)" }, - "code_khr": { "type": "string", "default": "Cambodian Riel (KHR)" }, - "code_kmf": { "type": "string", "default": "Comorian Franc (KMF)" }, - "code_kpw": { "type": "string", "default": "North Korean Won (KPW)" }, - "code_krw": { "type": "string", "default": "South Korean Won (KRW)" }, - "code_kwd": { "type": "string", "default": "Kuwaiti Dinar (KWD)" }, - "code_kyd": { "type": "string", "default": "Cayman Islands Dollar (KYD)" }, - "code_kzt": { "type": "string", "default": "Kazakhstani Tenge (KZT)" }, - "code_lak": { "type": "string", "default": "Laotian Kip (LAK)" }, - "code_lbp": { "type": "string", "default": "Lebanese Pound (LBP)" }, - "code_lkr": { "type": "string", "default": "Sri Lankan Rupee (LKR)" }, - "code_lrd": { "type": "string", "default": "Liberian Dollar (LRD)" }, - "code_lsl": { "type": "string", "default": "Lesotho Loti (LSL)" }, - "code_lyd": { "type": "string", "default": "Libyan Dinar (LYD)" }, - "code_mad": { "type": "string", "default": "Moroccan Dirham (MAD)" }, - "code_mdl": { "type": "string", "default": "Moldovan Leu (MDL)" }, - "code_mga": { "type": "string", "default": "Malagasy Ariary (MGA)" }, - "code_mkd": { "type": "string", "default": "Macedonian Denar (MKD)" }, - "code_mmk": { "type": "string", "default": "Myanma Kyat (MMK)" }, - "code_mnt": { "type": "string", "default": "Mongolian Tugrik (MNT)" }, - "code_mop": { "type": "string", "default": "Macanese Pataca (MOP)" }, - "code_mru": { "type": "string", "default": "Mauritanian Ouguiya (MRU)" }, - "code_mur": { "type": "string", "default": "Mauritian Rupee (MUR)" }, - "code_mvr": { "type": "string", "default": "Maldivian Rufiyaa (MVR)" }, - "code_mwk": { "type": "string", "default": "Malawian Kwacha (MWK)" }, - "code_mxn": { "type": "string", "default": "Mexican Peso (MXN)" }, - "code_myr": { "type": "string", "default": "Malaysian Ringgit (MYR)" }, - "code_mzn": { "type": "string", "default": "Mozambican Metical (MZN)" }, - "code_nad": { "type": "string", "default": "Namibian Dollar (NAD)" }, - "code_ngn": { "type": "string", "default": "Nigerian Naira (NGN)" }, - "code_nio": { "type": "string", "default": "Nicaraguan Córdoba (NIO)" }, - "code_nok": { "type": "string", "default": "Norwegian Krone (NOK)" }, - "code_npr": { "type": "string", "default": "Nepalese Rupee (NPR)" }, - "code_nzd": { "type": "string", "default": "New Zealand Dollar (NZD)" }, - "code_omr": { "type": "string", "default": "Omani Rial (OMR)" }, - "code_pab": { "type": "string", "default": "Panamanian Balboa (PAB)" }, - "code_pen": { "type": "string", "default": "Peruvian Nuevo Sol (PEN)" }, - "code_pgk": { "type": "string", "default": "Papua New Guinean Kina (PGK)" }, - "code_php": { "type": "string", "default": "Philippine Peso (PHP)" }, - "code_pkr": { "type": "string", "default": "Pakistani Rupee (PKR)" }, - "code_pln": { "type": "string", "default": "Polish Zloty (PLN)" }, - "code_pyg": { "type": "string", "default": "Paraguayan Guarani (PYG)" }, - "code_qar": { "type": "string", "default": "Qatari Rial (QAR)" }, - "code_ron": { "type": "string", "default": "Romanian Leu (RON)" }, - "code_rsd": { "type": "string", "default": "Serbian Dinar (RSD)" }, - "code_rub": { "type": "string", "default": "Russian Ruble (RUB)" }, - "code_rwf": { "type": "string", "default": "Rwandan Franc (RWF)" }, - "code_sar": { "type": "string", "default": "Saudi Riyal (SAR)" }, - "code_sbd": { "type": "string", "default": "Solomon Islands Dollar (SBD)" }, - "code_scr": { "type": "string", "default": "Seychellois Rupee (SCR)" }, - "code_sdg": { "type": "string", "default": "Sudanese Pound (SDG)" }, - "code_sek": { "type": "string", "default": "Swedish Krona (SEK)" }, - "code_sgd": { "type": "string", "default": "Singapore Dollar (SGD)" }, - "code_shp": { "type": "string", "default": "Saint Helena Pound (SHP)" }, - "code_sll": { "type": "string", "default": "Sierra Leonean Leone (SLL)" }, - "code_sos": { "type": "string", "default": "Somali Shilling (SOS)" }, - "code_srd": { "type": "string", "default": "Surinamese Dollar (SRD)" }, - "code_ssp": { "type": "string", "default": "South Sudanese Pound (SSP)" }, - "code_std": { "type": "string", "default": "São Tomé and Príncipe Dobra (pre-2018) (STD)" }, - "code_stn": { "type": "string", "default": "São Tomé and Príncipe Dobra (STN)" }, - "code_svc": { "type": "string", "default": "Salvadoran Colón (SVC)" }, - "code_syp": { "type": "string", "default": "Syrian Pound (SYP)" }, - "code_szl": { "type": "string", "default": "Swazi Lilangeni (SZL)" }, - "code_thb": { "type": "string", "default": "Thai Baht (THB)" }, - "code_tjs": { "type": "string", "default": "Tajikistani Somoni (TJS)" }, - "code_tmt": { "type": "string", "default": "Turkmenistani Manat (TMT)" }, - "code_tnd": { "type": "string", "default": "Tunisian Dinar (TND)" }, - "code_top": { "type": "string", "default": "Tongan Pa'anga (TOP)" }, - "code_try": { "type": "string", "default": "Turkish Lira (TRY)" }, - "code_ttd": { "type": "string", "default": "Trinidad and Tobago Dollar (TTD)" }, - "code_twd": { "type": "string", "default": "New Taiwan Dollar (TWD)" }, - "code_tzs": { "type": "string", "default": "Tanzanian Shilling (TZS)" }, - "code_uah": { "type": "string", "default": "Ukrainian Hryvnia (UAH)" }, - "code_ugx": { "type": "string", "default": "Ugandan Shilling (UGX)" }, - "code_usd": { "type": "string", "default": "United States Dollar (USD)" }, - "code_uyu": { "type": "string", "default": "Uruguayan Peso (UYU)" }, - "code_uzs": { "type": "string", "default": "Uzbekistan Som (UZS)" }, - "code_vef": { "type": "string", "default": "Venezuelan Bolívar Fuerte (Old) (VEF)" }, - "code_ves": { "type": "string", "default": "Venezuelan Bolívar Soberano (VES)" }, - "code_vnd": { "type": "string", "default": "Vietnamese Dong (VND)" }, - "code_vuv": { "type": "string", "default": "Vanuatu Vatu (VUV)" }, - "code_wst": { "type": "string", "default": "Samoan Tala (WST)" }, - "code_xaf": { "type": "string", "default": "CFA Franc BEAC (XAF)" }, - "code_xag": { "type": "string", "default": "Silver Ounce (XAG)" }, - "code_xau": { "type": "string", "default": "Gold Ounce (XAU)" }, - "code_xcd": { "type": "string", "default": "East Caribbean Dollar (XCD)" }, - "code_xdr": { "type": "string", "default": "Special Drawing Rights (XDR)" }, - "code_xof": { "type": "string", "default": "CFA Franc BCEAO (XOF)" }, - "code_xpd": { "type": "string", "default": "Palladium Ounce (XPD)" }, - "code_xpf": { "type": "string", "default": "CFP Franc (XPF)" }, - "code_xpt": { "type": "string", "default": "Platinum Ounce (XPT)" }, - "code_yer": { "type": "string", "default": "Yemeni Rial (YER)" }, - "code_zar": { "type": "string", "default": "South African Rand (ZAR)" }, - "code_zmw": { "type": "string", "default": "Zambian Kwacha (ZMW)" }, - "code_zwl": { "type": "string", "default": "Zimbabwean Dollar (ZWL)" } - }, - "required": [ - "label", - "placeholder", - "helper_text", - "code_aed", - "code_afn", - "code_all", - "code_amd", - "code_ang", - "code_aoa", - "code_ars", - "code_aud", - "code_awg", - "code_azn", - "code_bam", - "code_bbd", - "code_bdt", - "code_bgn", - "code_bhd", - "code_bif", - "code_bmd", - "code_bnd", - "code_bob", - "code_brl", - "code_bsd", - "code_btc", - "code_btn", - "code_bwp", - "code_byn", - "code_bzd", - "code_cad", - "code_cdf", - "code_chf", - "code_clf", - "code_clp", - "code_cnh", - "code_cny", - "code_cop", - "code_crc", - "code_cuc", - "code_cup", - "code_cve", - "code_czk", - "code_djf", - "code_dkk", - "code_dop", - "code_dzd", - "code_egp", - "code_ern", - "code_etb", - "code_eur", - "code_fjd", - "code_fkp", - "code_gbp", - "code_gel", - "code_ggp", - "code_ghs", - "code_gip", - "code_gmd", - "code_gnf", - "code_gtq", - "code_gyd", - "code_hkd", - "code_hnl", - "code_hrk", - "code_htg", - "code_huf", - "code_idr", - "code_ils", - "code_imp", - "code_inr", - "code_iqd", - "code_irr", - "code_isk", - "code_jep", - "code_jmd", - "code_jod", - "code_jpy", - "code_kes", - "code_kgs", - "code_khr", - "code_kmf", - "code_kpw", - "code_krw", - "code_kwd", - "code_kyd", - "code_kzt", - "code_lak", - "code_lbp", - "code_lkr", - "code_lrd", - "code_lsl", - "code_lyd", - "code_mad", - "code_mdl", - "code_mga", - "code_mkd", - "code_mmk", - "code_mnt", - "code_mop", - "code_mru", - "code_mur", - "code_mvr", - "code_mwk", - "code_mxn", - "code_myr", - "code_mzn", - "code_nad", - "code_ngn", - "code_nio", - "code_nok", - "code_npr", - "code_nzd", - "code_omr", - "code_pab", - "code_pen", - "code_pgk", - "code_php", - "code_pkr", - "code_pln", - "code_pyg", - "code_qar", - "code_ron", - "code_rsd", - "code_rub", - "code_rwf", - "code_sar", - "code_sbd", - "code_scr", - "code_sdg", - "code_sek", - "code_sgd", - "code_shp", - "code_sll", - "code_sos", - "code_srd", - "code_ssp", - "code_std", - "code_stn", - "code_svc", - "code_syp", - "code_szl", - "code_thb", - "code_tjs", - "code_tmt", - "code_tnd", - "code_top", - "code_try", - "code_ttd", - "code_twd", - "code_tzs", - "code_uah", - "code_ugx", - "code_usd", - "code_uyu", - "code_uzs", - "code_vef", - "code_ves", - "code_vnd", - "code_vuv", - "code_wst", - "code_xaf", - "code_xag", - "code_xau", - "code_xcd", - "code_xdr", - "code_xof", - "code_xpd", - "code_xpf", - "code_xpt", - "code_yer", - "code_zar", - "code_zmw", - "code_zwl" - ] - }, - "provisioning": { - "additionalProperties": false, - "properties": { - "toggle": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Provisioning" }, - "text": { "type": "string", "default": "Allow customers to buy this gift card" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "text", "helper_text"] - }, - "sku": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "SKU" }, - "placeholder": { "type": "string", "default": "E.g. 100_usd" }, - "helper_text": { - "type": "string", - "default": "You'll use this value to add this gift card to a customer's online cart." - }, - "v8n_required": { "type": "string", "default": "SKU is required for auto-provisioning" } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "min-balance": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Min balance" }, - "placeholder": { "type": "string", "default": "0" }, - "helper_text": { - "type": "string", - "default": "Customers won't be able to load this card with a balance less than this value." - }, - "v8n_negative": { "type": "string", "default": "Please enter a positive number" } - }, - "required": ["label", "placeholder", "helper_text", "v8n_negative"] - }, - "max-balance": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Max balance" }, - "placeholder": { "type": "string", "default": "0" }, - "helper_text": { - "type": "string", - "default": "Customers won't be able to load this card with a balance greater than this value." - }, - "v8n_negative": { "type": "string", "default": "Please enter a positive number" } - }, - "required": ["label", "placeholder", "helper_text", "v8n_negative"] - } - }, - "required": ["toggle", "sku", "min-balance", "max-balance"] - }, - "codes": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Codes" }, - "delete_header": { "type": "string", "default": "Remove code?" }, - "delete_message": { - "type": "string", - "default": "Please confirm that you'd like to remove this code from the gift card." - }, - "delete_confirm": { "type": "string", "default": "Remove" }, - "delete_cancel": { "type": "string", "default": "Cancel" }, - "search": { "type": "string", "default": "Search" }, - "clear": { "type": "string", "default": "Clear" }, - "dialog": { - "additionalProperties": false, - "properties": { - "header_create": { "type": "string", "default": "Create code" }, - "header_update": { "type": "string", "default": "Update code" }, - "close": { "type": "string", "default": "Close" }, - "save": { "type": "string", "default": "Save" }, - "cancel": { "type": "string", "default": "Cancel" }, - "undo_header": { "type": "string", "default": "Unsaved changes" }, - "undo_message": { - "type": "string", - "default": "Looks like you didn't save your changes! What would you like to do with them?" - }, - "undo_cancel": { "type": "string", "default": "Review" }, - "undo_confirm": { "type": "string", "default": "Discard" }, - "gift-card-code-form": { - "additionalProperties": false, - "properties": { - "code": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Code" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "The string value of this gift card code which your customer will add to their cart to use this gift card." - }, - "v8n_required": { "type": "string", "default": "Please enter a code" }, - "v8n_too_long": { - "type": "string", - "default": "Please enter a code with no more than 50 characters" - }, - "v8n_has_spaces": { - "type": "string", - "default": "Please enter a code without spaces" - } - }, - "required": [ - "label", - "placeholder", - "helper_text", - "v8n_required", - "v8n_too_long", - "v8n_has_spaces" - ] - }, - "current-balance": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Current balance" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "The current balance of this gift card." - }, - "v8n_required": { - "type": "string", - "default": "Please enter a current balance" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "end-date": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "End date" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { - "type": "string", - "default": "The date when this gift card will expire." - } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "customer": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Customer" }, - "dialog": { - "additionalProperties": false, - "properties": { - "cancel": { "type": "string", "default": "Cancel" }, - "close": { "type": "string", "default": "Close" }, - "header": { "type": "string", "default": "Select a customer" }, - "selection": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Customers" }, - "helper_text": { - "type": "string", - "default": "Select a customer to assign this gift card code to them. You won't be able to clear this selection once saved but you will able able to reassign it to another customer." - }, - "search": { "type": "string", "default": "Search" }, - "clear": { "type": "string", "default": "Clear" }, - "pagination": { - "additionalProperties": false, - "properties": { - "search_button_text": { "type": "string", "default": "Search" }, - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { - "type": "string", - "default": "{{from}}-{{to}} out of {{total}}" - }, - "previous": { "type": "string", "default": "Previous" }, - "card": { - "additionalProperties": false, - "properties": { - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { - "type": "string", - "default": "No customers found" - }, - "loading_error": { - "type": "string", - "default": "Unknown error" - } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["spinner"] - } - }, - "required": [ - "search_button_text", - "first", - "last", - "next", - "pagination", - "previous", - "card" - ] - }, - "query-builder": { - "additionalProperties": false, - "properties": { - "filters": { - "additionalProperties": false, - "properties": { - "id": { "type": "string", "default": "ID" }, - "tax_id": { "type": "string", "default": "Tax ID" }, - "email": { "type": "string", "default": "Email" }, - "first_name": { "type": "string", "default": "First name" }, - "last_name": { "type": "string", "default": "Last name" }, - "is_anonymous": { "type": "string", "default": "Anonymity" }, - "is_anonymous_true": { - "type": "string", - "default": "Anonymous" - }, - "is_anonymous_false": { - "type": "string", - "default": "Registered" - }, - "last_login_date": { - "type": "string", - "default": "Last login date" - }, - "date_created": { - "type": "string", - "default": "Creation date" - }, - "date_modified": { - "type": "string", - "default": "Last update date" - } - }, - "required": [ - "id", - "tax_id", - "email", - "first_name", - "last_name", - "is_anonymous", - "is_anonymous_true", - "is_anonymous_false", - "last_login_date", - "date_created", - "date_modified" - ] - }, - "add_or_clause": { "type": "string", "default": "Add OR clause" }, - "add_value": { "type": "string", "default": "Add value" }, - "code": { "type": "string", "default": "Code" }, - "date": { "type": "string", "default": "{{value, date}}" }, - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "delete": { "type": "string", "default": "Delete" }, - "field": { "type": "string", "default": "Field" }, - "hidden": { "type": "string", "default": "Hidden" }, - "is_defined_false": { "type": "string", "default": "Not defined" }, - "is_defined_true": { "type": "string", "default": "Defined" }, - "name": { "type": "string", "default": "Name" }, - "operator_equal": { "type": "string", "default": "Equal" }, - "operator_greaterthan": { - "type": "string", - "default": "Greater than" - }, - "operator_greaterthanorequal": { - "type": "string", - "default": "Greater than or equal" - }, - "operator_in": { "type": "string", "default": "One of" }, - "operator_isdefined": { "type": "string", "default": "Is defined" }, - "operator_lessthan": { "type": "string", "default": "Less than" }, - "operator_lessthanorequal": { - "type": "string", - "default": "Less than or equal" - }, - "operator_not": { "type": "string", "default": "Not equal" }, - "or": { "type": "string", "default": "Or" }, - "query_builder_group": { - "type": "string", - "default": "Group of filters" - }, - "query_builder_rule": { "type": "string", "default": "Filter" }, - "range_from": { "type": "string", "default": "From" }, - "range_to": { "type": "string", "default": "To" }, - "type": { "type": "string", "default": "Type" }, - "type_any": { - "type": "string", - "default": "Field of unknown type" - }, - "type_attribute": { - "type": "string", - "default": "Key-value resource" - }, - "type_date": { "type": "string", "default": "Date field" }, - "type_here": { "type": "string", "default": "Type here..." }, - "type_number": { "type": "string", "default": "Numeric field" }, - "type_string": { "type": "string", "default": "Text field" }, - "used_codes": { "type": "string", "default": "Codes used" }, - "value": { "type": "string", "default": "Value" } - }, - "required": [ - "filters", - "add_or_clause", - "add_value", - "code", - "date", - "date_created", - "date_modified", - "delete", - "field", - "hidden", - "is_defined_false", - "is_defined_true", - "name", - "operator_equal", - "operator_greaterthan", - "operator_greaterthanorequal", - "operator_in", - "operator_isdefined", - "operator_lessthan", - "operator_lessthanorequal", - "operator_not", - "or", - "query_builder_group", - "query_builder_rule", - "range_from", - "range_to", - "type", - "type_any", - "type_attribute", - "type_date", - "type_here", - "type_number", - "type_string", - "used_codes", - "value" - ] - } - }, - "required": [ - "label", - "helper_text", - "search", - "clear", - "pagination", - "query-builder" - ] - } - }, - "required": ["cancel", "close", "header", "selection"] - }, - "card": { - "additionalProperties": false, - "properties": { - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { - "type": "string", - "default": "Not assigned – click to select" - }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["spinner"] - }, - "helper_text": { - "type": "string", - "default": "Select a customer to assign this gift card code to them. You won't be able to clear this selection once saved but you will able able to reassign it to another customer." - } - }, - "required": ["label", "dialog", "card", "helper_text"] - }, - "cart-item": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Cart item" }, - "card": { - "additionalProperties": false, - "properties": { - "daily": { "type": "string", "default": "Daily" }, - "daily_plural": { "type": "string", "default": "Every {{count}} days" }, - "frequency": { - "type": "string", - "default": "$t({{units}}, { \"count\": {{count}}, \"ns\": \"item-card\" })" - }, - "monthly": { "type": "string", "default": "Monthly" }, - "monthly_plural": { "type": "string", "default": "Every {{count}} months" }, - "subinfo_recurring": { - "type": "string", - "default": "$t(frequency, { \"count\": \"{{count}}\", \"units\": \"{{units}}\", \"ns\": \"item-card\" }) from {{startDate, date}}" - }, - "subinfo_twice_a_month": { - "type": "string", - "default": "$t(twice_a_month, { \"ns\": \"item-card\" }) from {{startDate, date}}" - }, - "twice_a_month": { "type": "string", "default": "Twice a month" }, - "no_code": { "type": "string", "default": "No SKU" }, - "weekly": { "type": "string", "default": "Weekly" }, - "weekly_plural": { "type": "string", "default": "Every {{count}} weeks" }, - "yearly": { "type": "string", "default": "Yearly" }, - "yearly_plural": { "type": "string", "default": "Every {{count}} years" }, - "price": { "type": "string", "default": "{{amount, price}}" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No info" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "daily", - "daily_plural", - "frequency", - "monthly", - "monthly_plural", - "subinfo_recurring", - "subinfo_twice_a_month", - "twice_a_month", - "no_code", - "weekly", - "weekly_plural", - "yearly", - "yearly_plural", - "price", - "spinner" - ] - } - }, - "required": ["label", "card"] - }, - "logs": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Timeline" }, - "pagination": { - "additionalProperties": false, - "properties": { - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { - "type": "string", - "default": "{{from}}-{{to}} out of {{total}}" - }, - "previous": { "type": "string", "default": "Previous" }, - "card": { - "additionalProperties": false, - "properties": { - "title_updated_via_api": { - "type": "string", - "default": "Updated via API" - }, - "title_used": { "type": "string", "default": "Used on checkout" }, - "subtitle_transaction": { - "type": "string", - "default": "Transaction #{{ transaction_id }}" - }, - "subtitle_no_transaction": { - "type": "string", - "default": "No transaction" - }, - "date": { - "type": "string", - "default": "{{ date_created, date }} at {{ date_created, time }}" - }, - "adjustment": { "type": "string", "default": "{{ amount, price }}" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No records" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "title_updated_via_api", - "title_used", - "subtitle_transaction", - "subtitle_no_transaction", - "date", - "adjustment", - "spinner" - ] - } - }, - "required": ["first", "last", "next", "pagination", "previous", "card"] - } - }, - "required": ["label", "pagination"] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date": { "type": "string", "default": "{{value, date}}" }, - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" } - }, - "required": ["date", "date_created", "date_modified"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove this gift card code? You won't be able to bring it back." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "code", - "current-balance", - "end-date", - "customer", - "cart-item", - "logs", - "timestamps", - "delete", - "create", - "spinner" - ] - } - }, - "required": [ - "header_create", - "header_update", - "close", - "save", - "cancel", - "undo_header", - "undo_message", - "undo_cancel", - "undo_confirm", - "gift-card-code-form" - ] - }, - "pagination": { - "additionalProperties": false, - "properties": { - "create_button_text": { "type": "string", "default": "Add code +" }, - "search_button_text": { "type": "string", "default": "Search codes" }, - "card": { - "additionalProperties": false, - "properties": { - "delete_button_text": { "type": "string", "default": "Delete" }, - "copy_button_text": { "type": "string", "default": "Copy code" }, - "line_1": { "type": "string", "default": "{{ code }}" }, - "line_2": { "type": "string", "default": "End date: {{ end_date, date }}" }, - "current_balance": { "type": "string", "default": "Balance: {{ value, price }}" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No codes" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "delete_button_text", - "copy_button_text", - "line_1", - "line_2", - "current_balance", - "spinner" - ] - }, - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { "type": "string", "default": "{{from}}-{{to}} out of {{total}}" }, - "previous": { "type": "string", "default": "Previous" } - }, - "required": [ - "create_button_text", - "search_button_text", - "card", - "first", - "last", - "next", - "pagination", - "previous" - ] - }, - "query-builder": { - "additionalProperties": false, - "properties": { - "add_or_clause": { "type": "string", "default": "Add OR clause" }, - "add_value": { "type": "string", "default": "Add value" }, - "code": { "type": "string", "default": "Code" }, - "date": { "type": "string", "default": "{{value, date}}" }, - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "delete": { "type": "string", "default": "Delete" }, - "field": { "type": "string", "default": "Field" }, - "hidden": { "type": "string", "default": "Hidden" }, - "is_defined_false": { "type": "string", "default": "Not defined" }, - "is_defined_true": { "type": "string", "default": "Defined" }, - "name": { "type": "string", "default": "Name" }, - "operator_equal": { "type": "string", "default": "Equal" }, - "operator_greaterthan": { "type": "string", "default": "Greater than" }, - "operator_greaterthanorequal": { "type": "string", "default": "Greater than or equal" }, - "operator_in": { "type": "string", "default": "One of" }, - "operator_isdefined": { "type": "string", "default": "Is defined" }, - "operator_lessthan": { "type": "string", "default": "Less than" }, - "operator_lessthanorequal": { "type": "string", "default": "Less than or equal" }, - "operator_not": { "type": "string", "default": "Not equal" }, - "or": { "type": "string", "default": "Or" }, - "query_builder_group": { "type": "string", "default": "Group of filters" }, - "query_builder_rule": { "type": "string", "default": "Filter" }, - "range_from": { "type": "string", "default": "From" }, - "range_to": { "type": "string", "default": "To" }, - "type": { "type": "string", "default": "Type" }, - "type_any": { "type": "string", "default": "Field of unknown type" }, - "type_attribute": { "type": "string", "default": "Key-value resource" }, - "type_date": { "type": "string", "default": "Date field" }, - "type_here": { "type": "string", "default": "Type here..." }, - "type_number": { "type": "string", "default": "Numeric field" }, - "type_string": { "type": "string", "default": "Text field" }, - "used_codes": { "type": "string", "default": "Codes used" }, - "value": { "type": "string", "default": "Value" } - }, - "required": [ - "add_or_clause", - "add_value", - "code", - "date", - "date_created", - "date_modified", - "delete", - "field", - "hidden", - "is_defined_false", - "is_defined_true", - "name", - "operator_equal", - "operator_greaterthan", - "operator_greaterthanorequal", - "operator_in", - "operator_isdefined", - "operator_lessthan", - "operator_lessthanorequal", - "operator_not", - "or", - "query_builder_group", - "query_builder_rule", - "range_from", - "range_to", - "type", - "type_any", - "type_attribute", - "type_date", - "type_here", - "type_number", - "type_string", - "used_codes", - "value" - ] - } - }, - "required": [ - "label", - "delete_header", - "delete_message", - "delete_confirm", - "delete_cancel", - "search", - "clear", - "dialog", - "pagination", - "query-builder" - ] - }, - "product-code-restrictions": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Product code restrictions" }, - "placeholder": { "type": "string", "default": "Enter a product code and hit Enter" }, - "helper_text": { - "type": "string", - "default": "We'll apply this gift card only if one of the rules in the list matches the product code. Wildcards are allowed." - }, - "unit_allow": { "type": "string", "default": "Allow" }, - "unit_block": { "type": "string", "default": "Block" }, - "label_allow": { "type": "string", "default": "Allow {{ value }}" }, - "label_block": { "type": "string", "default": "Block {{ value }}" }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we are unable to store that many product code restrictions at the moment. Please reduce the number of rules in this section until this message disappears." - } - }, - "required": [ - "label", - "placeholder", - "helper_text", - "unit_allow", - "unit_block", - "label_allow", - "label_block", - "v8n_too_long" - ] - }, - "category-restrictions": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Item category restrictions" }, - "status_saving": { "type": "string", "default": "Saving..." }, - "status_loading": { "type": "string", "default": "Loading..." }, - "pagination": { - "additionalProperties": false, - "properties": { - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { "type": "string", "default": "{{from}}-{{to}} out of {{total}}" }, - "previous": { "type": "string", "default": "Previous" }, - "card": { - "additionalProperties": false, - "properties": { - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No restrictions" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["spinner"] - } - }, - "required": ["first", "last", "next", "pagination", "previous", "card"] - }, - "helper_text": { - "type": "string", - "default": "Limit which categories this gift card applies to. All changes are saved automatically." - } - }, - "required": ["label", "status_saving", "status_loading", "pagination", "helper_text"] - }, - "attributes": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Attributes" }, - "delete_header": { "type": "string", "default": "Remove attribute?" }, - "delete_message": { - "type": "string", - "default": "Please confirm that you'd like to remove this attribute from the gift card." - }, - "delete_confirm": { "type": "string", "default": "Remove" }, - "delete_cancel": { "type": "string", "default": "Cancel" }, - "dialog": { - "additionalProperties": false, - "properties": { - "header_create": { "type": "string", "default": "Create attribute" }, - "header_update": { "type": "string", "default": "Update attribute" }, - "close": { "type": "string", "default": "Close" }, - "save": { "type": "string", "default": "Save" }, - "cancel": { "type": "string", "default": "Cancel" }, - "undo_header": { "type": "string", "default": "Unsaved changes" }, - "undo_message": { - "type": "string", - "default": "Looks like you didn't save your changes! What would you like to do with them?" - }, - "undo_cancel": { "type": "string", "default": "Review" }, - "undo_confirm": { "type": "string", "default": "Discard" }, - "attribute-form": { - "additionalProperties": false, - "properties": { - "name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Name" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "Name of this attribute. It does not have to be unique." - }, - "v8n_required": { "type": "string", "default": "Please name this attribute." }, - "v8n_too_long": { - "type": "string", - "default": "Please choose a name that is 500 characters long or less." - } - }, - "required": [ - "label", - "placeholder", - "helper_text", - "v8n_required", - "v8n_too_long" - ] - }, - "value": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Value" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "Value of this attribute. Attribute values are automatically HTML-escaped." - }, - "v8n_required": { - "type": "string", - "default": "Please provide a value for this attribute." - }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we can't store values that are more than 1000 characters long." - } - }, - "required": [ - "label", - "placeholder", - "helper_text", - "v8n_required", - "v8n_too_long" - ] - }, - "visibility": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Visibility" }, - "option_public": { "type": "string", "default": "Everyone" }, - "option_restricted": { "type": "string", "default": "Store admins" }, - "option_private": { "type": "string", "default": "Only me" }, - "helper_text": { - "type": "string", - "default": "Controls who can see this attribute. Public attributes can be shown to anyone, including customers. Private attributes are more suitable for configuration or technical details which are irrelevant to the public. Restricted attributes can only be viewed with the OAuth client that created them." - } - }, - "required": [ - "label", - "option_public", - "option_restricted", - "option_private", - "helper_text" - ] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date": { "type": "string", "default": "{{value, date}}" }, - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" } - }, - "required": ["date", "date_created", "date_modified"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove this attribute? You won't be able to bring it back." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "name", - "value", - "visibility", - "timestamps", - "delete", - "create", - "spinner" - ] - } - }, - "required": [ - "header_create", - "header_update", - "close", - "save", - "cancel", - "undo_header", - "undo_message", - "undo_cancel", - "undo_confirm", - "attribute-form" - ] - }, - "pagination": { - "additionalProperties": false, - "properties": { - "create_button_text": { "type": "string", "default": "Add attribute +" }, - "card": { - "additionalProperties": false, - "properties": { - "delete_button_text": { "type": "string", "default": "Delete" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No attributes" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["delete_button_text", "spinner"] - }, - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { "type": "string", "default": "{{from}}-{{to}} out of {{total}}" }, - "previous": { "type": "string", "default": "Previous" } - }, - "required": [ - "create_button_text", - "card", - "first", - "last", - "next", - "pagination", - "previous" - ] - } - }, - "required": [ - "label", - "delete_header", - "delete_message", - "delete_confirm", - "delete_cancel", - "dialog", - "pagination" - ] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "date": { "type": "string", "default": "{{value, date}}" } - }, - "required": ["date_created", "date_modified", "date"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "This action is irreversible. Are you sure you want to delete this gift card?" - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "header", - "import", - "generate", - "name", - "expires", - "currency", - "provisioning", - "codes", - "product-code-restrictions", - "category-restrictions", - "attributes", - "timestamps", - "delete", - "create", - "spinner" - ] -} diff --git a/src/static/schemas/global.json b/src/static/schemas/global.json deleted file mode 100644 index 3c36fe4f6..000000000 --- a/src/static/schemas/global.json +++ /dev/null @@ -1,164 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "y": { "type": "string", "default": "Year" }, - "y_plural": { "type": "string", "default": "Years" }, - "m": { "type": "string", "default": "Month" }, - "m_plural": { "type": "string", "default": "Months" }, - "w": { "type": "string", "default": "Week" }, - "w_plural": { "type": "string", "default": "Weeks" }, - "d": { "type": "string", "default": "Day" }, - "d_plural": { "type": "string", "default": "Days" }, - "hour": { "type": "string", "default": "Hour" }, - "hour_plural": { "type": "string", "default": "Hours" }, - "minute": { "type": "string", "default": "Minute" }, - "minute_plural": { "type": "string", "default": "Minutes" }, - "duration": { "type": "string", "default": "{{count}} {{units, lowercase}}" }, - "frequency": { "type": "string", "default": "Every {{units, lowercase}}" }, - "frequency_0_5m": { "type": "string", "default": "Twice a month" }, - "frequency_once": { "type": "string", "default": "Just this once" }, - "frequency_plural": { "type": "string", "default": "Every {{count}} {{units, lowercase}}" }, - "and": { "type": "string", "default": "and" }, - "beta": { "type": "string", "default": "Beta" }, - "edit": { "type": "string", "default": "Edit" }, - "save": { "type": "string", "default": "Save changes" }, - "undo_all": { "type": "string", "default": "Undo all" }, - "email": { "type": "string", "default": "Email" }, - "password": { "type": "string", "default": "Password" }, - "password_new": { "type": "string", "default": "New password" }, - "sign_up": { "type": "string", "default": "Create account" }, - "sign_in": { "type": "string", "default": "Sign in" }, - "sign_in_reset": { - "type": "string", - "default": "We need you to update your password for security reasons. Please enter a new password and click Continue." - }, - "sign_in_error": { - "type": "string", - "default": "Your credentials are incorrect. Please check your email and password carefully and try again." - }, - "continue": { "type": "string", "default": "Continue" }, - "go_back": { "type": "string", "default": "Go back" }, - "remember_me": { "type": "string", "default": "Remember me" }, - "reset_password": { "type": "string", "default": "Reset password" }, - "required": { "type": "string", "default": "Please fill in this field" }, - "reload": { "type": "string", "default": "Reload" }, - "choice": { - "additionalProperties": false, - "properties": { - "other": { "type": "string", "default": "Other" }, - "other_placeholder": { "type": "string", "default": "Enter your choice" } - }, - "required": ["other", "other_placeholder"] - }, - "close": { "type": "string", "default": "Close" }, - "weekday-picker": { - "additionalProperties": false, - "properties": { - "hint": { "type": "string", "default": "Allow selecting only {{days, list}} of the month." } - }, - "required": ["hint"] - }, - "monthday-picker": { - "additionalProperties": false, - "properties": { - "hint": { - "type": "string", - "default": "Allow selecting only {{days, list}} of the month." - }, - "warning": { - "type": "string", - "default": "Please note that dates from 29 to 31 may not always be available depending on the month and year." - } - }, - "required": ["hint", "warning"] - }, - "password_reset": { - "additionalProperties": false, - "properties": { - "title": { "type": "string", "default": "Check your inbox!" }, - "message": { - "type": "string", - "default": "We've just sent you an email with further instructions. If you have trouble resetting your password, feel free to contact us." - }, - "action": { "type": "string", "default": "Contact us" } - }, - "required": ["title", "message", "action"] - }, - "errors": { - "additionalProperties": false, - "properties": { - "unknown": { - "additionalProperties": false, - "properties": { - "title": { "type": "string", "default": "Unknown error" }, - "message": { - "type": "string", - "default": "We've just detected an error that this element isn't prepared to handle. If you could take a moment and let us know what happened, we'd greatly appreciate your feedback." - }, - "action": { "type": "string", "default": "Contact us" }, - "href": { "type": "string", "default": "mailto:hello@foxy.io" } - }, - "required": ["title", "message", "action", "href"] - }, - "setup_needed": { - "additionalProperties": false, - "properties": { - "title": { "type": "string", "default": "Setup needed" }, - "message": { - "type": "string", - "default": "This element isn't configured to display any data yet. Please consult our docs for setup instructions." - }, - "action": { "type": "string", "default": "See docs" }, - "href": { "type": "string", "default": "https://docs.foxy.io" } - }, - "required": ["title", "message", "action", "href"] - } - }, - "required": ["unknown", "setup_needed"] - } - }, - "required": [ - "y", - "y_plural", - "m", - "m_plural", - "w", - "w_plural", - "d", - "d_plural", - "hour", - "hour_plural", - "minute", - "minute_plural", - "duration", - "frequency", - "frequency_0_5m", - "frequency_once", - "frequency_plural", - "and", - "beta", - "edit", - "save", - "undo_all", - "email", - "password", - "password_new", - "sign_up", - "sign_in", - "sign_in_reset", - "sign_in_error", - "continue", - "go_back", - "remember_me", - "reset_password", - "required", - "reload", - "choice", - "close", - "weekday-picker", - "monthday-picker", - "password_reset", - "errors" - ] -} diff --git a/src/static/schemas/i18n-editor.json b/src/static/schemas/i18n-editor.json deleted file mode 100644 index 057f6827d..000000000 --- a/src/static/schemas/i18n-editor.json +++ /dev/null @@ -1,20 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "delete_button_title": { "type": "string", "default": "Restore default value" }, - "undo_button": { "type": "string", "default": "Undo" }, - "save_button": { "type": "string", "default": "Save" }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["delete_button_title", "undo_button", "save_button", "spinner"] -} diff --git a/src/static/schemas/integration-card.json b/src/static/schemas/integration-card.json deleted file mode 100644 index 0f8a1df46..000000000 --- a/src/static/schemas/integration-card.json +++ /dev/null @@ -1,19 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "status_active": { "type": "string", "default": "Expires {{ date, date }}" }, - "status_expired": { "type": "string", "default": "Expired" }, - "no_description": { "type": "string", "default": "No description" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["status_active", "status_expired", "no_description", "spinner"] -} diff --git a/src/static/schemas/integration-form.json b/src/static/schemas/integration-form.json deleted file mode 100644 index f8d8beb6d..000000000 --- a/src/static/schemas/integration-form.json +++ /dev/null @@ -1,88 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "header": { - "additionalProperties": false, - "properties": { "no_description": { "type": "string", "default": "No description" } }, - "required": ["no_description"] - }, - "message": { - "additionalProperties": false, - "properties": { - "text": { - "type": "string", - "default": "Please copy the highlighted values below to a safe place and treat them like your password. We will not show them again for security reasons." - }, - "action": { "type": "string", "default": "I've copied the values" } - }, - "required": ["text", "action"] - }, - "project-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Name" }, - "placeholder": { "type": "string", "default": "Type here..." }, - "helper_text": { "type": "string", "default": "" }, - "v8n_required": { "type": "string", "default": "Please name your integration to continue" } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "project-description": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Description" }, - "placeholder": { "type": "string", "default": "Type here..." }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "table": { - "additionalProperties": false, - "properties": { - "expires_date": { "type": "string", "default": "{{ date, date }}" }, - "added_by": { "type": "string", "default": "Added by" }, - "contact": { "type": "string", "default": "Contact" }, - "company": { "type": "string", "default": "Company" }, - "expires": { "type": "string", "default": "Expires on" } - }, - "required": ["expires_date", "added_by", "contact", "company", "expires"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove this token? All applications using this token will lose access to Foxy API immediately." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "header", - "message", - "project-name", - "project-description", - "table", - "delete", - "create", - "spinner" - ] -} diff --git a/src/static/schemas/item-card.json b/src/static/schemas/item-card.json deleted file mode 100644 index 526ca521b..000000000 --- a/src/static/schemas/item-card.json +++ /dev/null @@ -1,55 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "daily": { "type": "string", "default": "Daily" }, - "daily_plural": { "type": "string", "default": "Every {{count}} days" }, - "frequency": { - "type": "string", - "default": "$t({{units}}, { \"count\": {{count}}, \"ns\": \"item-card\" })" - }, - "monthly": { "type": "string", "default": "Monthly" }, - "monthly_plural": { "type": "string", "default": "Every {{count}} months" }, - "subinfo_recurring": { - "type": "string", - "default": "$t(frequency, { \"count\": \"{{count}}\", \"units\": \"{{units}}\", \"ns\": \"item-card\" }) from {{startDate, date}}" - }, - "subinfo_twice_a_month": { - "type": "string", - "default": "$t(twice_a_month, { \"ns\": \"item-card\" }) from {{startDate, date}}" - }, - "twice_a_month": { "type": "string", "default": "Twice a month" }, - "no_code": { "type": "string", "default": "No SKU" }, - "weekly": { "type": "string", "default": "Weekly" }, - "weekly_plural": { "type": "string", "default": "Every {{count}} weeks" }, - "yearly": { "type": "string", "default": "Yearly" }, - "yearly_plural": { "type": "string", "default": "Every {{count}} years" }, - "price": { "type": "string", "default": "{{amount, price}}" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No items" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "daily", - "daily_plural", - "frequency", - "monthly", - "monthly_plural", - "subinfo_recurring", - "subinfo_twice_a_month", - "twice_a_month", - "no_code", - "weekly", - "weekly_plural", - "yearly", - "yearly_plural", - "price", - "spinner" - ] -} diff --git a/src/static/schemas/item-category-card.json b/src/static/schemas/item-category-card.json deleted file mode 100644 index 5f175ab78..000000000 --- a/src/static/schemas/item-category-card.json +++ /dev/null @@ -1,16 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["spinner"] -} diff --git a/src/static/schemas/item-category-form.json b/src/static/schemas/item-category-form.json deleted file mode 100644 index 08579347d..000000000 --- a/src/static/schemas/item-category-form.json +++ /dev/null @@ -1,420 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Name" }, - "placeholder": { "type": "string", "default": "Books" }, - "helper_text": { "type": "string", "default": "Category description for admins." }, - "v8n_required": { "type": "string", "default": "Item category name is required" }, - "v8n_too_long": { - "type": "string", - "default": "Item category name can't exceed 50 characters" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_too_long"] - }, - "code": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Code" }, - "placeholder": { "type": "string", "default": "MY_BOOKS_CATEGORY" }, - "helper_text": { "type": "string", "default": "Unique identifier for the cart." }, - "v8n_required": { "type": "string", "default": "Item category code is required" }, - "v8n_too_long": { - "type": "string", - "default": "Item categoty code can't exceed 50 characters" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_too_long"] - }, - "taxes": { - "additionalProperties": false, - "properties": { - "title": { "type": "string", "default": "Taxes" }, - "helper_text": { - "type": "string", - "default": "Select taxes that will apply to the products in this category. Changes here are saved immediately." - }, - "pagination": { - "additionalProperties": false, - "properties": { - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { "type": "string", "default": "{{from}}-{{to}} out of {{total}}" }, - "previous": { "type": "string", "default": "Previous" }, - "tax-card": { - "additionalProperties": false, - "properties": { - "percent": { "type": "string", "default": "{{fraction, percent}}" }, - "tax_global": { "type": "string", "default": "Global tax" }, - "tax_rate_provider_default": { - "type": "string", - "default": "Default (Thomson Reuters; others)" - }, - "tax_union": { "type": "string", "default": "European Union tax" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "percent", - "tax_global", - "tax_rate_provider_default", - "tax_union", - "spinner" - ] - } - }, - "required": ["first", "last", "next", "pagination", "previous", "tax-card"] - } - }, - "required": ["title", "helper_text", "pagination"] - }, - "item-delivery-type": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Delivery" }, - "option_shipped": { "type": "string", "default": "Shipped using live rates" }, - "option_flat_rate": { "type": "string", "default": "Shipped using a flat rate" }, - "option_downloaded": { "type": "string", "default": "Downloaded by the customer" }, - "option_pickup": { "type": "string", "default": "Picked up by the customer" }, - "option_notshipped": { "type": "string", "default": "Not shipped" }, - "placeholder": { "type": "string", "default": "Select..." }, - "helper_text": { "type": "string", "default": "" }, - "v8n_required": { "type": "string", "default": "Please select a delivery type" } - }, - "required": [ - "label", - "option_shipped", - "option_flat_rate", - "option_downloaded", - "option_pickup", - "option_notshipped", - "placeholder", - "helper_text", - "v8n_required" - ] - }, - "default-weight": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Default weight" }, - "placeholder": { "type": "string", "default": "1" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_required": { "type": "string", "default": "This field is required" }, - "v8n_negative": { "type": "string", "default": "Please enter a positive number" } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_negative"] - }, - "default-weight-unit": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Default weight unit" }, - "placeholder": { "type": "string", "default": "Select..." }, - "option_kgs": { "type": "string", "default": "KG" }, - "option_lbs": { "type": "string", "default": "LG" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_required": { "type": "string", "default": "Please select a unit" } - }, - "required": [ - "label", - "placeholder", - "option_kgs", - "option_lbs", - "helper_text", - "v8n_required" - ] - }, - "default-length-unit": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Default length unit" }, - "placeholder": { "type": "string", "default": "Select..." }, - "option_cm": { "type": "string", "default": "CM" }, - "option_in": { "type": "string", "default": "IN" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_required": { "type": "string", "default": "Please select a unit" } - }, - "required": ["label", "placeholder", "option_cm", "option_in", "helper_text", "v8n_required"] - }, - "max-downloads-per-customer": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Max downloads" }, - "placeholder": { "type": "string", "default": "3" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_required": { "type": "string", "default": "This field is required" }, - "v8n_negative": { "type": "string", "default": "Please enter a positive number" } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_negative"] - }, - "max-downloads-time-period": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Access duration (hrs)" }, - "placeholder": { "type": "string", "default": "24" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_required": { "type": "string", "default": "This field is required" }, - "v8n_negative": { "type": "string", "default": "Please enter a positive number" } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_negative"] - }, - "shipping-flat-rate": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Rate" }, - "placeholder": { "type": "string", "default": "0" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_required": { "type": "string", "default": "This field is required" }, - "v8n_negative": { "type": "string", "default": "Please enter a positive number" } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_negative"] - }, - "shipping-flat-rate-type": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Applies" }, - "placeholder": { "type": "string", "default": "Select..." }, - "option_per_order": { "type": "string", "default": "Per order" }, - "option_per_shipment": { "type": "string", "default": "Per shipment" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_required": { "type": "string", "default": "Please select a value" } - }, - "required": [ - "label", - "placeholder", - "option_per_order", - "option_per_shipment", - "helper_text", - "v8n_required" - ] - }, - "customs-value": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Customs value" }, - "placeholder": { "type": "string", "default": "0" }, - "helper_text": { - "type": "string", - "default": "Enter a dollar amount here for the declared customs value for international shipments. If you leave this blank, the sale price of the item will be used." - }, - "v8n_negative": { "type": "string", "default": "Please enter a positive number" } - }, - "required": ["label", "placeholder", "helper_text", "v8n_negative"] - }, - "handling-fee-type": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Handling fee" }, - "option_none": { "type": "string", "default": "No handling fee" }, - "option_flat_per_order": { "type": "string", "default": "Flat fee per shipment" }, - "option_flat_per_item": { "type": "string", "default": "Flat fee per product" }, - "option_flat_percent": { - "type": "string", - "default": "Flat fee per shipment + % of price" - }, - "option_flat_percent_with_minimum": { - "type": "string", - "default": "Flat fee per shipment or % of price, whichever is greater" - }, - "placeholder": { "type": "string", "default": "Select..." }, - "helper_text": { "type": "string", "default": "" }, - "v8n_required": { "type": "string", "default": "Please select a value" } - }, - "required": [ - "label", - "option_none", - "option_flat_per_order", - "option_flat_per_item", - "option_flat_percent", - "option_flat_percent_with_minimum", - "placeholder", - "helper_text", - "v8n_required" - ] - }, - "handling-fee": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Amount" }, - "placeholder": { "type": "string", "default": "0" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_required": { "type": "string", "default": "This field is required" }, - "v8n_negative": { "type": "string", "default": "Please enter a positive number" } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_negative"] - }, - "handling-fee-minimum": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Minimum fee" }, - "placeholder": { "type": "string", "default": "0" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_required": { "type": "string", "default": "This field is required" }, - "v8n_negative": { "type": "string", "default": "Please enter a positive number" } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_negative"] - }, - "handling-fee-percentage": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Percentage of price" }, - "placeholder": { "type": "string", "default": "0" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_required": { "type": "string", "default": "This field is required" }, - "v8n_negative": { "type": "string", "default": "Please enter a positive number" } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_negative"] - }, - "discount-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Discount" }, - "placeholder": { "type": "string", "default": "Name your discount to open the builder" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "discount-builder": { - "additionalProperties": false, - "properties": { - "tier": { "type": "string", "default": "Tier" }, - "tier_by": { "type": "string", "default": "by" }, - "tier_if": { "type": "string", "default": "if" }, - "tier_allunits": { "type": "string", "default": "price of each item" }, - "tier_incremental": { "type": "string", "default": "price of additional items" }, - "tier_repeat": { "type": "string", "default": "price of next item" }, - "tier_single": { "type": "string", "default": "order total" }, - "tier_then": { "type": "string", "default": "then" }, - "quantity": { "type": "string", "default": "quantity" }, - "total": { "type": "string", "default": "total" }, - "reduce": { "type": "string", "default": "reduce" }, - "increase": { "type": "string", "default": "increase" } - }, - "required": [ - "tier", - "tier_by", - "tier_if", - "tier_allunits", - "tier_incremental", - "tier_repeat", - "tier_single", - "tier_then", - "quantity", - "total", - "reduce", - "increase" - ] - }, - "admin-email-template-uri": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Message to admin" }, - "placeholder": { "type": "string", "default": "None (don't send)" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "admin-email": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Send to" }, - "placeholder": { "type": "string", "default": "admin@example.com" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_required": { "type": "string", "default": "Please enter an email" } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "customer-email-template-uri": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Message to customer" }, - "placeholder": { "type": "string", "default": "None (don't send)" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "gift-recipient-email-template-uri": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Message to gift recipient" }, - "placeholder": { "type": "string", "default": "None (don't send)" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "date": { "type": "string", "default": "{{value, date}}" } - }, - "required": ["date_created", "date_modified", "date"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove this item category? You won't be able to bring it back." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "name", - "code", - "taxes", - "item-delivery-type", - "default-weight", - "default-weight-unit", - "default-length-unit", - "max-downloads-per-customer", - "max-downloads-time-period", - "shipping-flat-rate", - "shipping-flat-rate-type", - "customs-value", - "handling-fee-type", - "handling-fee", - "handling-fee-minimum", - "handling-fee-percentage", - "discount-name", - "discount-builder", - "admin-email-template-uri", - "admin-email", - "customer-email-template-uri", - "gift-recipient-email-template-uri", - "timestamps", - "delete", - "create", - "spinner" - ] -} diff --git a/src/static/schemas/item-form.json b/src/static/schemas/item-form.json deleted file mode 100644 index fb6128e4e..000000000 --- a/src/static/schemas/item-form.json +++ /dev/null @@ -1,817 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "dimensions": { "type": "string", "default": "Dimensions" }, - "subscriptions": { "type": "string", "default": "Subscriptions" }, - "discount": { "type": "string", "default": "Discount" }, - "name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Name" }, - "helper_text": { "type": "string", "default": "Public name of this item." }, - "placeholder": { "type": "string", "default": "13' Laptop Case" }, - "v8n_required": { "type": "string", "default": "Name is required" }, - "v8n_too_long": { "type": "string", "default": "Name mustn't exceed 255 characters" } - }, - "required": ["label", "helper_text", "placeholder", "v8n_required", "v8n_too_long"] - }, - "price": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Price" }, - "helper_text": { "type": "string", "default": "Base price before option modifiers." }, - "placeholder": { "type": "string", "default": "25" }, - "v8n_required": { "type": "string", "default": "Price is required" }, - "v8n_negative": { "type": "string", "default": "Price can't be negative" } - }, - "required": ["label", "helper_text", "placeholder", "v8n_required", "v8n_negative"] - }, - "quantity": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Quantity" }, - "helper_text": { "type": "string", "default": "Number of items in the cart." }, - "placeholder": { "type": "string", "default": "1 by default" }, - "v8n_less_than_one": { "type": "string", "default": "Quantity must be 1 or more" } - }, - "required": ["label", "helper_text", "placeholder", "v8n_less_than_one"] - }, - "subscription-frequency": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Subscription frequency" }, - "helper_text": { - "type": "string", - "default": "This determines how often this subscription will be processed. To modify this value for an existing subscription, you must modify the subscription directly." - }, - "day": { "type": "string", "default": "Day" }, - "day_plural": { "type": "string", "default": "Days" }, - "week": { "type": "string", "default": "Week" }, - "week_plural": { "type": "string", "default": "Weeks" }, - "month": { "type": "string", "default": "Month" }, - "month_plural": { "type": "string", "default": "Months" }, - "year": { "type": "string", "default": "Year" }, - "year_plural": { "type": "string", "default": "Years" } - }, - "required": [ - "label", - "helper_text", - "day", - "day_plural", - "week", - "week_plural", - "month", - "month_plural", - "year", - "year_plural" - ] - }, - "subscription-start-date": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Subscription start" }, - "helper_text": { - "type": "string", - "default": "The original date this subscription began or will begin if set in the future. To modify this value for an existing subscription, you must modify the subscription directly." - }, - "placeholder": { "type": "string", "default": "01/01/2022" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "subscription-end-date": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Subscription end" }, - "helper_text": { - "type": "string", - "default": "If set, the date this subscription will end. The subscription will not run on this day." - }, - "placeholder": { "type": "string", "default": "01/01/2022" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "discount-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Discount name" }, - "helper_text": { - "type": "string", - "default": "The name of the line item discount if it is included on this item." - }, - "placeholder": { "type": "string", "default": "One-off 10% discount" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "discount-builder": { - "additionalProperties": false, - "properties": { - "tier": { "type": "string", "default": "Tier" }, - "tier_by": { "type": "string", "default": "by" }, - "tier_if": { "type": "string", "default": "if" }, - "tier_allunits": { "type": "string", "default": "price of each item" }, - "tier_incremental": { "type": "string", "default": "price of additional items" }, - "tier_repeat": { "type": "string", "default": "price of next item" }, - "tier_single": { "type": "string", "default": "order total" }, - "tier_then": { "type": "string", "default": "then" }, - "quantity": { "type": "string", "default": "quantity" }, - "total": { "type": "string", "default": "total" }, - "reduce": { "type": "string", "default": "reduce" }, - "increase": { "type": "string", "default": "increase" } - }, - "required": [ - "tier", - "tier_by", - "tier_if", - "tier_allunits", - "tier_incremental", - "tier_repeat", - "tier_single", - "tier_then", - "quantity", - "total", - "reduce", - "increase" - ] - }, - "expires": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Expires" }, - "helper_text": { - "type": "string", - "default": "Date when this item will be removed from the cart (optional)." - }, - "placeholder": { "type": "string", "default": "01/01/2022" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "image": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Image" }, - "helper_text": { - "type": "string", - "default": "URL of the image to display for this item in the cart and checkout." - }, - "placeholder": { "type": "string", "default": "https://picsum.photos/256" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "url": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "URL" }, - "helper_text": { - "type": "string", - "default": "Full URL for the customer to view this item on the store website." - }, - "placeholder": { "type": "string", "default": "https://example.com/products/123" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "quantity-min": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Min quantity" }, - "helper_text": { "type": "string", "default": "Minimum quantity per cart." }, - "placeholder": { "type": "string", "default": "1" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "quantity-max": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Max quantity" }, - "helper_text": { "type": "string", "default": "Maximum quantity per cart." }, - "placeholder": { "type": "string", "default": "25" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "shipto": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Shipping address" }, - "helper_text": { - "type": "string", - "default": "Used for multiship to assign this item to a specific shipment." - }, - "placeholder": { "type": "string", "default": "Select address to ship this item to..." } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "width": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Width" }, - "helper_text": { - "type": "string", - "default": "This is currently a placeholder for future use." - }, - "placeholder": { "type": "string", "default": "16" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "height": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Height" }, - "helper_text": { - "type": "string", - "default": "This is currently a placeholder for future use." - }, - "placeholder": { "type": "string", "default": "8" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "length": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Width" }, - "helper_text": { - "type": "string", - "default": "This is currently a placeholder for future use." - }, - "placeholder": { "type": "string", "default": "32" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "weight": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Weight" }, - "helper_text": { - "type": "string", - "default": "Per-item weight, used for shipping rate requests." - }, - "placeholder": { "type": "string", "default": "24" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "item-category-uri": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Item category" }, - "helper_text": { "type": "string", "default": "Item category associated with this item." }, - "placeholder": { "type": "string", "default": "Select item category..." } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "code": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Code" }, - "helper_text": { "type": "string", "default": "Unique item code such as SKU or barcode." }, - "placeholder": { "type": "string", "default": "MY-PRODUCT-001" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "parent-code": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Parent code" }, - "helper_text": { - "type": "string", - "default": "Used if this should be a child product in a bundle." - }, - "placeholder": { "type": "string", "default": "MY-BUNDLE-001" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "discount-details": { - "additionalProperties": false, - "properties": { - "title": { "type": "string", "default": "Discount details" }, - "pagination": { - "additionalProperties": false, - "properties": { - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { "type": "string", "default": "{{from}}-{{to}} out of {{total}}" }, - "previous": { "type": "string", "default": "Previous" }, - "card": { - "additionalProperties": false, - "properties": { - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["spinner"] - } - }, - "required": ["first", "last", "next", "pagination", "previous", "card"] - } - }, - "required": ["title", "pagination"] - }, - "coupon-details": { - "additionalProperties": false, - "properties": { - "title": { "type": "string", "default": "Coupon details" }, - "pagination": { - "additionalProperties": false, - "properties": { - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { "type": "string", "default": "{{from}}-{{to}} out of {{total}}" }, - "previous": { "type": "string", "default": "Previous" }, - "card": { - "additionalProperties": false, - "properties": { - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["spinner"] - } - }, - "required": ["first", "last", "next", "pagination", "previous", "card"] - } - }, - "required": ["title", "pagination"] - }, - "attributes": { - "additionalProperties": false, - "properties": { - "title": { "type": "string", "default": "Attributes" }, - "delete_header": { "type": "string", "default": "Remove attribute?" }, - "delete_message": { - "type": "string", - "default": "Please confirm that you'd like to remove this attribute from the item." - }, - "delete_confirm": { "type": "string", "default": "Remove" }, - "delete_cancel": { "type": "string", "default": "Cancel" }, - "dialog": { - "additionalProperties": false, - "properties": { - "header_create": { "type": "string", "default": "Create attribute" }, - "header_update": { "type": "string", "default": "Update attribute" }, - "close": { "type": "string", "default": "Close" }, - "save": { "type": "string", "default": "Save" }, - "cancel": { "type": "string", "default": "Cancel" }, - "undo_header": { "type": "string", "default": "Unsaved changes" }, - "undo_message": { - "type": "string", - "default": "Looks like you didn't save your changes! What would you like to do with them?" - }, - "undo_cancel": { "type": "string", "default": "Review" }, - "undo_confirm": { "type": "string", "default": "Discard" }, - "attribute-form": { - "additionalProperties": false, - "properties": { - "name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Name" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "Name of this attribute. It does not have to be unique." - }, - "v8n_required": { "type": "string", "default": "Please name this attribute." }, - "v8n_too_long": { - "type": "string", - "default": "Please choose a name that is 500 characters long or less." - } - }, - "required": [ - "label", - "placeholder", - "helper_text", - "v8n_required", - "v8n_too_long" - ] - }, - "value": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Value" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "Value of this attribute. Attribute values are automatically HTML-escaped." - }, - "v8n_required": { - "type": "string", - "default": "Please provide a value for this attribute." - }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we can't store values that are more than 1000 characters long." - } - }, - "required": [ - "label", - "placeholder", - "helper_text", - "v8n_required", - "v8n_too_long" - ] - }, - "visibility": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Visibility" }, - "option_public": { "type": "string", "default": "Everyone" }, - "option_restricted": { "type": "string", "default": "Store admins" }, - "option_private": { "type": "string", "default": "Only me" }, - "helper_text": { - "type": "string", - "default": "Controls who can see this attribute. Public attributes can be shown to anyone, including customers. Private attributes are more suitable for configuration or technical details which are irrelevant to the public. Restricted attributes can only be viewed with the OAuth client that created them." - } - }, - "required": [ - "label", - "option_public", - "option_restricted", - "option_private", - "helper_text" - ] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date": { "type": "string", "default": "{{value, date}}" }, - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" } - }, - "required": ["date", "date_created", "date_modified"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove this attribute? You won't be able to bring it back." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "name", - "value", - "visibility", - "timestamps", - "delete", - "create", - "spinner" - ] - } - }, - "required": [ - "header_create", - "header_update", - "close", - "save", - "cancel", - "undo_header", - "undo_message", - "undo_cancel", - "undo_confirm", - "attribute-form" - ] - }, - "pagination": { - "additionalProperties": false, - "properties": { - "create_button_text": { "type": "string", "default": "Add attribute +" }, - "card": { - "additionalProperties": false, - "properties": { - "delete_button_text": { "type": "string", "default": "Delete" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["delete_button_text", "spinner"] - }, - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { "type": "string", "default": "{{from}}-{{to}} out of {{total}}" }, - "previous": { "type": "string", "default": "Previous" } - }, - "required": [ - "create_button_text", - "card", - "first", - "last", - "next", - "pagination", - "previous" - ] - } - }, - "required": [ - "title", - "delete_header", - "delete_message", - "delete_confirm", - "delete_cancel", - "dialog", - "pagination" - ] - }, - "item-options": { - "additionalProperties": false, - "properties": { - "title": { "type": "string", "default": "Item options" }, - "delete_header": { "type": "string", "default": "Remove item option?" }, - "delete_message": { - "type": "string", - "default": "Please confirm that you'd like to remove this item option from the item." - }, - "delete_confirm": { "type": "string", "default": "Remove" }, - "delete_cancel": { "type": "string", "default": "Cancel" }, - "dialog": { - "additionalProperties": false, - "properties": { - "header_create": { "type": "string", "default": "Create option" }, - "header_update": { "type": "string", "default": "Update option" }, - "close": { "type": "string", "default": "Close" }, - "save": { "type": "string", "default": "Save" }, - "cancel": { "type": "string", "default": "Cancel" }, - "undo_header": { "type": "string", "default": "Unsaved changes" }, - "undo_message": { - "type": "string", - "default": "Looks like you didn't save your changes! What would you like to do with them?" - }, - "undo_cancel": { "type": "string", "default": "Review" }, - "undo_confirm": { "type": "string", "default": "Discard" }, - "item-option-form": { - "additionalProperties": false, - "properties": { - "name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Name" }, - "helper_text": { "type": "string", "default": "" }, - "placeholder": { "type": "string", "default": "Color" }, - "v8n_required": { "type": "string", "default": "Name is required" }, - "v8n_too_long": { - "type": "string", - "default": "Name mustn't exceed 100 characters" - } - }, - "required": [ - "label", - "helper_text", - "placeholder", - "v8n_required", - "v8n_too_long" - ] - }, - "value": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Value" }, - "helper_text": { "type": "string", "default": "" }, - "placeholder": { "type": "string", "default": "Red" }, - "v8n_required": { "type": "string", "default": "Value is required" }, - "v8n_too_long": { - "type": "string", - "default": "Value mustn't exceed 1024 characters" - } - }, - "required": [ - "label", - "helper_text", - "placeholder", - "v8n_required", - "v8n_too_long" - ] - }, - "price-mod": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Price" }, - "helper_text": { "type": "string", "default": "Same currency as item" }, - "placeholder": { "type": "string", "default": "10" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "weight-mod": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Weight" }, - "helper_text": { "type": "string", "default": "Arbitrary units" }, - "placeholder": { "type": "string", "default": "5" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "date": { "type": "string", "default": "{{value, date}}" } - }, - "required": ["date_created", "date_modified", "date"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove this item option? You won't be able to bring it back." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - } - }, - "required": [ - "name", - "value", - "price-mod", - "weight-mod", - "timestamps", - "spinner", - "delete", - "create" - ] - } - }, - "required": [ - "header_create", - "header_update", - "close", - "save", - "cancel", - "undo_header", - "undo_message", - "undo_cancel", - "undo_confirm", - "item-option-form" - ] - }, - "pagination": { - "additionalProperties": false, - "properties": { - "card": { - "additionalProperties": false, - "properties": { - "delete_button_text": { "type": "string", "default": "Delete" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["delete_button_text", "spinner"] - }, - "create_button_text": { "type": "string", "default": "Add option +" }, - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { "type": "string", "default": "{{from}}-{{to}} out of {{total}}" }, - "previous": { "type": "string", "default": "Previous" } - }, - "required": [ - "card", - "create_button_text", - "first", - "last", - "next", - "pagination", - "previous" - ] - } - }, - "required": [ - "title", - "delete_header", - "delete_message", - "delete_confirm", - "delete_cancel", - "dialog", - "pagination" - ] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "date": { "type": "string", "default": "{{value, date}}" } - }, - "required": ["date_created", "date_modified", "date"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove this item? You won't be able to bring it back." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "dimensions", - "subscriptions", - "discount", - "name", - "price", - "quantity", - "subscription-frequency", - "subscription-start-date", - "subscription-end-date", - "discount-name", - "discount-builder", - "expires", - "image", - "url", - "quantity-min", - "quantity-max", - "shipto", - "width", - "height", - "length", - "weight", - "item-category-uri", - "code", - "parent-code", - "discount-details", - "coupon-details", - "attributes", - "item-options", - "timestamps", - "delete", - "create", - "spinner" - ] -} diff --git a/src/static/schemas/item-option-form.json b/src/static/schemas/item-option-form.json deleted file mode 100644 index 843a31fb8..000000000 --- a/src/static/schemas/item-option-form.json +++ /dev/null @@ -1,91 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Name" }, - "helper_text": { "type": "string", "default": "" }, - "placeholder": { "type": "string", "default": "Color" }, - "v8n_required": { "type": "string", "default": "Name is required" }, - "v8n_too_long": { "type": "string", "default": "Name mustn't exceed 100 characters" } - }, - "required": ["label", "helper_text", "placeholder", "v8n_required", "v8n_too_long"] - }, - "value": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Value" }, - "helper_text": { "type": "string", "default": "" }, - "placeholder": { "type": "string", "default": "Red" }, - "v8n_required": { "type": "string", "default": "Value is required" }, - "v8n_too_long": { "type": "string", "default": "Value mustn't exceed 1024 characters" } - }, - "required": ["label", "helper_text", "placeholder", "v8n_required", "v8n_too_long"] - }, - "price-mod": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Price" }, - "helper_text": { "type": "string", "default": "Same currency as item" }, - "placeholder": { "type": "string", "default": "10" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "weight-mod": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Weight" }, - "helper_text": { "type": "string", "default": "Arbitrary units" }, - "placeholder": { "type": "string", "default": "5" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "date": { "type": "string", "default": "{{value, date}}" } - }, - "required": ["date_created", "date_modified", "date"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove this item option? You won't be able to bring it back." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - } - }, - "required": [ - "name", - "value", - "price-mod", - "weight-mod", - "timestamps", - "spinner", - "delete", - "create" - ] -} diff --git a/src/static/schemas/items-form.json b/src/static/schemas/items-form.json deleted file mode 100644 index 9773595b5..000000000 --- a/src/static/schemas/items-form.json +++ /dev/null @@ -1,66 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "checkout": { - "additionalProperties": false, - "properties": { - "buy": { "type": "string", "default": "Buy for {{value}}" }, - "subscribe_single_unit": { - "type": "string", - "default": "Subscribe for {{value}}/{{period}}" - }, - "subscribe_muiltiple_units": { - "type": "string", - "default": "Subscribe for {{value}} {{period}}" - } - }, - "required": ["buy", "subscribe_single_unit", "subscribe_muiltiple_units"] - }, - "freq": { - "additionalProperties": false, - "properties": { - "just_this_once": { "type": "string", "default": "Just this once" }, - "day": { "type": "string", "default": "day" }, - "week": { "type": "string", "default": "week" }, - "month": { "type": "string", "default": "month" }, - "year": { "type": "string", "default": "year" } - }, - "required": ["just_this_once", "day", "week", "month", "year"] - }, - "error": { - "additionalProperties": false, - "properties": { - "invalid_start_date": { "type": "string", "default": "Invalid start date." }, - "invalid_frequency": { "type": "string", "default": "Invalid frequency." }, - "invalid_end_date": { "type": "string", "default": "Invalid end date" }, - "frequency_options_must_be_array": { - "type": "string", - "default": "Frequency options must be an array." - }, - "no_currency": { "type": "string", "default": "No currency available." } - }, - "required": [ - "invalid_start_date", - "invalid_frequency", - "invalid_end_date", - "frequency_options_must_be_array", - "no_currency" - ] - }, - "item": { - "additionalProperties": false, - "properties": { - "remove": { "type": "string", "default": "Remove" }, - "items": { "type": "string", "default": "{{quantity}} items" } - }, - "required": ["remove", "items"] - }, - "price": { - "additionalProperties": false, - "properties": { "total": { "type": "string", "default": "{{ amount }} total" } }, - "required": ["total"] - } - }, - "required": ["checkout", "freq", "error", "item", "price"] -} diff --git a/src/static/schemas/native-integration-card.json b/src/static/schemas/native-integration-card.json deleted file mode 100644 index ec042d03e..000000000 --- a/src/static/schemas/native-integration-card.json +++ /dev/null @@ -1,55 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "image_alt": { "type": "string", "default": "Native integration logo" }, - "title_avalara": { "type": "string", "default": "Avalara" }, - "title_taxjar": { "type": "string", "default": "TaxJar" }, - "title_onesource": { "type": "string", "default": "ONESOURCE" }, - "title_webflow": { "type": "string", "default": "Webflow" }, - "title_zapier": { "type": "string", "default": "Zapier" }, - "title_webhook": { "type": "string", "default": "{{ title }}" }, - "title_apple_pay": { "type": "string", "default": "Apple Pay" }, - "title_custom_tax": { "type": "string", "default": "Custom Tax Endpoint" }, - "subtitle_avalara": { "type": "string", "default": "Account #{{ id }} • {{ service_url }}" }, - "subtitle_taxjar": { - "type": "string", - "default": "SmartCalcs API token ends in ****{{ api_token }}" - }, - "subtitle_onesource": { "type": "string", "default": "{{ service_url }}" }, - "subtitle_webflow": { "type": "string", "default": "{{ site_name }} • ID {{ site_id }}" }, - "subtitle_zapier": { "type": "string", "default": "{{ url }}" }, - "subtitle_webhook": { "type": "string", "default": "{{ url }}" }, - "subtitle_apple_pay": { "type": "string", "default": "Merchant #{{ merchantID }}" }, - "subtitle_custom_tax": { "type": "string", "default": "{{ url }}" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "image_alt", - "title_avalara", - "title_taxjar", - "title_onesource", - "title_webflow", - "title_zapier", - "title_webhook", - "title_apple_pay", - "title_custom_tax", - "subtitle_avalara", - "subtitle_taxjar", - "subtitle_onesource", - "subtitle_webflow", - "subtitle_zapier", - "subtitle_webhook", - "subtitle_apple_pay", - "subtitle_custom_tax", - "spinner" - ] -} diff --git a/src/static/schemas/native-integration-form.json b/src/static/schemas/native-integration-form.json deleted file mode 100644 index fd359c3b7..000000000 --- a/src/static/schemas/native-integration-form.json +++ /dev/null @@ -1,673 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "error": { - "additionalProperties": false, - "properties": { - "already_configured": { - "type": "string", - "default": "This integration is already configured. Please edit the existing integration instead." - } - }, - "required": ["already_configured"] - }, - "provider": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Provider" }, - "option_avalara": { "type": "string", "default": "Avalara" }, - "option_taxjar": { "type": "string", "default": "TaxJar" }, - "option_onesource": { "type": "string", "default": "ONESOURCE" }, - "option_webflow": { "type": "string", "default": "Webflow" }, - "option_zapier": { "type": "string", "default": "Zapier" }, - "helper_text": { - "type": "string", - "default": "Changing service provider is not possible after creation." - }, - "v8n_required": { "type": "string", "default": "Please select a provider." } - }, - "required": [ - "label", - "option_avalara", - "option_taxjar", - "option_onesource", - "option_webflow", - "option_zapier", - "helper_text", - "v8n_required" - ] - }, - "avalara-service-url": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Service URL" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "If in test mode, it should be https://development.avalara.net. If in production, it should be https://avatax.avalara.net unless a different Service URL has been provided to you by Avalara." - }, - "v8n_required": { "type": "string", "default": "Please enter a service URL." }, - "v8n_invalid": { "type": "string", "default": "Please enter a valid URL." } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_invalid"] - }, - "avalara-id": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Account number" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "Be sure to use either a development or production value based on your Service URL." - }, - "v8n_required": { "type": "string", "default": "Please enter an account number." } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "avalara-key": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "License key" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "Be sure to use either a development or production value based on your Service URL." - }, - "v8n_required": { "type": "string", "default": "Please enter a license key." } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "avalara-company-code": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Company code" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "Be sure to use either a development or production value based on your Service URL." - }, - "v8n_required": { "type": "string", "default": "Please enter a company code." } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "avalara-options": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Options" }, - "option_use_ava_tax": { "type": "string", "default": "Use for live taxes" }, - "option_enable_colorado_delivery_fee": { - "type": "string", - "default": "Enable Colorado Delivery Fee" - }, - "option_create_invoice": { "type": "string", "default": "Enable Committed Sales Invoice" }, - "option_use_address_validation": { - "type": "string", - "default": "Validate customer addresses" - }, - "helper_text": { "type": "string", "default": "" } - }, - "required": [ - "label", - "option_use_ava_tax", - "option_enable_colorado_delivery_fee", - "option_create_invoice", - "option_use_address_validation", - "helper_text" - ] - }, - "avalara-address-validation-countries": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Address validation countries" }, - "option_US": { "type": "string", "default": "United States" }, - "option_CA": { "type": "string", "default": "Canada" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "option_US", "option_CA", "helper_text"] - }, - "avalara-category-to-product-tax-code-mappings": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Category to product tax code mappings" }, - "helper_text": { - "type": "string", - "default": "Replace Foxy category codes with AvaTax tax codes when sending data to Avalara. If left empty, the category code will be sent to AvaTax instead." - }, - "placeholder": { "type": "string", "default": "foxy_category_code:avatax_tax_code" }, - "v8n_required": { "type": "string", "default": "Please add at least one tax code mapping." } - }, - "required": ["label", "helper_text", "placeholder", "v8n_required"] - }, - "taxjar-api-token": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "API token" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "Your SmartCalcs API token obtained from TaxJar." - }, - "v8n_required": { "type": "string", "default": "Please enter an API token." } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "taxjar-category-to-product-tax-code-mappings": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Category to product tax code mappings" }, - "helper_text": { - "type": "string", - "default": "Replace Foxy category codes with TaxJar tax codes when sending data to TaxJar. If left empty, the category code will be sent to TaxJar instead." - }, - "placeholder": { "type": "string", "default": "foxy_category_code:taxjar_tax_code" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "taxjar-options": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Options" }, - "option_create_invoice": { "type": "string", "default": "Enable Committed Sales Invoice" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "option_create_invoice", "helper_text"] - }, - "onesource-service-url": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Service URL" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "The ONESOURCE service URL you want to connect to." - }, - "v8n_required": { "type": "string", "default": "Please enter a service URL." }, - "v8n_invalid": { "type": "string", "default": "Please enter a valid URL." } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_invalid"] - }, - "onesource-external-company-id": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "External company ID" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "External company ID mapping to the Determination company owning the audit data." - }, - "v8n_required": { "type": "string", "default": "Please enter an external company ID." } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "onesource-calling-system-number": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Calling system number" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "A unique identifier for your ERP system. The combination of Calling System Number, Host System, and Unique Invoice Number form a unique key for an invoice in the Audit Database." - }, - "v8n_required": { "type": "string", "default": "Please enter a calling system number." } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "onesource-from-city": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "From city" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "This city should match the postal code and country you have configured in your settings." - }, - "v8n_required": { "type": "string", "default": "Please enter a city." } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "onesource-host-system": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Host system" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "A unique name for your ERP system. The combination of Calling System Number, Host System, and Unique Invoice Number form a unique key for an invoice in the Audit Database." - }, - "v8n_required": { "type": "string", "default": "Please enter a host system." } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "onesource-company-role": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Company role" }, - "option_buyer": { "type": "string", "default": "Buyer" }, - "option_seller": { "type": "string", "default": "Seller" }, - "option_middleman": { "type": "string", "default": "Middleman" }, - "helper_text": { - "type": "string", - "default": "The role the company plays in a given transaction. Each role results in different transaction tax and reporting requirements." - } - }, - "required": ["label", "option_buyer", "option_seller", "option_middleman", "helper_text"] - }, - "onesource-part-number-product-option": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Custom product option name" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { - "type": "string", - "default": "If you use a custom product option name to specify your part number such as SKU or ISBN, enter that name here here. You can also set it to \"code\" to use the standard product code attribute." - } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "onesource-product-order-priority": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Custom product order" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { - "type": "string", - "default": "The PRODUCT_CODE field in ONESOURCE is populated via the Foxy category code. The first shippable product will have the RELATED_LINE_NUMBER associated with it. To control which product is listed first, add a list of Foxy category codes here based on the order priority you'd like." - } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "onesource-audit-settings": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Audit" }, - "option_capture_only": { "type": "string", "default": "On capture" }, - "option_auth_and_capture": { "type": "string", "default": "On auth and capture" }, - "option_never": { "type": "string", "default": "Never" }, - "helper_text": { - "type": "string", - "default": "When completing a transaction, use this setting to determine if the information sent to Onesource will be audited and reported." - } - }, - "required": [ - "label", - "option_capture_only", - "option_auth_and_capture", - "option_never", - "helper_text" - ] - }, - "webhook-service": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Payload format" }, - "option_json": { "type": "string", "default": "JSON" }, - "option_legacy_xml": { "type": "string", "default": "XML" }, - "helper_text": { - "type": "string", - "default": "Use JSON for new services. XML webhooks are deprecated and may be removed in the future." - } - }, - "required": ["label", "option_json", "option_legacy_xml", "helper_text"] - }, - "webhook-json-title": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Provider" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "A descriptive title that identies your custom service." - }, - "v8n_required": { "type": "string", "default": "Please enter a title." } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "webhook-json-encryption-key": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Encryption key" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "This value is used as they key to encrypt the and verify the payload sent for the webhook." - }, - "v8n_required": { "type": "string", "default": "Please enter an encryption key." } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "webhook-json-url": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Webhook URL" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "The absolute URL (beginning with https:// or http://) to which Foxy will send the webhook on selected events." - }, - "v8n_required": { "type": "string", "default": "Please enter a webhook URL." }, - "v8n_invalid": { "type": "string", "default": "Please enter a valid URL." } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_invalid"] - }, - "webhook-json-events": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Events" }, - "option_transaction_created": { "type": "string", "default": "Transaction created" }, - "option_subscription_cancelled": { "type": "string", "default": "Subscription cancelled" }, - "helper_text": { - "type": "string", - "default": "Select at least one event that will trigger this webhook." - } - }, - "required": [ - "label", - "option_transaction_created", - "option_subscription_cancelled", - "helper_text" - ] - }, - "webhook-warning": { - "additionalProperties": false, - "properties": { - "warning_text": { - "type": "string", - "default": "We are winding down support for custom services that rely on legacy webhooks and XML datafeed. Please consider using the new JSON webhooks instead." - }, - "link_text": { "type": "string", "default": "Read the announcement" } - }, - "required": ["warning_text", "link_text"] - }, - "webhook-legacy-xml-title": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Provider" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "A descriptive title that identies your custom service." - }, - "v8n_required": { "type": "string", "default": "Please enter a title." } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "webhook-legacy-xml-url": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Webhook URL" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "The absolute URL (beginning with https:// or http://) to which Foxy will send the webhook on selected events." - }, - "v8n_required": { "type": "string", "default": "Please enter a webhook URL." }, - "v8n_invalid": { "type": "string", "default": "Please enter a valid URL." } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_invalid"] - }, - "webflow-site-id": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Site ID" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { "type": "string", "default": "The Site ID of your Webflow site." }, - "v8n_required": { "type": "string", "default": "Please enter a site ID." } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "webflow-site-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Site name" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { "type": "string", "default": "The name of your Webflow site." }, - "v8n_required": { "type": "string", "default": "Please enter a site name." } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "webflow-collection-id": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Collection ID" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "The ID of the collection that products are stored in." - }, - "v8n_required": { "type": "string", "default": "Please enter a collection ID." } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "webflow-collection-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Collection name" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { "type": "string", "default": "The name of your products collection." }, - "v8n_required": { "type": "string", "default": "Please enter a collection name." } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "webflow-sku-field-id": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "SKU field ID" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "The ID of the code field in your products collection." - }, - "v8n_required": { "type": "string", "default": "Please enter a SKU field ID." } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "webflow-sku-field-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "SKU field name" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "The name of the code field in your products collection." - }, - "v8n_required": { "type": "string", "default": "Please enter a SKU field name." } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "webflow-inventory-field-id": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Inventory field ID" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "The ID of the inventory field in your products collection." - }, - "v8n_required": { "type": "string", "default": "Please enter an inventory field ID." } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "webflow-inventory-field-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Inventory field name" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "The name of the inventory field in your products collection." - }, - "v8n_required": { "type": "string", "default": "Please enter an inventory field name." } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "webflow-auth": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Token" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "The OAuth2 authorization token for your Webflow site." - }, - "v8n_required": { "type": "string", "default": "Please enter an authorization token." } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "zapier-event": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Event" }, - "placeholder": { "type": "string", "default": "Defined by Zapier" }, - "helper_text": { "type": "string", "default": "The event this zap is subscribed to." } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "zapier-url": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "URL" }, - "placeholder": { "type": "string", "default": "Defined by Zapier" }, - "helper_text": { "type": "string", "default": "The Zapier webhook subscription URL." } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "zapier-warning": { - "additionalProperties": false, - "properties": { - "warning_text": { - "type": "string", - "default": "Zapier webhooks are read-only and can not be created or modified in the Foxy Admin. Please connect your Zapier webhooks at zapier.com." - } - }, - "required": ["warning_text"] - }, - "apple-pay-merchant-id": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Merchant ID" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { - "type": "string", - "default": "This identifier is configured automatically when you enable Apple Pay in your store settings." - } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "apple-pay-warning": { - "additionalProperties": false, - "properties": { - "warning_text": { - "type": "string", - "default": "Apple Pay native integration entry on this page is informational. To configure Apple Pay, please go to your gateway settings." - } - }, - "required": ["warning_text"] - }, - "custom-tax-url": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "URL" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "The URL of your custom tax service." } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "custom-tax-warning": { - "additionalProperties": false, - "properties": { - "warning_text": { - "type": "string", - "default": "It is currently not possible to configure this integration in this new admin app. Please use the legacy app at admin.foxycart.com to make changes." - } - }, - "required": ["warning_text"] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "date": { "type": "string", "default": "{{value, date}}" } - }, - "required": ["date_created", "date_modified", "date"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Please confirm that you want to delete this integration. This action cannot be undone." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "error", - "provider", - "avalara-service-url", - "avalara-id", - "avalara-key", - "avalara-company-code", - "avalara-options", - "avalara-address-validation-countries", - "avalara-category-to-product-tax-code-mappings", - "taxjar-api-token", - "taxjar-category-to-product-tax-code-mappings", - "taxjar-options", - "onesource-service-url", - "onesource-external-company-id", - "onesource-calling-system-number", - "onesource-from-city", - "onesource-host-system", - "onesource-company-role", - "onesource-part-number-product-option", - "onesource-product-order-priority", - "onesource-audit-settings", - "webhook-service", - "webhook-json-title", - "webhook-json-encryption-key", - "webhook-json-url", - "webhook-json-events", - "webhook-warning", - "webhook-legacy-xml-title", - "webhook-legacy-xml-url", - "webflow-site-id", - "webflow-site-name", - "webflow-collection-id", - "webflow-collection-name", - "webflow-sku-field-id", - "webflow-sku-field-name", - "webflow-inventory-field-id", - "webflow-inventory-field-name", - "webflow-auth", - "zapier-event", - "zapier-url", - "zapier-warning", - "apple-pay-merchant-id", - "apple-pay-warning", - "custom-tax-url", - "custom-tax-warning", - "timestamps", - "delete", - "create", - "spinner" - ] -} diff --git a/src/static/schemas/pagination.json b/src/static/schemas/pagination.json deleted file mode 100644 index e0f8206d5..000000000 --- a/src/static/schemas/pagination.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { "type": "string", "default": "{{from}}-{{to}} out of {{total}}" }, - "previous": { "type": "string", "default": "Previous" } - }, - "required": ["first", "last", "next", "pagination", "previous"] -} diff --git a/src/static/schemas/passkey-card.json b/src/static/schemas/passkey-card.json deleted file mode 100644 index 1097a2ea1..000000000 --- a/src/static/schemas/passkey-card.json +++ /dev/null @@ -1,24 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "subtitle_no_data": { - "type": "string", - "default": "Usage data is not available for this passkey" - }, - "subtitle": { - "type": "string", - "default": "Last used on {{ last_login_date, date }} in {{ last_login_ua }}" - }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["subtitle_no_data", "subtitle", "spinner"] -} diff --git a/src/static/schemas/passkey-form.json b/src/static/schemas/passkey-form.json deleted file mode 100644 index 76bcb8cc6..000000000 --- a/src/static/schemas/passkey-form.json +++ /dev/null @@ -1,86 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "credential-id": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Credential ID" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { - "type": "string", - "default": "Unique identifier of your passkey. You might be able to find this passkey by Credential ID in your password manager." - } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "last-login-date": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Last login date" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { - "type": "string", - "default": "The last time this passkey was used to sign in to your Foxy Account." - } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "last-login-ua": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Last browser" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { - "type": "string", - "default": "User agent string of the browser that was last used to sign in to your Foxy Account with this passkey." - } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "date": { "type": "string", "default": "{{value, date}}" } - }, - "required": ["date_created", "date_modified", "date"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Once deleted, this passkey will no longer be accepted on login but will remain in your password manager. Sessions created with this passkey will stay active." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "credential-id", - "last-login-date", - "last-login-ua", - "timestamps", - "delete", - "create", - "spinner" - ] -} diff --git a/src/static/schemas/payment-card-embed.json b/src/static/schemas/payment-card-embed.json deleted file mode 100644 index 5e18c04b5..000000000 --- a/src/static/schemas/payment-card-embed.json +++ /dev/null @@ -1,119 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "stripe": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Card details" }, - "status": { - "additionalProperties": false, - "properties": { - "idle": { - "type": "string", - "default": "Your card details are securely processed by Stripe. Visit https://stripe.com to learn more." - }, - "busy": { "type": "string", "default": "Encrypting your card details..." }, - "fail": { - "type": "string", - "default": "This service is currently unavailable. Please try again later." - }, - "unsupported": { - "type": "string", - "default": "We don't support this card type. Please try another card." - } - }, - "required": ["idle", "busy", "fail", "unsupported"] - } - }, - "required": ["label", "status"] - }, - "square": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Card details" }, - "status": { - "additionalProperties": false, - "properties": { - "idle": { - "type": "string", - "default": "Your card details are securely processed by Square. Visit https://squareup.com to learn more." - }, - "busy": { "type": "string", "default": "Encrypting your card details..." }, - "fail": { - "type": "string", - "default": "This service is currently unavailable. Please try again later." - }, - "unsupported": { - "type": "string", - "default": "We don't support this card type. Please try another card." - } - }, - "required": ["idle", "busy", "fail", "unsupported"] - } - }, - "required": ["label", "status"] - }, - "default": { - "additionalProperties": false, - "properties": { - "cc-number": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Card number" }, - "placeholder": { "type": "string", "default": "1234 1234 1234 1234" }, - "v8n_required": { "type": "string", "default": "Enter a card number." }, - "v8n_invalid": { - "type": "string", - "default": "Check your card number – it doesn't seem to be valid." - }, - "v8n_unsupported": { "type": "string", "default": "We don't support this card type." } - }, - "required": ["label", "placeholder", "v8n_required", "v8n_invalid", "v8n_unsupported"] - }, - "cc-exp": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Expires on" }, - "placeholder": { "type": "string", "default": "MM/YYYY" }, - "v8n_required": { "type": "string", "default": "Enter an expiry date." }, - "v8n_invalid": { "type": "string", "default": "Enter a date as MM/YYYY." }, - "v8n_expired": { "type": "string", "default": "Your card has expired." } - }, - "required": ["label", "placeholder", "v8n_required", "v8n_invalid", "v8n_expired"] - }, - "cc-csc": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "CSC" }, - "placeholder": { "type": "string", "default": "XXX" }, - "v8n_required": { "type": "string", "default": "Enter a security code." }, - "v8n_invalid": { "type": "string", "default": "Enter a 3-4 digits code." } - }, - "required": ["label", "placeholder", "v8n_required", "v8n_invalid"] - }, - "status": { - "additionalProperties": false, - "properties": { - "idle": { - "type": "string", - "default": "Your card details are securely processed by Foxy.io. Visit https://foxy.io to learn more." - }, - "busy": { "type": "string", "default": "Encrypting your card details..." }, - "fail": { - "type": "string", - "default": "This service is currently unavailable. Please try again later." - }, - "misconfigured": { - "type": "string", - "default": "This form is not configured correctly. If you are seeing this message as a customer, please report this issue to the store support team." - } - }, - "required": ["idle", "busy", "fail", "misconfigured"] - } - }, - "required": ["cc-number", "cc-exp", "cc-csc", "status"] - } - }, - "required": ["stripe", "square", "default"] -} diff --git a/src/static/schemas/payment-card.json b/src/static/schemas/payment-card.json deleted file mode 100644 index fe498cae7..000000000 --- a/src/static/schemas/payment-card.json +++ /dev/null @@ -1,36 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "code": { "type": "string", "default": "Code" }, - "date": { "type": "string", "default": "{{value, date}}" }, - "fraud_risk": { "type": "string", "default": "Fraud risk: {{ score }}" }, - "processor_response": { "type": "string", "default": "{{ processor_response }}" }, - "purchase_order": { "type": "string", "default": "PO {{ purchase_order }}" }, - "paypal_payer_id": { "type": "string", "default": "PayPal Payer ID {{ paypal_payer_id }}" }, - "third_party_id": { "type": "string", "default": "External ID {{ third_party_id }}" }, - "price": { "type": "string", "default": "{{amount, price}}" }, - "unknown": { "type": "string", "default": "Unknown" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "code", - "date", - "fraud_risk", - "processor_response", - "purchase_order", - "paypal_payer_id", - "third_party_id", - "price", - "unknown", - "spinner" - ] -} diff --git a/src/static/schemas/payment-method-card.json b/src/static/schemas/payment-method-card.json deleted file mode 100644 index 1291d38ed..000000000 --- a/src/static/schemas/payment-method-card.json +++ /dev/null @@ -1,439 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "cancel": { "type": "string", "default": "Cancel" }, - "delete": { "type": "string", "default": "Delete" }, - "add": { "type": "string", "default": "Add payment method" }, - "update": { "type": "string", "default": "Update payment method" }, - "delete_prompt": { - "type": "string", - "default": "This payment method will be permanently deleted from your account. Would you like to continue?" - }, - "expires": { "type": "string", "default": "Expires" }, - "last_4_digits": { "type": "string", "default": "Last 4 digits" }, - "unknown": { "type": "string", "default": "Unknown" }, - "dialog": { - "additionalProperties": false, - "properties": { - "close": { "type": "string", "default": "Close" }, - "dialog_header_add": { "type": "string", "default": "Add payment method" }, - "dialog_header_update": { "type": "string", "default": "Update payment method" }, - "update-payment-method-form": { - "additionalProperties": false, - "properties": { - "status": { - "additionalProperties": false, - "properties": { - "cc_token_success": { - "type": "string", - "default": "Card details saved successfully." - }, - "close": { "type": "string", "default": "Close" } - }, - "required": ["cc_token_success", "close"] - }, - "error": { - "additionalProperties": false, - "properties": { - "cc_token_invalid": { - "type": "string", - "default": "Unfortunately, we couldn't save your card details. Please try again later or use a different card." - } - }, - "required": ["cc_token_invalid"] - }, - "template-set": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Template set" }, - "dialog": { - "additionalProperties": false, - "properties": { - "cancel": { "type": "string", "default": "Cancel" }, - "close": { "type": "string", "default": "Close" }, - "header": { "type": "string", "default": "Choose a template set" }, - "selection": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" }, - "search": { "type": "string", "default": "Search" }, - "clear": { "type": "string", "default": "Clear" }, - "pagination": { - "additionalProperties": false, - "properties": { - "search_button_text": { "type": "string", "default": "Search" }, - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { - "type": "string", - "default": "{{from}}-{{to}} out of {{total}}" - }, - "previous": { "type": "string", "default": "Previous" }, - "card": { - "additionalProperties": false, - "properties": { - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { - "type": "string", - "default": "No template sets found" - }, - "loading_error": { - "type": "string", - "default": "Unknown error" - } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["spinner"] - } - }, - "required": [ - "search_button_text", - "first", - "last", - "next", - "pagination", - "previous", - "card" - ] - }, - "query-builder": { - "additionalProperties": false, - "properties": { - "filters": { - "additionalProperties": false, - "properties": {}, - "required": [] - }, - "add_or_clause": { "type": "string", "default": "Add OR clause" }, - "add_value": { "type": "string", "default": "Add value" }, - "code": { "type": "string", "default": "Code" }, - "date": { "type": "string", "default": "{{value, date}}" }, - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "delete": { "type": "string", "default": "Delete" }, - "field": { "type": "string", "default": "Field" }, - "hidden": { "type": "string", "default": "Hidden" }, - "is_defined_false": { "type": "string", "default": "Not defined" }, - "is_defined_true": { "type": "string", "default": "Defined" }, - "name": { "type": "string", "default": "Name" }, - "operator_equal": { "type": "string", "default": "Equal" }, - "operator_greaterthan": { "type": "string", "default": "Greater than" }, - "operator_greaterthanorequal": { - "type": "string", - "default": "Greater than or equal" - }, - "operator_in": { "type": "string", "default": "One of" }, - "operator_isdefined": { "type": "string", "default": "Is defined" }, - "operator_lessthan": { "type": "string", "default": "Less than" }, - "operator_lessthanorequal": { - "type": "string", - "default": "Less than or equal" - }, - "operator_not": { "type": "string", "default": "Not equal" }, - "or": { "type": "string", "default": "Or" }, - "query_builder_group": { - "type": "string", - "default": "Group of filters" - }, - "query_builder_rule": { "type": "string", "default": "Filter" }, - "range_from": { "type": "string", "default": "From" }, - "range_to": { "type": "string", "default": "To" }, - "type": { "type": "string", "default": "Type" }, - "type_any": { "type": "string", "default": "Field of unknown type" }, - "type_attribute": { "type": "string", "default": "Key-value resource" }, - "type_date": { "type": "string", "default": "Date field" }, - "type_here": { "type": "string", "default": "Type here..." }, - "type_number": { "type": "string", "default": "Numeric field" }, - "type_string": { "type": "string", "default": "Text field" }, - "used_codes": { "type": "string", "default": "Codes used" }, - "value": { "type": "string", "default": "Value" } - }, - "required": [ - "filters", - "add_or_clause", - "add_value", - "code", - "date", - "date_created", - "date_modified", - "delete", - "field", - "hidden", - "is_defined_false", - "is_defined_true", - "name", - "operator_equal", - "operator_greaterthan", - "operator_greaterthanorequal", - "operator_in", - "operator_isdefined", - "operator_lessthan", - "operator_lessthanorequal", - "operator_not", - "or", - "query_builder_group", - "query_builder_rule", - "range_from", - "range_to", - "type", - "type_any", - "type_attribute", - "type_date", - "type_here", - "type_number", - "type_string", - "used_codes", - "value" - ] - } - }, - "required": [ - "label", - "helper_text", - "search", - "clear", - "pagination", - "query-builder" - ] - } - }, - "required": ["cancel", "close", "header", "selection"] - }, - "card": { - "additionalProperties": false, - "properties": { - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "Click to select" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["spinner"] - }, - "helper_text": { - "type": "string", - "default": "Template set determines which payment gateway and tokenization service will be used to capture card details." - } - }, - "required": ["label", "dialog", "card", "helper_text"] - }, - "cc-token": { - "additionalProperties": false, - "properties": { - "tokenize": { "type": "string", "default": "Save card" }, - "payment-card-embed": { - "additionalProperties": false, - "properties": { - "stripe": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Card details" }, - "status": { - "additionalProperties": false, - "properties": { - "idle": { - "type": "string", - "default": "Your card details are securely processed by Stripe. Visit https://stripe.com to learn more." - }, - "busy": { - "type": "string", - "default": "Encrypting your card details..." - }, - "fail": { - "type": "string", - "default": "This service is currently unavailable. Please try again later." - }, - "unsupported": { - "type": "string", - "default": "We don't support this card type. Please try another card." - } - }, - "required": ["idle", "busy", "fail", "unsupported"] - } - }, - "required": ["label", "status"] - }, - "square": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Card details" }, - "status": { - "additionalProperties": false, - "properties": { - "idle": { - "type": "string", - "default": "Your card details are securely processed by Square. Visit https://squareup.com to learn more." - }, - "busy": { - "type": "string", - "default": "Encrypting your card details..." - }, - "fail": { - "type": "string", - "default": "This service is currently unavailable. Please try again later." - }, - "unsupported": { - "type": "string", - "default": "We don't support this card type. Please try another card." - } - }, - "required": ["idle", "busy", "fail", "unsupported"] - } - }, - "required": ["label", "status"] - }, - "default": { - "additionalProperties": false, - "properties": { - "cc-number": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Card number" }, - "placeholder": { "type": "string", "default": "1234 1234 1234 1234" }, - "v8n_required": { "type": "string", "default": "Enter a card number." }, - "v8n_invalid": { - "type": "string", - "default": "Check your card number – it doesn't seem to be valid." - }, - "v8n_unsupported": { - "type": "string", - "default": "We don't support this card type." - } - }, - "required": [ - "label", - "placeholder", - "v8n_required", - "v8n_invalid", - "v8n_unsupported" - ] - }, - "cc-exp": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Expires on" }, - "placeholder": { "type": "string", "default": "MM/YYYY" }, - "v8n_required": { - "type": "string", - "default": "Enter an expiry date." - }, - "v8n_invalid": { - "type": "string", - "default": "Enter a date as MM/YYYY." - }, - "v8n_expired": { "type": "string", "default": "Your card has expired." } - }, - "required": [ - "label", - "placeholder", - "v8n_required", - "v8n_invalid", - "v8n_expired" - ] - }, - "cc-csc": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "CSC" }, - "placeholder": { "type": "string", "default": "XXX" }, - "v8n_required": { - "type": "string", - "default": "Enter a security code." - }, - "v8n_invalid": { - "type": "string", - "default": "Enter a 3-4 digits code." - } - }, - "required": ["label", "placeholder", "v8n_required", "v8n_invalid"] - }, - "status": { - "additionalProperties": false, - "properties": { - "idle": { - "type": "string", - "default": "Your card details are securely processed by Foxy.io. Visit https://foxy.io to learn more." - }, - "busy": { - "type": "string", - "default": "Encrypting your card details..." - }, - "fail": { - "type": "string", - "default": "This service is currently unavailable. Please try again later." - }, - "misconfigured": { - "type": "string", - "default": "This form is not configured correctly. If you are seeing this message as a customer, please report this issue to the store support team." - } - }, - "required": ["idle", "busy", "fail", "misconfigured"] - } - }, - "required": ["cc-number", "cc-exp", "cc-csc", "status"] - } - }, - "required": ["stripe", "square", "default"] - } - }, - "required": ["tokenize", "payment-card-embed"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" }, - "loading_empty": { - "type": "string", - "default": "This form works only with existing payment methods" - } - }, - "required": ["refresh", "loading_busy", "loading_error", "loading_empty"] - } - }, - "required": ["status", "error", "template-set", "cc-token", "spinner"] - } - }, - "required": [ - "close", - "dialog_header_add", - "dialog_header_update", - "update-payment-method-form" - ] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No payment method" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "cancel", - "delete", - "add", - "update", - "delete_prompt", - "expires", - "last_4_digits", - "unknown", - "dialog", - "spinner" - ] -} diff --git a/src/static/schemas/payment-method-form.json b/src/static/schemas/payment-method-form.json deleted file mode 100644 index 253149f09..000000000 --- a/src/static/schemas/payment-method-form.json +++ /dev/null @@ -1,146 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "tab_0": { "type": "string", "default": "Use the saved card" }, - "tab_1": { "type": "string", "default": "Add a new card" }, - "cc-number": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Card number" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "cc-exp": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Expires on" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "cc-csc": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "CSC" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "cc-token": { - "additionalProperties": false, - "properties": { - "cc-number": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Card number" }, - "placeholder": { "type": "string", "default": "1234 1234 1234 1234" }, - "v8n_required": { "type": "string", "default": "Enter a card number" }, - "v8n_invalid": { - "type": "string", - "default": "Check your card number – it doesn't seem to be valid" - }, - "v8n_unsupported": { "type": "string", "default": "We don't support this card type" } - }, - "required": ["label", "placeholder", "v8n_required", "v8n_invalid", "v8n_unsupported"] - }, - "cc-exp": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Expires on" }, - "placeholder": { "type": "string", "default": "MM/YYYY" }, - "v8n_required": { "type": "string", "default": "Enter an expiry date" }, - "v8n_invalid": { "type": "string", "default": "Enter a date as MM/YYYY" }, - "v8n_expired": { "type": "string", "default": "Your card has expired" } - }, - "required": ["label", "placeholder", "v8n_required", "v8n_invalid", "v8n_expired"] - }, - "cc-csc": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "CSC" }, - "placeholder": { "type": "string", "default": "XXX" }, - "v8n_required": { "type": "string", "default": "Enter a security code" }, - "v8n_invalid": { "type": "string", "default": "Enter a 3-4 digits code" } - }, - "required": ["label", "placeholder", "v8n_required", "v8n_invalid"] - }, - "supported-cards": { - "additionalProperties": false, - "properties": { "label": { "type": "string", "default": "Accepted cards" } }, - "required": ["label"] - }, - "status-message": { - "additionalProperties": false, - "properties": { - "idle": { - "type": "string", - "default": "Your card details are protected with SSL and a NSA-approved encryption algorithm." - }, - "busy": { "type": "string", "default": "Encrypting your card details..." }, - "fail_5xx": { - "type": "string", - "default": "Card tokenization service is currently unavailable. Please try again later." - }, - "fail_4xx": { - "type": "string", - "default": "This card doesn't appear to be valid. Please check the details and try again." - } - }, - "required": ["idle", "busy", "fail_5xx", "fail_4xx"] - } - }, - "required": ["cc-number", "cc-exp", "cc-csc", "supported-cards", "status-message"] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date_created": { "type": "string", "default": "Added on" }, - "date_modified": { "type": "string", "default": "Last updated" }, - "date": { "type": "string", "default": "{{value, date}}" } - }, - "required": ["date_created", "date_modified", "date"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "If you have any active subscriptions, they will fail on next payment date. Are you sure you'd like to remove this card?" - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Add card" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Failed to load" } - }, - "required": ["loading_busy", "loading_error"] - } - }, - "required": [ - "tab_0", - "tab_1", - "cc-number", - "cc-exp", - "cc-csc", - "cc-token", - "timestamps", - "delete", - "create", - "spinner" - ] -} diff --git a/src/static/schemas/payments-api-fraud-protection-card.json b/src/static/schemas/payments-api-fraud-protection-card.json deleted file mode 100644 index 3c366bf10..000000000 --- a/src/static/schemas/payments-api-fraud-protection-card.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "image_alt": { "type": "string", "default": "Fraud protection logo" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["image_alt", "spinner"] -} diff --git a/src/static/schemas/payments-api-fraud-protection-form.json b/src/static/schemas/payments-api-fraud-protection-form.json deleted file mode 100644 index 9c32a61ee..000000000 --- a/src/static/schemas/payments-api-fraud-protection-form.json +++ /dev/null @@ -1,87 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "default_additional_field_placeholder": { "type": "string", "default": "None" }, - "select_protection_title": { - "type": "string", - "default": "Select a fraud protection type to get started" - }, - "select_another_button_label": { "type": "string", "default": "Back to fraud protections" }, - "score-threshold-reject": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Rejection threshold" }, - "placeholder": { "type": "string", "default": "Default" }, - "helper_text": { - "type": "string", - "default": "A number between 0 and 100. 0 will disable minFraud and 100 will turn it on for logging but still allow all transactions to go through." - }, - "v8n_out_of_range": { - "type": "string", - "default": "Please enter a whole number between 0 and 100 (inclusive)." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_out_of_range"] - }, - "description": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Description" }, - "placeholder": { "type": "string", "default": "None" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "Please reduce this description to a 100 characters or less" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "date": { "type": "string", "default": "{{value, date}}" } - }, - "required": ["date_created", "date_modified", "date"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Remove" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove this fraud protection? You'll need to configure it again if you decide to add it back." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Add fraud protection" } }, - "required": ["create"] - } - }, - "required": [ - "default_additional_field_placeholder", - "select_protection_title", - "select_another_button_label", - "score-threshold-reject", - "description", - "timestamps", - "spinner", - "delete", - "create" - ] -} diff --git a/src/static/schemas/payments-api-payment-method-card.json b/src/static/schemas/payments-api-payment-method-card.json deleted file mode 100644 index ce4bc93d6..000000000 --- a/src/static/schemas/payments-api-payment-method-card.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "image_alt": { "type": "string", "default": "Payment gateway logo" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["image_alt", "spinner"] -} diff --git a/src/static/schemas/payments-api-payment-method-form.json b/src/static/schemas/payments-api-payment-method-form.json deleted file mode 100644 index 3c1f2656a..000000000 --- a/src/static/schemas/payments-api-payment-method-form.json +++ /dev/null @@ -1,131 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "select_method_title": { "type": "string", "default": "Select a payment method" }, - "select_another_button_label": { "type": "string", "default": "Select another" }, - "default_additional_field_placeholder": { "type": "string", "default": "None" }, - "conflict_message": { "type": "string", "default": "Remove {{ name }} to use this method" }, - "tab_live": { "type": "string", "default": "Live setup" }, - "tab_test": { "type": "string", "default": "Test setup" }, - "account-id": { - "additionalProperties": false, - "properties": { "label": { "type": "string", "default": "Account ID" } }, - "required": ["label"] - }, - "account-key": { - "additionalProperties": false, - "properties": { "label": { "type": "string", "default": "Account Key" } }, - "required": ["label"] - }, - "third-party-key": { - "additionalProperties": false, - "properties": { "label": { "type": "string", "default": "3rd-party key" } }, - "required": ["label"] - }, - "test-account-id": { - "additionalProperties": false, - "properties": { "label": { "type": "string", "default": "Account ID" } }, - "required": ["label"] - }, - "test-account-key": { - "additionalProperties": false, - "properties": { "label": { "type": "string", "default": "Account Key" } }, - "required": ["label"] - }, - "test-third-party-key": { - "additionalProperties": false, - "properties": { "label": { "type": "string", "default": "3rd-party key" } }, - "required": ["label"] - }, - "three-d-secure-toggle": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "3D Secure" }, - "option_off": { "type": "string", "default": "Off" }, - "option_all_cards": { "type": "string", "default": "On for all cards" }, - "option_maestro_only": { "type": "string", "default": "On for Maestro cards" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "option_off", "option_all_cards", "option_maestro_only", "helper_text"] - }, - "three-d-secure-response": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "3D Secure Response" }, - "option_valid_only": { "type": "string", "default": "Require valid response" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "option_valid_only", "helper_text"] - }, - "description": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Description" }, - "placeholder": { "type": "string", "default": "Defaults to the gateway name" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "Please reduce this description to a 100 characters or less" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "date": { "type": "string", "default": "{{value, date}}" } - }, - "required": ["date_created", "date_modified", "date"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Remove" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove this payment method? You'll need to configure it again if you decide to bring it back." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - } - }, - "required": [ - "select_method_title", - "select_another_button_label", - "default_additional_field_placeholder", - "conflict_message", - "tab_live", - "tab_test", - "account-id", - "account-key", - "third-party-key", - "test-account-id", - "test-account-key", - "test-third-party-key", - "three-d-secure-toggle", - "three-d-secure-response", - "description", - "timestamps", - "spinner", - "delete", - "create" - ] -} diff --git a/src/static/schemas/payments-api-payment-preset-card.json b/src/static/schemas/payments-api-payment-preset-card.json deleted file mode 100644 index ed38a3f04..000000000 --- a/src/static/schemas/payments-api-payment-preset-card.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "status_test": { "type": "string", "default": "Test" }, - "status_live": { "type": "string", "default": "Live" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["status_test", "status_live", "spinner"] -} diff --git a/src/static/schemas/payments-api-payment-preset-form.json b/src/static/schemas/payments-api-payment-preset-form.json deleted file mode 100644 index 92ca81462..000000000 --- a/src/static/schemas/payments-api-payment-preset-form.json +++ /dev/null @@ -1,208 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "description": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Description" }, - "placeholder": { "type": "string", "default": "E.g. EU & UK Payment Options" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_required": { "type": "string", "default": "Please describe this payment method set" }, - "v8n_too_long": { - "type": "string", - "default": "Please reduce this description to a 100 characters or less" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_too_long"] - }, - "is-live": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "" }, - "option_live": { "type": "string", "default": "Use live credentials" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "option_live", "helper_text"] - }, - "is-purchase-order-enabled": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "" }, - "option_true": { "type": "string", "default": "Allow purchase orders" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "option_true", "helper_text"] - }, - "payment-methods": { - "additionalProperties": false, - "properties": { - "delete_header": { "type": "string", "default": "Remove payment method" }, - "delete_message": { - "type": "string", - "default": "Are you sure you'd like to remove this payment method? You'll need to configure it again if you decide to bring it back." - }, - "delete_confirm": { "type": "string", "default": "Remove" }, - "delete_cancel": { "type": "string", "default": "Cancel" }, - "label": { "type": "string", "default": "Payment methods" }, - "dialog": { - "additionalProperties": false, - "properties": { - "header_update": { "type": "string", "default": "Payment method" }, - "header_create": { "type": "string", "default": "New payment method" }, - "close": { "type": "string", "default": "Close" }, - "cancel": { "type": "string", "default": "Cancel" }, - "save": { "type": "string", "default": "Save" }, - "undo_header": { "type": "string", "default": "Unsaved changes" }, - "undo_message": { - "type": "string", - "default": "Looks like you didn't save your changes! What would you like to do with them?" - }, - "undo_cancel": { "type": "string", "default": "Review" }, - "undo_confirm": { "type": "string", "default": "Discard" } - }, - "required": [ - "header_update", - "header_create", - "close", - "cancel", - "save", - "undo_header", - "undo_message", - "undo_cancel", - "undo_confirm" - ] - }, - "pagination": { - "additionalProperties": false, - "properties": { - "create_button_text": { "type": "string", "default": "Add payment method +" }, - "card": { - "additionalProperties": false, - "properties": { "delete_button_text": { "type": "string", "default": "Remove" } }, - "required": ["delete_button_text"] - } - }, - "required": ["create_button_text", "card"] - } - }, - "required": [ - "delete_header", - "delete_message", - "delete_confirm", - "delete_cancel", - "label", - "dialog", - "pagination" - ] - }, - "fraud-protections": { - "additionalProperties": false, - "properties": { - "delete_header": { "type": "string", "default": "Remove fraud protection" }, - "delete_message": { - "type": "string", - "default": "Are you sure you'd like to remove this fraud protection? You'll need to configure it again if you decide to bring it back." - }, - "delete_confirm": { "type": "string", "default": "Remove" }, - "delete_cancel": { "type": "string", "default": "Cancel" }, - "label": { "type": "string", "default": "Fraud protections" }, - "dialog": { - "additionalProperties": false, - "properties": { - "header_update": { "type": "string", "default": "Fraud protection" }, - "header_create": { "type": "string", "default": "New fraud protection" }, - "close": { "type": "string", "default": "Close" }, - "cancel": { "type": "string", "default": "Cancel" }, - "save": { "type": "string", "default": "Save" }, - "undo_header": { "type": "string", "default": "Unsaved changes" }, - "undo_message": { - "type": "string", - "default": "Looks like you didn't save your changes! What would you like to do with them?" - }, - "undo_cancel": { "type": "string", "default": "Review" }, - "undo_confirm": { "type": "string", "default": "Discard" } - }, - "required": [ - "header_update", - "header_create", - "close", - "cancel", - "save", - "undo_header", - "undo_message", - "undo_cancel", - "undo_confirm" - ] - }, - "pagination": { - "additionalProperties": false, - "properties": { - "create_button_text": { "type": "string", "default": "Add fraud protection +" }, - "card": { - "additionalProperties": false, - "properties": { "delete_button_text": { "type": "string", "default": "Remove" } }, - "required": ["delete_button_text"] - } - }, - "required": ["create_button_text", "card"] - } - }, - "required": [ - "delete_header", - "delete_message", - "delete_confirm", - "delete_cancel", - "label", - "dialog", - "pagination" - ] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "date": { "type": "string", "default": "{{value, date}}" } - }, - "required": ["date_created", "date_modified", "date"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove this payment method set? You won't be able to bring it back." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - } - }, - "required": [ - "description", - "is-live", - "is-purchase-order-enabled", - "payment-methods", - "fraud-protections", - "timestamps", - "spinner", - "delete", - "create" - ] -} diff --git a/src/static/schemas/query-builder.json b/src/static/schemas/query-builder.json deleted file mode 100644 index 4bece82d5..000000000 --- a/src/static/schemas/query-builder.json +++ /dev/null @@ -1,68 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "add_or_clause": { "type": "string", "default": "Add OR clause" }, - "add_value": { "type": "string", "default": "Add value" }, - "date": { "type": "string", "default": "{{value, date}}" }, - "delete": { "type": "string", "default": "Delete" }, - "field": { "type": "string", "default": "Field" }, - "hidden": { "type": "string", "default": "Hidden" }, - "is_defined_false": { "type": "string", "default": "Not defined" }, - "is_defined_true": { "type": "string", "default": "Defined" }, - "name": { "type": "string", "default": "Name" }, - "operator_equal": { "type": "string", "default": "Equal" }, - "operator_greaterthan": { "type": "string", "default": "Greater than" }, - "operator_greaterthanorequal": { "type": "string", "default": "Greater than or equal" }, - "operator_in": { "type": "string", "default": "One of" }, - "operator_isdefined": { "type": "string", "default": "Is defined" }, - "operator_lessthan": { "type": "string", "default": "Less than" }, - "operator_lessthanorequal": { "type": "string", "default": "Less than or equal" }, - "operator_not": { "type": "string", "default": "Not equal" }, - "or": { "type": "string", "default": "Or" }, - "query_builder_group": { "type": "string", "default": "Group of filters" }, - "query_builder_rule": { "type": "string", "default": "Filter" }, - "range_from": { "type": "string", "default": "From" }, - "range_to": { "type": "string", "default": "To" }, - "type": { "type": "string", "default": "Type" }, - "type_any": { "type": "string", "default": "Field of unknown type" }, - "type_attribute": { "type": "string", "default": "Key-value resource" }, - "type_date": { "type": "string", "default": "Date field" }, - "type_here": { "type": "string", "default": "Type here..." }, - "type_number": { "type": "string", "default": "Numeric field" }, - "type_string": { "type": "string", "default": "Text field" }, - "value": { "type": "string", "default": "Value" } - }, - "required": [ - "add_or_clause", - "add_value", - "date", - "delete", - "field", - "hidden", - "is_defined_false", - "is_defined_true", - "name", - "operator_equal", - "operator_greaterthan", - "operator_greaterthanorequal", - "operator_in", - "operator_isdefined", - "operator_lessthan", - "operator_lessthanorequal", - "operator_not", - "or", - "query_builder_group", - "query_builder_rule", - "range_from", - "range_to", - "type", - "type_any", - "type_attribute", - "type_date", - "type_here", - "type_number", - "type_string", - "value" - ] -} diff --git a/src/static/schemas/region.json b/src/static/schemas/region.json deleted file mode 100644 index e28858e80..000000000 --- a/src/static/schemas/region.json +++ /dev/null @@ -1,136 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "AL": { "type": "string", "default": "Alabama" }, - "AK": { "type": "string", "default": "Alaska" }, - "AS": { "type": "string", "default": "American Samoa" }, - "AZ": { "type": "string", "default": "Arizona" }, - "AR": { "type": "string", "default": "Arkansas" }, - "AF": { "type": "string", "default": "Armed Forces Africa" }, - "AA": { "type": "string", "default": "Armed Forces Americas" }, - "AC": { "type": "string", "default": "Armed Forces Canada" }, - "AE": { "type": "string", "default": "Armed Forces Europe" }, - "AM": { "type": "string", "default": "Armed Forces Middle East" }, - "AP": { "type": "string", "default": "Armed Forces Pacific" }, - "CA": { "type": "string", "default": "California" }, - "CO": { "type": "string", "default": "Colorado" }, - "CT": { "type": "string", "default": "Connecticut" }, - "DE": { "type": "string", "default": "Delaware" }, - "DC": { "type": "string", "default": "Washington DC" }, - "FM": { "type": "string", "default": "Federated States Of Micronesia" }, - "FL": { "type": "string", "default": "Florida" }, - "GA": { "type": "string", "default": "Georgia" }, - "GU": { "type": "string", "default": "Guam" }, - "HI": { "type": "string", "default": "Hawaii" }, - "ID": { "type": "string", "default": "Idaho" }, - "IL": { "type": "string", "default": "Illinois" }, - "IN": { "type": "string", "default": "Indiana" }, - "IA": { "type": "string", "default": "Iowa" }, - "KS": { "type": "string", "default": "Kansas" }, - "KY": { "type": "string", "default": "Kentucky" }, - "LA": { "type": "string", "default": "Louisiana" }, - "ME": { "type": "string", "default": "Maine" }, - "MH": { "type": "string", "default": "Marshall Islands" }, - "MD": { "type": "string", "default": "Maryland" }, - "MA": { "type": "string", "default": "Massachusetts" }, - "MI": { "type": "string", "default": "Michigan" }, - "MN": { "type": "string", "default": "Minnesota" }, - "MS": { "type": "string", "default": "Mississippi" }, - "MO": { "type": "string", "default": "Missouri" }, - "MT": { "type": "string", "default": "Montana" }, - "NE": { "type": "string", "default": "Nebraska" }, - "NV": { "type": "string", "default": "Nevada" }, - "NH": { "type": "string", "default": "New Hampshire" }, - "NJ": { "type": "string", "default": "New Jersey" }, - "NM": { "type": "string", "default": "New Mexico" }, - "NY": { "type": "string", "default": "New York" }, - "NC": { "type": "string", "default": "North Carolina" }, - "ND": { "type": "string", "default": "North Dakota" }, - "MP": { "type": "string", "default": "Northern Mariana Islands" }, - "OH": { "type": "string", "default": "Ohio" }, - "OK": { "type": "string", "default": "Oklahoma" }, - "OR": { "type": "string", "default": "Oregon" }, - "PA": { "type": "string", "default": "Pennsylvania" }, - "PR": { "type": "string", "default": "Puerto Rico" }, - "RI": { "type": "string", "default": "Rhode Island" }, - "SC": { "type": "string", "default": "South Carolina" }, - "SD": { "type": "string", "default": "South Dakota" }, - "TN": { "type": "string", "default": "Tennessee" }, - "TX": { "type": "string", "default": "Texas" }, - "UT": { "type": "string", "default": "Utah" }, - "VT": { "type": "string", "default": "Vermont" }, - "VI": { "type": "string", "default": "Virgin Islands" }, - "VA": { "type": "string", "default": "Virginia" }, - "WA": { "type": "string", "default": "Washington" }, - "WV": { "type": "string", "default": "West Virginia" }, - "WI": { "type": "string", "default": "Wisconsin" }, - "WY": { "type": "string", "default": "Wyoming" } - }, - "required": [ - "AL", - "AK", - "AS", - "AZ", - "AR", - "AF", - "AA", - "AC", - "AE", - "AM", - "AP", - "CA", - "CO", - "CT", - "DE", - "DC", - "FM", - "FL", - "GA", - "GU", - "HI", - "ID", - "IL", - "IN", - "IA", - "KS", - "KY", - "LA", - "ME", - "MH", - "MD", - "MA", - "MI", - "MN", - "MS", - "MO", - "MT", - "NE", - "NV", - "NH", - "NJ", - "NM", - "NY", - "NC", - "ND", - "MP", - "OH", - "OK", - "OR", - "PA", - "PR", - "RI", - "SC", - "SD", - "TN", - "TX", - "UT", - "VT", - "VI", - "VA", - "WA", - "WV", - "WI", - "WY" - ] -} diff --git a/src/static/schemas/report-form.json b/src/static/schemas/report-form.json deleted file mode 100644 index 569dce3f3..000000000 --- a/src/static/schemas/report-form.json +++ /dev/null @@ -1,94 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "cancel": { "type": "string", "default": "Cancel" }, - "create": { "type": "string", "default": "Create" }, - "date": { "type": "string", "default": "{{value, date}}" }, - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "datetime_end_required": { "type": "string", "default": "End date is required" }, - "datetime_start_required": { "type": "string", "default": "Start date is required" }, - "delete": { "type": "string", "default": "Delete" }, - "delete_prompt": { - "type": "string", - "default": "If you proceed, this report will be deleted forever. Are you sure?" - }, - "end": { "type": "string", "default": "End" }, - "name": { "type": "string", "default": "Name" }, - "name_complete": { "type": "string", "default": "Complete" }, - "name_complete_explainer": { - "type": "string", - "default": "Transactions, coupon usage, subscription forecasts etc." - }, - "name_customers": { "type": "string", "default": "Customers" }, - "name_customers_explainer": { - "type": "string", - "default": "Exports customers to import somewhere else." - }, - "name_customers_ltv": { "type": "string", "default": "Lifetime value" }, - "name_customers_ltv_explainer": { - "type": "string", - "default": "Customers with lifetime value info." - }, - "preset": { "type": "string", "default": "Preset" }, - "preset_custom": { "type": "string", "default": "Custom" }, - "preset_last_30_days": { "type": "string", "default": "Last 30 days" }, - "preset_last_365_days": { "type": "string", "default": "Last 365 days" }, - "preset_previous_month": { "type": "string", "default": "Previous month" }, - "preset_previous_quarter": { "type": "string", "default": "Previous quarter" }, - "preset_previous_year": { "type": "string", "default": "Previous year" }, - "preset_this_month": { "type": "string", "default": "This month" }, - "preset_this_quarter": { "type": "string", "default": "This quarter" }, - "preset_this_year": { "type": "string", "default": "This year" }, - "range": { "type": "string", "default": "Range" }, - "select_date": { "type": "string", "default": "DD/MM/YYYY" }, - "select_time": { "type": "string", "default": "HH:MM:SS" }, - "start": { "type": "string", "default": "Start" }, - "use_precise_time": { "type": "string", "default": "Use precise time" }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "cancel", - "create", - "date", - "date_created", - "date_modified", - "datetime_end_required", - "datetime_start_required", - "delete", - "delete_prompt", - "end", - "name", - "name_complete", - "name_complete_explainer", - "name_customers", - "name_customers_explainer", - "name_customers_ltv", - "name_customers_ltv_explainer", - "preset", - "preset_custom", - "preset_last_30_days", - "preset_last_365_days", - "preset_previous_month", - "preset_previous_quarter", - "preset_previous_year", - "preset_this_month", - "preset_this_quarter", - "preset_this_year", - "range", - "select_date", - "select_time", - "start", - "use_precise_time", - "spinner" - ] -} diff --git a/src/static/schemas/reports-table.json b/src/static/schemas/reports-table.json deleted file mode 100644 index 4822e17fa..000000000 --- a/src/static/schemas/reports-table.json +++ /dev/null @@ -1,48 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "created_on": { "type": "string", "default": "Created on" }, - "date": { "type": "string", "default": "{{value, date}}" }, - "download": { "type": "string", "default": "Download" }, - "link": { "type": "string", "default": "Link" }, - "range_end": { "type": "string", "default": "End" }, - "range_start": { "type": "string", "default": "Start" }, - "report_name": { "type": "string", "default": "Name" }, - "report_name_complete": { "type": "string", "default": "Complete" }, - "report_name_customers": { "type": "string", "default": "Customers" }, - "report_name_customers_ltv": { "type": "string", "default": "Lifetime value" }, - "link-spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Preparing" }, - "loading_error": { "type": "string", "default": "Failed to create" } - }, - "required": ["loading_busy", "loading_error"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "created_on", - "date", - "download", - "link", - "range_end", - "range_start", - "report_name", - "report_name_complete", - "report_name_customers", - "report_name_customers_ltv", - "link-spinner", - "spinner" - ] -} diff --git a/src/static/schemas/shared.json b/src/static/schemas/shared.json deleted file mode 100644 index 0c832f552..000000000 --- a/src/static/schemas/shared.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "demo_key": { "type": "string", "default": "Hello" }, - "demo_date": { "type": "string", "default": "This is a date: {{ value, date }}" } - }, - "required": ["demo_key", "demo_date"] -} diff --git a/src/static/schemas/shipment-card.json b/src/static/schemas/shipment-card.json deleted file mode 100644 index 39a0c8e29..000000000 --- a/src/static/schemas/shipment-card.json +++ /dev/null @@ -1,25 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "full_address": { - "type": "string", - "default": "{{ address1 }} {{ address2 }} {{ city }} {{ region }} {{ postal_code }}" - }, - "quantity": { "type": "string", "default": "Qty: {{ count }}" }, - "no_code": { "type": "string", "default": "No SKU" }, - "price": { "type": "string", "default": "{{ amount, price }}" }, - "item": { "type": "string", "default": "{{ count }} item" }, - "item_plural": { "type": "string", "default": "{{ count }} items" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No shipments" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["full_address", "quantity", "no_code", "price", "item", "item_plural", "spinner"] -} diff --git a/src/static/schemas/shipping-method-card.json b/src/static/schemas/shipping-method-card.json deleted file mode 100644 index 975e76465..000000000 --- a/src/static/schemas/shipping-method-card.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "image_alt": { "type": "string", "default": "Shipping method logo" }, - "status_active": { "type": "string", "default": "Active" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["image_alt", "status_active", "spinner"] -} diff --git a/src/static/schemas/sign-in-form.json b/src/static/schemas/sign-in-form.json deleted file mode 100644 index e6d34550a..000000000 --- a/src/static/schemas/sign-in-form.json +++ /dev/null @@ -1,69 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "email": { "type": "string", "default": "Email" }, - "invalid_credential_error": { - "type": "string", - "default": "Incorrect email or password. Please check your credentials and try again." - }, - "mfa_remember_device": { "type": "string", "default": "Trust this device" }, - "mfa_remember_device_hint": { - "type": "string", - "default": "Don't require a verification code when signing in from this device in the future" - }, - "mfa_totp_code": { "type": "string", "default": "One-time code" }, - "mfa_totp_code_hint": { - "type": "string", - "default": "Scan the image below with your authenticator app to receive the verification code" - }, - "mfa_totp_code_invalid_error": { - "type": "string", - "default": "The one-time code you entered is invalid. Please try again." - }, - "new_password": { "type": "string", "default": "New password" }, - "new_password_format_error": { - "type": "string", - "default": "The new password you've chosen is too weak. Please enter a secure new password." - }, - "new_password_required_error": { - "type": "string", - "default": "To keep your account secure, please change your password before logging in this time." - }, - "password": { "type": "string", "default": "Password" }, - "sign_in": { "type": "string", "default": "Sign in" }, - "unknown_error": { - "type": "string", - "default": "An unknown error has occured. Please try again later." - }, - "v8n_invalid_email": { "type": "string", "default": "Invalid email" }, - "v8n_required": { "type": "string", "default": "Required" }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "email", - "invalid_credential_error", - "mfa_remember_device", - "mfa_remember_device_hint", - "mfa_totp_code", - "mfa_totp_code_hint", - "mfa_totp_code_invalid_error", - "new_password", - "new_password_format_error", - "new_password_required_error", - "password", - "sign_in", - "unknown_error", - "v8n_invalid_email", - "v8n_required", - "spinner" - ] -} diff --git a/src/static/schemas/spinner.json b/src/static/schemas/spinner.json deleted file mode 100644 index fad351bd5..000000000 --- a/src/static/schemas/spinner.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_end": { "type": "string", "default": "No more data" }, - "loading_error": { "type": "string", "default": "Unknown error" }, - "loading_paused": { "type": "string", "default": "Paused" } - }, - "required": ["loading_busy", "loading_empty", "loading_end", "loading_error", "loading_paused"] -} diff --git a/src/static/schemas/store-card.json b/src/static/schemas/store-card.json deleted file mode 100644 index 5f175ab78..000000000 --- a/src/static/schemas/store-card.json +++ /dev/null @@ -1,16 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["spinner"] -} diff --git a/src/static/schemas/store-form.json b/src/static/schemas/store-form.json deleted file mode 100644 index ca61d4435..000000000 --- a/src/static/schemas/store-form.json +++ /dev/null @@ -1,793 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "maintenance_mode_on_explainer": { - "type": "string", - "default": "Maintenance mode is on. Your customers can't make purchases or use the checkout page in any way. Once you're done making changes, disable this mode to continue getting orders." - }, - "maintenance_mode_off_explainer": { - "type": "string", - "default": "If you're about to make changes that may disrupt the checkout process, we recommend enabling the maintenance mode first. In this mode the checkout page will be completely non-functioning and the customers will see a message asking them to come back later." - }, - "enable_maintenance_mode": { "type": "string", "default": "Enable maintenance mode" }, - "disable_maintenance_mode": { "type": "string", "default": "Disable maintenance mode" }, - "store-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Name" }, - "placeholder": { "type": "string", "default": "My Store" }, - "helper_text": { - "type": "string", - "default": "The name of your store as you'd like it displayed to your customers and our system." - }, - "v8n_required": { "type": "string", "default": "Please enter the name of your store" }, - "v8n_too_long": { - "type": "string", - "default": "Please reduce the name of your store to 50 characters or less" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_too_long"] - }, - "store-email": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Emails" }, - "placeholder": { "type": "string", "default": "Enter an email and press Enter" }, - "helper_text": { - "type": "string", - "default": "Email addresses used for billing and communication with Foxy." - }, - "submit": { "type": "string", "default": "Submit" }, - "delete": { "type": "string", "default": "Delete" }, - "v8n_required": { "type": "string", "default": "Please enter at least one email" }, - "v8n_too_long": { - "type": "string", - "default": "All emails for this store must fit within 300 characters when comma-separated" - } - }, - "required": [ - "label", - "placeholder", - "helper_text", - "submit", - "delete", - "v8n_required", - "v8n_too_long" - ] - }, - "store-url": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Website" }, - "placeholder": { "type": "string", "default": "https://my.store.example.com" }, - "helper_text": { "type": "string", "default": "The URL of your online store." }, - "v8n_required": { - "type": "string", - "default": "Please enter the URL of your online store" - }, - "v8n_too_long": { - "type": "string", - "default": "Please use a URL that is 300 characters or less" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_too_long"] - }, - "store-domain": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Domain" }, - "placeholder": { "type": "string", "default": "my-store.foxycart.com" }, - "helper_text": { - "type": "string", - "default": "Unique Foxy subdomain or a custom domain for your cart, checkout, and receipt." - }, - "custom_domain_note": { - "type": "string", - "default": "IMPORTANT: to use a custom domain, you must purchase an SSL certificate through Foxy. This option is only for developers who have full control of their domain settings and may take a few days to fully process." - }, - "v8n_required": { "type": "string", "default": "Please enter the domain of your store" }, - "v8n_too_long": { - "type": "string", - "default": "Please use a domain that is 100 characters or less" - } - }, - "required": [ - "label", - "placeholder", - "helper_text", - "custom_domain_note", - "v8n_required", - "v8n_too_long" - ] - }, - "logo-url": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Logo" }, - "placeholder": { "type": "string", "default": "https://example.com/logo.png" }, - "helper_text": { - "type": "string", - "default": "URL to your store's logo that may be used in your store's templates." - }, - "v8n_too_long": { - "type": "string", - "default": "Please shorten this link to 200 characters of less" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "timezone": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Timezone" }, - "placeholder": { "type": "string", "default": "(GMT-08:00) Pacific Time (US and Canada)" }, - "helper_text": { - "type": "string", - "default": "The timezone of your store. This will impact how dates are shown to customers and within the admin." - } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "from-email": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "FROM email" }, - "placeholder": { "type": "string", "default": "Defaults to the first store email" }, - "helper_text": { - "type": "string", - "default": "If you'd like us to send messages from an address other than the first one of your store emails, list it here." - }, - "v8n_too_long": { - "type": "string", - "default": "Please use an email that is 100 characters or less" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "bcc-on-receipt-email": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" }, - "option_checked": { - "type": "string", - "default": "Send a copy of each receipt to the store email" - } - }, - "required": ["label", "helper_text", "option_checked"] - }, - "use-email-dns": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" }, - "option_checked": { "type": "string", "default": "Improve email deliverability with DNS" } - }, - "required": ["label", "helper_text", "option_checked"] - }, - "use_email_dns_helper_text": { - "type": "string", - "default": "Before saving your changes, make sure the DNS records for your domain list our servers. To learn more, see our Wiki:" - }, - "use-smtp-config": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" }, - "option_checked": { "type": "string", "default": "Use custom mail server" }, - "v8n_too_long": { - "type": "string", - "default": "This configuration must fit within 1000 characters when JSON-encoded" - } - }, - "required": ["label", "helper_text", "option_checked", "v8n_too_long"] - }, - "smtp-config-host": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Host" }, - "helper_text": { "type": "string", "default": "" }, - "placeholder": { "type": "string", "default": "smtp.example.com" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "smtp-config-port": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Port" }, - "helper_text": { "type": "string", "default": "" }, - "placeholder": { "type": "string", "default": "465" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "smtp-config-username": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Username" }, - "helper_text": { "type": "string", "default": "" }, - "placeholder": { "type": "string", "default": "sender@example.com" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "smtp-config-password": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Password" }, - "helper_text": { "type": "string", "default": "" }, - "placeholder": { "type": "string", "default": "Required" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "smtp-config-security": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" }, - "option_ssl": { "type": "string", "default": "Use SSL" }, - "option_tls": { "type": "string", "default": "Use TLS" }, - "option_none": { "type": "string", "default": "Don't encrypt" } - }, - "required": ["label", "helper_text", "option_ssl", "option_tls", "option_none"] - }, - "country": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Country" }, - "placeholder": { "type": "string", "default": "Select country..." }, - "helper_text": { - "type": "string", - "default": "The country your store is located in. We'll use this information to calculate shipping costs if you sell shippable items." - }, - "v8n_required": { "type": "string", "default": "Please select the country of your store" } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "region": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Region" }, - "placeholder": { "type": "string", "default": "Select region..." }, - "helper_text": { - "type": "string", - "default": "The region, province or state your store is located in. We'll use this information to calculate shipping costs if you sell shippable items." - }, - "v8n_required": { "type": "string", "default": "Please select the region of your store" }, - "v8n_too_long": { - "type": "string", - "default": "Please shorten the region name to 50 characters of less" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_too_long"] - }, - "postal-code": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Postal code" }, - "placeholder": { "type": "string", "default": "012345" }, - "helper_text": { - "type": "string", - "default": "The postal code (or zip code) of the area your store is located in. We'll use this information to calculate shipping costs if you sell shippable items." - }, - "v8n_required": { - "type": "string", - "default": "Please enter the postal code of your store" - }, - "v8n_too_long": { "type": "string", "default": "Postal code can't exceed 50 characters" } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_too_long"] - }, - "shipping-address-type": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Rate calculation" }, - "placeholder": { "type": "string", "default": "Rate based on Company field" }, - "helper_text": { - "type": "string", - "default": "Used for determining the type of the customer address used when calculating shipping costs." - } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "require-signed-shipping-rates": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" }, - "option_checked": { "type": "string", "default": "Prevent shipping rate tampering" } - }, - "required": ["label", "helper_text", "option_checked"] - }, - "require_signed_shipping_rates_helper_text": { - "type": "string", - "default": "Enabling shipping rate signing for your store ensures that the rate the customer selects is carried through and not altered in any way. If you're intending to make use of javascript snippets on your store to alter the price or label of shipping rates or add custom rates dynamically, disable this setting as it will block those rates from being applied." - }, - "features-multiship": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" }, - "option_checked": { "type": "string", "default": "Allow multiple destinations per order" } - }, - "required": ["label", "helper_text", "option_checked"] - }, - "language": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Language" }, - "placeholder": { "type": "string", "default": "English" }, - "helper_text": { - "type": "string", - "default": "The default language for your store's cart, checkout, and receipt strings." - } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "locale-code": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Locale code" }, - "placeholder": { "type": "string", "default": "en_US" }, - "helper_text": { - "type": "string", - "default": "The locale code for your store's locale. This will be used to format strings for your store." - } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "currency_style_label": { "type": "string", "default": "Currency display" }, - "currency_style_helper_text": { - "type": "string", - "default": "Choose how you'd like all prices and totals to appear across your store's cart, checkout, receipt and admin." - }, - "receipt-continue-url": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Return URL" }, - "placeholder": { "type": "string", "default": "https://example.com/thank-you" }, - "helper_text": { - "type": "string", - "default": "By default, the continue button on the receipt sends the customer to the store domain after completing a purchase. Instead, you can set a specific URL here." - }, - "v8n_too_long": { - "type": "string", - "default": "Please use a URL that is 300 characters or less" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "app-session-time": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Clear cart after" }, - "helper_text": { - "type": "string", - "default": "If your store sells products which collect personal or sensitive information as product attributes, you may want to consider lowering your cart session lifespan." - }, - "second": { "type": "string", "default": "Second" }, - "second_plural": { "type": "string", "default": "Seconds" }, - "minute": { "type": "string", "default": "Minute" }, - "minute_plural": { "type": "string", "default": "Minutes" }, - "hour": { "type": "string", "default": "Hour" }, - "hour_plural": { "type": "string", "default": "Hours" }, - "day": { "type": "string", "default": "Day" }, - "day_plural": { "type": "string", "default": "Days" } - }, - "required": [ - "label", - "helper_text", - "second", - "second_plural", - "minute", - "minute_plural", - "hour", - "hour_plural", - "day", - "day_plural" - ] - }, - "products-require-expires-property": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" }, - "option_checked": { "type": "string", "default": "My products have limited availability" } - }, - "required": ["label", "helper_text", "option_checked"] - }, - "products_require_expires_property_helper_text": { - "type": "string", - "default": "All products added to the cart for your store will need to contain the expires property to ensure stale products can't be purchased." - }, - "use-cart-validation": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" }, - "option_checked": { "type": "string", "default": "Prevent product link and form tampering" } - }, - "required": ["label", "helper_text", "option_checked"] - }, - "use_cart_validation_helper_text": { - "type": "string", - "default": "Enabling this option will require all cart links and forms to pass HMAC-based verification before products can be added to the cart. You will need to sign your HTML to use this feature. See our docs for more info:" - }, - "custom-display-id-config-enabled": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" }, - "option_checked": { "type": "string", "default": "Customize Transaction ID" }, - "v8n_too_long": { - "type": "string", - "default": "This configuration must fit within 100 characters when JSON-encoded" - } - }, - "required": ["label", "helper_text", "option_checked", "v8n_too_long"] - }, - "custom-display-id-config-transaction-journal-entries-enabled": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" }, - "option_checked": { "type": "string", "default": "Customize Transaction Journal entry ID" } - }, - "required": ["label", "helper_text", "option_checked"] - }, - "custom-display-id-config-length": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Length" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "custom-display-id-config-start": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Start" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "custom-display-id-config-prefix": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Prefix" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "custom-display-id-config-suffix": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Suffix" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "custom-display-id-config-first-example": { "type": "string", "default": "First:" }, - "custom-display-id-config-random-example": { "type": "string", "default": "Random:" }, - "custom-display-id-config-transaction-journal-entries-transaction-separator": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Separator" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "custom-display-id-config-transaction-journal-entries-log-detail-request-types-transaction-authcapture-prefix": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Authorization prefix" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "custom-display-id-config-transaction-journal-entries-log-detail-request-types-transaction-capture-prefix": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Capture prefix" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "custom-display-id-config-transaction-journal-entries-log-detail-request-types-transaction-void-prefix": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Void prefix" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "custom-display-id-config-transaction-journal-entries-log-detail-request-types-transaction-refund-prefix": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Refund prefix" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "custom-display-id-config-transaction-journal-entries-authcapture-example": { - "type": "string", - "default": "When authorized:" - }, - "custom-display-id-config-transaction-journal-entries-capture-example": { - "type": "string", - "default": "When captured:" - }, - "custom-display-id-config-transaction-journal-entries-void-example": { - "type": "string", - "default": "When voided:" - }, - "custom-display-id-config-transaction-journal-entries-refund-example": { - "type": "string", - "default": "When refunded:" - }, - "webhook-url": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "XML webhook endpoint" }, - "placeholder": { "type": "string", "default": "https://example.com/xml-webhook" }, - "helper_text": { - "type": "string", - "default": "Foxy will encrypt order info and POST it to this URL on each purchase as XML. When using this webhook, make sure to configure the encryption key for your store." - }, - "v8n_required": { "type": "string", "default": "Please enter the XML webhook endpoint" }, - "v8n_too_long": { - "type": "string", - "default": "Please shorten this URL to 300 characters or less" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_too_long"] - }, - "webhook-key-cart-signing": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "HMAC encryption key" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { - "type": "string", - "default": "We'll use this key to encrypt webhook payloads as well as to sign cart links and product forms." - } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "webhook-key-xml-datafeed": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "XML webhook encryption key" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { - "type": "string", - "default": "We'll use this key to encrypt legacy XML webhook payloads." - } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "webhook-key-api-legacy": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Legacy API key" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { - "type": "string", - "default": "API key you can use to access the legacy API." - } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "webhook-key-sso": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "SSO secret" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { - "type": "string", - "default": "We'll use this value to validate session tokens generated by your SSO setup." - } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "single-sign-on-url": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "SSO endpoint" }, - "placeholder": { "type": "string", "default": "https://example.com/sso" }, - "helper_text": { - "type": "string", - "default": "When configured, Foxy will redirect customers to this URL prior to hitting the checkout page. You can use this to validate items or to log customers in via your own auth provider." - }, - "v8n_required": { "type": "string", "default": "Please enter your SSO endpoint URL" }, - "v8n_too_long": { - "type": "string", - "default": "Please shorten this URL to 300 characters or less" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_too_long"] - }, - "unified-order-entry-password": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Unified order entry password" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { - "type": "string", - "default": "Set a master password here if you would like to be able to check out as your customers without having to know their password." - }, - "v8n_required": { - "type": "string", - "default": "Please reduce your UOE password to 100 characters" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "store-version-uri": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Version" }, - "placeholder": { "type": "string", "default": "Defaults to latest" }, - "helper_text": { - "type": "string", - "default": "Store version including templates, libraries, payment options and more. It's recommended to upgrade your integration to the newest version as soon as it becomes available." - } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "checkout-type": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "New accounts" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { - "type": "string", - "default": "The preferred configuration of your customer checkout experience, such as defaulting to guest checkout or requiring account creation with each checkout." - } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "customer-password-hash-type": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Password hashing method (advanced)" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { - "type": "string", - "default": "When saving a customer to Foxy, this is the password hashing method that will be used." - } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "customer-password-hash-config": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Password hashing configuration (advanced)" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { - "type": "string", - "default": "Configuration settings for the selected hashing method." - }, - "v8n_too_long": { - "type": "string", - "default": "Please reduce your configuration settings to 100 characters or less" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "date": { "type": "string", "default": "{{value, date}}" } - }, - "required": ["date_created", "date_modified", "date"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove this store? You won't be able to bring it back." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - } - }, - "required": [ - "maintenance_mode_on_explainer", - "maintenance_mode_off_explainer", - "enable_maintenance_mode", - "disable_maintenance_mode", - "store-name", - "store-email", - "store-url", - "store-domain", - "logo-url", - "timezone", - "from-email", - "bcc-on-receipt-email", - "use-email-dns", - "use_email_dns_helper_text", - "use-smtp-config", - "smtp-config-host", - "smtp-config-port", - "smtp-config-username", - "smtp-config-password", - "smtp-config-security", - "country", - "region", - "postal-code", - "shipping-address-type", - "require-signed-shipping-rates", - "require_signed_shipping_rates_helper_text", - "features-multiship", - "language", - "locale-code", - "currency_style_label", - "currency_style_helper_text", - "receipt-continue-url", - "app-session-time", - "products-require-expires-property", - "products_require_expires_property_helper_text", - "use-cart-validation", - "use_cart_validation_helper_text", - "custom-display-id-config-enabled", - "custom-display-id-config-transaction-journal-entries-enabled", - "custom-display-id-config-length", - "custom-display-id-config-start", - "custom-display-id-config-prefix", - "custom-display-id-config-suffix", - "custom-display-id-config-first-example", - "custom-display-id-config-random-example", - "custom-display-id-config-transaction-journal-entries-transaction-separator", - "custom-display-id-config-transaction-journal-entries-log-detail-request-types-transaction-authcapture-prefix", - "custom-display-id-config-transaction-journal-entries-log-detail-request-types-transaction-capture-prefix", - "custom-display-id-config-transaction-journal-entries-log-detail-request-types-transaction-void-prefix", - "custom-display-id-config-transaction-journal-entries-log-detail-request-types-transaction-refund-prefix", - "custom-display-id-config-transaction-journal-entries-authcapture-example", - "custom-display-id-config-transaction-journal-entries-capture-example", - "custom-display-id-config-transaction-journal-entries-void-example", - "custom-display-id-config-transaction-journal-entries-refund-example", - "webhook-url", - "webhook-key-cart-signing", - "webhook-key-xml-datafeed", - "webhook-key-api-legacy", - "webhook-key-sso", - "single-sign-on-url", - "unified-order-entry-password", - "store-version-uri", - "checkout-type", - "customer-password-hash-type", - "customer-password-hash-config", - "timestamps", - "spinner", - "delete", - "create" - ] -} diff --git a/src/static/schemas/store-shipping-method-form.json b/src/static/schemas/store-shipping-method-form.json deleted file mode 100644 index 7e919eb6c..000000000 --- a/src/static/schemas/store-shipping-method-form.json +++ /dev/null @@ -1,210 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "shipping-method-uri": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Shipping Method" }, - "placeholder": { "type": "string", "default": "Select service" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_required": { "type": "string", "default": "Please select a shipping method." } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "shipping-container-uri": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Container" }, - "placeholder": { "type": "string", "default": "Select container" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_required": { "type": "string", "default": "Please select a shipping method." } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "shipping-drop-type-uri": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Drop Type" }, - "placeholder": { "type": "string", "default": "Select pickup" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_required": { "type": "string", "default": "Please select a drop type." } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "destinations": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Destinations" }, - "domestic": { "type": "string", "default": "Domestic" }, - "international": { "type": "string", "default": "International" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "domestic", "international", "helper_text"] - }, - "authentication-key": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Authentication Key" }, - "placeholder": { "type": "string", "default": "N/A" }, - "helper_text": { - "type": "string", - "default": "If using account specific rates, enter your shipping account authentication key here, if applicable." - }, - "v8n_too_long": { - "type": "string", - "default": "Authentication key must be 50 characters or less." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "meter-number": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Meter Number" }, - "placeholder": { "type": "string", "default": "N/A" }, - "helper_text": { - "type": "string", - "default": "If using account specific rates, enter your shipping account meter number here, if applicable." - }, - "v8n_too_long": { - "type": "string", - "default": "Meter number must be 50 characters or less." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "accountid": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Account ID" }, - "placeholder": { "type": "string", "default": "N/A" }, - "helper_text": { - "type": "string", - "default": "If using account specific rates, enter your shipping account id here." - }, - "v8n_too_long": { "type": "string", "default": "Account ID must be 50 characters or less." } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "endpoint": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Endpoint URL" }, - "placeholder": { "type": "string", "default": "https://example.com/rates" }, - "helper_text": { - "type": "string", - "default": "Enter a URL that we'll poll for shipping rates." - }, - "v8n_required": { "type": "string", "default": "Please enter a valid endpoint URL." } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "password": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Password" }, - "placeholder": { "type": "string", "default": "N/A" }, - "helper_text": { - "type": "string", - "default": "If using account specific rates, enter your shipping account password here." - }, - "v8n_too_long": { "type": "string", "default": "Password must be 50 characters or less." } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "custom-code": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Custom Code" }, - "placeholder": { "type": "string", "default": "Paste your code here" }, - "helper_text": { - "type": "string", - "default": "JavaScript used to create and modify shipping rates." - }, - "v8n_too_long": { - "type": "string", - "default": "Please reduce the size of your custom code to 64KB or less." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "services": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Additional services" }, - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { "type": "string", "default": "{{from}}-{{to}} out of {{total}}" }, - "previous": { "type": "string", "default": "Previous" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" }, - "international_only": { "type": "string", "default": "– international only" } - }, - "required": [ - "label", - "first", - "last", - "next", - "pagination", - "previous", - "loading_busy", - "loading_error", - "international_only" - ] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "date": { "type": "string", "default": "{{value, date}}" } - }, - "required": ["date_created", "date_modified", "date"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove this shipping method? You won't be able to undo if you click Delete." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "shipping-method-uri", - "shipping-container-uri", - "shipping-drop-type-uri", - "destinations", - "authentication-key", - "meter-number", - "accountid", - "endpoint", - "password", - "custom-code", - "services", - "timestamps", - "delete", - "create", - "spinner" - ] -} diff --git a/src/static/schemas/subscription-card.json b/src/static/schemas/subscription-card.json deleted file mode 100644 index ca1473ad4..000000000 --- a/src/static/schemas/subscription-card.json +++ /dev/null @@ -1,74 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "daily": { "type": "string", "default": "Daily" }, - "daily_plural": { "type": "string", "default": "Every {{count}} days" }, - "frequency": { - "type": "string", - "default": "$t({{units}}, { \"count\": {{count}}, \"ns\": \"subscription-card\" })" - }, - "monthly": { "type": "string", "default": "Monthly" }, - "monthly_plural": { "type": "string", "default": "Every {{count}} months" }, - "price_recurring": { - "type": "string", - "default": "{{amount, price}} $t(frequency, { \"count\": \"{{count}}\", \"units\": \"{{units}}\", \"ns\": \"subscription-card\" })" - }, - "price_twice_a_month": { - "type": "string", - "default": "{{amount, price}} $t(twice_a_month, { \"ns\": \"subscription-card\" })" - }, - "subscription_active": { "type": "string", "default": "Next payment on {{date, date}}" }, - "subscription_cancelled": { "type": "string", "default": "Ended on {{date, date}}" }, - "subscription_failed": { "type": "string", "default": "Payment failed on {{date, date}}" }, - "subscription_inactive": { "type": "string", "default": "Inactive" }, - "subscription_plural": { "type": "string", "default": "Subscriptions" }, - "subscription_will_be_cancelled": { "type": "string", "default": "Ends on {{date, date}}" }, - "subscription_will_be_active": { "type": "string", "default": "Starts on {{date, date}}" }, - "transaction_summary": { "type": "string", "default": "{{most_expensive_item.name}}" }, - "fees_hint": { "type": "string", "default": "inc. shipping, taxes, etc." }, - "fees_explainer": { - "type": "string", - "default": "Taxes, shipping, and discounts may change the amount charged." - }, - "twice_a_month": { "type": "string", "default": "Twice a month" }, - "weekly": { "type": "string", "default": "Weekly" }, - "weekly_plural": { "type": "string", "default": "Every {{count}} weeks" }, - "yearly": { "type": "string", "default": "Yearly" }, - "yearly_plural": { "type": "string", "default": "Every {{count}} years" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "daily", - "daily_plural", - "frequency", - "monthly", - "monthly_plural", - "price_recurring", - "price_twice_a_month", - "subscription_active", - "subscription_cancelled", - "subscription_failed", - "subscription_inactive", - "subscription_plural", - "subscription_will_be_cancelled", - "subscription_will_be_active", - "transaction_summary", - "fees_hint", - "fees_explainer", - "twice_a_month", - "weekly", - "weekly_plural", - "yearly", - "yearly_plural", - "spinner" - ] -} diff --git a/src/static/schemas/subscription-form.json b/src/static/schemas/subscription-form.json deleted file mode 100644 index d6176aa72..000000000 --- a/src/static/schemas/subscription-form.json +++ /dev/null @@ -1,478 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "day": { "type": "string", "default": "Day" }, - "day_plural": { "type": "string", "default": "Days" }, - "week": { "type": "string", "default": "Week" }, - "week_plural": { "type": "string", "default": "Weeks" }, - "month": { "type": "string", "default": "Month" }, - "month_plural": { "type": "string", "default": "Months" }, - "year": { "type": "string", "default": "Year" }, - "year_plural": { "type": "string", "default": "Years" }, - "cancel": { "type": "string", "default": "Cancel" }, - "close": { "type": "string", "default": "Close" }, - "confirm": { "type": "string", "default": "Confirm" }, - "currency": { "type": "string", "default": "Currency" }, - "daily": { "type": "string", "default": "Daily" }, - "daily_plural": { "type": "string", "default": "Every {{count}} days" }, - "end_date": { "type": "string", "default": "End date" }, - "frequency": { - "type": "string", - "default": "$t({{units}}, { \"count\": {{count}}, \"ns\": \"subscription-form\" })" - }, - "frequency_label": { "type": "string", "default": "Frequency" }, - "item_plural": { "type": "string", "default": "Items" }, - "monthly": { "type": "string", "default": "Monthly" }, - "monthly_plural": { "type": "string", "default": "Every {{count}} months" }, - "next_transaction_date": { "type": "string", "default": "Next transaction date" }, - "start_date": { "type": "string", "default": "Start date" }, - "price_recurring": { - "type": "string", - "default": "{{amount, price}} $t(frequency, { \"count\": \"{{count}}\", \"units\": \"{{units}}\", \"ns\": \"subscription-form\" })" - }, - "price_twice_a_month": { - "type": "string", - "default": "{{amount, price}} $t(twice_a_month, { \"ns\": \"subscription-form\" })" - }, - "subscription_active": { - "type": "string", - "default": "Including shipping, taxes, etc. Next payment on {{date, date}}." - }, - "subscription_cancelled": { - "type": "string", - "default": "Including shipping, taxes, etc. Ended on {{date, date}}." - }, - "subscription_failed": { - "type": "string", - "default": "Including shipping, taxes, etc. Payment failed on {{date, date}}." - }, - "subscription_inactive": { - "type": "string", - "default": "Including shipping, taxes, etc. Inactive." - }, - "subscription_will_be_cancelled": { - "type": "string", - "default": "Including shipping, taxes, etc. Ends on {{date, date}}." - }, - "subscription_will_be_active": { - "type": "string", - "default": "Including shipping, taxes, etc. Starts on {{date, date}}." - }, - "transaction_plural": { "type": "string", "default": "Transactions" }, - "twice_a_month": { "type": "string", "default": "Twice a month" }, - "undo_cancel": { "type": "string", "default": "Review" }, - "undo_confirm": { "type": "string", "default": "Discard" }, - "undo_header": { "type": "string", "default": "Unsaved changes" }, - "undo_message": { - "type": "string", - "default": "Looks like you didn't save your changes! What would you like to do with them?" - }, - "weekly": { "type": "string", "default": "Weekly" }, - "weekly_plural": { "type": "string", "default": "Every {{count}} weeks" }, - "yearly": { "type": "string", "default": "Yearly" }, - "yearly_plural": { "type": "string", "default": "Every {{count}} years" }, - "customer": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Customer" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_error"] - } - }, - "required": ["label", "spinner"] - }, - "past-due-amount": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Past due amount" }, - "placeholder": { "type": "string", "default": "" }, - "helper_text": { - "type": "string", - "default": "If a subscription payment is missed, this amount will be increased by that payment. The next time the subscription runs, it may be charged automatically depending on your store's subscription settings." - } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "attributes": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Attributes" }, - "delete_confirm": { "type": "string", "default": "Delete" }, - "delete_cancel": { "type": "string", "default": "Cancel" }, - "delete_message": { - "type": "string", - "default": "Are you sure you'd like to remove this attribute? You won't be able to bring it back." - }, - "delete_header": { "type": "string", "default": "Delete attribute?" }, - "pagination": { - "additionalProperties": false, - "properties": { - "create_button_text": { "type": "string", "default": "Add attribute +" }, - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { "type": "string", "default": "{{from}}-{{to}} out of {{total}}" }, - "previous": { "type": "string", "default": "Previous" }, - "card": { - "additionalProperties": false, - "properties": { - "delete_button_text": { "type": "string", "default": "Remove" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No attributes" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["delete_button_text", "spinner"] - } - }, - "required": [ - "create_button_text", - "first", - "last", - "next", - "pagination", - "previous", - "card" - ] - }, - "dialog": { - "additionalProperties": false, - "properties": { - "close": { "type": "string", "default": "Close" }, - "header_update": { "type": "string", "default": "Attribute" }, - "header_create": { "type": "string", "default": "New attribute" }, - "save": { "type": "string", "default": "Save" }, - "undo_header": { "type": "string", "default": "Unsaved changes" }, - "undo_message": { - "type": "string", - "default": "Looks like you didn't save your changes! What would you like to do with them?" - }, - "undo_cancel": { "type": "string", "default": "Review" }, - "undo_confirm": { "type": "string", "default": "Discard" }, - "cancel": { "type": "string", "default": "Cancel" }, - "confirm": { "type": "string", "default": "Confirm" }, - "create": { "type": "string", "default": "Create" }, - "date": { "type": "string", "default": "{{value, date}}" }, - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "delete": { "type": "string", "default": "Delete" }, - "delete_prompt": { - "type": "string", - "default": "This attribute will be permanently removed. Are you sure?" - }, - "name": { "type": "string", "default": "Name" }, - "v8n_required": { "type": "string", "default": "Required" }, - "v8n_too_long": { "type": "string", "default": "Too long" }, - "value": { "type": "string", "default": "Value" }, - "visibility": { "type": "string", "default": "Visibility" }, - "visibility_private": { "type": "string", "default": "Only me" }, - "visibility_public": { "type": "string", "default": "Everyone" }, - "visibility_restricted": { "type": "string", "default": "Store admins" }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "close", - "header_update", - "header_create", - "save", - "undo_header", - "undo_message", - "undo_cancel", - "undo_confirm", - "cancel", - "confirm", - "create", - "date", - "date_created", - "date_modified", - "delete", - "delete_prompt", - "name", - "v8n_required", - "v8n_too_long", - "value", - "visibility", - "visibility_private", - "visibility_public", - "visibility_restricted", - "spinner" - ] - } - }, - "required": [ - "label", - "delete_confirm", - "delete_cancel", - "delete_message", - "delete_header", - "pagination", - "dialog" - ] - }, - "items": { - "additionalProperties": false, - "properties": { - "pagination": { - "additionalProperties": false, - "properties": { - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { "type": "string", "default": "{{from}}-{{to}} out of {{total}}" }, - "previous": { "type": "string", "default": "Previous" }, - "card": { - "additionalProperties": false, - "properties": { - "daily": { "type": "string", "default": "Daily" }, - "daily_plural": { "type": "string", "default": "Every {{count}} days" }, - "frequency": { - "type": "string", - "default": "$t(items.pagination.card.{{units}}, { \"count\": {{count}}, \"ns\": \"subscription-form\" })" - }, - "monthly": { "type": "string", "default": "Monthly" }, - "monthly_plural": { "type": "string", "default": "Every {{count}} months" }, - "subinfo_recurring": { - "type": "string", - "default": "$t(items.pagination.card.frequency, { \"count\": \"{{count}}\", \"units\": \"{{units}}\", \"ns\": \"subscription-form\" }) from {{startDate, date}}" - }, - "subinfo_twice_a_month": { - "type": "string", - "default": "$t(items.pagination.card.twice_a_month, { \"ns\": \"subscription-form\" }) from {{startDate, date}}" - }, - "twice_a_month": { "type": "string", "default": "Twice a month" }, - "no_code": { "type": "string", "default": "No SKU" }, - "weekly": { "type": "string", "default": "Weekly" }, - "weekly_plural": { "type": "string", "default": "Every {{count}} weeks" }, - "yearly": { "type": "string", "default": "Yearly" }, - "yearly_plural": { "type": "string", "default": "Every {{count}} years" }, - "price": { "type": "string", "default": "{{amount, price}}" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No items" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "daily", - "daily_plural", - "frequency", - "monthly", - "monthly_plural", - "subinfo_recurring", - "subinfo_twice_a_month", - "twice_a_month", - "no_code", - "weekly", - "weekly_plural", - "yearly", - "yearly_plural", - "price", - "spinner" - ] - } - }, - "required": ["first", "last", "next", "pagination", "previous", "card"] - } - }, - "required": ["pagination"] - }, - "transactions": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Transactions" }, - "pagination": { - "additionalProperties": false, - "properties": { - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { "type": "string", "default": "{{from}}-{{to}} out of {{total}}" }, - "previous": { "type": "string", "default": "Previous" }, - "card": { - "additionalProperties": false, - "properties": { - "code": { "type": "string", "default": "Code" }, - "customer": { "type": "string", "default": "Customer" }, - "description": { "type": "string", "default": "Description" }, - "price": { "type": "string", "default": "{{amount, price}}" }, - "time": { "type": "string", "default": "{{value, date}}" }, - "status_capturing": { "type": "string", "default": "Capturing" }, - "status_captured": { "type": "string", "default": "Captured" }, - "status_approved": { "type": "string", "default": "Approved" }, - "status_authorized": { "type": "string", "default": "Authorized" }, - "status_pending": { "type": "string", "default": "Pending" }, - "status_completed": { "type": "string", "default": "Completed" }, - "status_problem": { "type": "string", "default": "Problem" }, - "status_pending_fraud_review": { - "type": "string", - "default": "Pending_fraud_review" - }, - "status_rejected": { "type": "string", "default": "Rejected" }, - "status_declined": { "type": "string", "default": "Declined" }, - "status_refunding": { "type": "string", "default": "Refunding" }, - "status_refunded": { "type": "string", "default": "Refunded" }, - "status_voided": { "type": "string", "default": "Voided" }, - "status_verified": { "type": "string", "default": "Verified" }, - "summary": { "type": "string", "default": "{{most_expensive_item.name}}" }, - "summary_plural": { - "type": "string", - "default": "{{most_expensive_item.name}} and {{count_minus_one}} more" - }, - "summary_payment_method_change": { - "type": "string", - "default": "Payment method change" - }, - "summary_subscription_modification": { - "type": "string", - "default": "Subscription modification" - }, - "summary_subscription_cancellation": { - "type": "string", - "default": "Subscription cancellation" - }, - "source_MIT": { - "type": "string", - "default": "This transaction was initiated by the merchant" - }, - "source_CIT": { - "type": "string", - "default": "This transaction was initiated by the customer" - }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No transactions" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "code", - "customer", - "description", - "price", - "time", - "status_capturing", - "status_captured", - "status_approved", - "status_authorized", - "status_pending", - "status_completed", - "status_problem", - "status_pending_fraud_review", - "status_rejected", - "status_declined", - "status_refunding", - "status_refunded", - "status_voided", - "status_verified", - "summary", - "summary_plural", - "summary_payment_method_change", - "summary_subscription_modification", - "summary_subscription_cancellation", - "source_MIT", - "source_CIT", - "spinner" - ] - } - }, - "required": ["first", "last", "next", "pagination", "previous", "card"] - } - }, - "required": ["label", "pagination"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "date": { "type": "string", "default": "{{value, date}}" } - }, - "required": ["date_created", "date_modified", "date"] - } - }, - "required": [ - "day", - "day_plural", - "week", - "week_plural", - "month", - "month_plural", - "year", - "year_plural", - "cancel", - "close", - "confirm", - "currency", - "daily", - "daily_plural", - "end_date", - "frequency", - "frequency_label", - "item_plural", - "monthly", - "monthly_plural", - "next_transaction_date", - "start_date", - "price_recurring", - "price_twice_a_month", - "subscription_active", - "subscription_cancelled", - "subscription_failed", - "subscription_inactive", - "subscription_will_be_cancelled", - "subscription_will_be_active", - "transaction_plural", - "twice_a_month", - "undo_cancel", - "undo_confirm", - "undo_header", - "undo_message", - "weekly", - "weekly_plural", - "yearly", - "yearly_plural", - "customer", - "past-due-amount", - "attributes", - "items", - "transactions", - "spinner", - "timestamps" - ] -} diff --git a/src/static/schemas/subscription-settings-form.json b/src/static/schemas/subscription-settings-form.json deleted file mode 100644 index b7eb9f9c3..000000000 --- a/src/static/schemas/subscription-settings-form.json +++ /dev/null @@ -1,242 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "day": { "type": "string", "default": "{{ count }} day" }, - "day_plural": { "type": "string", "default": "{{ count }} days" }, - "day_suffix": { "type": "string", "default": "day" }, - "day_suffix_plural": { "type": "string", "default": "days" }, - "modification-url": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Modification URL" }, - "placeholder": { "type": "string", "default": "https://example.com/edit-subscription" }, - "helper_text": { - "type": "string", - "default": "Enter a full URL or a path to the page under your Store URL where customers can modify their subscription. If present, subscriptions in the Customer Portal will show an Edit link that will send subscribers to this page." - } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "past-due-amount-handling": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Past due amount value" }, - "option_increment": { - "type": "string", - "default": "Contains the sum of all missed payments" - }, - "option_replace": { - "type": "string", - "default": "Contains the last missed payment amount" - }, - "option_ignore": { "type": "string", "default": "Doesn't change" }, - "helper_text": { - "type": "string", - "default": "This setting determines how you'd like to handle past due amounts when we try to process a subscription and that subscritpion fails." - } - }, - "required": ["label", "option_increment", "option_replace", "option_ignore", "helper_text"] - }, - "automatically-charge-past-due-amount": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "" }, - "option_checked": { - "type": "string", - "default": "Charge past due amount with subscription payment" - }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "option_checked", "helper_text"] - }, - "clear-past-due-amounts-on-success": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "" }, - "option_checked": { - "type": "string", - "default": "Clear past due amount on successful payment" - }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "option_checked", "helper_text"] - }, - "reset-nextdate-on-makeup-payment": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "" }, - "option_checked": { - "type": "string", - "default": "Reset next transaction date on make-up payment" - }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "option_checked", "helper_text"] - }, - "reattempt-schedule": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Reattempt schedule" }, - "placeholder": { "type": "string", "default": "Period in days, e.g. 14" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "This schedule is too large. Please reduce the number of entries." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "reminder-email-schedule": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Failed subscription payment email schedule" }, - "placeholder": { "type": "string", "default": "Period in days, e.g. 14" }, - "helper_text": { - "type": "string", - "default": "Number of days after the initial failure that an email notification to the customer should be sent. This only happens for active subscriptions which still have a past due amount. If a reattempt is successful, no additional reminder email will be sent." - }, - "v8n_too_long": { - "type": "string", - "default": "This schedule is too large. Please reduce the number of entries." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "expiring-soon-payment-reminder-schedule": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Payment method expiration email schedule" }, - "placeholder": { "type": "string", "default": "Period in days, e.g. 14" }, - "helper_text": { - "type": "string", - "default": "Number of days until the payment card expires that an email notification should be sent to the customer. This only happens for customers with active subscriptions." - }, - "v8n_too_long": { - "type": "string", - "default": "This schedule is too large. Please reduce the number of entries." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "cancellation-schedule": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Cancel failed subscriptions after" }, - "placeholder": { "type": "string", "default": "Don't cancel" }, - "helper_text": { - "type": "string", - "default": "A single number representing the number of days after the initial failure that a subscription should be set to cancel (assuming a successful payment hasn't been made in the meantime)." - } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "send-email-receipts-for-automated-billing": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "" }, - "option_checked": { - "type": "string", - "default": "Send email receipts for automated billing" - }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "option_checked", "helper_text"] - }, - "reattempt-bypass": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Reattempt behavior" }, - "helper_text": { - "type": "string", - "default": "Determines whether Foxy should reattempt the subscription charge if the transaction's previous error string does or doesn't contain specific text." - }, - "option_reattempt_if_exists": { - "type": "string", - "default": "Reattempt on certain errors" - }, - "option_skip_if_exists": { "type": "string", "default": "Skip on certain errors" }, - "option_always_reattempt": { "type": "string", "default": "Always reattempt" }, - "option_never_reattempt": { "type": "string", "default": "Never reattempt" }, - "reattempt-bypass-strings": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "" }, - "placeholder": { "type": "string", "default": "Add errors..." }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "This list is too large. Please reduce the number of entries." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - } - }, - "required": [ - "label", - "helper_text", - "option_reattempt_if_exists", - "option_skip_if_exists", - "option_always_reattempt", - "option_never_reattempt", - "reattempt-bypass-strings" - ] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "date": { "type": "string", "default": "{{value, date}}" } - }, - "required": ["date_created", "date_modified", "date"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove these subscription settings? You won't be able to bring them back." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - } - }, - "required": [ - "day", - "day_plural", - "day_suffix", - "day_suffix_plural", - "modification-url", - "past-due-amount-handling", - "automatically-charge-past-due-amount", - "clear-past-due-amounts-on-success", - "reset-nextdate-on-makeup-payment", - "reattempt-schedule", - "reminder-email-schedule", - "expiring-soon-payment-reminder-schedule", - "cancellation-schedule", - "send-email-receipts-for-automated-billing", - "reattempt-bypass", - "timestamps", - "spinner", - "delete", - "create" - ] -} diff --git a/src/static/schemas/subscriptions-table.json b/src/static/schemas/subscriptions-table.json deleted file mode 100644 index 74ab8bcb0..000000000 --- a/src/static/schemas/subscriptions-table.json +++ /dev/null @@ -1,68 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "daily": { "type": "string", "default": "Daily" }, - "daily_plural": { "type": "string", "default": "Every {{count}} days" }, - "frequency": { - "type": "string", - "default": "$t({{units}}, { \"count\": {{count}}, \"ns\": \"subscriptions-table\" })" - }, - "monthly": { "type": "string", "default": "Monthly" }, - "monthly_plural": { "type": "string", "default": "Every {{count}} months" }, - "price_recurring": { - "type": "string", - "default": "{{amount, price}} $t(frequency, { \"count\": \"{{count}}\", \"units\": \"{{units}}\", \"ns\": \"subscriptions-table\" })" - }, - "price_twice_a_month": { - "type": "string", - "default": "{{amount, price}} $t(twice_a_month, { \"ns\": \"subscriptions-table\" })" - }, - "subscription_active": { "type": "string", "default": "Next payment on {{date, date}}" }, - "subscription_cancelled": { "type": "string", "default": "Ended on {{date, date}}" }, - "subscription_failed": { "type": "string", "default": "Payment failed on {{date, date}}" }, - "subscription_inactive": { "type": "string", "default": "Inactive" }, - "subscription_will_be_cancelled": { "type": "string", "default": "Ends on {{date, date}}" }, - "subscription_will_be_active": { "type": "string", "default": "Starts on {{date, date}}" }, - "transaction_summary": { "type": "string", "default": "{{most_expensive_item.name}}" }, - "twice_a_month": { "type": "string", "default": "Twice a month" }, - "update": { "type": "string", "default": "Update" }, - "weekly": { "type": "string", "default": "Weekly" }, - "weekly_plural": { "type": "string", "default": "Every {{count}} weeks" }, - "yearly": { "type": "string", "default": "Yearly" }, - "yearly_plural": { "type": "string", "default": "Every {{count}} years" }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "daily", - "daily_plural", - "frequency", - "monthly", - "monthly_plural", - "price_recurring", - "price_twice_a_month", - "subscription_active", - "subscription_cancelled", - "subscription_failed", - "subscription_inactive", - "subscription_will_be_cancelled", - "subscription_will_be_active", - "transaction_summary", - "twice_a_month", - "update", - "weekly", - "weekly_plural", - "yearly", - "yearly_plural", - "spinner" - ] -} diff --git a/src/static/schemas/tax-card.json b/src/static/schemas/tax-card.json deleted file mode 100644 index 5daa3a8fd..000000000 --- a/src/static/schemas/tax-card.json +++ /dev/null @@ -1,23 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "percent": { "type": "string", "default": "{{fraction, percent}}" }, - "tax_global": { "type": "string", "default": "Global tax" }, - "tax_rate_provider_default": { - "type": "string", - "default": "Default (Thomson Reuters; others)" - }, - "tax_union": { "type": "string", "default": "European Union tax" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["percent", "tax_global", "tax_rate_provider_default", "tax_union", "spinner"] -} diff --git a/src/static/schemas/tax-form.json b/src/static/schemas/tax-form.json deleted file mode 100644 index 56db2996c..000000000 --- a/src/static/schemas/tax-form.json +++ /dev/null @@ -1,100 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "cancel": { "type": "string", "default": "Cancel" }, - "city": { "type": "string", "default": "City" }, - "country": { "type": "string", "default": "Country" }, - "create": { "type": "string", "default": "Create" }, - "date": { "type": "string", "default": "{{value, date}}" }, - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "default": { "type": "string", "default": "Default" }, - "delete": { "type": "string", "default": "Delete" }, - "delete_prompt": { - "type": "string", - "default": "This resource will be permanently removed. Are you sure?" - }, - "error": { "type": "string", "default": "Error" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "name": { "type": "string", "default": "Name" }, - "region": { "type": "string", "default": "Region" }, - "tax_apply_to_shipping": { "type": "string", "default": "Apply to shipping" }, - "tax_apply_to_shipping_explainer": { - "type": "string", - "default": "Check to apply this tax to the shipping costs." - }, - "tax_country": { "type": "string", "default": "Country tax" }, - "tax_exempt_all_customer_tax_ids": { - "type": "string", - "default": "Exempt all customers with Tax ID" - }, - "tax_exempt_all_customer_tax_ids_explainer": { - "type": "string", - "default": "Check to skip tax collection for customers with Tax ID on file." - }, - "tax_global": { "type": "string", "default": "Global tax" }, - "tax_local": { "type": "string", "default": "Local tax" }, - "tax_rate": { "type": "string", "default": "Rate (%)" }, - "tax_rate_provider": { "type": "string", "default": "Rate provider" }, - "tax_rate_provider_default": { - "type": "string", - "default": "Default (Thomson Reuters; others)" - }, - "tax_rate_provider_none": { "type": "string", "default": "None (custom rate)" }, - "tax_region": { "type": "string", "default": "Regional tax" }, - "tax_union": { "type": "string", "default": "European Union tax" }, - "tax_use_origin_rates": { "type": "string", "default": "Use origin tax rates" }, - "tax_use_origin_rates_explainer": { - "type": "string", - "default": "Check to use the tax rate of your country regardless of where customers are located." - }, - "type": { "type": "string", "default": "Type" }, - "v8n_required": { "type": "string", "default": "Required" }, - "v8n_too_long": { "type": "string", "default": "Too long" }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "cancel", - "city", - "country", - "create", - "date", - "date_created", - "date_modified", - "default", - "delete", - "delete_prompt", - "error", - "loading_busy", - "name", - "region", - "tax_apply_to_shipping", - "tax_apply_to_shipping_explainer", - "tax_country", - "tax_exempt_all_customer_tax_ids", - "tax_exempt_all_customer_tax_ids_explainer", - "tax_global", - "tax_local", - "tax_rate", - "tax_rate_provider", - "tax_rate_provider_default", - "tax_rate_provider_none", - "tax_region", - "tax_union", - "tax_use_origin_rates", - "tax_use_origin_rates_explainer", - "type", - "v8n_required", - "v8n_too_long", - "spinner" - ] -} diff --git a/src/static/schemas/template-config-form.json b/src/static/schemas/template-config-form.json deleted file mode 100644 index 5370baf66..000000000 --- a/src/static/schemas/template-config-form.json +++ /dev/null @@ -1,321 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "add_country": { "type": "string", "default": "Add country" }, - "add_field": { "type": "string", "default": "Add field" }, - "add_region": { "type": "string", "default": "Add region" }, - "address1": { "type": "string", "default": "Address Line 1" }, - "address2": { "type": "string", "default": "Address Line 2" }, - "allow": { "type": "string", "default": "Allow" }, - "allowlist": { "type": "string", "default": "Allow specific locations" }, - "billing": { "type": "string", "default": "Billing" }, - "block": { "type": "string", "default": "Block" }, - "blocklist": { "type": "string", "default": "Block specific locations" }, - "cart_controls": { "type": "string", "default": "Quantity" }, - "cart_type": { "type": "string", "default": "Cart display" }, - "cart_type_custom": { "type": "string", "default": "Custom" }, - "cart_type_custom_explainer": { - "type": "string", - "default": "Build your own JSONP cart with included config" - }, - "cart_type_default": { "type": "string", "default": "Sidecart" }, - "cart_type_default_explainer": { - "type": "string", - "default": "Default cart appearance in version 2.0" - }, - "cart_type_fullpage": { "type": "string", "default": "Full page" }, - "cart_type_fullpage_explainer": { - "type": "string", - "default": "Send all customers to a full page cart while still including minicart functionality" - }, - "checked_by_default": { "type": "string", "default": "Checked by default" }, - "checkout_type": { "type": "string", "default": "Accounts" }, - "checkout_type_account_only": { "type": "string", "default": "Allow customer accounts only" }, - "checkout_type_default_account": { - "type": "string", - "default": "Allow both, default to customer" - }, - "checkout_type_default_guest": { "type": "string", "default": "Allow both, default to guest" }, - "checkout_type_guest_only": { "type": "string", "default": "Allow guests only" }, - "checkout_type_helper_text": { - "type": "string", - "default": "If you select Allow guests only, your store will not be able to use subscriptions." - }, - "city": { "type": "string", "default": "City" }, - "close": { "type": "string", "default": "Close" }, - "close_icon": { "type": "string", "default": "Close icon" }, - "company": { "type": "string", "default": "Company" }, - "consent": { "type": "string", "default": "Consent" }, - "copy": { "type": "string", "default": "Copy" }, - "country": { "type": "string", "default": "Country" }, - "coupon_entry": { "type": "string", "default": "Coupon code" }, - "create": { "type": "string", "default": "Create" }, - "custom_config": { "type": "string", "default": "Custom config" }, - "custom_config_helper_text": { - "type": "string", - "default": "If you have any custom values you'd like to make available to your twig template, you can add them here as a valid JSON string." - }, - "custom_fields": { "type": "string", "default": "Custom fields" }, - "custom_fields_helper_text": { - "type": "string", - "default": "If you have information you'd like to collect from the customer on the checkout page, you can add custom form fields here which will be added to the checkout form. We recommend you follow the same HTML container structure used on other checkout fields for consistency. You can use Twig syntax here." - }, - "custom_footer": { "type": "string", "default": "Custom footer" }, - "custom_footer_helper_text": { - "type": "string", - "default": "Any JS snippets or conversion scripts you need to add to the footer can be put here and will be inserted before the tag. You can use Twig syntax here. For conversion scripts you only want to display once on the receipt page, use {% if first_receipt_display %} {# conversion script content here #} {% endif %}." - }, - "custom_header": { "type": "string", "default": "Custom header" }, - "custom_header_helper_text": { - "type": "string", - "default": "Any CSS or JS you need to add to the header can be put here and will be inserted before the tag of your templates. Keep in mind all script file references must be through https or run through the Foxy caching system. Twig syntax is not available in the header." - }, - "default": { "type": "string", "default": "Default" }, - "delete": { "type": "string", "default": "Delete" }, - "delete_prompt": { - "type": "string", - "default": "This resource will be permanently removed. Are you sure?" - }, - "disabled": { "type": "string", "default": "Disabled" }, - "display_sdta": { - "type": "string", - "default": "Display a Secure Data Transfer agreement to EU customers" - }, - "display_sdta_explainer": { - "type": "string", - "default": "If you have customers in the European Union, enable this feature so they can opt in to sending their data to our secure servers in the United States." - }, - "display_tos_link": { "type": "string", "default": "Display a link to Terms & Conditions" }, - "display_tos_link_explainer": { - "type": "string", - "default": "Include a checkbox to ask your customers to agree to your Terms of Service." - }, - "enable_postcode_lookup": { - "type": "string", - "default": "Offer city and state suggestions based on postcode" - }, - "enabled": { "type": "string", "default": "Enabled" }, - "error": { "type": "string", "default": "Error" }, - "field_plural": { "type": "string", "default": "Fields" }, - "first_name": { "type": "string", "default": "First name" }, - "foxycomplete": { "type": "string", "default": "Location autocomplete" }, - "foxycomplete_combobox": { "type": "string", "default": "Combo Box" }, - "foxycomplete_combobox_explainer": { - "type": "string", - "default": "Expand to browse options, type to search" - }, - "foxycomplete_disabled": { "type": "string", "default": "Disabled" }, - "foxycomplete_disabled_explainer": { - "type": "string", - "default": "Let customers pick an option from a list" - }, - "foxycomplete_search": { "type": "string", "default": "Search" }, - "foxycomplete_search_explainer": { - "type": "string", - "default": "Display a «search as you type» field" - }, - "ga_account_id": { "type": "string", "default": "Account ID" }, - "ga_account_id_explainer": { - "type": "string", - "default": "You can find the ID in the Admin section of your Analytics in Tracking info > Tracking code." - }, - "ga_include_on_site": { "type": "string", "default": "Include via loader.js" }, - "ga_include_on_site_explainer": { - "type": "string", - "default": "Enable Google Analytics on any page where the loader.js file is included." - }, - "ga_deprecation_notice": { - "type": "string", - "default": "Google has ended support for this integration in July 2023. Please use the newer Google Tag integration below." - }, - "gt_account_id": { "type": "string", "default": "Tag ID" }, - "gt_account_id_explainer": { - "type": "string", - "default": "Tag ID prefixed with G- or AW-. Values prefixed with GT- are not fully supported at this time." - }, - "gt_send_to": { "type": "string", "default": "Ads send to" }, - "gt_send_to_explainer": { - "type": "string", - "default": "Optional. Setting this value will trigger the conversion event to be tracked on the receipt." - }, - "gt_usage_notice": { - "type": "string", - "default": "Enabling the Google Tag for your store requires some additional configuration on your store and within your tag administration to make the data logged through this functionality useful." - }, - "gt_docs_link": { "type": "string", "default": "See our docs for more info" }, - "hidden": { "type": "string", "default": "Hidden" }, - "hidden_fields": { "type": "string", "default": "Hidden fields" }, - "last_name": { "type": "string", "default": "Last name" }, - "location_plural": { "type": "string", "default": "Locations" }, - "location_url": { "type": "string", "default": "Location (URL)" }, - "newsletter_subscribe": { - "type": "string", - "default": "Allow users to sign up for your newsletter" - }, - "newsletter_subscribe_explainer": { - "type": "string", - "default": "This includes a checkbox on your checkout to allow customers to choose to sign up to your newsletter, available in the transaction reports, the API and webhooks." - }, - "open_icon": { "type": "string", "default": "Open icon" }, - "optional": { "type": "string", "default": "Optional" }, - "phone": { "type": "string", "default": "Phone" }, - "postal_code": { "type": "string", "default": "Postal code" }, - "product_category": { "type": "string", "default": "Product category" }, - "product_code": { "type": "string", "default": "Product code" }, - "product_options": { "type": "string", "default": "Product options" }, - "product_weight": { "type": "string", "default": "Product weight" }, - "region": { "type": "string", "default": "Region" }, - "require_consent": { "type": "string", "default": "Require consent to proceed" }, - "required": { "type": "string", "default": "Required" }, - "same_as_shipping": { "type": "string", "default": "Same as shipping" }, - "shipping": { "type": "string", "default": "Shipping" }, - "show_country_flags": { "type": "string", "default": "Show country flags" }, - "sio_account_id": { "type": "string", "default": "Write Key" }, - "sio_account_id_explainer": { - "type": "string", - "default": "You can find the write key in your project set up guide or in the source’s settings." - }, - "skip_csc_for_saved": { "type": "string", "default": "Skip CSC for saved cards" }, - "skip_csc_for_sso": { "type": "string", "default": "Skip CSC for single sign-on" }, - "sub_enddate": { "type": "string", "default": "Subscription end date" }, - "sub_frequency": { "type": "string", "default": "Subscription frequency" }, - "sub_nextdate": { "type": "string", "default": "Subscription next date" }, - "sub_startdate": { "type": "string", "default": "Subscription start date" }, - "supported_cards": { "type": "string", "default": "Cards" }, - "supported_cards_disclaimer": { - "type": "string", - "default": "Applies only to payment gateways where the customer enters their payment card information directly on the Foxy checkout. Exceptions: Adyen Embedded, Amazon Pay, Apple Pay, Klarna, Square and Stripe." - }, - "tax_id": { "type": "string", "default": "Tax ID" }, - "troubleshooting": { "type": "string", "default": "Troubleshooting" }, - "troubleshooting_debug": { - "type": "string", - "default": "Log debug messages in the browser console" - }, - "troubleshooting_debug_explainer": { - "type": "string", - "default": "Enable this option to trigger console.log() calls for our JS, which can assist with troubleshooting your store." - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "add_country", - "add_field", - "add_region", - "address1", - "address2", - "allow", - "allowlist", - "billing", - "block", - "blocklist", - "cart_controls", - "cart_type", - "cart_type_custom", - "cart_type_custom_explainer", - "cart_type_default", - "cart_type_default_explainer", - "cart_type_fullpage", - "cart_type_fullpage_explainer", - "checked_by_default", - "checkout_type", - "checkout_type_account_only", - "checkout_type_default_account", - "checkout_type_default_guest", - "checkout_type_guest_only", - "checkout_type_helper_text", - "city", - "close", - "close_icon", - "company", - "consent", - "copy", - "country", - "coupon_entry", - "create", - "custom_config", - "custom_config_helper_text", - "custom_fields", - "custom_fields_helper_text", - "custom_footer", - "custom_footer_helper_text", - "custom_header", - "custom_header_helper_text", - "default", - "delete", - "delete_prompt", - "disabled", - "display_sdta", - "display_sdta_explainer", - "display_tos_link", - "display_tos_link_explainer", - "enable_postcode_lookup", - "enabled", - "error", - "field_plural", - "first_name", - "foxycomplete", - "foxycomplete_combobox", - "foxycomplete_combobox_explainer", - "foxycomplete_disabled", - "foxycomplete_disabled_explainer", - "foxycomplete_search", - "foxycomplete_search_explainer", - "ga_account_id", - "ga_account_id_explainer", - "ga_include_on_site", - "ga_include_on_site_explainer", - "ga_deprecation_notice", - "gt_account_id", - "gt_account_id_explainer", - "gt_send_to", - "gt_send_to_explainer", - "gt_usage_notice", - "gt_docs_link", - "hidden", - "hidden_fields", - "last_name", - "location_plural", - "location_url", - "newsletter_subscribe", - "newsletter_subscribe_explainer", - "open_icon", - "optional", - "phone", - "postal_code", - "product_category", - "product_code", - "product_options", - "product_weight", - "region", - "require_consent", - "required", - "same_as_shipping", - "shipping", - "show_country_flags", - "sio_account_id", - "sio_account_id_explainer", - "skip_csc_for_saved", - "skip_csc_for_sso", - "sub_enddate", - "sub_frequency", - "sub_nextdate", - "sub_startdate", - "supported_cards", - "supported_cards_disclaimer", - "tax_id", - "troubleshooting", - "troubleshooting_debug", - "troubleshooting_debug_explainer", - "spinner" - ] -} diff --git a/src/static/schemas/template-form.json b/src/static/schemas/template-form.json deleted file mode 100644 index 7f2864021..000000000 --- a/src/static/schemas/template-form.json +++ /dev/null @@ -1,65 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "cache": { "type": "string", "default": "Sync" }, - "cancel": { "type": "string", "default": "Cancel" }, - "create": { "type": "string", "default": "Create" }, - "date": { "type": "string", "default": "{{value, date}}" }, - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "default": { "type": "string", "default": "Default" }, - "delete": { "type": "string", "default": "Delete" }, - "delete_prompt": { - "type": "string", - "default": "This resource will be permanently removed. Are you sure?" - }, - "description": { "type": "string", "default": "Description" }, - "template": { "type": "string", "default": "Template" }, - "template_clipboard": { "type": "string", "default": "Upload source code" }, - "template_default": { "type": "string", "default": "Use default template" }, - "template_url": { "type": "string", "default": "Pull from public URL" }, - "url": { "type": "string", "default": "URL" }, - "url_source_label": { "type": "string", "default": "Cached source" }, - "url_source_placeholder": { - "type": "string", - "default": "Template markup will appear here once cached" - }, - "clipboard_source_label": { "type": "string", "default": "Source" }, - "clipboard_source_placeholder": { - "type": "string", - "default": "Enter your template markup here" - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "cache", - "cancel", - "create", - "date", - "date_created", - "date_modified", - "default", - "delete", - "delete_prompt", - "description", - "template", - "template_clipboard", - "template_default", - "template_url", - "url", - "url_source_label", - "url_source_placeholder", - "clipboard_source_label", - "clipboard_source_placeholder", - "spinner" - ] -} diff --git a/src/static/schemas/template-set-card.json b/src/static/schemas/template-set-card.json deleted file mode 100644 index 5f175ab78..000000000 --- a/src/static/schemas/template-set-card.json +++ /dev/null @@ -1,16 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["spinner"] -} diff --git a/src/static/schemas/template-set-form.json b/src/static/schemas/template-set-form.json deleted file mode 100644 index cd73cf125..000000000 --- a/src/static/schemas/template-set-form.json +++ /dev/null @@ -1,144 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "description": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Description" }, - "placeholder": { "type": "string", "default": "Required - e.g. My Template Set" }, - "helper_text": { - "type": "string", - "default": "Any label that will help you identify this template set in the admin. We won't show this text to the customers." - }, - "v8n_required": { "type": "string", "default": "Please enter a description for this set" }, - "v8n_too_long": { - "type": "string", - "default": "Please reduce this description to 100 characters or less" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_too_long"] - }, - "code": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Code" }, - "placeholder": { "type": "string", "default": "Required - e.g. MY-TEMPLATE-SET" }, - "helper_text": { - "type": "string", - "default": "The template set code for applying this template set to the cart. Your customers might see this code in the URL." - }, - "v8n_required": { "type": "string", "default": "Please enter a code for this set" }, - "v8n_too_long": { - "type": "string", - "default": "Please reduce this code to 50 characters or less" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_too_long"] - }, - "language": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Language" }, - "placeholder": { "type": "string", "default": "Select language" }, - "helper_text": { - "type": "string", - "default": "We'll apply this language to our cart, checkout and receipt pages." - }, - "v8n_required": { "type": "string", "default": "Please select a language for this set" } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "locale-code": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Locale" }, - "placeholder": { "type": "string", "default": "Select locale" }, - "helper_text": { - "type": "string", - "default": "We'll use this locale to format prices and dates for your customers." - }, - "v8n_required": { "type": "string", "default": "Please select a locale for this set" } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "payment-method-set-uri": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Payment method set" }, - "placeholder": { "type": "string", "default": "Default payment method set" }, - "helper_text": { - "type": "string", - "default": "With this template set applied, your customers will see payment methods from the selected set." - } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "language-overrides": { - "additionalProperties": false, - "properties": { - "delete_button_title": { "type": "string", "default": "Restore default value" }, - "save_button": { "type": "string", "default": "Save" }, - "undo_button": { "type": "string", "default": "Undo" }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["delete_button_title", "save_button", "undo_button", "spinner"] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "date": { "type": "string", "default": "{{value, date}}" } - }, - "required": ["date_created", "date_modified", "date"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove this template set? You won't be able to bring it back." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "description", - "code", - "language", - "locale-code", - "payment-method-set-uri", - "language-overrides", - "timestamps", - "delete", - "create", - "spinner" - ] -} diff --git a/src/static/schemas/transaction-card.json b/src/static/schemas/transaction-card.json deleted file mode 100644 index ca94b287e..000000000 --- a/src/static/schemas/transaction-card.json +++ /dev/null @@ -1,79 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "code": { "type": "string", "default": "Code" }, - "customer": { "type": "string", "default": "Customer" }, - "description": { "type": "string", "default": "Description" }, - "price": { "type": "string", "default": "{{amount, price}}" }, - "time": { "type": "string", "default": "{{value, date}} at {{value, time}}" }, - "status_capturing": { "type": "string", "default": "Capturing" }, - "status_captured": { "type": "string", "default": "Captured" }, - "status_approved": { "type": "string", "default": "Approved" }, - "status_authorized": { "type": "string", "default": "Authorized" }, - "status_pending": { "type": "string", "default": "Pending" }, - "status_completed": { "type": "string", "default": "Completed" }, - "status_problem": { "type": "string", "default": "Problem" }, - "status_pending_fraud_review": { "type": "string", "default": "Pending_fraud_review" }, - "status_rejected": { "type": "string", "default": "Rejected" }, - "status_declined": { "type": "string", "default": "Declined" }, - "status_refunding": { "type": "string", "default": "Refunding" }, - "status_refunded": { "type": "string", "default": "Refunded" }, - "status_voided": { "type": "string", "default": "Voided" }, - "status_verified": { "type": "string", "default": "Verified" }, - "summary": { "type": "string", "default": "{{most_expensive_item.name}}" }, - "summary_plural": { - "type": "string", - "default": "{{most_expensive_item.name}} and {{count_minus_one}} more" - }, - "summary_payment_method_change": { "type": "string", "default": "Payment method change" }, - "summary_subscription_modification": { - "type": "string", - "default": "Subscription modification" - }, - "summary_subscription_cancellation": { - "type": "string", - "default": "Subscription cancellation" - }, - "source_MIT": { "type": "string", "default": "This transaction was initiated by the merchant" }, - "source_CIT": { "type": "string", "default": "This transaction was initiated by the customer" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "code", - "customer", - "description", - "price", - "time", - "status_capturing", - "status_captured", - "status_approved", - "status_authorized", - "status_pending", - "status_completed", - "status_problem", - "status_pending_fraud_review", - "status_rejected", - "status_declined", - "status_refunding", - "status_refunded", - "status_voided", - "status_verified", - "summary", - "summary_plural", - "summary_payment_method_change", - "summary_subscription_modification", - "summary_subscription_cancellation", - "source_MIT", - "source_CIT", - "spinner" - ] -} diff --git a/src/static/schemas/transaction.json b/src/static/schemas/transaction.json deleted file mode 100644 index 10b508629..000000000 --- a/src/static/schemas/transaction.json +++ /dev/null @@ -1,3281 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "header": { - "additionalProperties": false, - "properties": { - "title": { "type": "string", "default": "ID {{ display_id }}" }, - "subtitle": { - "type": "string", - "default": "{{ transaction_date, date }} at {{ transaction_date, time }} • {{ ip_country }}" - }, - "subtitle_customer_changed_payment_method": { - "type": "string", - "default": "{{ transaction_date, date }} at {{ transaction_date, time }} • {{ ip_country }} • Customer changed payment method" - }, - "subtitle_admin_changed_payment_method_with_uoe": { - "type": "string", - "default": "{{ transaction_date, date }} at {{ transaction_date, time }} • Store admin used UOE password to change payment method" - }, - "subtitle_integration_changed_payment_method": { - "type": "string", - "default": "{{ transaction_date, date }} at {{ transaction_date, time }} • Integration changed payment method" - }, - "subtitle_admin_changed_payment_method": { - "type": "string", - "default": "{{ transaction_date, date }} at {{ transaction_date, time }} • Store admin changed payment method" - }, - "subtitle_customer_changed_subscription": { - "type": "string", - "default": "{{ transaction_date, date }} at {{ transaction_date, time }} • {{ ip_country }} • Customer made changes to subscription" - }, - "subtitle_admin_changed_subscription_with_uoe": { - "type": "string", - "default": "{{ transaction_date, date }} at {{ transaction_date, time }} • Store admin used UOE password to make changes to subscription" - }, - "subtitle_integration_changed_subscription": { - "type": "string", - "default": "{{ transaction_date, date }} at {{ transaction_date, time }} • Integration made changes to subscription" - }, - "subtitle_admin_changed_subscription": { - "type": "string", - "default": "{{ transaction_date, date }} at {{ transaction_date, time }} • Store admin made changes to subscription" - }, - "subtitle_subscription_renewal_attempt": { - "type": "string", - "default": "{{ transaction_date, date }} at {{ transaction_date, time }} • Subscription renewal attempt" - }, - "subtitle_subscription_renewal_automated_reattempt": { - "type": "string", - "default": "{{ transaction_date, date }} at {{ transaction_date, time }} • Automated subscription renewal reattempt" - }, - "subtitle_subscription_renewal_manual_reattempt": { - "type": "string", - "default": "{{ transaction_date, date }} at {{ transaction_date, time }} • Store admin attempted to renew subscription" - }, - "subtitle_customer_canceled_subscription": { - "type": "string", - "default": "{{ transaction_date, date }} at {{ transaction_date, time }} • {{ ip_country }} • Customer cancelled subscription" - }, - "subtitle_admin_canceled_subscription": { - "type": "string", - "default": "{{ transaction_date, date }} at {{ transaction_date, time }} • Store admin cancelled subscription" - }, - "subtitle_customer_subscribed": { - "type": "string", - "default": "{{ transaction_date, date }} at {{ transaction_date, time }} • {{ ip_country }} • Customer bought a subscription" - }, - "subtitle_admin_subscribed_with_uoe": { - "type": "string", - "default": "{{ transaction_date, date }} at {{ transaction_date, time }} • Store admin used UOE password to buy a subscription" - }, - "subtitle_integration_subscribed": { - "type": "string", - "default": "{{ transaction_date, date }} at {{ transaction_date, time }} • Integration placed an order for customer" - }, - "subtitle_customer_placed_order": { - "type": "string", - "default": "{{ transaction_date, date }} at {{ transaction_date, time }} • {{ ip_country }} • Customer placed an order" - }, - "subtitle_admin_placed_order_with_uoe": { - "type": "string", - "default": "{{ transaction_date, date }} at {{ transaction_date, time }} • Store admin used UOE password to place an order" - }, - "subtitle_integration_placed_order": { - "type": "string", - "default": "{{ transaction_date, date }} at {{ transaction_date, time }} • Integration bought a subscription" - }, - "alert_status_problem": { - "type": "string", - "default": "We were unable to complete this transaction because the amount that was sent to the payment gateway did not match the final total amount." - }, - "alert_status_pending_fraud_review": { - "type": "string", - "default": "The payment gateway flagged this transaction as potentially fraudulent. Please log in to your gateway’s dashboard and look for this transaction to review." - }, - "alert_status_rejected": { - "type": "string", - "default": "The payment gateway refused to process this transaction based on its internal policy. You may be able to get more information about this error by logging in to your gateway’s dashboard and looking for this transaction." - }, - "alert_status_declined": { - "type": "string", - "default": "The payment method used for this transaction was declined. This could be due to insufficient funds, an expired card, or a different reason. You may be able to get more information about this error in your gateway’s dashboard." - } - }, - "required": [ - "title", - "subtitle", - "subtitle_customer_changed_payment_method", - "subtitle_admin_changed_payment_method_with_uoe", - "subtitle_integration_changed_payment_method", - "subtitle_admin_changed_payment_method", - "subtitle_customer_changed_subscription", - "subtitle_admin_changed_subscription_with_uoe", - "subtitle_integration_changed_subscription", - "subtitle_admin_changed_subscription", - "subtitle_subscription_renewal_attempt", - "subtitle_subscription_renewal_automated_reattempt", - "subtitle_subscription_renewal_manual_reattempt", - "subtitle_customer_canceled_subscription", - "subtitle_admin_canceled_subscription", - "subtitle_customer_subscribed", - "subtitle_admin_subscribed_with_uoe", - "subtitle_integration_subscribed", - "subtitle_customer_placed_order", - "subtitle_admin_placed_order_with_uoe", - "subtitle_integration_placed_order", - "alert_status_problem", - "alert_status_pending_fraud_review", - "alert_status_rejected", - "alert_status_declined" - ] - }, - "customer": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Customer" }, - "copy_email_caption": { "type": "string", "default": "Copy email" }, - "copy_id_caption": { "type": "string", "default": "Copy ID" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No customer" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["label", "copy_email_caption", "copy_id_caption", "spinner"] - }, - "items": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Items" }, - "delete_header": { "type": "string", "default": "Remove item?" }, - "delete_message": { - "type": "string", - "default": "Please confirm that you'd like to remove this item from the transaction." - }, - "delete_confirm": { "type": "string", "default": "Remove" }, - "delete_cancel": { "type": "string", "default": "Cancel" }, - "pagination": { - "additionalProperties": false, - "properties": { - "create_button_text": { "type": "string", "default": "Add item +" }, - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { "type": "string", "default": "{{from}}-{{to}} out of {{total}}" }, - "previous": { "type": "string", "default": "Previous" }, - "card": { - "additionalProperties": false, - "properties": { - "delete_button_text": { "type": "string", "default": "Remove" }, - "daily": { "type": "string", "default": "Daily" }, - "daily_plural": { "type": "string", "default": "Every {{count}} days" }, - "frequency": { - "type": "string", - "default": "$t(items.pagination.card.{{units}}, { \"count\": {{count}}, \"ns\": \"transaction\" })" - }, - "monthly": { "type": "string", "default": "Monthly" }, - "monthly_plural": { "type": "string", "default": "Every {{count}} months" }, - "subinfo_recurring": { - "type": "string", - "default": "$t(items.pagination.card.frequency, { \"count\": \"{{count}}\", \"units\": \"{{units}}\", \"ns\": \"transaction\" }) from {{startDate, date}}" - }, - "subinfo_twice_a_month": { - "type": "string", - "default": "$t(items.pagination.card.twice_a_month, { \"ns\": \"transaction\" }) from {{startDate, date}}" - }, - "twice_a_month": { "type": "string", "default": "Twice a month" }, - "no_code": { "type": "string", "default": "No SKU" }, - "weekly": { "type": "string", "default": "Weekly" }, - "weekly_plural": { "type": "string", "default": "Every {{count}} weeks" }, - "yearly": { "type": "string", "default": "Yearly" }, - "yearly_plural": { "type": "string", "default": "Every {{count}} years" }, - "price": { "type": "string", "default": "{{amount, price}}" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No items" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "delete_button_text", - "daily", - "daily_plural", - "frequency", - "monthly", - "monthly_plural", - "subinfo_recurring", - "subinfo_twice_a_month", - "twice_a_month", - "no_code", - "weekly", - "weekly_plural", - "yearly", - "yearly_plural", - "price", - "spinner" - ] - } - }, - "required": [ - "create_button_text", - "first", - "last", - "next", - "pagination", - "previous", - "card" - ] - }, - "dialog": { - "additionalProperties": false, - "properties": { - "close": { "type": "string", "default": "Close" }, - "cancel": { "type": "string", "default": "Cancel" }, - "header_update": { "type": "string", "default": "Item" }, - "header_create": { "type": "string", "default": "New item" }, - "save": { "type": "string", "default": "Save" }, - "undo_header": { "type": "string", "default": "Unsaved changes" }, - "undo_message": { - "type": "string", - "default": "Looks like you didn't save your changes! What would you like to do with them?" - }, - "undo_cancel": { "type": "string", "default": "Review" }, - "undo_confirm": { "type": "string", "default": "Discard" }, - "item-form": { - "additionalProperties": false, - "properties": { - "dimensions": { "type": "string", "default": "Dimensions" }, - "subscriptions": { "type": "string", "default": "Subscriptions" }, - "discount": { "type": "string", "default": "Discount" }, - "name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Name" }, - "helper_text": { "type": "string", "default": "Public name of this item." }, - "placeholder": { "type": "string", "default": "13' Laptop Case" }, - "v8n_required": { "type": "string", "default": "Name is required" }, - "v8n_too_long": { - "type": "string", - "default": "Name mustn't exceed 255 characters" - } - }, - "required": [ - "label", - "helper_text", - "placeholder", - "v8n_required", - "v8n_too_long" - ] - }, - "price": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Price" }, - "helper_text": { - "type": "string", - "default": "Base price before option modifiers." - }, - "placeholder": { "type": "string", "default": "25" }, - "v8n_required": { "type": "string", "default": "Price is required" }, - "v8n_negative": { "type": "string", "default": "Price can't be negative" } - }, - "required": [ - "label", - "helper_text", - "placeholder", - "v8n_required", - "v8n_negative" - ] - }, - "quantity": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Quantity" }, - "helper_text": { "type": "string", "default": "Number of items in the cart." }, - "placeholder": { "type": "string", "default": "1 by default" }, - "v8n_less_than_one": { - "type": "string", - "default": "Quantity must be 1 or more" - } - }, - "required": ["label", "helper_text", "placeholder", "v8n_less_than_one"] - }, - "subscription-frequency": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Subscription frequency" }, - "day": { "type": "string", "default": "Day" }, - "day_plural": { "type": "string", "default": "Days" }, - "week": { "type": "string", "default": "Week" }, - "week_plural": { "type": "string", "default": "Weeks" }, - "month": { "type": "string", "default": "Month" }, - "month_plural": { "type": "string", "default": "Months" }, - "year": { "type": "string", "default": "Year" }, - "year_plural": { "type": "string", "default": "Years" }, - "helper_text": { - "type": "string", - "default": "This determines how often this subscription will be processed. To modify this value for an existing subscription, you must modify the subscription directly." - } - }, - "required": [ - "label", - "day", - "day_plural", - "week", - "week_plural", - "month", - "month_plural", - "year", - "year_plural", - "helper_text" - ] - }, - "subscription-start-date": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Subscription start" }, - "helper_text": { - "type": "string", - "default": "The original date this subscription began or will begin if set in the future. To modify this value for an existing subscription, you must modify the subscription directly." - }, - "placeholder": { "type": "string", "default": "01/01/2022" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "subscription-end-date": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Subscription end" }, - "helper_text": { - "type": "string", - "default": "If set, the date this subscription will end. The subscription will not run on this day." - }, - "placeholder": { "type": "string", "default": "01/01/2022" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "discount-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Discount name" }, - "helper_text": { - "type": "string", - "default": "The name of the line item discount if it is included on this item." - }, - "placeholder": { "type": "string", "default": "One-off 10% discount" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "discount-builder": { - "additionalProperties": false, - "properties": { - "tier": { "type": "string", "default": "Tier" }, - "tier_by": { "type": "string", "default": "by" }, - "tier_if": { "type": "string", "default": "if" }, - "tier_allunits": { "type": "string", "default": "price of each item" }, - "tier_incremental": { - "type": "string", - "default": "price of additional items" - }, - "tier_repeat": { "type": "string", "default": "price of next item" }, - "tier_single": { "type": "string", "default": "order total" }, - "tier_then": { "type": "string", "default": "then" }, - "quantity": { "type": "string", "default": "quantity" }, - "total": { "type": "string", "default": "total" }, - "reduce": { "type": "string", "default": "reduce" }, - "increase": { "type": "string", "default": "increase" } - }, - "required": [ - "tier", - "tier_by", - "tier_if", - "tier_allunits", - "tier_incremental", - "tier_repeat", - "tier_single", - "tier_then", - "quantity", - "total", - "reduce", - "increase" - ] - }, - "expires": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Expires" }, - "helper_text": { - "type": "string", - "default": "Date when this item will be removed from the cart (optional)." - }, - "placeholder": { "type": "string", "default": "01/01/2022" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "image": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Image" }, - "helper_text": { - "type": "string", - "default": "URL of the image to display for this item in the cart and checkout." - }, - "placeholder": { "type": "string", "default": "https://picsum.photos/256" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "url": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "URL" }, - "helper_text": { - "type": "string", - "default": "Full URL for the customer to view this item on the store website." - }, - "placeholder": { - "type": "string", - "default": "https://example.com/products/123" - } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "quantity-min": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Min quantity" }, - "helper_text": { "type": "string", "default": "Minimum quantity per cart." }, - "placeholder": { "type": "string", "default": "1" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "quantity-max": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Max quantity" }, - "helper_text": { "type": "string", "default": "Maximum quantity per cart." }, - "placeholder": { "type": "string", "default": "25" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "shipto": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Shipping address" }, - "helper_text": { - "type": "string", - "default": "Used for multiship to assign this item to a specific shipment." - }, - "placeholder": { - "type": "string", - "default": "Select address to ship this item to..." - } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "width": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Width" }, - "helper_text": { - "type": "string", - "default": "This is currently a placeholder for future use." - }, - "placeholder": { "type": "string", "default": "16" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "height": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Height" }, - "helper_text": { - "type": "string", - "default": "This is currently a placeholder for future use." - }, - "placeholder": { "type": "string", "default": "8" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "length": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Width" }, - "helper_text": { - "type": "string", - "default": "This is currently a placeholder for future use." - }, - "placeholder": { "type": "string", "default": "32" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "weight": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Weight" }, - "helper_text": { - "type": "string", - "default": "Per-item weight, used for shipping rate requests." - }, - "placeholder": { "type": "string", "default": "24" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "item-category-uri": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Item category" }, - "helper_text": { - "type": "string", - "default": "Item category associated with this item." - }, - "placeholder": { "type": "string", "default": "Select item category..." } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "code": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Code" }, - "helper_text": { - "type": "string", - "default": "Unique item code such as SKU or barcode." - }, - "placeholder": { "type": "string", "default": "MY-PRODUCT-001" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "parent-code": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Parent code" }, - "helper_text": { - "type": "string", - "default": "Used if this should be a child product in a bundle." - }, - "placeholder": { "type": "string", "default": "MY-BUNDLE-001" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "discount-details": { - "additionalProperties": false, - "properties": { - "title": { "type": "string", "default": "Discounts" }, - "pagination": { - "additionalProperties": false, - "properties": { - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { - "type": "string", - "default": "{{from}}-{{to}} out of {{total}}" - }, - "previous": { "type": "string", "default": "Previous" }, - "card": { - "additionalProperties": false, - "properties": { - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No discounts" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["spinner"] - } - }, - "required": ["first", "last", "next", "pagination", "previous", "card"] - } - }, - "required": ["title", "pagination"] - }, - "coupon-details": { - "additionalProperties": false, - "properties": { - "title": { "type": "string", "default": "Coupons" }, - "pagination": { - "additionalProperties": false, - "properties": { - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { - "type": "string", - "default": "{{from}}-{{to}} out of {{total}}" - }, - "previous": { "type": "string", "default": "Previous" }, - "card": { - "additionalProperties": false, - "properties": { - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No coupons" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["spinner"] - } - }, - "required": ["first", "last", "next", "pagination", "previous", "card"] - } - }, - "required": ["title", "pagination"] - }, - "attributes": { - "additionalProperties": false, - "properties": { - "title": { "type": "string", "default": "Attributes" }, - "delete_header": { "type": "string", "default": "Remove attribute?" }, - "delete_message": { - "type": "string", - "default": "Please confirm that you'd like to remove this attribute from the item." - }, - "delete_confirm": { "type": "string", "default": "Remove" }, - "delete_cancel": { "type": "string", "default": "Cancel" }, - "dialog": { - "additionalProperties": false, - "properties": { - "header_create": { "type": "string", "default": "Create attribute" }, - "header_update": { "type": "string", "default": "Update attribute" }, - "close": { "type": "string", "default": "Close" }, - "save": { "type": "string", "default": "Save" }, - "cancel": { "type": "string", "default": "Cancel" }, - "undo_header": { "type": "string", "default": "Unsaved changes" }, - "undo_message": { - "type": "string", - "default": "Looks like you didn't save your changes! What would you like to do with them?" - }, - "undo_cancel": { "type": "string", "default": "Review" }, - "undo_confirm": { "type": "string", "default": "Discard" }, - "attribute-form": { - "additionalProperties": false, - "properties": { - "name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Name" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "Name of this attribute. It does not have to be unique." - }, - "v8n_required": { - "type": "string", - "default": "Please name this attribute." - }, - "v8n_too_long": { - "type": "string", - "default": "Please choose a name that is 500 characters long or less." - } - }, - "required": [ - "label", - "placeholder", - "helper_text", - "v8n_required", - "v8n_too_long" - ] - }, - "value": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Value" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "Value of this attribute. Attribute values are automatically HTML-escaped." - }, - "v8n_required": { - "type": "string", - "default": "Please provide a value for this attribute." - }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we can't store values that are more than 1000 characters long." - } - }, - "required": [ - "label", - "placeholder", - "helper_text", - "v8n_required", - "v8n_too_long" - ] - }, - "visibility": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Visibility" }, - "option_public": { "type": "string", "default": "Everyone" }, - "option_restricted": { - "type": "string", - "default": "Store admins" - }, - "option_private": { "type": "string", "default": "Only me" }, - "helper_text": { - "type": "string", - "default": "Controls who can see this attribute. Public attributes can be shown to anyone, including customers. Private attributes are more suitable for configuration or technical details which are irrelevant to the public. Restricted attributes can only be viewed with the OAuth client that created them." - } - }, - "required": [ - "label", - "option_public", - "option_restricted", - "option_private", - "helper_text" - ] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date": { "type": "string", "default": "{{value, date}}" }, - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" } - }, - "required": ["date", "date_created", "date_modified"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove this attribute? You won't be able to bring it back." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "name", - "value", - "visibility", - "timestamps", - "delete", - "create", - "spinner" - ] - } - }, - "required": [ - "header_create", - "header_update", - "close", - "save", - "cancel", - "undo_header", - "undo_message", - "undo_cancel", - "undo_confirm", - "attribute-form" - ] - }, - "pagination": { - "additionalProperties": false, - "properties": { - "create_button_text": { "type": "string", "default": "Add attribute +" }, - "card": { - "additionalProperties": false, - "properties": { - "delete_button_text": { "type": "string", "default": "Delete" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No attributes" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["delete_button_text", "spinner"] - }, - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { - "type": "string", - "default": "{{from}}-{{to}} out of {{total}}" - }, - "previous": { "type": "string", "default": "Previous" } - }, - "required": [ - "create_button_text", - "card", - "first", - "last", - "next", - "pagination", - "previous" - ] - } - }, - "required": [ - "title", - "delete_header", - "delete_message", - "delete_confirm", - "delete_cancel", - "dialog", - "pagination" - ] - }, - "item-options": { - "additionalProperties": false, - "properties": { - "title": { "type": "string", "default": "Item options" }, - "delete_header": { "type": "string", "default": "Remove item option?" }, - "delete_message": { - "type": "string", - "default": "Please confirm that you'd like to remove this item option from the item." - }, - "delete_confirm": { "type": "string", "default": "Remove" }, - "delete_cancel": { "type": "string", "default": "Cancel" }, - "dialog": { - "additionalProperties": false, - "properties": { - "header_create": { "type": "string", "default": "Create option" }, - "header_update": { "type": "string", "default": "Update option" }, - "close": { "type": "string", "default": "Close" }, - "save": { "type": "string", "default": "Save" }, - "cancel": { "type": "string", "default": "Cancel" }, - "undo_header": { "type": "string", "default": "Unsaved changes" }, - "undo_message": { - "type": "string", - "default": "Looks like you didn't save your changes! What would you like to do with them?" - }, - "undo_cancel": { "type": "string", "default": "Review" }, - "undo_confirm": { "type": "string", "default": "Discard" }, - "item-option-form": { - "additionalProperties": false, - "properties": { - "name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Name" }, - "helper_text": { "type": "string", "default": "" }, - "placeholder": { "type": "string", "default": "Color" }, - "v8n_required": { "type": "string", "default": "Name is required" }, - "v8n_too_long": { - "type": "string", - "default": "Name mustn't exceed 100 characters" - } - }, - "required": [ - "label", - "helper_text", - "placeholder", - "v8n_required", - "v8n_too_long" - ] - }, - "value": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Value" }, - "helper_text": { "type": "string", "default": "" }, - "placeholder": { "type": "string", "default": "Red" }, - "v8n_required": { - "type": "string", - "default": "Value is required" - }, - "v8n_too_long": { - "type": "string", - "default": "Value mustn't exceed 1024 characters" - } - }, - "required": [ - "label", - "helper_text", - "placeholder", - "v8n_required", - "v8n_too_long" - ] - }, - "price-mod": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Price" }, - "helper_text": { - "type": "string", - "default": "Same currency as item" - }, - "placeholder": { "type": "string", "default": "10" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "weight-mod": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Weight" }, - "helper_text": { "type": "string", "default": "Arbitrary units" }, - "placeholder": { "type": "string", "default": "5" } - }, - "required": ["label", "helper_text", "placeholder"] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "date": { "type": "string", "default": "{{value, date}}" } - }, - "required": ["date_created", "date_modified", "date"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove this item option? You won't be able to bring it back." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - } - }, - "required": [ - "name", - "value", - "price-mod", - "weight-mod", - "timestamps", - "spinner", - "delete", - "create" - ] - } - }, - "required": [ - "header_create", - "header_update", - "close", - "save", - "cancel", - "undo_header", - "undo_message", - "undo_cancel", - "undo_confirm", - "item-option-form" - ] - }, - "pagination": { - "additionalProperties": false, - "properties": { - "card": { - "additionalProperties": false, - "properties": { - "delete_button_text": { "type": "string", "default": "Delete" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No item options" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["delete_button_text", "spinner"] - }, - "create_button_text": { "type": "string", "default": "Add option +" }, - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { - "type": "string", - "default": "{{from}}-{{to}} out of {{total}}" - }, - "previous": { "type": "string", "default": "Previous" } - }, - "required": [ - "card", - "create_button_text", - "first", - "last", - "next", - "pagination", - "previous" - ] - } - }, - "required": [ - "title", - "delete_header", - "delete_message", - "delete_confirm", - "delete_cancel", - "dialog", - "pagination" - ] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "date": { "type": "string", "default": "{{value, date}}" } - }, - "required": ["date_created", "date_modified", "date"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove this item? You won't be able to bring it back." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "dimensions", - "subscriptions", - "discount", - "name", - "price", - "quantity", - "subscription-frequency", - "subscription-start-date", - "subscription-end-date", - "discount-name", - "discount-builder", - "expires", - "image", - "url", - "quantity-min", - "quantity-max", - "shipto", - "width", - "height", - "length", - "weight", - "item-category-uri", - "code", - "parent-code", - "discount-details", - "coupon-details", - "attributes", - "item-options", - "timestamps", - "delete", - "create", - "spinner" - ] - } - }, - "required": [ - "close", - "cancel", - "header_update", - "header_create", - "save", - "undo_header", - "undo_message", - "undo_cancel", - "undo_confirm", - "item-form" - ] - } - }, - "required": [ - "label", - "delete_header", - "delete_message", - "delete_confirm", - "delete_cancel", - "pagination", - "dialog" - ] - }, - "custom-fields": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Custom fields" }, - "delete_header": { "type": "string", "default": "Remove custom field?" }, - "delete_message": { - "type": "string", - "default": "Please confirm that you'd like to remove this custom field from the item." - }, - "delete_confirm": { "type": "string", "default": "Remove" }, - "delete_cancel": { "type": "string", "default": "Cancel" }, - "dialog": { - "additionalProperties": false, - "properties": { - "close": { "type": "string", "default": "Close" }, - "cancel": { "type": "string", "default": "Cancel" }, - "header_update": { "type": "string", "default": "Custom field" }, - "header_create": { "type": "string", "default": "New custom field" }, - "save": { "type": "string", "default": "Save" }, - "undo_header": { "type": "string", "default": "Unsaved changes" }, - "undo_message": { - "type": "string", - "default": "Looks like you didn't save your changes! What would you like to do with them?" - }, - "undo_cancel": { "type": "string", "default": "Review" }, - "undo_confirm": { "type": "string", "default": "Discard" }, - "custom-field-form": { - "additionalProperties": false, - "properties": { - "name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Name" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { "type": "string", "default": "Maximum 100 characters." }, - "v8n_required": { - "type": "string", - "default": "Please name this custom field." - }, - "v8n_too_long": { - "type": "string", - "default": "Please choose a name that is 100 characters long or less." - } - }, - "required": [ - "label", - "placeholder", - "helper_text", - "v8n_required", - "v8n_too_long" - ] - }, - "value": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Value" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { "type": "string", "default": "Maximum 700 characters." }, - "v8n_required": { - "type": "string", - "default": "Please provide a value for this custom field." - }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we can't store values that are more than 700 characters long." - } - }, - "required": [ - "label", - "placeholder", - "helper_text", - "v8n_required", - "v8n_too_long" - ] - }, - "visibility": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Visibility" }, - "option_hidden": { "type": "string", "default": "Hide in receipts" }, - "helper_text": { - "type": "string", - "default": "Whether or not this custom field is visible on the receipt and email receipt. This correlates to custom fields with a \"h:\" prefix when added to the cart." - } - }, - "required": ["label", "option_hidden", "helper_text"] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date": { "type": "string", "default": "{{value, date}}" }, - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" } - }, - "required": ["date", "date_created", "date_modified"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove this custom field? You won't be able to bring it back." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "name", - "value", - "visibility", - "timestamps", - "delete", - "create", - "spinner" - ] - } - }, - "required": [ - "close", - "cancel", - "header_update", - "header_create", - "save", - "undo_header", - "undo_message", - "undo_cancel", - "undo_confirm", - "custom-field-form" - ] - }, - "pagination": { - "additionalProperties": false, - "properties": { - "create_button_text": { "type": "string", "default": "Add custom field +" }, - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { "type": "string", "default": "{{from}}-{{to}} out of {{total}}" }, - "previous": { "type": "string", "default": "Previous" }, - "card": { - "additionalProperties": false, - "properties": { - "delete_button_text": { "type": "string", "default": "Remove" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No custom fields" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["delete_button_text", "spinner"] - } - }, - "required": [ - "create_button_text", - "first", - "last", - "next", - "pagination", - "previous", - "card" - ] - } - }, - "required": [ - "label", - "delete_header", - "delete_message", - "delete_confirm", - "delete_cancel", - "dialog", - "pagination" - ] - }, - "attributes": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Attributes" }, - "delete_header": { "type": "string", "default": "Remove attribute?" }, - "delete_message": { - "type": "string", - "default": "Please confirm that you'd like to remove this attribute from the item." - }, - "delete_confirm": { "type": "string", "default": "Remove" }, - "delete_cancel": { "type": "string", "default": "Cancel" }, - "dialog": { - "additionalProperties": false, - "properties": { - "close": { "type": "string", "default": "Close" }, - "cancel": { "type": "string", "default": "Cancel" }, - "header_update": { "type": "string", "default": "Attribute" }, - "header_create": { "type": "string", "default": "New attribute" }, - "save": { "type": "string", "default": "Save" }, - "undo_header": { "type": "string", "default": "Unsaved changes" }, - "undo_message": { - "type": "string", - "default": "Looks like you didn't save your changes! What would you like to do with them?" - }, - "undo_cancel": { "type": "string", "default": "Review" }, - "undo_confirm": { "type": "string", "default": "Discard" }, - "attribute-form": { - "additionalProperties": false, - "properties": { - "name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Name" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "Name of this attribute. It does not have to be unique." - }, - "v8n_required": { "type": "string", "default": "Please name this attribute." }, - "v8n_too_long": { - "type": "string", - "default": "Please choose a name that is 500 characters long or less." - } - }, - "required": [ - "label", - "placeholder", - "helper_text", - "v8n_required", - "v8n_too_long" - ] - }, - "value": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Value" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "Value of this attribute. Attribute values are automatically HTML-escaped." - }, - "v8n_required": { - "type": "string", - "default": "Please provide a value for this attribute." - }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we can't store values that are more than 1000 characters long." - } - }, - "required": [ - "label", - "placeholder", - "helper_text", - "v8n_required", - "v8n_too_long" - ] - }, - "visibility": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Visibility" }, - "option_public": { "type": "string", "default": "Everyone" }, - "option_restricted": { "type": "string", "default": "Store admins" }, - "option_private": { "type": "string", "default": "Only me" }, - "helper_text": { - "type": "string", - "default": "Controls who can see this attribute. Public attributes can be shown to anyone, including customers. Private attributes are more suitable for configuration or technical details which are irrelevant to the public. Restricted attributes can only be viewed with the OAuth client that created them." - } - }, - "required": [ - "label", - "option_public", - "option_restricted", - "option_private", - "helper_text" - ] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date": { "type": "string", "default": "{{value, date}}" }, - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" } - }, - "required": ["date", "date_created", "date_modified"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove this attribute? You won't be able to bring it back." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "name", - "value", - "visibility", - "timestamps", - "delete", - "create", - "spinner" - ] - } - }, - "required": [ - "close", - "cancel", - "header_update", - "header_create", - "save", - "undo_header", - "undo_message", - "undo_cancel", - "undo_confirm", - "attribute-form" - ] - }, - "pagination": { - "additionalProperties": false, - "properties": { - "create_button_text": { "type": "string", "default": "Add attribute +" }, - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { "type": "string", "default": "{{from}}-{{to}} out of {{total}}" }, - "previous": { "type": "string", "default": "Previous" }, - "card": { - "additionalProperties": false, - "properties": { - "delete_button_text": { "type": "string", "default": "Remove" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No attributes" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["delete_button_text", "spinner"] - } - }, - "required": [ - "create_button_text", - "first", - "last", - "next", - "pagination", - "previous", - "card" - ] - } - }, - "required": [ - "label", - "delete_header", - "delete_message", - "delete_confirm", - "delete_cancel", - "dialog", - "pagination" - ] - }, - "summary": { - "additionalProperties": false, - "properties": { - "total_shipping": { "type": "string", "default": "Shipping" }, - "total_tax": { "type": "string", "default": "Tax" }, - "subtotal": { "type": "string", "default": "Subtotal" }, - "total": { "type": "string", "default": "Total" }, - "price": { "type": "string", "default": "{{amount, price}}" }, - "status_capturing": { "type": "string", "default": "Capturing" }, - "status_captured": { "type": "string", "default": "Captured" }, - "status_approved": { "type": "string", "default": "Approved" }, - "status_authorized": { "type": "string", "default": "Authorized" }, - "status_pending": { "type": "string", "default": "Pending" }, - "status_completed": { "type": "string", "default": "Completed" }, - "status_problem": { "type": "string", "default": "Problem" }, - "status_pending_fraud_review": { "type": "string", "default": "Pending_fraud_review" }, - "status_rejected": { "type": "string", "default": "Rejected" }, - "status_declined": { "type": "string", "default": "Declined" }, - "status_refunding": { "type": "string", "default": "Refunding" }, - "status_refunded": { "type": "string", "default": "Refunded" }, - "status_voided": { "type": "string", "default": "Voided" }, - "status_verified": { "type": "string", "default": "Verified" } - }, - "required": [ - "total_shipping", - "total_tax", - "subtotal", - "total", - "price", - "status_capturing", - "status_captured", - "status_approved", - "status_authorized", - "status_pending", - "status_completed", - "status_problem", - "status_pending_fraud_review", - "status_rejected", - "status_declined", - "status_refunding", - "status_refunded", - "status_voided", - "status_verified" - ] - }, - "payments": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Payments" }, - "pagination": { - "additionalProperties": false, - "properties": { - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { "type": "string", "default": "{{from}}-{{to}} out of {{total}}" }, - "previous": { "type": "string", "default": "Previous" }, - "card": { - "additionalProperties": false, - "properties": { - "code": { "type": "string", "default": "Code" }, - "date": { "type": "string", "default": "{{value, date}}" }, - "fraud_risk": { "type": "string", "default": "Fraud risk: {{ score }}" }, - "processor_response": { "type": "string", "default": "{{ processor_response }}" }, - "purchase_order": { "type": "string", "default": "PO {{ purchase_order }}" }, - "paypal_payer_id": { - "type": "string", - "default": "PayPal Payer ID {{ paypal_payer_id }}" - }, - "third_party_id": { - "type": "string", - "default": "External ID {{ third_party_id }}" - }, - "price": { "type": "string", "default": "{{amount, price}}" }, - "unknown": { "type": "string", "default": "Unknown" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No payments" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "code", - "date", - "fraud_risk", - "processor_response", - "purchase_order", - "paypal_payer_id", - "third_party_id", - "price", - "unknown", - "spinner" - ] - } - }, - "required": ["first", "last", "next", "pagination", "previous", "card"] - } - }, - "required": ["label", "pagination"] - }, - "billing-addresses": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Billing addresses" }, - "dialog": { - "additionalProperties": false, - "properties": { - "close": { "type": "string", "default": "Close" }, - "cancel": { "type": "string", "default": "Cancel" }, - "header_update": { "type": "string", "default": "Billing address" }, - "address-form": { - "additionalProperties": false, - "properties": { - "address-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Address name" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_required": { "type": "string", "default": "Please enter address name" }, - "v8n_too_long": { - "type": "string", - "default": "Please shorten address name to 100 characters or less" - } - }, - "required": [ - "label", - "placeholder", - "helper_text", - "v8n_required", - "v8n_too_long" - ] - }, - "first-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "First name" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we can't store first names longer than 50 characters" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "last-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Last name" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we can't store last names longer than 50 characters" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "company": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Company" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we can't store company names longer than 50 characters" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "phone": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Phone" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "This phone number appears to be too long" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "address-one": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Address Line 1" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "Street address, P.O. box, company name, c/o" - }, - "v8n_required": { "type": "string", "default": "Please enter address line 1" }, - "v8n_too_long": { - "type": "string", - "default": "Please shorten address line 1 to 100 characters or less" - } - }, - "required": [ - "label", - "placeholder", - "helper_text", - "v8n_required", - "v8n_too_long" - ] - }, - "address-two": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Address Line 2" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { - "type": "string", - "default": "Apartment, suite, unit, building, floor, etc." - }, - "v8n_too_long": { - "type": "string", - "default": "Please shorten address line 2 to 100 characters or less" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "city": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "City" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we can't store city names longer than 50 characters" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "postal-code": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Postal code" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "This postal code appears to be too long" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "country": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Country" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { "type": "string", "default": "" } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "region": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Region" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we can't store region names longer than 50 characters" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date": { "type": "string", "default": "{{value, date}}" }, - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" } - }, - "required": ["date", "date_created", "date_modified"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove this address? You won't be able to bring it back." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - }, - "country_af": { "type": "string", "default": "Afghanistan" }, - "country_ax": { "type": "string", "default": "Åland Islands" }, - "country_al": { "type": "string", "default": "Albania" }, - "country_dz": { "type": "string", "default": "Algeria" }, - "country_as": { "type": "string", "default": "American Samoa" }, - "country_ad": { "type": "string", "default": "Andorra" }, - "country_ao": { "type": "string", "default": "Angola" }, - "country_ai": { "type": "string", "default": "Anguilla" }, - "country_aq": { "type": "string", "default": "Antarctica" }, - "country_ag": { "type": "string", "default": "Antigua and Barbuda" }, - "country_ar": { "type": "string", "default": "Argentina" }, - "country_am": { "type": "string", "default": "Armenia" }, - "country_aw": { "type": "string", "default": "Aruba" }, - "country_au": { "type": "string", "default": "Australia" }, - "country_au_region_act": { - "type": "string", - "default": "Australian Capital Territory" - }, - "country_au_region_nsw": { "type": "string", "default": "New South Wales" }, - "country_au_region_nt": { "type": "string", "default": "Northern Territory" }, - "country_au_region_qld": { "type": "string", "default": "Queensland" }, - "country_au_region_sa": { "type": "string", "default": "South Australia" }, - "country_au_region_tas": { "type": "string", "default": "Tasmania" }, - "country_au_region_vic": { "type": "string", "default": "Victoria" }, - "country_au_region_wa": { "type": "string", "default": "Western Australia" }, - "country_at": { "type": "string", "default": "Austria" }, - "country_at_region_bl": { "type": "string", "default": "Burgenland" }, - "country_at_region_kn": { "type": "string", "default": "Kaernten" }, - "country_at_region_no": { "type": "string", "default": "Niederoesterreich" }, - "country_at_region_oo": { "type": "string", "default": "Oberoesterreich" }, - "country_at_region_sb": { "type": "string", "default": "Salzburg" }, - "country_at_region_st": { "type": "string", "default": "Steiermark" }, - "country_at_region_ti": { "type": "string", "default": "Tirol" }, - "country_at_region_vb": { "type": "string", "default": "Voralberg" }, - "country_at_region_wi": { "type": "string", "default": "Wien" }, - "country_az": { "type": "string", "default": "Azerbaijan" }, - "country_bs": { "type": "string", "default": "Bahamas" }, - "country_bh": { "type": "string", "default": "Bahrain" }, - "country_bd": { "type": "string", "default": "Bangladesh" }, - "country_bb": { "type": "string", "default": "Barbados" }, - "country_by": { "type": "string", "default": "Belarus" }, - "country_be": { "type": "string", "default": "Belgium" }, - "country_bz": { "type": "string", "default": "Belize" }, - "country_bj": { "type": "string", "default": "Benin" }, - "country_bm": { "type": "string", "default": "Bermuda" }, - "country_bt": { "type": "string", "default": "Bhutan" }, - "country_bo": { "type": "string", "default": "Bolivia" }, - "country_bq": { "type": "string", "default": "Bonaire, Sint Eustatius and Saba" }, - "country_bq_region_bo": { "type": "string", "default": "Bonaire" }, - "country_bq_region_sa": { "type": "string", "default": "Saba" }, - "country_bq_region_se": { "type": "string", "default": "Sint Eustatius" }, - "country_ba": { "type": "string", "default": "Bosnia and Herzegovina" }, - "country_bw": { "type": "string", "default": "Botswana" }, - "country_bv": { "type": "string", "default": "Bouvet Island" }, - "country_br": { "type": "string", "default": "Brazil" }, - "country_io": { "type": "string", "default": "British Indian Ocean Territory" }, - "country_bn": { "type": "string", "default": "Brunei Darussalam" }, - "country_bg": { "type": "string", "default": "Bulgaria" }, - "country_bf": { "type": "string", "default": "Burkina Faso" }, - "country_bi": { "type": "string", "default": "Burundi" }, - "country_kh": { "type": "string", "default": "Cambodia" }, - "country_cm": { "type": "string", "default": "Cameroon" }, - "country_ca": { "type": "string", "default": "Canada" }, - "country_ca_region_ab": { "type": "string", "default": "Alberta" }, - "country_ca_region_bc": { "type": "string", "default": "British Columbia" }, - "country_ca_region_mb": { "type": "string", "default": "Manitoba" }, - "country_ca_region_nb": { "type": "string", "default": "New Brunswick" }, - "country_ca_region_nl": { - "type": "string", - "default": "Newfoundland and Labrador" - }, - "country_ca_region_nt": { "type": "string", "default": "Northwest Territories" }, - "country_ca_region_ns": { "type": "string", "default": "Nova Scotia" }, - "country_ca_region_nu": { "type": "string", "default": "Nunavut" }, - "country_ca_region_on": { "type": "string", "default": "Ontario" }, - "country_ca_region_pe": { "type": "string", "default": "Prince Edward Island" }, - "country_ca_region_qc": { "type": "string", "default": "Quebec" }, - "country_ca_region_sk": { "type": "string", "default": "Saskatchewan" }, - "country_ca_region_yt": { "type": "string", "default": "Yukon" }, - "country_cv": { "type": "string", "default": "Cape Verde" }, - "country_cw": { "type": "string", "default": "Curaçao" }, - "country_ky": { "type": "string", "default": "Cayman Islands" }, - "country_cf": { "type": "string", "default": "Central African Republic" }, - "country_td": { "type": "string", "default": "Chad" }, - "country_cl": { "type": "string", "default": "Chile" }, - "country_cn": { "type": "string", "default": "China" }, - "country_cx": { "type": "string", "default": "Christmas Island" }, - "country_cc": { "type": "string", "default": "Cocos (Keeling) Islands" }, - "country_co": { "type": "string", "default": "Colombia" }, - "country_km": { "type": "string", "default": "Comoros" }, - "country_cg": { "type": "string", "default": "Congo" }, - "country_cd": { - "type": "string", - "default": "Congo, the Democratic Republic of the" - }, - "country_ck": { "type": "string", "default": "Cook Islands" }, - "country_cr": { "type": "string", "default": "Costa Rica" }, - "country_ci": { "type": "string", "default": "Cote DIvoire" }, - "country_hr": { "type": "string", "default": "Croatia" }, - "country_cu": { "type": "string", "default": "Cuba" }, - "country_cy": { "type": "string", "default": "Cyprus" }, - "country_cz": { "type": "string", "default": "Czech Republic" }, - "country_dk": { "type": "string", "default": "Denmark" }, - "country_dj": { "type": "string", "default": "Djibouti" }, - "country_dm": { "type": "string", "default": "Dominica" }, - "country_do": { "type": "string", "default": "Dominican Republic" }, - "country_ec": { "type": "string", "default": "Ecuador" }, - "country_eg": { "type": "string", "default": "Egypt" }, - "country_sv": { "type": "string", "default": "El Salvador" }, - "country_sx": { "type": "string", "default": "Sint Maarten" }, - "country_gq": { "type": "string", "default": "Equatorial Guinea" }, - "country_er": { "type": "string", "default": "Eritrea" }, - "country_ee": { "type": "string", "default": "Estonia" }, - "country_et": { "type": "string", "default": "Ethiopia" }, - "country_fk": { "type": "string", "default": "Falkland Islands (Malvinas)" }, - "country_fo": { "type": "string", "default": "Faroe Islands" }, - "country_fj": { "type": "string", "default": "Fiji" }, - "country_fi": { "type": "string", "default": "Finland" }, - "country_fr": { "type": "string", "default": "France" }, - "country_gf": { "type": "string", "default": "French Guiana" }, - "country_pf": { "type": "string", "default": "French Polynesia" }, - "country_tf": { "type": "string", "default": "French Southern Territories" }, - "country_ga": { "type": "string", "default": "Gabon" }, - "country_gm": { "type": "string", "default": "Gambia" }, - "country_ge": { "type": "string", "default": "Georgia" }, - "country_de": { "type": "string", "default": "Germany" }, - "country_de_region_bw": { "type": "string", "default": "Baden-Wuerttemberg" }, - "country_de_region_by": { "type": "string", "default": "Bayern" }, - "country_de_region_be": { "type": "string", "default": "Berlin" }, - "country_de_region_bb": { "type": "string", "default": "Brandenburg" }, - "country_de_region_hb": { "type": "string", "default": "Bremen" }, - "country_de_region_hh": { "type": "string", "default": "Hamburg" }, - "country_de_region_he": { "type": "string", "default": "Hessen" }, - "country_de_region_mv": { "type": "string", "default": "Mecklenburg-Vorpommern" }, - "country_de_region_ni": { "type": "string", "default": "Niedersachsen" }, - "country_de_region_nw": { "type": "string", "default": "Nordrhein-Westfalen" }, - "country_de_region_rp": { "type": "string", "default": "Rheinland-Pfalz" }, - "country_de_region_sl": { "type": "string", "default": "Saarland" }, - "country_de_region_sn": { "type": "string", "default": "Sachsen" }, - "country_de_region_st": { "type": "string", "default": "Sachsen-Anhalt" }, - "country_de_region_sh": { "type": "string", "default": "Schleswig-Holstein" }, - "country_de_region_th": { "type": "string", "default": "Thueringen" }, - "country_gh": { "type": "string", "default": "Ghana" }, - "country_gi": { "type": "string", "default": "Gibraltar" }, - "country_gr": { "type": "string", "default": "Greece" }, - "country_gl": { "type": "string", "default": "Greenland" }, - "country_gd": { "type": "string", "default": "Grenada" }, - "country_gp": { "type": "string", "default": "Guadeloupe" }, - "country_gu": { "type": "string", "default": "Guam" }, - "country_gt": { "type": "string", "default": "Guatemala" }, - "country_gg": { "type": "string", "default": "Guernsey" }, - "country_gn": { "type": "string", "default": "Guinea" }, - "country_gw": { "type": "string", "default": "Guinea-bissau" }, - "country_gy": { "type": "string", "default": "Guyana" }, - "country_ht": { "type": "string", "default": "Haiti" }, - "country_hm": { "type": "string", "default": "Heard Island and McDonald Island" }, - "country_va": { "type": "string", "default": "Holy See (Vatican City State)" }, - "country_hn": { "type": "string", "default": "Honduras" }, - "country_hk": { "type": "string", "default": "Hong Kong" }, - "country_hu": { "type": "string", "default": "Hungary" }, - "country_is": { "type": "string", "default": "Iceland" }, - "country_in": { "type": "string", "default": "India" }, - "country_in_region_an": { - "type": "string", - "default": "Andaman and Nicobar Islands" - }, - "country_in_region_ap": { "type": "string", "default": "Andhra Pradesh" }, - "country_in_region_ar": { "type": "string", "default": "Arunachal Pradesh" }, - "country_in_region_as": { "type": "string", "default": "Assam" }, - "country_in_region_br": { "type": "string", "default": "Bihar" }, - "country_in_region_ch": { "type": "string", "default": "Chandigarh" }, - "country_in_region_ct": { "type": "string", "default": "Chhattisgarh" }, - "country_in_region_dn": { "type": "string", "default": "Dadra and Nagar Haveli" }, - "country_in_region_dd": { "type": "string", "default": "Daman and Diu" }, - "country_in_region_dl": { "type": "string", "default": "Delhi" }, - "country_in_region_ga": { "type": "string", "default": "Goa" }, - "country_in_region_gj": { "type": "string", "default": "Gujarat" }, - "country_in_region_hr": { "type": "string", "default": "Haryana" }, - "country_in_region_hp": { "type": "string", "default": "Himachal Pradesh" }, - "country_in_region_jk": { "type": "string", "default": "Jammu and Kashmir" }, - "country_in_region_jh": { "type": "string", "default": "Jharkhand" }, - "country_in_region_ka": { "type": "string", "default": "Karnataka" }, - "country_in_region_kl": { "type": "string", "default": "Kerala" }, - "country_in_region_ld": { "type": "string", "default": "Lakshadweep" }, - "country_in_region_mp": { "type": "string", "default": "Madhya Pradesh" }, - "country_in_region_mh": { "type": "string", "default": "Maharashtra" }, - "country_in_region_mn": { "type": "string", "default": "Manipur" }, - "country_in_region_ml": { "type": "string", "default": "Meghalaya" }, - "country_in_region_mz": { "type": "string", "default": "Mizoram" }, - "country_in_region_nl": { "type": "string", "default": "Nagaland" }, - "country_in_region_or": { "type": "string", "default": "Odisha" }, - "country_in_region_py": { "type": "string", "default": "Puducherry" }, - "country_in_region_pb": { "type": "string", "default": "Punjab" }, - "country_in_region_rj": { "type": "string", "default": "Rajasthan" }, - "country_in_region_sk": { "type": "string", "default": "Sikkim" }, - "country_in_region_tn": { "type": "string", "default": "Tamil Nadu" }, - "country_in_region_tg": { "type": "string", "default": "Telangana" }, - "country_in_region_tr": { "type": "string", "default": "Tripura" }, - "country_in_region_ut": { "type": "string", "default": "Uttarakhand" }, - "country_in_region_up": { "type": "string", "default": "Uttar Pradesh" }, - "country_in_region_wb": { "type": "string", "default": "West Bengal" }, - "country_id": { "type": "string", "default": "Indonesia" }, - "country_ir": { "type": "string", "default": "Iran, Islamic Republic of" }, - "country_iq": { "type": "string", "default": "Iraq" }, - "country_ie": { "type": "string", "default": "Ireland" }, - "country_ie_region_cw": { "type": "string", "default": "Carlow" }, - "country_ie_region_cn": { "type": "string", "default": "Cavan" }, - "country_ie_region_ce": { "type": "string", "default": "Clare" }, - "country_ie_region_co": { "type": "string", "default": "Cork" }, - "country_ie_region_dl": { "type": "string", "default": "Donegal" }, - "country_ie_region_d": { "type": "string", "default": "Dublin" }, - "country_ie_region_g": { "type": "string", "default": "Galway" }, - "country_ie_region_ky": { "type": "string", "default": "Kerry" }, - "country_ie_region_ke": { "type": "string", "default": "Kildare" }, - "country_ie_region_kk": { "type": "string", "default": "Kilkenny" }, - "country_ie_region_ls": { "type": "string", "default": "Laois" }, - "country_ie_region_lm": { "type": "string", "default": "Leitrim" }, - "country_ie_region_lk": { "type": "string", "default": "Limerick" }, - "country_ie_region_ld": { "type": "string", "default": "Longford" }, - "country_ie_region_lh": { "type": "string", "default": "Louth" }, - "country_ie_region_mo": { "type": "string", "default": "Mayo" }, - "country_ie_region_mh": { "type": "string", "default": "Meath" }, - "country_ie_region_mn": { "type": "string", "default": "Monaghan" }, - "country_ie_region_oy": { "type": "string", "default": "Offaly" }, - "country_ie_region_rn": { "type": "string", "default": "Roscommon" }, - "country_ie_region_so": { "type": "string", "default": "Sligo" }, - "country_ie_region_ta": { "type": "string", "default": "Tipperary" }, - "country_ie_region_wd": { "type": "string", "default": "Waterford" }, - "country_ie_region_wh": { "type": "string", "default": "Westmeath" }, - "country_ie_region_wx": { "type": "string", "default": "Wexford" }, - "country_ie_region_ww": { "type": "string", "default": "Wicklow" }, - "country_im": { "type": "string", "default": "Isle of Man" }, - "country_il": { "type": "string", "default": "Israel" }, - "country_it": { "type": "string", "default": "Italy" }, - "country_jm": { "type": "string", "default": "Jamaica" }, - "country_jp": { "type": "string", "default": "Japan" }, - "country_jp_region_10": { "type": "string", "default": "Gunma" }, - "country_jp_region_11": { "type": "string", "default": "Saitama" }, - "country_jp_region_12": { "type": "string", "default": "Chiba" }, - "country_jp_region_13": { "type": "string", "default": "Tokyo" }, - "country_jp_region_14": { "type": "string", "default": "Kanagawa" }, - "country_jp_region_15": { "type": "string", "default": "Niigata" }, - "country_jp_region_16": { "type": "string", "default": "Toyama" }, - "country_jp_region_17": { "type": "string", "default": "Ishikawa" }, - "country_jp_region_18": { "type": "string", "default": "Fukui" }, - "country_jp_region_19": { "type": "string", "default": "Yamanashi" }, - "country_jp_region_20": { "type": "string", "default": "Nagano" }, - "country_jp_region_21": { "type": "string", "default": "Gifu" }, - "country_jp_region_22": { "type": "string", "default": "Shizuoka" }, - "country_jp_region_23": { "type": "string", "default": "Aichi" }, - "country_jp_region_24": { "type": "string", "default": "Mie" }, - "country_jp_region_25": { "type": "string", "default": "Shiga" }, - "country_jp_region_26": { "type": "string", "default": "Kyoto" }, - "country_jp_region_27": { "type": "string", "default": "Osaka" }, - "country_jp_region_28": { "type": "string", "default": "Hyogo" }, - "country_jp_region_29": { "type": "string", "default": "Nara" }, - "country_jp_region_30": { "type": "string", "default": "Wakayama" }, - "country_jp_region_31": { "type": "string", "default": "Tottori" }, - "country_jp_region_32": { "type": "string", "default": "Shimane" }, - "country_jp_region_33": { "type": "string", "default": "Okayama" }, - "country_jp_region_34": { "type": "string", "default": "Hiroshima" }, - "country_jp_region_35": { "type": "string", "default": "Yamaguchi" }, - "country_jp_region_36": { "type": "string", "default": "Tokushima" }, - "country_jp_region_37": { "type": "string", "default": "Kagawa" }, - "country_jp_region_38": { "type": "string", "default": "Ehime" }, - "country_jp_region_39": { "type": "string", "default": "Kochi" }, - "country_jp_region_40": { "type": "string", "default": "Fukuoka" }, - "country_jp_region_41": { "type": "string", "default": "Saga" }, - "country_jp_region_42": { "type": "string", "default": "Nagasaki" }, - "country_jp_region_43": { "type": "string", "default": "Kumamoto" }, - "country_jp_region_44": { "type": "string", "default": "Oita" }, - "country_jp_region_45": { "type": "string", "default": "Miyazaki" }, - "country_jp_region_46": { "type": "string", "default": "Kagoshima" }, - "country_jp_region_47": { "type": "string", "default": "Okinawa" }, - "country_jp_region_05": { "type": "string", "default": "Akita" }, - "country_jp_region_02": { "type": "string", "default": "Aomori" }, - "country_jp_region_07": { "type": "string", "default": "Fukushima" }, - "country_jp_region_01": { "type": "string", "default": "Hokkaido" }, - "country_jp_region_08": { "type": "string", "default": "Ibaraki" }, - "country_jp_region_03": { "type": "string", "default": "Iwate" }, - "country_jp_region_04": { "type": "string", "default": "Miyagi" }, - "country_jp_region_09": { "type": "string", "default": "Tochigi" }, - "country_jp_region_06": { "type": "string", "default": "Yamagata" }, - "country_je": { "type": "string", "default": "Jersey" }, - "country_jo": { "type": "string", "default": "Jordan" }, - "country_kz": { "type": "string", "default": "Kazakhstan" }, - "country_ke": { "type": "string", "default": "Kenya" }, - "country_ki": { "type": "string", "default": "Kiribati" }, - "country_kp": { - "type": "string", - "default": "Korea, Democratic People's Republic of" - }, - "country_kr": { "type": "string", "default": "Korea, Republic of" }, - "country_kw": { "type": "string", "default": "Kuwait" }, - "country_kg": { "type": "string", "default": "Kyrgyzstan" }, - "country_la": { "type": "string", "default": "Lao People's Democratic Republic" }, - "country_lv": { "type": "string", "default": "Latvia" }, - "country_lb": { "type": "string", "default": "Lebanon" }, - "country_ls": { "type": "string", "default": "Lesotho" }, - "country_lr": { "type": "string", "default": "Liberia" }, - "country_ly": { "type": "string", "default": "Libya" }, - "country_li": { "type": "string", "default": "Liechtenstein" }, - "country_lt": { "type": "string", "default": "Lithuania" }, - "country_lu": { "type": "string", "default": "Luxembourg" }, - "country_mo": { - "type": "string", - "default": "Macau Special Administrative Region of China" - }, - "country_mk": { "type": "string", "default": "North Macedonia" }, - "country_mg": { "type": "string", "default": "Madagascar" }, - "country_mw": { "type": "string", "default": "Malawi" }, - "country_my": { "type": "string", "default": "Malaysia" }, - "country_mv": { "type": "string", "default": "Maldives" }, - "country_ml": { "type": "string", "default": "Mali" }, - "country_mt": { "type": "string", "default": "Malta" }, - "country_mh": { "type": "string", "default": "Marshall Islands" }, - "country_mq": { "type": "string", "default": "Martinique" }, - "country_mr": { "type": "string", "default": "Mauritania" }, - "country_mu": { "type": "string", "default": "Mauritius" }, - "country_yt": { "type": "string", "default": "Mayotte" }, - "country_mx": { "type": "string", "default": "Mexico" }, - "country_fm": { "type": "string", "default": "Micronesia, Federated States of" }, - "country_md": { "type": "string", "default": "Moldova, Republic of" }, - "country_mc": { "type": "string", "default": "Monaco" }, - "country_mn": { "type": "string", "default": "Mongolia" }, - "country_me": { "type": "string", "default": "Montenegro" }, - "country_ms": { "type": "string", "default": "Montserrat" }, - "country_ma": { "type": "string", "default": "Morocco" }, - "country_mz": { "type": "string", "default": "Mozambique" }, - "country_mm": { "type": "string", "default": "Myanmar" }, - "country_na": { "type": "string", "default": "Namibia" }, - "country_nr": { "type": "string", "default": "Nauru" }, - "country_np": { "type": "string", "default": "Nepal" }, - "country_nl": { "type": "string", "default": "Netherlands" }, - "country_nc": { "type": "string", "default": "New Caledonia" }, - "country_nz": { "type": "string", "default": "New Zealand" }, - "country_ni": { "type": "string", "default": "Nicaragua" }, - "country_ne": { "type": "string", "default": "Niger" }, - "country_ng": { "type": "string", "default": "Nigeria" }, - "country_nu": { "type": "string", "default": "Niue" }, - "country_nf": { "type": "string", "default": "Norfolk Island" }, - "country_mp": { "type": "string", "default": "Northern Mariana Islands" }, - "country_no": { "type": "string", "default": "Norway" }, - "country_no_region_10": { "type": "string", "default": "Vest-Agder" }, - "country_no_region_11": { "type": "string", "default": "Rogaland" }, - "country_no_region_12": { "type": "string", "default": "Hordaland" }, - "country_no_region_14": { "type": "string", "default": "Sogn og Fjordane" }, - "country_no_region_15": { "type": "string", "default": "Møre og Romsdal" }, - "country_no_region_16": { "type": "string", "default": "Sør-Trøndelag" }, - "country_no_region_17": { "type": "string", "default": "Nord-Trøndelag" }, - "country_no_region_18": { "type": "string", "default": "Nordland" }, - "country_no_region_19": { "type": "string", "default": "Troms" }, - "country_no_region_20": { "type": "string", "default": "Finnmark" }, - "country_no_region_30": { "type": "string", "default": "Viken" }, - "country_no_region_34": { "type": "string", "default": "Innlandet" }, - "country_no_region_38": { "type": "string", "default": "Vestfold og Telemark" }, - "country_no_region_42": { "type": "string", "default": "Agder" }, - "country_no_region_46": { "type": "string", "default": "Vestland" }, - "country_no_region_50": { "type": "string", "default": "Trøndelag" }, - "country_no_region_54": { "type": "string", "default": "Troms og Finnmark" }, - "country_no_region_01": { "type": "string", "default": "Østfold" }, - "country_no_region_02": { "type": "string", "default": "Akershus" }, - "country_no_region_03": { "type": "string", "default": "Oslo" }, - "country_no_region_04": { "type": "string", "default": "Hedmark" }, - "country_no_region_05": { "type": "string", "default": "Oppland" }, - "country_no_region_06": { "type": "string", "default": "Buskerud" }, - "country_no_region_07": { "type": "string", "default": "Vestfold" }, - "country_no_region_08": { "type": "string", "default": "Telemark" }, - "country_no_region_09": { "type": "string", "default": "Aust-Agder" }, - "country_om": { "type": "string", "default": "Oman" }, - "country_pk": { "type": "string", "default": "Pakistan" }, - "country_pw": { "type": "string", "default": "Palau" }, - "country_ps": { "type": "string", "default": "Palestine, State of" }, - "country_pa": { "type": "string", "default": "Panama" }, - "country_pg": { "type": "string", "default": "Papua New Guinea" }, - "country_py": { "type": "string", "default": "Paraguay" }, - "country_pe": { "type": "string", "default": "Peru" }, - "country_ph": { "type": "string", "default": "Philippines" }, - "country_pn": { "type": "string", "default": "Pitcairn" }, - "country_pl": { "type": "string", "default": "Poland" }, - "country_pt": { "type": "string", "default": "Portugal" }, - "country_pr": { "type": "string", "default": "Puerto Rico" }, - "country_qa": { "type": "string", "default": "Qatar" }, - "country_re": { "type": "string", "default": "Réunion" }, - "country_ro": { "type": "string", "default": "Romania" }, - "country_ru": { "type": "string", "default": "Russian Federation" }, - "country_rw": { "type": "string", "default": "Rwanda" }, - "country_bl": { "type": "string", "default": "Saint Barthélemy" }, - "country_sh": { - "type": "string", - "default": "Saint Helena, Ascension and Tristan da Cunha" - }, - "country_kn": { "type": "string", "default": "Saint Kitts and Nevis" }, - "country_lc": { "type": "string", "default": "Saint Lucia" }, - "country_mf": { "type": "string", "default": "Saint Martin" }, - "country_pm": { "type": "string", "default": "Saint Pierre and Miquelon" }, - "country_vc": { "type": "string", "default": "Saint Vincent and the Grenadines" }, - "country_ws": { "type": "string", "default": "Samoa" }, - "country_sm": { "type": "string", "default": "San Marino" }, - "country_ss": { "type": "string", "default": "South Sudan" }, - "country_st": { "type": "string", "default": "Sao Tome and Principe" }, - "country_sa": { "type": "string", "default": "Saudi Arabia" }, - "country_sn": { "type": "string", "default": "Senegal" }, - "country_rs": { "type": "string", "default": "Serbia" }, - "country_sc": { "type": "string", "default": "Seychelles" }, - "country_sl": { "type": "string", "default": "Sierra Leone" }, - "country_sg": { "type": "string", "default": "Singapore" }, - "country_sk": { "type": "string", "default": "Slovakia" }, - "country_si": { "type": "string", "default": "Slovenia" }, - "country_sb": { "type": "string", "default": "Solomon Islands" }, - "country_so": { "type": "string", "default": "Somalia" }, - "country_za": { "type": "string", "default": "South Africa" }, - "country_gs": { - "type": "string", - "default": "South Georgia and the South Sandwich Islands" - }, - "country_es": { "type": "string", "default": "Spain" }, - "country_es_region_a coruna": { "type": "string", "default": "A Coruna" }, - "country_es_region_alava": { "type": "string", "default": "Alava" }, - "country_es_region_albacete": { "type": "string", "default": "Albacete" }, - "country_es_region_alicante": { "type": "string", "default": "Alicante" }, - "country_es_region_almeria": { "type": "string", "default": "Almeria" }, - "country_es_region_asturias": { "type": "string", "default": "Asturias" }, - "country_es_region_avila": { "type": "string", "default": "Avila" }, - "country_es_region_badajoz": { "type": "string", "default": "Badajoz" }, - "country_es_region_baleares": { "type": "string", "default": "Baleares" }, - "country_es_region_barcelona": { "type": "string", "default": "Barcelona" }, - "country_es_region_burgos": { "type": "string", "default": "Burgos" }, - "country_es_region_caceres": { "type": "string", "default": "Caceres" }, - "country_es_region_cadiz": { "type": "string", "default": "Cadiz" }, - "country_es_region_cn": { "type": "string", "default": "Canarias" }, - "country_es_region_cantabria": { "type": "string", "default": "Cantabria" }, - "country_es_region_castellon": { "type": "string", "default": "Castellon" }, - "country_es_region_ceuta": { "type": "string", "default": "Ceuta" }, - "country_es_region_ciudad real": { "type": "string", "default": "Ciudad Real" }, - "country_es_region_cordoba": { "type": "string", "default": "Cordoba" }, - "country_es_region_cuenca": { "type": "string", "default": "Cuenca" }, - "country_es_region_gipuzkoa": { "type": "string", "default": "Gipuzkoa" }, - "country_es_region_girona": { "type": "string", "default": "Girona" }, - "country_es_region_granada": { "type": "string", "default": "Granada" }, - "country_es_region_guadalajara": { "type": "string", "default": "Guadalajara" }, - "country_es_region_guipuzcoa": { "type": "string", "default": "Guipuzcoa" }, - "country_es_region_huelva": { "type": "string", "default": "Huelva" }, - "country_es_region_huesca": { "type": "string", "default": "Huesca" }, - "country_es_region_jaen": { "type": "string", "default": "Jaen" }, - "country_es_region_la rioja": { "type": "string", "default": "La Rioja" }, - "country_es_region_las palmas": { "type": "string", "default": "Las Palmas" }, - "country_es_region_leon": { "type": "string", "default": "Leon" }, - "country_es_region_lleida": { "type": "string", "default": "Lleida" }, - "country_es_region_lugo": { "type": "string", "default": "Lugo" }, - "country_es_region_madrid": { "type": "string", "default": "Madrid" }, - "country_es_region_malaga": { "type": "string", "default": "Malaga" }, - "country_es_region_melilla": { "type": "string", "default": "Melilla" }, - "country_es_region_murcia": { "type": "string", "default": "Murcia" }, - "country_es_region_navarra": { "type": "string", "default": "Navarra" }, - "country_es_region_ourense": { "type": "string", "default": "Ourense" }, - "country_es_region_palencia": { "type": "string", "default": "Palencia" }, - "country_es_region_pontevedra": { "type": "string", "default": "Pontevedra" }, - "country_es_region_salamanca": { "type": "string", "default": "Salamanca" }, - "country_es_region_santa cruz de tenerife": { - "type": "string", - "default": "Santa Cruz de Tenerife" - }, - "country_es_region_segovia": { "type": "string", "default": "Segovia" }, - "country_es_region_sevilla": { "type": "string", "default": "Sevilla" }, - "country_es_region_soria": { "type": "string", "default": "Soria" }, - "country_es_region_tarragona": { "type": "string", "default": "Tarragona" }, - "country_es_region_teruel": { "type": "string", "default": "Teruel" }, - "country_es_region_toledo": { "type": "string", "default": "Toledo" }, - "country_es_region_valencia": { "type": "string", "default": "Valencia" }, - "country_es_region_valladolid": { "type": "string", "default": "Valladolid" }, - "country_es_region_vizcaya": { "type": "string", "default": "Biscay" }, - "country_es_region_zamora": { "type": "string", "default": "Zamora" }, - "country_es_region_zaragoza": { "type": "string", "default": "Zaragoza" }, - "country_lk": { "type": "string", "default": "Sri Lanka" }, - "country_sd": { "type": "string", "default": "Sudan" }, - "country_sr": { "type": "string", "default": "Suriname" }, - "country_sj": { "type": "string", "default": "Svalbard and Jan Mayen" }, - "country_sz": { "type": "string", "default": "Eswatini" }, - "country_se": { "type": "string", "default": "Sweden" }, - "country_ch": { "type": "string", "default": "Switzerland" }, - "country_ch_region_ag": { "type": "string", "default": "Aargau" }, - "country_ch_region_ar": { "type": "string", "default": "Appenzell Ausserrhoden" }, - "country_ch_region_ai": { "type": "string", "default": "Appenzell Innerrhoden" }, - "country_ch_region_bl": { "type": "string", "default": "Basel-Landschaft" }, - "country_ch_region_bs": { "type": "string", "default": "Basel-Stadt" }, - "country_ch_region_be": { "type": "string", "default": "Bern" }, - "country_ch_region_fr": { "type": "string", "default": "Freiburg" }, - "country_ch_region_ge": { "type": "string", "default": "Genf" }, - "country_ch_region_gl": { "type": "string", "default": "Glarus" }, - "country_ch_region_gr": { "type": "string", "default": "Graubuenden" }, - "country_ch_region_ju": { "type": "string", "default": "Jura" }, - "country_ch_region_lu": { "type": "string", "default": "Luzern" }, - "country_ch_region_ne": { "type": "string", "default": "Neuenburg" }, - "country_ch_region_nw": { "type": "string", "default": "Nidwalden" }, - "country_ch_region_ow": { "type": "string", "default": "Obwalden" }, - "country_ch_region_sh": { "type": "string", "default": "Schaffhausen" }, - "country_ch_region_sz": { "type": "string", "default": "Schwyz" }, - "country_ch_region_so": { "type": "string", "default": "Solothurn" }, - "country_ch_region_sg": { "type": "string", "default": "St. Gallen" }, - "country_ch_region_ti": { "type": "string", "default": "Tessin" }, - "country_ch_region_tg": { "type": "string", "default": "Thurgau" }, - "country_ch_region_ur": { "type": "string", "default": "Uri" }, - "country_ch_region_vs": { "type": "string", "default": "Valais" }, - "country_ch_region_vd": { "type": "string", "default": "Vaud" }, - "country_ch_region_zh": { "type": "string", "default": "Zurich" }, - "country_ch_region_zg": { "type": "string", "default": "Zug" }, - "country_sy": { "type": "string", "default": "Syrian Arab Republic" }, - "country_tw": { "type": "string", "default": "Taiwan" }, - "country_tj": { "type": "string", "default": "Tajikistan" }, - "country_tz": { "type": "string", "default": "Tanzania, United Republic of" }, - "country_th": { "type": "string", "default": "Thailand" }, - "country_tl": { "type": "string", "default": "Timor-Leste" }, - "country_tg": { "type": "string", "default": "Togo" }, - "country_tk": { "type": "string", "default": "Tokelau" }, - "country_to": { "type": "string", "default": "Tonga" }, - "country_tt": { "type": "string", "default": "Trinidad and Tobago" }, - "country_tn": { "type": "string", "default": "Tunisia" }, - "country_tr": { "type": "string", "default": "Turkey" }, - "country_tm": { "type": "string", "default": "Turkmenistan" }, - "country_tc": { "type": "string", "default": "Turks and Caicos Islands" }, - "country_tv": { "type": "string", "default": "Tuvalu" }, - "country_ug": { "type": "string", "default": "Uganda" }, - "country_ua": { "type": "string", "default": "Ukraine" }, - "country_ae": { "type": "string", "default": "United Arab Emirates" }, - "country_gb": { "type": "string", "default": "United Kingdom" }, - "country_us": { "type": "string", "default": "United States" }, - "country_us_region_al": { "type": "string", "default": "Alabama" }, - "country_us_region_ak": { "type": "string", "default": "Alaska" }, - "country_us_region_as": { "type": "string", "default": "American Samoa" }, - "country_us_region_az": { "type": "string", "default": "Arizona" }, - "country_us_region_ar": { "type": "string", "default": "Arkansas" }, - "country_us_region_af": { "type": "string", "default": "Armed Forces Africa" }, - "country_us_region_aa": { "type": "string", "default": "Armed Forces Americas" }, - "country_us_region_ac": { "type": "string", "default": "Armed Forces Canada" }, - "country_us_region_ae": { "type": "string", "default": "Armed Forces Europe" }, - "country_us_region_am": { "type": "string", "default": "Armed Forces Middle East" }, - "country_us_region_ap": { "type": "string", "default": "Armed Forces Pacific" }, - "country_us_region_ca": { "type": "string", "default": "California" }, - "country_us_region_co": { "type": "string", "default": "Colorado" }, - "country_us_region_ct": { "type": "string", "default": "Connecticut" }, - "country_us_region_de": { "type": "string", "default": "Delaware" }, - "country_us_region_dc": { "type": "string", "default": "Washington DC" }, - "country_us_region_fm": { - "type": "string", - "default": "Federated States Of Micronesia" - }, - "country_us_region_fl": { "type": "string", "default": "Florida" }, - "country_us_region_ga": { "type": "string", "default": "Georgia" }, - "country_us_region_gu": { "type": "string", "default": "Guam" }, - "country_us_region_hi": { "type": "string", "default": "Hawaii" }, - "country_us_region_id": { "type": "string", "default": "Idaho" }, - "country_us_region_il": { "type": "string", "default": "Illinois" }, - "country_us_region_in": { "type": "string", "default": "Indiana" }, - "country_us_region_ia": { "type": "string", "default": "Iowa" }, - "country_us_region_ks": { "type": "string", "default": "Kansas" }, - "country_us_region_ky": { "type": "string", "default": "Kentucky" }, - "country_us_region_la": { "type": "string", "default": "Louisiana" }, - "country_us_region_me": { "type": "string", "default": "Maine" }, - "country_us_region_mh": { "type": "string", "default": "Marshall Islands" }, - "country_us_region_md": { "type": "string", "default": "Maryland" }, - "country_us_region_ma": { "type": "string", "default": "Massachusetts" }, - "country_us_region_mi": { "type": "string", "default": "Michigan" }, - "country_us_region_mn": { "type": "string", "default": "Minnesota" }, - "country_us_region_ms": { "type": "string", "default": "Mississippi" }, - "country_us_region_mo": { "type": "string", "default": "Missouri" }, - "country_us_region_mt": { "type": "string", "default": "Montana" }, - "country_us_region_ne": { "type": "string", "default": "Nebraska" }, - "country_us_region_nv": { "type": "string", "default": "Nevada" }, - "country_us_region_nh": { "type": "string", "default": "New Hampshire" }, - "country_us_region_nj": { "type": "string", "default": "New Jersey" }, - "country_us_region_nm": { "type": "string", "default": "New Mexico" }, - "country_us_region_ny": { "type": "string", "default": "New York" }, - "country_us_region_nc": { "type": "string", "default": "North Carolina" }, - "country_us_region_nd": { "type": "string", "default": "North Dakota" }, - "country_us_region_mp": { "type": "string", "default": "Northern Mariana Islands" }, - "country_us_region_oh": { "type": "string", "default": "Ohio" }, - "country_us_region_ok": { "type": "string", "default": "Oklahoma" }, - "country_us_region_or": { "type": "string", "default": "Oregon" }, - "country_us_region_pa": { "type": "string", "default": "Pennsylvania" }, - "country_us_region_pr": { "type": "string", "default": "Puerto Rico" }, - "country_us_region_ri": { "type": "string", "default": "Rhode Island" }, - "country_us_region_sc": { "type": "string", "default": "South Carolina" }, - "country_us_region_sd": { "type": "string", "default": "South Dakota" }, - "country_us_region_tn": { "type": "string", "default": "Tennessee" }, - "country_us_region_tx": { "type": "string", "default": "Texas" }, - "country_us_region_ut": { "type": "string", "default": "Utah" }, - "country_us_region_vt": { "type": "string", "default": "Vermont" }, - "country_us_region_vi": { "type": "string", "default": "Virgin Islands" }, - "country_us_region_va": { "type": "string", "default": "Virginia" }, - "country_us_region_wa": { "type": "string", "default": "Washington" }, - "country_us_region_wv": { "type": "string", "default": "West Virginia" }, - "country_us_region_wi": { "type": "string", "default": "Wisconsin" }, - "country_us_region_wy": { "type": "string", "default": "Wyoming" }, - "country_um": { - "type": "string", - "default": "United States Minor Outlying Islands" - }, - "country_uy": { "type": "string", "default": "Uruguay" }, - "country_uz": { "type": "string", "default": "Uzbekistan" }, - "country_vu": { "type": "string", "default": "Vanuatu" }, - "country_ve": { "type": "string", "default": "Venezuela" }, - "country_vn": { "type": "string", "default": "Vietnam" }, - "country_vg": { "type": "string", "default": "Virgin Islands, British" }, - "country_vi": { "type": "string", "default": "Virgin Islands, U.S." }, - "country_wf": { "type": "string", "default": "Wallis and Futuna Islands" }, - "country_eh": { "type": "string", "default": "Western Sahara" }, - "country_ye": { "type": "string", "default": "Yemen" }, - "country_zm": { "type": "string", "default": "Zambia" }, - "country_zw": { "type": "string", "default": "Zimbabwe" } - }, - "required": [ - "address-name", - "first-name", - "last-name", - "company", - "phone", - "address-one", - "address-two", - "city", - "postal-code", - "country", - "region", - "timestamps", - "delete", - "create", - "spinner", - "country_af", - "country_ax", - "country_al", - "country_dz", - "country_as", - "country_ad", - "country_ao", - "country_ai", - "country_aq", - "country_ag", - "country_ar", - "country_am", - "country_aw", - "country_au", - "country_au_region_act", - "country_au_region_nsw", - "country_au_region_nt", - "country_au_region_qld", - "country_au_region_sa", - "country_au_region_tas", - "country_au_region_vic", - "country_au_region_wa", - "country_at", - "country_at_region_bl", - "country_at_region_kn", - "country_at_region_no", - "country_at_region_oo", - "country_at_region_sb", - "country_at_region_st", - "country_at_region_ti", - "country_at_region_vb", - "country_at_region_wi", - "country_az", - "country_bs", - "country_bh", - "country_bd", - "country_bb", - "country_by", - "country_be", - "country_bz", - "country_bj", - "country_bm", - "country_bt", - "country_bo", - "country_bq", - "country_bq_region_bo", - "country_bq_region_sa", - "country_bq_region_se", - "country_ba", - "country_bw", - "country_bv", - "country_br", - "country_io", - "country_bn", - "country_bg", - "country_bf", - "country_bi", - "country_kh", - "country_cm", - "country_ca", - "country_ca_region_ab", - "country_ca_region_bc", - "country_ca_region_mb", - "country_ca_region_nb", - "country_ca_region_nl", - "country_ca_region_nt", - "country_ca_region_ns", - "country_ca_region_nu", - "country_ca_region_on", - "country_ca_region_pe", - "country_ca_region_qc", - "country_ca_region_sk", - "country_ca_region_yt", - "country_cv", - "country_cw", - "country_ky", - "country_cf", - "country_td", - "country_cl", - "country_cn", - "country_cx", - "country_cc", - "country_co", - "country_km", - "country_cg", - "country_cd", - "country_ck", - "country_cr", - "country_ci", - "country_hr", - "country_cu", - "country_cy", - "country_cz", - "country_dk", - "country_dj", - "country_dm", - "country_do", - "country_ec", - "country_eg", - "country_sv", - "country_sx", - "country_gq", - "country_er", - "country_ee", - "country_et", - "country_fk", - "country_fo", - "country_fj", - "country_fi", - "country_fr", - "country_gf", - "country_pf", - "country_tf", - "country_ga", - "country_gm", - "country_ge", - "country_de", - "country_de_region_bw", - "country_de_region_by", - "country_de_region_be", - "country_de_region_bb", - "country_de_region_hb", - "country_de_region_hh", - "country_de_region_he", - "country_de_region_mv", - "country_de_region_ni", - "country_de_region_nw", - "country_de_region_rp", - "country_de_region_sl", - "country_de_region_sn", - "country_de_region_st", - "country_de_region_sh", - "country_de_region_th", - "country_gh", - "country_gi", - "country_gr", - "country_gl", - "country_gd", - "country_gp", - "country_gu", - "country_gt", - "country_gg", - "country_gn", - "country_gw", - "country_gy", - "country_ht", - "country_hm", - "country_va", - "country_hn", - "country_hk", - "country_hu", - "country_is", - "country_in", - "country_in_region_an", - "country_in_region_ap", - "country_in_region_ar", - "country_in_region_as", - "country_in_region_br", - "country_in_region_ch", - "country_in_region_ct", - "country_in_region_dn", - "country_in_region_dd", - "country_in_region_dl", - "country_in_region_ga", - "country_in_region_gj", - "country_in_region_hr", - "country_in_region_hp", - "country_in_region_jk", - "country_in_region_jh", - "country_in_region_ka", - "country_in_region_kl", - "country_in_region_ld", - "country_in_region_mp", - "country_in_region_mh", - "country_in_region_mn", - "country_in_region_ml", - "country_in_region_mz", - "country_in_region_nl", - "country_in_region_or", - "country_in_region_py", - "country_in_region_pb", - "country_in_region_rj", - "country_in_region_sk", - "country_in_region_tn", - "country_in_region_tg", - "country_in_region_tr", - "country_in_region_ut", - "country_in_region_up", - "country_in_region_wb", - "country_id", - "country_ir", - "country_iq", - "country_ie", - "country_ie_region_cw", - "country_ie_region_cn", - "country_ie_region_ce", - "country_ie_region_co", - "country_ie_region_dl", - "country_ie_region_d", - "country_ie_region_g", - "country_ie_region_ky", - "country_ie_region_ke", - "country_ie_region_kk", - "country_ie_region_ls", - "country_ie_region_lm", - "country_ie_region_lk", - "country_ie_region_ld", - "country_ie_region_lh", - "country_ie_region_mo", - "country_ie_region_mh", - "country_ie_region_mn", - "country_ie_region_oy", - "country_ie_region_rn", - "country_ie_region_so", - "country_ie_region_ta", - "country_ie_region_wd", - "country_ie_region_wh", - "country_ie_region_wx", - "country_ie_region_ww", - "country_im", - "country_il", - "country_it", - "country_jm", - "country_jp", - "country_jp_region_10", - "country_jp_region_11", - "country_jp_region_12", - "country_jp_region_13", - "country_jp_region_14", - "country_jp_region_15", - "country_jp_region_16", - "country_jp_region_17", - "country_jp_region_18", - "country_jp_region_19", - "country_jp_region_20", - "country_jp_region_21", - "country_jp_region_22", - "country_jp_region_23", - "country_jp_region_24", - "country_jp_region_25", - "country_jp_region_26", - "country_jp_region_27", - "country_jp_region_28", - "country_jp_region_29", - "country_jp_region_30", - "country_jp_region_31", - "country_jp_region_32", - "country_jp_region_33", - "country_jp_region_34", - "country_jp_region_35", - "country_jp_region_36", - "country_jp_region_37", - "country_jp_region_38", - "country_jp_region_39", - "country_jp_region_40", - "country_jp_region_41", - "country_jp_region_42", - "country_jp_region_43", - "country_jp_region_44", - "country_jp_region_45", - "country_jp_region_46", - "country_jp_region_47", - "country_jp_region_05", - "country_jp_region_02", - "country_jp_region_07", - "country_jp_region_01", - "country_jp_region_08", - "country_jp_region_03", - "country_jp_region_04", - "country_jp_region_09", - "country_jp_region_06", - "country_je", - "country_jo", - "country_kz", - "country_ke", - "country_ki", - "country_kp", - "country_kr", - "country_kw", - "country_kg", - "country_la", - "country_lv", - "country_lb", - "country_ls", - "country_lr", - "country_ly", - "country_li", - "country_lt", - "country_lu", - "country_mo", - "country_mk", - "country_mg", - "country_mw", - "country_my", - "country_mv", - "country_ml", - "country_mt", - "country_mh", - "country_mq", - "country_mr", - "country_mu", - "country_yt", - "country_mx", - "country_fm", - "country_md", - "country_mc", - "country_mn", - "country_me", - "country_ms", - "country_ma", - "country_mz", - "country_mm", - "country_na", - "country_nr", - "country_np", - "country_nl", - "country_nc", - "country_nz", - "country_ni", - "country_ne", - "country_ng", - "country_nu", - "country_nf", - "country_mp", - "country_no", - "country_no_region_10", - "country_no_region_11", - "country_no_region_12", - "country_no_region_14", - "country_no_region_15", - "country_no_region_16", - "country_no_region_17", - "country_no_region_18", - "country_no_region_19", - "country_no_region_20", - "country_no_region_30", - "country_no_region_34", - "country_no_region_38", - "country_no_region_42", - "country_no_region_46", - "country_no_region_50", - "country_no_region_54", - "country_no_region_01", - "country_no_region_02", - "country_no_region_03", - "country_no_region_04", - "country_no_region_05", - "country_no_region_06", - "country_no_region_07", - "country_no_region_08", - "country_no_region_09", - "country_om", - "country_pk", - "country_pw", - "country_ps", - "country_pa", - "country_pg", - "country_py", - "country_pe", - "country_ph", - "country_pn", - "country_pl", - "country_pt", - "country_pr", - "country_qa", - "country_re", - "country_ro", - "country_ru", - "country_rw", - "country_bl", - "country_sh", - "country_kn", - "country_lc", - "country_mf", - "country_pm", - "country_vc", - "country_ws", - "country_sm", - "country_ss", - "country_st", - "country_sa", - "country_sn", - "country_rs", - "country_sc", - "country_sl", - "country_sg", - "country_sk", - "country_si", - "country_sb", - "country_so", - "country_za", - "country_gs", - "country_es", - "country_es_region_a coruna", - "country_es_region_alava", - "country_es_region_albacete", - "country_es_region_alicante", - "country_es_region_almeria", - "country_es_region_asturias", - "country_es_region_avila", - "country_es_region_badajoz", - "country_es_region_baleares", - "country_es_region_barcelona", - "country_es_region_burgos", - "country_es_region_caceres", - "country_es_region_cadiz", - "country_es_region_cn", - "country_es_region_cantabria", - "country_es_region_castellon", - "country_es_region_ceuta", - "country_es_region_ciudad real", - "country_es_region_cordoba", - "country_es_region_cuenca", - "country_es_region_gipuzkoa", - "country_es_region_girona", - "country_es_region_granada", - "country_es_region_guadalajara", - "country_es_region_guipuzcoa", - "country_es_region_huelva", - "country_es_region_huesca", - "country_es_region_jaen", - "country_es_region_la rioja", - "country_es_region_las palmas", - "country_es_region_leon", - "country_es_region_lleida", - "country_es_region_lugo", - "country_es_region_madrid", - "country_es_region_malaga", - "country_es_region_melilla", - "country_es_region_murcia", - "country_es_region_navarra", - "country_es_region_ourense", - "country_es_region_palencia", - "country_es_region_pontevedra", - "country_es_region_salamanca", - "country_es_region_santa cruz de tenerife", - "country_es_region_segovia", - "country_es_region_sevilla", - "country_es_region_soria", - "country_es_region_tarragona", - "country_es_region_teruel", - "country_es_region_toledo", - "country_es_region_valencia", - "country_es_region_valladolid", - "country_es_region_vizcaya", - "country_es_region_zamora", - "country_es_region_zaragoza", - "country_lk", - "country_sd", - "country_sr", - "country_sj", - "country_sz", - "country_se", - "country_ch", - "country_ch_region_ag", - "country_ch_region_ar", - "country_ch_region_ai", - "country_ch_region_bl", - "country_ch_region_bs", - "country_ch_region_be", - "country_ch_region_fr", - "country_ch_region_ge", - "country_ch_region_gl", - "country_ch_region_gr", - "country_ch_region_ju", - "country_ch_region_lu", - "country_ch_region_ne", - "country_ch_region_nw", - "country_ch_region_ow", - "country_ch_region_sh", - "country_ch_region_sz", - "country_ch_region_so", - "country_ch_region_sg", - "country_ch_region_ti", - "country_ch_region_tg", - "country_ch_region_ur", - "country_ch_region_vs", - "country_ch_region_vd", - "country_ch_region_zh", - "country_ch_region_zg", - "country_sy", - "country_tw", - "country_tj", - "country_tz", - "country_th", - "country_tl", - "country_tg", - "country_tk", - "country_to", - "country_tt", - "country_tn", - "country_tr", - "country_tm", - "country_tc", - "country_tv", - "country_ug", - "country_ua", - "country_ae", - "country_gb", - "country_us", - "country_us_region_al", - "country_us_region_ak", - "country_us_region_as", - "country_us_region_az", - "country_us_region_ar", - "country_us_region_af", - "country_us_region_aa", - "country_us_region_ac", - "country_us_region_ae", - "country_us_region_am", - "country_us_region_ap", - "country_us_region_ca", - "country_us_region_co", - "country_us_region_ct", - "country_us_region_de", - "country_us_region_dc", - "country_us_region_fm", - "country_us_region_fl", - "country_us_region_ga", - "country_us_region_gu", - "country_us_region_hi", - "country_us_region_id", - "country_us_region_il", - "country_us_region_in", - "country_us_region_ia", - "country_us_region_ks", - "country_us_region_ky", - "country_us_region_la", - "country_us_region_me", - "country_us_region_mh", - "country_us_region_md", - "country_us_region_ma", - "country_us_region_mi", - "country_us_region_mn", - "country_us_region_ms", - "country_us_region_mo", - "country_us_region_mt", - "country_us_region_ne", - "country_us_region_nv", - "country_us_region_nh", - "country_us_region_nj", - "country_us_region_nm", - "country_us_region_ny", - "country_us_region_nc", - "country_us_region_nd", - "country_us_region_mp", - "country_us_region_oh", - "country_us_region_ok", - "country_us_region_or", - "country_us_region_pa", - "country_us_region_pr", - "country_us_region_ri", - "country_us_region_sc", - "country_us_region_sd", - "country_us_region_tn", - "country_us_region_tx", - "country_us_region_ut", - "country_us_region_vt", - "country_us_region_vi", - "country_us_region_va", - "country_us_region_wa", - "country_us_region_wv", - "country_us_region_wi", - "country_us_region_wy", - "country_um", - "country_uy", - "country_uz", - "country_vu", - "country_ve", - "country_vn", - "country_vg", - "country_vi", - "country_wf", - "country_eh", - "country_ye", - "country_zm", - "country_zw" - ] - } - }, - "required": ["close", "cancel", "header_update", "address-form"] - }, - "pagination": { - "additionalProperties": false, - "properties": { - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { "type": "string", "default": "{{from}}-{{to}} out of {{total}}" }, - "previous": { "type": "string", "default": "Previous" }, - "card": { - "additionalProperties": false, - "properties": { - "full_address": { - "type": "string", - "default": "{{address1}} {{address2}} {{city}} {{region}} {{country}} {{postal_code}}" - }, - "full_name": { "type": "string", "default": "{{first_name}} {{last_name}}" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No addresses" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["full_address", "full_name", "spinner"] - } - }, - "required": ["first", "last", "next", "pagination", "previous", "card"] - } - }, - "required": ["label", "dialog", "pagination"] - }, - "shipments": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Shipments" }, - "pagination": { - "additionalProperties": false, - "properties": { - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { "type": "string", "default": "{{from}}-{{to}} out of {{total}}" }, - "previous": { "type": "string", "default": "Previous" }, - "card": { - "additionalProperties": false, - "properties": { - "full_address": { - "type": "string", - "default": "{{ address1 }} {{ address2 }} {{ city }} {{ region }} {{ postal_code }}" - }, - "quantity": { "type": "string", "default": "Qty: {{ count }}" }, - "no_code": { "type": "string", "default": "No SKU" }, - "price": { "type": "string", "default": "{{ amount, price }}" }, - "item": { "type": "string", "default": "{{ count }} item" }, - "item_plural": { "type": "string", "default": "{{ count }} items" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No shipments" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "full_address", - "quantity", - "no_code", - "price", - "item", - "item_plural", - "spinner" - ] - } - }, - "required": ["first", "last", "next", "pagination", "previous", "card"] - } - }, - "required": ["label", "pagination"] - }, - "actions": { - "additionalProperties": false, - "properties": { - "capture": { - "additionalProperties": false, - "properties": { - "idle": { "type": "string", "default": "Capture" }, - "busy": { "type": "string", "default": "Capturing..." }, - "fail": { "type": "string", "default": "Failed to capture" }, - "confirm": { - "additionalProperties": false, - "properties": { - "header": { "type": "string", "default": "Capture" }, - "message": { - "type": "string", - "default": "Are you sure you'd like to capture this transaction?" - }, - "confirm": { "type": "string", "default": "Yes" }, - "cancel": { "type": "string", "default": "No" } - }, - "required": ["header", "message", "confirm", "cancel"] - } - }, - "required": ["idle", "busy", "fail", "confirm"] - }, - "void": { - "additionalProperties": false, - "properties": { - "idle": { "type": "string", "default": "Void" }, - "busy": { "type": "string", "default": "Voiding..." }, - "fail": { "type": "string", "default": "Failed to void" }, - "confirm": { - "additionalProperties": false, - "properties": { - "header": { "type": "string", "default": "Void" }, - "message": { - "type": "string", - "default": "Are you sure you'd like to void this transaction?" - }, - "confirm": { "type": "string", "default": "Yes" }, - "cancel": { "type": "string", "default": "No" } - }, - "required": ["header", "message", "confirm", "cancel"] - } - }, - "required": ["idle", "busy", "fail", "confirm"] - }, - "refund": { - "additionalProperties": false, - "properties": { - "idle": { "type": "string", "default": "Refund" }, - "busy": { "type": "string", "default": "Refunding..." }, - "fail": { "type": "string", "default": "Failed to refund" }, - "confirm": { - "additionalProperties": false, - "properties": { - "header": { "type": "string", "default": "Refund" }, - "message": { - "type": "string", - "default": "Are you sure you'd like to refund this transaction?" - }, - "confirm": { "type": "string", "default": "Yes" }, - "cancel": { "type": "string", "default": "No" } - }, - "required": ["header", "message", "confirm", "cancel"] - } - }, - "required": ["idle", "busy", "fail", "confirm"] - }, - "send-emails": { - "additionalProperties": false, - "properties": { - "idle": { "type": "string", "default": "Resend emails" }, - "busy": { "type": "string", "default": "Resending emails..." }, - "fail": { "type": "string", "default": "Failed to resend emails" }, - "confirm": { - "additionalProperties": false, - "properties": { - "header": { "type": "string", "default": "Send emails" }, - "message": { - "type": "string", - "default": "Are you sure you'd like to send emails for this transaction?" - }, - "confirm": { "type": "string", "default": "Yes" }, - "cancel": { "type": "string", "default": "No" } - }, - "required": ["header", "message", "confirm", "cancel"] - } - }, - "required": ["idle", "busy", "fail", "confirm"] - }, - "subscription": { - "additionalProperties": false, - "properties": { "caption": { "type": "string", "default": "Go to subscription" } }, - "required": ["caption"] - } - }, - "required": ["capture", "void", "refund", "send-emails", "subscription"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "header", - "customer", - "items", - "custom-fields", - "attributes", - "summary", - "payments", - "billing-addresses", - "shipments", - "actions", - "spinner" - ] -} diff --git a/src/static/schemas/transactions-table.json b/src/static/schemas/transactions-table.json deleted file mode 100644 index af038e0d4..000000000 --- a/src/static/schemas/transactions-table.json +++ /dev/null @@ -1,52 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "date": { "type": "string", "default": "{{value, date}}" }, - "price": { "type": "string", "default": "{{amount, price}}" }, - "receipt": { "type": "string", "default": "Receipt" }, - "transaction_approved": { "type": "string", "default": "Approved" }, - "transaction_authorized": { "type": "string", "default": "Authorized" }, - "transaction_captured": { "type": "string", "default": "Captured" }, - "transaction_completed": { "type": "string", "default": "Completed" }, - "transaction_declined": { "type": "string", "default": "Declined" }, - "transaction_pending": { "type": "string", "default": "Pending" }, - "transaction_refunded": { "type": "string", "default": "Refunded" }, - "transaction_rejected": { "type": "string", "default": "Rejected" }, - "transaction_summary": { "type": "string", "default": "{{most_expensive_item.name}}" }, - "transaction_summary_plural": { - "type": "string", - "default": "{{most_expensive_item.name}} and {{count_minus_one}} more" - }, - "transaction_verified": { "type": "string", "default": "Verified" }, - "transaction_voided": { "type": "string", "default": "Voided" }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_empty", "loading_error"] - } - }, - "required": [ - "date", - "price", - "receipt", - "transaction_approved", - "transaction_authorized", - "transaction_captured", - "transaction_completed", - "transaction_declined", - "transaction_pending", - "transaction_refunded", - "transaction_rejected", - "transaction_summary", - "transaction_summary_plural", - "transaction_verified", - "transaction_voided", - "spinner" - ] -} diff --git a/src/static/schemas/update-payment-method-form.json b/src/static/schemas/update-payment-method-form.json deleted file mode 100644 index d40857b8f..000000000 --- a/src/static/schemas/update-payment-method-form.json +++ /dev/null @@ -1,341 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "status": { - "additionalProperties": false, - "properties": { - "cc_token_success": { "type": "string", "default": "Card details saved successfully." }, - "close": { "type": "string", "default": "Close" } - }, - "required": ["cc_token_success", "close"] - }, - "error": { - "additionalProperties": false, - "properties": { - "cc_token_invalid": { - "type": "string", - "default": "Unfortunately, we couldn't save your card details. Please try again later or use a different card." - } - }, - "required": ["cc_token_invalid"] - }, - "template-set": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Template set" }, - "dialog": { - "additionalProperties": false, - "properties": { - "cancel": { "type": "string", "default": "Cancel" }, - "close": { "type": "string", "default": "Close" }, - "header": { "type": "string", "default": "Choose a template set" }, - "selection": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "" }, - "helper_text": { "type": "string", "default": "" }, - "search": { "type": "string", "default": "Search" }, - "clear": { "type": "string", "default": "Clear" }, - "pagination": { - "additionalProperties": false, - "properties": { - "search_button_text": { "type": "string", "default": "Search" }, - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { - "type": "string", - "default": "{{from}}-{{to}} out of {{total}}" - }, - "previous": { "type": "string", "default": "Previous" }, - "card": { - "additionalProperties": false, - "properties": { - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { - "type": "string", - "default": "No template sets found" - }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["spinner"] - } - }, - "required": [ - "search_button_text", - "first", - "last", - "next", - "pagination", - "previous", - "card" - ] - }, - "query-builder": { - "additionalProperties": false, - "properties": { - "filters": { "additionalProperties": false, "properties": {}, "required": [] }, - "add_or_clause": { "type": "string", "default": "Add OR clause" }, - "add_value": { "type": "string", "default": "Add value" }, - "code": { "type": "string", "default": "Code" }, - "date": { "type": "string", "default": "{{value, date}}" }, - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "delete": { "type": "string", "default": "Delete" }, - "field": { "type": "string", "default": "Field" }, - "hidden": { "type": "string", "default": "Hidden" }, - "is_defined_false": { "type": "string", "default": "Not defined" }, - "is_defined_true": { "type": "string", "default": "Defined" }, - "name": { "type": "string", "default": "Name" }, - "operator_equal": { "type": "string", "default": "Equal" }, - "operator_greaterthan": { "type": "string", "default": "Greater than" }, - "operator_greaterthanorequal": { - "type": "string", - "default": "Greater than or equal" - }, - "operator_in": { "type": "string", "default": "One of" }, - "operator_isdefined": { "type": "string", "default": "Is defined" }, - "operator_lessthan": { "type": "string", "default": "Less than" }, - "operator_lessthanorequal": { - "type": "string", - "default": "Less than or equal" - }, - "operator_not": { "type": "string", "default": "Not equal" }, - "or": { "type": "string", "default": "Or" }, - "query_builder_group": { "type": "string", "default": "Group of filters" }, - "query_builder_rule": { "type": "string", "default": "Filter" }, - "range_from": { "type": "string", "default": "From" }, - "range_to": { "type": "string", "default": "To" }, - "type": { "type": "string", "default": "Type" }, - "type_any": { "type": "string", "default": "Field of unknown type" }, - "type_attribute": { "type": "string", "default": "Key-value resource" }, - "type_date": { "type": "string", "default": "Date field" }, - "type_here": { "type": "string", "default": "Type here..." }, - "type_number": { "type": "string", "default": "Numeric field" }, - "type_string": { "type": "string", "default": "Text field" }, - "used_codes": { "type": "string", "default": "Codes used" }, - "value": { "type": "string", "default": "Value" } - }, - "required": [ - "filters", - "add_or_clause", - "add_value", - "code", - "date", - "date_created", - "date_modified", - "delete", - "field", - "hidden", - "is_defined_false", - "is_defined_true", - "name", - "operator_equal", - "operator_greaterthan", - "operator_greaterthanorequal", - "operator_in", - "operator_isdefined", - "operator_lessthan", - "operator_lessthanorequal", - "operator_not", - "or", - "query_builder_group", - "query_builder_rule", - "range_from", - "range_to", - "type", - "type_any", - "type_attribute", - "type_date", - "type_here", - "type_number", - "type_string", - "used_codes", - "value" - ] - } - }, - "required": ["label", "helper_text", "search", "clear", "pagination", "query-builder"] - } - }, - "required": ["cancel", "close", "header", "selection"] - }, - "card": { - "additionalProperties": false, - "properties": { - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "Click to select" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["spinner"] - }, - "helper_text": { - "type": "string", - "default": "Template set determines which payment gateway and tokenization service will be used to capture card details." - } - }, - "required": ["label", "dialog", "card", "helper_text"] - }, - "cc-token": { - "additionalProperties": false, - "properties": { - "tokenize": { "type": "string", "default": "Save card" }, - "payment-card-embed": { - "additionalProperties": false, - "properties": { - "stripe": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Card details" }, - "status": { - "additionalProperties": false, - "properties": { - "idle": { - "type": "string", - "default": "Your card details are securely processed by Stripe. Visit https://stripe.com to learn more." - }, - "busy": { "type": "string", "default": "Encrypting your card details..." }, - "fail": { - "type": "string", - "default": "This service is currently unavailable. Please try again later." - }, - "unsupported": { - "type": "string", - "default": "We don't support this card type. Please try a different card." - } - }, - "required": ["idle", "busy", "fail", "unsupported"] - } - }, - "required": ["label", "status"] - }, - "square": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Card details" }, - "status": { - "additionalProperties": false, - "properties": { - "idle": { - "type": "string", - "default": "Your card details are securely processed by Square. Visit https://squareup.com to learn more." - }, - "busy": { "type": "string", "default": "Encrypting your card details..." }, - "fail": { - "type": "string", - "default": "This service is currently unavailable. Please try again later." - }, - "unsupported": { - "type": "string", - "default": "We don't support this card type. Please try a different card." - } - }, - "required": ["idle", "busy", "fail", "unsupported"] - } - }, - "required": ["label", "status"] - }, - "default": { - "additionalProperties": false, - "properties": { - "cc-number": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Card number" }, - "placeholder": { "type": "string", "default": "1234 1234 1234 1234" }, - "v8n_required": { "type": "string", "default": "Enter a card number." }, - "v8n_invalid": { - "type": "string", - "default": "Check your card number – it doesn't seem to be valid." - }, - "v8n_unsupported": { - "type": "string", - "default": "We don't support this card type." - } - }, - "required": [ - "label", - "placeholder", - "v8n_required", - "v8n_invalid", - "v8n_unsupported" - ] - }, - "cc-exp": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Expires on" }, - "placeholder": { "type": "string", "default": "MM/YYYY" }, - "v8n_required": { "type": "string", "default": "Enter an expiry date." }, - "v8n_invalid": { "type": "string", "default": "Enter a date as MM/YYYY." }, - "v8n_expired": { "type": "string", "default": "Your card has expired." } - }, - "required": ["label", "placeholder", "v8n_required", "v8n_invalid", "v8n_expired"] - }, - "cc-csc": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "CSC" }, - "placeholder": { "type": "string", "default": "XXX" }, - "v8n_required": { "type": "string", "default": "Enter a security code." }, - "v8n_invalid": { "type": "string", "default": "Enter a 3-4 digits code." } - }, - "required": ["label", "placeholder", "v8n_required", "v8n_invalid"] - }, - "status": { - "additionalProperties": false, - "properties": { - "idle": { - "type": "string", - "default": "Your card details are securely processed by Foxy.io. Visit https://foxy.io to learn more." - }, - "busy": { "type": "string", "default": "Encrypting your card details..." }, - "fail": { - "type": "string", - "default": "This service is currently unavailable. Please try again later." - }, - "misconfigured": { - "type": "string", - "default": "This form is not configured correctly. If you are seeing this message as a customer, please report this issue to the store support team." - } - }, - "required": ["idle", "busy", "fail", "misconfigured"] - } - }, - "required": ["cc-number", "cc-exp", "cc-csc", "status"] - } - }, - "required": ["stripe", "square", "default"] - } - }, - "required": ["tokenize", "payment-card-embed"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" }, - "loading_empty": { - "type": "string", - "default": "This form works only with existing payment methods" - } - }, - "required": ["refresh", "loading_busy", "loading_error", "loading_empty"] - } - }, - "required": ["status", "error", "template-set", "cc-token", "spinner"] -} diff --git a/src/static/schemas/user-card.json b/src/static/schemas/user-card.json deleted file mode 100644 index c299b8e34..000000000 --- a/src/static/schemas/user-card.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "no_name": { "type": "string", "default": "No name" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["loading_busy", "loading_empty", "loading_error"] - } - }, - "required": ["no_name", "spinner"] -} diff --git a/src/static/schemas/user-form.json b/src/static/schemas/user-form.json deleted file mode 100644 index d30faeaca..000000000 --- a/src/static/schemas/user-form.json +++ /dev/null @@ -1,159 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "first-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "First name" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_required": { "type": "string", "default": "Please enter your first name" }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we can't store first names longer than 50 characters" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_too_long"] - }, - "last-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Last name" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_required": { - "type": "string", - "default": "Please enter your last name. If you don't have a last name, put any character in this field." - }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we can't store last names longer than 50 characters" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_too_long"] - }, - "email": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Email" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "This email is your login to Foxy Admin. We'll also send important notifications to this address." - }, - "v8n_required": { "type": "string", "default": "Please enter your email address" }, - "v8n_invalid_email": { "type": "string", "default": "Please enter a valid email address" }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we can't store email addresses longer than 100 characters" - } - }, - "required": [ - "label", - "placeholder", - "helper_text", - "v8n_required", - "v8n_invalid_email", - "v8n_too_long" - ] - }, - "phone": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Phone" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { - "type": "string", - "default": "We'll only use this number to contact you about your account." - }, - "v8n_too_long": { - "type": "string", - "default": "This phone number appears to be too long. Please make sure you entered it correctly." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "affiliate-id": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Affiliate ID" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { - "type": "string", - "default": "This value can only be set during user creation. Contact us if you need this value changed later." - } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "role": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Role" }, - "helper_text": { - "type": "string", - "default": "If you contact us for help, your role will help us understand how to best assist you." - }, - "option_merchant": { "type": "string", "default": "Merchant" }, - "option_backend_developer": { "type": "string", "default": "Backend Developer" }, - "option_frontend_developer": { "type": "string", "default": "Frontend Developer" }, - "option_designer": { "type": "string", "default": "Designer" } - }, - "required": [ - "label", - "helper_text", - "option_merchant", - "option_backend_developer", - "option_frontend_developer", - "option_designer" - ] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "date": { "type": "string", "default": "{{value, date}}" } - }, - "required": ["date_created", "date_modified", "date"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove this account? You won't be able to bring it back." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "first-name", - "last-name", - "email", - "phone", - "affiliate-id", - "role", - "timestamps", - "delete", - "create", - "spinner" - ] -} diff --git a/src/static/schemas/users-table.json b/src/static/schemas/users-table.json deleted file mode 100644 index ea3169d2c..000000000 --- a/src/static/schemas/users-table.json +++ /dev/null @@ -1,206 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "cancel": { "type": "string", "default": "Cancel" }, - "close": { "type": "string", "default": "Close" }, - "confirm": { "type": "string", "default": "Confirm" }, - "date": { "type": "string", "default": "{{value, date}}" }, - "save": { "type": "string", "default": "Save" }, - "time": { "type": "string", "default": "{{value, time}}" }, - "undo_cancel": { "type": "string", "default": "Review" }, - "undo_confirm": { "type": "string", "default": "Discard" }, - "undo_header": { "type": "string", "default": "Unsaved changes" }, - "undo_message": { - "type": "string", - "default": "Looks like you didn't save your changes! What would you like to do with them?" - }, - "update": { "type": "string", "default": "Update" }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_empty": { "type": "string", "default": "No data" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_empty", "loading_error"] - }, - "user-form": { - "additionalProperties": false, - "properties": { - "first-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "First name" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_required": { "type": "string", "default": "Please enter your first name" }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we can't store first names longer than 50 characters" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_too_long"] - }, - "last-name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Last name" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { "type": "string", "default": "" }, - "v8n_required": { - "type": "string", - "default": "Please enter your last name. If you don't have a last name, put any character in this field." - }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we can't store last names longer than 50 characters" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_too_long"] - }, - "email": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Email" }, - "placeholder": { "type": "string", "default": "Required" }, - "helper_text": { - "type": "string", - "default": "This email is your login to Foxy Admin. We'll also send important notifications to this address." - }, - "v8n_required": { "type": "string", "default": "Please enter your email address" }, - "v8n_invalid_email": { - "type": "string", - "default": "Please enter a valid email address" - }, - "v8n_too_long": { - "type": "string", - "default": "Unfortunately we can't store email addresses longer than 100 characters" - } - }, - "required": [ - "label", - "placeholder", - "helper_text", - "v8n_required", - "v8n_invalid_email", - "v8n_too_long" - ] - }, - "phone": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Phone" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { - "type": "string", - "default": "We'll only use this number to contact you about your account." - }, - "v8n_too_long": { - "type": "string", - "default": "This phone number appears to be too long. Please make sure you entered it correctly." - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "affiliate-id": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Affiliate ID" }, - "placeholder": { "type": "string", "default": "Optional" }, - "helper_text": { - "type": "string", - "default": "This value can only be set during user creation. Contact us if you need this value changed later." - } - }, - "required": ["label", "placeholder", "helper_text"] - }, - "role": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Role" }, - "helper_text": { - "type": "string", - "default": "If you contact us for help, your role will help us understand how to best assist you." - }, - "option_merchant": { "type": "string", "default": "Merchant" }, - "option_backend_developer": { "type": "string", "default": "Backend Developer" }, - "option_frontend_developer": { "type": "string", "default": "Frontend Developer" }, - "option_designer": { "type": "string", "default": "Designer" } - }, - "required": [ - "label", - "helper_text", - "option_merchant", - "option_backend_developer", - "option_frontend_developer", - "option_designer" - ] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "date": { "type": "string", "default": "{{value, date}}" } - }, - "required": ["date_created", "date_modified", "date"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove this account? You won't be able to bring it back." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "first-name", - "last-name", - "email", - "phone", - "affiliate-id", - "role", - "timestamps", - "delete", - "create", - "spinner" - ] - } - }, - "required": [ - "cancel", - "close", - "confirm", - "date", - "save", - "time", - "undo_cancel", - "undo_confirm", - "undo_header", - "undo_message", - "update", - "spinner", - "user-form" - ] -} diff --git a/src/static/schemas/webhook-card.json b/src/static/schemas/webhook-card.json deleted file mode 100644 index c4d939f8e..000000000 --- a/src/static/schemas/webhook-card.json +++ /dev/null @@ -1,16 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" }, - "loading_empty": { "type": "string", "default": "No data" } - }, - "required": ["loading_busy", "loading_error", "loading_empty"] - } - }, - "required": ["spinner"] -} diff --git a/src/static/schemas/webhook-form.json b/src/static/schemas/webhook-form.json deleted file mode 100644 index a17cdd86d..000000000 --- a/src/static/schemas/webhook-form.json +++ /dev/null @@ -1,228 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "name": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Name" }, - "placeholder": { "type": "string", "default": "My JSON Webhook" }, - "helper_text": { "type": "string", "default": "The name of this webhook." }, - "v8n_required": { "type": "string", "default": "Webhook name is required" }, - "v8n_too_long": { "type": "string", "default": "Webhook name cannot exceed 255 characters" } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required", "v8n_too_long"] - }, - "format": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Format" }, - "helper_text": { "type": "string", "default": "The type of this webhook." }, - "v8n_required": { "type": "string", "default": "Please select a format" } - }, - "required": ["label", "helper_text", "v8n_required"] - }, - "version": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Version" }, - "placeholder": { "type": "string", "default": "2" }, - "helper_text": { - "type": "string", - "default": "Version of the webhook. Enter 2 for latest or use other if you have specific instructions from Foxy." - }, - "v8n_required": { "type": "string", "default": "Version is required" } - }, - "required": ["label", "placeholder", "helper_text", "v8n_required"] - }, - "url": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "URL" }, - "placeholder": { "type": "string", "default": "https://example.com/webhook" }, - "helper_text": { - "type": "string", - "default": "The endpoint where we will send the webhook data." - }, - "v8n_too_long": { "type": "string", "default": "URL cannot exceed 1000 characters" } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "query": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Query" }, - "placeholder": { "type": "string", "default": "zoom=items,items:options,customer" }, - "helper_text": { - "type": "string", - "default": "The webhook payload mirrors the API, and you can include more or less data according to your needs using zoom and other modifiers." - }, - "v8n_too_long": { "type": "string", "default": "Query cannot exceed 1000 characters" } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "encryption-key": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Encryption key" }, - "placeholder": { "type": "string", "default": "HNL978XVXXCM66DM5N2T78D5MT66BC6D" }, - "helper_text": { - "type": "string", - "default": "The JSON webhooks are encrypted in certain situations. This key is also used to generate a signature to verify the integrity of the payload." - }, - "v8n_too_long": { - "type": "string", - "default": "Encryption key cannot exceed 1000 characters" - } - }, - "required": ["label", "placeholder", "helper_text", "v8n_too_long"] - }, - "event-resource": { - "additionalProperties": false, - "properties": { - "label": { "type": "string", "default": "Resource" }, - "helper_text": { - "type": "string", - "default": "Changes in selected resource type will trigger this webhook. Resource type cannot be changed after the webhook has been created." - }, - "event_resource_subscription": { "type": "string", "default": "Subscription" }, - "event_resource_transaction": { "type": "string", "default": "Transaction" }, - "event_resource_customer": { "type": "string", "default": "Customer" } - }, - "required": [ - "label", - "helper_text", - "event_resource_subscription", - "event_resource_transaction", - "event_resource_customer" - ] - }, - "statuses": { - "additionalProperties": false, - "properties": { - "title": { "type": "string", "default": "Statuses" }, - "pagination": { - "additionalProperties": false, - "properties": { - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { "type": "string", "default": "{{from}}-{{to}} out of {{total}}" }, - "previous": { "type": "string", "default": "Previous" }, - "card": { - "additionalProperties": false, - "properties": { - "status_successful": { "type": "string", "default": "Successful" }, - "status_pending": { "type": "string", "default": "Pending" }, - "status_failed": { "type": "string", "default": "Failed" }, - "date": { "type": "string", "default": "{{value, date}}" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" }, - "loading_empty": { "type": "string", "default": "No data" } - }, - "required": ["loading_busy", "loading_error", "loading_empty"] - } - }, - "required": [ - "status_successful", - "status_pending", - "status_failed", - "date", - "spinner" - ] - } - }, - "required": ["first", "last", "next", "pagination", "previous", "card"] - } - }, - "required": ["title", "pagination"] - }, - "logs": { - "additionalProperties": false, - "properties": { - "title": { "type": "string", "default": "Logs" }, - "pagination": { - "additionalProperties": false, - "properties": { - "first": { "type": "string", "default": "First" }, - "last": { "type": "string", "default": "Last" }, - "next": { "type": "string", "default": "Next" }, - "pagination": { "type": "string", "default": "{{from}}-{{to}} out of {{total}}" }, - "previous": { "type": "string", "default": "Previous" }, - "card": { - "additionalProperties": false, - "properties": { - "date": { "type": "string", "default": "{{value, date}}" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" }, - "loading_empty": { "type": "string", "default": "No data" } - }, - "required": ["loading_busy", "loading_error", "loading_empty"] - } - }, - "required": ["date", "spinner"] - } - }, - "required": ["first", "last", "next", "pagination", "previous", "card"] - } - }, - "required": ["title", "pagination"] - }, - "timestamps": { - "additionalProperties": false, - "properties": { - "date_created": { "type": "string", "default": "Created on" }, - "date_modified": { "type": "string", "default": "Last updated on" }, - "date": { "type": "string", "default": "{{value, date}}" } - }, - "required": ["date_created", "date_modified", "date"] - }, - "delete": { - "additionalProperties": false, - "properties": { - "delete": { "type": "string", "default": "Delete" }, - "cancel": { "type": "string", "default": "Cancel" }, - "delete_prompt": { - "type": "string", - "default": "Are you sure you'd like to remove this webhook? You won't be able to bring it back." - } - }, - "required": ["delete", "cancel", "delete_prompt"] - }, - "create": { - "additionalProperties": false, - "properties": { "create": { "type": "string", "default": "Create" } }, - "required": ["create"] - }, - "spinner": { - "additionalProperties": false, - "properties": { - "refresh": { "type": "string", "default": "Refresh" }, - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" } - }, - "required": ["refresh", "loading_busy", "loading_error"] - } - }, - "required": [ - "name", - "format", - "version", - "url", - "query", - "encryption-key", - "event-resource", - "statuses", - "logs", - "timestamps", - "delete", - "create", - "spinner" - ] -} diff --git a/src/static/schemas/webhook-log-card.json b/src/static/schemas/webhook-log-card.json deleted file mode 100644 index e8c7dcb56..000000000 --- a/src/static/schemas/webhook-log-card.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "date": { "type": "string", "default": "{{value, date}}" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" }, - "loading_empty": { "type": "string", "default": "No data" } - }, - "required": ["loading_busy", "loading_error", "loading_empty"] - } - }, - "required": ["date", "spinner"] -} diff --git a/src/static/schemas/webhook-status-card.json b/src/static/schemas/webhook-status-card.json deleted file mode 100644 index 9ba378b39..000000000 --- a/src/static/schemas/webhook-status-card.json +++ /dev/null @@ -1,20 +0,0 @@ -{ - "$schema": "http://json-schema.org/draft-07/schema", - "additionalProperties": false, - "properties": { - "status_successful": { "type": "string", "default": "Successful" }, - "status_pending": { "type": "string", "default": "Pending" }, - "status_failed": { "type": "string", "default": "Failed" }, - "date": { "type": "string", "default": "{{value, date}}" }, - "spinner": { - "additionalProperties": false, - "properties": { - "loading_busy": { "type": "string", "default": "Loading" }, - "loading_error": { "type": "string", "default": "Unknown error" }, - "loading_empty": { "type": "string", "default": "No data" } - }, - "required": ["loading_busy", "loading_error", "loading_empty"] - } - }, - "required": ["status_successful", "status_pending", "status_failed", "date", "spinner"] -} diff --git a/src/static/translations/address-form/en.json b/src/static/translations/address-form/en.json index c681cd313..d39bdd1e7 100644 --- a/src/static/translations/address-form/en.json +++ b/src/static/translations/address-form/en.json @@ -1,4 +1,27 @@ { + "header": { + "title_existing": "Customer address #{{ id }}", + "title_new": "New customer address", + "subtitle_default_shipping": "Default shipping address", + "subtitle_default_billing": "Default billing address", + "subtitle_custom": "Custom address", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, + "error": { + "country_banned": "Store settings prohibit addresses in this country. Please adjust your store settings or use the Ignore address restrictions option.", + "address_name_exists": "Another address with the same name already exists. Please choose a unique name." + }, "address-name": { "label": "Address name", "placeholder": "Required", @@ -66,6 +89,11 @@ "helper_text": "", "v8n_too_long": "Unfortunately we can't store region names longer than 50 characters" }, + "ignore-address-restrictions": { + "label": "Advanced", + "option_true": "Ignore address restrictions", + "helper_text": "By default, the country value must be valid according to the store's location filtering settings. Checking this box will remove this restriction." + }, "timestamps": { "date": "{{value, date}}", "date_created": "Created on", @@ -76,8 +104,14 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove this address? You won't be able to bring it back." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" }, "spinner": { "refresh": "Refresh", @@ -661,4 +695,4 @@ "country_ye": "Yemen", "country_zm": "Zambia", "country_zw": "Zimbabwe" -} +} \ No newline at end of file diff --git a/src/static/translations/api-browser/en.json b/src/static/translations/api-browser/en.json index 063a64861..cd1317f7e 100644 --- a/src/static/translations/api-browser/en.json +++ b/src/static/translations/api-browser/en.json @@ -11,7 +11,7 @@ "next": "Next", "pagination": "{{from}}-{{to}} out of {{total}}", "previous": "Previous", - "undo": "Undo", + "caption": "Undo", "editor": { "label": "Resource JSON", "placeholder": "Enter resource JSON here and click Submit to save" @@ -30,7 +30,13 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove this resource? You won't be able to bring it back." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Submit" + "caption": "Submit" } -} +} \ No newline at end of file diff --git a/src/static/translations/applied-coupon-code-form/en.json b/src/static/translations/applied-coupon-code-form/en.json index d05e553f9..3b662c4e7 100644 --- a/src/static/translations/applied-coupon-code-form/en.json +++ b/src/static/translations/applied-coupon-code-form/en.json @@ -1,4 +1,21 @@ { + "header": { + "title_existing": "Applied coupon code #{{ id }}", + "title_new": "Apply coupon code", + "subtitle": "", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "code": { "label": "Coupon code", "placeholder": "MY-COUPON-123", @@ -16,12 +33,18 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove this coupon code? This might affect the cart total." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Apply" + "caption": "Apply" }, "spinner": { "refresh": "Refresh", "loading_busy": "Loading", "loading_error": "Unknown error" } -} +} \ No newline at end of file diff --git a/src/static/translations/attribute-form/en.json b/src/static/translations/attribute-form/en.json index 92c36b91e..ac1896755 100644 --- a/src/static/translations/attribute-form/en.json +++ b/src/static/translations/attribute-form/en.json @@ -1,4 +1,23 @@ { + "header": { + "title_existing": "Attribute #{{ id }}", + "title_new": "New attribute", + "subtitle_private": "Visible only to you", + "subtitle_restricted": "Visible to store admins", + "subtitle_public": "Visible to everyone", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "name": { "label": "Name", "placeholder": "Required", @@ -30,12 +49,18 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove this attribute? You won't be able to bring it back." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" }, "spinner": { "refresh": "Refresh", "loading_busy": "Loading", "loading_error": "Unknown error" } -} +} \ No newline at end of file diff --git a/src/static/translations/cart-form/en.json b/src/static/translations/cart-form/en.json index 310585c74..ba9a1a0ac 100644 --- a/src/static/translations/cart-form/en.json +++ b/src/static/translations/cart-form/en.json @@ -1,4 +1,21 @@ { + "header": { + "title_existing": "Cart #{{ id }}", + "title_new": "New cart", + "subtitle": "", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "order_section_title": "Order", "order_section_description": "Cart items, discounts and metadata", "billing_section_title": "Billing", @@ -64,6 +81,24 @@ "undo_message": "Looks like you didn't save your changes! What would you like to do with them?", "undo_cancel": "Review", "undo_confirm": "Discard", + "header": { + "title_existing": "Item #{{ id }}", + "title_new": "New item", + "subtitle_future_line_item": "This item is part of a future subscription", + "subtitle_regular": "", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "dimensions": "Dimensions", "subscriptions": "Subscriptions", "discount": "Discount", @@ -156,7 +191,7 @@ }, "shipto": { "label": "Shipping address", - "helper_text": "Used for multiship to assign this item to a specific shipment.", + "helper_text": "Used for multiship to assign this item to a specific shipment. This value will be the address name of the shipment.", "placeholder": "Select address to ship this item to..." }, "width": { @@ -181,8 +216,40 @@ }, "item-category-uri": { "label": "Item category", - "helper_text": "Item category associated with this item.", - "placeholder": "Select item category..." + "dialog": { + "cancel": "Cancel", + "close": "Close", + "header": "Select an item category", + "selection": { + "label": "Item categories", + "helper_text": "Select an item category to use with this item.", + "search": "Search", + "clear": "Clear", + "pagination": { + "search_button_text": "Search", + "first": "First", + "last": "Last", + "next": "Next", + "pagination": "{{from}}-{{to}} out of {{total}}", + "previous": "Previous", + "card": { + "spinner": { + "loading_busy": "Loading", + "loading_empty": "No item categories found", + "loading_error": "Unknown error" + } + } + } + } + }, + "card": { + "spinner": { + "loading_busy": "Loading", + "loading_empty": "Not assigned – click to select", + "loading_error": "Unknown error" + } + }, + "helper_text": "Item category associated with this item." }, "code": { "label": "Code", @@ -245,6 +312,25 @@ "undo_cancel": "Review", "undo_confirm": "Discard", "attribute-form": { + "header": { + "title_existing": "Item attribute #{{ id }}", + "title_new": "New item attribute", + "subtitle_private": "Visible only to you", + "subtitle_restricted": "Visible to store admins", + "subtitle_public": "Visible to everyone", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "name": { "label": "Name", "placeholder": "Required", @@ -276,8 +362,14 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove this attribute? You won't be able to bring it back." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" }, "spinner": { "refresh": "Refresh", @@ -320,6 +412,23 @@ "undo_cancel": "Review", "undo_confirm": "Discard", "item-option-form": { + "header": { + "title_existing": "Item option #{{ id }}", + "title_new": "New item option", + "subtitle": "", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "name": { "label": "Name", "helper_text": "", @@ -359,8 +468,14 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove this item option? You won't be able to bring it back." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" } } }, @@ -391,8 +506,14 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove this item? You won't be able to bring it back." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" }, "spinner": { "refresh": "Refresh", @@ -434,7 +555,57 @@ "undo_header": "Unsaved changes", "undo_message": "Looks like you didn't save your changes! What would you like to do with them?", "undo_cancel": "Review", - "undo_confirm": "Discard" + "undo_confirm": "Discard", + "applied-coupon-code-form": { + "header": { + "title_existing": "Applied coupon code #{{ id }}", + "title_new": "Apply coupon code", + "subtitle": "", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, + "code": { + "label": "Coupon code", + "placeholder": "MY-COUPON-123", + "helper_text_new": "To find the right code, go to the Coupons page, select a coupon and scroll down to the Codes section.", + "helper_text_existing": "Applied codes can't be modified. To replace this code, remove it using the button below and then add a new one.", + "v8n_required": "Please enter a coupon code." + }, + "ignore-usage-limits": { + "label": "", + "helper_text": "", + "option_checked": "Ignore usage limits" + }, + "delete": { + "delete": "Remove", + "cancel": "Cancel", + "delete_prompt": "Are you sure you'd like to remove this coupon code? This might affect the cart total." + }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, + "create": { + "caption": "Apply" + }, + "spinner": { + "refresh": "Refresh", + "loading_busy": "Loading", + "loading_error": "Unknown error" + } + } } }, "totals": { @@ -620,7 +791,69 @@ "undo_header": "Unsaved changes", "undo_message": "Looks like you didn't save your changes! What would you like to do with them?", "undo_cancel": "Review", - "undo_confirm": "Discard" + "undo_confirm": "Discard", + "custom-field-form": { + "header": { + "title_existing": "Cart custom field #{{ id }}", + "title_new": "New cart custom field", + "subtitle": "", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, + "name": { + "label": "Name", + "placeholder": "Required", + "helper_text": "Maximum 100 characters.", + "v8n_required": "Please name this custom field.", + "v8n_too_long": "Please choose a name that is 100 characters long or less." + }, + "value": { + "label": "Value", + "placeholder": "Required", + "helper_text": "Maximum 700 characters.", + "v8n_required": "Please provide a value for this custom field.", + "v8n_too_long": "Unfortunately we can't store values that are more than 700 characters long." + }, + "visibility": { + "label": "Visibility", + "option_hidden": "Hide in receipts", + "helper_text": "Whether or not this custom field is visible on the receipt and email receipt. This correlates to custom fields with a \"h:\" prefix when added to the cart." + }, + "timestamps": { + "date": "{{value, date}}", + "date_created": "Created on", + "date_modified": "Last updated on" + }, + "delete": { + "delete": "Delete", + "cancel": "Cancel", + "delete_prompt": "Are you sure you'd like to remove this custom field? You won't be able to bring it back." + }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, + "create": { + "caption": "Create" + }, + "spinner": { + "refresh": "Refresh", + "loading_busy": "Loading", + "loading_error": "Unknown error" + } + } } }, "attributes": { @@ -674,12 +907,18 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove this cart? You won't be able to bring it back." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" }, "spinner": { "refresh": "Refresh", "loading_busy": "Loading", "loading_error": "Unknown error" } -} +} \ No newline at end of file diff --git a/src/static/translations/client-form/en.json b/src/static/translations/client-form/en.json index e83da8560..6adfc5f2b 100644 --- a/src/static/translations/client-form/en.json +++ b/src/static/translations/client-form/en.json @@ -1,4 +1,21 @@ { + "header": { + "title_existing": "Client #{{ id }}", + "title_new": "New client", + "subtitle": "", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "client-id": { "label": "Client ID", "placeholder": "", @@ -64,12 +81,18 @@ "cancel": "Cancel", "delete_prompt": "Once deleted, applications using this client will no longer be able to access Foxy stores and users." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" }, "spinner": { "refresh": "Refresh", "loading_busy": "Loading", "loading_error": "Unknown error" } -} +} \ No newline at end of file diff --git a/src/static/translations/coupon-code-form/en.json b/src/static/translations/coupon-code-form/en.json index d541d959f..21a17eb02 100644 --- a/src/static/translations/coupon-code-form/en.json +++ b/src/static/translations/coupon-code-form/en.json @@ -1,4 +1,21 @@ { + "header": { + "title_existing": "Coupon code #{{ id }}", + "title_new": "New coupon code", + "subtitle": "Number of uses: {{ number_of_uses_to_date }}", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "code": { "label": "Code", "placeholder": "Required", @@ -7,10 +24,6 @@ "v8n_too_long": "Coupon code must be 50 characters or less", "v8n_has_spaces": "Please remove spaces from the coupon code" }, - "number-of-uses-to-date": { - "label": "Number of uses", - "helper_text": "For informational purposes, this shows you how many times this coupon code has already been used." - }, "transactions": { "label": "Transactions", "pagination": { @@ -64,12 +77,18 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove this coupon code? You won't be able to bring it back." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" }, "spinner": { "refresh": "Refresh", "loading_busy": "Loading", "loading_error": "Unknown error" } -} +} \ No newline at end of file diff --git a/src/static/translations/coupon-codes-form/en.json b/src/static/translations/coupon-codes-form/en.json index 5ae5da28e..1ab7db9c2 100644 --- a/src/static/translations/coupon-codes-form/en.json +++ b/src/static/translations/coupon-codes-form/en.json @@ -8,12 +8,18 @@ "helper_text": "Paste multiple space-separated codes in the field above to add all of them at once. Importing duplicate codes clears their usage stats.", "v8n_required": "Please add at least one code" }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Import" + "caption": "Import" }, "spinner": { "refresh": "Refresh", "loading_busy": "Loading", "loading_error": "Unknown error" } -} +} \ No newline at end of file diff --git a/src/static/translations/coupon-form/en.json b/src/static/translations/coupon-form/en.json index a5234278d..061419515 100644 --- a/src/static/translations/coupon-form/en.json +++ b/src/static/translations/coupon-form/en.json @@ -1,8 +1,20 @@ { "header": { - "title_existing": "ID {{ id }}", + "title_existing": "{{ name }}", "title_new": "New coupon", - "subtitle": "Used {{ number_of_uses_to_date }} times (see individual codes for more info)" + "subtitle": "Uses to date: {{ number_of_uses_to_date }} • #{{ id }}", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } }, "import": { "button_text": "Import codes", @@ -25,8 +37,14 @@ "helper_text": "Paste multiple space-separated codes in the field above to add all of them at once. Importing duplicate codes clears their usage stats.", "v8n_required": "Please add at least one code" }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Import" + "caption": "Import" }, "spinner": { "refresh": "Refresh", @@ -79,8 +97,14 @@ "placeholder": "", "helper_text": "This is what the generated codes will look like." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Generate" + "caption": "Generate" }, "spinner": { "refresh": "Refresh", @@ -162,6 +186,23 @@ "undo_cancel": "Review", "undo_confirm": "Discard", "coupon-code-form": { + "header": { + "title_existing": "Coupon code #{{ id }}", + "title_new": "New coupon code", + "subtitle": "Number of uses: {{ number_of_uses_to_date }}", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "code": { "label": "Code", "placeholder": "Required", @@ -170,10 +211,6 @@ "v8n_too_long": "Coupon code must be 50 characters or less", "v8n_has_spaces": "Please remove spaces from the coupon code" }, - "number-of-uses-to-date": { - "label": "Number of uses", - "helper_text": "For informational purposes, this shows you how many times this coupon code has already been used." - }, "transactions": { "label": "Transactions", "pagination": { @@ -227,8 +264,14 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove this coupon code? You won't be able to bring it back." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" }, "spinner": { "refresh": "Refresh", @@ -313,6 +356,25 @@ "undo_cancel": "Review", "undo_confirm": "Discard", "attribute-form": { + "header": { + "title_existing": "Coupon attribute #{{ id }}", + "title_new": "New coupon attribute", + "subtitle_private": "Visible only to you", + "subtitle_restricted": "Visible to store admins", + "subtitle_public": "Visible to everyone", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "name": { "label": "Name", "placeholder": "Required", @@ -344,8 +406,14 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove this attribute? You won't be able to bring it back." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" }, "spinner": { "refresh": "Refresh", @@ -424,7 +492,7 @@ "label": "Auto-apply: subscription restrictions", "placeholder": "Enter a product code and hit Enter", "helper_text": "This coupon will be automatically applied when a subscription includes a product with one of the codes in the list. Wildcards are allowed just like in product code restrictions.", - "submit": "Add this code", + "caption": "Add this code", "delete": "Delete this code", "v8n_too_long": "Unfortunately we are unable to store that many subscription restrictions at the moment. Please reduce the number of rules in this section until this message disappears." }, @@ -547,12 +615,18 @@ "cancel": "Cancel", "delete_prompt": "This action is irreversible. Are you sure you want to delete this coupon?" }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" }, "spinner": { "refresh": "Refresh", "loading_busy": "Loading", "loading_error": "Unknown error" } -} +} \ No newline at end of file diff --git a/src/static/translations/custom-field-form/en.json b/src/static/translations/custom-field-form/en.json index 8f4fce207..342b024ac 100644 --- a/src/static/translations/custom-field-form/en.json +++ b/src/static/translations/custom-field-form/en.json @@ -1,4 +1,21 @@ { + "header": { + "title_existing": "Custom field #{{ id }}", + "title_new": "New custom field", + "subtitle": "", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "name": { "label": "Name", "placeholder": "Required", @@ -28,12 +45,18 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove this custom field? You won't be able to bring it back." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" }, "spinner": { "refresh": "Refresh", "loading_busy": "Loading", "loading_error": "Unknown error" } -} +} \ No newline at end of file diff --git a/src/static/translations/customer-form/en.json b/src/static/translations/customer-form/en.json index 1f2949649..1f38035f5 100644 --- a/src/static/translations/customer-form/en.json +++ b/src/static/translations/customer-form/en.json @@ -1,4 +1,23 @@ { + "header": { + "title_existing": "{{ first_name }} {{ last_name }}", + "title_no_name": "No name", + "title_new": "New customer", + "subtitle_anonymous": "Guest customer #{{ id }}", + "subtitle_registered": "Customer #{{ id }}", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "legal-notice": { "text": "By creating an account, you agree to our Terms of Service.", "link": "Click here to open them in a new tab." @@ -80,12 +99,18 @@ "cancel": "Cancel", "delete_prompt": "This action is irreversible. Are you sure you want to delete this customer?" }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" }, "spinner": { "refresh": "Refresh", "loading_busy": "Loading", "loading_error": "Unknown error" } -} +} \ No newline at end of file diff --git a/src/static/translations/customer-portal-settings-form/en.json b/src/static/translations/customer-portal-settings-form/en.json index 1ced6c8ce..a209a25fb 100644 --- a/src/static/translations/customer-portal-settings-form/en.json +++ b/src/static/translations/customer-portal-settings-form/en.json @@ -1,4 +1,15 @@ { + "header": { + "title_existing": "Customer portal settings", + "title_new": "Customer portal settings", + "subtitle": "Customer portal is enabled", + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "session-lifespan-in-minutes": { "label": "Session lifespan", "option_minute": "Minute", @@ -96,8 +107,14 @@ "cancel": "Cancel", "delete_prompt": "Please confirm that you'd like to remove this rule." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" }, "spinner": { "refresh": "Refresh", @@ -227,8 +244,14 @@ "cancel": "Cancel", "delete_prompt": "Please confirm that you'd like to remove this rule." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" }, "spinner": { "refresh": "Refresh", @@ -289,12 +312,18 @@ "cancel": "Cancel", "delete_prompt": "Disabling Customer Portal will erase the configuration and disable the related APIs. Would you like to proceed?" }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Enable" + "caption": "Enable" }, "spinner": { "refresh": "Refresh", "loading_busy": "Loading", "loading_error": "Unknown error" } -} +} \ No newline at end of file diff --git a/src/static/translations/customer-portal/de.json b/src/static/translations/customer-portal/de.json index 8f0a06379..46a07563b 100644 --- a/src/static/translations/customer-portal/de.json +++ b/src/static/translations/customer-portal/de.json @@ -63,6 +63,10 @@ } }, "address-form": { + "error": { + "country_banned": "Leider akzeptieren wir keine Bestellungen aus dem von Ihnen gewählten Land.", + "address_name_exists": "Es existiert bereits eine andere Adresse mit demselben Namen. Bitte wählen Sie einen eindeutigen Namen." + }, "address-name": { "label": "Adressname", "placeholder": "Erforderlich", @@ -140,8 +144,14 @@ "cancel": "Abbrechen", "delete_prompt": "Sind Sie sicher, dass Sie diese Adresse entfernen möchten? " }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Erstellen" + "caption": "Erstellen" }, "spinner": { "refresh": "Aktualisierung", @@ -804,6 +814,10 @@ "dialog_header_add": "Zahlungsmethode hinzufügen", "dialog_header_update": "Zahlungsmethode aktualisieren", "update-payment-method-form": { + "header": { + "title_existing": "Karte aktualisieren", + "subtitle": "Geben Sie unten die Kartendetails ein und klicken Sie auf Karte speichern" + }, "status": { "cc_token_success": "Kartendetails erfolgreich gespeichert.", "close": "Schließen" @@ -981,6 +995,30 @@ } }, "subscription-form": { + "header": { + "title_new": "Abonnement", + "title_existing": "Abonnement", + "title_recurring": "{{amount, price}} $t(customer.subscription-form.frequency, { \"count\": \"{{count}}\", \"units\": \"{{units}}\", \"ns\": \"customer-portal\" })", + "title_twice_a_month": "{{amount, price}} $t(customer.subscription-form.twice_a_month, { \"ns\": \"customer-portal\" })", + "subscription_active": "Inklusive Versand, Steuern usw. Nächste Zahlung am {{date, date}}.", + "subscription_cancelled": "Inklusive Versand, Steuern usw. Endet am {{date, date}}.", + "subscription_failed": "Einschließlich Versand, Steuern usw. Die Zahlung ist fehlgeschlagen {{date, date}}.", + "subscription_inactive": "Inklusive Versand, Steuern usw. Inaktiv.", + "subscription_will_be_cancelled": "Inklusive Versand, Steuern usw. Endet am {{date, date}}.", + "subscription_will_be_active": "Inklusive Versand, Steuern usw. Beginnt am {{date, date}}.", + "copy-id": { + "failed_to_copy": "Kopieren fehlgeschlagen", + "click_to_copy": "ID kopieren", + "copying": "Kopieren...", + "done": "In Zwischenablage kopiert" + }, + "copy-json": { + "failed_to_copy": "Kopieren fehlgeschlagen", + "click_to_copy": "Quelle als JSON kopieren", + "copying": "Kopieren...", + "done": "In Zwischenablage kopiert" + } + }, "day": "Tag", "day_plural": "Tage", "week": "Woche", @@ -1004,12 +1042,6 @@ "next_transaction_date": "Nächstes Transaktionsdatum", "price_recurring": "{{amount, price}} $t(customer.subscription-form.frequency, { \"count\": \"{{count}}\", \"units\": \"{{units}}\", \"ns\": \"customer-portal\" })", "price_twice_a_month": "{{amount, price}} $t(customer.subscription-form.twice_a_month, { \"ns\": \"customer-portal\" })", - "subscription_active": "Inklusive Versand, Steuern usw. Nächste Zahlung am {{date, date}}.", - "subscription_cancelled": "Inklusive Versand, Steuern usw. Endet am {{date, date}}.", - "subscription_failed": "Einschließlich Versand, Steuern usw. Die Zahlung ist fehlgeschlagen {{date, date}}.", - "subscription_inactive": "Inklusive Versand, Steuern usw. Inaktiv.", - "subscription_will_be_cancelled": "Inklusive Versand, Steuern usw. Endet am {{date, date}}.", - "subscription_will_be_active": "Inklusive Versand, Steuern usw. Beginnt am {{date, date}}.", "transaction_plural": "Transaktionen", "twice_a_month": "Zweimal im Monat", "update_billing": "Abrechnung aktualisieren", @@ -1161,8 +1193,14 @@ "text": "Durch die Erstellung eines Kontos stimmen Sie unseren Nutzungsbedingungen zu.", "link": "Klicken Sie hier, um sie in einem neuen Tab zu öffnen." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Benutzerkonto erstellen" + "caption": "Benutzerkonto erstellen" }, "spinner": { "refresh": "Aktualisierung", @@ -1170,4 +1208,4 @@ "loading_error": "Wurde nicht geladen" } } -} +} \ No newline at end of file diff --git a/src/static/translations/customer-portal/en.json b/src/static/translations/customer-portal/en.json index 80ab52345..b9f81f65b 100644 --- a/src/static/translations/customer-portal/en.json +++ b/src/static/translations/customer-portal/en.json @@ -63,6 +63,10 @@ } }, "address-form": { + "error": { + "country_banned": "Unfortunately, we don't accept orders from the country you've selected.", + "address_name_exists": "Another address with the same name already exists. Please choose a unique name." + }, "address-name": { "label": "Address name", "placeholder": "Required", @@ -140,8 +144,14 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove this address? You won't be able to bring it back." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" }, "spinner": { "refresh": "Refresh", @@ -804,6 +814,10 @@ "dialog_header_add": "Add payment method", "dialog_header_update": "Update payment method", "update-payment-method-form": { + "header": { + "title_existing": "Update card", + "subtitle": "Enter card details below and click Save card" + }, "status": { "cc_token_success": "Card details saved successfully.", "close": "Close" @@ -981,6 +995,30 @@ } }, "subscription-form": { + "header": { + "title_new": "Subscription", + "title_existing": "Subscription", + "title_recurring": "{{amount, price}} $t(customer.subscription-form.frequency, { \"count\": \"{{count}}\", \"units\": \"{{units}}\", \"ns\": \"customer-portal\" })", + "title_twice_a_month": "{{amount, price}} $t(customer.subscription-form.twice_a_month, { \"ns\": \"customer-portal\" })", + "subtitle_active": "Including shipping, taxes, etc. Next payment on {{date, date}}.", + "subtitle_cancelled": "Including shipping, taxes, etc. Ended on {{date, date}}.", + "subtitle_failed": "Including shipping, taxes, etc. Payment failed on {{date, date}}.", + "subtitle_inactive": "Including shipping, taxes, etc. Inactive.", + "subtitle_will_be_cancelled": "Including shipping, taxes, etc. Ends on {{date, date}}.", + "subtitle_will_be_active": "Including shipping, taxes, etc. Starts on {{date, date}}.", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "day": "Day", "day_plural": "Days", "week": "Week", @@ -1004,12 +1042,6 @@ "next_transaction_date": "Next transaction date", "price_recurring": "{{amount, price}} $t(customer.subscription-form.frequency, { \"count\": \"{{count}}\", \"units\": \"{{units}}\", \"ns\": \"customer-portal\" })", "price_twice_a_month": "{{amount, price}} $t(customer.subscription-form.twice_a_month, { \"ns\": \"customer-portal\" })", - "subscription_active": "Including shipping, taxes, etc. Next payment on {{date, date}}.", - "subscription_cancelled": "Including shipping, taxes, etc. Ended on {{date, date}}.", - "subscription_failed": "Including shipping, taxes, etc. Payment failed on {{date, date}}.", - "subscription_inactive": "Including shipping, taxes, etc. Inactive.", - "subscription_will_be_cancelled": "Including shipping, taxes, etc. Ends on {{date, date}}.", - "subscription_will_be_active": "Including shipping, taxes, etc. Starts on {{date, date}}.", "transaction_plural": "Transactions", "twice_a_month": "Twice a month", "update_billing": "Update billing", @@ -1161,8 +1193,14 @@ "text": "By creating an account, you agree to our Terms of Service.", "link": "Click here to open them in a new tab." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create account" + "caption": "Create account" }, "spinner": { "refresh": "Refresh", @@ -1170,4 +1208,4 @@ "loading_error": "Unknown error" } } -} +} \ No newline at end of file diff --git a/src/static/translations/customer-portal/es.json b/src/static/translations/customer-portal/es.json index 68afb7a2c..f8561e251 100644 --- a/src/static/translations/customer-portal/es.json +++ b/src/static/translations/customer-portal/es.json @@ -63,6 +63,10 @@ } }, "address-form": { + "error": { + "country_banned": "Lamentablemente, no aceptamos pedidos del país que has seleccionado.", + "address_name_exists": "Ya existe otra dirección con el mismo nombre. Por favor, elija un nombre único." + }, "address-name": { "label": "Nombre de la dirección", "placeholder": "Requerido", @@ -140,8 +144,14 @@ "cancel": "Cancelar", "delete_prompt": "¿Está seguro de que desea eliminar esta dirección? " }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Crear" + "caption": "Crear" }, "spinner": { "refresh": "Actualizar", @@ -804,6 +814,10 @@ "dialog_header_add": "Añadir método de pago", "dialog_header_update": "Actualizar método de pago", "update-payment-method-form": { + "header": { + "title_existing": "Actualizar tarjeta", + "subtitle": "Ingrese los detalles de la tarjeta a continuación y haga clic en Guardar tarjeta" + }, "status": { "cc_token_success": "Los datos de la tarjeta se guardaron correctamente.", "close": "Cerca" @@ -980,6 +994,30 @@ } }, "subscription-form": { + "header": { + "title_new": "Suscripción", + "title_existing": "Suscripción", + "title_recurring": "{{amount, price}} $t(customer.subscription-form.frequency, { \"count\": \"{{count}}\", \"units\": \"{{units}}\", \"ns\": \"customer-portal\" })", + "title_twice_a_month": "{{amount, price}} $t(customer.subscription-form.twice_a_month, { \"ns\": \"customer-portal\" })", + "subtitle_active": "Incluye envío, impuestos, etc. Próximo pago el {{date, date}}.", + "subtitle_cancelled": "Incluye envío, impuestos, etc. Terminó el {{date, date}}.", + "subtitle_failed": "Incluye envío, impuestos, etc. El pago falló el {{date, date}}.", + "subtitle_inactive": "Incluye envío, impuestos, etc. Inactivo.", + "subtitle_will_be_cancelled": "Incluye envío, impuestos, etc. Termina el {{date, date}}.", + "subtitle_will_be_active": "Incluye envío, impuestos, etc. Comienza el {{date, date}}.", + "copy-id": { + "failed_to_copy": "Error al copiar", + "click_to_copy": "Copiar ID", + "copying": "Copiando...", + "done": "Copiado al portapapeles" + }, + "copy-json": { + "failed_to_copy": "Error al copiar", + "click_to_copy": "Copiar fuente como JSON", + "copying": "Copiando...", + "done": "Copiado al portapapeles" + } + }, "day": "Día", "day_plural": "Días", "week": "Semana", @@ -1003,12 +1041,6 @@ "next_transaction_date": "Fecha de la próxima transacción", "price_recurring": "{{amount, price}} $t(customer.subscription-form.frequency, { \"count\": \"{{count}}\", \"units\": \"{{units}}\", \"ns\": \"customer-portal\" })", "price_twice_a_month": "{{amount, price}} $t(customer.subscription-form.twice_a_month, { \"ns\": \"customer-portal\" })", - "subscription_active": "Incluye envío, impuestos, etc. Próximo pago el {{date, date}}.", - "subscription_cancelled": "Incluye envío, impuestos, etc. Finalizado el {{date, date}}.", - "subscription_failed": "Incluye envío, impuestos, etc. El pago falló el {{date, date}}.", - "subscription_inactive": "Incluye envío, impuestos, etc. Inactivo.", - "subscription_will_be_cancelled": "Incluye envío, impuestos, etc. Finaliza el {{date, date}}.", - "subscription_will_be_active": "Incluye envío, impuestos, etc. Comienza el {{date, date}}.", "transaction_plural": "Actas", "twice_a_month": "Dos veces al mes", "update_billing": "Actualizar facturación", @@ -1160,8 +1192,14 @@ "text": "Al crear una cuenta, acepta nuestros Términos de servicio.", "link": "Haga clic aquí para abrirlos en una nueva pestaña." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Crear una cuenta" + "caption": "Crear una cuenta" }, "spinner": { "refresh": "Actualizar", @@ -1169,4 +1207,4 @@ "loading_error": "Error desconocido" } } -} +} \ No newline at end of file diff --git a/src/static/translations/customer-portal/fr.json b/src/static/translations/customer-portal/fr.json index 393c54f08..7dd21ea27 100644 --- a/src/static/translations/customer-portal/fr.json +++ b/src/static/translations/customer-portal/fr.json @@ -63,6 +63,10 @@ } }, "address-form": { + "error": { + "country_banned": "Malheureusement, nous n'acceptons pas les commandes du pays que vous avez sélectionné.", + "address_name_exists": "Une autre adresse avec le même nom existe déjà. Veuillez choisir un nom unique." + }, "address-name": { "label": "Nom de l'adresse", "placeholder": "Requis", @@ -140,8 +144,14 @@ "cancel": "Annuler", "delete_prompt": "Êtes-vous sûr de vouloir supprimer cette adresse ? " }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Créer" + "caption": "Créer" }, "spinner": { "refresh": "Rafraîchir", @@ -804,6 +814,10 @@ "dialog_header_add": "Ajouter un mode de paiement", "dialog_header_update": "Mettre à jour le mode de paiement", "update-payment-method-form": { + "header": { + "title_existing": "Mettre à jour la carte", + "subtitle": "Entrez les détails de la carte ci-dessous et cliquez sur Enregistrer la carte" + }, "status": { "cc_token_success": "Les détails de la carte ont été enregistrés avec succès.", "close": "Fermer" @@ -981,6 +995,30 @@ } }, "subscription-form": { + "header": { + "title_new": "Abonnement", + "title_existing": "Abonnement", + "title_recurring": "{{amount, price}} $t(customer.subscription-form.frequency, { \"count\": \"{{count}}\", \"units\": \"{{units}}\", \"ns\": \"customer-portal\" })", + "title_twice_a_month": "{{amount, price}} $t(customer.subscription-form.twice_a_month, { \"ns\": \"customer-portal\" })", + "subtitle_active": "Incluant les frais d'expédition, les taxes, etc. Prochain paiement le {{date, date}}.", + "subtitle_cancelled": "Incluant les frais d'expédition, les taxes, etc. Terminé le {{date, date}}.", + "subtitle_failed": "Incluant les frais d'expédition, les taxes, etc. Le paiement a échoué le {{date, date}}.", + "subtitle_inactive": "Incluant les frais d'expédition, les taxes, etc. Inactif.", + "subtitle_will_be_cancelled": "Incluant les frais d'expédition, les taxes, etc. Se termine le {{date, date}}.", + "subtitle_will_be_active": "Incluant les frais d'expédition, les taxes, etc. Commence le {{date, date}}.", + "copy-id": { + "failed_to_copy": "Échec de la copie", + "click_to_copy": "Copier l'ID", + "copying": "Copie en cours...", + "done": "Copié dans le presse-papiers" + }, + "copy-json": { + "failed_to_copy": "Échec de la copie", + "click_to_copy": "Copier la source en JSON", + "copying": "Copie en cours...", + "done": "Copié dans le presse-papiers" + } + }, "day": "Jour", "day_plural": "Jours", "week": "Semaine", @@ -1004,12 +1042,6 @@ "next_transaction_date": "Date de la prochaine transaction", "price_recurring": "{{amount, price}} $t(customer.subscription-form.frequency, { \"count\": \"{{count}}\", \"units\": \"{{units}}\", \"ns\": \"customer-portal\" })", "price_twice_a_month": "{{amount, price}} $t(customer.subscription-form.twice_a_month, { \"ns\": \"customer-portal\" })", - "subscription_active": "Y compris les frais d'expédition, les taxes, etc. Prochain paiement le {{date, date}}.", - "subscription_cancelled": "Y compris les frais d'expédition, les taxes, etc. Terminé le {{date, date}}.", - "subscription_failed": "Y compris les frais d'expédition, les taxes, etc. Le paiement a échoué le {{date, date}}.", - "subscription_inactive": "Y compris les frais d'expédition, les taxes, etc. Inactif.", - "subscription_will_be_cancelled": "Y compris les frais d'expédition, les taxes, etc. Se termine le {{date, date}}.", - "subscription_will_be_active": "Y compris les frais d'expédition, les taxes, etc. À partir du {{date, date}}.", "transaction_plural": "Transactions", "twice_a_month": "Deux fois par mois", "update_billing": "Mettre à jour la facturation", @@ -1161,8 +1193,14 @@ "text": "En créant un compte, vous acceptez nos conditions d'utilisation.", "link": "Cliquez ici pour les ouvrir dans un nouvel onglet." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Créer un compte" + "caption": "Créer un compte" }, "spinner": { "refresh": "Rafraîchir", @@ -1170,4 +1208,4 @@ "loading_error": "Erreur inconnue" } } -} +} \ No newline at end of file diff --git a/src/static/translations/customer-portal/nl.json b/src/static/translations/customer-portal/nl.json index 9bfd55781..739ed0f92 100644 --- a/src/static/translations/customer-portal/nl.json +++ b/src/static/translations/customer-portal/nl.json @@ -63,6 +63,10 @@ } }, "address-form": { + "error": { + "country_banned": "Helaas accepteren we geen bestellingen uit het geselecteerde land.", + "address_name_exists": "Er bestaat al een ander adres met dezelfde naam. Kies alstublieft een unieke naam." + }, "address-name": { "label": "Adres naam", "placeholder": "Vereist", @@ -140,8 +144,14 @@ "cancel": "Annuleren", "delete_prompt": "Weet u zeker dat u dit adres wilt verwijderen? " }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Creëren" + "caption": "Creëren" }, "spinner": { "refresh": "Vernieuwen", @@ -804,6 +814,10 @@ "dialog_header_add": "Betaalmethode toevoegen", "dialog_header_update": "Betaalmethode bijwerken", "update-payment-method-form": { + "header": { + "title_existing": "Kaart bijwerken", + "subtitle": "Voer hieronder de kaartgegevens in en klik op Kaart opslaan" + }, "status": { "cc_token_success": "Kaartgegevens zijn succesvol opgeslagen.", "close": "Dichtbij" @@ -981,6 +995,30 @@ } }, "subscription-form": { + "header": { + "title_new": "Abonnement", + "title_existing": "Abonnement", + "title_recurring": "{{amount, price}} $t(customer.subscription-form.frequency, { \"count\": \"{{count}}\", \"units\": \"{{units}}\", \"ns\": \"customer-portal\" })", + "title_twice_a_month": "{{amount, price}} $t(customer.subscription-form.twice_a_month, { \"ns\": \"customer-portal\" })", + "subtitle_active": "Inclusief verzendkosten, belastingen etc. Volgende betaling op {{date, date}}.", + "subtitle_cancelled": "Inclusief verzendkosten, belastingen, etc. Beëindigd op {{date, date}}.", + "subtitle_failed": "Inclusief verzendkosten, belastingen etc. Betaling mislukt op {{date, date}}.", + "subtitle_inactive": "Inclusief verzendkosten, belastingen etc. Inactief.", + "subtitle_will_be_cancelled": "Inclusief verzendkosten, belastingen etc. Eindigt op {{date, date}}.", + "subtitle_will_be_active": "Inclusief verzendkosten, belastingen etc. Begint op {{date, date}}.", + "copy-id": { + "failed_to_copy": "Kopiëren mislukt", + "click_to_copy": "ID kopiëren", + "copying": "Kopiëren...", + "done": "Gekopieerd naar klembord" + }, + "copy-json": { + "failed_to_copy": "Kopiëren mislukt", + "click_to_copy": "Bron kopiëren als JSON", + "copying": "Kopiëren...", + "done": "Gekopieerd naar klembord" + } + }, "day": "Dag", "day_plural": "Dagen", "week": "Week", @@ -1004,12 +1042,6 @@ "next_transaction_date": "Volgende transactiedatum", "price_recurring": "{{amount, price}} $t(customer.subscription-form.frequency, { \"count\": \"{{count}}\", \"units\": \"{{units}}\", \"ns\": \"customer-portal\" })", "price_twice_a_month": "{{amount, price}} $t(customer.subscription-form.twice_a_month, { \"ns\": \"customer-portal\" })", - "subscription_active": "Inclusief verzendkosten, belastingen etc. Volgende betaling op {{date, date}}.", - "subscription_cancelled": "Inclusief verzendkosten, belastingen, etc. Beëindigd op {{date, date}}.", - "subscription_failed": "Inclusief verzendkosten, belastingen etc. Betaling mislukt {{date, date}}.", - "subscription_inactive": "Inclusief verzendkosten, belastingen etc. Inactief.", - "subscription_will_be_cancelled": "Inclusief verzendkosten, belastingen etc. Eindigt op {{date, date}}.", - "subscription_will_be_active": "Inclusief verzendkosten, belastingen etc. Begint op {{date, date}}.", "transaction_plural": "Transacties", "twice_a_month": "Twee keer per maand", "update_billing": "Facturering bijwerken", @@ -1161,8 +1193,14 @@ "text": "Door een account aan te maken, gaat u akkoord met onze Servicevoorwaarden.", "link": "Klik hier om ze in een nieuw tabblad te openen." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Account aanmaken" + "caption": "Account aanmaken" }, "spinner": { "refresh": "Vernieuwen", @@ -1170,4 +1208,4 @@ "loading_error": "Onbekende fout" } } -} +} \ No newline at end of file diff --git a/src/static/translations/customer-portal/pl.json b/src/static/translations/customer-portal/pl.json index aaf683980..9bfe19678 100644 --- a/src/static/translations/customer-portal/pl.json +++ b/src/static/translations/customer-portal/pl.json @@ -63,6 +63,10 @@ } }, "address-form": { + "error": { + "country_banned": "Niestety, nie akceptujemy zamówień z wybranego kraju.", + "address_name_exists": "Inny adres o takiej samej nazwie już istnieje. Proszę wybrać unikalną nazwę." + }, "address-name": { "label": "Adres", "placeholder": "Wymagany", @@ -140,8 +144,14 @@ "cancel": "Anulować", "delete_prompt": "Czy na pewno chcesz usunąć ten adres? " }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Tworzyć" + "caption": "Tworzyć" }, "spinner": { "refresh": "Odświeżać", @@ -804,6 +814,10 @@ "dialog_header_add": "Dodaj metodę płatności", "dialog_header_update": "Zaktualizuj metodę płatności", "update-payment-method-form": { + "header": { + "title_existing": "Aktualizuj kartę", + "subtitle": "Wprowadź dane karty poniżej i kliknij Zapisz kartę" + }, "status": { "cc_token_success": "Dane karty zostały zapisane pomyślnie.", "close": "Zamknąć" @@ -981,6 +995,30 @@ } }, "subscription-form": { + "header": { + "title_new": "Subskrypcja", + "title_existing": "Subskrypcja", + "title_recurring": "{{amount, price}} $t(customer.subscription-form.frequency, { \"count\": \"{{count}}\", \"units\": \"{{units}}\", \"ns\": \"customer-portal\" })", + "title_twice_a_month": "{{amount, price}} $t(customer.subscription-form.twice_a_month, { \"ns\": \"customer-portal\" })", + "subtitle_active": "Obejmuje wysyłkę, podatki itp. Następna płatność w dniu {{date, date}}.", + "subtitle_cancelled": "Obejmuje wysyłkę, podatki itp. Zakończono dnia {{date, date}}.", + "subtitle_failed": "Obejmuje wysyłkę, podatki itp. Płatność nie powiodła się {{date, date}}.", + "subtitle_inactive": "Łącznie z przesyłką, podatkami itp. Nieaktywne.", + "subtitle_will_be_cancelled": "Łącznie z przesyłką, podatkami itp. Kończy się dnia {{date, date}}.", + "subtitle_will_be_active": "Obejmuje wysyłkę, podatki itp. Rozpoczyna się w dniu {{date, date}}.", + "copy-id": { + "failed_to_copy": "Nie udało się skopiować", + "click_to_copy": "Skopiuj ID", + "copying": "Kopiowanie...", + "done": "Skopiowano do schowka" + }, + "copy-json": { + "failed_to_copy": "Nie udało się skopiować", + "click_to_copy": "Skopiuj źródło jako JSON", + "copying": "Kopiowanie...", + "done": "Skopiowano do schowka" + } + }, "day": "Dzień", "day_plural": "Dni", "week": "Tydzień", @@ -1004,12 +1042,6 @@ "next_transaction_date": "Data następnej transakcji", "price_recurring": "{{amount, price}} $t(customer.subscription-form.frequency, { \"count\": \"{{count}}\", \"units\": \"{{units}}\", \"ns\": \"customer-portal\" })", "price_twice_a_month": "{{amount, price}} $t(customer.subscription-form.twice_a_month, { \"ns\": \"customer-portal\" })", - "subscription_active": "Obejmuje wysyłkę, podatki itp. Następna płatność w dniu {{date, date}}.", - "subscription_cancelled": "Obejmuje wysyłkę, podatki itp. Zakończono dnia {{date, date}}.", - "subscription_failed": "Obejmuje wysyłkę, podatki itp. Płatność nie powiodła się {{date, date}}.", - "subscription_inactive": "Łącznie z przesyłką, podatkami itp. Nieaktywne.", - "subscription_will_be_cancelled": "Łącznie z przesyłką, podatkami itp. Kończy się dnia {{date, date}}.", - "subscription_will_be_active": "Obejmuje wysyłkę, podatki itp. Rozpoczyna się w dniu {{date, date}}.", "transaction_plural": "Transakcje", "twice_a_month": "Dwa razy w miesiącu", "update_billing": "Zaktualizuj rozliczenia", @@ -1161,8 +1193,14 @@ "text": "Tworząc konto, wyrażasz zgodę na nasze Warunki świadczenia usług.", "link": "Kliknij tutaj, aby otworzyć je w nowej karcie." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Utwórz konto" + "caption": "Utwórz konto" }, "spinner": { "refresh": "Odświeżać", @@ -1170,4 +1208,4 @@ "loading_error": "Nieznany błąd" } } -} +} \ No newline at end of file diff --git a/src/static/translations/customer-portal/sv.json b/src/static/translations/customer-portal/sv.json index 4c3fa8c5b..9838c6eda 100644 --- a/src/static/translations/customer-portal/sv.json +++ b/src/static/translations/customer-portal/sv.json @@ -63,6 +63,10 @@ } }, "address-form": { + "error": { + "country_banned": "Tyvärr accepterar vi inte beställningar från det land du har valt.", + "address_name_exists": "Ett annat adress med samma namn finns redan. Vänligen välj ett unikt namn." + }, "address-name": { "label": "Adressnamn", "placeholder": "Nödvändig", @@ -140,8 +144,14 @@ "cancel": "Annullera", "delete_prompt": "Är du säker på att du vill ta bort den här adressen? " }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Skapa" + "caption": "Skapa" }, "spinner": { "refresh": "Uppdatera", @@ -804,6 +814,10 @@ "dialog_header_add": "Lägg till betalningsmetod", "dialog_header_update": "Uppdatera betalningsmetod", "update-payment-method-form": { + "header": { + "title_existing": "Uppdatera kort", + "subtitle": "Ange kortuppgifter nedan och klicka på Spara kort" + }, "status": { "cc_token_success": "Kortinformationen har sparats.", "close": "Stänga" @@ -981,6 +995,30 @@ } }, "subscription-form": { + "header": { + "title_new": "Prenumeration", + "title_existing": "Prenumeration", + "title_recurring": "{{amount, price}} $t(customer.subscription-form.frequency, { \"count\": \"{{count}}\", \"units\": \"{{units}}\", \"ns\": \"customer-portal\" })", + "title_twice_a_month": "{{amount, price}} $t(customer.subscription-form.twice_a_month, { \"ns\": \"customer-portal\" })", + "subtitle_active": "Inklusive frakt, skatter etc. Nästa betalning på {{date, date}}.", + "subtitle_cancelled": "Inklusive frakt, skatter etc. Slutade den {{date, date}}.", + "subtitle_failed": "Inklusive frakt, skatter etc. Betalning misslyckades den {{date, date}}.", + "subtitle_inactive": "Inklusive frakt, skatter etc. Inaktiv.", + "subtitle_will_be_cancelled": "Inklusive frakt, skatter etc. Slutar på {{date, date}}.", + "subtitle_will_be_active": "Inklusive frakt, skatter etc. Börjar på {{date, date}}.", + "copy-id": { + "failed_to_copy": "Misslyckades att kopiera", + "click_to_copy": "Kopiera ID", + "copying": "Kopierar...", + "done": "Kopierad till urklipp" + }, + "copy-json": { + "failed_to_copy": "Misslyckades att kopiera", + "click_to_copy": "Kopiera källa som JSON", + "copying": "Kopierar...", + "done": "Kopierad till urklipp" + } + }, "day": "Dag", "day_plural": "dagar", "week": "Vecka", @@ -1004,12 +1042,6 @@ "next_transaction_date": "Nästa transaktionsdatum", "price_recurring": "{{amount, price}} $t(customer.subscription-form.frequency, { \"count\": \"{{count}}\", \"units\": \"{{units}}\", \"ns\": \"customer-portal\" })", "price_twice_a_month": "{{amount, price}} $t(customer.subscription-form.twice_a_month, { \"ns\": \"customer-portal\" })", - "subscription_active": "Inklusive frakt, skatter etc. Nästa betalning på {{date, date}}.", - "subscription_cancelled": "Inklusive frakt, skatter etc. Slutade den {{date, date}}.", - "subscription_failed": "Inklusive frakt, skatter etc. Betalning misslyckades den {{date, date}}.", - "subscription_inactive": "Inklusive frakt, skatter etc. Inaktiv.", - "subscription_will_be_cancelled": "Inklusive frakt, skatter etc. Slutar på {{date, date}}.", - "subscription_will_be_active": "Inklusive frakt, skatter etc. Börjar på {{date, date}}.", "transaction_plural": "Transaktioner", "twice_a_month": "Två gånger i månaden", "update_billing": "Uppdatera fakturering", @@ -1161,8 +1193,14 @@ "text": "Genom att skapa ett konto godkänner du våra användarvillkor.", "link": "Klicka här för att öppna dem på en ny flik." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Skapa konto" + "caption": "Skapa konto" }, "spinner": { "refresh": "Uppdatera", @@ -1170,4 +1208,4 @@ "loading_error": "Okänt fel" } } -} +} \ No newline at end of file diff --git a/src/static/translations/customer-portal/zh-hk.json b/src/static/translations/customer-portal/zh-hk.json index 0b1473108..105bef025 100644 --- a/src/static/translations/customer-portal/zh-hk.json +++ b/src/static/translations/customer-portal/zh-hk.json @@ -63,6 +63,10 @@ } }, "address-form": { + "error": { + "country_banned": "很抱歉,我们不接受来自您选择的国家的订单。", + "address_name_exists": "已存在具有相同名称的其他地址。请选择一个唯一的名称。" + }, "address-name": { "label": "地址名称", "placeholder": "必需的", @@ -140,8 +144,14 @@ "cancel": "取消", "delete_prompt": "您确定要删除该地址吗?" }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "创造" + "caption": "创造" }, "spinner": { "refresh": "刷新", @@ -804,6 +814,10 @@ "dialog_header_add": "添加付款方式", "dialog_header_update": "更新付款方式", "update-payment-method-form": { + "header": { + "title_existing": "更新信用卡", + "subtitle": "在下方输入信用卡详细信息,然后点击保存信用卡" + }, "status": { "cc_token_success": "卡详细信息已成功保存。", "close": "关闭" @@ -981,6 +995,30 @@ } }, "subscription-form": { + "header": { + "title_new": "訂閱", + "title_existing": "訂閱", + "title_recurring": "{{amount, price}} $t(customer.subscription-form.frequency, { \"count\": \"{{count}}\", \"units\": \"{{units}}\", \"ns\": \"customer-portal\" })", + "title_twice_a_month": "{{amount, price}} $t(customer.subscription-form.twice_a_month, { \"ns\": \"customer-portal\" })", + "subtitle_active": "包括運費、稅金等。下次付款日期 {{date, date}}。", + "subtitle_cancelled": "包括運費、稅金等。結束於 {{date, date}}。", + "subtitle_failed": "包括運費、稅金等。付款失敗於 {{date, date}}。", + "subtitle_inactive": "包括運費、稅金等。不活躍。", + "subtitle_will_be_cancelled": "包括運費、稅金等。結束於 {{date, date}}。", + "subtitle_will_be_active": "包括運費、稅金等。開始於 {{date, date}}。", + "copy-id": { + "failed_to_copy": "複製失敗", + "click_to_copy": "複製 ID", + "copying": "複製中...", + "done": "已複製到剪貼板" + }, + "copy-json": { + "failed_to_copy": "複製失敗", + "click_to_copy": "複製原始碼為 JSON", + "copying": "複製中...", + "done": "已複製到剪貼板" + } + }, "day": "天", "day_plural": "天", "week": "星期", @@ -1004,12 +1042,6 @@ "next_transaction_date": "下次交易日期", "price_recurring": "{{amount, price}} $t(customer.subscription-form.frequency, { \"count\": \"{{count}}\", \"units\": \"{{units}}\", \"ns\": \"customer-portal\" })", "price_twice_a_month": "{{amount, price}} $t(customer.subscription-form.twice_a_month, { \"ns\": \"customer-portal\" })", - "subscription_active": "包括运费、税费等。下次付款 {{date, date}}。", - "subscription_cancelled": "包括运费、税金等。结束于 {{date, date}}。", - "subscription_failed": "包括运费、税费等。付款失败于 {{date, date}}。", - "subscription_inactive": "包括运费、税金等。不活跃。", - "subscription_will_be_cancelled": "包括运费、税费等。结束于 {{date, date}}。", - "subscription_will_be_active": "包括运费、税费等。开始于 {{date, date}}。", "transaction_plural": "交易", "twice_a_month": "每月两次", "update_billing": "更新帐单", @@ -1161,8 +1193,14 @@ "text": "创建帐户即表示您同意我们的服务条款。", "link": "单击此处在新选项卡中打开它们。" }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "创建账户" + "caption": "创建账户" }, "spinner": { "refresh": "刷新", @@ -1170,4 +1208,4 @@ "loading_error": "未知错误" } } -} +} \ No newline at end of file diff --git a/src/static/translations/customer/en.json b/src/static/translations/customer/en.json index 197c68ba5..f2476ead7 100644 --- a/src/static/translations/customer/en.json +++ b/src/static/translations/customer/en.json @@ -3,7 +3,7 @@ "attribute_plural": "Attributes", "cancel": "Cancel", "close": "Close", - "create": "Create", + "caption": "Create", "customer": "Customer", "delete_prompt": "This resource will be permanently removed. Are you sure?", "payment_method_plural": "Payment methods", @@ -27,6 +27,29 @@ } }, "address-form": { + "header": { + "title_existing": "Customer address #{{ id }}", + "title_new": "New customer address", + "subtitle_default_shipping": "Default shipping address", + "subtitle_default_billing": "Default billing address", + "subtitle_custom": "Custom address", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, + "error": { + "country_banned": "Store settings prohibit addresses in this country. Please adjust your store settings or use the Ignore address restrictions option.", + "address_name_exists": "Another address with the same name already exists. Please choose a unique name." + }, "address-name": { "label": "Address name", "placeholder": "Required", @@ -94,6 +117,11 @@ "helper_text": "", "v8n_too_long": "Unfortunately we can't store region names longer than 50 characters" }, + "ignore-address-restrictions": { + "label": "Advanced", + "option_true": "Ignore address restrictions", + "helper_text": "By default, the country value must be valid according to the store's location filtering settings. Checking this box will remove this restriction." + }, "timestamps": { "date": "{{value, date}}", "date_created": "Created on", @@ -104,8 +132,14 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove this address? You won't be able to bring it back." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" }, "spinner": { "refresh": "Refresh", @@ -698,6 +732,25 @@ } }, "attribute-form": { + "header": { + "title_existing": "Customer attribute #{{ id }}", + "title_new": "New customer attribute", + "subtitle_private": "Visible only to you", + "subtitle_restricted": "Visible to store admins", + "subtitle_public": "Visible to everyone", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "name": { "label": "Name", "placeholder": "Required", @@ -729,8 +782,14 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove this attribute? You won't be able to bring it back." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" }, "spinner": { "refresh": "Refresh", @@ -739,6 +798,25 @@ } }, "customer-form": { + "header": { + "title_existing": "{{ first_name }} {{ last_name }}", + "title_no_name": "No name", + "title_new": "New customer", + "subtitle_anonymous": "Guest customer #{{ id }}", + "subtitle_registered": "Customer #{{ id }}", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "status": { "password_change_success": "You have successfully set a new password for {{ email }}.", "close": "Close" @@ -812,8 +890,14 @@ "cancel": "Cancel", "delete_prompt": "This action is irreversible. Are you sure you want to delete this customer?" }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" }, "spinner": { "refresh": "Refresh", @@ -835,6 +919,10 @@ "dialog_header_add": "Add payment method", "dialog_header_update": "Update payment method", "update-payment-method-form": { + "header": { + "title_existing": "Update card", + "subtitle": "Enter card details below and click Save card" + }, "status": { "cc_token_success": "Card details saved successfully.", "close": "Close" @@ -987,6 +1075,30 @@ "loading_error": "Unknown error" }, "subscription-form": { + "header": { + "title_new": "Subscription", + "title_existing": "Subscription", + "title_recurring": "{{amount, price}} $t(frequency, { \"count\": \"{{count}}\", \"units\": \"{{units}}\", \"ns\": \"subscription-form\" })", + "title_twice_a_month": "{{amount, price}} $t(twice_a_month, { \"ns\": \"subscription-form\" })", + "subtitle_active": "Including shipping, taxes, etc. Next payment on {{date, date}}.", + "subtitle_cancelled": "Including shipping, taxes, etc. Ended on {{date, date}}.", + "subtitle_failed": "Including shipping, taxes, etc. Payment failed on {{date, date}}.", + "subtitle_inactive": "Including shipping, taxes, etc. Inactive.", + "subtitle_will_be_cancelled": "Including shipping, taxes, etc. Ends on {{date, date}}.", + "subtitle_will_be_active": "Including shipping, taxes, etc. Starts on {{date, date}}.", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "day": "Day", "day_plural": "Days", "week": "Week", @@ -1011,12 +1123,6 @@ "start_date": "Start date", "price_recurring": "{{amount, price}} $t(subscription-form.frequency, { \"count\": \"{{count}}\", \"units\": \"{{units}}\", \"ns\": \"customer\" })", "price_twice_a_month": "{{amount, price}} $t(subscription-form.twice_a_month, { \"ns\": \"customer\" })", - "subscription_active": "Including shipping, taxes, etc. Next payment on {{date, date}}.", - "subscription_cancelled": "Including shipping, taxes, etc. Ended on {{date, date}}.", - "subscription_failed": "Including shipping, taxes, etc. Payment failed on {{date, date}}.", - "subscription_inactive": "Including shipping, taxes, etc. Inactive.", - "subscription_will_be_cancelled": "Including shipping, taxes, etc. Ends on {{date, date}}.", - "subscription_will_be_active": "Including shipping, taxes, etc. Starts on {{date, date}}.", "transaction_plural": "Transactions", "twice_a_month": "Twice a month", "undo_cancel": "Review", @@ -1072,7 +1178,7 @@ "undo_confirm": "Discard", "cancel": "Cancel", "confirm": "Confirm", - "create": "Create", + "caption": "Create", "date": "{{value, date}}", "date_created": "Created on", "date_modified": "Last updated on", @@ -1103,11 +1209,11 @@ "card": { "daily": "Daily", "daily_plural": "Every {{count}} days", - "frequency": "$t(subscription-form.pagination.card.{{units}}, { \"count\": {{count}}, \"ns\": \"customer\" })", + "frequency": "$t(items.pagination.card.{{units}}, { \"count\": {{count}}, \"ns\": \"subscription-form\" })", "monthly": "Monthly", "monthly_plural": "Every {{count}} months", - "subinfo_recurring": "$t(subscription-form.pagination.card.frequency, { \"count\": \"{{count}}\", \"units\": \"{{units}}\", \"ns\": \"customer\" }) from {{startDate, date}}", - "subinfo_twice_a_month": "$t(subscription-form.pagination.card.twice_a_month, { \"ns\": \"customer\" }) from {{startDate, date}}", + "subinfo_recurring": "$t(items.pagination.card.frequency, { \"count\": \"{{count}}\", \"units\": \"{{units}}\", \"ns\": \"subscription-form\" }) from {{startDate, date}}", + "subinfo_twice_a_month": "$t(items.pagination.card.twice_a_month, { \"ns\": \"subscription-form\" }) from {{startDate, date}}", "twice_a_month": "Twice a month", "no_code": "No SKU", "weekly": "Weekly", @@ -1228,4 +1334,4 @@ "loading_error": "Unknown error" } } -} +} \ No newline at end of file diff --git a/src/static/translations/downloadable-form/en.json b/src/static/translations/downloadable-form/en.json index 35ba4cd2f..1ab2e5fd5 100644 --- a/src/static/translations/downloadable-form/en.json +++ b/src/static/translations/downloadable-form/en.json @@ -1,4 +1,21 @@ { + "header": { + "title_existing": "Downloadable #{{ id }}", + "title_new": "New downloadable", + "subtitle": "Uploaded on {{ upload_date, date }}", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "item-category-uri": { "label": "Item category", "placeholder": "", @@ -55,12 +72,18 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove this downloadable? You won't be able to bring it back." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" }, "spinner": { "refresh": "Refresh", "loading_busy": "Loading", "loading_error": "Unknown error" } -} +} \ No newline at end of file diff --git a/src/static/translations/email-template-form/en.json b/src/static/translations/email-template-form/en.json index 75ec1af06..b16c94baa 100644 --- a/src/static/translations/email-template-form/en.json +++ b/src/static/translations/email-template-form/en.json @@ -2,7 +2,7 @@ "cache": "Sync", "cancel": "Cancel", "confirm": "Confirm", - "create": "Create", + "caption": "Create", "date": "{{value, date}}", "date_created": "Created on", "date_modified": "Last updated on", @@ -35,4 +35,4 @@ "loading_busy": "Loading", "loading_error": "Unknown error" } -} +} \ No newline at end of file diff --git a/src/static/translations/filter-attribute-form/en.json b/src/static/translations/filter-attribute-form/en.json index 7b065d8ec..f9f3b2548 100644 --- a/src/static/translations/filter-attribute-form/en.json +++ b/src/static/translations/filter-attribute-form/en.json @@ -37,7 +37,7 @@ "helper_text": "" }, "action": { - "create": "Pin to sidebar", + "caption": "Pin to sidebar", "update": "Save changes", "delete": "Unpin", "reset": "Reset" @@ -47,4 +47,4 @@ "loading_busy": "Loading", "loading_error": "Unknown error" } -} +} \ No newline at end of file diff --git a/src/static/translations/generate-codes-form/en.json b/src/static/translations/generate-codes-form/en.json index 131d0d9bd..b8c1d5982 100644 --- a/src/static/translations/generate-codes-form/en.json +++ b/src/static/translations/generate-codes-form/en.json @@ -30,12 +30,18 @@ "placeholder": "", "helper_text": "This is what the generated codes will look like." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Generate" + "caption": "Generate" }, "spinner": { "refresh": "Refresh", "loading_busy": "Loading", "loading_error": "Unknown error" } -} +} \ No newline at end of file diff --git a/src/static/translations/gift-card-code-form/en.json b/src/static/translations/gift-card-code-form/en.json index d0b41e42c..a11fb1bd4 100644 --- a/src/static/translations/gift-card-code-form/en.json +++ b/src/static/translations/gift-card-code-form/en.json @@ -1,4 +1,21 @@ { + "header": { + "title_existing": "Gift card code #{{ id }}", + "title_new": "New gift card code", + "subtitle": "", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "code": { "label": "Code", "placeholder": "Required", @@ -161,12 +178,18 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove this gift card code? You won't be able to bring it back." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" }, "spinner": { "refresh": "Refresh", "loading_busy": "Loading", "loading_error": "Unknown error" } -} +} \ No newline at end of file diff --git a/src/static/translations/gift-card-codes-form/en.json b/src/static/translations/gift-card-codes-form/en.json index f693259bb..39675a9c7 100644 --- a/src/static/translations/gift-card-codes-form/en.json +++ b/src/static/translations/gift-card-codes-form/en.json @@ -14,12 +14,18 @@ "placeholder": "0", "helper_text": "All imported codes will have this balance." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Import" + "caption": "Import" }, "spinner": { "refresh": "Refresh", "loading_busy": "Loading", "loading_error": "Unknown error" } -} +} \ No newline at end of file diff --git a/src/static/translations/gift-card-form/en.json b/src/static/translations/gift-card-form/en.json index dcbcba20b..8b10140d3 100644 --- a/src/static/translations/gift-card-form/en.json +++ b/src/static/translations/gift-card-form/en.json @@ -1,8 +1,20 @@ { "header": { - "title_existing": "ID {{ id }}", + "title_existing": "{{ name }}", "title_new": "New gift card", - "subtitle": "{{ name }}, {{ currency_code }}" + "subtitle": "Gift card #{{ id }}", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } }, "import": { "button_text": "Import codes", @@ -31,8 +43,14 @@ "placeholder": "0", "helper_text": "All imported codes will have this balance." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Import" + "caption": "Import" }, "spinner": { "refresh": "Refresh", @@ -85,8 +103,14 @@ "placeholder": "", "helper_text": "This is what the generated codes will look like." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Generate" + "caption": "Generate" }, "spinner": { "refresh": "Refresh", @@ -335,6 +359,23 @@ "undo_cancel": "Review", "undo_confirm": "Discard", "gift-card-code-form": { + "header": { + "title_existing": "Gift card code #{{ id }}", + "title_new": "New gift card code", + "subtitle": "", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "code": { "label": "Code", "placeholder": "Required", @@ -497,8 +538,14 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove this gift card code? You won't be able to bring it back." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" }, "spinner": { "refresh": "Refresh", @@ -612,6 +659,25 @@ "undo_cancel": "Review", "undo_confirm": "Discard", "attribute-form": { + "header": { + "title_existing": "Gift card attribute #{{ id }}", + "title_new": "New gift card attribute", + "subtitle_private": "Visible only to you", + "subtitle_restricted": "Visible to store admins", + "subtitle_public": "Visible to everyone", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "name": { "label": "Name", "placeholder": "Required", @@ -643,8 +709,14 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove this attribute? You won't be able to bring it back." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" }, "spinner": { "refresh": "Refresh", @@ -680,12 +752,18 @@ "cancel": "Cancel", "delete_prompt": "This action is irreversible. Are you sure you want to delete this gift card?" }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" }, "spinner": { "refresh": "Refresh", "loading_busy": "Loading", "loading_error": "Unknown error" } -} +} \ No newline at end of file diff --git a/src/static/translations/integration-form/en.json b/src/static/translations/integration-form/en.json index 8cec33070..e244d05de 100644 --- a/src/static/translations/integration-form/en.json +++ b/src/static/translations/integration-form/en.json @@ -1,6 +1,14 @@ { "header": { - "no_description": "No description" + "title_existing": "{{ project_name }}", + "title_new": "New test client", + "subtitle": "{{ project_description }}", + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } }, "message": { "text": "Please copy the highlighted values below to a safe place and treat them like your password. We will not show them again for security reasons.", @@ -29,12 +37,18 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove this token? All applications using this token will lose access to Foxy API immediately." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" }, "spinner": { "refresh": "Refresh", "loading_busy": "Loading", "loading_error": "Unknown error" } -} +} \ No newline at end of file diff --git a/src/static/translations/item-category-form/en.json b/src/static/translations/item-category-form/en.json index 37708d489..813f1ae74 100644 --- a/src/static/translations/item-category-form/en.json +++ b/src/static/translations/item-category-form/en.json @@ -1,4 +1,21 @@ { + "header": { + "title_existing": "Item category #{{ id }}", + "title_new": "New item category", + "subtitle": "", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "name": { "label": "Name", "placeholder": "Books", @@ -14,26 +31,28 @@ "v8n_too_long": "Item categoty code can't exceed 50 characters" }, "taxes": { - "title": "Taxes", - "helper_text": "Select taxes that will apply to the products in this category. Changes here are saved immediately.", + "label": "Taxes", + "status_saving": "Saving...", + "status_loading": "Loading...", "pagination": { "first": "First", "last": "Last", "next": "Next", "pagination": "{{from}}-{{to}} out of {{total}}", "previous": "Previous", - "tax-card": { + "card": { "percent": "{{fraction, percent}}", "tax_global": "Global tax", "tax_rate_provider_default": "Default (Thomson Reuters; others)", "tax_union": "European Union tax", "spinner": { "loading_busy": "Loading", - "loading_empty": "No data", + "loading_empty": "Add a tax in settings to apply it here", "loading_error": "Unknown error" } } - } + }, + "helper_text": "Select taxes that will apply to the products in this category. Changes here are saved immediately." }, "item-delivery-type": { "label": "Delivery", @@ -186,12 +205,18 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove this item category? You won't be able to bring it back." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" }, "spinner": { "refresh": "Refresh", "loading_busy": "Loading", "loading_error": "Unknown error" } -} +} \ No newline at end of file diff --git a/src/static/translations/item-form/en.json b/src/static/translations/item-form/en.json index 954dd3402..1be43a783 100644 --- a/src/static/translations/item-form/en.json +++ b/src/static/translations/item-form/en.json @@ -1,4 +1,22 @@ { + "header": { + "title_existing": "Item #{{ id }}", + "title_new": "New item", + "subtitle_future_line_item": "This item is part of a future subscription", + "subtitle_regular": "", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "dimensions": "Dimensions", "subscriptions": "Subscriptions", "discount": "Discount", @@ -91,7 +109,7 @@ }, "shipto": { "label": "Shipping address", - "helper_text": "Used for multiship to assign this item to a specific shipment.", + "helper_text": "Used for multiship to assign this item to a specific shipment. This value will be the address name of the shipment.", "placeholder": "Select address to ship this item to..." }, "width": { @@ -116,8 +134,40 @@ }, "item-category-uri": { "label": "Item category", - "helper_text": "Item category associated with this item.", - "placeholder": "Select item category..." + "dialog": { + "cancel": "Cancel", + "close": "Close", + "header": "Select an item category", + "selection": { + "label": "Item categories", + "helper_text": "Select an item category to use with this item.", + "search": "Search", + "clear": "Clear", + "pagination": { + "search_button_text": "Search", + "first": "First", + "last": "Last", + "next": "Next", + "pagination": "{{from}}-{{to}} out of {{total}}", + "previous": "Previous", + "card": { + "spinner": { + "loading_busy": "Loading", + "loading_empty": "No item categories found", + "loading_error": "Unknown error" + } + } + } + } + }, + "card": { + "spinner": { + "loading_busy": "Loading", + "loading_empty": "Not assigned – click to select", + "loading_error": "Unknown error" + } + }, + "helper_text": "Item category associated with this item." }, "code": { "label": "Code", @@ -180,6 +230,25 @@ "undo_cancel": "Review", "undo_confirm": "Discard", "attribute-form": { + "header": { + "title_existing": "Item attribute #{{ id }}", + "title_new": "New item attribute", + "subtitle_private": "Visible only to you", + "subtitle_restricted": "Visible to store admins", + "subtitle_public": "Visible to everyone", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "name": { "label": "Name", "placeholder": "Required", @@ -211,8 +280,14 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove this attribute? You won't be able to bring it back." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" }, "spinner": { "refresh": "Refresh", @@ -255,6 +330,23 @@ "undo_cancel": "Review", "undo_confirm": "Discard", "item-option-form": { + "header": { + "title_existing": "Item option #{{ id }}", + "title_new": "New item option", + "subtitle": "", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "name": { "label": "Name", "helper_text": "", @@ -294,8 +386,14 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove this item option? You won't be able to bring it back." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" } } }, @@ -326,12 +424,18 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove this item? You won't be able to bring it back." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" }, "spinner": { "refresh": "Refresh", "loading_busy": "Loading", "loading_error": "Unknown error" } -} +} \ No newline at end of file diff --git a/src/static/translations/item-option-form/en.json b/src/static/translations/item-option-form/en.json index 6a5490f22..2db6ae4f3 100644 --- a/src/static/translations/item-option-form/en.json +++ b/src/static/translations/item-option-form/en.json @@ -1,4 +1,21 @@ { + "header": { + "title_existing": "Item option #{{ id }}", + "title_new": "New item option", + "subtitle": "", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "name": { "label": "Name", "helper_text": "", @@ -38,7 +55,13 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove this item option? You won't be able to bring it back." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" } -} +} \ No newline at end of file diff --git a/src/static/translations/native-integration-form/en.json b/src/static/translations/native-integration-form/en.json index 80a4aab21..18c11d740 100644 --- a/src/static/translations/native-integration-form/en.json +++ b/src/static/translations/native-integration-form/en.json @@ -1,4 +1,28 @@ { + "header": { + "title_existing_avalara": "Avalara", + "title_existing_taxjar": "TaxJar", + "title_existing_onesource": "ONESOURCE", + "title_existing_webflow": "Webflow", + "title_existing_zapier": "Zapier webhook #{{ id }}", + "title_existing_webhook": "Legacy webhook #{{ id }}", + "title_existing_apple_pay": "Apple Pay", + "title_existing_custom_tax": "Custom tax endpoint #{{ id }}", + "title_new": "New native integration", + "subtitle": "", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "error": { "already_configured": "This integration is already configured. Please edit the existing integration instead." }, @@ -269,12 +293,18 @@ "cancel": "Cancel", "delete_prompt": "Please confirm that you want to delete this integration. This action cannot be undone." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" }, "spinner": { "refresh": "Refresh", "loading_busy": "Loading", "loading_error": "Unknown error" } -} +} \ No newline at end of file diff --git a/src/static/translations/passkey-form/en.json b/src/static/translations/passkey-form/en.json index b82156537..8cc638307 100644 --- a/src/static/translations/passkey-form/en.json +++ b/src/static/translations/passkey-form/en.json @@ -1,14 +1,26 @@ { + "header": { + "title_existing": "Passkey #{{ id }}", + "title_new": "", + "subtitle": "Last used on {{ last_login_date, date }}", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "credential-id": { "label": "Credential ID", "placeholder": "", "helper_text": "Unique identifier of your passkey. You might be able to find this passkey by Credential ID in your password manager." }, - "last-login-date": { - "label": "Last login date", - "placeholder": "", - "helper_text": "The last time this passkey was used to sign in to your Foxy Account." - }, "last-login-ua": { "label": "Last browser", "placeholder": "", @@ -24,12 +36,18 @@ "cancel": "Cancel", "delete_prompt": "Once deleted, this passkey will no longer be accepted on login but will remain in your password manager. Sessions created with this passkey will stay active." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" }, "spinner": { "refresh": "Refresh", "loading_busy": "Loading", "loading_error": "Unknown error" } -} +} \ No newline at end of file diff --git a/src/static/translations/payments-api-fraud-protection-form/en.json b/src/static/translations/payments-api-fraud-protection-form/en.json index 5bd0feb4d..9ac95f6c4 100644 --- a/src/static/translations/payments-api-fraud-protection-form/en.json +++ b/src/static/translations/payments-api-fraud-protection-form/en.json @@ -1,6 +1,18 @@ { + "header": { + "title_new": "New fraud protection", + "title_minfraud": "MaxMind minFraud", + "title_google_recaptcha": "Google reCAPTCHA", + "title_custom_precheckout_hook": "Pre-checkout webhook", + "subtitle": "Fraud protection #{{ id }}", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "default_additional_field_placeholder": "None", - "select_protection_title": "Select a fraud protection type to get started", "select_another_button_label": "Back to fraud protections", "score-threshold-reject": { "label": "Rejection threshold", @@ -29,7 +41,13 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove this fraud protection? You'll need to configure it again if you decide to add it back." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Add fraud protection" + "caption": "Add fraud protection" } -} +} \ No newline at end of file diff --git a/src/static/translations/payments-api-payment-method-form/en.json b/src/static/translations/payments-api-payment-method-form/en.json index f780a0802..896d538af 100644 --- a/src/static/translations/payments-api-payment-method-form/en.json +++ b/src/static/translations/payments-api-payment-method-form/en.json @@ -1,5 +1,21 @@ { - "select_method_title": "Select a payment method", + "header": { + "title_new": "New payment method", + "title_selected": "{{ name }}", + "subtitle_regular": "Payment gateway #{{ id }}", + "subtitle_hosted": "Hosted payment gateway #{{ id }}", + "subtitle": "", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, + "list-spinner": { + "loading_busy": "Loading payment methods...", + "loading_error": "Unknown error. Failed to load payment methods." + }, "select_another_button_label": "Select another", "default_additional_field_placeholder": "None", "conflict_message": "Remove {{ name }} to use this method", @@ -56,7 +72,13 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove this payment method? You'll need to configure it again if you decide to bring it back." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" } -} +} \ No newline at end of file diff --git a/src/static/translations/payments-api-payment-preset-form/en.json b/src/static/translations/payments-api-payment-preset-form/en.json index ab0b88229..2a2a0f940 100644 --- a/src/static/translations/payments-api-payment-preset-form/en.json +++ b/src/static/translations/payments-api-payment-preset-form/en.json @@ -1,4 +1,15 @@ { + "header": { + "title_existing": "Payment method set #{{ id }}", + "title_new": "New payment method set", + "subtitle": "", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "description": { "label": "Description", "placeholder": "E.g. EU & UK Payment Options", @@ -55,7 +66,67 @@ "undo_header": "Unsaved changes", "undo_message": "Looks like you didn't save your changes! What would you like to do with them?", "undo_cancel": "Review", - "undo_confirm": "Discard" + "undo_confirm": "Discard", + "payments-api-fraud-protection-form": { + "header": { + "title_new": "New fraud protection", + "title_minfraud": "MaxMind minFraud", + "title_google_recaptcha": "Google reCAPTCHA", + "title_custom_precheckout_hook": "Pre-checkout webhook", + "subtitle": "Fraud protection #{{ id }}", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, + "default_additional_field_placeholder": "None", + "select_protection_title": "Select a fraud protection type to get started", + "select_another_button_label": "Back to fraud protections", + "score-threshold-reject": { + "label": "Rejection threshold", + "placeholder": "Default", + "helper_text": "A number between 0 and 100. 0 will disable minFraud and 100 will turn it on for logging but still allow all transactions to go through.", + "v8n_out_of_range": "Please enter a whole number between 0 and 100 (inclusive)." + }, + "description": { + "label": "Description", + "placeholder": "None", + "helper_text": "", + "v8n_too_long": "Please reduce this description to a 100 characters or less" + }, + "timestamps": { + "date_created": "Created on", + "date_modified": "Last updated on", + "date": "{{value, date}}" + }, + "spinner": { + "refresh": "Refresh", + "loading_busy": "Loading", + "loading_error": "Unknown error" + }, + "delete": { + "delete": "Remove", + "cancel": "Cancel", + "delete_prompt": "Are you sure you'd like to remove this fraud protection? You'll need to configure it again if you decide to add it back." + }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, + "create": { + "caption": "Add fraud protection" + } + } }, "pagination": { "create_button_text": "Add fraud protection +", @@ -79,7 +150,13 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove this payment method set? You won't be able to bring it back." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" } -} +} \ No newline at end of file diff --git a/src/static/translations/report-form/en.json b/src/static/translations/report-form/en.json index 347ff3dfb..6371cbc8a 100644 --- a/src/static/translations/report-form/en.json +++ b/src/static/translations/report-form/en.json @@ -1,6 +1,6 @@ { "cancel": "Cancel", - "create": "Create", + "caption": "Create", "date": "{{value, date}}", "date_created": "Created on", "date_modified": "Last updated on", @@ -36,4 +36,4 @@ "loading_busy": "Loading", "loading_error": "Unknown error" } -} +} \ No newline at end of file diff --git a/src/static/translations/shipping-container-card/en.json b/src/static/translations/shipping-container-card/en.json new file mode 100644 index 000000000..19c0728d1 --- /dev/null +++ b/src/static/translations/shipping-container-card/en.json @@ -0,0 +1,8 @@ +{ + "subtitle": "Code: {{ code }}", + "spinner": { + "loading_busy": "Loading", + "loading_empty": "No data", + "loading_error": "Unknown error" + } +} diff --git a/src/static/translations/shipping-drop-type-card/en.json b/src/static/translations/shipping-drop-type-card/en.json new file mode 100644 index 000000000..19c0728d1 --- /dev/null +++ b/src/static/translations/shipping-drop-type-card/en.json @@ -0,0 +1,8 @@ +{ + "subtitle": "Code: {{ code }}", + "spinner": { + "loading_busy": "Loading", + "loading_empty": "No data", + "loading_error": "Unknown error" + } +} diff --git a/src/static/translations/shipping-method-card/en.json b/src/static/translations/shipping-method-card/en.json index 4aae46406..289cf2d29 100644 --- a/src/static/translations/shipping-method-card/en.json +++ b/src/static/translations/shipping-method-card/en.json @@ -1,6 +1,7 @@ { "image_alt": "Shipping method logo", "status_active": "Active", + "status_inactive": "Inactive", "spinner": { "loading_busy": "Loading", "loading_empty": "No data", diff --git a/src/static/translations/shipping-service-card/en.json b/src/static/translations/shipping-service-card/en.json new file mode 100644 index 000000000..ed08fcbcd --- /dev/null +++ b/src/static/translations/shipping-service-card/en.json @@ -0,0 +1,9 @@ +{ + "subtitle": "Code: {{ code }}", + "subtitle_international_only": "Code: {{ code }} • International Only", + "spinner": { + "loading_busy": "Loading", + "loading_empty": "No data", + "loading_error": "Unknown error" + } +} diff --git a/src/static/translations/store-form/en.json b/src/static/translations/store-form/en.json index d8390cbef..cbea74690 100644 --- a/src/static/translations/store-form/en.json +++ b/src/static/translations/store-form/en.json @@ -1,4 +1,21 @@ { + "header": { + "title_existing": "Store #{{ id }}", + "title_new": "New store", + "subtitle": "", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "maintenance_mode_on_explainer": "Maintenance mode is on. Your customers can't make purchases or use the checkout page in any way. Once you're done making changes, disable this mode to continue getting orders.", "maintenance_mode_off_explainer": "If you're about to make changes that may disrupt the checkout process, we recommend enabling the maintenance mode first. In this mode the checkout page will be completely non-functioning and the customers will see a message asking them to come back later.", "enable_maintenance_mode": "Enable maintenance mode", @@ -14,7 +31,7 @@ "label": "Emails", "placeholder": "Enter an email and press Enter", "helper_text": "Email addresses used for billing and communication with Foxy.", - "submit": "Submit", + "caption": "Submit", "delete": "Delete", "v8n_required": "Please enter at least one email", "v8n_too_long": "All emails for this store must fit within 300 characters when comma-separated" @@ -311,7 +328,13 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove this store? You won't be able to bring it back." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" } -} +} \ No newline at end of file diff --git a/src/static/translations/store-shipping-method-form/en.json b/src/static/translations/store-shipping-method-form/en.json index 78905d15f..e59906dea 100644 --- a/src/static/translations/store-shipping-method-form/en.json +++ b/src/static/translations/store-shipping-method-form/en.json @@ -1,19 +1,133 @@ { + "header": { + "title_existing": "{{ provider }}", + "title_new": "New shipping method", + "subtitle": "Shipping method #{{ id }}", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "shipping-method-uri": { - "label": "Shipping Method", - "placeholder": "Select service", + "label": "Provider", + "dialog": { + "cancel": "Cancel", + "close": "Close", + "header": "Select a provider", + "selection": { + "label": "Providers", + "helper_text": "", + "pagination": { + "first": "First", + "last": "Last", + "next": "Next", + "pagination": "{{from}}-{{to}} out of {{total}}", + "previous": "Previous", + "card": { + "image_alt": "Shipping method logo", + "status_active": "Active", + "status_inactive": "Inactive", + "spinner": { + "loading_busy": "Loading", + "loading_empty": "No providers found", + "loading_error": "Unknown error" + } + } + } + } + }, + "card": { + "image_alt": "Shipping method logo", + "status_active": "Active", + "status_inactive": "Inactive", + "spinner": { + "loading_busy": "Loading", + "loading_empty": "Select a provider", + "loading_error": "Unknown error" + } + }, "helper_text": "", - "v8n_required": "Please select a shipping method." + "v8n_required": "Please select a provider." }, "shipping-container-uri": { "label": "Container", - "placeholder": "Select container", + "dialog": { + "cancel": "Cancel", + "close": "Close", + "header": "Select a container", + "selection": { + "label": "Containers", + "helper_text": "", + "pagination": { + "first": "First", + "last": "Last", + "next": "Next", + "pagination": "{{from}}-{{to}} out of {{total}}", + "previous": "Previous", + "card": { + "subtitle": "Code: {{ code }}", + "spinner": { + "loading_busy": "Loading", + "loading_empty": "No containers found", + "loading_error": "Unknown error" + } + } + } + } + }, + "card": { + "subtitle": "Code: {{ code }}", + "spinner": { + "loading_busy": "Loading", + "loading_empty": "Select a container", + "loading_error": "Unknown error" + } + }, "helper_text": "", - "v8n_required": "Please select a shipping method." + "v8n_required": "Please select a shipping container." }, "shipping-drop-type-uri": { - "label": "Drop Type", - "placeholder": "Select pickup", + "label": "Drop type", + "dialog": { + "cancel": "Cancel", + "close": "Close", + "header": "Select a drop type", + "selection": { + "label": "Drop types", + "helper_text": "", + "pagination": { + "first": "First", + "last": "Last", + "next": "Next", + "pagination": "{{from}}-{{to}} out of {{total}}", + "previous": "Previous", + "card": { + "subtitle": "Code: {{ code }}", + "spinner": { + "loading_busy": "Loading", + "loading_empty": "No drop types found", + "loading_error": "Unknown error" + } + } + } + } + }, + "card": { + "subtitle": "Code: {{ code }}", + "spinner": { + "loading_busy": "Loading", + "loading_empty": "Select a drop type", + "loading_error": "Unknown error" + } + }, "helper_text": "", "v8n_required": "Please select a drop type." }, @@ -21,7 +135,7 @@ "label": "Destinations", "domestic": "Domestic", "international": "International", - "helper_text": "" + "helper_text": "Select which shipping rate requests to apply this shipping method to." }, "authentication-key": { "label": "Authentication Key", @@ -61,14 +175,25 @@ }, "services": { "label": "Additional services", - "first": "First", - "last": "Last", - "next": "Next", - "pagination": "{{from}}-{{to}} out of {{total}}", - "previous": "Previous", - "loading_busy": "Loading", - "loading_error": "Unknown error", - "international_only": "– international only" + "status_saving": "Saving...", + "status_loading": "Loading...", + "pagination": { + "first": "First", + "last": "Last", + "next": "Next", + "pagination": "{{from}}-{{to}} out of {{total}}", + "previous": "Previous", + "card": { + "subtitle": "Code: {{ code }}", + "subtitle_international_only": "Code: {{ code }} • International Only", + "spinner": { + "loading_busy": "Loading", + "loading_empty": "No additional services available", + "loading_error": "Unknown error" + } + } + }, + "helper_text": "Enable additional services for this shipping method. All changes here are saved automatically." }, "timestamps": { "date_created": "Created on", @@ -80,12 +205,18 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove this shipping method? You won't be able to undo if you click Delete." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" }, "spinner": { "refresh": "Refresh", "loading_busy": "Loading", "loading_error": "Unknown error" } -} +} \ No newline at end of file diff --git a/src/static/translations/subscription-form/en.json b/src/static/translations/subscription-form/en.json index abe3ef5c5..a6cda3d04 100644 --- a/src/static/translations/subscription-form/en.json +++ b/src/static/translations/subscription-form/en.json @@ -1,4 +1,28 @@ { + "header": { + "title_new": "Subscription", + "title_existing": "Subscription", + "title_recurring": "{{amount, price}} $t(frequency, { \"count\": \"{{count}}\", \"units\": \"{{units}}\", \"ns\": \"subscription-form\" })", + "title_twice_a_month": "{{amount, price}} $t(twice_a_month, { \"ns\": \"subscription-form\" })", + "subtitle_active": "Including shipping, taxes, etc. Next payment on {{date, date}}.", + "subtitle_cancelled": "Including shipping, taxes, etc. Ended on {{date, date}}.", + "subtitle_failed": "Including shipping, taxes, etc. Payment failed on {{date, date}}.", + "subtitle_inactive": "Including shipping, taxes, etc. Inactive.", + "subtitle_will_be_cancelled": "Including shipping, taxes, etc. Ends on {{date, date}}.", + "subtitle_will_be_active": "Including shipping, taxes, etc. Starts on {{date, date}}.", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "day": "Day", "day_plural": "Days", "week": "Week", @@ -23,12 +47,6 @@ "start_date": "Start date", "price_recurring": "{{amount, price}} $t(frequency, { \"count\": \"{{count}}\", \"units\": \"{{units}}\", \"ns\": \"subscription-form\" })", "price_twice_a_month": "{{amount, price}} $t(twice_a_month, { \"ns\": \"subscription-form\" })", - "subscription_active": "Including shipping, taxes, etc. Next payment on {{date, date}}.", - "subscription_cancelled": "Including shipping, taxes, etc. Ended on {{date, date}}.", - "subscription_failed": "Including shipping, taxes, etc. Payment failed on {{date, date}}.", - "subscription_inactive": "Including shipping, taxes, etc. Inactive.", - "subscription_will_be_cancelled": "Including shipping, taxes, etc. Ends on {{date, date}}.", - "subscription_will_be_active": "Including shipping, taxes, etc. Starts on {{date, date}}.", "transaction_plural": "Transactions", "twice_a_month": "Twice a month", "undo_cancel": "Review", @@ -84,7 +102,7 @@ "undo_confirm": "Discard", "cancel": "Cancel", "confirm": "Confirm", - "create": "Create", + "caption": "Create", "date": "{{value, date}}", "date_created": "Created on", "date_modified": "Last updated on", @@ -188,4 +206,4 @@ "date_modified": "Last updated on", "date": "{{value, date}}" } -} +} \ No newline at end of file diff --git a/src/static/translations/subscription-settings-form/en.json b/src/static/translations/subscription-settings-form/en.json index 3c405b9dd..40f5bcda8 100644 --- a/src/static/translations/subscription-settings-form/en.json +++ b/src/static/translations/subscription-settings-form/en.json @@ -1,4 +1,15 @@ { + "header": { + "title_new": "Subscription settings", + "title_existing": "Subscription settings", + "subtitle": "", + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "day": "{{ count }} day", "day_plural": "{{ count }} days", "day_suffix": "day", @@ -87,7 +98,13 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove these subscription settings? You won't be able to bring them back." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" } -} +} \ No newline at end of file diff --git a/src/static/translations/tax-form/en.json b/src/static/translations/tax-form/en.json index 55a23ce73..51be150d6 100644 --- a/src/static/translations/tax-form/en.json +++ b/src/static/translations/tax-form/en.json @@ -2,7 +2,7 @@ "cancel": "Cancel", "city": "City", "country": "Country", - "create": "Create", + "caption": "Create", "date": "{{value, date}}", "date_created": "Created on", "date_modified": "Last updated on", @@ -36,4 +36,4 @@ "loading_busy": "Loading", "loading_error": "Unknown error" } -} +} \ No newline at end of file diff --git a/src/static/translations/template-config-form/en.json b/src/static/translations/template-config-form/en.json index b84cf5aa0..2a28ca1ac 100644 --- a/src/static/translations/template-config-form/en.json +++ b/src/static/translations/template-config-form/en.json @@ -32,7 +32,7 @@ "copy": "Copy", "country": "Country", "coupon_entry": "Coupon code", - "create": "Create", + "caption": "Create", "custom_config": "Custom config", "custom_config_helper_text": "If you have any custom values you'd like to make available to your twig template, you can add them here as a valid JSON string.", "custom_fields": "Custom fields", @@ -112,4 +112,4 @@ "loading_busy": "Loading", "loading_error": "Unknown error" } -} +} \ No newline at end of file diff --git a/src/static/translations/template-form/en.json b/src/static/translations/template-form/en.json index d624c87ac..81da28f7b 100644 --- a/src/static/translations/template-form/en.json +++ b/src/static/translations/template-form/en.json @@ -1,7 +1,7 @@ { "cache": "Sync", "cancel": "Cancel", - "create": "Create", + "caption": "Create", "date": "{{value, date}}", "date_created": "Created on", "date_modified": "Last updated on", @@ -23,4 +23,4 @@ "loading_busy": "Loading", "loading_error": "Unknown error" } -} +} \ No newline at end of file diff --git a/src/static/translations/template-set-form/en.json b/src/static/translations/template-set-form/en.json index 18358022f..5cf8d8c38 100644 --- a/src/static/translations/template-set-form/en.json +++ b/src/static/translations/template-set-form/en.json @@ -1,4 +1,22 @@ { + "header": { + "title_new": "New template set", + "title_existing": "Template set #{{ id }}", + "subtitle": "", + "subtitle_default": "Default template set", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "description": { "label": "Description", "placeholder": "Required - e.g. My Template Set", @@ -27,7 +45,40 @@ }, "payment-method-set-uri": { "label": "Payment method set", - "placeholder": "Default payment method set", + "dialog": { + "cancel": "Cancel", + "close": "Close", + "header": "Select a payment method set", + "selection": { + "label": "Payment method sets", + "helper_text": "", + "pagination": { + "first": "First", + "last": "Last", + "next": "Next", + "pagination": "{{from}}-{{to}} out of {{total}}", + "previous": "Previous", + "card": { + "status_test": "Test", + "status_live": "Live", + "spinner": { + "loading_busy": "Loading", + "loading_empty": "No payment method sets found", + "loading_error": "Unknown error" + } + } + } + } + }, + "card": { + "status_test": "Test", + "status_live": "Live", + "spinner": { + "loading_busy": "Loading", + "loading_empty": "Select a payment method set", + "loading_error": "Unknown error" + } + }, "helper_text": "With this template set applied, your customers will see payment methods from the selected set." }, "language-overrides": { @@ -51,12 +102,18 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove this template set? You won't be able to bring it back." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" }, "spinner": { "refresh": "Refresh", "loading_busy": "Loading", "loading_error": "Unknown error" } -} +} \ No newline at end of file diff --git a/src/static/translations/transaction/en.json b/src/static/translations/transaction/en.json index 9f09731a7..58aba6639 100644 --- a/src/static/translations/transaction/en.json +++ b/src/static/translations/transaction/en.json @@ -1,6 +1,6 @@ { "header": { - "title": "ID {{ display_id }}", + "title": "Transaction #{{ display_id }}", "subtitle": "{{ transaction_date, date }} at {{ transaction_date, time }} • {{ ip_country }}", "subtitle_customer_changed_payment_method": "{{ transaction_date, date }} at {{ transaction_date, time }} • {{ ip_country }} • Customer changed payment method", "subtitle_admin_changed_payment_method_with_uoe": "{{ transaction_date, date }} at {{ transaction_date, time }} • Store admin used UOE password to change payment method", @@ -24,7 +24,19 @@ "alert_status_problem": "We were unable to complete this transaction because the amount that was sent to the payment gateway did not match the final total amount.", "alert_status_pending_fraud_review": "The payment gateway flagged this transaction as potentially fraudulent. Please log in to your gateway’s dashboard and look for this transaction to review.", "alert_status_rejected": "The payment gateway refused to process this transaction based on its internal policy. You may be able to get more information about this error by logging in to your gateway’s dashboard and looking for this transaction.", - "alert_status_declined": "The payment method used for this transaction was declined. This could be due to insufficient funds, an expired card, or a different reason. You may be able to get more information about this error in your gateway’s dashboard." + "alert_status_declined": "The payment method used for this transaction was declined. This could be due to insufficient funds, an expired card, or a different reason. You may be able to get more information about this error in your gateway’s dashboard.", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } }, "customer": { "label": "Customer", @@ -83,6 +95,24 @@ "undo_cancel": "Review", "undo_confirm": "Discard", "item-form": { + "header": { + "title_existing": "Item #{{ id }}", + "title_new": "New item", + "subtitle_future_line_item": "This item is part of a future subscription", + "subtitle_regular": "", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "dimensions": "Dimensions", "subscriptions": "Subscriptions", "discount": "Discount", @@ -108,6 +138,7 @@ }, "subscription-frequency": { "label": "Subscription frequency", + "helper_text": "", "day": "Day", "day_plural": "Days", "week": "Week", @@ -174,7 +205,7 @@ }, "shipto": { "label": "Shipping address", - "helper_text": "Used for multiship to assign this item to a specific shipment.", + "helper_text": "Used for multiship to assign this item to a specific shipment. This value will be the address name of the shipment.", "placeholder": "Select address to ship this item to..." }, "width": { @@ -199,8 +230,40 @@ }, "item-category-uri": { "label": "Item category", - "helper_text": "Item category associated with this item.", - "placeholder": "Select item category..." + "dialog": { + "cancel": "Cancel", + "close": "Close", + "header": "Select an item category", + "selection": { + "label": "Item categories", + "helper_text": "Select an item category to use with this item.", + "search": "Search", + "clear": "Clear", + "pagination": { + "search_button_text": "Search", + "first": "First", + "last": "Last", + "next": "Next", + "pagination": "{{from}}-{{to}} out of {{total}}", + "previous": "Previous", + "card": { + "spinner": { + "loading_busy": "Loading", + "loading_empty": "No item categories found", + "loading_error": "Unknown error" + } + } + } + } + }, + "card": { + "spinner": { + "loading_busy": "Loading", + "loading_empty": "Not assigned – click to select", + "loading_error": "Unknown error" + } + }, + "helper_text": "Item category associated with this item." }, "code": { "label": "Code", @@ -213,7 +276,7 @@ "placeholder": "MY-BUNDLE-001" }, "discount-details": { - "title": "Discounts", + "title": "Discount details", "pagination": { "first": "First", "last": "Last", @@ -223,14 +286,14 @@ "card": { "spinner": { "loading_busy": "Loading", - "loading_empty": "No discounts", + "loading_empty": "No data", "loading_error": "Unknown error" } } } }, "coupon-details": { - "title": "Coupons", + "title": "Coupon details", "pagination": { "first": "First", "last": "Last", @@ -240,7 +303,7 @@ "card": { "spinner": { "loading_busy": "Loading", - "loading_empty": "No coupons", + "loading_empty": "No data", "loading_error": "Unknown error" } } @@ -263,6 +326,25 @@ "undo_cancel": "Review", "undo_confirm": "Discard", "attribute-form": { + "header": { + "title_existing": "Item attribute #{{ id }}", + "title_new": "New item attribute", + "subtitle_private": "Visible only to you", + "subtitle_restricted": "Visible to store admins", + "subtitle_public": "Visible to everyone", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "name": { "label": "Name", "placeholder": "Required", @@ -294,8 +376,14 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove this attribute? You won't be able to bring it back." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" }, "spinner": { "refresh": "Refresh", @@ -310,7 +398,7 @@ "delete_button_text": "Delete", "spinner": { "loading_busy": "Loading", - "loading_empty": "No attributes", + "loading_empty": "No data", "loading_error": "Unknown error" } }, @@ -338,6 +426,23 @@ "undo_cancel": "Review", "undo_confirm": "Discard", "item-option-form": { + "header": { + "title_existing": "Item option #{{ id }}", + "title_new": "New item option", + "subtitle": "", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "name": { "label": "Name", "helper_text": "", @@ -377,8 +482,14 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove this item option? You won't be able to bring it back." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" } } }, @@ -387,7 +498,7 @@ "delete_button_text": "Delete", "spinner": { "loading_busy": "Loading", - "loading_empty": "No item options", + "loading_empty": "No data", "loading_error": "Unknown error" } }, @@ -409,8 +520,14 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove this item? You won't be able to bring it back." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" }, "spinner": { "refresh": "Refresh", @@ -437,6 +554,23 @@ "undo_cancel": "Review", "undo_confirm": "Discard", "custom-field-form": { + "header": { + "title_existing": "Transaction custom field #{{ id }}", + "title_new": "New transaction custom field", + "subtitle": "", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "name": { "label": "Name", "placeholder": "Required", @@ -466,8 +600,14 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove this custom field? You won't be able to bring it back." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" }, "spinner": { "refresh": "Refresh", @@ -510,6 +650,25 @@ "undo_cancel": "Review", "undo_confirm": "Discard", "attribute-form": { + "header": { + "title_existing": "ID {{ id }}", + "title_new": "New attribute", + "subtitle_private": "Visible only to you", + "subtitle_restricted": "Visible to store admins", + "subtitle_public": "Visible to everyone", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "name": { "label": "Name", "placeholder": "Required", @@ -541,8 +700,14 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove this attribute? You won't be able to bring it back." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" }, "spinner": { "refresh": "Refresh", @@ -622,6 +787,29 @@ "cancel": "Cancel", "header_update": "Billing address", "address-form": { + "header": { + "title_existing": "ID {{ id }}", + "title_new": "New address", + "subtitle_default_shipping": "Default shipping address", + "subtitle_default_billing": "Default billing address", + "subtitle_custom": "Custom address", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, + "error": { + "country_banned": "Store settings prohibit addresses in this country. Please adjust your store settings or use the Ignore address restrictions option.", + "address_name_exists": "Another address with the same name already exists. Please choose a unique name." + }, "address-name": { "label": "Address name", "placeholder": "Required", @@ -689,6 +877,11 @@ "helper_text": "", "v8n_too_long": "Unfortunately we can't store region names longer than 50 characters" }, + "ignore-address-restrictions": { + "label": "Advanced", + "option_true": "Ignore address restrictions", + "helper_text": "By default, the country value must be valid according to the store's location filtering settings. Checking this box will remove this restriction." + }, "timestamps": { "date": "{{value, date}}", "date_created": "Created on", @@ -699,8 +892,14 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove this address? You won't be able to bring it back." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" }, "spinner": { "refresh": "Refresh", @@ -1381,4 +1580,4 @@ "loading_empty": "No data", "loading_error": "Unknown error" } -} +} \ No newline at end of file diff --git a/src/static/translations/update-payment-method-form/en.json b/src/static/translations/update-payment-method-form/en.json index c3abc3f44..e6b7a4834 100644 --- a/src/static/translations/update-payment-method-form/en.json +++ b/src/static/translations/update-payment-method-form/en.json @@ -1,4 +1,8 @@ { + "header": { + "title_existing": "Update card", + "subtitle": "Enter card details below and click Save card" + }, "status": { "cc_token_success": "Card details saved successfully.", "close": "Close" @@ -137,4 +141,4 @@ "loading_error": "Unknown error", "loading_empty": "This form works only with existing payment methods" } -} +} \ No newline at end of file diff --git a/src/static/translations/user-form/en.json b/src/static/translations/user-form/en.json index d74250cb1..c346a78f5 100644 --- a/src/static/translations/user-form/en.json +++ b/src/static/translations/user-form/en.json @@ -1,4 +1,22 @@ { + "header": { + "title_new": "New user", + "title_existing": "User #{{ id }}", + "subtitle": "", + "subtitle_affiliate": "Affiliate #{{ affiliate_id }}", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "first-name": { "label": "First name", "placeholder": "Required", @@ -50,12 +68,18 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove this account? You won't be able to bring it back." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" }, "spinner": { "refresh": "Refresh", "loading_busy": "Loading", "loading_error": "Unknown error" } -} +} \ No newline at end of file diff --git a/src/static/translations/users-table/en.json b/src/static/translations/users-table/en.json index 34bc3f5fd..d13a0022f 100644 --- a/src/static/translations/users-table/en.json +++ b/src/static/translations/users-table/en.json @@ -68,8 +68,14 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove this account? You won't be able to bring it back." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" }, "spinner": { "refresh": "Refresh", @@ -77,4 +83,4 @@ "loading_error": "Unknown error" } } -} +} \ No newline at end of file diff --git a/src/static/translations/webhook-form/en.json b/src/static/translations/webhook-form/en.json index 82e97b549..0abec707a 100644 --- a/src/static/translations/webhook-form/en.json +++ b/src/static/translations/webhook-form/en.json @@ -1,4 +1,24 @@ { + "header": { + "title_new": "New webhook", + "title_existing": "Webhook #{{ id }}", + "subtitle": "", + "subtitle_transaction": "Transaction webhook", + "subtitle_subscription": "Subscription webhook", + "subtitle_customer": "Customer webhook", + "copy-id": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy ID", + "copying": "Copying...", + "done": "Copied to clipboard" + }, + "copy-json": { + "failed_to_copy": "Failed to copy", + "click_to_copy": "Copy source as JSON", + "copying": "Copying...", + "done": "Copied to clipboard" + } + }, "name": { "label": "Name", "placeholder": "My JSON Webhook", @@ -43,7 +63,7 @@ "event_resource_customer": "Customer" }, "statuses": { - "title": "Statuses", + "label": "Runs", "pagination": { "first": "First", "last": "Last", @@ -54,17 +74,17 @@ "status_successful": "Successful", "status_pending": "Pending", "status_failed": "Failed", - "date": "{{value, date}}", + "date": "{{ value, date }} at {{ value, time }}", "spinner": { "loading_busy": "Loading", "loading_error": "Unknown error", - "loading_empty": "No data" + "loading_empty": "This webhook has not been triggered yet." } } } }, "logs": { - "title": "Logs", + "label": "Logs", "pagination": { "first": "First", "last": "Last", @@ -72,11 +92,11 @@ "pagination": "{{from}}-{{to}} out of {{total}}", "previous": "Previous", "card": { - "date": "{{value, date}}", + "date": "{{ value, date }} at {{ value, time }}", "spinner": { "loading_busy": "Loading", "loading_error": "Unknown error", - "loading_empty": "No data" + "loading_empty": "This webhook has not been triggered yet." } } } @@ -91,12 +111,18 @@ "cancel": "Cancel", "delete_prompt": "Are you sure you'd like to remove this webhook? You won't be able to bring it back." }, + "undo": { + "caption": "Undo" + }, + "submit": { + "caption": "Save changes" + }, "create": { - "create": "Create" + "caption": "Create" }, "spinner": { "refresh": "Refresh", "loading_busy": "Loading", "loading_error": "Unknown error" } -} +} \ No newline at end of file diff --git a/src/static/translations/webhook-log-card/en.json b/src/static/translations/webhook-log-card/en.json index f2a476f8b..50972004b 100644 --- a/src/static/translations/webhook-log-card/en.json +++ b/src/static/translations/webhook-log-card/en.json @@ -1,8 +1,8 @@ { - "date": "{{value, date}}", + "date": "{{ value, date }} at {{ value, time }}", "spinner": { "loading_busy": "Loading", "loading_error": "Unknown error", "loading_empty": "No data" } -} +} \ No newline at end of file diff --git a/src/static/translations/webhook-status-card/en.json b/src/static/translations/webhook-status-card/en.json index 5ae78960c..7b8224784 100644 --- a/src/static/translations/webhook-status-card/en.json +++ b/src/static/translations/webhook-status-card/en.json @@ -2,10 +2,10 @@ "status_successful": "Successful", "status_pending": "Pending", "status_failed": "Failed", - "date": "{{value, date}}", + "date": "{{ value, date }} at {{ value, time }}", "spinner": { "loading_busy": "Loading", "loading_error": "Unknown error", "loading_empty": "No data" } -} +} \ No newline at end of file diff --git a/web-test-runner.groups.js b/web-test-runner.groups.js index e0b20542f..8d95ef535 100644 --- a/web-test-runner.groups.js +++ b/web-test-runner.groups.js @@ -39,10 +39,6 @@ export const groups = [ name: 'foxy-internal-control', files: './src/elements/internal/InternalControl/**/*.test.ts', }, - { - name: 'foxy-internal-create-control', - files: './src/elements/internal/InternalCreateControl/**/*.test.ts', - }, { name: 'foxy-internal-date-control', files: './src/elements/internal/InternalDateControl/**/*.test.ts', @@ -107,6 +103,10 @@ export const groups = [ name: 'foxy-internal-source-control', files: './src/elements/internal/InternalSourceControl/**/*.test.ts', }, + { + name: 'foxy-internal-submit-control', + files: './src/elements/internal/InternalSubmitControl/**/*.test.ts', + }, { name: 'foxy-internal-text-area-control', files: './src/elements/internal/InternalTextAreaControl/**/*.test.ts', @@ -119,6 +119,10 @@ export const groups = [ name: 'foxy-internal-timestamps-control', files: './src/elements/internal/InternalTimestampsControl/**/*.test.ts', }, + { + name: 'foxy-internal-undo-control', + files: './src/elements/internal/InternalUndoControl/**/*.test.ts', + }, { name: 'x-checkbox', files: './src/elements/private/Checkbox/**/*.test.ts', @@ -539,10 +543,22 @@ export const groups = [ name: 'foxy-shipment-card', files: './src/elements/public/ShipmentCard/**/*.test.ts', }, + { + name: 'foxy-shipping-container-card', + files: './src/elements/public/ShippingContainerCard/**/*.test.ts', + }, + { + name: 'foxy-shipping-drop-type-card', + files: './src/elements/public/ShippingDropTypeCard/**/*.test.ts', + }, { name: 'foxy-shipping-method-card', files: './src/elements/public/ShippingMethodCard/**/*.test.ts', }, + { + name: 'foxy-shipping-service-card', + files: './src/elements/public/ShippingServiceCard/**/*.test.ts', + }, { name: 'foxy-sign-in-form', files: './src/elements/public/SignInForm/**/*.test.ts', diff --git a/wiki/mixins.md b/wiki/mixins.md index 1600cb55e..96c74ff29 100644 --- a/wiki/mixins.md +++ b/wiki/mixins.md @@ -177,56 +177,3 @@ export class CustomFieldForm extends ConfigurableMixin(NucleonElement) { ``` - -### Documenting Controls - -Step 1: add `Templates` type definition to the `types.ts` file in your element folder. Describe each template like below using the `Renderer` generic from the configurable mixin file: - -```ts -import { Renderer } from '../../../mixins/configurable'; -import { CustomFieldForm } from './CustomFieldForm'; - -export type Templates = { - 'name:before'?: Renderer; - 'name:after'?: Renderer; - 'value:before'?: Renderer; - 'value:after'?: Renderer; -}; -``` - -Step 2: add [JSDoc](https://github.com/runem/web-component-analyzer#-how-to-document-your-components-using-jsdoc) for each one of the templates using the `@slot` tag: - -```ts -import { ConfigurableMixin } from '../../../mixins/configurable'; -import { NucleonElement } from '../NucleonElement/NucleonElement'; -import { Data } from './types'; - -/** - * Form element for creating or editing `fx:custom_field` resources. - * - * @slot name:before - * @slot name:after - * - * @slot value:before - * @slot value:after - * - * @element foxy-custom-field-form - * @since 1.11.0 - */ -export class CustomFieldForm extends ConfigurableMixin(NucleonElement) {} -``` - -Step 3: explicitly specify the type on a property in your element class: - -```ts -import { ConfigurableMixin } from '../../../mixins/configurable'; -import { NucleonElement } from '../NucleonElement/NucleonElement'; -import { Data, Templates } from './types'; - -/** [collapsed] */ -export class CustomFieldForm extends ConfigurableMixin(NucleonElement) { - templates: Templates = {}; -} -``` - -Don't forget to run `npm run wca` when you're done to update `custom-elements.json`.