diff --git a/.changeset/afraid-pugs-kiss.md b/.changeset/afraid-pugs-kiss.md deleted file mode 100644 index dbfe3c05183..00000000000 --- a/.changeset/afraid-pugs-kiss.md +++ /dev/null @@ -1,8 +0,0 @@ ---- -"@aws-amplify/ui-react": major ---- - -BREAKING: -* Removing stylistic data-attributes from React primitives -* Update SwitchField classnames to be BEM -* Removing remnants of "countryCode" diff --git a/.changeset/bogus-cats-shred.md b/.changeset/bogus-cats-shred.md deleted file mode 100644 index 42e909852ca..00000000000 --- a/.changeset/bogus-cats-shred.md +++ /dev/null @@ -1,46 +0,0 @@ ---- -"@aws-amplify/ui-react": major -"@aws-amplify/ui": major ---- - -breaking: refactoring Tabs component to remove Radix dependency and allow more composability and customization. - -```diff -- import { Tabs, TabItem } from '@aws-amplify/ui-react' -+ import { Tabs } from '@aws-amplify/ui-react' - -- -- -- Tab 1 Content -- - -+ -+ -+ Tab 1 -+ -+ -+ Tab 1 Content -+ -+ -``` - - -You can also use the Tabs in a uncomposed way too: - -```jsx - -``` - -Some notable differences: -* Instead of providing a `defaultIndex` or `currentIndex` you provide a `defaultValue` or `value`. Each Tabs.Item and Tabs.Panel should have a `value` that matches with the corresponding element. -* `onChange` becomes `onValueChange` -* You should supply a `defaultValue` or `value` or else there will be no default selected tab. Previously the Tabs component would default to the first tab. - -There are also more design tokens and better CSS classes for easier customization. diff --git a/.changeset/clever-mirrors-boil.md b/.changeset/clever-mirrors-boil.md deleted file mode 100644 index 1b9eec82b7d..00000000000 --- a/.changeset/clever-mirrors-boil.md +++ /dev/null @@ -1,7 +0,0 @@ ---- -"@aws-amplify/ui-react-native": minor -"@aws-amplify/ui-react": minor -"@aws-amplify/ui": minor ---- - -feat: allow themes to have arbitrary tokens diff --git a/.changeset/cool-mangos-dress.md b/.changeset/cool-mangos-dress.md deleted file mode 100644 index 4e7ee47538a..00000000000 --- a/.changeset/cool-mangos-dress.md +++ /dev/null @@ -1,7 +0,0 @@ ---- -"@aws-amplify/ui-react-storage": patch ---- - -fix(react-storage): StorageImage now fires onStorageGetError when an object is not found - -StorageImage now has a prop called `validateObjectExistence` which is default to `true`. This checks if there is a file at the given path before adding it as the `src` on an image. diff --git a/.changeset/hip-apples-happen.md b/.changeset/hip-apples-happen.md deleted file mode 100644 index d482144a2fa..00000000000 --- a/.changeset/hip-apples-happen.md +++ /dev/null @@ -1,20 +0,0 @@ ---- -"@aws-amplify/ui-react": major -"@aws-amplify/ui": major ---- - -breaking: updating classnames for better BEM syntax - -* `amplify-loader__percentage-text` -> `amplify-loader__label` -* `amplify-menu-content-wrapper` -> `amplify-menu__wrapper` -* `amplify-menu-trigger` -> `amplify-menu__trigger` -* `amplify-menu-content` -> `amplify-menu__content` -* `amplify-menu-content__item` -> `amplify-menu__content__item` -* `amplify-pagination__item-button` -> `amplify-pagination__item` -* `amplify-pagination__item-current` -> `amplify-pagination__item--current` -* `amplify-pagination__item-ellipsis` -> `amplify-pagination__item--ellipsis` -* `amplify-rating-icon-container` -> `amplify-rating__item` -* `amplify-rating-icon` -> `amplify-rating__icon` -* `amplify-rating-icon-filled` -> `amplify-rating__icon--filled` -* `amplify-rating-icon-empty` -> `amplify-rating__icon--empty` -* `amplify-select__icon-wrapper` -> `amplify-select__icon` diff --git a/.changeset/itchy-ads-bake.md b/.changeset/itchy-ads-bake.md deleted file mode 100644 index 6d9c21a6fdc..00000000000 --- a/.changeset/itchy-ads-bake.md +++ /dev/null @@ -1,31 +0,0 @@ ---- -"@aws-amplify/ui": major -"@aws-amplify/ui-react": major ---- - -breaking: renaming Expander to Accordion and removing Radix dependency. The Accordion component is now built with `
` and `` elements to handle showing/hiding content. - -```jsx - - - - Click me first! - - - - Now when you click the second item, this item will automatically collapse. - - - - - Then click me! - - - - Notice how only one item can be open at a time for the single Accordion type. - - - -``` - -The Accordion can be controlled or uncontrolled (with a default value) diff --git a/.changeset/mighty-gifts-crash.md b/.changeset/mighty-gifts-crash.md deleted file mode 100644 index 937e5ecd9bc..00000000000 --- a/.changeset/mighty-gifts-crash.md +++ /dev/null @@ -1,35 +0,0 @@ ---- -"@aws-amplify/ui": major -"@aws-amplify/ui-react": major ---- - -breaking(theme): removing brand namespace from the theme tokens - -```diff -- tokens.colors.brand.primary[10] -+ tokens.colors.primary[10] -``` - - -```diff -const theme = createTheme({ - tokens: { - colors: { -- brand: { - primary: { - //... - } -- } - } - } -}) -``` - -We also added the ability to easily set the entire range of primary and secondary colors at the theme level - -```ts -const theme = createTheme({ - primaryColor: 'red', - secondaryColor: 'green' -}); -``` diff --git a/.changeset/plenty-apples-end.md b/.changeset/plenty-apples-end.md deleted file mode 100644 index 82c650b4ef3..00000000000 --- a/.changeset/plenty-apples-end.md +++ /dev/null @@ -1,12 +0,0 @@ ---- -"@aws-amplify/ui-react": patch ---- - -refactor(ui): update RadioGroupField to use Fieldset - -Update to `RadioGroupField` component props: - - `legend` replaces `label` - - `legendHidden` replaces `labelHidden` - -Example usage: -``` ``` diff --git a/.changeset/slow-ants-attend.md b/.changeset/slow-ants-attend.md deleted file mode 100644 index c3949326df4..00000000000 --- a/.changeset/slow-ants-attend.md +++ /dev/null @@ -1,23 +0,0 @@ ---- -"@aws-amplify/ui-react": minor -"@aws-amplify/ui": minor ---- - -feat: add CSS layers support and CSS file splitting. The default style import '@aws-amplify/ui-react/styles.css' remains unchanged so these features are opt-in. -We are now exposing each different component CSS file if you want fine-grained control over what CSS is loaded. Additionally, we will have a CSS reset and a base CSS file. -If you only wanted the button CSS you could do this: - -```javascript -import '@aws-amplify/ui-react/styles/reset.css' -import '@aws-amplify/ui-react/styles/base.css' -import '@aws-amplify/ui-react/styles/button.css' -``` - -You can also use the main 'styles.css' import with the new reset file too. - -To use CSS layers, replace '.css' with '.layer.css' for any CSS import. - -```diff -- import '@aws-amplify/ui-react/styles.css' -+ import '@aws-amplify/ui-react/styles.layer.css' -``` diff --git a/.github/workflows/publish-latest.yml b/.github/workflows/publish-latest.yml index a665a183303..694a652281d 100644 --- a/.github/workflows/publish-latest.yml +++ b/.github/workflows/publish-latest.yml @@ -1,149 +1,149 @@ -# Description: this workflow publishes UI packages to `latest` tag on NPM. -# -# Triggered by: whenever "Version Packages" is merged to `main` +# # Description: this workflow publishes UI packages to `latest` tag on NPM. +# # +# # Triggered by: whenever "Version Packages" is merged to `main` -# If successful, we will publish all updated UI packages to NPM. +# # If successful, we will publish all updated UI packages to NPM. -name: Test and Publish / latest +# name: Test and Publish / latest -on: - push: - branches: [main] +# on: +# push: +# branches: [main] -permissions: - id-token: write # This is required for requesting the JWT - contents: write # Used to push tags to GitHub +# permissions: +# id-token: write # This is required for requesting the JWT +# contents: write # Used to push tags to GitHub -jobs: - setup: - runs-on: ubuntu-latest - outputs: - has-changesets: ${{ steps.has-changesets.outputs.has-changesets }} - steps: - - name: Checkout repo - uses: actions/checkout@24cb9080177205b6e8c946b17badbe402adc938f # v3.4.0 https://github.com/actions/checkout/commit/24cb9080177205b6e8c946b17badbe402adc938f - with: - # This makes Actions fetch all Git history so that Changesets can generate changelogs with the correct commits - fetch-depth: 0 - - name: Check if repo has unconsumed changesets - id: has-changesets - uses: ./.github/actions/has-changesets - # Note: if there are no changesets, that means that either - # (1) "Version Packages" PR was just merged, or - # (2) no commits with changesets have been merged after packages were last published. - # - # In either way, we'll attempt to publish the packages. In case of (1), publish will succeed. In - # case of (2), `@changesets/action` will know that UI packages have already published and will - # skip publish. +# jobs: +# setup: +# runs-on: ubuntu-latest +# outputs: +# has-changesets: ${{ steps.has-changesets.outputs.has-changesets }} +# steps: +# - name: Checkout repo +# uses: actions/checkout@24cb9080177205b6e8c946b17badbe402adc938f # v3.4.0 https://github.com/actions/checkout/commit/24cb9080177205b6e8c946b17badbe402adc938f +# with: +# # This makes Actions fetch all Git history so that Changesets can generate changelogs with the correct commits +# fetch-depth: 0 +# - name: Check if repo has unconsumed changesets +# id: has-changesets +# uses: ./.github/actions/has-changesets +# # Note: if there are no changesets, that means that either +# # (1) "Version Packages" PR was just merged, or +# # (2) no commits with changesets have been merged after packages were last published. +# # +# # In either way, we'll attempt to publish the packages. In case of (1), publish will succeed. In +# # case of (2), `@changesets/action` will know that UI packages have already published and will +# # skip publish. - build-test: - runs-on: ubuntu-latest - needs: setup - environment: ci - if: ${{ needs.setup.outputs.has-changesets != 'true' }} - steps: - - name: Checkout repo - uses: actions/checkout@24cb9080177205b6e8c946b17badbe402adc938f # v3.4.0 https://github.com/actions/checkout/commit/24cb9080177205b6e8c946b17badbe402adc938f - - name: Setup Node.js 20 - uses: actions/setup-node@64ed1c7eab4cce3362f8c340dee64e5eaeef8f7c # v3.6.0 https://github.com/actions/setup-node/commit/64ed1c7eab4cce3362f8c340dee64e5eaeef8f7c - with: - node-version: 20 - cache: 'yarn' - env: - SEGMENT_DOWNLOAD_TIMEOUT_MINS: 2 - - name: Add Amplify CLI - run: yarn global add @aws-amplify/cli - - name: Configure AWS credentials - uses: aws-actions/configure-aws-credentials@e1e17a757e536f70e52b5a12b2e8d1d1c60e04ef # v2.0.0 https://github.com/aws-actions/configure-aws-credentials/commit/e1e17a757e536f70e52b5a12b2e8d1d1c60e04ef - with: - aws-region: us-east-2 - role-to-assume: ${{ secrets.AUTH_E2E_ROLE_ARN }} - # Amplify CLI does not support headless pull with temporary credentials - # when useProfile is false. - # See: https://github.com/aws-amplify/amplify-cli/issues/11009. - - name: Create temp AWS profile - run: | - aws configure set aws_access_key_id $AWS_ACCESS_KEY_ID && \ - aws configure set aws_secret_access_key $AWS_SECRET_ACCESS_KEY && \ - aws configure set aws_session_token $AWS_SESSION_TOKEN && \ - aws configure set default.region $AWS_REGION - - name: Pull down AWS environments - run: yarn pull - working-directory: ./canary - - name: Delete AWS Profile - run: rm -rf ~/.aws - - name: Setup canary apps against @next - run: yarn setup:next - working-directory: ./canary - - name: Run yarn install on each sample app - run: yarn install - working-directory: ./canary - - name: Run yarn build on each sample app - run: yarn build - working-directory: ./canary +# build-test: +# runs-on: ubuntu-latest +# needs: setup +# environment: ci +# if: ${{ needs.setup.outputs.has-changesets != 'true' }} +# steps: +# - name: Checkout repo +# uses: actions/checkout@24cb9080177205b6e8c946b17badbe402adc938f # v3.4.0 https://github.com/actions/checkout/commit/24cb9080177205b6e8c946b17badbe402adc938f +# - name: Setup Node.js 20 +# uses: actions/setup-node@64ed1c7eab4cce3362f8c340dee64e5eaeef8f7c # v3.6.0 https://github.com/actions/setup-node/commit/64ed1c7eab4cce3362f8c340dee64e5eaeef8f7c +# with: +# node-version: 20 +# cache: 'yarn' +# env: +# SEGMENT_DOWNLOAD_TIMEOUT_MINS: 2 +# - name: Add Amplify CLI +# run: yarn global add @aws-amplify/cli +# - name: Configure AWS credentials +# uses: aws-actions/configure-aws-credentials@e1e17a757e536f70e52b5a12b2e8d1d1c60e04ef # v2.0.0 https://github.com/aws-actions/configure-aws-credentials/commit/e1e17a757e536f70e52b5a12b2e8d1d1c60e04ef +# with: +# aws-region: us-east-2 +# role-to-assume: ${{ secrets.AUTH_E2E_ROLE_ARN }} +# # Amplify CLI does not support headless pull with temporary credentials +# # when useProfile is false. +# # See: https://github.com/aws-amplify/amplify-cli/issues/11009. +# - name: Create temp AWS profile +# run: | +# aws configure set aws_access_key_id $AWS_ACCESS_KEY_ID && \ +# aws configure set aws_secret_access_key $AWS_SECRET_ACCESS_KEY && \ +# aws configure set aws_session_token $AWS_SESSION_TOKEN && \ +# aws configure set default.region $AWS_REGION +# - name: Pull down AWS environments +# run: yarn pull +# working-directory: ./canary +# - name: Delete AWS Profile +# run: rm -rf ~/.aws +# - name: Setup canary apps against @next +# run: yarn setup:next +# working-directory: ./canary +# - name: Run yarn install on each sample app +# run: yarn install +# working-directory: ./canary +# - name: Run yarn build on each sample app +# run: yarn build +# working-directory: ./canary - publish: - runs-on: ubuntu-latest - environment: deployment - needs: build-test - if: ${{ needs.setup.outputs.has-changesets != 'true' }} - steps: - - name: Checkout repo - uses: actions/checkout@24cb9080177205b6e8c946b17badbe402adc938f # v3.4.0 https://github.com/actions/checkout/commit/24cb9080177205b6e8c946b17badbe402adc938f - with: - # This makes Actions fetch all Git history so that Changesets can generate changelogs with the correct commits - fetch-depth: 0 - - name: Setup Node.js 20 - uses: actions/setup-node@64ed1c7eab4cce3362f8c340dee64e5eaeef8f7c # v3.6.0 https://github.com/actions/setup-node/commit/64ed1c7eab4cce3362f8c340dee64e5eaeef8f7c - with: - node-version: 20 - cache: 'yarn' - env: - SEGMENT_DOWNLOAD_TIMEOUT_MINS: 2 - - name: Install packages - uses: ./.github/actions/install-with-retries - with: - skip-cypress-binary: true # publishing doesn't need cypress - - name: Build packages - run: yarn build - - name: Publish to @latest - uses: changesets/action@b98cec97583b917ff1dc6179dd4d230d3e439894 - with: - publish: yarn publish:latest - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - NPM_TOKEN: ${{ secrets.NPM_TOKEN }} - - name: Trigger build for prod liveness sample app pointing at latest tag - run: curl -X POST -d {} $ENDPOINT -H "Content-Type:application/json" - env: - ENDPOINT: ${{ secrets.LIVENESS_PROD_SAMPLE_APP_BUILD_TRIGGER }} +# publish: +# runs-on: ubuntu-latest +# environment: deployment +# needs: build-test +# if: ${{ needs.setup.outputs.has-changesets != 'true' }} +# steps: +# - name: Checkout repo +# uses: actions/checkout@24cb9080177205b6e8c946b17badbe402adc938f # v3.4.0 https://github.com/actions/checkout/commit/24cb9080177205b6e8c946b17badbe402adc938f +# with: +# # This makes Actions fetch all Git history so that Changesets can generate changelogs with the correct commits +# fetch-depth: 0 +# - name: Setup Node.js 20 +# uses: actions/setup-node@64ed1c7eab4cce3362f8c340dee64e5eaeef8f7c # v3.6.0 https://github.com/actions/setup-node/commit/64ed1c7eab4cce3362f8c340dee64e5eaeef8f7c +# with: +# node-version: 20 +# cache: 'yarn' +# env: +# SEGMENT_DOWNLOAD_TIMEOUT_MINS: 2 +# - name: Install packages +# uses: ./.github/actions/install-with-retries +# with: +# skip-cypress-binary: true # publishing doesn't need cypress +# - name: Build packages +# run: yarn build +# - name: Publish to @latest +# uses: changesets/action@b98cec97583b917ff1dc6179dd4d230d3e439894 +# with: +# publish: yarn publish:latest +# env: +# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} +# NPM_TOKEN: ${{ secrets.NPM_TOKEN }} +# - name: Trigger build for prod liveness sample app pointing at latest tag +# run: curl -X POST -d {} $ENDPOINT -H "Content-Type:application/json" +# env: +# ENDPOINT: ${{ secrets.LIVENESS_PROD_SAMPLE_APP_BUILD_TRIGGER }} - log-failure-metric: - # Send a failure data point to metric PublishLatestFailure in github-workflows@ us-east-2 - runs-on: ubuntu-latest - environment: ci - needs: publish - if: ${{ failure() }} - steps: - - name: Log failure data point to metric PublishLatestFailure - uses: aws-amplify/amplify-ui/.github/actions/log-metric@main - with: - metric-name: PublishLatestFailure - value: 1 - role-to-assume: ${{ secrets.METRIC_LOGGER_ROLE_ARN }} - aws-region: us-east-2 +# log-failure-metric: +# # Send a failure data point to metric PublishLatestFailure in github-workflows@ us-east-2 +# runs-on: ubuntu-latest +# environment: ci +# needs: publish +# if: ${{ failure() }} +# steps: +# - name: Log failure data point to metric PublishLatestFailure +# uses: aws-amplify/amplify-ui/.github/actions/log-metric@main +# with: +# metric-name: PublishLatestFailure +# value: 1 +# role-to-assume: ${{ secrets.METRIC_LOGGER_ROLE_ARN }} +# aws-region: us-east-2 - log-success-metric: - # Send a success data point to metric PublishLatestFailure in github-workflows@ us-east-2 - runs-on: ubuntu-latest - environment: ci - needs: publish - if: ${{ success() }} - steps: - - name: Log success data point to metric PublishLatestFailure - uses: aws-amplify/amplify-ui/.github/actions/log-metric@main - with: - metric-name: PublishLatestFailure - value: 0 - role-to-assume: ${{ secrets.METRIC_LOGGER_ROLE_ARN }} - aws-region: us-east-2 +# log-success-metric: +# # Send a success data point to metric PublishLatestFailure in github-workflows@ us-east-2 +# runs-on: ubuntu-latest +# environment: ci +# needs: publish +# if: ${{ success() }} +# steps: +# - name: Log success data point to metric PublishLatestFailure +# uses: aws-amplify/amplify-ui/.github/actions/log-metric@main +# with: +# metric-name: PublishLatestFailure +# value: 0 +# role-to-assume: ${{ secrets.METRIC_LOGGER_ROLE_ARN }} +# aws-region: us-east-2 diff --git a/.github/workflows/publish-next-release-unstable.yml b/.github/workflows/publish-next-release-unstable.yml deleted file mode 100644 index f1582c8c275..00000000000 --- a/.github/workflows/publish-next-release-unstable.yml +++ /dev/null @@ -1,73 +0,0 @@ -# Description: This workflow runs unit + e2e tests, then publishes UI packages -# to `@next-release` NPM tag. -# -# Triggered by: merge to `next-release/main` - -name: Test and Publish / next-release-unstable - -on: - push: - branches: [next-release/main] - -permissions: - id-token: write # This is required for requesting the JWT - contents: read # This is required for actions/checkout - -jobs: - setup-cache: - uses: aws-amplify/amplify-ui/.github/workflows/reusable-setup-cache.yml@next-release/main - with: - commit: ${{ github.sha }} - repository: ${{ github.repository }} - - publish: - uses: ./.github/workflows/reusable-tagged-publish.yml - with: - dist-tag: next-release-unstable - secrets: - NPM_TOKEN: ${{ secrets.NPM_TOKEN }} - - build-test: - needs: publish - runs-on: ubuntu-latest - environment: ci - steps: - - name: Checkout repo - uses: actions/checkout@24cb9080177205b6e8c946b17badbe402adc938f # v3.4.0 https://github.com/actions/checkout/commit/24cb9080177205b6e8c946b17badbe402adc938f - - name: Setup Node.js 20 - uses: actions/setup-node@64ed1c7eab4cce3362f8c340dee64e5eaeef8f7c # v3.6.0 https://github.com/actions/setup-node/commit/64ed1c7eab4cce3362f8c340dee64e5eaeef8f7c - with: - node-version: 20 - cache: 'yarn' - env: - SEGMENT_DOWNLOAD_TIMEOUT_MINS: 2 - - name: Add Amplify CLI - run: yarn global add @aws-amplify/cli - - name: Configure AWS credentials - uses: aws-actions/configure-aws-credentials@v1 - with: - aws-region: us-east-2 - role-to-assume: ${{ secrets.AUTH_E2E_ROLE_ARN }} - # Amplify CLI does not support headless pull with temporary credentials - # when useProfile is false. - # See: https://github.com/aws-amplify/amplify-cli/issues/11009. - - name: Create temp AWS profile - run: | - aws configure set aws_access_key_id $AWS_ACCESS_KEY_ID && \ - aws configure set aws_secret_access_key $AWS_SECRET_ACCESS_KEY && \ - aws configure set aws_session_token $AWS_SESSION_TOKEN && \ - aws configure set default.region $AWS_REGION - - name: Pull down AWS environments - run: yarn pull - working-directory: ./canary - - name: Delete AWS Profile - run: rm -rf ~/.aws - - name: Setup canary apps against @next-release-unstable - run: yarn setup:next-release-unstable - working-directory: ./canary - - name: Run yarn install on each sample app - run: yarn install - working-directory: ./canary - - name: Run yarn build on each sample app - run: yarn build - working-directory: ./canary diff --git a/.github/workflows/publish-next-release.yml b/.github/workflows/publish-next-release.yml deleted file mode 100644 index cca59de3da9..00000000000 --- a/.github/workflows/publish-next-release.yml +++ /dev/null @@ -1,104 +0,0 @@ -# Description: This workflow runs unit + e2e tests, then publishes UI packages -# to `@next-release` NPM tag. -# -# Triggered by: merge to `next-release/main` - -name: Test and Publish / next-release - -on: - push: - branches: [next-release/main] - -permissions: - id-token: write # This is required for requesting the JWT - contents: read # This is required for actions/checkout - -jobs: - setup-cache: - uses: aws-amplify/amplify-ui/.github/workflows/reusable-setup-cache.yml@next-release/main - with: - commit: ${{ github.sha }} - repository: ${{ github.repository }} - - unit: - uses: aws-amplify/amplify-ui/.github/workflows/reusable-unit.yml@next-release/main - needs: setup-cache - with: - commit: ${{ github.sha }} - repository: ${{ github.repository }} - - e2e: - uses: aws-amplify/amplify-ui/.github/workflows/reusable-e2e.yml@next-release/main - needs: unit - with: - commit: ${{ github.sha }} - repository: ${{ github.repository }} - secrets: - AUTH_E2E_ROLE_ARN: ${{ secrets.AUTH_E2E_ROLE_ARN }} - DATASTORE_E2E_ROLE_ARN: ${{ secrets.DATASTORE_E2E_ROLE_ARN }} - GEO_E2E_ROLE_ARN: ${{ secrets.GEO_E2E_ROLE_ARN }} - STORAGE_E2E_ROLE_ARN: ${{ secrets.STORAGE_E2E_ROLE_ARN }} - LIVENESS_E2E_ROLE_ARN: ${{ secrets.LIVENESS_E2E_ROLE_ARN }} - IN_APP_MESSAGING_E2E_ROLE_ARN: ${{ secrets.IN_APP_MESSAGING_E2E_ROLE_ARN }} - DOMAIN: ${{ secrets.DOMAIN }} - PHONE_NUMBER: ${{ secrets.PHONE_NUMBER }} - USERNAME: ${{ secrets.USERNAME }} - NEW_PASSWORD: ${{ secrets.NEW_PASSWORD }} - VALID_PASSWORD: ${{ secrets.VALID_PASSWORD }} - SITE_URL: ${{ secrets.SITE_URL }} - DOCSEARCH_DOCS_APP_ID: ${{ secrets.DOCSEARCH_DOCS_APP_ID }} - DOCSEARCH_DOCS_API_KEY: ${{ secrets.DOCSEARCH_DOCS_API_KEY }} - DOCSEARCH_DOCS_INDEX_NAME: ${{ secrets.DOCSEARCH_DOCS_INDEX_NAME }} - - publish: - needs: [e2e] - uses: ./.github/workflows/reusable-tagged-publish.yml - with: - dist-tag: next-release - secrets: - NPM_TOKEN: ${{ secrets.NPM_TOKEN }} - - build-test: - needs: publish - runs-on: ubuntu-latest - environment: ci - steps: - - name: Checkout repo - uses: actions/checkout@24cb9080177205b6e8c946b17badbe402adc938f # v3.4.0 https://github.com/actions/checkout/commit/24cb9080177205b6e8c946b17badbe402adc938f - - name: Setup Node.js 20 - uses: actions/setup-node@64ed1c7eab4cce3362f8c340dee64e5eaeef8f7c # v3.6.0 https://github.com/actions/setup-node/commit/64ed1c7eab4cce3362f8c340dee64e5eaeef8f7c - with: - node-version: 20 - cache: 'yarn' - env: - SEGMENT_DOWNLOAD_TIMEOUT_MINS: 2 - - name: Add Amplify CLI - run: yarn global add @aws-amplify/cli - - name: Configure AWS credentials - uses: aws-actions/configure-aws-credentials@v1 - with: - aws-region: us-east-2 - role-to-assume: ${{ secrets.AUTH_E2E_ROLE_ARN }} - # Amplify CLI does not support headless pull with temporary credentials - # when useProfile is false. - # See: https://github.com/aws-amplify/amplify-cli/issues/11009. - - name: Create temp AWS profile - run: | - aws configure set aws_access_key_id $AWS_ACCESS_KEY_ID && \ - aws configure set aws_secret_access_key $AWS_SECRET_ACCESS_KEY && \ - aws configure set aws_session_token $AWS_SESSION_TOKEN && \ - aws configure set default.region $AWS_REGION - - name: Pull down AWS environments - run: yarn pull - working-directory: ./canary - - name: Delete AWS Profile - run: rm -rf ~/.aws - - name: Setup canary apps against @next-release - run: yarn setup:next-release - working-directory: ./canary - - name: Run yarn install on each sample app - run: yarn install - working-directory: ./canary - - name: Run yarn build on each sample app - run: yarn build - working-directory: ./canary diff --git a/.github/workflows/publish-next.yml b/.github/workflows/publish-next.yml index 9b4d46bf13c..b24ce8c1f06 100644 --- a/.github/workflows/publish-next.yml +++ b/.github/workflows/publish-next.yml @@ -56,6 +56,7 @@ jobs: DOCSEARCH_DOCS_INDEX_NAME: ${{ secrets.DOCSEARCH_DOCS_INDEX_NAME }} guides: + if: false # temporarily disable job runs-on: ubuntu-latest environment: ci env: @@ -150,7 +151,6 @@ jobs: retention-days: 5 publish: - needs: [e2e, guides] uses: aws-amplify/amplify-ui/.github/workflows/reusable-tagged-publish.yml@main with: dist-tag: next diff --git a/.github/workflows/reusable-e2e.yml b/.github/workflows/reusable-e2e.yml index dc938525b6f..404276c53eb 100644 --- a/.github/workflows/reusable-e2e.yml +++ b/.github/workflows/reusable-e2e.yml @@ -67,15 +67,15 @@ jobs: include: - example: angular package: angular - tags: '@angular and not @todo-angular and not @todo-migration' + tags: '@angular and not @todo-angular' - example: next package: react - tags: '@react and not @todo-react and not @todo-migration' + tags: '@react and not @todo-react' - example: vue package: vue - tags: '@vue and not @todo-vue and not @todo-migration' + tags: '@vue and not @todo-vue' steps: - name: Checkout Amplify UI @@ -349,7 +349,8 @@ jobs: e2e-ios: needs: check-changed-packages - if: ${{ inputs.skip-changed-packages-check == 'true' || needs.check-changed-packages.outputs.has-changed-packages == 'true' }} + if: false # Temporarily disable RN iOS tests + # if: ${{ inputs.skip-changed-packages-check == 'true' || needs.check-changed-packages.outputs.has-changed-packages == 'true' }} runs-on: macos-13 environment: ci env: @@ -469,7 +470,8 @@ jobs: e2e-android: needs: check-changed-packages - if: ${{ inputs.skip-changed-packages-check == 'true' || needs.check-changed-packages.outputs.has-changed-packages == 'true' }} + if: false # Temporarily disable RN Android tests + # if: ${{ inputs.skip-changed-packages-check == 'true' || needs.check-changed-packages.outputs.has-changed-packages == 'true' }} runs-on: macos-13 environment: ci env: diff --git a/.github/workflows/test-internal-prs.yml b/.github/workflows/test-internal-prs.yml index c47c398b282..f3d7e6e6307 100644 --- a/.github/workflows/test-internal-prs.yml +++ b/.github/workflows/test-internal-prs.yml @@ -5,7 +5,7 @@ # (2) On every commit to the PR # (3) Adding run-tests label to the PR -name: Test / Internal PRs / next-release +name: Test / Internal PRs concurrency: group: test-internal-prs-${{ github.event.pull_request.id }} @@ -13,7 +13,7 @@ concurrency: on: pull_request: - branches: [next-release/main] + branches: [main, hotfix] types: [opened, synchronize, labeled] jobs: diff --git a/.gitignore b/.gitignore index d3bb1526e78..46a80d50075 100644 --- a/.gitignore +++ b/.gitignore @@ -5,6 +5,7 @@ node_modules aws-exports.js aws-exports.ts +amplifyconfiguration.json # We have mock exports in the following locations !examples/angular/src/pages/ui/components/*/*/aws-exports.js diff --git a/build-system-tests/package.json b/build-system-tests/package.json index ebd154a5417..c939a24bc2a 100644 --- a/build-system-tests/package.json +++ b/build-system-tests/package.json @@ -29,7 +29,7 @@ "react-latest-cra-latest-js": "npm run setup:react:cra -- -l js", "react-17-next-11-ts": "npm run setup:react:next -- -f 17 -b 11", "react-latest-vite-2-ts": "npm run setup:react:vite -- -b 2", - "angular-latest-angular-cli-latest-ts": "npm run setup:angular:cli", + "angular-latest-angular-cli-16-ts": "npm run setup:angular:cli -- -b 16", "angular-14-angular-cli-14-ts": "npm run setup:angular:cli -- -f 14 -b 14 -n angular-latest-angular-cli-v14-ts", "vue-3-vue-cli-latest-ts": "npm run setup:vue:cli -- -f 3 -P yarn", "vue-latest-vite-latest-ts": "npm run setup:vue:vite", diff --git a/docs/package.json b/docs/package.json index bddd1f3fb24..8e3b18b2d7f 100644 --- a/docs/package.json +++ b/docs/package.json @@ -23,12 +23,12 @@ "test:links": "node --require esbuild-register ./scripts/link-checker-puppeteer.ts" }, "dependencies": { - "@aws-amplify/ui-react": "5.3.2", + "@aws-amplify/ui-react": "6.0.0", "@docsearch/react": "3", "@mdx-js/loader": "^2.1.0", "@mdx-js/mdx": "^2.1.0", "@mdx-js/react": "^2.1.0", - "aws-amplify": "unstable", + "aws-amplify": "^6.0.2", "countries-list": "^2.6.1", "dotenv": "^16.0.0", "gray-matter": "^4.0.3", diff --git a/docs/src/components/SocialProviderDemo.tsx b/docs/src/components/SocialProviderDemo.tsx index e13d3f5618a..d4612097e10 100644 --- a/docs/src/components/SocialProviderDemo.tsx +++ b/docs/src/components/SocialProviderDemo.tsx @@ -1,7 +1,6 @@ import { translations } from '@aws-amplify/ui'; import { Authenticator } from '@aws-amplify/ui-react'; -// @todo-migration fix import import { I18n } from 'aws-amplify/utils'; import * as React from 'react'; diff --git a/docs/src/components/Theming/TokenGroups.tsx b/docs/src/components/Theming/TokenGroups.tsx index db72aa245a0..53b19549cce 100644 --- a/docs/src/components/Theming/TokenGroups.tsx +++ b/docs/src/components/Theming/TokenGroups.tsx @@ -21,10 +21,10 @@ export const TokensColorsOverlay = () => ( // Colors, Brand export const TokensColorsBrandPrimary = () => ( - + ); export const TokensColorsBrandSecondary = () => ( - + ); // Colors, Palette diff --git a/docs/src/pages/[platform]/connected-components/account-settings/delete-user/props.ts b/docs/src/pages/[platform]/connected-components/account-settings/delete-user/props.ts index 447cc48d58c..75ca6527aa9 100644 --- a/docs/src/pages/[platform]/connected-components/account-settings/delete-user/props.ts +++ b/docs/src/pages/[platform]/connected-components/account-settings/delete-user/props.ts @@ -13,7 +13,7 @@ export const DELETE_USER = [ { name: `handleDelete?`, description: 'Custom delete user handler', - type: `(user: AmplifyUser) => Promise | void`, + type: `(user: AuthUser) => Promise | void`, }, { name: `components?`, diff --git a/docs/src/pages/[platform]/connected-components/authenticator/advanced/current-route.angular.mdx b/docs/src/pages/[platform]/connected-components/authenticator/advanced/current-route.angular.mdx index b9680048c5a..a42bf7683ba 100644 --- a/docs/src/pages/[platform]/connected-components/authenticator/advanced/current-route.angular.mdx +++ b/docs/src/pages/[platform]/connected-components/authenticator/advanced/current-route.angular.mdx @@ -6,9 +6,9 @@ You can use `AuthenticatorService` to access `route` string that represents the - `signUp` - `confirmSignIn` - `confirmSignUp` -- `setupTOTP` +- `setupTotp` - `forceNewPassword` -- `resetPassword` +- `forgotPassword` - `confirmResetPassword` - `verifyUser` - `confirmVerifyUser` diff --git a/docs/src/pages/[platform]/connected-components/authenticator/advanced/current-route.react-native.mdx b/docs/src/pages/[platform]/connected-components/authenticator/advanced/current-route.react-native.mdx index 9fd019f3f8b..f402311169e 100644 --- a/docs/src/pages/[platform]/connected-components/authenticator/advanced/current-route.react-native.mdx +++ b/docs/src/pages/[platform]/connected-components/authenticator/advanced/current-route.react-native.mdx @@ -6,9 +6,9 @@ You can use `useAuthenticator` hook to access `route` string that represents the - `signUp` - `confirmSignIn` - `confirmSignUp` -- `setupTOTP` +- `setupTotp` - `forceNewPassword` -- `resetPassword` +- `forgotPassword` - `confirmResetPassword` - `verifyUser` - `confirmVerifyUser` diff --git a/docs/src/pages/[platform]/connected-components/authenticator/advanced/current-route.react.mdx b/docs/src/pages/[platform]/connected-components/authenticator/advanced/current-route.react.mdx index ed4a97192bc..890970f38b0 100644 --- a/docs/src/pages/[platform]/connected-components/authenticator/advanced/current-route.react.mdx +++ b/docs/src/pages/[platform]/connected-components/authenticator/advanced/current-route.react.mdx @@ -6,9 +6,9 @@ You can use `useAuthenticator` hook to access `route` string that represents the - `signUp` - `confirmSignIn` - `confirmSignUp` -- `setupTOTP` +- `setupTotp` - `forceNewPassword` -- `resetPassword` +- `forgotPassword` - `confirmResetPassword` - `verifyUser` - `confirmVerifyUser` diff --git a/docs/src/pages/[platform]/connected-components/authenticator/advanced/current-route.vue.mdx b/docs/src/pages/[platform]/connected-components/authenticator/advanced/current-route.vue.mdx index cd5b51c8835..3478740b64a 100644 --- a/docs/src/pages/[platform]/connected-components/authenticator/advanced/current-route.vue.mdx +++ b/docs/src/pages/[platform]/connected-components/authenticator/advanced/current-route.vue.mdx @@ -6,9 +6,9 @@ You can use `useAuthenticator` composable to access `route` string that represen - `signUp` - `confirmSignIn` - `confirmSignUp` -- `setupTOTP` +- `setupTotp` - `forceNewPassword` -- `resetPassword` +- `forgotPassword` - `confirmResetPassword` - `verifyUser` - `confirmVerifyUser` diff --git a/docs/src/pages/[platform]/connected-components/authenticator/advanced/example.angular.mdx b/docs/src/pages/[platform]/connected-components/authenticator/advanced/example.angular.mdx index fa559167ce0..3bd640194e4 100644 --- a/docs/src/pages/[platform]/connected-components/authenticator/advanced/example.angular.mdx +++ b/docs/src/pages/[platform]/connected-components/authenticator/advanced/example.angular.mdx @@ -27,7 +27,7 @@ _use-authenticator.component.html_
); diff --git a/docs/src/pages/[platform]/connected-components/authenticator/advanced/example.vue.mdx b/docs/src/pages/[platform]/connected-components/authenticator/advanced/example.vue.mdx index a87890deafa..a4b8b896538 100644 --- a/docs/src/pages/[platform]/connected-components/authenticator/advanced/example.vue.mdx +++ b/docs/src/pages/[platform]/connected-components/authenticator/advanced/example.vue.mdx @@ -8,7 +8,7 @@ import aws_exports from './aws-exports'; Amplify.configure(aws_exports); -const { toResetPassword } = toRefs(useAuthenticator()); +const { toForgotPassword } = toRefs(useAuthenticator());