From 08501234a85a1c927b49721edd54c39a5c3a0815 Mon Sep 17 00:00:00 2001 From: Zach Pomerantz Date: Tue, 8 Aug 2023 10:38:37 -0700 Subject: [PATCH] build: replace babel with swc (#7056) * chore: refactor ms.macro to ms * build: upgrade lingui@4 * chore: avoid styled-components/macro * build: replace babel loader with swc * build: upgrade vanilla-extract * build: simplify e2e config * build: migrate jest to swc * build: dedup * whoops * fix: initial translations * build: coverage * build: ignore static extract warning * build: rm old babel pkg * test: rm e2e codecov * build: fix swc cache * cleanup * fix visible t9ns * cleanup * cleanup setup * crank it * actual merge conflict resolution * fix: restore locale initialization --- .eslintrc.js | 2 + .github/actions/setup/action.yml | 36 +- .github/workflows/test.yml | 23 +- .gitignore | 1 + .swcrc | 29 + babel-plugin-macros.config.js | 10 - codecov.yml | 9 - craco.config.cjs | 91 +- lingui.config.ts | 61 -- package.json | 34 +- src/components/About/AboutFooter.tsx | 2 +- src/components/About/Card.tsx | 2 +- src/components/About/Icons.tsx | 2 +- src/components/About/ProtocolBanner.tsx | 2 +- src/components/About/constants.tsx | 2 +- .../AccountDrawer/AuthenticatedHeader.tsx | 2 +- src/components/AccountDrawer/DefaultMenu.tsx | 2 +- .../AccountDrawer/DownloadButton.tsx | 2 +- .../AccountDrawer/GitVersionRow.tsx | 2 +- src/components/AccountDrawer/IconButton.tsx | 2 +- .../MiniPortfolio/Activity/ActivityRow.tsx | 2 +- .../Activity/OffchainActivityModal.tsx | 2 +- .../MiniPortfolio/Activity/index.tsx | 2 +- .../MiniPortfolio/Activity/parseRemote.tsx | 18 +- .../MiniPortfolio/ExpandoRow.tsx | 2 +- .../MiniPortfolio/NFTs/NFTItem.tsx | 2 +- .../MiniPortfolio/NFTs/index.tsx | 2 +- .../MiniPortfolio/Pools/cache.ts | 4 +- .../MiniPortfolio/Pools/index.tsx | 2 +- .../MiniPortfolio/PortfolioLogo.tsx | 2 +- .../MiniPortfolio/PortfolioRow.tsx | 2 +- .../MiniPortfolio/Tokens/index.tsx | 2 +- .../AccountDrawer/MiniPortfolio/index.tsx | 2 +- src/components/AccountDrawer/SettingsMenu.tsx | 2 +- .../AccountDrawer/SettingsToggle.tsx | 2 +- src/components/AccountDrawer/SlideOutMenu.tsx | 2 +- .../AccountDrawer/UniwalletModal.tsx | 2 +- src/components/AccountDrawer/index.tsx | 2 +- src/components/AddressInputPanel/index.tsx | 2 +- src/components/AirdropModal/index.tsx | 2 +- src/components/Badge/RangeBadge.tsx | 2 +- src/components/Badge/index.tsx | 2 +- src/components/Banner/UniswapWalletBanner.tsx | 2 +- src/components/Button/index.tsx | 2 +- src/components/Card/index.tsx | 2 +- src/components/Charts/AnimatedInLineChart.tsx | 6 +- src/components/Charts/FadeInLineChart.tsx | 2 +- src/components/Charts/LineChart.tsx | 2 +- src/components/Charts/SparklineChart.tsx | 2 +- src/components/Column/index.tsx | 2 +- src/components/Common/index.tsx | 2 +- .../ConnectedAccountBlocked/index.tsx | 2 +- .../CurrencyInputPanel/FiatValue.tsx | 2 +- .../SwapCurrencyInputPanel.tsx | 2 +- src/components/CurrencyInputPanel/index.tsx | 2 +- src/components/DoubleLogo/index.tsx | 2 +- src/components/ErrorBoundary/index.tsx | 2 +- src/components/Expand/index.tsx | 2 +- .../FeatureFlagModal/FeatureFlagModal.tsx | 2 +- src/components/FeeSelector/FeeOption.tsx | 2 +- src/components/FeeSelector/index.tsx | 2 +- src/components/FiatOnrampModal/index.tsx | 2 +- src/components/HoverInlineText/index.tsx | 2 +- src/components/Icons/AlertTriangleFilled.tsx | 2 +- src/components/Icons/LoadingSpinner.tsx | 2 +- src/components/Icons/shared.tsx | 2 +- src/components/Identicon/StatusIcon.tsx | 2 +- src/components/Identicon/index.tsx | 2 +- .../InputStepCounter/InputStepCounter.tsx | 2 +- .../LiquidityChartRangeInput/Area.tsx | 2 +- .../LiquidityChartRangeInput/AxisBottom.tsx | 2 +- .../LiquidityChartRangeInput/Brush.tsx | 2 +- .../LiquidityChartRangeInput/Line.tsx | 2 +- .../LiquidityChartRangeInput/Zoom.tsx | 2 +- .../LiquidityChartRangeInput/index.tsx | 2 +- src/components/Loader/styled.tsx | 2 +- src/components/Logo/AssetLogo.tsx | 2 +- src/components/Menu/index.tsx | 2 +- src/components/Modal/index.tsx | 2 +- src/components/ModalViews/index.tsx | 2 +- src/components/NavBar/Bag.tsx | 2 +- src/components/NavBar/Blur.tsx | 2 +- src/components/NavBar/ChainSelector.tsx | 2 +- src/components/NavBar/ChainSelectorRow.tsx | 2 +- src/components/NavBar/MenuDropdown.tsx | 2 +- src/components/NavBar/SearchBar.tsx | 23 +- src/components/NavBar/SearchBarDropdown.tsx | 2 +- src/components/NavBar/SuggestionRow.tsx | 2 +- src/components/NavBar/index.tsx | 2 +- src/components/NavigationTabs/index.tsx | 2 +- src/components/NetworkAlert/NetworkAlert.tsx | 2 +- src/components/NumericalInput/index.tsx | 2 +- .../Polling/ChainConnectivityWarning.tsx | 2 +- src/components/Polling/index.tsx | 8 +- src/components/Popover/index.tsx | 2 +- src/components/Popups/ClaimPopup.tsx | 2 +- src/components/Popups/PopupContent.tsx | 2 +- src/components/Popups/index.tsx | 2 +- src/components/PositionCard/Sushi.tsx | 2 +- src/components/PositionCard/V2.tsx | 2 +- src/components/PositionCard/index.tsx | 2 +- src/components/PositionList/index.tsx | 2 +- src/components/PositionListItem/index.tsx | 2 +- src/components/PositionPreview/index.tsx | 2 +- src/components/PrivacyPolicy/index.tsx | 2 +- src/components/QuestionHelper/index.tsx | 2 +- .../RangeSelector/PresetsButtons.tsx | 2 +- .../RouterLabel/UniswapXRouterLabel.tsx | 2 +- .../RoutingDiagram/RoutingDiagram.tsx | 2 +- src/components/Row/index.tsx | 2 +- src/components/SearchModal/CommonBases.tsx | 2 +- .../SearchModal/CurrencyList/index.tsx | 2 +- src/components/SearchModal/CurrencySearch.tsx | 2 +- src/components/SearchModal/styleds.tsx | 2 +- src/components/Settings/Input/index.tsx | 2 +- .../Settings/MaxSlippageSettings/index.tsx | 2 +- src/components/Settings/MenuButton/index.tsx | 2 +- .../RouterPreferenceSettings/index.tsx | 2 +- .../TransactionDeadlineSettings/index.tsx | 4 +- src/components/Settings/index.tsx | 2 +- src/components/Slider/index.tsx | 2 +- src/components/SwitchLocaleLink/index.tsx | 2 +- src/components/TextInput/index.tsx | 2 +- src/components/Toggle/MultiToggle.tsx | 2 +- src/components/Toggle/index.tsx | 2 +- .../TokenSafety/TokenSafetyIcon.tsx | 2 +- .../TokenSafety/TokenSafetyLabel.tsx | 2 +- .../TokenSafety/TokenSafetyMessage.tsx | 2 +- src/components/TokenSafety/index.tsx | 2 +- src/components/Tokens/TokenDetails/About.tsx | 2 +- .../Tokens/TokenDetails/AddressSection.tsx | 2 +- .../Tokens/TokenDetails/BalanceSummary.tsx | 2 +- .../Tokens/TokenDetails/BreadcrumbNavLink.tsx | 2 +- .../TokenDetails/InvalidTokenDetails.tsx | 2 +- .../MobileBalanceSummaryFooter.tsx | 2 +- .../Tokens/TokenDetails/PriceChart.tsx | 2 +- .../Tokens/TokenDetails/Resource.tsx | 2 +- .../Tokens/TokenDetails/ShareButton.tsx | 2 +- .../Tokens/TokenDetails/Skeleton.tsx | 2 +- .../Tokens/TokenDetails/StatsSection.tsx | 2 +- .../Tokens/TokenDetails/TimeSelector.tsx | 2 +- src/components/Tokens/TokenDetails/index.tsx | 2 +- .../Tokens/TokenTable/FilterOption.tsx | 2 +- .../Tokens/TokenTable/NetworkFilter.tsx | 2 +- .../Tokens/TokenTable/SearchBar.tsx | 2 +- .../Tokens/TokenTable/TimeSelector.tsx | 2 +- src/components/Tokens/TokenTable/TokenRow.tsx | 2 +- .../Tokens/TokenTable/TokenTable.tsx | 2 +- .../__snapshots__/TokenRow.test.tsx.snap | 18 +- src/components/Tokens/loading.tsx | 2 +- src/components/Tooltip/index.tsx | 2 +- .../AnimatedConfirmation.tsx | 2 +- .../TransactionConfirmationModal/index.tsx | 2 +- src/components/V2Unsupported/index.tsx | 2 +- .../WalletModal/ConnectionErrorView.tsx | 2 +- src/components/WalletModal/Option.tsx | 2 +- .../WalletModal/PrivacyPolicyNotice.tsx | 2 +- src/components/WalletModal/index.tsx | 2 +- src/components/Web3Status/index.tsx | 2 +- .../addLiquidity/OwnershipWarning.tsx | 2 +- src/components/claim/AddressClaimModal.tsx | 2 +- src/components/earn/styled.ts | 2 +- src/components/swap/ConfirmSwapModal.tsx | 2 +- src/components/swap/GasBreakdownTooltip.tsx | 2 +- src/components/swap/GasEstimateTooltip.tsx | 2 +- .../PendingModalContent/ErrorModalContent.tsx | 2 +- .../swap/PendingModalContent/Logos.tsx | 2 +- .../swap/PendingModalContent/TradeSummary.tsx | 2 +- .../swap/PendingModalContent/index.tsx | 2 +- src/components/swap/PriceImpactModal.tsx | 2 +- src/components/swap/PriceImpactWarning.tsx | 2 +- src/components/swap/SwapBuyFiatButton.tsx | 2 +- src/components/swap/SwapDetailsDropdown.tsx | 2 +- src/components/swap/SwapHeader.tsx | 2 +- src/components/swap/SwapModalFooter.tsx | 5 +- src/components/swap/SwapModalHeader.tsx | 2 +- src/components/swap/SwapModalHeaderAmount.tsx | 2 +- src/components/swap/SwapSkeleton.tsx | 2 +- src/components/swap/TradePrice.tsx | 2 +- .../swap/UnsupportedCurrencyFooter.tsx | 2 +- src/components/swap/styleds.tsx | 2 +- src/components/vote/DelegateModal.tsx | 2 +- src/components/vote/ExecuteModal.tsx | 2 +- src/components/vote/ProposalEmptyState.tsx | 2 +- src/components/vote/QueueModal.tsx | 2 +- src/components/vote/VoteModal.tsx | 2 +- src/constants/chainInfo.ts | 28 +- src/constants/chains.ts | 4 - src/constants/locales.ts | 1 + src/graphql/data/util.tsx | 11 +- src/hooks/useAccountRiskCheck.ts | 4 +- src/hooks/useActiveLocale.ts | 3 +- src/hooks/useBestTrade.test.ts | 3 +- src/hooks/useBestTrade.ts | 3 +- src/hooks/useFeeTierDistribution.ts | 4 +- src/hooks/usePermitAllowance.ts | 6 +- src/hooks/usePoolTickData.ts | 4 +- src/hooks/useStablecoinPrice.ts | 2 +- src/hooks/useTokenWarningColor.ts | 2 +- src/hooks/useUSDPrice.ts | 3 +- src/i18n.tsx | 2 +- src/lib/hooks/orders/updater.tsx | 4 +- .../routing/clientSideSmartOrderRouter.ts | 3 +- .../hooks/routing/useRoutingAPIArguments.ts | 3 +- src/lib/hooks/transactions/updater.tsx | 6 +- src/lib/i18n.tsx | 99 +- src/nft/components/bag/Bag.tsx | 2 +- src/nft/components/bag/BagFooter.tsx | 2 +- src/nft/components/bag/BagHeader.tsx | 2 +- src/nft/components/bag/BagRow.tsx | 2 +- src/nft/components/bag/ButtonStates.tsx | 2 +- src/nft/components/bag/EmptyContent.tsx | 2 +- src/nft/components/bag/TimedLoader.tsx | 2 +- src/nft/components/card/containers.tsx | 2 +- src/nft/components/card/icons.tsx | 2 +- src/nft/components/card/media.tsx | 2 +- src/nft/components/collection/Activity.tsx | 2 +- .../components/collection/ActivityCells.tsx | 2 +- .../collection/ActivitySwitcher.tsx | 2 +- .../components/collection/CollectionNfts.tsx | 2 +- .../collection/CollectionPageSkeleton.tsx | 2 +- .../components/collection/CollectionStats.tsx | 2 +- .../collection/MarketplaceSelect.tsx | 2 +- src/nft/components/collection/PriceRange.tsx | 2 +- src/nft/components/collection/Sweep.tsx | 2 +- src/nft/components/collection/TraitChip.tsx | 2 +- .../components/collection/TraitsHeader.tsx | 2 +- .../collection/TransactionCompleteModal.tsx | 2 +- .../CollectionAsset.test.tsx.snap | 4 +- src/nft/components/collection/shared.tsx | 2 +- src/nft/components/details/AssetActivity.tsx | 2 +- src/nft/components/details/AssetDetails.tsx | 2 +- .../details/AssetDetailsLoading.tsx | 2 +- .../components/details/AssetPriceDetails.tsx | 2 +- .../components/details/DetailsContainer.tsx | 2 +- src/nft/components/details/InfoContainer.tsx | 2 +- .../components/details/TraitsContainer.tsx | 2 +- src/nft/components/explore/Banner.tsx | 2 +- src/nft/components/explore/Carousel.tsx | 2 +- src/nft/components/explore/CarouselCard.tsx | 2 +- src/nft/components/explore/Cells/Cells.tsx | 2 +- src/nft/components/explore/Table.tsx | 2 +- .../explore/TrendingCollections.tsx | 6 +- src/nft/components/icons.tsx | 2 +- src/nft/components/profile/list/Dropdown.tsx | 2 +- src/nft/components/profile/list/ListPage.tsx | 2 +- .../components/profile/list/ListingButton.tsx | 2 +- .../profile/list/MarketplaceRow.tsx | 2 +- .../list/Modal/BelowFloorWarningModal.tsx | 2 +- .../profile/list/Modal/ContentRow.tsx | 2 +- .../profile/list/Modal/ListModal.tsx | 2 +- .../profile/list/Modal/ListModalSection.tsx | 4 +- .../profile/list/Modal/SuccessScreen.tsx | 2 +- .../components/profile/list/NFTListRow.tsx | 2 +- .../profile/list/NFTListingsGrid.tsx | 2 +- .../profile/list/PriceTextInput.tsx | 2 +- .../profile/list/RoyaltyTooltip.tsx | 2 +- .../list/SelectMarketplacesDropdown.tsx | 2 +- .../profile/list/SetDurationModal.tsx | 10 +- src/nft/components/profile/list/shared.tsx | 2 +- src/nft/components/profile/list/utils.ts | 6 +- .../profile/view/EmptyWalletContent.tsx | 2 +- .../components/profile/view/FilterSidebar.tsx | 2 +- .../components/profile/view/ProfilePage.tsx | 2 +- .../view/ProfilePageLoadingSkeleton.tsx | 2 +- .../ViewMyNftsAsset.test.tsx.snap | 4 +- src/nft/components/profile/view/icons.tsx | 2 +- .../useDerivedPayWithAnyTokenSwapInfo.ts | 3 +- src/nft/hooks/usePriceImpact.ts | 2 +- src/nft/pages/asset/Asset.tsx | 2 +- src/nft/pages/collection/index.css.ts | 2 +- src/nft/pages/collection/index.tsx | 2 +- src/nft/pages/explore/index.tsx | 2 +- src/nft/pages/profile/profile.tsx | 2 +- .../queries/openSea/PostOpenSeaSellOrder.ts | 4 +- src/nft/utils/time.ts | 14 +- src/pages/AddLiquidity/Review.tsx | 2 +- src/pages/AddLiquidity/index.tsx | 2 +- src/pages/AddLiquidity/styled.tsx | 2 +- src/pages/AddLiquidityV2/PoolPriceBar.tsx | 2 +- src/pages/AddLiquidityV2/index.tsx | 2 +- src/pages/App.tsx | 2 +- src/pages/AppBody.tsx | 2 +- .../CreateProposal/ProposalActionDetail.tsx | 2 +- .../CreateProposal/ProposalActionSelector.tsx | 2 +- src/pages/CreateProposal/ProposalEditor.tsx | 2 +- .../ProposalSubmissionModal.tsx | 2 +- src/pages/CreateProposal/index.tsx | 2 +- .../Landing/__snapshots__/index.test.tsx.snap | 82 +- src/pages/Landing/index.tsx | 2 +- src/pages/MigrateV2/MigrateV2Pair.tsx | 2 +- src/pages/MigrateV2/index.tsx | 2 +- src/pages/NotFound/index.tsx | 2 +- src/pages/Pool/CTACards.test.tsx | 9 +- src/pages/Pool/CTACards.tsx | 2 +- src/pages/Pool/PositionPage.tsx | 2 +- src/pages/Pool/index.test.tsx | 20 +- src/pages/Pool/index.tsx | 2 +- src/pages/Pool/styleds.tsx | 2 +- src/pages/Pool/v2.tsx | 2 +- src/pages/RemoveLiquidity/V3.tsx | 2 +- src/pages/RemoveLiquidity/index.tsx | 2 +- src/pages/RemoveLiquidity/styled.ts | 2 +- src/pages/Swap/UniswapXOptIn.tsx | 2 +- src/pages/Swap/index.tsx | 2 +- src/pages/Tokens/index.tsx | 2 +- src/pages/Vote/Landing.tsx | 2 +- src/pages/Vote/VotePage.tsx | 8 +- src/pages/Vote/styled.tsx | 2 +- src/setupTests.ts | 1 + src/state/lists/updater.ts | 4 +- src/state/routing/slice.ts | 34 +- src/state/routing/types.ts | 28 +- src/state/routing/useRoutingAPITrade.ts | 17 +- src/state/routing/utils.ts | 3 +- src/theme/components/SegmentedControl.tsx | 2 +- src/theme/components/ThemeToggle.tsx | 4 +- src/theme/components/index.tsx | 2 +- src/theme/components/text.tsx | 2 +- src/theme/index.tsx | 2 +- src/theme/styled.d.ts | 2 +- src/theme/styles.ts | 2 +- yarn.lock | 927 +++++++++--------- 323 files changed, 1065 insertions(+), 1232 deletions(-) create mode 100644 .swcrc delete mode 100644 babel-plugin-macros.config.js diff --git a/.eslintrc.js b/.eslintrc.js index 9a66e49699..dda8306355 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -1,5 +1,6 @@ /* eslint-env node */ +const { node: restrictedImports } = require('@uniswap/eslint-config/restrictedImports') require('@uniswap/eslint-config/load') const rulesDirPlugin = require('eslint-plugin-rulesdir') @@ -27,6 +28,7 @@ module.exports = { { files: ['**/*.ts', '**/*.tsx'], rules: { + '@typescript-eslint/no-restricted-imports': ['error', restrictedImports], 'import/no-restricted-paths': [ 'error', { diff --git a/.github/actions/setup/action.yml b/.github/actions/setup/action.yml index 107c3e3c27..a506d7baf6 100644 --- a/.github/actions/setup/action.yml +++ b/.github/actions/setup/action.yml @@ -24,10 +24,6 @@ runs: run: yarn install --frozen-lockfile --ignore-scripts shell: bash - # Validators compile quickly, so caching can be omitted. - - run: yarn ajv - shell: bash - # Contracts are compiled from source. If source hasn't changed, the contracts do not need to be re-compiled. - uses: actions/cache@v3 id: contracts-cache @@ -40,30 +36,10 @@ runs: run: yarn contracts shell: bash - # GraphQL is generated from schema and client-side graphql queries. The schema is always fetched and changes to - # client-side queries are hard to detect, so it is always re-generated. - # TODO(WEB-2498): Cache based on both fetched schema and client-side graphql queries. - # This will require some processing: cp all literal graphql tags into a separate file and hash it? - - run: yarn graphql - shell: bash - - # Messages are extracted from source. - # A record of source file content hashes and catalogs is maintained in node_modules/.cache/lingui. - # Messages are always extracted, but extraction may short-circuit from the custom extractor's cache. - - uses: ./.github/actions/cache-on-main - with: - path: node_modules/.cache - key: ${{ runner.os }}-i18n-extract-${{ github.run_id }} - restore-keys: ${{ runner.os }}-i18n-extract- - - run: yarn i18n:extract - shell: bash - - # Translations are compiled from messages. If messages haven't changed, the translations do not need to be re-compiled. - - uses: actions/cache@v3 - id: i18n-compile-cache - with: - path: src/locales/*.js - key: ${{ runner.os }}-i18n-compile-${{ hashFiles('src/locales/*.po') }} - - if: steps.i18n-compile-cache.outputs.cache-hit !='true' - run: yarn i18n:compile + # These operations cannot be cached, so they are run concurrently + # - ajv: Validators compile quickly, so caching can be omitted. + # - graphql: GraphQL is generated from schema and client-side graphql queries. The schema is always fetched and + # changes to client-side queries are hard to detect, so it is always re-generated. + # - i18n: Messages are extracted from source and compiled. No caching extractor is available (out-of-the-box). + - run: yarn concurrently --max-processes=100% npm:ajv npm:graphql npm:i18n shell: bash diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index b848dd5668..6b3bf7ca1f 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -81,22 +81,20 @@ jobs: name: Unit tests SLACK_WEBHOOK_URL: ${{ secrets.SLACK_TEST_REPORTER_WEBHOOK }} - build-e2e: + build: runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 - uses: ./.github/actions/setup - uses: ./.github/actions/cache-on-main with: - path: node_modules/.cache - key: ${{ runner.os }}-build-e2e-${{ github.run_id }} - restore-keys: ${{ runner.os }}-build-e2e- - - run: yarn build:e2e - env: - NODE_OPTIONS: "--max_old_space_size=4096" + path: node_modules/.swc + key: ${{ runner.os }}-swc-${{ github.run_id }} + restore-keys: ${{ runner.os }}-swc- + - run: yarn build - uses: actions/upload-artifact@v3 with: - name: build-e2e + name: build path: build if-no-files-found: error @@ -124,7 +122,7 @@ jobs: - run: exit 0 cypress-test-matrix: - needs: [build-e2e, cypress-rerun] + needs: [build, cypress-rerun] runs-on: ubuntu-latest strategy: fail-fast: false @@ -143,7 +141,7 @@ jobs: - uses: actions/download-artifact@v3 with: - name: build-e2e + name: build path: build - uses: ./.github/actions/cache-on-main @@ -175,11 +173,6 @@ jobs: COMMIT_INFO_TIMESTAMP: ${{ github.event.pull_request.updated_at || github.event.head_commit.timestamp }} CYPRESS_PULL_REQUEST_ID: ${{ github.event.pull_request.number }} CYPRESS_PULL_REQUEST_URL: ${{ github.event.pull_request.html_url }} - - uses: codecov/codecov-action@v3 - with: - token: ${{ secrets.CODECOV_TOKEN }} - fail_ci_if_error: false - flags: e2e-tests - if: failure() && github.ref_name == 'main' uses: ./.github/actions/report with: diff --git a/.gitignore b/.gitignore index d6fbe5d46d..54ce7dd646 100644 --- a/.gitignore +++ b/.gitignore @@ -20,6 +20,7 @@ schema.graphql /coverage /cache /functions/coverage +/.swc # builds /build diff --git a/.swcrc b/.swcrc new file mode 100644 index 0000000000..fcd2e2051c --- /dev/null +++ b/.swcrc @@ -0,0 +1,29 @@ +{ + "$schema": "https://json.schemastore.org/swcrc", + "jsc": { + "keepClassNames": true, + "experimental": { + "plugins": [ + [ + "@lingui/swc-plugin", + {} + ], + [ + "@swc/plugin-styled-components", + { + "displayName": true + } + ] + ] + }, + "parser": { + "syntax": "typescript", + "tsx": true + }, + "transform": { + "react": { + "runtime": "automatic" + } + } + } +} diff --git a/babel-plugin-macros.config.js b/babel-plugin-macros.config.js deleted file mode 100644 index 5f65e606c0..0000000000 --- a/babel-plugin-macros.config.js +++ /dev/null @@ -1,10 +0,0 @@ -/* eslint-env node */ - -const isDev = process.env.NODE_ENV === 'development' - -module.exports = { - styledComponents: { - fileName: isDev, - displayName: isDev, - }, -} diff --git a/codecov.yml b/codecov.yml index 00c2dc6ac1..090053580b 100644 --- a/codecov.yml +++ b/codecov.yml @@ -11,7 +11,6 @@ ignore: coverage: status: - # Omit merging unit/e2e reports into the defaults, as it is nonsensical. project: off patch: off @@ -28,17 +27,9 @@ flag_management: target: 80% individual_flags: - name: unit-tests - - name: e2e-tests - # Wait until all machines have reported coverage - e2e tests run across 4 machines. - after_n_builds: 4 - statuses: - - type: patch - target: 0% comment: layout: flags - # Wait until all machines have reported coverage - e2e tests run across 4 machines + unit tests across 1. - after_n_builds: 5 hide_comment_details: false github_checks: diff --git a/craco.config.cjs b/craco.config.cjs index 624c17cc45..d87d328b5a 100644 --- a/craco.config.cjs +++ b/craco.config.cjs @@ -5,12 +5,15 @@ const { execSync } = require('child_process') const MiniCssExtractPlugin = require('mini-css-extract-plugin') const path = require('path') const ModuleScopePlugin = require('react-dev-utils/ModuleScopePlugin') -const { DefinePlugin, IgnorePlugin, ProvidePlugin } = require('webpack') +const TerserPlugin = require('terser-webpack-plugin') +const { IgnorePlugin, ProvidePlugin } = require('webpack') const { RetryChunkLoadPlugin } = require('webpack-retry-chunk-load-plugin') const commitHash = execSync('git rev-parse HEAD').toString().trim() const isProduction = process.env.NODE_ENV === 'production' +process.env.REACT_APP_GIT_COMMIT_HASH = commitHash + // Linting and type checking are only necessary as part of development and testing. // Omit them from production builds, as they slow down the feedback loop. const shouldLintOrTypeCheck = !isProduction @@ -21,32 +24,6 @@ function getCacheDirectory(cacheName) { } module.exports = { - babel: { - plugins: [ - '@vanilla-extract/babel-plugin', - ...(process.env.REACT_APP_ADD_COVERAGE_INSTRUMENTATION - ? [ - [ - 'istanbul', - { - all: true, - include: ['src/**/*.tsx', 'src/**/*.ts'], - exclude: [ - 'src/**/*.css', - 'src/**/*.css.ts', - 'src/**/*.test.ts', - 'src/**/*.test.tsx', - 'src/**/*.spec.ts', - 'src/**/*.spec.tsx', - 'src/**/graphql/**/*', - 'src/**/*.d.ts', - ], - }, - ], - ] - : []), - ], - }, eslint: { enable: shouldLintOrTypeCheck, pluginOptions(eslintConfig) { @@ -69,11 +46,16 @@ module.exports = { configure(jestConfig) { return Object.assign(jestConfig, { cacheDirectory: getCacheDirectory('jest'), - transform: Object.assign(jestConfig.transform, { + transform: { + ...Object.entries(jestConfig.transform).reduce((transform, [key, value]) => { + if (value.match(/babel/)) return transform + return { ...transform, [key]: value } + }, {}), // Transform vanilla-extract using its own transformer. // See https://sandroroth.com/blog/vanilla-extract-cra#jest-transform. '\\.css\\.ts$': '@vanilla-extract/jest-transform', - }), + '\\.(t|j)sx?$': '@swc/jest', + }, // Use @uniswap/conedison's build directly, as jest does not support its exports. transformIgnorePatterns: ['@uniswap/conedison/format', '@uniswap/conedison/provider'], moduleNameMapper: { @@ -88,12 +70,9 @@ module.exports = { // Webpack 5 does not polyfill node globals, so we do so for those necessary: new ProvidePlugin({ // - react-markdown requires process.cwd - process: 'process/browser', + process: 'process/browser.js', }), - // vanilla-extract has poor performance on M1 machines with 'debug' identifiers, so we use 'short' instead. - // See https://vanilla-extract.style/documentation/integrations/webpack/#identifiers for docs. - // See https://github.com/vanilla-extract-css/vanilla-extract/issues/771#issuecomment-1249524366. - new VanillaExtractPlugin({ identifiers: 'short' }), + new VanillaExtractPlugin(), new RetryChunkLoadPlugin({ cacheBust: `function() { return 'cache-bust=' + Date.now(); @@ -109,14 +88,6 @@ module.exports = { // Configure webpack plugins: webpackConfig.plugins = webpackConfig.plugins .map((plugin) => { - // Extend process.env with dynamic values (eg commit hash). - // This will make dynamic values available to JavaScript only, not to interpolated HTML (ie index.html). - if (plugin instanceof DefinePlugin) { - Object.assign(plugin.definitions['process.env'], { - REACT_APP_GIT_COMMIT_HASH: JSON.stringify(commitHash), - }) - } - // CSS ordering is mitigated through scoping / naming conventions, so we can ignore order warnings. // See https://webpack.js.org/plugins/mini-css-extract-plugin/#remove-order-warnings. if (plugin instanceof MiniCssExtractPlugin) { @@ -163,13 +134,9 @@ module.exports = { // Configure webpack transpilation (create-react-app specifies transpilation rules in a oneOf): webpackConfig.module.rules[1].oneOf = webpackConfig.module.rules[1].oneOf.map((rule) => { - // The fallback rule (eg for dependencies). - if (rule.loader && rule.loader.match(/babel-loader/) && !rule.include) { - // Allow not-fully-specified modules so that legacy packages are still able to build. - rule.resolve = { fullySpecified: false } - - // The class properties transform is required for @uniswap/analytics to build. - rule.options.plugins.push('@babel/plugin-proposal-class-properties') + if (rule.loader && rule.loader.match(/babel-loader/)) { + rule.loader = 'swc-loader' + delete rule.options } return rule }) @@ -177,6 +144,15 @@ module.exports = { // Configure webpack optimization: webpackConfig.optimization = Object.assign( webpackConfig.optimization, + { + minimize: isProduction, + minimizer: [ + new TerserPlugin({ + minify: TerserPlugin.swcMinify, + parallel: require('os').cpus().length, + }), + ], + }, isProduction ? { splitChunks: { @@ -192,16 +168,15 @@ module.exports = { : {} ) - // Configure webpack caching: - webpackConfig.cache = Object.assign(webpackConfig.cache, { - cacheDirectory: getCacheDirectory('webpack'), - }) + // Configure webpack resolution. webpackConfig.cache is unused with swc-loader, but the resolver can still cache: + webpackConfig.resolve = Object.assign(webpackConfig.resolve, { unsafeCache: true }) - // Ignore failed source mappings to avoid spamming the console. - // Source mappings for a package will fail if the package does not provide them, but the build will still succeed, - // so it is unnecessary (and bothersome) to log it. This should be turned off when debugging missing sourcemaps. - // See https://webpack.js.org/loaders/source-map-loader#ignoring-warnings. - webpackConfig.ignoreWarnings = [/Failed to parse source map/] + webpackConfig.ignoreWarnings = [ + // Source mappings for a package will fail if the package does not provide them, but the build will still succeed, + // so it is unnecessary (and bothersome) to log it. This should be turned off when debugging missing sourcemaps. + // See https://webpack.js.org/loaders/source-map-loader#ignoring-warnings. + /Failed to parse source map/, + ] return webpackConfig }, diff --git a/lingui.config.ts b/lingui.config.ts index e367228b2b..dd9dba09b3 100644 --- a/lingui.config.ts +++ b/lingui.config.ts @@ -1,64 +1,4 @@ /* eslint-env node */ -import { default as babelExtractor } from '@lingui/cli/api/extractors/babel' -import { createHash } from 'crypto' -import { mkdirSync, readFileSync, writeFileSync } from 'fs' -import { existsSync } from 'fs' -import * as path from 'path' - -/** A custom caching extractor built on top of babelExtractor. */ -const cachingExtractor: typeof babelExtractor = { - /** Delegates to babelExtractor.match. */ - match(filename: string) { - return babelExtractor.match(filename) - }, - /** - * Checks a cache before extraction, only delegating to babelExtractor.extract if the file has changed. - * - * The lingui extractor works by extracting JSON (the catalog) from `filename` to `buildDir/filename.json`. - * Caching works by man-in-the-middling this: - * - File freshness is computed as a hash of `filename` contents. - * - Before extracting, we check the cache to see if we already have a fresh catalog for the file. - * If we do, we copy it to `localeDir/filename.json`. Copying is significantly faster than extracting. - * - After extracting, we copy the catalog to the cache. - */ - extract(filename: string, localeDir: string, ...options: unknown[]) { - // This runs from node_modules/@lingui/conf, so we need to back out to the root. - const root = __dirname.split('/node_modules')[0] - - // This logic mimics catalogFilename in @lingui/babel-plugin-extract-messages. - const buildDir = path.join(localeDir, '_build') - const localePath = path.join(buildDir, filename + '.json') - - const filePath = path.join(root, filename) - const fileHash = createHash('sha256').update(readFileSync(filePath)).digest('hex') - - const cacheRoot = path.join(root, 'node_modules/.cache/lingui') - const cachePath = path.join(cacheRoot, filename + '.json') - - // If we have a matching cached copy of the catalog, we can copy it to localePath and return early. - if (existsSync(cachePath)) { - const { hash, catalog } = JSON.parse(readFileSync(cachePath, 'utf8')) - if (hash === fileHash) { - if (catalog) { - mkdirSync(path.dirname(localePath), { recursive: true }) - writeFileSync(localePath, JSON.stringify(catalog, null, 2)) - } - return - } - } - - babelExtractor.extract(filename, localeDir, ...options) - - // Cache the extracted catalog. - mkdirSync(path.dirname(cachePath), { recursive: true }) - if (existsSync(localePath)) { - const catalog = JSON.parse(readFileSync(localePath, 'utf8')) - writeFileSync(cachePath, JSON.stringify({ hash: fileHash, catalog })) - } else { - writeFileSync(cachePath, JSON.stringify({ hash: fileHash })) - } - }, -} const linguiConfig = { catalogs: [ @@ -120,7 +60,6 @@ const linguiConfig = { rootDir: '.', runtimeConfigModule: ['@lingui/core', 'i18n'], sourceLocale: 'en-US', - extractors: [cachingExtractor], } export default linguiConfig diff --git a/package.json b/package.json index 6abe5be694..f860f8151f 100644 --- a/package.json +++ b/package.json @@ -20,7 +20,6 @@ "start": "craco start", "start:cloud": "NODE_OPTIONS=--dns-result-order=ipv4first PORT=3001 npx wrangler pages dev --node-compat --proxy=3001 --port=3000 -- yarn start", "build": "craco build", - "build:e2e": "REACT_APP_CSP_ALLOW_UNSAFE_EVAL=true REACT_APP_ADD_COVERAGE_INSTRUMENTATION=true craco build", "analyze": "source-map-explorer 'build/static/js/*.js' --only-mapped", "serve": "serve build -l 3000", "lint": "yarn eslint --ignore-path .gitignore --cache --cache-location node_modules/.cache/eslint/ .", @@ -69,12 +68,15 @@ ] }, "devDependencies": { - "@babel/plugin-proposal-private-property-in-object": "^7.21.11", "@babel/preset-env": "^7.22.7", "@cloudflare/workers-types": "^4.20230710.1", "@craco/craco": "^7.1.0", "@ethersproject/experimental": "^5.4.0", - "@lingui/cli": "^3.9.0", + "@lingui/cli": "^4.3.0", + "@lingui/swc-plugin": "^4.0.4", + "@swc/core": "^1.3.72", + "@swc/jest": "^0.2.27", + "@swc/plugin-styled-components": "^1.5.70", "@testing-library/jest-dom": "^5.16.4", "@testing-library/react": "^13.1", "@testing-library/user-event": "^14.4.3", @@ -86,7 +88,7 @@ "@types/lingui__core": "^2.7.1", "@types/lingui__macro": "^2.7.4", "@types/lingui__react": "^2.8.3", - "@types/ms.macro": "^2.0.0", + "@types/ms": "^0.7.31", "@types/multicodec": "^1.0.0", "@types/node": "^13.13.5", "@types/qs": "^6.9.2", @@ -104,12 +106,10 @@ "@types/wcag-contrast": "^3.0.0", "@uniswap/default-token-list": "^11.2.0", "@uniswap/eslint-config": "^1.2.0", - "@vanilla-extract/babel-plugin": "^1.1.7", "@vanilla-extract/jest-transform": "^1.1.1", - "@vanilla-extract/webpack-plugin": "^2.1.11", + "@vanilla-extract/webpack-plugin": "^2.2.0", "@walletconnect/types": "^2.8.6", "babel-jest": "^29.6.1", - "babel-plugin-istanbul": "^6.1.1", "browser-cache-mock": "^0.1.7", "buffer": "^6.0.3", "concurrently": "^8.0.1", @@ -126,7 +126,7 @@ "jest-fail-on-console": "^3.1.1", "jest-fetch-mock": "^3.0.3", "jest-styled-components": "^7.0.8", - "ms.macro": "^2.0.0", + "mini-css-extract-plugin": "^2.7.6", "path-browserify": "^1.0.1", "prettier": "^2.8.8", "process": "^0.11.10", @@ -134,10 +134,13 @@ "resize-observer-polyfill": "^1.5.1", "serve": "^11.3.2", "source-map-explorer": "^2.5.3", + "swc-loader": "^0.2.3", + "terser-webpack-plugin": "^5.3.9", "ts-jest": "^29.1.1", "ts-transform-graphql-tag": "^0.2.1", "typechain": "^5.0.0", "typescript": "^4.9.4", + "webpack": "^5.88.2", "webpack-retry-chunk-load-plugin": "^3.1.1", "wrangler": "^3.4.0", "yarn-deduplicate": "^6.0.0" @@ -155,9 +158,9 @@ "@graphql-codegen/typescript-react-apollo": "^3.3.7", "@graphql-codegen/typescript-resolvers": "^3.2.1", "@juggle/resize-observer": "^3.4.0", - "@lingui/core": "^3.14.0", - "@lingui/macro": "^3.14.0", - "@lingui/react": "^3.14.0", + "@lingui/core": "^4.3.0", + "@lingui/macro": "^4.3.0", + "@lingui/react": "^4.3.0", "@looksrare/sdk": "^0.10.2", "@metamask/jazzicon": "^2.0.0", "@opensea/seaport-js": "^1.2.0", @@ -189,10 +192,10 @@ "@uniswap/v3-core": "^1.0.1", "@uniswap/v3-periphery": "^1.1.1", "@uniswap/v3-sdk": "^3.10.0", - "@vanilla-extract/css": "^1.7.2", - "@vanilla-extract/css-utils": "^0.1.2", - "@vanilla-extract/dynamic": "^2.0.2", - "@vanilla-extract/sprinkles": "^1.4.1", + "@vanilla-extract/css": "^1.12.0", + "@vanilla-extract/css-utils": "^0.1.3", + "@vanilla-extract/dynamic": "^2.0.3", + "@vanilla-extract/sprinkles": "^1.6.1", "@visx/axis": "^2.12.2", "@visx/event": "^2.6.0", "@visx/glyph": "^2.10.0", @@ -228,6 +231,7 @@ "jotai": "^1.3.7", "jsbi": "^3.1.4", "make-plural": "^7.0.0", + "ms": "^2.1.3", "multicodec": "^3.0.1", "multihashes": "^4.0.2", "node-vibrant": "^3.2.1-alpha.1", diff --git a/src/components/About/AboutFooter.tsx b/src/components/About/AboutFooter.tsx index 5630d44a46..e587f6eeda 100644 --- a/src/components/About/AboutFooter.tsx +++ b/src/components/About/AboutFooter.tsx @@ -1,7 +1,7 @@ import { BrowserEvent, InterfaceElementName, SharedEventName } from '@uniswap/analytics-events' import { TraceEvent } from 'analytics' import { useDisableNFTRoutes } from 'hooks/useDisableNFTRoutes' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { BREAKPOINTS, ExternalLink, StyledRouterLink } from 'theme' import { useIsDarkMode } from 'theme/components/ThemeToggle' diff --git a/src/components/About/Card.tsx b/src/components/About/Card.tsx index 99e799328e..27bf9c068b 100644 --- a/src/components/About/Card.tsx +++ b/src/components/About/Card.tsx @@ -1,7 +1,7 @@ import { BrowserEvent, SharedEventName } from '@uniswap/analytics-events' import { TraceEvent } from 'analytics' import { Link } from 'react-router-dom' -import styled, { DefaultTheme } from 'styled-components/macro' +import styled, { DefaultTheme } from 'styled-components' import { BREAKPOINTS } from 'theme' import { useIsDarkMode } from 'theme/components/ThemeToggle' diff --git a/src/components/About/Icons.tsx b/src/components/About/Icons.tsx index a606345e8f..195f8aed18 100644 --- a/src/components/About/Icons.tsx +++ b/src/components/About/Icons.tsx @@ -1,4 +1,4 @@ -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ReactComponent as DiscordI } from './images/discord.svg' import { ReactComponent as GithubI } from './images/github.svg' diff --git a/src/components/About/ProtocolBanner.tsx b/src/components/About/ProtocolBanner.tsx index 0c7544580c..f342fcd9e0 100644 --- a/src/components/About/ProtocolBanner.tsx +++ b/src/components/About/ProtocolBanner.tsx @@ -1,5 +1,5 @@ import { ButtonEmpty } from 'components/Button' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { BREAKPOINTS } from 'theme' import { useIsDarkMode } from 'theme/components/ThemeToggle' diff --git a/src/components/About/constants.tsx b/src/components/About/constants.tsx index 37119f4d5d..f480b6f4f2 100644 --- a/src/components/About/constants.tsx +++ b/src/components/About/constants.tsx @@ -1,6 +1,6 @@ import { InterfaceElementName } from '@uniswap/analytics-events' import { DollarSign, Terminal } from 'react-feather' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { lightTheme } from 'theme/colors' import darkArrowImgSrc from './images/aboutArrowDark.png' diff --git a/src/components/AccountDrawer/AuthenticatedHeader.tsx b/src/components/AccountDrawer/AuthenticatedHeader.tsx index 6974be95dc..539ea5b81a 100644 --- a/src/components/AccountDrawer/AuthenticatedHeader.tsx +++ b/src/components/AccountDrawer/AuthenticatedHeader.tsx @@ -21,7 +21,7 @@ import { ArrowDownRight, ArrowUpRight, CreditCard, IconProps, Info, LogOut, Sett import { useNavigate } from 'react-router-dom' import { useAppDispatch } from 'state/hooks' import { updateSelectedWallet } from 'state/user/reducer' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import { CopyHelper, ExternalLink, ThemedText } from 'theme' import { shortenAddress } from 'utils' diff --git a/src/components/AccountDrawer/DefaultMenu.tsx b/src/components/AccountDrawer/DefaultMenu.tsx index f64b25e0cd..1f2a6c2f90 100644 --- a/src/components/AccountDrawer/DefaultMenu.tsx +++ b/src/components/AccountDrawer/DefaultMenu.tsx @@ -2,7 +2,7 @@ import { useWeb3React } from '@web3-react/core' import Column from 'components/Column' import WalletModal from 'components/WalletModal' import { useCallback, useEffect, useState } from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' import AuthenticatedHeader from './AuthenticatedHeader' import SettingsMenu from './SettingsMenu' diff --git a/src/components/AccountDrawer/DownloadButton.tsx b/src/components/AccountDrawer/DownloadButton.tsx index 8c01efd4e2..cf3c0b013a 100644 --- a/src/components/AccountDrawer/DownloadButton.tsx +++ b/src/components/AccountDrawer/DownloadButton.tsx @@ -1,6 +1,6 @@ import { InterfaceElementName } from '@uniswap/analytics-events' import { PropsWithChildren, useCallback } from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ClickableStyle } from 'theme' import { openDownloadApp } from 'utils/openDownloadApp' diff --git a/src/components/AccountDrawer/GitVersionRow.tsx b/src/components/AccountDrawer/GitVersionRow.tsx index 92ea6b76cd..03b36c9cdd 100644 --- a/src/components/AccountDrawer/GitVersionRow.tsx +++ b/src/components/AccountDrawer/GitVersionRow.tsx @@ -1,7 +1,7 @@ import { Trans } from '@lingui/macro' import Tooltip from 'components/Tooltip' import useCopyClipboard from 'hooks/useCopyClipboard' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ThemedText } from 'theme' const Container = styled.div` diff --git a/src/components/AccountDrawer/IconButton.tsx b/src/components/AccountDrawer/IconButton.tsx index 7bc0ad23ea..8978aee618 100644 --- a/src/components/AccountDrawer/IconButton.tsx +++ b/src/components/AccountDrawer/IconButton.tsx @@ -1,6 +1,6 @@ import React, { forwardRef, useCallback, useEffect, useRef, useState } from 'react' import { Icon } from 'react-feather' -import styled, { css, DefaultTheme } from 'styled-components/macro' +import styled, { css, DefaultTheme } from 'styled-components' import useResizeObserver from 'use-resize-observer' import { TRANSITION_DURATIONS } from '../../theme/styles' diff --git a/src/components/AccountDrawer/MiniPortfolio/Activity/ActivityRow.tsx b/src/components/AccountDrawer/MiniPortfolio/Activity/ActivityRow.tsx index 299eab7409..d4fde41bf1 100644 --- a/src/components/AccountDrawer/MiniPortfolio/Activity/ActivityRow.tsx +++ b/src/components/AccountDrawer/MiniPortfolio/Activity/ActivityRow.tsx @@ -7,7 +7,7 @@ import Row from 'components/Row' import { TransactionStatus } from 'graphql/data/__generated__/types-and-hooks' import useENSName from 'hooks/useENSName' import { useCallback } from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { EllipsisStyle, ThemedText } from 'theme' import { shortenAddress } from 'utils' import { ExplorerDataType, getExplorerLink } from 'utils/getExplorerLink' diff --git a/src/components/AccountDrawer/MiniPortfolio/Activity/OffchainActivityModal.tsx b/src/components/AccountDrawer/MiniPortfolio/Activity/OffchainActivityModal.tsx index 64f3896daf..a39f40c40c 100644 --- a/src/components/AccountDrawer/MiniPortfolio/Activity/OffchainActivityModal.tsx +++ b/src/components/AccountDrawer/MiniPortfolio/Activity/OffchainActivityModal.tsx @@ -16,7 +16,7 @@ import { X } from 'react-feather' import { InterfaceTrade } from 'state/routing/types' import { useOrder } from 'state/signatures/hooks' import { UniswapXOrderDetails } from 'state/signatures/types' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ExternalLink, ThemedText } from 'theme' import { ExplorerDataType, getExplorerLink } from 'utils/getExplorerLink' diff --git a/src/components/AccountDrawer/MiniPortfolio/Activity/index.tsx b/src/components/AccountDrawer/MiniPortfolio/Activity/index.tsx index 466437ebc3..525514a9d7 100644 --- a/src/components/AccountDrawer/MiniPortfolio/Activity/index.tsx +++ b/src/components/AccountDrawer/MiniPortfolio/Activity/index.tsx @@ -8,7 +8,7 @@ import { PollingInterval } from 'graphql/data/util' import { atom, useAtom } from 'jotai' import { EmptyWalletModule } from 'nft/components/profile/view/EmptyWalletContent' import { useEffect, useMemo } from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ThemedText } from 'theme' import { PortfolioSkeleton, PortfolioTabWrapper } from '../PortfolioRow' diff --git a/src/components/AccountDrawer/MiniPortfolio/Activity/parseRemote.tsx b/src/components/AccountDrawer/MiniPortfolio/Activity/parseRemote.tsx index 613e7092aa..af74fbb46e 100644 --- a/src/components/AccountDrawer/MiniPortfolio/Activity/parseRemote.tsx +++ b/src/components/AccountDrawer/MiniPortfolio/Activity/parseRemote.tsx @@ -19,7 +19,7 @@ import { TransactionDetailsPartsFragment, } from 'graphql/data/__generated__/types-and-hooks' import { logSentryErrorForUnsupportedChain, supportedChainIdFromGQLChain } from 'graphql/data/util' -import ms from 'ms.macro' +import ms from 'ms' import { useEffect, useState } from 'react' import { isAddress } from 'utils' @@ -387,12 +387,12 @@ const getTimeSince = (timestamp: number) => { let interval // TODO(cartcrom): use locale to determine date shorthands to use for non-english - if ((interval = seconds / ms`1y`) > 1) return Math.floor(interval) + 'y' - if ((interval = seconds / ms`30d`) > 1) return Math.floor(interval) + 'mo' - if ((interval = seconds / ms`1d`) > 1) return Math.floor(interval) + 'd' - if ((interval = seconds / ms`1h`) > 1) return Math.floor(interval) + 'h' - if ((interval = seconds / ms`1m`) > 1) return Math.floor(interval) + 'm' - else return Math.floor(seconds / ms`1s`) + 's' + if ((interval = seconds / ms(`1y`)) > 1) return Math.floor(interval) + 'y' + if ((interval = seconds / ms(`30d`)) > 1) return Math.floor(interval) + 'mo' + if ((interval = seconds / ms(`1d`)) > 1) return Math.floor(interval) + 'd' + if ((interval = seconds / ms(`1h`)) > 1) return Math.floor(interval) + 'h' + if ((interval = seconds / ms(`1m`)) > 1) return Math.floor(interval) + 'm' + else return Math.floor(seconds / ms(`1s`)) + 's' } /** @@ -406,11 +406,11 @@ export function useTimeSince(timestamp: number) { useEffect(() => { const refreshTime = () => setTimeout(() => { - if (Math.floor(Date.now() - timestamp * 1000) / ms`61s` <= 1) { + if (Math.floor(Date.now() - timestamp * 1000) / ms(`61s`) <= 1) { setTimeSince(getTimeSince(timestamp)) timeout = refreshTime() } - }, ms`1s`) + }, ms(`1s`)) let timeout = refreshTime() diff --git a/src/components/AccountDrawer/MiniPortfolio/ExpandoRow.tsx b/src/components/AccountDrawer/MiniPortfolio/ExpandoRow.tsx index 73d0e5ebc7..109a020d9b 100644 --- a/src/components/AccountDrawer/MiniPortfolio/ExpandoRow.tsx +++ b/src/components/AccountDrawer/MiniPortfolio/ExpandoRow.tsx @@ -3,7 +3,7 @@ import Column from 'components/Column' import Row from 'components/Row' import { PropsWithChildren } from 'react' import { ChevronDown } from 'react-feather' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ThemedText } from 'theme' const ExpandIcon = styled(ChevronDown)<{ $expanded: boolean }>` diff --git a/src/components/AccountDrawer/MiniPortfolio/NFTs/NFTItem.tsx b/src/components/AccountDrawer/MiniPortfolio/NFTs/NFTItem.tsx index b30af153eb..a97df7b470 100644 --- a/src/components/AccountDrawer/MiniPortfolio/NFTs/NFTItem.tsx +++ b/src/components/AccountDrawer/MiniPortfolio/NFTs/NFTItem.tsx @@ -10,7 +10,7 @@ import { VerifiedIcon } from 'nft/components/icons' import { WalletAsset } from 'nft/types' import { floorFormatter } from 'nft/utils' import { useNavigate } from 'react-router-dom' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ThemedText } from 'theme' const FloorPrice = styled(Row)` diff --git a/src/components/AccountDrawer/MiniPortfolio/NFTs/index.tsx b/src/components/AccountDrawer/MiniPortfolio/NFTs/index.tsx index beb7c52fae..4833df30ce 100644 --- a/src/components/AccountDrawer/MiniPortfolio/NFTs/index.tsx +++ b/src/components/AccountDrawer/MiniPortfolio/NFTs/index.tsx @@ -3,7 +3,7 @@ import { LoadingAssets } from 'nft/components/collection/CollectionAssetLoading' import { EmptyWalletModule } from 'nft/components/profile/view/EmptyWalletContent' import { useState } from 'react' import InfiniteScroll from 'react-infinite-scroll-component' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { useAccountDrawer } from '../..' import { DEFAULT_NFT_QUERY_AMOUNT } from '../constants' diff --git a/src/components/AccountDrawer/MiniPortfolio/Pools/cache.ts b/src/components/AccountDrawer/MiniPortfolio/Pools/cache.ts index f039c4aeec..fa7bdbf900 100644 --- a/src/components/AccountDrawer/MiniPortfolio/Pools/cache.ts +++ b/src/components/AccountDrawer/MiniPortfolio/Pools/cache.ts @@ -3,7 +3,7 @@ import { Pool, Position } from '@uniswap/v3-sdk' import { useAllTokensMultichain } from 'hooks/Tokens' import { atom, useAtom } from 'jotai' import { atomWithStorage } from 'jotai/utils' -import ms from 'ms.macro' +import ms from 'ms' import { useCallback } from 'react' import { deserializeToken, serializeToken } from 'state/user/hooks' import { SerializedToken } from 'state/user/types' @@ -25,7 +25,7 @@ export type PositionInfo = { prices?: [number?, number?] } -const POSITION_CACHE_EXPIRY = ms`1m` // 1 minute is arbitrary here +const POSITION_CACHE_EXPIRY = ms(`1m`) // 1 minute is arbitrary here // Allows reusing recently fetched positions between component mounts type CachedPositionsEntry = { result: PositionInfo[]; stale: boolean } const cachedPositionsAtom = atom<{ [address: string]: CachedPositionsEntry | undefined }>({}) diff --git a/src/components/AccountDrawer/MiniPortfolio/Pools/index.tsx b/src/components/AccountDrawer/MiniPortfolio/Pools/index.tsx index 93a85ea70a..a7ba5da4f0 100644 --- a/src/components/AccountDrawer/MiniPortfolio/Pools/index.tsx +++ b/src/components/AccountDrawer/MiniPortfolio/Pools/index.tsx @@ -12,7 +12,7 @@ import { useSwitchChain } from 'hooks/useSwitchChain' import { EmptyWalletModule } from 'nft/components/profile/view/EmptyWalletContent' import { useCallback, useMemo, useReducer } from 'react' import { useNavigate } from 'react-router-dom' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ThemedText } from 'theme' import { ExpandoRow } from '../ExpandoRow' diff --git a/src/components/AccountDrawer/MiniPortfolio/PortfolioLogo.tsx b/src/components/AccountDrawer/MiniPortfolio/PortfolioLogo.tsx index a556e0ce7e..b2289a5024 100644 --- a/src/components/AccountDrawer/MiniPortfolio/PortfolioLogo.tsx +++ b/src/components/AccountDrawer/MiniPortfolio/PortfolioLogo.tsx @@ -10,7 +10,7 @@ import useTokenLogoSource from 'hooks/useAssetLogoSource' import useENSAvatar from 'hooks/useENSAvatar' import React from 'react' import { Loader } from 'react-feather' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' const UnknownContract = styled(UnknownStatus)` color: ${({ theme }) => theme.textSecondary}; ` diff --git a/src/components/AccountDrawer/MiniPortfolio/PortfolioRow.tsx b/src/components/AccountDrawer/MiniPortfolio/PortfolioRow.tsx index 15b2787625..ffc2542d49 100644 --- a/src/components/AccountDrawer/MiniPortfolio/PortfolioRow.tsx +++ b/src/components/AccountDrawer/MiniPortfolio/PortfolioRow.tsx @@ -1,7 +1,7 @@ import Column, { AutoColumn } from 'components/Column' import Row from 'components/Row' import { LoadingBubble } from 'components/Tokens/loading' -import styled, { css, keyframes } from 'styled-components/macro' +import styled, { css, keyframes } from 'styled-components' export const PortfolioRowWrapper = styled(Row)<{ onClick?: any }>` gap: 12px; diff --git a/src/components/AccountDrawer/MiniPortfolio/Tokens/index.tsx b/src/components/AccountDrawer/MiniPortfolio/Tokens/index.tsx index 970a6b9089..6b40b02e54 100644 --- a/src/components/AccountDrawer/MiniPortfolio/Tokens/index.tsx +++ b/src/components/AccountDrawer/MiniPortfolio/Tokens/index.tsx @@ -10,7 +10,7 @@ import { useAtomValue } from 'jotai/utils' import { EmptyWalletModule } from 'nft/components/profile/view/EmptyWalletContent' import { useCallback, useMemo, useState } from 'react' import { useNavigate } from 'react-router-dom' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { EllipsisStyle, ThemedText } from 'theme' import { useToggleAccountDrawer } from '../..' diff --git a/src/components/AccountDrawer/MiniPortfolio/index.tsx b/src/components/AccountDrawer/MiniPortfolio/index.tsx index 66e6b9cd7c..a4ffb09697 100644 --- a/src/components/AccountDrawer/MiniPortfolio/index.tsx +++ b/src/components/AccountDrawer/MiniPortfolio/index.tsx @@ -7,7 +7,7 @@ import { AutoRow } from 'components/Row' import { useDisableNFTRoutes } from 'hooks/useDisableNFTRoutes' import { useIsNftPage } from 'hooks/useIsNftPage' import { useEffect, useState } from 'react' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import { BREAKPOINTS, ThemedText } from 'theme' import { ActivityTab } from './Activity' diff --git a/src/components/AccountDrawer/SettingsMenu.tsx b/src/components/AccountDrawer/SettingsMenu.tsx index c001895252..e819739230 100644 --- a/src/components/AccountDrawer/SettingsMenu.tsx +++ b/src/components/AccountDrawer/SettingsMenu.tsx @@ -4,7 +4,7 @@ import { useActiveLocale } from 'hooks/useActiveLocale' import { useLocationLinkProps } from 'hooks/useLocationLinkProps' import { Check } from 'react-feather' import { Link } from 'react-router-dom' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import { ClickableStyle, ThemedText } from 'theme' import ThemeToggle from 'theme/components/ThemeToggle' diff --git a/src/components/AccountDrawer/SettingsToggle.tsx b/src/components/AccountDrawer/SettingsToggle.tsx index d9b842149f..486b5dbc2f 100644 --- a/src/components/AccountDrawer/SettingsToggle.tsx +++ b/src/components/AccountDrawer/SettingsToggle.tsx @@ -1,7 +1,7 @@ import Column from 'components/Column' import Row from 'components/Row' import Toggle from 'components/Toggle' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ThemedText } from 'theme' const StyledColumn = styled(Column)` diff --git a/src/components/AccountDrawer/SlideOutMenu.tsx b/src/components/AccountDrawer/SlideOutMenu.tsx index aa5fb89b1d..9f8701f33f 100644 --- a/src/components/AccountDrawer/SlideOutMenu.tsx +++ b/src/components/AccountDrawer/SlideOutMenu.tsx @@ -1,6 +1,6 @@ import { ScrollBarStyles } from 'components/Common' import { ArrowLeft } from 'react-feather' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ClickableStyle, ThemedText } from 'theme' const Menu = styled.div` diff --git a/src/components/AccountDrawer/UniwalletModal.tsx b/src/components/AccountDrawer/UniwalletModal.tsx index e9d5614659..c54e97d7e6 100644 --- a/src/components/AccountDrawer/UniwalletModal.tsx +++ b/src/components/AccountDrawer/UniwalletModal.tsx @@ -11,7 +11,7 @@ import { ConnectionType } from 'connection/types' import { UniwalletConnect as UniwalletConnectV2 } from 'connection/WalletConnectV2' import { QRCodeSVG } from 'qrcode.react' import { useEffect, useState } from 'react' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import { CloseIcon, ThemedText } from 'theme' import { isIOS } from 'utils/userAgent' diff --git a/src/components/AccountDrawer/index.tsx b/src/components/AccountDrawer/index.tsx index 2d75578340..ff9f0a03d9 100644 --- a/src/components/AccountDrawer/index.tsx +++ b/src/components/AccountDrawer/index.tsx @@ -8,7 +8,7 @@ import { useAtomValue, useUpdateAtom } from 'jotai/utils' import { useCallback, useEffect, useRef, useState } from 'react' import { ChevronsRight } from 'react-feather' import { useGesture } from 'react-use-gesture' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { BREAKPOINTS, ClickableStyle } from 'theme' import { Z_INDEX } from 'theme/zIndex' import { isMobile } from 'utils/userAgent' diff --git a/src/components/AddressInputPanel/index.tsx b/src/components/AddressInputPanel/index.tsx index c1145cebac..70c1a2bfef 100644 --- a/src/components/AddressInputPanel/index.tsx +++ b/src/components/AddressInputPanel/index.tsx @@ -3,7 +3,7 @@ import { Trans } from '@lingui/macro' import { t } from '@lingui/macro' import { useWeb3React } from '@web3-react/core' import { ChangeEvent, ReactNode, useCallback } from 'react' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import { flexColumnNoWrap } from 'theme/styles' import useENS from '../../hooks/useENS' diff --git a/src/components/AirdropModal/index.tsx b/src/components/AirdropModal/index.tsx index 463c973f96..6116e4072b 100644 --- a/src/components/AirdropModal/index.tsx +++ b/src/components/AirdropModal/index.tsx @@ -16,7 +16,7 @@ import { useEffect, useState } from 'react' import { AlertTriangle } from 'react-feather' import { useModalIsOpen, useToggleModal } from 'state/application/hooks' import { ApplicationModal } from 'state/application/reducer' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { CloseIcon, ThemedText } from 'theme' import Modal from '../Modal' diff --git a/src/components/Badge/RangeBadge.tsx b/src/components/Badge/RangeBadge.tsx index 2d485ad39a..c7f9afd027 100644 --- a/src/components/Badge/RangeBadge.tsx +++ b/src/components/Badge/RangeBadge.tsx @@ -1,6 +1,6 @@ import { Trans } from '@lingui/macro' import { AlertTriangle, Slash } from 'react-feather' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import { MouseoverTooltip } from '../../components/Tooltip' diff --git a/src/components/Badge/index.tsx b/src/components/Badge/index.tsx index dd34edfa0d..d38cc3adbf 100644 --- a/src/components/Badge/index.tsx +++ b/src/components/Badge/index.tsx @@ -1,6 +1,6 @@ import { readableColor } from 'polished' import { PropsWithChildren } from 'react' -import styled, { DefaultTheme } from 'styled-components/macro' +import styled, { DefaultTheme } from 'styled-components' export enum BadgeVariant { DEFAULT = 'DEFAULT', diff --git a/src/components/Banner/UniswapWalletBanner.tsx b/src/components/Banner/UniswapWalletBanner.tsx index 41456545f9..d193012bb5 100644 --- a/src/components/Banner/UniswapWalletBanner.tsx +++ b/src/components/Banner/UniswapWalletBanner.tsx @@ -10,7 +10,7 @@ import { useScreenSize } from 'hooks/useScreenSize' import { X } from 'react-feather' import { useLocation } from 'react-router-dom' import { useHideUniswapWalletBanner } from 'state/user/hooks' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ThemedText } from 'theme' import { Z_INDEX } from 'theme/zIndex' import { openDownloadApp, openWalletMicrosite } from 'utils/openDownloadApp' diff --git a/src/components/Button/index.tsx b/src/components/Button/index.tsx index 2b03238a0d..2790074985 100644 --- a/src/components/Button/index.tsx +++ b/src/components/Button/index.tsx @@ -2,7 +2,7 @@ import { darken } from 'polished' import { forwardRef } from 'react' import { Check, ChevronDown } from 'react-feather' import { Button as RebassButton, ButtonProps as ButtonPropsOriginal } from 'rebass/styled-components' -import styled, { DefaultTheme, useTheme } from 'styled-components/macro' +import styled, { DefaultTheme, useTheme } from 'styled-components' import { RowBetween } from '../Row' diff --git a/src/components/Card/index.tsx b/src/components/Card/index.tsx index 780fc57c2e..3b5004c982 100644 --- a/src/components/Card/index.tsx +++ b/src/components/Card/index.tsx @@ -1,5 +1,5 @@ import { Box } from 'rebass/styled-components' -import styled from 'styled-components/macro' +import styled from 'styled-components' const Card = styled(Box)<{ width?: string; padding?: string; border?: string; $borderRadius?: string }>` width: ${({ width }) => width ?? '100%'}; diff --git a/src/components/Charts/AnimatedInLineChart.tsx b/src/components/Charts/AnimatedInLineChart.tsx index 81400ab3d1..68d13fd8a2 100644 --- a/src/components/Charts/AnimatedInLineChart.tsx +++ b/src/components/Charts/AnimatedInLineChart.tsx @@ -1,18 +1,18 @@ import { Group } from '@visx/group' import { LinePath } from '@visx/shape' import { easeSinOut } from 'd3' -import ms from 'ms.macro' +import ms from 'ms' import React from 'react' import { useEffect, useRef, useState } from 'react' import { animated, useSpring } from 'react-spring' -import { useTheme } from 'styled-components/macro' +import { useTheme } from 'styled-components' import { LineChartProps } from './LineChart' type AnimatedInLineChartProps = Omit, 'height' | 'width' | 'children'> const config = { - duration: ms`0.8s`, + duration: ms(`0.8s`), easing: easeSinOut, } diff --git a/src/components/Charts/FadeInLineChart.tsx b/src/components/Charts/FadeInLineChart.tsx index 7652041fdd..7057fd3989 100644 --- a/src/components/Charts/FadeInLineChart.tsx +++ b/src/components/Charts/FadeInLineChart.tsx @@ -4,7 +4,7 @@ import { easeCubicInOut } from 'd3' import React from 'react' import { useEffect, useRef, useState } from 'react' import { animated, useSpring } from 'react-spring' -import { useTheme } from 'styled-components/macro' +import { useTheme } from 'styled-components' import { LineChartProps } from './LineChart' diff --git a/src/components/Charts/LineChart.tsx b/src/components/Charts/LineChart.tsx index 656c3b39e3..bf5ce8a7d8 100644 --- a/src/components/Charts/LineChart.tsx +++ b/src/components/Charts/LineChart.tsx @@ -3,7 +3,7 @@ import { LinePath } from '@visx/shape' import { CurveFactory } from 'd3' import React from 'react' import { ReactNode } from 'react' -import { useTheme } from 'styled-components/macro' +import { useTheme } from 'styled-components' export interface LineChartProps { data: T[] diff --git a/src/components/Charts/SparklineChart.tsx b/src/components/Charts/SparklineChart.tsx index 54694754b6..47714678f9 100644 --- a/src/components/Charts/SparklineChart.tsx +++ b/src/components/Charts/SparklineChart.tsx @@ -3,7 +3,7 @@ import { curveCardinal, scaleLinear } from 'd3' import { SparklineMap, TopToken } from 'graphql/data/TopTokens' import { PricePoint } from 'graphql/data/util' import { memo } from 'react' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import { getPriceBounds } from '../Tokens/TokenDetails/PriceChart' import LineChart from './LineChart' diff --git a/src/components/Column/index.tsx b/src/components/Column/index.tsx index 0de838bc3e..f2fb29de81 100644 --- a/src/components/Column/index.tsx +++ b/src/components/Column/index.tsx @@ -1,4 +1,4 @@ -import styled from 'styled-components/macro' +import styled from 'styled-components' import { Gap } from 'theme' export const Column = styled.div<{ diff --git a/src/components/Common/index.tsx b/src/components/Common/index.tsx index a4747240ef..aa67d14d7c 100644 --- a/src/components/Common/index.tsx +++ b/src/components/Common/index.tsx @@ -1,4 +1,4 @@ -import { css } from 'styled-components/macro' +import { css } from 'styled-components' export const ScrollBarStyles = css<{ $isHorizontalScroll?: boolean }>` // Firefox scrollbar styling diff --git a/src/components/ConnectedAccountBlocked/index.tsx b/src/components/ConnectedAccountBlocked/index.tsx index 60376a01c8..2ece51cf06 100644 --- a/src/components/ConnectedAccountBlocked/index.tsx +++ b/src/components/ConnectedAccountBlocked/index.tsx @@ -1,7 +1,7 @@ import { Trans } from '@lingui/macro' import Column from 'components/Column' import { BlockedIcon } from 'components/TokenSafety/TokenSafetyIcon' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import { ExternalLink, ThemedText } from 'theme' import { CopyHelper } from '../../theme' diff --git a/src/components/CurrencyInputPanel/FiatValue.tsx b/src/components/CurrencyInputPanel/FiatValue.tsx index 27bffd6c3b..3671ee4164 100644 --- a/src/components/CurrencyInputPanel/FiatValue.tsx +++ b/src/components/CurrencyInputPanel/FiatValue.tsx @@ -5,7 +5,7 @@ import Row from 'components/Row' import { LoadingBubble } from 'components/Tokens/loading' import { MouseoverTooltip } from 'components/Tooltip' import { useMemo } from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ThemedText } from 'theme' import { warningSeverity } from 'utils/prices' diff --git a/src/components/CurrencyInputPanel/SwapCurrencyInputPanel.tsx b/src/components/CurrencyInputPanel/SwapCurrencyInputPanel.tsx index 531c6c8c9e..f66a00cdef 100644 --- a/src/components/CurrencyInputPanel/SwapCurrencyInputPanel.tsx +++ b/src/components/CurrencyInputPanel/SwapCurrencyInputPanel.tsx @@ -13,7 +13,7 @@ import { isSupportedChain } from 'constants/chains' import { darken } from 'polished' import { ReactNode, useCallback, useState } from 'react' import { Lock } from 'react-feather' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import { flexColumnNoWrap, flexRowNoWrap } from 'theme/styles' import { ReactComponent as DropDown } from '../../assets/images/dropdown.svg' diff --git a/src/components/CurrencyInputPanel/index.tsx b/src/components/CurrencyInputPanel/index.tsx index 91904adf5c..0b606caeab 100644 --- a/src/components/CurrencyInputPanel/index.tsx +++ b/src/components/CurrencyInputPanel/index.tsx @@ -8,7 +8,7 @@ import { LoadingOpacityContainer, loadingOpacityMixin } from 'components/Loader/ import { isSupportedChain } from 'constants/chains' import { darken } from 'polished' import { ReactNode, useCallback, useState } from 'react' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import { flexColumnNoWrap, flexRowNoWrap } from 'theme/styles' import { formatCurrencyAmount } from 'utils/formatCurrencyAmount' diff --git a/src/components/DoubleLogo/index.tsx b/src/components/DoubleLogo/index.tsx index 4eb79373f1..73a8ca7cee 100644 --- a/src/components/DoubleLogo/index.tsx +++ b/src/components/DoubleLogo/index.tsx @@ -1,5 +1,5 @@ import { Currency } from '@uniswap/sdk-core' -import styled from 'styled-components/macro' +import styled from 'styled-components' import CurrencyLogo from '../Logo/CurrencyLogo' diff --git a/src/components/ErrorBoundary/index.tsx b/src/components/ErrorBoundary/index.tsx index 537877a1b4..3a4aa872d6 100644 --- a/src/components/ErrorBoundary/index.tsx +++ b/src/components/ErrorBoundary/index.tsx @@ -6,7 +6,7 @@ import { ChevronUpIcon } from 'nft/components/icons' import { useIsMobile } from 'nft/hooks' import React, { PropsWithChildren, useState } from 'react' import { Copy } from 'react-feather' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { isSentryEnabled } from 'utils/env' import { CopyToClipboard, ExternalLink, ThemedText } from '../../theme' diff --git a/src/components/Expand/index.tsx b/src/components/Expand/index.tsx index 6fa41735ed..4e6280b642 100644 --- a/src/components/Expand/index.tsx +++ b/src/components/Expand/index.tsx @@ -2,7 +2,7 @@ import AnimatedDropdown from 'components/AnimatedDropdown' import Column from 'components/Column' import React, { PropsWithChildren, ReactElement } from 'react' import { ChevronDown } from 'react-feather' -import styled from 'styled-components/macro' +import styled from 'styled-components' import Row, { RowBetween } from '../Row' diff --git a/src/components/FeatureFlagModal/FeatureFlagModal.tsx b/src/components/FeatureFlagModal/FeatureFlagModal.tsx index 7aeecc1e54..62bfbeb51d 100644 --- a/src/components/FeatureFlagModal/FeatureFlagModal.tsx +++ b/src/components/FeatureFlagModal/FeatureFlagModal.tsx @@ -11,7 +11,7 @@ import { Children, PropsWithChildren, ReactElement, ReactNode, useCallback, useS import { X } from 'react-feather' import { useModalIsOpen, useToggleFeatureFlags } from 'state/application/hooks' import { ApplicationModal } from 'state/application/reducer' -import styled from 'styled-components/macro' +import styled from 'styled-components' const StyledModal = styled.div` position: fixed; diff --git a/src/components/FeeSelector/FeeOption.tsx b/src/components/FeeSelector/FeeOption.tsx index ab9d562861..e4651b315b 100644 --- a/src/components/FeeSelector/FeeOption.tsx +++ b/src/components/FeeSelector/FeeOption.tsx @@ -5,7 +5,7 @@ import { AutoColumn } from 'components/Column' import { useFeeTierDistribution } from 'hooks/useFeeTierDistribution' import { PoolState } from 'hooks/usePools' import React from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ThemedText } from 'theme' import { FeeTierPercentageBadge } from './FeeTierPercentageBadge' diff --git a/src/components/FeeSelector/index.tsx b/src/components/FeeSelector/index.tsx index 2cfa86b0e0..63e4bf0d61 100644 --- a/src/components/FeeSelector/index.tsx +++ b/src/components/FeeSelector/index.tsx @@ -13,7 +13,7 @@ import usePrevious from 'hooks/usePrevious' import { DynamicSection } from 'pages/AddLiquidity/styled' import { useCallback, useEffect, useMemo, useRef, useState } from 'react' import { Box } from 'rebass' -import styled, { keyframes } from 'styled-components/macro' +import styled, { keyframes } from 'styled-components' import { ThemedText } from 'theme' import { FeeOption } from './FeeOption' diff --git a/src/components/FiatOnrampModal/index.tsx b/src/components/FiatOnrampModal/index.tsx index fe7730c357..73081fc7b5 100644 --- a/src/components/FiatOnrampModal/index.tsx +++ b/src/components/FiatOnrampModal/index.tsx @@ -4,7 +4,7 @@ import { useCallback, useEffect, useState } from 'react' import { useHref } from 'react-router-dom' import { useCloseModal, useModalIsOpen } from 'state/application/hooks' import { ApplicationModal } from 'state/application/reducer' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import { CustomLightSpinner, ThemedText } from 'theme' import { useIsDarkMode } from 'theme/components/ThemeToggle' diff --git a/src/components/HoverInlineText/index.tsx b/src/components/HoverInlineText/index.tsx index b5a63bcf15..68c28ce37b 100644 --- a/src/components/HoverInlineText/index.tsx +++ b/src/components/HoverInlineText/index.tsx @@ -1,6 +1,6 @@ import Tooltip from 'components/Tooltip' import { useState } from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' const TextWrapper = styled.span<{ margin: boolean diff --git a/src/components/Icons/AlertTriangleFilled.tsx b/src/components/Icons/AlertTriangleFilled.tsx index a3f2991a81..5e5744f341 100644 --- a/src/components/Icons/AlertTriangleFilled.tsx +++ b/src/components/Icons/AlertTriangleFilled.tsx @@ -1,4 +1,4 @@ -import { useTheme } from 'styled-components/macro' +import { useTheme } from 'styled-components' import { StyledSVG } from './shared' diff --git a/src/components/Icons/LoadingSpinner.tsx b/src/components/Icons/LoadingSpinner.tsx index 2f4103e869..f3beca9781 100644 --- a/src/components/Icons/LoadingSpinner.tsx +++ b/src/components/Icons/LoadingSpinner.tsx @@ -1,4 +1,4 @@ -import { useTheme } from 'styled-components/macro' +import { useTheme } from 'styled-components' import { StyledRotatingSVG, StyledSVG } from './shared' diff --git a/src/components/Icons/shared.tsx b/src/components/Icons/shared.tsx index ebaa490da9..3586dd7974 100644 --- a/src/components/Icons/shared.tsx +++ b/src/components/Icons/shared.tsx @@ -1,4 +1,4 @@ -import styled, { css, keyframes } from 'styled-components/macro' +import styled, { css, keyframes } from 'styled-components' const rotateAnimation = keyframes` from { diff --git a/src/components/Identicon/StatusIcon.tsx b/src/components/Identicon/StatusIcon.tsx index 06de0397e9..51efe43fe8 100644 --- a/src/components/Identicon/StatusIcon.tsx +++ b/src/components/Identicon/StatusIcon.tsx @@ -1,7 +1,7 @@ import { Unicon } from 'components/Unicon' import { Connection, ConnectionType } from 'connection/types' import useENSAvatar from 'hooks/useENSAvatar' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { useIsDarkMode } from 'theme/components/ThemeToggle' import { flexColumnNoWrap } from 'theme/styles' diff --git a/src/components/Identicon/index.tsx b/src/components/Identicon/index.tsx index bb735c0e70..eff4cfd45a 100644 --- a/src/components/Identicon/index.tsx +++ b/src/components/Identicon/index.tsx @@ -1,7 +1,7 @@ import jazzicon from '@metamask/jazzicon' import useENSAvatar from 'hooks/useENSAvatar' import { useCallback, useLayoutEffect, useMemo, useRef, useState } from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' const StyledIdenticon = styled.div<{ iconSize: number }>` height: ${({ iconSize }) => `${iconSize}px`}; diff --git a/src/components/InputStepCounter/InputStepCounter.tsx b/src/components/InputStepCounter/InputStepCounter.tsx index 15a4fda1a3..f46eab2654 100644 --- a/src/components/InputStepCounter/InputStepCounter.tsx +++ b/src/components/InputStepCounter/InputStepCounter.tsx @@ -5,7 +5,7 @@ import { OutlineCard } from 'components/Card' import { AutoColumn } from 'components/Column' import { ReactNode, useCallback, useEffect, useState } from 'react' import { Minus, Plus } from 'react-feather' -import styled, { keyframes } from 'styled-components/macro' +import styled, { keyframes } from 'styled-components' import { ThemedText } from 'theme' import { Input as NumericalInput } from '../NumericalInput' diff --git a/src/components/LiquidityChartRangeInput/Area.tsx b/src/components/LiquidityChartRangeInput/Area.tsx index 316e3d9353..18d672d55c 100644 --- a/src/components/LiquidityChartRangeInput/Area.tsx +++ b/src/components/LiquidityChartRangeInput/Area.tsx @@ -1,6 +1,6 @@ import { area, curveStepAfter, ScaleLinear } from 'd3' import React, { useMemo } from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ChartEntry } from './types' diff --git a/src/components/LiquidityChartRangeInput/AxisBottom.tsx b/src/components/LiquidityChartRangeInput/AxisBottom.tsx index e0fbee6a41..e7ad38594a 100644 --- a/src/components/LiquidityChartRangeInput/AxisBottom.tsx +++ b/src/components/LiquidityChartRangeInput/AxisBottom.tsx @@ -1,6 +1,6 @@ import { Axis as d3Axis, axisBottom, NumberValue, ScaleLinear, select } from 'd3' import React, { useMemo } from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' const StyledGroup = styled.g` line { diff --git a/src/components/LiquidityChartRangeInput/Brush.tsx b/src/components/LiquidityChartRangeInput/Brush.tsx index a9aa24ab80..eb6e460301 100644 --- a/src/components/LiquidityChartRangeInput/Brush.tsx +++ b/src/components/LiquidityChartRangeInput/Brush.tsx @@ -2,7 +2,7 @@ import { brushHandleAccentPath, brushHandlePath, OffScreenHandle } from 'compone import { BrushBehavior, brushX, D3BrushEvent, ScaleLinear, select } from 'd3' import usePrevious from 'hooks/usePrevious' import React, { useCallback, useEffect, useMemo, useRef, useState } from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' const Handle = styled.path<{ color: string }>` cursor: ew-resize; diff --git a/src/components/LiquidityChartRangeInput/Line.tsx b/src/components/LiquidityChartRangeInput/Line.tsx index d25a260e78..5d00d7ddbc 100644 --- a/src/components/LiquidityChartRangeInput/Line.tsx +++ b/src/components/LiquidityChartRangeInput/Line.tsx @@ -1,6 +1,6 @@ import { ScaleLinear } from 'd3' import React, { useMemo } from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' const StyledLine = styled.line` opacity: 0.5; diff --git a/src/components/LiquidityChartRangeInput/Zoom.tsx b/src/components/LiquidityChartRangeInput/Zoom.tsx index d8cc6f8cd4..8defdcbbad 100644 --- a/src/components/LiquidityChartRangeInput/Zoom.tsx +++ b/src/components/LiquidityChartRangeInput/Zoom.tsx @@ -2,7 +2,7 @@ import { ButtonGray } from 'components/Button' import { ScaleLinear, select, zoom, ZoomBehavior, zoomIdentity, ZoomTransform } from 'd3' import React, { useEffect, useMemo, useRef } from 'react' import { RefreshCcw, ZoomIn, ZoomOut } from 'react-feather' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ZoomLevels } from './types' diff --git a/src/components/LiquidityChartRangeInput/index.tsx b/src/components/LiquidityChartRangeInput/index.tsx index beeba91eb7..83f811c948 100644 --- a/src/components/LiquidityChartRangeInput/index.tsx +++ b/src/components/LiquidityChartRangeInput/index.tsx @@ -10,7 +10,7 @@ import { ReactNode, useCallback, useMemo } from 'react' import { BarChart2, CloudOff, Inbox } from 'react-feather' import { batch } from 'react-redux' import { Bound } from 'state/mint/v3/actions' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import { ThemedText } from '../../theme' import { Chart } from './Chart' diff --git a/src/components/Loader/styled.tsx b/src/components/Loader/styled.tsx index 6236b7d2e6..baacf7c059 100644 --- a/src/components/Loader/styled.tsx +++ b/src/components/Loader/styled.tsx @@ -1,4 +1,4 @@ -import styled, { css, keyframes } from 'styled-components/macro' +import styled, { css, keyframes } from 'styled-components' export const loadingAnimation = keyframes` 0% { diff --git a/src/components/Logo/AssetLogo.tsx b/src/components/Logo/AssetLogo.tsx index 8fd1750cda..c9c5cb03a0 100644 --- a/src/components/Logo/AssetLogo.tsx +++ b/src/components/Logo/AssetLogo.tsx @@ -2,7 +2,7 @@ import { ChainId } from '@uniswap/sdk-core' import { getChainInfo } from 'constants/chainInfo' import useTokenLogoSource from 'hooks/useAssetLogoSource' import React, { useState } from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' export const MissingImageLogo = styled.div<{ size?: string }>` --size: ${({ size }) => size}; diff --git a/src/components/Menu/index.tsx b/src/components/Menu/index.tsx index ae01843385..cabe20a69c 100644 --- a/src/components/Menu/index.tsx +++ b/src/components/Menu/index.tsx @@ -1,6 +1,6 @@ import { FunctionComponent, PropsWithChildren, useRef } from 'react' import { Link } from 'react-router-dom' -import styled, { css } from 'styled-components/macro' +import styled, { css } from 'styled-components' import { ReactComponent as MenuIcon } from '../../assets/images/menu.svg' import { useOnClickOutside } from '../../hooks/useOnClickOutside' diff --git a/src/components/Modal/index.tsx b/src/components/Modal/index.tsx index 8aa20417c7..5cc6cbc4ca 100644 --- a/src/components/Modal/index.tsx +++ b/src/components/Modal/index.tsx @@ -2,7 +2,7 @@ import { DialogContent, DialogOverlay } from '@reach/dialog' import React from 'react' import { animated, useSpring, useTransition } from 'react-spring' import { useGesture } from 'react-use-gesture' -import styled, { css } from 'styled-components/macro' +import styled, { css } from 'styled-components' import { Z_INDEX } from 'theme/zIndex' import { isMobile } from '../../utils/userAgent' diff --git a/src/components/ModalViews/index.tsx b/src/components/ModalViews/index.tsx index 75977d3b27..92ee468395 100644 --- a/src/components/ModalViews/index.tsx +++ b/src/components/ModalViews/index.tsx @@ -1,7 +1,7 @@ import { Trans } from '@lingui/macro' import { useWeb3React } from '@web3-react/core' import { ArrowUpCircle } from 'react-feather' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import Circle from '../../assets/images/blue-loader.svg' import { CloseIcon, CustomLightSpinner, ThemedText } from '../../theme' diff --git a/src/components/NavBar/Bag.tsx b/src/components/NavBar/Bag.tsx index d751a707e6..73377537fe 100644 --- a/src/components/NavBar/Bag.tsx +++ b/src/components/NavBar/Bag.tsx @@ -3,7 +3,7 @@ import { useIsNftProfilePage } from 'hooks/useIsNftPage' import { BagIcon, HundredsOverflowIcon, TagIcon } from 'nft/components/icons' import { useBag, useSellAsset } from 'nft/hooks' import { useCallback } from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { shallow } from 'zustand/shallow' const CounterDot = styled.div` diff --git a/src/components/NavBar/Blur.tsx b/src/components/NavBar/Blur.tsx index e9f5472a4e..dce0452a77 100644 --- a/src/components/NavBar/Blur.tsx +++ b/src/components/NavBar/Blur.tsx @@ -1,4 +1,4 @@ -import styled from 'styled-components/macro' +import styled from 'styled-components' const MAX_STRENGTH = 5 const BLUR_STEPS = 20 diff --git a/src/components/NavBar/ChainSelector.tsx b/src/components/NavBar/ChainSelector.tsx index 8b6e182962..84a6a44c9c 100644 --- a/src/components/NavBar/ChainSelector.tsx +++ b/src/components/NavBar/ChainSelector.tsx @@ -25,7 +25,7 @@ import { Column, Row } from 'nft/components/Flex' import { useIsMobile } from 'nft/hooks' import { useCallback, useMemo, useRef, useState } from 'react' import { AlertTriangle, ChevronDown, ChevronUp } from 'react-feather' -import { useTheme } from 'styled-components/macro' +import { useTheme } from 'styled-components' import { getSupportedChainIdsFromWalletConnectSession } from 'utils/getSupportedChainIdsFromWalletConnectSession' import * as styles from './ChainSelector.css' diff --git a/src/components/NavBar/ChainSelectorRow.tsx b/src/components/NavBar/ChainSelectorRow.tsx index 6c9c2a9d72..c3ab2d9e3f 100644 --- a/src/components/NavBar/ChainSelectorRow.tsx +++ b/src/components/NavBar/ChainSelectorRow.tsx @@ -5,7 +5,7 @@ import Loader from 'components/Icons/LoadingSpinner' import { getChainInfo } from 'constants/chainInfo' import { useBaseEnabledChains } from 'featureFlags/flags/baseEnabled' import { CheckMarkIcon } from 'nft/components/icons' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' const LOGO_SIZE = 20 diff --git a/src/components/NavBar/MenuDropdown.tsx b/src/components/NavBar/MenuDropdown.tsx index 17d7f8d068..65e5c69608 100644 --- a/src/components/NavBar/MenuDropdown.tsx +++ b/src/components/NavBar/MenuDropdown.tsx @@ -19,7 +19,7 @@ import { themeVars } from 'nft/css/sprinkles.css' import { ReactNode, useReducer, useRef } from 'react' import { NavLink, NavLinkProps } from 'react-router-dom' import { useToggleModal } from 'state/application/hooks' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import { isDevelopmentEnv, isStagingEnv } from 'utils/env' import { openDownloadApp } from 'utils/openDownloadApp' diff --git a/src/components/NavBar/SearchBar.tsx b/src/components/NavBar/SearchBar.tsx index 0229140559..a413ffc2f0 100644 --- a/src/components/NavBar/SearchBar.tsx +++ b/src/components/NavBar/SearchBar.tsx @@ -1,5 +1,6 @@ // eslint-disable-next-line no-restricted-imports import { t } from '@lingui/macro' +import { useLingui } from '@lingui/react' import { BrowserEvent, InterfaceElementName, InterfaceEventName, InterfaceSectionName } from '@uniswap/analytics-events' import { useWeb3React } from '@web3-react/core' import { sendAnalyticsEvent, Trace, TraceEvent, useTrace } from 'analytics' @@ -16,9 +17,9 @@ import { Column, Row } from 'nft/components/Flex' import { magicalGradientOnHover } from 'nft/css/common.css' import { useIsMobile, useIsTablet } from 'nft/hooks' import { useIsNavSearchInputVisible } from 'nft/hooks/useIsNavSearchInputVisible' -import { ChangeEvent, useCallback, useEffect, useMemo, useReducer, useRef, useState } from 'react' +import { ChangeEvent, useCallback, useEffect, useReducer, useRef, useState } from 'react' import { useLocation } from 'react-router-dom' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ChevronLeftIcon, MagnifyingGlassIcon, NavMagnifyingGlassIcon } from '../../nft/components/icons' import { NavIcon } from './NavIcon' @@ -103,17 +104,13 @@ export const SearchBar = () => { hasInput: debouncedSearchValue && debouncedSearchValue.length > 0, ...trace, } - const placeholderText = useMemo(() => { - if (isMobileOrTablet) { - return t`Search` - } else { - if (shouldDisableNFTRoutes) { - return t`Search tokens` - } else { - return t`Search tokens and NFT collections` - } - } - }, [isMobileOrTablet, shouldDisableNFTRoutes]) + + const { i18n } = useLingui() // subscribe to locale changes + const placeholderText = isMobileOrTablet + ? t(i18n)`Search` + : shouldDisableNFTRoutes + ? t(i18n)`Search tokens` + : t(i18n)`Search tokens and NFT collections` const handleKeyPress = useCallback( (event: any) => { diff --git a/src/components/NavBar/SearchBarDropdown.tsx b/src/components/NavBar/SearchBarDropdown.tsx index 82c8e0472b..3d3614a00b 100644 --- a/src/components/NavBar/SearchBarDropdown.tsx +++ b/src/components/NavBar/SearchBarDropdown.tsx @@ -19,7 +19,7 @@ import { subheadSmall } from 'nft/css/common.css' import { GenieCollection, TrendingCollection } from 'nft/types' import { useEffect, useMemo, useState } from 'react' import { useLocation } from 'react-router-dom' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ThemedText } from 'theme' import { ClockIcon, TrendingArrow } from '../../nft/components/icons' diff --git a/src/components/NavBar/SuggestionRow.tsx b/src/components/NavBar/SuggestionRow.tsx index 4655f11a6f..c3a188038a 100644 --- a/src/components/NavBar/SuggestionRow.tsx +++ b/src/components/NavBar/SuggestionRow.tsx @@ -17,7 +17,7 @@ import { ethNumberStandardFormatter } from 'nft/utils/currency' import { putCommas } from 'nft/utils/putCommas' import { useCallback, useEffect, useState } from 'react' import { Link, useNavigate } from 'react-router-dom' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ThemedText } from 'theme' import { DeltaText, getDeltaArrow } from '../Tokens/TokenDetails/PriceChart' diff --git a/src/components/NavBar/index.tsx b/src/components/NavBar/index.tsx index ab2f21536f..b9cd833486 100644 --- a/src/components/NavBar/index.tsx +++ b/src/components/NavBar/index.tsx @@ -13,7 +13,7 @@ import { useProfilePageState } from 'nft/hooks' import { ProfilePageStateType } from 'nft/types' import { ReactNode, useCallback } from 'react' import { NavLink, NavLinkProps, useLocation, useNavigate } from 'react-router-dom' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { useIsNavSearchInputVisible } from '../../nft/hooks/useIsNavSearchInputVisible' import { Bag } from './Bag' diff --git a/src/components/NavigationTabs/index.tsx b/src/components/NavigationTabs/index.tsx index 80a4802291..b6ee911114 100644 --- a/src/components/NavigationTabs/index.tsx +++ b/src/components/NavigationTabs/index.tsx @@ -8,7 +8,7 @@ import { Box } from 'rebass' import { useAppDispatch } from 'state/hooks' import { resetMintState } from 'state/mint/actions' import { resetMintState as resetMintV3State } from 'state/mint/v3/actions' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import { ThemedText } from 'theme' import { flexRowNoWrap } from 'theme/styles' diff --git a/src/components/NetworkAlert/NetworkAlert.tsx b/src/components/NetworkAlert/NetworkAlert.tsx index d5eab38a49..e84c3a37d8 100644 --- a/src/components/NetworkAlert/NetworkAlert.tsx +++ b/src/components/NetworkAlert/NetworkAlert.tsx @@ -4,7 +4,7 @@ import { useWeb3React } from '@web3-react/core' import { getChainInfo } from 'constants/chainInfo' import { useBaseEnabledChains } from 'featureFlags/flags/baseEnabled' import { ArrowUpRight } from 'react-feather' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ExternalLink, HideSmall } from 'theme' import { colors } from 'theme/colors' import { useDarkModeManager } from 'theme/components/ThemeToggle' diff --git a/src/components/NumericalInput/index.tsx b/src/components/NumericalInput/index.tsx index bee3078f26..0bcb2450b6 100644 --- a/src/components/NumericalInput/index.tsx +++ b/src/components/NumericalInput/index.tsx @@ -1,5 +1,5 @@ import React from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { escapeRegExp } from 'utils' const StyledInput = styled.input<{ error?: boolean; fontSize?: string; align?: string }>` diff --git a/src/components/Polling/ChainConnectivityWarning.tsx b/src/components/Polling/ChainConnectivityWarning.tsx index fce27e4958..07db216598 100644 --- a/src/components/Polling/ChainConnectivityWarning.tsx +++ b/src/components/Polling/ChainConnectivityWarning.tsx @@ -3,7 +3,7 @@ import { ChainId } from '@uniswap/sdk-core' import { useWeb3React } from '@web3-react/core' import { getChainInfoOrDefault, L2ChainInfo } from 'constants/chainInfo' import { AlertTriangle } from 'react-feather' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ExternalLink, MEDIA_WIDTHS } from 'theme' const BodyRow = styled.div` diff --git a/src/components/Polling/index.tsx b/src/components/Polling/index.tsx index 9a0818f9aa..01093b220e 100644 --- a/src/components/Polling/index.tsx +++ b/src/components/Polling/index.tsx @@ -7,9 +7,9 @@ import { useIsLandingPage } from 'hooks/useIsLandingPage' import { useIsNftPage } from 'hooks/useIsNftPage' import useMachineTimeMs from 'hooks/useMachineTime' import useBlockNumber from 'lib/hooks/useBlockNumber' -import ms from 'ms.macro' +import ms from 'ms' import { useEffect, useMemo, useState } from 'react' -import styled, { keyframes } from 'styled-components/macro' +import styled, { keyframes } from 'styled-components' import { ExternalLink, ThemedText } from 'theme' import { ExplorerDataType, getExplorerLink } from 'utils/getExplorerLink' @@ -97,8 +97,8 @@ const Spinner = styled.div<{ warning: boolean }>` top: -3px; ` -const DEFAULT_MS_BEFORE_WARNING = ms`10m` -const NETWORK_HEALTH_CHECK_MS = ms`10s` +const DEFAULT_MS_BEFORE_WARNING = ms(`10m`) +const NETWORK_HEALTH_CHECK_MS = ms(`10s`) export default function Polling() { const { chainId } = useWeb3React() diff --git a/src/components/Popover/index.tsx b/src/components/Popover/index.tsx index 272bacb207..9e5e6ea290 100644 --- a/src/components/Popover/index.tsx +++ b/src/components/Popover/index.tsx @@ -3,7 +3,7 @@ import Portal from '@reach/portal' import useInterval from 'lib/hooks/useInterval' import React, { CSSProperties, useCallback, useMemo, useState } from 'react' import { usePopper } from 'react-popper' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { Z_INDEX } from 'theme/zIndex' const PopoverContainer = styled.div<{ show: boolean }>` diff --git a/src/components/Popups/ClaimPopup.tsx b/src/components/Popups/ClaimPopup.tsx index 5872b8adad..a12c69f43d 100644 --- a/src/components/Popups/ClaimPopup.tsx +++ b/src/components/Popups/ClaimPopup.tsx @@ -4,7 +4,7 @@ import { useWeb3React } from '@web3-react/core' import { sendEvent } from 'components/analytics' import { useCallback, useEffect } from 'react' import { Heart, X } from 'react-feather' -import styled, { keyframes } from 'styled-components/macro' +import styled, { keyframes } from 'styled-components' import tokenLogo from '../../assets/images/token-logo.png' import { diff --git a/src/components/Popups/PopupContent.tsx b/src/components/Popups/PopupContent.tsx index e344f7fb1e..54993646ac 100644 --- a/src/components/Popups/PopupContent.tsx +++ b/src/components/Popups/PopupContent.tsx @@ -15,7 +15,7 @@ import useENSName from 'hooks/useENSName' import { X } from 'react-feather' import { useOrder } from 'state/signatures/hooks' import { useTransaction } from 'state/transactions/hooks' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { EllipsisStyle, ThemedText } from 'theme' import { ExplorerDataType, getExplorerLink } from 'utils/getExplorerLink' diff --git a/src/components/Popups/index.tsx b/src/components/Popups/index.tsx index 4c96296901..0b673c14bb 100644 --- a/src/components/Popups/index.tsx +++ b/src/components/Popups/index.tsx @@ -1,6 +1,6 @@ import { ChainId } from '@uniswap/sdk-core' import { useWeb3React } from '@web3-react/core' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { MEDIA_WIDTHS } from 'theme' import { useActivePopups } from '../../state/application/hooks' diff --git a/src/components/PositionCard/Sushi.tsx b/src/components/PositionCard/Sushi.tsx index f3b188fc58..021ebcfc05 100644 --- a/src/components/PositionCard/Sushi.tsx +++ b/src/components/PositionCard/Sushi.tsx @@ -4,7 +4,7 @@ import Badge, { BadgeVariant } from 'components/Badge' import { transparentize } from 'polished' import { Link } from 'react-router-dom' import { Text } from 'rebass' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { useColor } from '../../hooks/useColor' import { unwrappedToken } from '../../utils/unwrappedToken' diff --git a/src/components/PositionCard/V2.tsx b/src/components/PositionCard/V2.tsx index e5e6e0fdef..fcb278aeb8 100644 --- a/src/components/PositionCard/V2.tsx +++ b/src/components/PositionCard/V2.tsx @@ -8,7 +8,7 @@ import { useState } from 'react' import { ChevronDown, ChevronUp } from 'react-feather' import { Link } from 'react-router-dom' import { Text } from 'rebass' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { BIG_INT_ZERO } from '../../constants/misc' import { useColor } from '../../hooks/useColor' diff --git a/src/components/PositionCard/index.tsx b/src/components/PositionCard/index.tsx index 70aa4e892e..9fed313e59 100644 --- a/src/components/PositionCard/index.tsx +++ b/src/components/PositionCard/index.tsx @@ -8,7 +8,7 @@ import { useState } from 'react' import { ChevronDown, ChevronUp } from 'react-feather' import { Link } from 'react-router-dom' import { Text } from 'rebass' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { BIG_INT_ZERO } from '../../constants/misc' import { useColor } from '../../hooks/useColor' diff --git a/src/components/PositionList/index.tsx b/src/components/PositionList/index.tsx index 3149052e90..f3ca25306c 100644 --- a/src/components/PositionList/index.tsx +++ b/src/components/PositionList/index.tsx @@ -1,7 +1,7 @@ import { Trans } from '@lingui/macro' import PositionListItem from 'components/PositionListItem' import React from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { MEDIA_WIDTHS } from 'theme' import { PositionDetails } from 'types/position' diff --git a/src/components/PositionListItem/index.tsx b/src/components/PositionListItem/index.tsx index 385e0d8930..b80479a2f5 100644 --- a/src/components/PositionListItem/index.tsx +++ b/src/components/PositionListItem/index.tsx @@ -13,7 +13,7 @@ import { usePool } from 'hooks/usePools' import { useMemo } from 'react' import { Link } from 'react-router-dom' import { Bound } from 'state/mint/v3/actions' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { HideSmall, MEDIA_WIDTHS, SmallOnly, ThemedText } from 'theme' import { formatTickPrice } from 'utils/formatTickPrice' import { unwrappedToken } from 'utils/unwrappedToken' diff --git a/src/components/PositionPreview/index.tsx b/src/components/PositionPreview/index.tsx index abbde8ffd8..d1561fc4ff 100644 --- a/src/components/PositionPreview/index.tsx +++ b/src/components/PositionPreview/index.tsx @@ -12,7 +12,7 @@ import { RowBetween, RowFixed } from 'components/Row' import JSBI from 'jsbi' import { ReactNode, useCallback, useState } from 'react' import { Bound } from 'state/mint/v3/actions' -import { useTheme } from 'styled-components/macro' +import { useTheme } from 'styled-components' import { ThemedText } from 'theme' import { formatTickPrice } from 'utils/formatTickPrice' import { unwrappedToken } from 'utils/unwrappedToken' diff --git a/src/components/PrivacyPolicy/index.tsx b/src/components/PrivacyPolicy/index.tsx index 76033952ae..8f6250062e 100644 --- a/src/components/PrivacyPolicy/index.tsx +++ b/src/components/PrivacyPolicy/index.tsx @@ -4,7 +4,7 @@ import Card, { DarkGrayCard } from 'components/Card' import Row, { AutoRow, RowBetween } from 'components/Row' import { useEffect, useRef } from 'react' import { ArrowDown, Info, X } from 'react-feather' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ExternalLink, ThemedText } from 'theme' import { isMobile } from 'utils/userAgent' diff --git a/src/components/QuestionHelper/index.tsx b/src/components/QuestionHelper/index.tsx index c0bd401b64..fdf35bbac4 100644 --- a/src/components/QuestionHelper/index.tsx +++ b/src/components/QuestionHelper/index.tsx @@ -1,6 +1,6 @@ import { ReactNode, useCallback, useState } from 'react' import { HelpCircle } from 'react-feather' -import styled from 'styled-components/macro' +import styled from 'styled-components' import Tooltip from '../Tooltip' diff --git a/src/components/RangeSelector/PresetsButtons.tsx b/src/components/RangeSelector/PresetsButtons.tsx index 96c6f7515b..b884cbc425 100644 --- a/src/components/RangeSelector/PresetsButtons.tsx +++ b/src/components/RangeSelector/PresetsButtons.tsx @@ -1,7 +1,7 @@ import { Trans } from '@lingui/macro' import { ButtonOutlined } from 'components/Button' import { AutoRow } from 'components/Row' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ThemedText } from 'theme' const Button = styled(ButtonOutlined).attrs(() => ({ diff --git a/src/components/RouterLabel/UniswapXRouterLabel.tsx b/src/components/RouterLabel/UniswapXRouterLabel.tsx index cdeb4a1b39..784c320972 100644 --- a/src/components/RouterLabel/UniswapXRouterLabel.tsx +++ b/src/components/RouterLabel/UniswapXRouterLabel.tsx @@ -1,6 +1,6 @@ import Row from 'components/Row' import { useRef } from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { v4 as uuid } from 'uuid' import { BoxProps } from '../../nft/components/Box' diff --git a/src/components/RoutingDiagram/RoutingDiagram.tsx b/src/components/RoutingDiagram/RoutingDiagram.tsx index 58984b3719..22f96ca568 100644 --- a/src/components/RoutingDiagram/RoutingDiagram.tsx +++ b/src/components/RoutingDiagram/RoutingDiagram.tsx @@ -8,7 +8,7 @@ import CurrencyLogo from 'components/Logo/CurrencyLogo' import Row, { AutoRow } from 'components/Row' import { useTokenInfoFromActiveList } from 'hooks/useTokenInfoFromActiveList' import { Box } from 'rebass' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ThemedText } from 'theme' import { Z_INDEX } from 'theme/zIndex' import { RoutingDiagramEntry } from 'utils/getRoutingDiagramEntries' diff --git a/src/components/Row/index.tsx b/src/components/Row/index.tsx index f39351035c..abd83e7b10 100644 --- a/src/components/Row/index.tsx +++ b/src/components/Row/index.tsx @@ -1,5 +1,5 @@ import { Box } from 'rebass/styled-components' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { Gap } from 'theme' // TODO(WEB-1983): diff --git a/src/components/SearchModal/CommonBases.tsx b/src/components/SearchModal/CommonBases.tsx index 101c6669ef..abc59c34b6 100644 --- a/src/components/SearchModal/CommonBases.tsx +++ b/src/components/SearchModal/CommonBases.tsx @@ -8,7 +8,7 @@ import { COMMON_BASES } from 'constants/routing' import { useTokenInfoFromActiveList } from 'hooks/useTokenInfoFromActiveList' import { getTokenAddress } from 'lib/utils/analytics' import { Text } from 'rebass' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { currencyId } from 'utils/currencyId' const MobileWrapper = styled(AutoColumn)` diff --git a/src/components/SearchModal/CurrencyList/index.tsx b/src/components/SearchModal/CurrencyList/index.tsx index 4566386ff4..19fd3837cf 100644 --- a/src/components/SearchModal/CurrencyList/index.tsx +++ b/src/components/SearchModal/CurrencyList/index.tsx @@ -11,7 +11,7 @@ import { CSSProperties, MutableRefObject, useCallback, useMemo } from 'react' import { Check } from 'react-feather' import { FixedSizeList } from 'react-window' import { Text } from 'rebass' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { useIsUserAddedToken } from '../../../hooks/Tokens' import { WrappedTokenInfo } from '../../../state/lists/wrappedTokenInfo' diff --git a/src/components/SearchModal/CurrencySearch.tsx b/src/components/SearchModal/CurrencySearch.tsx index e6166288f2..6572f37b82 100644 --- a/src/components/SearchModal/CurrencySearch.tsx +++ b/src/components/SearchModal/CurrencySearch.tsx @@ -17,7 +17,7 @@ import { ChangeEvent, KeyboardEvent, RefObject, useCallback, useEffect, useMemo, import AutoSizer from 'react-virtualized-auto-sizer' import { FixedSizeList } from 'react-window' import { Text } from 'rebass' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import { UserAddedToken } from 'types/tokens' import { useDefaultActiveTokens, useIsUserAddedToken, useSearchInactiveTokenLists, useToken } from '../../hooks/Tokens' diff --git a/src/components/SearchModal/styleds.tsx b/src/components/SearchModal/styleds.tsx index 95a775e9d7..28c7e427d5 100644 --- a/src/components/SearchModal/styleds.tsx +++ b/src/components/SearchModal/styleds.tsx @@ -1,6 +1,6 @@ import searchIcon from 'assets/svg/search.svg' import { LoadingRows as BaseLoadingRows } from 'components/Loader/styled' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { AutoColumn } from '../Column' import { RowBetween } from '../Row' diff --git a/src/components/Settings/Input/index.tsx b/src/components/Settings/Input/index.tsx index 72afac7746..9ac001878d 100644 --- a/src/components/Settings/Input/index.tsx +++ b/src/components/Settings/Input/index.tsx @@ -1,4 +1,4 @@ -import styled from 'styled-components/macro' +import styled from 'styled-components' import Row from '../../Row' diff --git a/src/components/Settings/MaxSlippageSettings/index.tsx b/src/components/Settings/MaxSlippageSettings/index.tsx index dc481f912a..b7efcf7b65 100644 --- a/src/components/Settings/MaxSlippageSettings/index.tsx +++ b/src/components/Settings/MaxSlippageSettings/index.tsx @@ -6,7 +6,7 @@ import Row, { RowBetween } from 'components/Row' import React, { useState } from 'react' import { useUserSlippageTolerance } from 'state/user/hooks' import { SlippageTolerance } from 'state/user/types' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { CautionTriangle, ThemedText } from 'theme' import { Input, InputContainer } from '../Input' diff --git a/src/components/Settings/MenuButton/index.tsx b/src/components/Settings/MenuButton/index.tsx index 7187bb24f3..f3254ca56e 100644 --- a/src/components/Settings/MenuButton/index.tsx +++ b/src/components/Settings/MenuButton/index.tsx @@ -3,7 +3,7 @@ import { ReactComponent as Settings } from 'assets/svg/settings.svg' import Row from 'components/Row' import { useUserSlippageTolerance } from 'state/user/hooks' import { SlippageTolerance } from 'state/user/types' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ThemedText } from 'theme' import validateUserSlippageTolerance, { SlippageValidationResult } from 'utils/validateUserSlippageTolerance' diff --git a/src/components/Settings/RouterPreferenceSettings/index.tsx b/src/components/Settings/RouterPreferenceSettings/index.tsx index 056c938416..2cdeaba0a5 100644 --- a/src/components/Settings/RouterPreferenceSettings/index.tsx +++ b/src/components/Settings/RouterPreferenceSettings/index.tsx @@ -10,7 +10,7 @@ import { useAppDispatch } from 'state/hooks' import { RouterPreference } from 'state/routing/types' import { useRouterPreference } from 'state/user/hooks' import { updateDisabledUniswapX } from 'state/user/reducer' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { Divider, ExternalLink, ThemedText } from 'theme' const InlineLink = styled(ThemedText.Caption)` diff --git a/src/components/Settings/TransactionDeadlineSettings/index.tsx b/src/components/Settings/TransactionDeadlineSettings/index.tsx index ffc4564926..c89747d83b 100644 --- a/src/components/Settings/TransactionDeadlineSettings/index.tsx +++ b/src/components/Settings/TransactionDeadlineSettings/index.tsx @@ -4,7 +4,7 @@ import QuestionHelper from 'components/QuestionHelper' import Row from 'components/Row' import { Input, InputContainer } from 'components/Settings/Input' import { DEFAULT_DEADLINE_FROM_NOW } from 'constants/misc' -import ms from 'ms.macro' +import ms from 'ms' import React, { useState } from 'react' import { useUserTransactionTTL } from 'state/user/hooks' import { ThemedText } from 'theme' @@ -13,7 +13,7 @@ enum DeadlineError { InvalidInput = 'InvalidInput', } -const THREE_DAYS_IN_SECONDS = ms`3 days` / 1000 +const THREE_DAYS_IN_SECONDS = ms(`3d`) / 1000 const NUMBERS_ONLY = /^[0-9\b]+$/ export default function TransactionDeadlineSettings() { diff --git a/src/components/Settings/index.tsx b/src/components/Settings/index.tsx index f3c423afc4..4e90594f64 100644 --- a/src/components/Settings/index.tsx +++ b/src/components/Settings/index.tsx @@ -10,7 +10,7 @@ import { useModalIsOpen, useToggleSettingsMenu } from 'state/application/hooks' import { ApplicationModal } from 'state/application/reducer' import { InterfaceTrade } from 'state/routing/types' import { isUniswapXTrade } from 'state/routing/utils' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { Divider } from 'theme' import MaxSlippageSettings from './MaxSlippageSettings' diff --git a/src/components/Slider/index.tsx b/src/components/Slider/index.tsx index d8e4094628..38c3bf02a5 100644 --- a/src/components/Slider/index.tsx +++ b/src/components/Slider/index.tsx @@ -1,5 +1,5 @@ import { ChangeEvent, useCallback } from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' const StyledRangeInput = styled.input<{ size: number }>` -webkit-appearance: none; /* Hides the slider so that custom slider can be made */ diff --git a/src/components/SwitchLocaleLink/index.tsx b/src/components/SwitchLocaleLink/index.tsx index dfaee68d25..db42136bd5 100644 --- a/src/components/SwitchLocaleLink/index.tsx +++ b/src/components/SwitchLocaleLink/index.tsx @@ -1,7 +1,7 @@ import { Trans } from '@lingui/macro' import { useLocationLinkProps } from 'hooks/useLocationLinkProps' import { useMemo } from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { DEFAULT_LOCALE, LOCALE_LABEL, SupportedLocale } from '../../constants/locales' import { navigatorLocale, useActiveLocale } from '../../hooks/useActiveLocale' diff --git a/src/components/TextInput/index.tsx b/src/components/TextInput/index.tsx index cda929061a..9fab52c59f 100644 --- a/src/components/TextInput/index.tsx +++ b/src/components/TextInput/index.tsx @@ -1,5 +1,5 @@ import React, { ChangeEvent, memo, useCallback, useRef } from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' const Input = styled.input<{ error?: boolean; fontSize?: string }>` font-size: ${({ fontSize }) => fontSize || '1.25rem'}; diff --git a/src/components/Toggle/MultiToggle.tsx b/src/components/Toggle/MultiToggle.tsx index 85d15c574d..4528776d87 100644 --- a/src/components/Toggle/MultiToggle.tsx +++ b/src/components/Toggle/MultiToggle.tsx @@ -1,4 +1,4 @@ -import styled from 'styled-components/macro' +import styled from 'styled-components' export const ToggleWrapper = styled.button<{ width?: string }>` display: flex; diff --git a/src/components/Toggle/index.tsx b/src/components/Toggle/index.tsx index 1ac5712719..af5b244fac 100644 --- a/src/components/Toggle/index.tsx +++ b/src/components/Toggle/index.tsx @@ -1,6 +1,6 @@ import { darken } from 'polished' import { useState } from 'react' -import styled, { keyframes } from 'styled-components/macro' +import styled, { keyframes } from 'styled-components' const Wrapper = styled.button<{ isActive?: boolean; activeElement?: boolean }>` align-items: center; diff --git a/src/components/TokenSafety/TokenSafetyIcon.tsx b/src/components/TokenSafety/TokenSafetyIcon.tsx index 510bb5396d..ae8b099d42 100644 --- a/src/components/TokenSafety/TokenSafetyIcon.tsx +++ b/src/components/TokenSafety/TokenSafetyIcon.tsx @@ -1,6 +1,6 @@ import { Warning, WARNING_LEVEL } from 'constants/tokenSafety' import { AlertTriangle, Slash } from 'react-feather' -import styled, { css } from 'styled-components/macro' +import styled, { css } from 'styled-components' const WarningContainer = styled.div` margin-left: 4px; diff --git a/src/components/TokenSafety/TokenSafetyLabel.tsx b/src/components/TokenSafety/TokenSafetyLabel.tsx index 5c63ee9505..40303f234d 100644 --- a/src/components/TokenSafety/TokenSafetyLabel.tsx +++ b/src/components/TokenSafety/TokenSafetyLabel.tsx @@ -3,7 +3,7 @@ import { useTokenWarningColor, useTokenWarningTextColor } from 'hooks/useTokenWa import { ReactNode } from 'react' import { AlertTriangle, Slash } from 'react-feather' import { Text } from 'rebass' -import styled from 'styled-components/macro' +import styled from 'styled-components' const Label = styled.div<{ color: string; backgroundColor: string }>` padding: 4px 4px; diff --git a/src/components/TokenSafety/TokenSafetyMessage.tsx b/src/components/TokenSafety/TokenSafetyMessage.tsx index 7527317ad7..d31e9223ee 100644 --- a/src/components/TokenSafety/TokenSafetyMessage.tsx +++ b/src/components/TokenSafety/TokenSafetyMessage.tsx @@ -3,7 +3,7 @@ import { displayWarningLabel, getWarningCopy, TOKEN_SAFETY_ARTICLE, Warning } fr import { useTokenWarningColor, useTokenWarningTextColor } from 'hooks/useTokenWarningColor' import { AlertTriangle, Slash } from 'react-feather' import { Text } from 'rebass' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ExternalLink } from 'theme' const Label = styled.div<{ color: string; backgroundColor: string }>` diff --git a/src/components/TokenSafety/index.tsx b/src/components/TokenSafety/index.tsx index a7e50334fd..c50d9f8613 100644 --- a/src/components/TokenSafety/index.tsx +++ b/src/components/TokenSafety/index.tsx @@ -16,7 +16,7 @@ import { useToken } from 'hooks/Tokens' import { ExternalLink as LinkIconFeather } from 'react-feather' import { Text } from 'rebass' import { useAddUserToken } from 'state/user/hooks' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ButtonText, CopyLinkIcon, ExternalLink } from 'theme' import { ExplorerDataType, getExplorerLink } from 'utils/getExplorerLink' diff --git a/src/components/Tokens/TokenDetails/About.tsx b/src/components/Tokens/TokenDetails/About.tsx index b5b84eb510..fcc4287819 100644 --- a/src/components/Tokens/TokenDetails/About.tsx +++ b/src/components/Tokens/TokenDetails/About.tsx @@ -3,7 +3,7 @@ import { ChainId } from '@uniswap/sdk-core' import { getChainInfo } from 'constants/chainInfo' import { darken } from 'polished' import { useState } from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ThemedText } from 'theme' import { textFadeIn } from 'theme/styles' diff --git a/src/components/Tokens/TokenDetails/AddressSection.tsx b/src/components/Tokens/TokenDetails/AddressSection.tsx index de846f9da2..4176662603 100644 --- a/src/components/Tokens/TokenDetails/AddressSection.tsx +++ b/src/components/Tokens/TokenDetails/AddressSection.tsx @@ -1,5 +1,5 @@ import { Trans } from '@lingui/macro' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { CopyContractAddress, ThemedText } from 'theme' const ContractAddressSection = styled.div` diff --git a/src/components/Tokens/TokenDetails/BalanceSummary.tsx b/src/components/Tokens/TokenDetails/BalanceSummary.tsx index fe60063f9b..5d1531563b 100644 --- a/src/components/Tokens/TokenDetails/BalanceSummary.tsx +++ b/src/components/Tokens/TokenDetails/BalanceSummary.tsx @@ -7,7 +7,7 @@ import { getChainInfo } from 'constants/chainInfo' import { asSupportedChain } from 'constants/chains' import { useStablecoinValue } from 'hooks/useStablecoinPrice' import useCurrencyBalance from 'lib/hooks/useCurrencyBalance' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import { ThemedText } from 'theme' const BalancesCard = styled.div` diff --git a/src/components/Tokens/TokenDetails/BreadcrumbNavLink.tsx b/src/components/Tokens/TokenDetails/BreadcrumbNavLink.tsx index 108793fe93..f68d12e1ba 100644 --- a/src/components/Tokens/TokenDetails/BreadcrumbNavLink.tsx +++ b/src/components/Tokens/TokenDetails/BreadcrumbNavLink.tsx @@ -1,5 +1,5 @@ import { Link } from 'react-router-dom' -import styled from 'styled-components/macro' +import styled from 'styled-components' export const BreadcrumbNavLink = styled(Link)` display: flex; diff --git a/src/components/Tokens/TokenDetails/InvalidTokenDetails.tsx b/src/components/Tokens/TokenDetails/InvalidTokenDetails.tsx index 13ab6e190b..399565cf23 100644 --- a/src/components/Tokens/TokenDetails/InvalidTokenDetails.tsx +++ b/src/components/Tokens/TokenDetails/InvalidTokenDetails.tsx @@ -5,7 +5,7 @@ import { ButtonPrimary } from 'components/Button' import { getChainInfo } from 'constants/chainInfo' import useSelectChain from 'hooks/useSelectChain' import { useNavigate } from 'react-router-dom' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ThemedText } from 'theme' import { ReactComponent as EyeIcon } from '../../../assets/svg/eye.svg' diff --git a/src/components/Tokens/TokenDetails/MobileBalanceSummaryFooter.tsx b/src/components/Tokens/TokenDetails/MobileBalanceSummaryFooter.tsx index 8f4e111677..ea5ec97c36 100644 --- a/src/components/Tokens/TokenDetails/MobileBalanceSummaryFooter.tsx +++ b/src/components/Tokens/TokenDetails/MobileBalanceSummaryFooter.tsx @@ -6,7 +6,7 @@ import { NATIVE_CHAIN_ID } from 'constants/tokens' import { CHAIN_ID_TO_BACKEND_NAME } from 'graphql/data/util' import { useStablecoinValue } from 'hooks/useStablecoinPrice' import useCurrencyBalance from 'lib/hooks/useCurrencyBalance' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { StyledInternalLink } from 'theme' const Wrapper = styled.div` diff --git a/src/components/Tokens/TokenDetails/PriceChart.tsx b/src/components/Tokens/TokenDetails/PriceChart.tsx index 6fb0b072a0..cf24624292 100644 --- a/src/components/Tokens/TokenDetails/PriceChart.tsx +++ b/src/components/Tokens/TokenDetails/PriceChart.tsx @@ -13,7 +13,7 @@ import { TimePeriod } from 'graphql/data/util' import { useActiveLocale } from 'hooks/useActiveLocale' import { ReactNode, useCallback, useEffect, useMemo, useState } from 'react' import { ArrowDownRight, ArrowUpRight, TrendingUp } from 'react-feather' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import { ThemedText } from 'theme' import { textFadeIn } from 'theme/styles' import { diff --git a/src/components/Tokens/TokenDetails/Resource.tsx b/src/components/Tokens/TokenDetails/Resource.tsx index 20999a85d8..90b321c87e 100644 --- a/src/components/Tokens/TokenDetails/Resource.tsx +++ b/src/components/Tokens/TokenDetails/Resource.tsx @@ -1,5 +1,5 @@ import { darken } from 'polished' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ExternalLink } from 'theme' const ResourceLink = styled(ExternalLink)` diff --git a/src/components/Tokens/TokenDetails/ShareButton.tsx b/src/components/Tokens/TokenDetails/ShareButton.tsx index bfd450d994..ebbbd184fd 100644 --- a/src/components/Tokens/TokenDetails/ShareButton.tsx +++ b/src/components/Tokens/TokenDetails/ShareButton.tsx @@ -8,7 +8,7 @@ import { useRef } from 'react' import { Link, Twitter } from 'react-feather' import { useModalIsOpen, useToggleModal } from 'state/application/hooks' import { ApplicationModal } from 'state/application/reducer' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import { ClickableStyle, CopyHelperRefType } from 'theme' import { colors } from 'theme/colors' import { opacify } from 'theme/utils' diff --git a/src/components/Tokens/TokenDetails/Skeleton.tsx b/src/components/Tokens/TokenDetails/Skeleton.tsx index 1fb69b0c32..a0c95989cd 100644 --- a/src/components/Tokens/TokenDetails/Skeleton.tsx +++ b/src/components/Tokens/TokenDetails/Skeleton.tsx @@ -1,7 +1,7 @@ import { SwapSkeleton } from 'components/swap/SwapSkeleton' import { ArrowLeft } from 'react-feather' import { useParams } from 'react-router-dom' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import { textFadeIn } from 'theme/styles' import { LoadingBubble } from '../loading' diff --git a/src/components/Tokens/TokenDetails/StatsSection.tsx b/src/components/Tokens/TokenDetails/StatsSection.tsx index 0054640e71..370b6cb923 100644 --- a/src/components/Tokens/TokenDetails/StatsSection.tsx +++ b/src/components/Tokens/TokenDetails/StatsSection.tsx @@ -4,7 +4,7 @@ import { ChainId } from '@uniswap/sdk-core' import { MouseoverTooltip } from 'components/Tooltip' import { getChainInfo } from 'constants/chainInfo' import { ReactNode } from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ExternalLink, ThemedText } from 'theme' import { textFadeIn } from 'theme/styles' diff --git a/src/components/Tokens/TokenDetails/TimeSelector.tsx b/src/components/Tokens/TokenDetails/TimeSelector.tsx index 097145b214..f7b16fad9d 100644 --- a/src/components/Tokens/TokenDetails/TimeSelector.tsx +++ b/src/components/Tokens/TokenDetails/TimeSelector.tsx @@ -1,6 +1,6 @@ import { TimePeriod } from 'graphql/data/util' import { startTransition, useState } from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { MEDIUM_MEDIA_BREAKPOINT } from '../constants' import { DISPLAYS, ORDERED_TIMES } from '../TokenTable/TimeSelector' diff --git a/src/components/Tokens/TokenDetails/index.tsx b/src/components/Tokens/TokenDetails/index.tsx index 12b32e1a26..7e8419c920 100644 --- a/src/components/Tokens/TokenDetails/index.tsx +++ b/src/components/Tokens/TokenDetails/index.tsx @@ -35,7 +35,7 @@ import { ArrowLeft } from 'react-feather' import { useNavigate } from 'react-router-dom' import { Field } from 'state/swap/actions' import { SwapState } from 'state/swap/reducer' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { isAddress } from 'utils' import { addressesAreEquivalent } from 'utils/addressesAreEquivalent' diff --git a/src/components/Tokens/TokenTable/FilterOption.tsx b/src/components/Tokens/TokenTable/FilterOption.tsx index 53034fc4db..e0ba1f0118 100644 --- a/src/components/Tokens/TokenTable/FilterOption.tsx +++ b/src/components/Tokens/TokenTable/FilterOption.tsx @@ -1,4 +1,4 @@ -import styled from 'styled-components/macro' +import styled from 'styled-components' const FilterOption = styled.button<{ active: boolean; highlight?: boolean }>` height: 100%; color: ${({ theme, active }) => (active ? theme.accentActive : theme.textPrimary)}; diff --git a/src/components/Tokens/TokenTable/NetworkFilter.tsx b/src/components/Tokens/TokenTable/NetworkFilter.tsx index 87bd93aa67..afb0741f6e 100644 --- a/src/components/Tokens/TokenTable/NetworkFilter.tsx +++ b/src/components/Tokens/TokenTable/NetworkFilter.tsx @@ -12,7 +12,7 @@ import { Check, ChevronDown, ChevronUp } from 'react-feather' import { useNavigate, useParams } from 'react-router-dom' import { useModalIsOpen, useToggleModal } from 'state/application/hooks' import { ApplicationModal } from 'state/application/reducer' -import styled, { css, useTheme } from 'styled-components/macro' +import styled, { css, useTheme } from 'styled-components' import { EllipsisStyle } from 'theme' import FilterOption from './FilterOption' diff --git a/src/components/Tokens/TokenTable/SearchBar.tsx b/src/components/Tokens/TokenTable/SearchBar.tsx index a1fa6a2de9..b38f9a03a9 100644 --- a/src/components/Tokens/TokenTable/SearchBar.tsx +++ b/src/components/Tokens/TokenTable/SearchBar.tsx @@ -6,7 +6,7 @@ import xIcon from 'assets/svg/x.svg' import useDebounce from 'hooks/useDebounce' import { useAtomValue, useUpdateAtom } from 'jotai/utils' import { useEffect, useState } from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { MEDIUM_MEDIA_BREAKPOINT } from '../constants' import { filterStringAtom } from '../state' diff --git a/src/components/Tokens/TokenTable/TimeSelector.tsx b/src/components/Tokens/TokenTable/TimeSelector.tsx index 484204cc78..e68a2920c8 100644 --- a/src/components/Tokens/TokenTable/TimeSelector.tsx +++ b/src/components/Tokens/TokenTable/TimeSelector.tsx @@ -5,7 +5,7 @@ import { useRef } from 'react' import { Check, ChevronDown, ChevronUp } from 'react-feather' import { useModalIsOpen, useToggleModal } from 'state/application/hooks' import { ApplicationModal } from 'state/application/reducer' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import { MOBILE_MEDIA_BREAKPOINT, SMALL_MEDIA_BREAKPOINT } from '../constants' import { filterTimeAtom } from '../state' diff --git a/src/components/Tokens/TokenTable/TokenRow.tsx b/src/components/Tokens/TokenTable/TokenRow.tsx index 6fbca40070..66522e96ec 100644 --- a/src/components/Tokens/TokenTable/TokenRow.tsx +++ b/src/components/Tokens/TokenTable/TokenRow.tsx @@ -13,7 +13,7 @@ import { ForwardedRef, forwardRef } from 'react' import { CSSProperties, ReactNode } from 'react' import { ArrowDown, ArrowUp, Info } from 'react-feather' import { Link, useParams } from 'react-router-dom' -import styled, { css, useTheme } from 'styled-components/macro' +import styled, { css, useTheme } from 'styled-components' import { BREAKPOINTS, ClickableStyle } from 'theme' import { diff --git a/src/components/Tokens/TokenTable/TokenTable.tsx b/src/components/Tokens/TokenTable/TokenTable.tsx index a2e80faecd..ea010768bb 100644 --- a/src/components/Tokens/TokenTable/TokenTable.tsx +++ b/src/components/Tokens/TokenTable/TokenTable.tsx @@ -4,7 +4,7 @@ import { validateUrlChainParam } from 'graphql/data/util' import { ReactNode } from 'react' import { AlertTriangle } from 'react-feather' import { useParams } from 'react-router-dom' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { MAX_WIDTH_MEDIA_BREAKPOINT } from '../constants' import { HeaderRow, LoadedRow, LoadingRow } from './TokenRow' diff --git a/src/components/Tokens/TokenTable/__snapshots__/TokenRow.test.tsx.snap b/src/components/Tokens/TokenTable/__snapshots__/TokenRow.test.tsx.snap index b270d8a9f4..4f966b4dec 100644 --- a/src/components/Tokens/TokenTable/__snapshots__/TokenRow.test.tsx.snap +++ b/src/components/Tokens/TokenTable/__snapshots__/TokenRow.test.tsx.snap @@ -377,16 +377,16 @@ exports[`LoadedRow.tsx renders a row 1`] = ` />
USD Coin
USDC
@@ -401,11 +401,11 @@ exports[`LoadedRow.tsx renders a row 1`] = ` class="c5" >
$1.00
` height: 90px; diff --git a/src/components/TransactionConfirmationModal/index.tsx b/src/components/TransactionConfirmationModal/index.tsx index f9777017c9..cba4396aa7 100644 --- a/src/components/TransactionConfirmationModal/index.tsx +++ b/src/components/TransactionConfirmationModal/index.tsx @@ -8,7 +8,7 @@ import useCurrencyLogoURIs from 'lib/hooks/useCurrencyLogoURIs' import { ReactNode, useCallback, useState } from 'react' import { AlertCircle, ArrowUpCircle, CheckCircle } from 'react-feather' import { useIsTransactionConfirmed, useTransaction } from 'state/transactions/hooks' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import { isL2ChainId } from 'utils/chains' import { ExplorerDataType, getExplorerLink } from 'utils/getExplorerLink' diff --git a/src/components/V2Unsupported/index.tsx b/src/components/V2Unsupported/index.tsx index a1f9b36f86..c797b7d01c 100644 --- a/src/components/V2Unsupported/index.tsx +++ b/src/components/V2Unsupported/index.tsx @@ -1,6 +1,6 @@ import { Trans } from '@lingui/macro' import { AutoColumn } from 'components/Column' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ThemedText } from 'theme' const TextWrapper = styled.div` diff --git a/src/components/WalletModal/ConnectionErrorView.tsx b/src/components/WalletModal/ConnectionErrorView.tsx index 17f82e2de9..e6f7d39c52 100644 --- a/src/components/WalletModal/ConnectionErrorView.tsx +++ b/src/components/WalletModal/ConnectionErrorView.tsx @@ -3,7 +3,7 @@ import { useCloseAccountDrawer } from 'components/AccountDrawer' import { ButtonEmpty, ButtonPrimary } from 'components/Button' import { ActivationStatus, useActivationState } from 'connection/activate' import { AlertTriangle } from 'react-feather' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ThemedText } from 'theme' import { flexColumnNoWrap } from 'theme/styles' diff --git a/src/components/WalletModal/Option.tsx b/src/components/WalletModal/Option.tsx index 47b47355d2..d1147795f1 100644 --- a/src/components/WalletModal/Option.tsx +++ b/src/components/WalletModal/Option.tsx @@ -5,7 +5,7 @@ import { useToggleAccountDrawer } from 'components/AccountDrawer' import Loader from 'components/Icons/LoadingSpinner' import { ActivationStatus, useActivationState } from 'connection/activate' import { Connection } from 'connection/types' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { useIsDarkMode } from 'theme/components/ThemeToggle' import { flexColumnNoWrap, flexRowNoWrap } from 'theme/styles' diff --git a/src/components/WalletModal/PrivacyPolicyNotice.tsx b/src/components/WalletModal/PrivacyPolicyNotice.tsx index 71d17daf1b..75c1f15b5f 100644 --- a/src/components/WalletModal/PrivacyPolicyNotice.tsx +++ b/src/components/WalletModal/PrivacyPolicyNotice.tsx @@ -1,5 +1,5 @@ import { Trans } from '@lingui/macro' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ExternalLink, ThemedText } from 'theme' const StyledLink = styled(ExternalLink)` diff --git a/src/components/WalletModal/index.tsx b/src/components/WalletModal/index.tsx index 91f0a2bce9..4bdc7c6b0f 100644 --- a/src/components/WalletModal/index.tsx +++ b/src/components/WalletModal/index.tsx @@ -7,7 +7,7 @@ import { ActivationStatus, useActivationState } from 'connection/activate' import { isSupportedChain } from 'constants/chains' import { useEffect } from 'react' import { Settings } from 'react-feather' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ThemedText } from 'theme' import { flexColumnNoWrap } from 'theme/styles' diff --git a/src/components/Web3Status/index.tsx b/src/components/Web3Status/index.tsx index 9d904364a4..c85fdd75a5 100644 --- a/src/components/Web3Status/index.tsx +++ b/src/components/Web3Status/index.tsx @@ -16,7 +16,7 @@ import { useIsNftClaimAvailable } from 'nft/hooks/useIsNftClaimAvailable' import { darken } from 'polished' import { useCallback } from 'react' import { useAppSelector } from 'state/hooks' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { colors } from 'theme/colors' import { flexRowNoWrap } from 'theme/styles' import { shortenAddress } from 'utils' diff --git a/src/components/addLiquidity/OwnershipWarning.tsx b/src/components/addLiquidity/OwnershipWarning.tsx index fc75afd141..9843b4c649 100644 --- a/src/components/addLiquidity/OwnershipWarning.tsx +++ b/src/components/addLiquidity/OwnershipWarning.tsx @@ -1,6 +1,6 @@ import { Trans } from '@lingui/macro' import { AlertTriangle } from 'react-feather' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ThemedText } from 'theme' const ExplainerText = styled.div` diff --git a/src/components/claim/AddressClaimModal.tsx b/src/components/claim/AddressClaimModal.tsx index 8406158960..a24617f14a 100644 --- a/src/components/claim/AddressClaimModal.tsx +++ b/src/components/claim/AddressClaimModal.tsx @@ -4,7 +4,7 @@ import { CurrencyAmount, Token } from '@uniswap/sdk-core' import { useWeb3React } from '@web3-react/core' import { useState } from 'react' import { Text } from 'rebass' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { shortenAddress } from 'utils' import Circle from '../../assets/images/blue-loader.svg' diff --git a/src/components/earn/styled.ts b/src/components/earn/styled.ts index 1dbd0d2710..a1ca41c7ba 100644 --- a/src/components/earn/styled.ts +++ b/src/components/earn/styled.ts @@ -1,4 +1,4 @@ -import styled from 'styled-components/macro' +import styled from 'styled-components' import uImage from '../../assets/images/big_unicorn.png' import noise from '../../assets/images/noise.png' diff --git a/src/components/swap/ConfirmSwapModal.tsx b/src/components/swap/ConfirmSwapModal.tsx index 5a7ab63fc2..0a888b6ca6 100644 --- a/src/components/swap/ConfirmSwapModal.tsx +++ b/src/components/swap/ConfirmSwapModal.tsx @@ -26,7 +26,7 @@ import { useCallback, useEffect, useState } from 'react' import { InterfaceTrade, TradeFillType } from 'state/routing/types' import { Field } from 'state/swap/actions' import { useIsTransactionConfirmed, useSwapTransactionStatus } from 'state/transactions/hooks' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ThemedText } from 'theme' import invariant from 'tiny-invariant' import { isL2ChainId } from 'utils/chains' diff --git a/src/components/swap/GasBreakdownTooltip.tsx b/src/components/swap/GasBreakdownTooltip.tsx index 9635882963..4ff76be711 100644 --- a/src/components/swap/GasBreakdownTooltip.tsx +++ b/src/components/swap/GasBreakdownTooltip.tsx @@ -6,7 +6,7 @@ import Row from 'components/Row' import { ReactNode } from 'react' import { InterfaceTrade } from 'state/routing/types' import { isClassicTrade, isUniswapXTrade } from 'state/routing/utils' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { Divider, ExternalLink, ThemedText } from 'theme' const Container = styled(AutoColumn)` diff --git a/src/components/swap/GasEstimateTooltip.tsx b/src/components/swap/GasEstimateTooltip.tsx index 6a314774b3..2a0be36417 100644 --- a/src/components/swap/GasEstimateTooltip.tsx +++ b/src/components/swap/GasEstimateTooltip.tsx @@ -9,7 +9,7 @@ import { MouseoverTooltip, TooltipSize } from 'components/Tooltip' import { SUPPORTED_GAS_ESTIMATE_CHAIN_IDS } from 'constants/chains' import { InterfaceTrade } from 'state/routing/types' import { isUniswapXTrade } from 'state/routing/utils' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ThemedText } from 'theme' import { ReactComponent as GasIcon } from '../../assets/images/gas-icon.svg' diff --git a/src/components/swap/PendingModalContent/ErrorModalContent.tsx b/src/components/swap/PendingModalContent/ErrorModalContent.tsx index ee4eb0ffef..b06253c9c6 100644 --- a/src/components/swap/PendingModalContent/ErrorModalContent.tsx +++ b/src/components/swap/PendingModalContent/ErrorModalContent.tsx @@ -4,7 +4,7 @@ import { ColumnCenter } from 'components/Column' import QuestionHelper from 'components/QuestionHelper' import Row from 'components/Row' import { AlertTriangle } from 'react-feather' -import { useTheme } from 'styled-components/macro' +import { useTheme } from 'styled-components' import { ThemedText } from 'theme' import { PendingModalContainer } from '.' diff --git a/src/components/swap/PendingModalContent/Logos.tsx b/src/components/swap/PendingModalContent/Logos.tsx index efb3c745b0..8a6bb06f35 100644 --- a/src/components/swap/PendingModalContent/Logos.tsx +++ b/src/components/swap/PendingModalContent/Logos.tsx @@ -4,7 +4,7 @@ import { LoaderV3 } from 'components/Icons/LoadingSpinner' import CurrencyLogo from 'components/Logo/CurrencyLogo' import { useUnmountingAnimation } from 'hooks/useUnmountingAnimation' import { useRef } from 'react' -import styled, { css, keyframes, useTheme } from 'styled-components/macro' +import styled, { css, keyframes, useTheme } from 'styled-components' export const LogoContainer = styled.div` height: 48px; diff --git a/src/components/swap/PendingModalContent/TradeSummary.tsx b/src/components/swap/PendingModalContent/TradeSummary.tsx index adc39f1109..8bf482afc9 100644 --- a/src/components/swap/PendingModalContent/TradeSummary.tsx +++ b/src/components/swap/PendingModalContent/TradeSummary.tsx @@ -2,7 +2,7 @@ import CurrencyLogo from 'components/Logo/CurrencyLogo' import Row from 'components/Row' import { ArrowRight } from 'react-feather' import { InterfaceTrade } from 'state/routing/types' -import { useTheme } from 'styled-components/macro' +import { useTheme } from 'styled-components' import { ThemedText } from 'theme' import { formatReviewSwapCurrencyAmount } from 'utils/formatNumbers' diff --git a/src/components/swap/PendingModalContent/index.tsx b/src/components/swap/PendingModalContent/index.tsx index 577298f4d1..bfe0eb5917 100644 --- a/src/components/swap/PendingModalContent/index.tsx +++ b/src/components/swap/PendingModalContent/index.tsx @@ -14,7 +14,7 @@ import { InterfaceTrade, TradeFillType } from 'state/routing/types' import { useOrder } from 'state/signatures/hooks' import { UniswapXOrderDetails } from 'state/signatures/types' import { useIsTransactionConfirmed, useSwapTransactionStatus } from 'state/transactions/hooks' -import styled, { css, keyframes } from 'styled-components/macro' +import styled, { css, keyframes } from 'styled-components' import { ExternalLink } from 'theme' import { ThemedText } from 'theme/components/text' import { getExplorerLink } from 'utils/getExplorerLink' diff --git a/src/components/swap/PriceImpactModal.tsx b/src/components/swap/PriceImpactModal.tsx index b9fdf11e50..ca965d33e5 100644 --- a/src/components/swap/PriceImpactModal.tsx +++ b/src/components/swap/PriceImpactModal.tsx @@ -5,7 +5,7 @@ import { ButtonEmphasis, ButtonSize, ThemeButton } from 'components/Button' import { ColumnCenter } from 'components/Column' import Row from 'components/Row' import { AlertTriangle } from 'react-feather' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { CloseIcon, ThemedText } from 'theme' import Modal from '../Modal' diff --git a/src/components/swap/PriceImpactWarning.tsx b/src/components/swap/PriceImpactWarning.tsx index 87cfc03735..1411a6e939 100644 --- a/src/components/swap/PriceImpactWarning.tsx +++ b/src/components/swap/PriceImpactWarning.tsx @@ -1,7 +1,7 @@ import { Trans } from '@lingui/macro' import { Percent } from '@uniswap/sdk-core' import { OutlineCard } from 'components/Card' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import { opacify } from 'theme/utils' import formatPriceImpact from 'utils/formatPriceImpact' diff --git a/src/components/swap/SwapBuyFiatButton.tsx b/src/components/swap/SwapBuyFiatButton.tsx index 9fd695b499..7026f73fa2 100644 --- a/src/components/swap/SwapBuyFiatButton.tsx +++ b/src/components/swap/SwapBuyFiatButton.tsx @@ -6,7 +6,7 @@ import { useAccountDrawer } from 'components/AccountDrawer' import { ButtonText } from 'components/Button' import { MouseoverTooltip } from 'components/Tooltip' import { useCallback, useEffect, useState } from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ExternalLink } from 'theme' import { useFiatOnrampAvailability, useOpenModal } from '../../state/application/hooks' diff --git a/src/components/swap/SwapDetailsDropdown.tsx b/src/components/swap/SwapDetailsDropdown.tsx index 8c047b4e43..a9676fa5b9 100644 --- a/src/components/swap/SwapDetailsDropdown.tsx +++ b/src/components/swap/SwapDetailsDropdown.tsx @@ -10,7 +10,7 @@ import { formatCommonPropertiesForTrade } from 'lib/utils/analytics' import { useState } from 'react' import { ChevronDown } from 'react-feather' import { InterfaceTrade } from 'state/routing/types' -import styled, { keyframes, useTheme } from 'styled-components/macro' +import styled, { keyframes, useTheme } from 'styled-components' import { ThemedText } from 'theme' import { AdvancedSwapDetails } from './AdvancedSwapDetails' diff --git a/src/components/swap/SwapHeader.tsx b/src/components/swap/SwapHeader.tsx index c41885d3be..b64c19f52d 100644 --- a/src/components/swap/SwapHeader.tsx +++ b/src/components/swap/SwapHeader.tsx @@ -2,7 +2,7 @@ import { Trans } from '@lingui/macro' import { Percent } from '@uniswap/sdk-core' import { useFiatOnRampButtonEnabled } from 'featureFlags/flags/fiatOnRampButton' import { InterfaceTrade } from 'state/routing/types' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ThemedText } from 'theme' import { RowBetween, RowFixed } from '../Row' diff --git a/src/components/swap/SwapModalFooter.tsx b/src/components/swap/SwapModalFooter.tsx index 3036bea5a9..918fc728e5 100644 --- a/src/components/swap/SwapModalFooter.tsx +++ b/src/components/swap/SwapModalFooter.tsx @@ -11,11 +11,10 @@ import useTransactionDeadline from 'hooks/useTransactionDeadline' import useNativeCurrency from 'lib/hooks/useNativeCurrency' import { ReactNode } from 'react' import { AlertTriangle } from 'react-feather' -import { RouterPreference } from 'state/routing/types' -import { InterfaceTrade } from 'state/routing/types' +import { InterfaceTrade, RouterPreference } from 'state/routing/types' import { getTransactionCount, isClassicTrade } from 'state/routing/utils' import { useRouterPreference, useUserSlippageTolerance } from 'state/user/hooks' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import { ThemedText } from 'theme' import { formatTransactionAmount, priceToPreciseFloat } from 'utils/formatNumbers' import getRoutingDiagramEntries from 'utils/getRoutingDiagramEntries' diff --git a/src/components/swap/SwapModalHeader.tsx b/src/components/swap/SwapModalHeader.tsx index c39b555ef3..254a04d7fa 100644 --- a/src/components/swap/SwapModalHeader.tsx +++ b/src/components/swap/SwapModalHeader.tsx @@ -4,7 +4,7 @@ import Column, { AutoColumn } from 'components/Column' import { useUSDPrice } from 'hooks/useUSDPrice' import { InterfaceTrade } from 'state/routing/types' import { Field } from 'state/swap/actions' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { Divider, ThemedText } from 'theme' import { SwapModalHeaderAmount } from './SwapModalHeaderAmount' diff --git a/src/components/swap/SwapModalHeaderAmount.tsx b/src/components/swap/SwapModalHeaderAmount.tsx index 0bbc06132c..4fc38697b2 100644 --- a/src/components/swap/SwapModalHeaderAmount.tsx +++ b/src/components/swap/SwapModalHeaderAmount.tsx @@ -8,7 +8,7 @@ import { useWindowSize } from 'hooks/useWindowSize' import { PropsWithChildren, ReactNode } from 'react' import { TextProps } from 'rebass' import { Field } from 'state/swap/actions' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { BREAKPOINTS, ThemedText } from 'theme' import { formatReviewSwapCurrencyAmount } from 'utils/formatNumbers' diff --git a/src/components/swap/SwapSkeleton.tsx b/src/components/swap/SwapSkeleton.tsx index df982db029..7323d6b28e 100644 --- a/src/components/swap/SwapSkeleton.tsx +++ b/src/components/swap/SwapSkeleton.tsx @@ -1,7 +1,7 @@ import { Trans } from '@lingui/macro' import { ArrowContainer } from 'pages/Swap' import { ArrowDown } from 'react-feather' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import { ThemedText } from 'theme' import { ArrowWrapper } from './styleds' diff --git a/src/components/swap/TradePrice.tsx b/src/components/swap/TradePrice.tsx index 5910e9eed0..aeed0d2435 100644 --- a/src/components/swap/TradePrice.tsx +++ b/src/components/swap/TradePrice.tsx @@ -4,7 +4,7 @@ import { Currency, Price } from '@uniswap/sdk-core' import { useUSDPrice } from 'hooks/useUSDPrice' import tryParseCurrencyAmount from 'lib/utils/tryParseCurrencyAmount' import { useCallback, useMemo, useState } from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ThemedText } from 'theme' interface TradePriceProps { diff --git a/src/components/swap/UnsupportedCurrencyFooter.tsx b/src/components/swap/UnsupportedCurrencyFooter.tsx index 2e2452b23c..0d051a62aa 100644 --- a/src/components/swap/UnsupportedCurrencyFooter.tsx +++ b/src/components/swap/UnsupportedCurrencyFooter.tsx @@ -8,7 +8,7 @@ import CurrencyLogo from 'components/Logo/CurrencyLogo' import Modal from 'components/Modal' import { AutoRow, RowBetween } from 'components/Row' import { useState } from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { CloseIcon, ExternalLink, ThemedText } from 'theme' import { Z_INDEX } from 'theme/zIndex' diff --git a/src/components/swap/styleds.tsx b/src/components/swap/styleds.tsx index 0d4e41a196..47f408bc30 100644 --- a/src/components/swap/styleds.tsx +++ b/src/components/swap/styleds.tsx @@ -2,7 +2,7 @@ import { ChainId } from '@uniswap/sdk-core' import { transparentize } from 'polished' import { ReactNode } from 'react' import { AlertTriangle } from 'react-feather' -import styled, { css } from 'styled-components/macro' +import styled, { css } from 'styled-components' import { Z_INDEX } from 'theme/zIndex' import { useIsDarkMode } from '../../theme/components/ThemeToggle' diff --git a/src/components/vote/DelegateModal.tsx b/src/components/vote/DelegateModal.tsx index d7564818a4..1dcad613ac 100644 --- a/src/components/vote/DelegateModal.tsx +++ b/src/components/vote/DelegateModal.tsx @@ -3,7 +3,7 @@ import { Trans } from '@lingui/macro' import { useWeb3React } from '@web3-react/core' import { ReactNode, useState } from 'react' import { X } from 'react-feather' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { formatCurrencyAmount } from 'utils/formatCurrencyAmount' import { UNI } from '../../constants/tokens' diff --git a/src/components/vote/ExecuteModal.tsx b/src/components/vote/ExecuteModal.tsx index 2b6f54213c..19677e9b81 100644 --- a/src/components/vote/ExecuteModal.tsx +++ b/src/components/vote/ExecuteModal.tsx @@ -2,7 +2,7 @@ import { Trans } from '@lingui/macro' import { useWeb3React } from '@web3-react/core' import { useState } from 'react' import { ArrowUpCircle, X } from 'react-feather' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import Circle from '../../assets/images/blue-loader.svg' import { useExecuteCallback } from '../../state/governance/hooks' diff --git a/src/components/vote/ProposalEmptyState.tsx b/src/components/vote/ProposalEmptyState.tsx index ccdd8bd372..970e2a853f 100644 --- a/src/components/vote/ProposalEmptyState.tsx +++ b/src/components/vote/ProposalEmptyState.tsx @@ -1,7 +1,7 @@ import { Trans } from '@lingui/macro' import { ChainId } from '@uniswap/sdk-core' import { useWeb3React } from '@web3-react/core' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ThemedText } from 'theme' const EmptyProposals = styled.div` diff --git a/src/components/vote/QueueModal.tsx b/src/components/vote/QueueModal.tsx index 6569f6012c..8e70816805 100644 --- a/src/components/vote/QueueModal.tsx +++ b/src/components/vote/QueueModal.tsx @@ -2,7 +2,7 @@ import { Trans } from '@lingui/macro' import { useWeb3React } from '@web3-react/core' import { useState } from 'react' import { ArrowUpCircle, X } from 'react-feather' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import Circle from '../../assets/images/blue-loader.svg' import { useQueueCallback } from '../../state/governance/hooks' diff --git a/src/components/vote/VoteModal.tsx b/src/components/vote/VoteModal.tsx index 36e4b127e0..5a0192e055 100644 --- a/src/components/vote/VoteModal.tsx +++ b/src/components/vote/VoteModal.tsx @@ -2,7 +2,7 @@ import { Trans } from '@lingui/macro' import { useWeb3React } from '@web3-react/core' import { useState } from 'react' import { ArrowUpCircle, X } from 'react-feather' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import { formatCurrencyAmount } from 'utils/formatCurrencyAmount' import Circle from '../../assets/images/blue-loader.svg' diff --git a/src/constants/chainInfo.ts b/src/constants/chainInfo.ts index e67ae7d33b..1e7793816a 100644 --- a/src/constants/chainInfo.ts +++ b/src/constants/chainInfo.ts @@ -15,13 +15,13 @@ import optimismSquareLogoUrl from 'assets/svg/optimism_square_logo.svg' import optimismLogoUrl from 'assets/svg/optimistic_ethereum.svg' import polygonSquareLogoUrl from 'assets/svg/polygon_square_logo.svg' import polygonMaticLogo from 'assets/svg/polygon-matic-logo.svg' -import ms from 'ms.macro' +import ms from 'ms' import { darkTheme } from 'theme/colors' import { SupportedL1ChainId, SupportedL2ChainId } from './chains' import { ARBITRUM_LIST, AVALANCHE_LIST, BASE_LIST, CELO_LIST, OPTIMISM_LIST, PLASMA_BNB_LIST } from './lists' -export const AVERAGE_L1_BLOCK_TIME = ms`12s` +export const AVERAGE_L1_BLOCK_TIME = ms(`12s`) export enum NetworkType { L1, @@ -97,7 +97,7 @@ const CHAIN_INFO: ChainInfoMap = { }, [ChainId.OPTIMISM]: { networkType: NetworkType.L2, - blockWaitMsBeforeWarning: ms`25m`, + blockWaitMsBeforeWarning: ms(`25m`), bridge: 'https://app.optimism.io/bridge', defaultListUrl: OPTIMISM_LIST, docs: 'https://optimism.io/', @@ -116,7 +116,7 @@ const CHAIN_INFO: ChainInfoMap = { }, [ChainId.OPTIMISM_GOERLI]: { networkType: NetworkType.L2, - blockWaitMsBeforeWarning: ms`25m`, + blockWaitMsBeforeWarning: ms(`25m`), bridge: 'https://app.optimism.io/bridge', defaultListUrl: OPTIMISM_LIST, docs: 'https://optimism.io/', @@ -131,7 +131,7 @@ const CHAIN_INFO: ChainInfoMap = { }, [ChainId.ARBITRUM_ONE]: { networkType: NetworkType.L2, - blockWaitMsBeforeWarning: ms`10m`, + blockWaitMsBeforeWarning: ms(`10m`), bridge: 'https://bridge.arbitrum.io/', docs: 'https://offchainlabs.com/', explorer: 'https://arbiscan.io/', @@ -147,7 +147,7 @@ const CHAIN_INFO: ChainInfoMap = { }, [ChainId.ARBITRUM_GOERLI]: { networkType: NetworkType.L2, - blockWaitMsBeforeWarning: ms`10m`, + blockWaitMsBeforeWarning: ms(`10m`), bridge: 'https://bridge.arbitrum.io/', docs: 'https://offchainlabs.com/', explorer: 'https://goerli.arbiscan.io/', @@ -161,7 +161,7 @@ const CHAIN_INFO: ChainInfoMap = { }, [ChainId.POLYGON]: { networkType: NetworkType.L1, - blockWaitMsBeforeWarning: ms`10m`, + blockWaitMsBeforeWarning: ms(`10m`), bridge: 'https://wallet.polygon.technology/polygon/bridge', docs: 'https://polygon.io/', explorer: 'https://polygonscan.com/', @@ -176,7 +176,7 @@ const CHAIN_INFO: ChainInfoMap = { }, [ChainId.POLYGON_MUMBAI]: { networkType: NetworkType.L1, - blockWaitMsBeforeWarning: ms`10m`, + blockWaitMsBeforeWarning: ms(`10m`), bridge: 'https://wallet.polygon.technology/polygon/bridge/deposit', docs: 'https://polygon.io/', explorer: 'https://mumbai.polygonscan.com/', @@ -187,7 +187,7 @@ const CHAIN_INFO: ChainInfoMap = { }, [ChainId.CELO]: { networkType: NetworkType.L1, - blockWaitMsBeforeWarning: ms`10m`, + blockWaitMsBeforeWarning: ms(`10m`), bridge: 'https://www.portalbridge.com/#/transfer', docs: 'https://docs.celo.org/', explorer: 'https://celoscan.io/', @@ -201,7 +201,7 @@ const CHAIN_INFO: ChainInfoMap = { }, [ChainId.CELO_ALFAJORES]: { networkType: NetworkType.L1, - blockWaitMsBeforeWarning: ms`10m`, + blockWaitMsBeforeWarning: ms(`10m`), bridge: 'https://www.portalbridge.com/#/transfer', docs: 'https://docs.celo.org/', explorer: 'https://alfajores-blockscout.celo-testnet.org/', @@ -213,7 +213,7 @@ const CHAIN_INFO: ChainInfoMap = { }, [ChainId.BNB]: { networkType: NetworkType.L1, - blockWaitMsBeforeWarning: ms`10m`, + blockWaitMsBeforeWarning: ms(`10m`), bridge: 'https://cbridge.celer.network/1/56', docs: 'https://docs.bnbchain.org/', explorer: 'https://bscscan.com/', @@ -229,7 +229,7 @@ const CHAIN_INFO: ChainInfoMap = { }, [ChainId.AVALANCHE]: { networkType: NetworkType.L1, - blockWaitMsBeforeWarning: ms`10m`, + blockWaitMsBeforeWarning: ms(`10m`), bridge: 'https://core.app/bridge/', docs: 'https://docs.avax.network/', explorer: 'https://snowtrace.io/', @@ -245,7 +245,7 @@ const CHAIN_INFO: ChainInfoMap = { }, [ChainId.BASE]: { networkType: NetworkType.L2, - blockWaitMsBeforeWarning: ms`25m`, + blockWaitMsBeforeWarning: ms(`25m`), bridge: 'https://bridge.base.org/deposit', defaultListUrl: BASE_LIST, docs: 'https://docs.base.org', @@ -261,7 +261,7 @@ const CHAIN_INFO: ChainInfoMap = { }, [ChainId.BASE_GOERLI]: { networkType: NetworkType.L2, - blockWaitMsBeforeWarning: ms`25m`, + blockWaitMsBeforeWarning: ms(`25m`), bridge: 'https://goerli-bridge.base.org/deposit', defaultListUrl: BASE_LIST, docs: 'https://docs.base.org', diff --git a/src/constants/chains.ts b/src/constants/chains.ts index e3ee0acc4b..a066ca065e 100644 --- a/src/constants/chains.ts +++ b/src/constants/chains.ts @@ -102,10 +102,6 @@ export const L2_CHAIN_IDS = [ export type SupportedL2ChainId = (typeof L2_CHAIN_IDS)[number] -export function isPolygonChain(chainId: number): chainId is ChainId.POLYGON | ChainId.POLYGON_MUMBAI { - return chainId === ChainId.POLYGON || chainId === ChainId.POLYGON_MUMBAI -} - /** * Get the priority of a chainId based on its relevance to the user. * @param {ChainId} chainId - The chainId to determine the priority for. diff --git a/src/constants/locales.ts b/src/constants/locales.ts index a8c9cbb21e..4ac3da9af6 100644 --- a/src/constants/locales.ts +++ b/src/constants/locales.ts @@ -36,6 +36,7 @@ export const SUPPORTED_LOCALES = [ export type SupportedLocale = (typeof SUPPORTED_LOCALES)[number] export const DEFAULT_LOCALE: SupportedLocale = 'en-US' +export { messages as DEFAULT_MESSAGES } from 'locales/en-US' export const LOCALE_LABEL: { [locale in SupportedLocale]: string } = { 'af-ZA': 'Afrikaans', diff --git a/src/graphql/data/util.tsx b/src/graphql/data/util.tsx index a7338aa5f1..6235d8db8d 100644 --- a/src/graphql/data/util.tsx +++ b/src/graphql/data/util.tsx @@ -1,18 +1,19 @@ import { QueryResult } from '@apollo/client' import * as Sentry from '@sentry/react' import { ChainId, Currency, Token } from '@uniswap/sdk-core' +import { AVERAGE_L1_BLOCK_TIME } from 'constants/chainInfo' import { NATIVE_CHAIN_ID, nativeOnChain, WRAPPED_NATIVE_CURRENCY } from 'constants/tokens' -import ms from 'ms.macro' +import ms from 'ms' import { useEffect } from 'react' import { getNativeTokenDBAddress } from 'utils/nativeTokens' import { Chain, ContractInput, HistoryDuration, TokenStandard } from './__generated__/types-and-hooks' export enum PollingInterval { - Slow = ms`5m`, - Normal = ms`1m`, - Fast = ms`12s`, // 12 seconds, block times for mainnet - LightningMcQueen = ms`3s`, // 3 seconds, approx block times for polygon + Slow = ms(`5m`), + Normal = ms(`1m`), + Fast = AVERAGE_L1_BLOCK_TIME, + LightningMcQueen = ms(`3s`), // approx block interval for polygon } // Polls a query only when the current component is mounted, as useQuery's pollInterval prop will continue to poll after unmount diff --git a/src/hooks/useAccountRiskCheck.ts b/src/hooks/useAccountRiskCheck.ts index 1d210c6b83..a3f015516d 100644 --- a/src/hooks/useAccountRiskCheck.ts +++ b/src/hooks/useAccountRiskCheck.ts @@ -1,5 +1,5 @@ import { sendEvent } from 'components/analytics' -import ms from 'ms.macro' +import ms from 'ms' import { useEffect } from 'react' import { ApplicationModal, setOpenModal } from 'state/application/reducer' import { useAppDispatch } from 'state/hooks' @@ -35,7 +35,7 @@ export default function useAccountRiskCheck(account: string | null | undefined) .catch(() => dispatch(setOpenModal(null))) } } finally { - localStorage.setItem(riskCheckLocalStorageKey, (now + ms`1 day`).toString()) + localStorage.setItem(riskCheckLocalStorageKey, (now + ms(`1d`)).toString()) } } }, [account, dispatch]) diff --git a/src/hooks/useActiveLocale.ts b/src/hooks/useActiveLocale.ts index d14b34863e..95f1aa8fcb 100644 --- a/src/hooks/useActiveLocale.ts +++ b/src/hooks/useActiveLocale.ts @@ -3,8 +3,7 @@ import { useMemo } from 'react' import store from 'state' import { useUserLocale } from 'state/user/hooks' -import useParsedQueryString from './useParsedQueryString' -import { parsedQueryString } from './useParsedQueryString' +import useParsedQueryString, { parsedQueryString } from './useParsedQueryString' /** * Given a locale string (e.g. from user agent), return the best match for corresponding SupportedLocale diff --git a/src/hooks/useBestTrade.test.ts b/src/hooks/useBestTrade.test.ts index 58e697cd97..dc17411cf9 100644 --- a/src/hooks/useBestTrade.test.ts +++ b/src/hooks/useBestTrade.test.ts @@ -1,8 +1,7 @@ import { renderHook } from '@testing-library/react' import { CurrencyAmount, TradeType } from '@uniswap/sdk-core' import { DAI, USDC_MAINNET } from 'constants/tokens' -import { RouterPreference } from 'state/routing/types' -import { TradeState } from 'state/routing/types' +import { RouterPreference, TradeState } from 'state/routing/types' import { useRouterPreference } from 'state/user/hooks' import { mocked } from 'test-utils/mocked' diff --git a/src/hooks/useBestTrade.ts b/src/hooks/useBestTrade.ts index 2250337fff..f362514c01 100644 --- a/src/hooks/useBestTrade.ts +++ b/src/hooks/useBestTrade.ts @@ -3,8 +3,7 @@ import { useWeb3React } from '@web3-react/core' import { WRAPPED_NATIVE_CURRENCY } from 'constants/tokens' import { DebounceSwapQuoteVariant, useDebounceSwapQuoteFlag } from 'featureFlags/flags/debounceSwapQuote' import { useMemo } from 'react' -import { RouterPreference } from 'state/routing/types' -import { ClassicTrade, InterfaceTrade, QuoteMethod, TradeState } from 'state/routing/types' +import { ClassicTrade, InterfaceTrade, QuoteMethod, RouterPreference, TradeState } from 'state/routing/types' import { useRoutingAPITrade } from 'state/routing/useRoutingAPITrade' import { useRouterPreference } from 'state/user/hooks' diff --git a/src/hooks/useFeeTierDistribution.ts b/src/hooks/useFeeTierDistribution.ts index b876b818dd..678d605993 100644 --- a/src/hooks/useFeeTierDistribution.ts +++ b/src/hooks/useFeeTierDistribution.ts @@ -1,7 +1,7 @@ import { Currency, Token } from '@uniswap/sdk-core' import { FeeAmount } from '@uniswap/v3-sdk' import useBlockNumber from 'lib/hooks/useBlockNumber' -import ms from 'ms.macro' +import ms from 'ms' import { useMemo } from 'react' import useFeeTierDistributionQuery from '../graphql/thegraph/FeeTierDistributionQuery' @@ -75,7 +75,7 @@ export function useFeeTierDistribution( function usePoolTVL(token0: Token | undefined, token1: Token | undefined) { const latestBlock = useBlockNumber() - const { isLoading, error, data } = useFeeTierDistributionQuery(token0?.address, token1?.address, ms`30s`) + const { isLoading, error, data } = useFeeTierDistributionQuery(token0?.address, token1?.address, ms(`30s`)) const { asToken0, asToken1, _meta } = data ?? {} diff --git a/src/hooks/usePermitAllowance.ts b/src/hooks/usePermitAllowance.ts index cc311f2643..996e7cfe33 100644 --- a/src/hooks/usePermitAllowance.ts +++ b/src/hooks/usePermitAllowance.ts @@ -6,13 +6,13 @@ import PERMIT2_ABI from 'abis/permit2.json' import { Permit2 } from 'abis/types' import { useContract } from 'hooks/useContract' import { useSingleCallResult } from 'lib/hooks/multicall' -import ms from 'ms.macro' +import ms from 'ms' import { useCallback, useEffect, useMemo, useState } from 'react' import { toReadableError, UserRejectedRequestError } from 'utils/errors' import { didUserReject } from 'utils/swapErrorToUserReadableMessage' -const PERMIT_EXPIRATION = ms`30d` -const PERMIT_SIG_EXPIRATION = ms`30m` +const PERMIT_EXPIRATION = ms(`30d`) +const PERMIT_SIG_EXPIRATION = ms(`30m`) function toDeadline(expiration: number): number { return Math.floor((Date.now() + expiration) / 1000) diff --git a/src/hooks/usePoolTickData.ts b/src/hooks/usePoolTickData.ts index f01b7574c0..07504f8de5 100644 --- a/src/hooks/usePoolTickData.ts +++ b/src/hooks/usePoolTickData.ts @@ -7,7 +7,7 @@ import { TickData, Ticks } from 'graphql/thegraph/AllV3TicksQuery' import { apolloClient } from 'graphql/thegraph/apollo' import JSBI from 'jsbi' import { useSingleContractMultipleData } from 'lib/hooks/multicall' -import ms from 'ms.macro' +import ms from 'ms' import { useEffect, useMemo, useState } from 'react' import computeSurroundingTicks from 'utils/computeSurroundingTicks' @@ -158,7 +158,7 @@ function useTicksFromSubgraph( return useAllV3TicksQuery({ variables: { poolAddress: poolAddress?.toLowerCase(), skip }, skip: !poolAddress, - pollInterval: ms`30s`, + pollInterval: ms(`30s`), client: apolloClient, }) } diff --git a/src/hooks/useStablecoinPrice.ts b/src/hooks/useStablecoinPrice.ts index c201e0ffe8..9795db6828 100644 --- a/src/hooks/useStablecoinPrice.ts +++ b/src/hooks/useStablecoinPrice.ts @@ -2,7 +2,7 @@ import { ChainId, Currency, CurrencyAmount, Price, Token, TradeType } from '@uni import { useWeb3React } from '@web3-react/core' import tryParseCurrencyAmount from 'lib/utils/tryParseCurrencyAmount' import { useMemo, useRef } from 'react' -import { INTERNAL_ROUTER_PREFERENCE_PRICE } from 'state/routing/slice' +import { INTERNAL_ROUTER_PREFERENCE_PRICE } from 'state/routing/types' import { useRoutingAPITrade } from 'state/routing/useRoutingAPITrade' import { diff --git a/src/hooks/useTokenWarningColor.ts b/src/hooks/useTokenWarningColor.ts index bc04911101..6bc26a19b8 100644 --- a/src/hooks/useTokenWarningColor.ts +++ b/src/hooks/useTokenWarningColor.ts @@ -1,5 +1,5 @@ import { WARNING_LEVEL } from 'constants/tokenSafety' -import { useTheme } from 'styled-components/macro' +import { useTheme } from 'styled-components' export const useTokenWarningTextColor = (level: WARNING_LEVEL) => { const theme = useTheme() diff --git a/src/hooks/useUSDPrice.ts b/src/hooks/useUSDPrice.ts index fe865ed13c..ac65bb7aae 100644 --- a/src/hooks/useUSDPrice.ts +++ b/src/hooks/useUSDPrice.ts @@ -3,8 +3,7 @@ import { ChainId, Currency, CurrencyAmount, Price, TradeType } from '@uniswap/sd import { nativeOnChain } from 'constants/tokens' import { Chain, useTokenSpotPriceQuery } from 'graphql/data/__generated__/types-and-hooks' import { chainIdToBackendName, isGqlSupportedChain, PollingInterval } from 'graphql/data/util' -import { INTERNAL_ROUTER_PREFERENCE_PRICE } from 'state/routing/slice' -import { TradeState } from 'state/routing/types' +import { INTERNAL_ROUTER_PREFERENCE_PRICE, TradeState } from 'state/routing/types' import { useRoutingAPITrade } from 'state/routing/useRoutingAPITrade' import { getNativeTokenDBAddress } from 'utils/nativeTokens' diff --git a/src/i18n.tsx b/src/i18n.tsx index 7eb5396edb..e47a819876 100644 --- a/src/i18n.tsx +++ b/src/i18n.tsx @@ -19,7 +19,7 @@ export function LanguageProvider({ children }: { children: ReactNode }) { ) return ( - + {children} ) diff --git a/src/lib/hooks/orders/updater.tsx b/src/lib/hooks/orders/updater.tsx index 11ee0bfff0..a7149e58c6 100644 --- a/src/lib/hooks/orders/updater.tsx +++ b/src/lib/hooks/orders/updater.tsx @@ -1,5 +1,5 @@ import { useWeb3React } from '@web3-react/core' -import ms from 'ms.macro' +import ms from 'ms' import { useEffect } from 'react' import { isFinalizedOrder } from 'state/signatures/hooks' import { UniswapXOrderDetails } from 'state/signatures/types' @@ -16,7 +16,7 @@ function fetchOrderStatuses(account: string, orders: UniswapXOrderDetails[]) { return global.fetch(`${UNISWAP_API_URL}/orders?swapper=${account}&orderHashes=${orderHashes}`) } -const OFF_CHAIN_ORDER_STATUS_POLLING = ms`2s` // every 2 seconds +const OFF_CHAIN_ORDER_STATUS_POLLING = ms(`2s`) interface UpdaterProps { pendingOrders: UniswapXOrderDetails[] diff --git a/src/lib/hooks/routing/clientSideSmartOrderRouter.ts b/src/lib/hooks/routing/clientSideSmartOrderRouter.ts index 1b33e83fcc..ddc1db7955 100644 --- a/src/lib/hooks/routing/clientSideSmartOrderRouter.ts +++ b/src/lib/hooks/routing/clientSideSmartOrderRouter.ts @@ -4,8 +4,7 @@ import { BigintIsh, CurrencyAmount, Token, TradeType } from '@uniswap/sdk-core' import { AlphaRouter, AlphaRouterConfig } from '@uniswap/smart-order-router' import { nativeOnChain } from 'constants/tokens' import JSBI from 'jsbi' -import { GetQuoteArgs } from 'state/routing/slice' -import { QuoteResult, QuoteState, SwapRouterNativeAssets } from 'state/routing/types' +import { GetQuoteArgs, QuoteResult, QuoteState, SwapRouterNativeAssets } from 'state/routing/types' import { transformSwapRouteToGetQuoteResult } from 'utils/transformSwapRouteToGetQuoteResult' async function getQuote( diff --git a/src/lib/hooks/routing/useRoutingAPIArguments.ts b/src/lib/hooks/routing/useRoutingAPIArguments.ts index 64485c2c6a..01ad0a3994 100644 --- a/src/lib/hooks/routing/useRoutingAPIArguments.ts +++ b/src/lib/hooks/routing/useRoutingAPIArguments.ts @@ -5,8 +5,7 @@ import { useUniswapXEnabled } from 'featureFlags/flags/uniswapx' import { useUniswapXEthOutputEnabled } from 'featureFlags/flags/uniswapXEthOutput' import { useUniswapXSyntheticQuoteEnabled } from 'featureFlags/flags/uniswapXUseSyntheticQuote' import { useMemo } from 'react' -import { GetQuoteArgs, INTERNAL_ROUTER_PREFERENCE_PRICE } from 'state/routing/slice' -import { RouterPreference } from 'state/routing/types' +import { GetQuoteArgs, INTERNAL_ROUTER_PREFERENCE_PRICE, RouterPreference } from 'state/routing/types' import { currencyAddressForSwapQuote } from 'state/routing/utils' import { useUserDisabledUniswapX } from 'state/user/hooks' diff --git a/src/lib/hooks/transactions/updater.tsx b/src/lib/hooks/transactions/updater.tsx index add3a3dcd5..a27e24bacb 100644 --- a/src/lib/hooks/transactions/updater.tsx +++ b/src/lib/hooks/transactions/updater.tsx @@ -3,7 +3,7 @@ import { ChainId } from '@uniswap/sdk-core' import { useWeb3React } from '@web3-react/core' import useCurrentBlockTimestamp from 'hooks/useCurrentBlockTimestamp' import useBlockNumber, { useFastForwardBlockNumber } from 'lib/hooks/useBlockNumber' -import ms from 'ms.macro' +import ms from 'ms' import { useCallback, useEffect } from 'react' import { useTransactionRemover } from 'state/transactions/hooks' import { TransactionDetails } from 'state/transactions/types' @@ -21,7 +21,7 @@ export function shouldCheck(lastBlockNumber: number, tx: Transaction): boolean { if (!tx.lastCheckedBlockNumber) return true const blocksSinceCheck = lastBlockNumber - tx.lastCheckedBlockNumber if (blocksSinceCheck < 1) return false - const minutesPending = (new Date().getTime() - tx.addedTime) / ms`1m` + const minutesPending = (new Date().getTime() - tx.addedTime) / ms(`1m`) if (minutesPending > 60) { // every 10 blocks if pending longer than an hour return blocksSinceCheck > 9 @@ -72,7 +72,7 @@ export default function Updater({ pendingTransactions, onCheck, onReceipt }: Upd if (blockTimestamp && tx.deadline < blockTimestamp.toNumber()) { removeTransaction(hash) } - } else if (tx.addedTime + ms`6h` < Date.now()) { + } else if (tx.addedTime + ms(`6h`) < Date.now()) { removeTransaction(hash) } } diff --git a/src/lib/i18n.tsx b/src/lib/i18n.tsx index c0ebbda6dc..bc302c791b 100644 --- a/src/lib/i18n.tsx +++ b/src/lib/i18n.tsx @@ -1,83 +1,15 @@ import { i18n } from '@lingui/core' import { I18nProvider } from '@lingui/react' -import { DEFAULT_LOCALE, SupportedLocale } from 'constants/locales' -import { - af, - ar, - ca, - cs, - da, - de, - el, - en, - es, - fi, - fr, - he, - hu, - id, - it, - ja, - ko, - nl, - no, - pl, - pt, - ro, - ru, - sr, - sv, - sw, - tr, - uk, - vi, - zh, -} from 'make-plural/plurals' -import { PluralCategory } from 'make-plural/plurals' +import { DEFAULT_LOCALE, DEFAULT_MESSAGES, SupportedLocale } from 'constants/locales' import { ReactNode, useEffect } from 'react' -type LocalePlural = { - [key in SupportedLocale]: (n: number | string, ord?: boolean) => PluralCategory -} - -const plurals: LocalePlural = { - 'af-ZA': af, - 'ar-SA': ar, - 'ca-ES': ca, - 'cs-CZ': cs, - 'da-DK': da, - 'de-DE': de, - 'el-GR': el, - 'en-US': en, - 'es-ES': es, - 'fi-FI': fi, - 'fr-FR': fr, - 'he-IL': he, - 'hu-HU': hu, - 'id-ID': id, - 'it-IT': it, - 'ja-JP': ja, - 'ko-KR': ko, - 'nl-NL': nl, - 'no-NO': no, - 'pl-PL': pl, - 'pt-BR': pt, - 'pt-PT': pt, - 'ro-RO': ro, - 'ru-RU': ru, - 'sr-SP': sr, - 'sv-SE': sv, - 'sw-TZ': sw, - 'tr-TR': tr, - 'uk-UA': uk, - 'vi-VN': vi, - 'zh-CN': zh, - 'zh-TW': zh, - pseudo: en, -} +// Initialize the locale immediately to DEFAULT_LOCALE/DEFAULT_MESSAGES, +// so that messages are shown while the appropriate translation load. +// This is necessary for initial macro translations (t``) to work in the DEFAULT_LOCALE. +i18n.load(DEFAULT_LOCALE, DEFAULT_MESSAGES) +i18n.activate(DEFAULT_LOCALE) export async function dynamicActivate(locale: SupportedLocale) { - i18n.loadLocaleData(locale, { plurals: () => plurals[locale] }) try { const catalog = await import(`locales/${locale}.js`) // Bundlers will either export it as default or as a named export named default. @@ -90,12 +22,11 @@ export async function dynamicActivate(locale: SupportedLocale) { interface ProviderProps { locale: SupportedLocale - forceRenderAfterLocaleChange?: boolean onActivate?: (locale: SupportedLocale) => void children: ReactNode } -export function Provider({ locale, forceRenderAfterLocaleChange = true, onActivate, children }: ProviderProps) { +export function Provider({ locale, onActivate, children }: ProviderProps) { useEffect(() => { dynamicActivate(locale) .then(() => onActivate?.(locale)) @@ -104,19 +35,5 @@ export function Provider({ locale, forceRenderAfterLocaleChange = true, onActiva }) }, [locale, onActivate]) - // Initialize the locale immediately if it is DEFAULT_LOCALE, so that keys are shown while the translation messages load. - // This renders the translation _keys_, not the translation _messages_, which is only acceptable while loading the DEFAULT_LOCALE, - // as [there are no "default" messages](https://github.com/lingui/js-lingui/issues/388#issuecomment-497779030). - // See https://github.com/lingui/js-lingui/issues/1194#issuecomment-1068488619. - if (i18n.locale === undefined && locale === DEFAULT_LOCALE) { - i18n.loadLocaleData(DEFAULT_LOCALE, { plurals: () => plurals[DEFAULT_LOCALE] }) - i18n.load(DEFAULT_LOCALE, {}) - i18n.activate(DEFAULT_LOCALE) - } - - return ( - - {children} - - ) + return {children} } diff --git a/src/nft/components/bag/Bag.tsx b/src/nft/components/bag/Bag.tsx index 0b0025f9ca..cc05f08a83 100644 --- a/src/nft/components/bag/Bag.tsx +++ b/src/nft/components/bag/Bag.tsx @@ -11,7 +11,7 @@ import { useBag, useIsMobile, useProfilePageState, useSellAsset, useSubscribeScr import { BagStatus, ProfilePageStateType } from 'nft/types' import { formatAssetEventProperties, recalculateBagUsingPooledAssets } from 'nft/utils' import { useCallback, useEffect, useMemo, useState } from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { Z_INDEX } from 'theme/zIndex' import { shallow } from 'zustand/shallow' diff --git a/src/nft/components/bag/BagFooter.tsx b/src/nft/components/bag/BagFooter.tsx index b1f0daaee1..e36c3b3e6f 100644 --- a/src/nft/components/bag/BagFooter.tsx +++ b/src/nft/components/bag/BagFooter.tsx @@ -35,7 +35,7 @@ import { ethNumberStandardFormatter, formatWeiToDecimal } from 'nft/utils' import { PropsWithChildren, useEffect, useMemo, useState } from 'react' import { AlertTriangle, ChevronDown } from 'react-feather' import { InterfaceTrade, TradeFillType, TradeState } from 'state/routing/types' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import { ThemedText } from 'theme' import { shallow } from 'zustand/shallow' diff --git a/src/nft/components/bag/BagHeader.tsx b/src/nft/components/bag/BagHeader.tsx index 28cc62de4e..b4a33c7bf3 100644 --- a/src/nft/components/bag/BagHeader.tsx +++ b/src/nft/components/bag/BagHeader.tsx @@ -2,7 +2,7 @@ import { Trans } from '@lingui/macro' import { OpacityHoverState } from 'components/Common' import { BagCloseIcon } from 'nft/components/icons' import { useMemo } from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ButtonText, ThemedText } from 'theme' const ClearButton = styled(ButtonText)` diff --git a/src/nft/components/bag/BagRow.tsx b/src/nft/components/bag/BagRow.tsx index 74347d326c..a2f01cb70d 100644 --- a/src/nft/components/bag/BagRow.tsx +++ b/src/nft/components/bag/BagRow.tsx @@ -21,7 +21,7 @@ import { GenieAsset, UpdatedGenieAsset } from 'nft/types' import { ethNumberStandardFormatter, formatWeiToDecimal, getAssetHref } from 'nft/utils' import { MouseEvent, useCallback, useEffect, useReducer, useState } from 'react' import { Link } from 'react-router-dom' -import styled from 'styled-components/macro' +import styled from 'styled-components' import * as styles from './BagRow.css' diff --git a/src/nft/components/bag/ButtonStates.tsx b/src/nft/components/bag/ButtonStates.tsx index 01b80c3ee2..59a5d79e7a 100644 --- a/src/nft/components/bag/ButtonStates.tsx +++ b/src/nft/components/bag/ButtonStates.tsx @@ -1,7 +1,7 @@ import { Trans } from '@lingui/macro' import { PriceImpact } from 'nft/hooks/usePriceImpact' import { ReactNode } from 'react' -import { DefaultTheme } from 'styled-components/macro' +import { DefaultTheme } from 'styled-components' export enum BuyButtonStates { WALLET_NOT_CONNECTED, diff --git a/src/nft/components/bag/EmptyContent.tsx b/src/nft/components/bag/EmptyContent.tsx index aae98f9c2d..3ca1b16038 100644 --- a/src/nft/components/bag/EmptyContent.tsx +++ b/src/nft/components/bag/EmptyContent.tsx @@ -3,7 +3,7 @@ import { Center, Column } from 'nft/components/Flex' import { BagIcon, LargeTagIcon } from 'nft/components/icons' import { subhead } from 'nft/css/common.css' import { themeVars } from 'nft/css/sprinkles.css' -import styled from 'styled-components/macro' +import styled from 'styled-components' const StyledColumn = styled(Column)` gap: 12px; diff --git a/src/nft/components/bag/TimedLoader.tsx b/src/nft/components/bag/TimedLoader.tsx index 005d82b0f3..6356f3f4a1 100644 --- a/src/nft/components/bag/TimedLoader.tsx +++ b/src/nft/components/bag/TimedLoader.tsx @@ -1,5 +1,5 @@ import { Box } from 'nft/components/Box' -import styled, { keyframes } from 'styled-components/macro' +import styled, { keyframes } from 'styled-components' const dash = keyframes` 0% { diff --git a/src/nft/components/card/containers.tsx b/src/nft/components/card/containers.tsx index e972d8af00..a97db697d1 100644 --- a/src/nft/components/card/containers.tsx +++ b/src/nft/components/card/containers.tsx @@ -3,7 +3,7 @@ import Row from 'components/Row' import { StyledImage } from 'nft/components/card/media' import { ReactNode } from 'react' import { Link } from 'react-router-dom' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { BREAKPOINTS, ThemedText } from 'theme' const BORDER_RADIUS = '12' diff --git a/src/nft/components/card/icons.tsx b/src/nft/components/card/icons.tsx index 4646b49b2c..8ab7d169f6 100644 --- a/src/nft/components/card/icons.tsx +++ b/src/nft/components/card/icons.tsx @@ -7,7 +7,7 @@ import { CollectionSelectedAssetIcon } from 'nft/components/icons' import { Markets } from 'nft/types' import { putCommas } from 'nft/utils' import { AlertTriangle, Check, Tag } from 'react-feather' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ThemedText } from 'theme' const StyledMarketplaceContainer = styled.div<{ isText?: boolean }>` diff --git a/src/nft/components/card/media.tsx b/src/nft/components/card/media.tsx index d4120050ca..d22689d84e 100644 --- a/src/nft/components/card/media.tsx +++ b/src/nft/components/card/media.tsx @@ -4,7 +4,7 @@ import { getHeightFromAspectRatio, getMediaAspectRatio, handleUniformAspectRatio import { UniformAspectRatio, UniformAspectRatios } from 'nft/types' import { ReactNode, useEffect, useRef, useState } from 'react' import { Pause, Play } from 'react-feather' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { BREAKPOINTS, ThemedText } from 'theme' import { colors } from 'theme/colors' diff --git a/src/nft/components/collection/Activity.tsx b/src/nft/components/collection/Activity.tsx index cadbfcb1d3..dcbff204e3 100644 --- a/src/nft/components/collection/Activity.tsx +++ b/src/nft/components/collection/Activity.tsx @@ -10,7 +10,7 @@ import { fetchPrice } from 'nft/utils/fetchPrice' import { useCallback, useEffect, useReducer, useState } from 'react' import InfiniteScroll from 'react-infinite-scroll-component' import { Link } from 'react-router-dom' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { useIsDarkMode } from 'theme/components/ThemeToggle' import * as styles from './Activity.css' diff --git a/src/nft/components/collection/ActivityCells.tsx b/src/nft/components/collection/ActivityCells.tsx index 71b4ffb194..012e32d445 100644 --- a/src/nft/components/collection/ActivityCells.tsx +++ b/src/nft/components/collection/ActivityCells.tsx @@ -30,7 +30,7 @@ import { formatEth } from 'nft/utils/currency' import { getTimeDifference } from 'nft/utils/date' import { putCommas } from 'nft/utils/putCommas' import { MouseEvent, ReactNode, useMemo, useState } from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ExternalLink } from 'theme' import { shortenAddress } from 'utils' import { ExplorerDataType, getExplorerLink } from 'utils/getExplorerLink' diff --git a/src/nft/components/collection/ActivitySwitcher.tsx b/src/nft/components/collection/ActivitySwitcher.tsx index 9bd881dcae..1a67cfa6bc 100644 --- a/src/nft/components/collection/ActivitySwitcher.tsx +++ b/src/nft/components/collection/ActivitySwitcher.tsx @@ -3,7 +3,7 @@ import { TraceEvent } from 'analytics' import { Box } from 'nft/components/Box' import { Row } from 'nft/components/Flex' import { useIsCollectionLoading } from 'nft/hooks' -import styled from 'styled-components/macro' +import styled from 'styled-components' import * as styles from './ActivitySwitcher.css' diff --git a/src/nft/components/collection/CollectionNfts.tsx b/src/nft/components/collection/CollectionNfts.tsx index 5383458b4a..4de9bc92bd 100644 --- a/src/nft/components/collection/CollectionNfts.tsx +++ b/src/nft/components/collection/CollectionNfts.tsx @@ -52,7 +52,7 @@ import { applyFiltersFromURL, syncLocalFiltersWithURL } from 'nft/utils/urlParam import { useCallback, useEffect, useMemo, useRef, useState } from 'react' import InfiniteScroll from 'react-infinite-scroll-component' import { useLocation } from 'react-router-dom' -import styled, { css } from 'styled-components/macro' +import styled, { css } from 'styled-components' import { ThemedText } from 'theme' import { LoadingAssets } from './CollectionAssetLoading' diff --git a/src/nft/components/collection/CollectionPageSkeleton.tsx b/src/nft/components/collection/CollectionPageSkeleton.tsx index 2906e8ed5b..8931540f15 100644 --- a/src/nft/components/collection/CollectionPageSkeleton.tsx +++ b/src/nft/components/collection/CollectionPageSkeleton.tsx @@ -4,7 +4,7 @@ import { BAG_WIDTH, XXXL_BAG_WIDTH } from 'nft/components/bag/Bag' import { useBag, useIsMobile } from 'nft/hooks' import { BannerWrapper, CollectionBannerLoading } from 'nft/pages/collection' import { ScreenBreakpointsPaddings } from 'nft/pages/collection/index.css' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ActivitySwitcherLoading } from './ActivitySwitcher' import { CollectionNftsAndMenuLoading } from './CollectionNfts' diff --git a/src/nft/components/collection/CollectionStats.tsx b/src/nft/components/collection/CollectionStats.tsx index 464450dc0c..50bbdbd3cf 100644 --- a/src/nft/components/collection/CollectionStats.tsx +++ b/src/nft/components/collection/CollectionStats.tsx @@ -11,7 +11,7 @@ import { GenieCollection, TokenType } from 'nft/types' import { floorFormatter, quantityFormatter, roundWholePercentage, volumeFormatter } from 'nft/utils/numbers' import { ReactNode, useEffect, useReducer, useRef, useState } from 'react' import ReactMarkdown from 'react-markdown' -import styled, { css } from 'styled-components/macro' +import styled, { css } from 'styled-components' import { ThemedText } from 'theme' import { DiscordIcon, EllipsisIcon, ExternalIcon, InstagramIcon, TwitterIcon, VerifiedIcon, XMarkIcon } from '../icons' diff --git a/src/nft/components/collection/MarketplaceSelect.tsx b/src/nft/components/collection/MarketplaceSelect.tsx index 3fef8e7a01..59af086195 100644 --- a/src/nft/components/collection/MarketplaceSelect.tsx +++ b/src/nft/components/collection/MarketplaceSelect.tsx @@ -10,7 +10,7 @@ import { useCollectionFilters } from 'nft/hooks/useCollectionFilters' import { TraitPosition, useTraitsOpen } from 'nft/hooks/useTraitsOpen' import { getMarketplaceIcon } from 'nft/utils' import { FormEvent, useEffect, useMemo, useReducer, useState } from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ThemedText } from 'theme' import { Checkbox } from '../layout/Checkbox' diff --git a/src/nft/components/collection/PriceRange.tsx b/src/nft/components/collection/PriceRange.tsx index db4db1d0e0..ae55f79d7b 100644 --- a/src/nft/components/collection/PriceRange.tsx +++ b/src/nft/components/collection/PriceRange.tsx @@ -13,7 +13,7 @@ import { scrollToTop } from 'nft/utils/scrollToTop' import { default as Slider } from 'rc-slider' import { FocusEventHandler, FormEvent, useEffect, useState } from 'react' import { useLocation } from 'react-router-dom' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import { darkTheme } from 'theme/colors' import * as styles from './PriceRange.css' diff --git a/src/nft/components/collection/Sweep.tsx b/src/nft/components/collection/Sweep.tsx index 35a056d3dc..4e49d12605 100644 --- a/src/nft/components/collection/Sweep.tsx +++ b/src/nft/components/collection/Sweep.tsx @@ -9,7 +9,7 @@ import { GenieAsset, isPooledMarket, Markets } from 'nft/types' import { calcPoolPrice, formatWeiToDecimal, isInSameSudoSwapPool } from 'nft/utils' import { default as Slider } from 'rc-slider' import { useEffect, useMemo, useReducer, useState } from 'react' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import { ThemedText } from 'theme' const SweepContainer = styled.div` diff --git a/src/nft/components/collection/TraitChip.tsx b/src/nft/components/collection/TraitChip.tsx index 34621a842a..dcbf92d1a6 100644 --- a/src/nft/components/collection/TraitChip.tsx +++ b/src/nft/components/collection/TraitChip.tsx @@ -1,5 +1,5 @@ import { CrossIcon } from 'nft/components/icons' -import styled from 'styled-components/macro' +import styled from 'styled-components' const TraitChipWrap = styled.div` display: flex; diff --git a/src/nft/components/collection/TraitsHeader.tsx b/src/nft/components/collection/TraitsHeader.tsx index 2453bc0749..c7db9d28f7 100644 --- a/src/nft/components/collection/TraitsHeader.tsx +++ b/src/nft/components/collection/TraitsHeader.tsx @@ -6,7 +6,7 @@ import { subheadSmall } from 'nft/css/common.css' import { useIsMobile } from 'nft/hooks' import { TraitPosition, useTraitsOpen } from 'nft/hooks/useTraitsOpen' import { ReactNode, useEffect, useState } from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' const ChildreMobileWrapper = styled.div<{ isMobile: boolean }>` padding: ${({ isMobile }) => (isMobile ? '0px 16px 0px 12px' : '0px')}; diff --git a/src/nft/components/collection/TransactionCompleteModal.tsx b/src/nft/components/collection/TransactionCompleteModal.tsx index d106841326..1c419ef37d 100644 --- a/src/nft/components/collection/TransactionCompleteModal.tsx +++ b/src/nft/components/collection/TransactionCompleteModal.tsx @@ -23,7 +23,7 @@ import { } from 'nft/utils' import { formatAssetEventProperties } from 'nft/utils/formatEventProperties' import { useEffect, useMemo, useRef, useState } from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ExplorerDataType, getExplorerLink } from 'utils/getExplorerLink' import * as styles from './TransactionCompleteModal.css' diff --git a/src/nft/components/collection/__snapshots__/CollectionAsset.test.tsx.snap b/src/nft/components/collection/__snapshots__/CollectionAsset.test.tsx.snap index 3ed44c8d12..5c75dd2383 100644 --- a/src/nft/components/collection/__snapshots__/CollectionAsset.test.tsx.snap +++ b/src/nft/components/collection/__snapshots__/CollectionAsset.test.tsx.snap @@ -379,10 +379,10 @@ exports[`NftCard renders correctly 1`] = ` class="c4 c5 c20" >
15.8 ETH
diff --git a/src/nft/components/collection/shared.tsx b/src/nft/components/collection/shared.tsx index 6b0515f73f..0fb6130d27 100644 --- a/src/nft/components/collection/shared.tsx +++ b/src/nft/components/collection/shared.tsx @@ -1,4 +1,4 @@ -import styled from 'styled-components/macro' +import styled from 'styled-components' export const ClearAllButton = styled.button` color: ${({ theme }) => theme.textTertiary}; diff --git a/src/nft/components/details/AssetActivity.tsx b/src/nft/components/details/AssetActivity.tsx index 566d4f4539..8cf98a84ec 100644 --- a/src/nft/components/details/AssetActivity.tsx +++ b/src/nft/components/details/AssetActivity.tsx @@ -7,7 +7,7 @@ import { getMarketplaceIcon } from 'nft/utils' import { formatEth } from 'nft/utils/currency' import { getTimeDifference } from 'nft/utils/date' import { ReactNode } from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { shortenAddress } from 'utils' const TR = styled.tr` diff --git a/src/nft/components/details/AssetDetails.tsx b/src/nft/components/details/AssetDetails.tsx index 2fdecef780..534af938bf 100644 --- a/src/nft/components/details/AssetDetails.tsx +++ b/src/nft/components/details/AssetDetails.tsx @@ -17,7 +17,7 @@ import { putCommas } from 'nft/utils/putCommas' import { useCallback, useMemo, useReducer, useState } from 'react' import InfiniteScroll from 'react-infinite-scroll-component' import { Link as RouterLink } from 'react-router-dom' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { useIsDarkMode } from 'theme/components/ThemeToggle' import { shortenAddress } from 'utils/addresses' diff --git a/src/nft/components/details/AssetDetailsLoading.tsx b/src/nft/components/details/AssetDetailsLoading.tsx index 06ed3464e0..841cc55146 100644 --- a/src/nft/components/details/AssetDetailsLoading.tsx +++ b/src/nft/components/details/AssetDetailsLoading.tsx @@ -2,7 +2,7 @@ import Column from 'components/Column' import Loader from 'components/Icons/LoadingSpinner' import { LoadingBubble } from 'components/Tokens/loading' import { ScreenBreakpointsPaddings } from 'nft/pages/collection/index.css' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' const BREAKPOINT = '960px' diff --git a/src/nft/components/details/AssetPriceDetails.tsx b/src/nft/components/details/AssetPriceDetails.tsx index 84b91f9e0d..172cc5bd00 100644 --- a/src/nft/components/details/AssetPriceDetails.tsx +++ b/src/nft/components/details/AssetPriceDetails.tsx @@ -19,7 +19,7 @@ import { useMemo } from 'react' import { Upload } from 'react-feather' import { useQuery } from 'react-query' import { Link, useNavigate } from 'react-router-dom' -import styled, { css, useTheme } from 'styled-components/macro' +import styled, { css, useTheme } from 'styled-components' import { ExternalLink, ThemedText } from 'theme' import { shortenAddress } from 'utils/addresses' diff --git a/src/nft/components/details/DetailsContainer.tsx b/src/nft/components/details/DetailsContainer.tsx index 8a1e607d8e..d9b89e8be2 100644 --- a/src/nft/components/details/DetailsContainer.tsx +++ b/src/nft/components/details/DetailsContainer.tsx @@ -4,7 +4,7 @@ import { CollectionInfoForAsset, GenieAsset } from 'nft/types' import { putCommas } from 'nft/utils' import { useCallback } from 'react' import { Copy } from 'react-feather' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { shortenAddress } from 'utils' const Details = styled.div` diff --git a/src/nft/components/details/InfoContainer.tsx b/src/nft/components/details/InfoContainer.tsx index cc2e7f9a47..eb52cdcb24 100644 --- a/src/nft/components/details/InfoContainer.tsx +++ b/src/nft/components/details/InfoContainer.tsx @@ -1,6 +1,6 @@ import { useState } from 'react' import { ChevronDown, ChevronUp } from 'react-feather' -import styled, { css } from 'styled-components/macro' +import styled, { css } from 'styled-components' const Header = styled.div<{ isOpen: boolean }>` display: flex; diff --git a/src/nft/components/details/TraitsContainer.tsx b/src/nft/components/details/TraitsContainer.tsx index 02798c665c..f1c81421a1 100644 --- a/src/nft/components/details/TraitsContainer.tsx +++ b/src/nft/components/details/TraitsContainer.tsx @@ -3,7 +3,7 @@ import { GenieAsset, Trait } from 'nft/types' import qs from 'query-string' import { useMemo } from 'react' import { Link } from 'react-router-dom' -import styled from 'styled-components/macro' +import styled from 'styled-components' const Grid = styled.div` display: grid; diff --git a/src/nft/components/explore/Banner.tsx b/src/nft/components/explore/Banner.tsx index 26a7d6d542..b794391600 100644 --- a/src/nft/components/explore/Banner.tsx +++ b/src/nft/components/explore/Banner.tsx @@ -3,7 +3,7 @@ import { useTrendingCollections } from 'graphql/data/nft/TrendingCollections' import { calculateCardIndex } from 'nft/utils' import { useCallback, useMemo, useState } from 'react' import { useNavigate } from 'react-router-dom' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { opacify } from 'theme/utils' import { Carousel, LoadingCarousel } from './Carousel' diff --git a/src/nft/components/explore/Carousel.tsx b/src/nft/components/explore/Carousel.tsx index 5cc39c1268..19b03346ed 100644 --- a/src/nft/components/explore/Carousel.tsx +++ b/src/nft/components/explore/Carousel.tsx @@ -2,7 +2,7 @@ import { ChevronLeftIcon, ChevronRightIcon } from 'nft/components/icons' import { calculateCardIndex, calculateFirstCardIndex, calculateRank } from 'nft/utils' import { ReactNode, useCallback, useEffect, useRef } from 'react' import { a, useSprings } from 'react-spring' -import styled from 'styled-components/macro' +import styled from 'styled-components' const CarouselContainer = styled.div` display: flex; diff --git a/src/nft/components/explore/CarouselCard.tsx b/src/nft/components/explore/CarouselCard.tsx index 91891cde2d..f10983b405 100644 --- a/src/nft/components/explore/CarouselCard.tsx +++ b/src/nft/components/explore/CarouselCard.tsx @@ -5,7 +5,7 @@ import { useCollection } from 'graphql/data/nft/Collection' import { UniswapMagentaIcon, VerifiedIcon } from 'nft/components/icons' import { Markets, TrendingCollection } from 'nft/types' import { ethNumberStandardFormatter } from 'nft/utils' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ThemedText } from 'theme/components/text' const CarouselCardBorder = styled.div` diff --git a/src/nft/components/explore/Cells/Cells.tsx b/src/nft/components/explore/Cells/Cells.tsx index 7486b9d4cb..ac4e647008 100644 --- a/src/nft/components/explore/Cells/Cells.tsx +++ b/src/nft/components/explore/Cells/Cells.tsx @@ -4,7 +4,7 @@ import { useIsMobile } from 'nft/hooks' import { Denomination } from 'nft/types' import { ethNumberStandardFormatter, volumeFormatter } from 'nft/utils' import { ReactNode } from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ThemedText } from 'theme' import * as styles from './Cells.css' diff --git a/src/nft/components/explore/Table.tsx b/src/nft/components/explore/Table.tsx index 7a2e630830..5aaa0419cf 100644 --- a/src/nft/components/explore/Table.tsx +++ b/src/nft/components/explore/Table.tsx @@ -7,7 +7,7 @@ import { useIsMobile } from 'nft/hooks' import { useEffect } from 'react' import { useNavigate } from 'react-router-dom' import { Column, ColumnInstance, HeaderGroup, IdType, useSortBy, useTable } from 'react-table' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import { GlowEffect, ThemedText } from 'theme' import { Box } from '../../components/Box' diff --git a/src/nft/components/explore/TrendingCollections.tsx b/src/nft/components/explore/TrendingCollections.tsx index 6beb23277d..543c2b9578 100644 --- a/src/nft/components/explore/TrendingCollections.tsx +++ b/src/nft/components/explore/TrendingCollections.tsx @@ -1,12 +1,12 @@ import { OpacityHoverState } from 'components/Common' import { HistoryDuration } from 'graphql/data/__generated__/types-and-hooks' import { useTrendingCollections } from 'graphql/data/nft/TrendingCollections' -import ms from 'ms.macro' +import ms from 'ms' import { CollectionTableColumn, Denomination, TimePeriod, VolumeType } from 'nft/types' import { fetchPrice } from 'nft/utils' import { useMemo, useState } from 'react' import { useQuery } from 'react-query' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ThemedText } from 'theme' import CollectionTable from './CollectionTable' @@ -98,7 +98,7 @@ const TrendingCollections = () => { refetchOnReconnect: false, refetchOnWindowFocus: false, refetchOnMount: false, - refetchInterval: ms`1m`, + refetchInterval: ms(`1m`), }) const trendingCollectionColumns = useMemo(() => { diff --git a/src/nft/components/icons.tsx b/src/nft/components/icons.tsx index 70c6126edf..9706cbbb1d 100644 --- a/src/nft/components/icons.tsx +++ b/src/nft/components/icons.tsx @@ -1,5 +1,5 @@ import React from 'react' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import { themeVars, vars } from '../css/sprinkles.css' diff --git a/src/nft/components/profile/list/Dropdown.tsx b/src/nft/components/profile/list/Dropdown.tsx index 942b5bc772..b81c9afb6e 100644 --- a/src/nft/components/profile/list/Dropdown.tsx +++ b/src/nft/components/profile/list/Dropdown.tsx @@ -2,7 +2,7 @@ import Column from 'components/Column' import Row from 'components/Row' import { DropDownOption } from 'nft/types' import { Check } from 'react-feather' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import { ThemedText } from 'theme' const DropdownWrapper = styled(Column)<{ $width: number }>` diff --git a/src/nft/components/profile/list/ListPage.tsx b/src/nft/components/profile/list/ListPage.tsx index 29d3d463ae..78fe2c4565 100644 --- a/src/nft/components/profile/list/ListPage.tsx +++ b/src/nft/components/profile/list/ListPage.tsx @@ -23,7 +23,7 @@ import { formatEth } from 'nft/utils' import { ListingMarkets } from 'nft/utils/listNfts' import { useEffect, useMemo, useReducer, useState } from 'react' import { ArrowLeft } from 'react-feather' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { BREAKPOINTS, ThemedText } from 'theme' import { Z_INDEX } from 'theme/zIndex' import { shallow } from 'zustand/shallow' diff --git a/src/nft/components/profile/list/ListingButton.tsx b/src/nft/components/profile/list/ListingButton.tsx index 4ef87f27ac..5484ea52d3 100644 --- a/src/nft/components/profile/list/ListingButton.tsx +++ b/src/nft/components/profile/list/ListingButton.tsx @@ -3,7 +3,7 @@ import { BaseButton } from 'components/Button' import { BelowFloorWarningModal } from 'nft/components/profile/list/Modal/BelowFloorWarningModal' import { useIsMobile, useSellAsset } from 'nft/hooks' import { useMemo, useState } from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { BREAKPOINTS } from 'theme' import { shallow } from 'zustand/shallow' diff --git a/src/nft/components/profile/list/MarketplaceRow.tsx b/src/nft/components/profile/list/MarketplaceRow.tsx index 8ddc28c9cc..9bab7b0c9d 100644 --- a/src/nft/components/profile/list/MarketplaceRow.tsx +++ b/src/nft/components/profile/list/MarketplaceRow.tsx @@ -10,7 +10,7 @@ import { getMarketplaceIcon } from 'nft/utils' import { formatEth, formatUsdPrice } from 'nft/utils/currency' import { fetchPrice } from 'nft/utils/fetchPrice' import { Dispatch, DispatchWithoutAction, useCallback, useEffect, useMemo, useReducer, useState } from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { BREAKPOINTS, ThemedText } from 'theme' import { PriceTextInput } from './PriceTextInput' diff --git a/src/nft/components/profile/list/Modal/BelowFloorWarningModal.tsx b/src/nft/components/profile/list/Modal/BelowFloorWarningModal.tsx index 638ef70ea7..61f9e068a6 100644 --- a/src/nft/components/profile/list/Modal/BelowFloorWarningModal.tsx +++ b/src/nft/components/profile/list/Modal/BelowFloorWarningModal.tsx @@ -6,7 +6,7 @@ import { Overlay } from 'nft/components/modals/Overlay' import { Listing, WalletAsset } from 'nft/types' import React from 'react' import { AlertTriangle, X } from 'react-feather' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import { BREAKPOINTS, ThemedText } from 'theme' import { Z_INDEX } from 'theme/zIndex' diff --git a/src/nft/components/profile/list/Modal/ContentRow.tsx b/src/nft/components/profile/list/Modal/ContentRow.tsx index c19abd5224..5cb61af1b6 100644 --- a/src/nft/components/profile/list/Modal/ContentRow.tsx +++ b/src/nft/components/profile/list/Modal/ContentRow.tsx @@ -7,7 +7,7 @@ import { AssetRow, CollectionRow, ListingStatus } from 'nft/types' import { getMarketplaceIcon } from 'nft/utils' import { useEffect, useRef } from 'react' import { Check, XOctagon } from 'react-feather' -import styled, { css, useTheme } from 'styled-components/macro' +import styled, { css, useTheme } from 'styled-components' import { ThemedText } from 'theme' import { opacify } from 'theme/utils' diff --git a/src/nft/components/profile/list/Modal/ListModal.tsx b/src/nft/components/profile/list/Modal/ListModal.tsx index 7c0e1bbcfe..a18f0e0fab 100644 --- a/src/nft/components/profile/list/Modal/ListModal.tsx +++ b/src/nft/components/profile/list/Modal/ListModal.tsx @@ -13,7 +13,7 @@ import { useNFTList, useSellAsset } from 'nft/hooks' import { ListingStatus } from 'nft/types' import { useCallback, useEffect, useMemo, useReducer } from 'react' import { X } from 'react-feather' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { BREAKPOINTS, ThemedText } from 'theme' import { Z_INDEX } from 'theme/zIndex' import { shallow } from 'zustand/shallow' diff --git a/src/nft/components/profile/list/Modal/ListModalSection.tsx b/src/nft/components/profile/list/Modal/ListModalSection.tsx index c8bf9f0ee8..8d073a6855 100644 --- a/src/nft/components/profile/list/Modal/ListModalSection.tsx +++ b/src/nft/components/profile/list/Modal/ListModalSection.tsx @@ -8,7 +8,7 @@ import { useSellAsset } from 'nft/hooks' import { AssetRow, CollectionRow, ListingRow, ListingStatus } from 'nft/types' import { useMemo } from 'react' import { Info } from 'react-feather' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import { ThemedText } from 'theme' import { colors } from 'theme/colors' import { TRANSITION_DURATIONS } from 'theme/styles' @@ -109,7 +109,7 @@ export const ListModalSection = ({ sectionType, active, content, toggleSection } {isCollectionApprovalSection ? ( <> Approve  - + ) : ( <> diff --git a/src/nft/components/profile/list/Modal/SuccessScreen.tsx b/src/nft/components/profile/list/Modal/SuccessScreen.tsx index b89182e125..b7e834d955 100644 --- a/src/nft/components/profile/list/Modal/SuccessScreen.tsx +++ b/src/nft/components/profile/list/Modal/SuccessScreen.tsx @@ -12,7 +12,7 @@ import { useSellAsset } from 'nft/hooks' import { formatEth, generateTweetForList, pluralize } from 'nft/utils' import { useMemo } from 'react' import { Twitter, X } from 'react-feather' -import styled, { css, useTheme } from 'styled-components/macro' +import styled, { css, useTheme } from 'styled-components' import { BREAKPOINTS, ThemedText } from 'theme' import { TitleRow } from '../shared' diff --git a/src/nft/components/profile/list/NFTListRow.tsx b/src/nft/components/profile/list/NFTListRow.tsx index d04c4873fd..15a8d1a5b2 100644 --- a/src/nft/components/profile/list/NFTListRow.tsx +++ b/src/nft/components/profile/list/NFTListRow.tsx @@ -5,7 +5,7 @@ import { useSellAsset } from 'nft/hooks' import { ListingMarket, WalletAsset } from 'nft/types' import { Dispatch, useEffect, useReducer, useState } from 'react' import { Trash2 } from 'react-feather' -import styled, { css, useTheme } from 'styled-components/macro' +import styled, { css, useTheme } from 'styled-components' import { BREAKPOINTS, ThemedText } from 'theme' import { MarketplaceRow } from './MarketplaceRow' diff --git a/src/nft/components/profile/list/NFTListingsGrid.tsx b/src/nft/components/profile/list/NFTListingsGrid.tsx index 1d8c3370e5..4c7f242be2 100644 --- a/src/nft/components/profile/list/NFTListingsGrid.tsx +++ b/src/nft/components/profile/list/NFTListingsGrid.tsx @@ -6,7 +6,7 @@ import { useSellAsset } from 'nft/hooks' import { DropDownOption, ListingMarket } from 'nft/types' import { useMemo, useReducer, useRef, useState } from 'react' import { ChevronDown } from 'react-feather' -import styled, { css } from 'styled-components/macro' +import styled, { css } from 'styled-components' import { BREAKPOINTS } from 'theme' import { Dropdown } from './Dropdown' diff --git a/src/nft/components/profile/list/PriceTextInput.tsx b/src/nft/components/profile/list/PriceTextInput.tsx index 9c97e37b5c..b9cb29b64f 100644 --- a/src/nft/components/profile/list/PriceTextInput.tsx +++ b/src/nft/components/profile/list/PriceTextInput.tsx @@ -10,7 +10,7 @@ import { WalletAsset } from 'nft/types' import { formatEth } from 'nft/utils/currency' import { Dispatch, useRef, useState } from 'react' import { AlertTriangle, Link } from 'react-feather' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import { BREAKPOINTS } from 'theme' import { colors } from 'theme/colors' diff --git a/src/nft/components/profile/list/RoyaltyTooltip.tsx b/src/nft/components/profile/list/RoyaltyTooltip.tsx index 47edd65a9a..04288bdb49 100644 --- a/src/nft/components/profile/list/RoyaltyTooltip.tsx +++ b/src/nft/components/profile/list/RoyaltyTooltip.tsx @@ -4,7 +4,7 @@ import Row from 'components/Row' import { getRoyalty } from 'nft/components/profile/list/utils' import { ListingMarket, WalletAsset } from 'nft/types' import { formatEth, getMarketplaceIcon } from 'nft/utils' -import styled, { css } from 'styled-components/macro' +import styled, { css } from 'styled-components' import { ThemedText } from 'theme' const FeeWrap = styled(Row)` diff --git a/src/nft/components/profile/list/SelectMarketplacesDropdown.tsx b/src/nft/components/profile/list/SelectMarketplacesDropdown.tsx index 43c65d9979..593e87ccca 100644 --- a/src/nft/components/profile/list/SelectMarketplacesDropdown.tsx +++ b/src/nft/components/profile/list/SelectMarketplacesDropdown.tsx @@ -9,7 +9,7 @@ import { ListingMarket } from 'nft/types' import { getMarketplaceIcon } from 'nft/utils' import { ListingMarkets } from 'nft/utils/listNfts' import { Dispatch, FormEvent, useMemo, useReducer, useRef } from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ThemedText } from 'theme' import { Z_INDEX } from 'theme/zIndex' diff --git a/src/nft/components/profile/list/SetDurationModal.tsx b/src/nft/components/profile/list/SetDurationModal.tsx index 77dbca54ec..532ff98f43 100644 --- a/src/nft/components/profile/list/SetDurationModal.tsx +++ b/src/nft/components/profile/list/SetDurationModal.tsx @@ -1,6 +1,6 @@ import { Plural } from '@lingui/macro' import { useOnClickOutside } from 'hooks/useOnClickOutside' -import ms from 'ms.macro' +import ms from 'ms' import { Column, Row } from 'nft/components/Flex' import { NumericInput } from 'nft/components/layout/Input' import { body, caption } from 'nft/css/common.css' @@ -8,7 +8,7 @@ import { useSellAsset } from 'nft/hooks' import { DropDownOption } from 'nft/types' import { useEffect, useMemo, useReducer, useRef, useState } from 'react' import { AlertTriangle, ChevronDown } from 'react-feather' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { Z_INDEX } from 'theme/zIndex' import { Dropdown } from './Dropdown' @@ -163,8 +163,8 @@ export const SetDurationModal = () => { useEffect(() => { const expiration = convertDurationToExpiration(parseFloat(amount), duration) - if (expiration * 1000 - Date.now() < ms`60 seconds` || isNaN(expiration)) setErrorState(ErrorState.empty) - else if (expiration * 1000 - Date.now() > ms`180 days`) setErrorState(ErrorState.overMax) + if (expiration * 1000 - Date.now() < ms(`60s`) || isNaN(expiration)) setErrorState(ErrorState.empty) + else if (expiration * 1000 - Date.now() > ms(`180d`)) setErrorState(ErrorState.overMax) else setErrorState(ErrorState.valid) setGlobalExpiration(expiration) }, [amount, duration, setGlobalExpiration]) @@ -218,5 +218,5 @@ const convertDurationToExpiration = (amount: number, duration: Duration) => { return 24 * 30 } } - return Math.round((Date.now() + ms`1 hour` * durationFactor() * amount) / 1000) + return Math.round((Date.now() + ms(`1h`) * durationFactor() * amount) / 1000) } diff --git a/src/nft/components/profile/list/shared.tsx b/src/nft/components/profile/list/shared.tsx index 73a30b924f..a9e86bd5f5 100644 --- a/src/nft/components/profile/list/shared.tsx +++ b/src/nft/components/profile/list/shared.tsx @@ -1,5 +1,5 @@ import Row from 'components/Row' -import styled from 'styled-components/macro' +import styled from 'styled-components' export const RemoveIconWrap = styled.div<{ hovered: boolean }>` position: absolute; diff --git a/src/nft/components/profile/list/utils.ts b/src/nft/components/profile/list/utils.ts index 6e221d455a..4a47930d28 100644 --- a/src/nft/components/profile/list/utils.ts +++ b/src/nft/components/profile/list/utils.ts @@ -1,7 +1,7 @@ import type { JsonRpcSigner, Web3Provider } from '@ethersproject/providers' import { addressesByNetwork, SupportedChainId } from '@looksrare/sdk' import { NftStandard } from 'graphql/data/__generated__/types-and-hooks' -import ms from 'ms.macro' +import ms from 'ms' import { SetPriceMethod, WarningType } from 'nft/components/profile/list/shared' import { useNFTList, useSellAsset } from 'nft/hooks' import { @@ -233,11 +233,11 @@ export const findListingIssues = (sellAssets: WalletAsset[]) => { const missingExpiration = sellAssets.some((asset) => { return ( asset.expirationTime != null && - (isNaN(asset.expirationTime) || asset.expirationTime * 1000 - Date.now() < ms`60 seconds`) + (isNaN(asset.expirationTime) || asset.expirationTime * 1000 - Date.now() < ms(`60s`)) ) }) const overMaxExpiration = sellAssets.some((asset) => { - return asset.expirationTime != null && asset.expirationTime * 1000 - Date.now() > ms`180 days` + return asset.expirationTime != null && asset.expirationTime * 1000 - Date.now() > ms(`180d`) }) const listingsMissingPrice: [WalletAsset, Listing][] = [] diff --git a/src/nft/components/profile/view/EmptyWalletContent.tsx b/src/nft/components/profile/view/EmptyWalletContent.tsx index 36ad88b4af..23815fd9a4 100644 --- a/src/nft/components/profile/view/EmptyWalletContent.tsx +++ b/src/nft/components/profile/view/EmptyWalletContent.tsx @@ -2,7 +2,7 @@ import { Trans } from '@lingui/macro' import { headlineMedium } from 'nft/css/common.css' import { useCallback } from 'react' import { useNavigate } from 'react-router-dom' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ThemedText } from 'theme' import { EmptyActivityIcon, EmptyNftsIcon, EmptyPoolsIcon, EmptyTokensIcon } from './icons' diff --git a/src/nft/components/profile/view/FilterSidebar.tsx b/src/nft/components/profile/view/FilterSidebar.tsx index 8ad9fe251b..d10b47f3fc 100644 --- a/src/nft/components/profile/view/FilterSidebar.tsx +++ b/src/nft/components/profile/view/FilterSidebar.tsx @@ -25,7 +25,7 @@ import { easings, useSpring } from 'react-spring' import AutoSizer from 'react-virtualized-auto-sizer' import { FixedSizeList, ListOnItemsRenderedProps } from 'react-window' import InfiniteLoader from 'react-window-infinite-loader' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ThemedText } from 'theme' import { TRANSITION_DURATIONS } from 'theme/styles' import noop from 'utils/noop' diff --git a/src/nft/components/profile/view/ProfilePage.tsx b/src/nft/components/profile/view/ProfilePage.tsx index 5c828c427a..b73e9daac2 100644 --- a/src/nft/components/profile/view/ProfilePage.tsx +++ b/src/nft/components/profile/view/ProfilePage.tsx @@ -23,7 +23,7 @@ import { Dispatch, SetStateAction, Suspense, useCallback, useEffect, useMemo, us import InfiniteScroll from 'react-infinite-scroll-component' import { useInfiniteQuery } from 'react-query' import { easings, useSpring } from 'react-spring' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { shallow } from 'zustand/shallow' import { EmptyWalletModule } from './EmptyWalletContent' diff --git a/src/nft/components/profile/view/ProfilePageLoadingSkeleton.tsx b/src/nft/components/profile/view/ProfilePageLoadingSkeleton.tsx index 35cd54f082..498a57cf73 100644 --- a/src/nft/components/profile/view/ProfilePageLoadingSkeleton.tsx +++ b/src/nft/components/profile/view/ProfilePageLoadingSkeleton.tsx @@ -2,7 +2,7 @@ import { Box } from 'nft/components/Box' import { assetList } from 'nft/components/collection/CollectionNfts.css' import { loadingAsset } from 'nft/css/loading.css' import { ScreenBreakpointsPaddings } from 'nft/pages/collection/index.css' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { DEFAULT_WALLET_ASSET_QUERY_AMOUNT } from './ProfilePage' diff --git a/src/nft/components/profile/view/__snapshots__/ViewMyNftsAsset.test.tsx.snap b/src/nft/components/profile/view/__snapshots__/ViewMyNftsAsset.test.tsx.snap index 6366d4634a..a2ab790919 100644 --- a/src/nft/components/profile/view/__snapshots__/ViewMyNftsAsset.test.tsx.snap +++ b/src/nft/components/profile/view/__snapshots__/ViewMyNftsAsset.test.tsx.snap @@ -313,10 +313,10 @@ exports[`NftCard renders correctly 1`] = ` class="c2 c3 c16" >
Froggy Friend #2359
diff --git a/src/nft/components/profile/view/icons.tsx b/src/nft/components/profile/view/icons.tsx index 47e3d85f11..35f2a42e14 100644 --- a/src/nft/components/profile/view/icons.tsx +++ b/src/nft/components/profile/view/icons.tsx @@ -1,4 +1,4 @@ -import { useTheme } from 'styled-components/macro' +import { useTheme } from 'styled-components' import { colors } from 'theme/colors' type SVGProps = React.SVGProps & { fill?: string } diff --git a/src/nft/hooks/useDerivedPayWithAnyTokenSwapInfo.ts b/src/nft/hooks/useDerivedPayWithAnyTokenSwapInfo.ts index fb629006f9..90038e1199 100644 --- a/src/nft/hooks/useDerivedPayWithAnyTokenSwapInfo.ts +++ b/src/nft/hooks/useDerivedPayWithAnyTokenSwapInfo.ts @@ -2,8 +2,7 @@ import { Currency, CurrencyAmount, NativeCurrency, Percent, Token, TradeType } f import useAutoSlippageTolerance from 'hooks/useAutoSlippageTolerance' import { useBestTrade } from 'hooks/useBestTrade' import { useMemo } from 'react' -import { RouterPreference } from 'state/routing/types' -import { ClassicTrade, TradeState } from 'state/routing/types' +import { ClassicTrade, RouterPreference, TradeState } from 'state/routing/types' import { isClassicTrade } from 'state/routing/utils' export default function useDerivedPayWithAnyTokenSwapInfo( diff --git a/src/nft/hooks/usePriceImpact.ts b/src/nft/hooks/usePriceImpact.ts index 0803626248..22a8f68f41 100644 --- a/src/nft/hooks/usePriceImpact.ts +++ b/src/nft/hooks/usePriceImpact.ts @@ -1,7 +1,7 @@ import { Percent } from '@uniswap/sdk-core' import { useMemo } from 'react' import { ClassicTrade } from 'state/routing/types' -import { useTheme } from 'styled-components/macro' +import { useTheme } from 'styled-components' import { computeRealizedPriceImpact, getPriceImpactWarning } from 'utils/prices' export interface PriceImpact { diff --git a/src/nft/pages/asset/Asset.tsx b/src/nft/pages/asset/Asset.tsx index c9a8d9318d..30619ebccf 100644 --- a/src/nft/pages/asset/Asset.tsx +++ b/src/nft/pages/asset/Asset.tsx @@ -5,7 +5,7 @@ import { AssetDetails } from 'nft/components/details/AssetDetails' import { AssetDetailsLoading } from 'nft/components/details/AssetDetailsLoading' import { AssetPriceDetails } from 'nft/components/details/AssetPriceDetails' import { useParams } from 'react-router-dom' -import styled from 'styled-components/macro' +import styled from 'styled-components' const AssetContainer = styled.div` display: flex; diff --git a/src/nft/pages/collection/index.css.ts b/src/nft/pages/collection/index.css.ts index 1d6746ed52..8458631352 100644 --- a/src/nft/pages/collection/index.css.ts +++ b/src/nft/pages/collection/index.css.ts @@ -2,7 +2,7 @@ import { style } from '@vanilla-extract/css' import { MOBILE_MEDIA_BREAKPOINT, SMALL_MEDIA_BREAKPOINT, XLARGE_MEDIA_BREAKPOINT } from 'components/Tokens/constants' import { buttonTextMedium } from 'nft/css/common.css' import { loadingBlock } from 'nft/css/loading.css' -import { css } from 'styled-components/macro' +import { css } from 'styled-components' import { sprinkles } from '../../css/sprinkles.css' diff --git a/src/nft/pages/collection/index.tsx b/src/nft/pages/collection/index.tsx index c5694650d1..5b375847bb 100644 --- a/src/nft/pages/collection/index.tsx +++ b/src/nft/pages/collection/index.tsx @@ -19,7 +19,7 @@ import { blocklistedCollections } from 'nft/utils' import { Suspense, useEffect } from 'react' import { useLocation, useNavigate, useParams } from 'react-router-dom' import { animated, easings, useSpring } from 'react-spring' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ThemedText } from 'theme' import { TRANSITION_DURATIONS } from 'theme/styles' import { Z_INDEX } from 'theme/zIndex' diff --git a/src/nft/pages/explore/index.tsx b/src/nft/pages/explore/index.tsx index c5540b3662..e51314f316 100644 --- a/src/nft/pages/explore/index.tsx +++ b/src/nft/pages/explore/index.tsx @@ -4,7 +4,7 @@ import Banner from 'nft/components/explore/Banner' import TrendingCollections from 'nft/components/explore/TrendingCollections' import { useBag } from 'nft/hooks' import { useEffect } from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' const ExploreContainer = styled.div` display: flex; diff --git a/src/nft/pages/profile/profile.tsx b/src/nft/pages/profile/profile.tsx index 36399f7144..362bd2fc3c 100644 --- a/src/nft/pages/profile/profile.tsx +++ b/src/nft/pages/profile/profile.tsx @@ -11,7 +11,7 @@ import { ProfilePageLoadingSkeleton } from 'nft/components/profile/view/ProfileP import { useBag, useProfilePageState, useSellAsset, useWalletCollections } from 'nft/hooks' import { ProfilePageStateType } from 'nft/types' import { Suspense, useEffect, useRef } from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { BREAKPOINTS, ThemedText } from 'theme' import { LIST_PAGE_MARGIN, LIST_PAGE_MARGIN_MOBILE } from './shared' diff --git a/src/nft/queries/openSea/PostOpenSeaSellOrder.ts b/src/nft/queries/openSea/PostOpenSeaSellOrder.ts index 7ddea2ea84..aac605bfbc 100644 --- a/src/nft/queries/openSea/PostOpenSeaSellOrder.ts +++ b/src/nft/queries/openSea/PostOpenSeaSellOrder.ts @@ -1,4 +1,4 @@ -import ms from 'ms.macro' +import ms from 'ms' export async function PostOpenSeaSellOrder(payload?: Record): Promise { const body = payload ? JSON.stringify(payload) : undefined @@ -12,7 +12,7 @@ export async function PostOpenSeaSellOrder(payload?: Record): P body, signal: ac.signal, }) - const timeout = setTimeout(() => ac.abort(), ms`60s`) + const timeout = setTimeout(() => ac.abort(), ms(`60s`)) try { const res = await fetch(req) const data = await res.json() diff --git a/src/nft/utils/time.ts b/src/nft/utils/time.ts index 072372ab11..cd7f40a28c 100644 --- a/src/nft/utils/time.ts +++ b/src/nft/utils/time.ts @@ -1,14 +1,14 @@ import { plural, t } from '@lingui/macro' -import ms from 'ms.macro' +import ms from 'ms' import { roundAndPluralize } from './roundAndPluralize' -const SECOND = ms`1s` -const MINUTE = ms`1m` -const HOUR = ms`1h` -const DAY = ms`1d` -const WEEK = ms`7d` -const MONTH = ms`30d` +const SECOND = ms(`1s`) +const MINUTE = ms(`1m`) +const HOUR = ms(`1h`) +const DAY = ms(`1d`) +const WEEK = ms(`7d`) +const MONTH = ms(`30d`) interface TimePeriod { milliseconds: number diff --git a/src/pages/AddLiquidity/Review.tsx b/src/pages/AddLiquidity/Review.tsx index 8497123b17..eb97b76463 100644 --- a/src/pages/AddLiquidity/Review.tsx +++ b/src/pages/AddLiquidity/Review.tsx @@ -2,7 +2,7 @@ import { Currency, CurrencyAmount, Price } from '@uniswap/sdk-core' import { Position } from '@uniswap/v3-sdk' import { AutoColumn } from 'components/Column' import { PositionPreview } from 'components/PositionPreview' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { Bound, Field } from '../../state/mint/v3/actions' diff --git a/src/pages/AddLiquidity/index.tsx b/src/pages/AddLiquidity/index.tsx index 62bd2a0693..a9bffb0e31 100644 --- a/src/pages/AddLiquidity/index.tsx +++ b/src/pages/AddLiquidity/index.tsx @@ -25,7 +25,7 @@ import { useV3MintActionHandlers, useV3MintState, } from 'state/mint/v3/hooks' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import { addressesAreEquivalent } from 'utils/addressesAreEquivalent' import { ButtonError, ButtonLight, ButtonPrimary, ButtonText } from '../../components/Button' diff --git a/src/pages/AddLiquidity/styled.tsx b/src/pages/AddLiquidity/styled.tsx index 50fe371598..1a02d5e451 100644 --- a/src/pages/AddLiquidity/styled.tsx +++ b/src/pages/AddLiquidity/styled.tsx @@ -1,7 +1,7 @@ import { AutoColumn } from 'components/Column' import CurrencyInputPanel from 'components/CurrencyInputPanel' import Input from 'components/NumericalInput' -import styled from 'styled-components/macro' +import styled from 'styled-components' export const Wrapper = styled.div` position: relative; diff --git a/src/pages/AddLiquidityV2/PoolPriceBar.tsx b/src/pages/AddLiquidityV2/PoolPriceBar.tsx index d1203b0af7..d9c3d48066 100644 --- a/src/pages/AddLiquidityV2/PoolPriceBar.tsx +++ b/src/pages/AddLiquidityV2/PoolPriceBar.tsx @@ -1,7 +1,7 @@ import { Trans } from '@lingui/macro' import { Currency, Percent, Price } from '@uniswap/sdk-core' import { Text } from 'rebass' -import { useTheme } from 'styled-components/macro' +import { useTheme } from 'styled-components' import { AutoColumn } from '../../components/Column' import { AutoRow } from '../../components/Row' diff --git a/src/pages/AddLiquidityV2/index.tsx b/src/pages/AddLiquidityV2/index.tsx index 1060b1620c..0214d288b4 100644 --- a/src/pages/AddLiquidityV2/index.tsx +++ b/src/pages/AddLiquidityV2/index.tsx @@ -15,7 +15,7 @@ import { useCallback, useState } from 'react' import { Plus } from 'react-feather' import { useLocation, useNavigate, useParams } from 'react-router-dom' import { Text } from 'rebass' -import { useTheme } from 'styled-components/macro' +import { useTheme } from 'styled-components' import { ButtonError, ButtonLight, ButtonPrimary } from '../../components/Button' import { BlueCard, LightCard } from '../../components/Card' diff --git a/src/pages/App.tsx b/src/pages/App.tsx index 486c5b0277..f5a446b386 100644 --- a/src/pages/App.tsx +++ b/src/pages/App.tsx @@ -11,7 +11,7 @@ import { Navigate, Route, Routes, useLocation, useSearchParams } from 'react-rou import { shouldDisableNFTRoutesAtom } from 'state/application/atoms' import { useRouterPreference } from 'state/user/hooks' import { StatsigProvider, StatsigUser } from 'statsig-react' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { SpinnerSVG } from 'theme/components' import { useIsDarkMode } from 'theme/components/ThemeToggle' import { flexRowNoWrap } from 'theme/styles' diff --git a/src/pages/AppBody.tsx b/src/pages/AppBody.tsx index 8b7843c91d..f935cf0dc2 100644 --- a/src/pages/AppBody.tsx +++ b/src/pages/AppBody.tsx @@ -1,5 +1,5 @@ import { PropsWithChildren } from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { Z_INDEX } from 'theme/zIndex' interface BodyWrapperProps { diff --git a/src/pages/CreateProposal/ProposalActionDetail.tsx b/src/pages/CreateProposal/ProposalActionDetail.tsx index bfc7e2c8fd..610850a35c 100644 --- a/src/pages/CreateProposal/ProposalActionDetail.tsx +++ b/src/pages/CreateProposal/ProposalActionDetail.tsx @@ -3,7 +3,7 @@ import { Currency } from '@uniswap/sdk-core' import AddressInputPanel from 'components/AddressInputPanel' import CurrencyInputPanel from 'components/CurrencyInputPanel' import React from 'react' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ProposalAction } from './ProposalActionSelector' diff --git a/src/pages/CreateProposal/ProposalActionSelector.tsx b/src/pages/CreateProposal/ProposalActionSelector.tsx index 8a096e86b9..7d569a7944 100644 --- a/src/pages/CreateProposal/ProposalActionSelector.tsx +++ b/src/pages/CreateProposal/ProposalActionSelector.tsx @@ -6,7 +6,7 @@ import { RowBetween } from 'components/Row' import { MenuItem, PaddedColumn, Separator } from 'components/SearchModal/styleds' import React, { useCallback } from 'react' import { Text } from 'rebass' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { CloseIcon } from 'theme' export enum ProposalAction { diff --git a/src/pages/CreateProposal/ProposalEditor.tsx b/src/pages/CreateProposal/ProposalEditor.tsx index 0faf4d2a93..57f0af125b 100644 --- a/src/pages/CreateProposal/ProposalEditor.tsx +++ b/src/pages/CreateProposal/ProposalEditor.tsx @@ -3,7 +3,7 @@ import { t, Trans } from '@lingui/macro' import { ResizingTextArea, TextInput } from 'components/TextInput' import React, { memo } from 'react' import { Text } from 'rebass' -import styled from 'styled-components/macro' +import styled from 'styled-components' const ProposalEditorHeader = styled(Text)` font-size: 14px; diff --git a/src/pages/CreateProposal/ProposalSubmissionModal.tsx b/src/pages/CreateProposal/ProposalSubmissionModal.tsx index 5833e4fc4a..3433c94d90 100644 --- a/src/pages/CreateProposal/ProposalSubmissionModal.tsx +++ b/src/pages/CreateProposal/ProposalSubmissionModal.tsx @@ -5,7 +5,7 @@ import Modal from 'components/Modal' import { LoadingView, SubmittedView } from 'components/ModalViews' import { Link } from 'react-router-dom' import { Text } from 'rebass' -import { useTheme } from 'styled-components/macro' +import { useTheme } from 'styled-components' import { ExternalLink, ThemedText } from 'theme' import { ExplorerDataType, getExplorerLink } from 'utils/getExplorerLink' diff --git a/src/pages/CreateProposal/index.tsx b/src/pages/CreateProposal/index.tsx index 44bd976f9a..1bbf6ad5f1 100644 --- a/src/pages/CreateProposal/index.tsx +++ b/src/pages/CreateProposal/index.tsx @@ -23,7 +23,7 @@ import { useProposalThreshold, useUserVotes, } from 'state/governance/hooks' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ExternalLink, ThemedText } from 'theme' import { LATEST_GOVERNOR_INDEX } from '../../constants/governance' diff --git a/src/pages/Landing/__snapshots__/index.test.tsx.snap b/src/pages/Landing/__snapshots__/index.test.tsx.snap index bc148518d5..605c61c4c9 100644 --- a/src/pages/Landing/__snapshots__/index.test.tsx.snap +++ b/src/pages/Landing/__snapshots__/index.test.tsx.snap @@ -2027,25 +2027,25 @@ exports[`disable nft on landing page does not render nft information and card 1`

Get started

Learn more
© 2023 @@ -4601,25 +4601,25 @@ exports[`disable nft on landing page renders nft information and card 1`] = `

Get started

Learn more
© 2023 diff --git a/src/pages/Landing/index.tsx b/src/pages/Landing/index.tsx index 1376365de4..647976ea5c 100644 --- a/src/pages/Landing/index.tsx +++ b/src/pages/Landing/index.tsx @@ -17,7 +17,7 @@ import { ArrowDownCircle } from 'react-feather' import { useLocation, useNavigate } from 'react-router-dom' import { Link as NativeLink } from 'react-router-dom' import { useAppSelector } from 'state/hooks' -import styled, { css } from 'styled-components/macro' +import styled, { css } from 'styled-components' import { BREAKPOINTS } from 'theme' import { useIsDarkMode } from 'theme/components/ThemeToggle' import { TRANSITION_DURATIONS } from 'theme/styles' diff --git a/src/pages/MigrateV2/MigrateV2Pair.tsx b/src/pages/MigrateV2/MigrateV2Pair.tsx index 5ca0efe387..88685c0011 100644 --- a/src/pages/MigrateV2/MigrateV2Pair.tsx +++ b/src/pages/MigrateV2/MigrateV2Pair.tsx @@ -32,7 +32,7 @@ import { Bound, resetMintState } from 'state/mint/v3/actions' import { useRangeHopCallbacks, useV3DerivedMintInfo, useV3MintActionHandlers } from 'state/mint/v3/hooks' import { useIsTransactionPending, useTransactionAdder } from 'state/transactions/hooks' import { useUserSlippageToleranceWithDefault } from 'state/user/hooks' -import { useTheme } from 'styled-components/macro' +import { useTheme } from 'styled-components' import { formatCurrencyAmount } from 'utils/formatCurrencyAmount' import { unwrappedToken } from 'utils/unwrappedToken' diff --git a/src/pages/MigrateV2/index.tsx b/src/pages/MigrateV2/index.tsx index 45b58cff8c..9da2f33c56 100644 --- a/src/pages/MigrateV2/index.tsx +++ b/src/pages/MigrateV2/index.tsx @@ -12,7 +12,7 @@ import { useNetworkSupportsV2 } from 'hooks/useNetworkSupportsV2' import { PairState, useV2Pairs } from 'hooks/useV2Pairs' import { ReactNode, useMemo } from 'react' import { Text } from 'rebass' -import { useTheme } from 'styled-components/macro' +import { useTheme } from 'styled-components' import { LightCard } from '../../components/Card' import { AutoColumn } from '../../components/Column' diff --git a/src/pages/NotFound/index.tsx b/src/pages/NotFound/index.tsx index 4cbd4dde14..3a2f68c7d3 100644 --- a/src/pages/NotFound/index.tsx +++ b/src/pages/NotFound/index.tsx @@ -4,7 +4,7 @@ import { Trace } from 'analytics' import { SmallButtonPrimary } from 'components/Button' import { useIsMobile } from 'nft/hooks' import { Link } from 'react-router-dom' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ThemedText } from 'theme' import { useIsDarkMode } from 'theme/components/ThemeToggle' diff --git a/src/pages/Pool/CTACards.test.tsx b/src/pages/Pool/CTACards.test.tsx index 1bc7ba7700..8f0ce879a8 100644 --- a/src/pages/Pool/CTACards.test.tsx +++ b/src/pages/Pool/CTACards.test.tsx @@ -1,13 +1,14 @@ -import * as useV3Positions from 'hooks/useV3Positions' +import { useV3Positions } from 'hooks/useV3Positions' +import { mocked } from 'test-utils/mocked' import { render, screen } from 'test-utils/render' import CTACards from './CTACards' +jest.mock('hooks/useV3Positions') + describe('CTAcard links', () => { it('renders mainnet link when chain is not supported', () => { - jest.spyOn(useV3Positions, 'useV3Positions').mockImplementation(() => { - return { loading: false, positions: undefined } - }) + mocked(useV3Positions).mockReturnValue({ loading: false, positions: undefined }) render() expect(screen.getByTestId('cta-infolink')).toHaveAttribute('href', 'https://info.uniswap.org/#/pools') diff --git a/src/pages/Pool/CTACards.tsx b/src/pages/Pool/CTACards.tsx index 5c63ea8856..ae40442d37 100644 --- a/src/pages/Pool/CTACards.tsx +++ b/src/pages/Pool/CTACards.tsx @@ -2,7 +2,7 @@ import { Trans } from '@lingui/macro' import { useWeb3React } from '@web3-react/core' import { AutoColumn } from 'components/Column' import { getChainInfoOrDefault } from 'constants/chainInfo' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ThemedText } from 'theme' import { ExternalLink } from '../../theme' diff --git a/src/pages/Pool/PositionPage.tsx b/src/pages/Pool/PositionPage.tsx index 47bd7bc4d7..1b0378c402 100644 --- a/src/pages/Pool/PositionPage.tsx +++ b/src/pages/Pool/PositionPage.tsx @@ -34,7 +34,7 @@ import { PropsWithChildren, useCallback, useMemo, useRef, useState } from 'react import { Link, useParams } from 'react-router-dom' import { Bound } from 'state/mint/v3/actions' import { useIsTransactionPending, useTransactionAdder } from 'state/transactions/hooks' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import { ExternalLink, HideExtraSmall, HideSmall, StyledRouterLink, ThemedText } from 'theme' import { currencyId } from 'utils/currencyId' import { formatCurrencyAmount } from 'utils/formatCurrencyAmount' diff --git a/src/pages/Pool/index.test.tsx b/src/pages/Pool/index.test.tsx index 68899274fe..9d06e7d818 100644 --- a/src/pages/Pool/index.test.tsx +++ b/src/pages/Pool/index.test.tsx @@ -1,25 +1,25 @@ -import * as chains from 'constants/chains' -import * as useV3Positions from 'hooks/useV3Positions' +import { isSupportedChain } from 'constants/chains' +import { useV3Positions } from 'hooks/useV3Positions' +import { mocked } from 'test-utils/mocked' import { render, screen } from 'test-utils/render' import Pool from '.' +jest.mock('constants/chains') +jest.mock('hooks/useV3Positions') + describe('networks', () => { it('renders error card when unsupported chain is selected', () => { - jest.spyOn(chains, 'isSupportedChain').mockReturnValue(false) - jest.spyOn(useV3Positions, 'useV3Positions').mockImplementation(() => { - return { loading: false, positions: undefined } - }) + mocked(isSupportedChain).mockReturnValue(false) + mocked(useV3Positions).mockReturnValue({ loading: false, positions: undefined }) render() expect(screen.getByText('Your connected network is unsupported.')).toBeInTheDocument() }) it('renders empty positions card when on supported chain with no positions', () => { - jest.spyOn(chains, 'isSupportedChain').mockReturnValue(true) - jest.spyOn(useV3Positions, 'useV3Positions').mockImplementation(() => { - return { loading: false, positions: undefined } - }) + mocked(isSupportedChain).mockReturnValue(true) + mocked(useV3Positions).mockReturnValue({ loading: false, positions: undefined }) render() expect(screen.getByText('Your active V3 liquidity positions will appear here.')).toBeInTheDocument() diff --git a/src/pages/Pool/index.tsx b/src/pages/Pool/index.tsx index 5047d05aa2..3ead052fb2 100644 --- a/src/pages/Pool/index.tsx +++ b/src/pages/Pool/index.tsx @@ -18,7 +18,7 @@ import { useMemo } from 'react' import { AlertTriangle, BookOpen, ChevronDown, ChevronsRight, Inbox, Layers } from 'react-feather' import { Link } from 'react-router-dom' import { useUserHideClosedPositions } from 'state/user/hooks' -import styled, { css, useTheme } from 'styled-components/macro' +import styled, { css, useTheme } from 'styled-components' import { HideSmall, ThemedText } from 'theme' import { PositionDetails } from 'types/position' diff --git a/src/pages/Pool/styleds.tsx b/src/pages/Pool/styleds.tsx index 20d8305519..e19f50082c 100644 --- a/src/pages/Pool/styleds.tsx +++ b/src/pages/Pool/styleds.tsx @@ -1,6 +1,6 @@ import { LoadingRows as BaseLoadingRows } from 'components/Loader/styled' import { Text } from 'rebass' -import styled from 'styled-components/macro' +import styled from 'styled-components' export const Wrapper = styled.div` position: relative; diff --git a/src/pages/Pool/v2.tsx b/src/pages/Pool/v2.tsx index 626320559d..84db422db3 100644 --- a/src/pages/Pool/v2.tsx +++ b/src/pages/Pool/v2.tsx @@ -10,7 +10,7 @@ import { useMemo } from 'react' import { ChevronsRight } from 'react-feather' import { Link } from 'react-router-dom' import { Text } from 'rebass' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import { ButtonOutlined, ButtonPrimary, ButtonSecondary } from '../../components/Button' import Card from '../../components/Card' diff --git a/src/pages/RemoveLiquidity/V3.tsx b/src/pages/RemoveLiquidity/V3.tsx index b61706c556..23a31ff518 100644 --- a/src/pages/RemoveLiquidity/V3.tsx +++ b/src/pages/RemoveLiquidity/V3.tsx @@ -31,7 +31,7 @@ import { Text } from 'rebass' import { useBurnV3ActionHandlers, useBurnV3State, useDerivedV3BurnInfo } from 'state/burn/v3/hooks' import { useTransactionAdder } from 'state/transactions/hooks' import { useUserSlippageToleranceWithDefault } from 'state/user/hooks' -import { useTheme } from 'styled-components/macro' +import { useTheme } from 'styled-components' import { ThemedText } from 'theme' import TransactionConfirmationModal, { ConfirmationModalContent } from '../../components/TransactionConfirmationModal' diff --git a/src/pages/RemoveLiquidity/index.tsx b/src/pages/RemoveLiquidity/index.tsx index df0518f5eb..c1ecf84f39 100644 --- a/src/pages/RemoveLiquidity/index.tsx +++ b/src/pages/RemoveLiquidity/index.tsx @@ -17,7 +17,7 @@ import { useCallback, useMemo, useState } from 'react' import { ArrowDown, Plus } from 'react-feather' import { useNavigate, useParams } from 'react-router-dom' import { Text } from 'rebass' -import { useTheme } from 'styled-components/macro' +import { useTheme } from 'styled-components' import { ButtonConfirmed, ButtonError, ButtonLight, ButtonPrimary } from '../../components/Button' import { BlueCard, LightCard } from '../../components/Card' diff --git a/src/pages/RemoveLiquidity/styled.ts b/src/pages/RemoveLiquidity/styled.ts index 4e7f8eb81c..60c46580d9 100644 --- a/src/pages/RemoveLiquidity/styled.ts +++ b/src/pages/RemoveLiquidity/styled.ts @@ -1,6 +1,6 @@ import { MaxButton } from 'pages/Pool/styleds' import { Text } from 'rebass' -import styled from 'styled-components/macro' +import styled from 'styled-components' export const Wrapper = styled.div` position: relative; diff --git a/src/pages/Swap/UniswapXOptIn.tsx b/src/pages/Swap/UniswapXOptIn.tsx index 497781852b..8e375ffd90 100644 --- a/src/pages/Swap/UniswapXOptIn.tsx +++ b/src/pages/Swap/UniswapXOptIn.tsx @@ -24,7 +24,7 @@ import { isClassicTrade } from 'state/routing/utils' import { SwapInfo } from 'state/swap/hooks' import { useRouterPreference, useUserDisabledUniswapX } from 'state/user/hooks' import { updateDisabledUniswapX } from 'state/user/reducer' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ThemedText } from 'theme' export const UniswapXOptIn = (props: { swapInfo: SwapInfo; isSmall: boolean }) => { diff --git a/src/pages/Swap/index.tsx b/src/pages/Swap/index.tsx index 4bd46b4dbf..76bd2f3e1a 100644 --- a/src/pages/Swap/index.tsx +++ b/src/pages/Swap/index.tsx @@ -55,7 +55,7 @@ import { isClassicTrade, isUniswapXTrade } from 'state/routing/utils' import { Field, replaceSwapState } from 'state/swap/actions' import { useDefaultsFromURLSearch, useDerivedSwapInfo, useSwapActionHandlers } from 'state/swap/hooks' import swapReducer, { initialState as initialSwapState, SwapState } from 'state/swap/reducer' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import { LinkStyledButton, ThemedText } from 'theme' import { computeFiatValuePriceImpact } from 'utils/computeFiatValuePriceImpact' import { maxAmountSpend } from 'utils/maxAmountSpend' diff --git a/src/pages/Tokens/index.tsx b/src/pages/Tokens/index.tsx index 44c90fcde7..dcd01d2ec6 100644 --- a/src/pages/Tokens/index.tsx +++ b/src/pages/Tokens/index.tsx @@ -11,7 +11,7 @@ import { MouseoverTooltip } from 'components/Tooltip' import { useResetAtom } from 'jotai/utils' import { useEffect } from 'react' import { useLocation } from 'react-router-dom' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ThemedText } from 'theme' const ExploreContainer = styled.div` diff --git a/src/pages/Vote/Landing.tsx b/src/pages/Vote/Landing.tsx index c689ce4223..82e874d50a 100644 --- a/src/pages/Vote/Landing.tsx +++ b/src/pages/Vote/Landing.tsx @@ -23,7 +23,7 @@ import { ApplicationModal } from 'state/application/reducer' import { useTokenBalance } from 'state/connection/hooks' import { ProposalData, ProposalState } from 'state/governance/hooks' import { useAllProposalData, useUserDelegatee, useUserVotes } from 'state/governance/hooks' -import styled, { useTheme } from 'styled-components/macro' +import styled, { useTheme } from 'styled-components' import { ExternalLink, ThemedText } from 'theme' import { shortenAddress } from 'utils' import { ExplorerDataType, getExplorerLink } from 'utils/getExplorerLink' diff --git a/src/pages/Vote/VotePage.tsx b/src/pages/Vote/VotePage.tsx index ff32695d11..1948093fee 100644 --- a/src/pages/Vote/VotePage.tsx +++ b/src/pages/Vote/VotePage.tsx @@ -10,12 +10,12 @@ import { useActiveLocale } from 'hooks/useActiveLocale' import useCurrentBlockTimestamp from 'hooks/useCurrentBlockTimestamp' import JSBI from 'jsbi' import useBlockNumber from 'lib/hooks/useBlockNumber' -import ms from 'ms.macro' +import ms from 'ms' import { useState } from 'react' import { ArrowLeft } from 'react-feather' import ReactMarkdown from 'react-markdown' import { useParams } from 'react-router-dom' -import styled from 'styled-components/macro' +import styled from 'styled-components' import { ButtonPrimary } from '../../components/Button' import { GrayCard } from '../../components/Card' @@ -154,7 +154,7 @@ function getDateFromBlock( date.setTime( currentTimestamp .add(BigNumber.from(averageBlockTimeInSeconds).mul(BigNumber.from(targetBlock - currentBlock))) - .toNumber() * ms`1 second` + .toNumber() * ms(`1s`) ) return date } @@ -218,7 +218,7 @@ export default function VotePage() { timeZoneName: 'short', } // convert the eta to milliseconds before it's a date - const eta = proposalData?.eta ? new Date(proposalData.eta.mul(ms`1 second`).toNumber()) : undefined + const eta = proposalData?.eta ? new Date(proposalData.eta.mul(ms(`1s`)).toNumber()) : undefined // get total votes and format percentages for UI const totalVotes = proposalData?.forCount?.add(proposalData.againstCount) diff --git a/src/pages/Vote/styled.tsx b/src/pages/Vote/styled.tsx index f08ae5ca08..0076b2d58e 100644 --- a/src/pages/Vote/styled.tsx +++ b/src/pages/Vote/styled.tsx @@ -1,5 +1,5 @@ import { Trans } from '@lingui/macro' -import styled, { DefaultTheme } from 'styled-components/macro' +import styled, { DefaultTheme } from 'styled-components' import { ProposalState } from '../../state/governance/hooks' diff --git a/src/setupTests.ts b/src/setupTests.ts index c2de360f7f..d7798baad0 100644 --- a/src/setupTests.ts +++ b/src/setupTests.ts @@ -1,4 +1,5 @@ import '@testing-library/jest-dom' // jest custom assertions +import '@vanilla-extract/css/disableRuntimeStyles' // https://vanilla-extract.style/documentation/test-environments/#disabling-runtime-styles import 'polyfills' import 'jest-styled-components' // adds style diffs to snapshot tests import 'polyfills' diff --git a/src/state/lists/updater.ts b/src/state/lists/updater.ts index c9a5779acb..bf53bb980e 100644 --- a/src/state/lists/updater.ts +++ b/src/state/lists/updater.ts @@ -2,7 +2,7 @@ import { getVersionUpgrade, VersionUpgrade } from '@uniswap/token-lists' import { useWeb3React } from '@web3-react/core' import { DEFAULT_LIST_OF_LISTS, UNSUPPORTED_LIST_URLS } from 'constants/lists' import useInterval from 'lib/hooks/useInterval' -import ms from 'ms.macro' +import ms from 'ms' import { useCallback, useEffect } from 'react' import { useAppDispatch } from 'state/hooks' import { useAllLists } from 'state/lists/hooks' @@ -31,7 +31,7 @@ export default function Updater(): null { }, [fetchList, isWindowVisible]) // fetch all lists every 10 minutes, but only after we initialize provider - useInterval(fetchAllListsCallback, provider ? ms`10m` : null) + useInterval(fetchAllListsCallback, provider ? ms(`10m`) : null) // whenever a list is not loaded and not loading, try again to load it useEffect(() => { diff --git a/src/state/routing/slice.ts b/src/state/routing/slice.ts index 90ae09e89c..c0f4d64390 100644 --- a/src/state/routing/slice.ts +++ b/src/state/routing/slice.ts @@ -1,12 +1,14 @@ import { createApi, fetchBaseQuery, FetchBaseQueryError } from '@reduxjs/toolkit/query/react' import { Protocol } from '@uniswap/router-sdk' -import { ChainId, TradeType } from '@uniswap/sdk-core' +import { TradeType } from '@uniswap/sdk-core' import { isUniswapXSupportedChain } from 'constants/chains' import { getClientSideQuote } from 'lib/hooks/routing/clientSideSmartOrderRouter' -import ms from 'ms.macro' +import ms from 'ms' import { trace } from 'tracing/trace' import { + GetQuoteArgs, + INTERNAL_ROUTER_PREFERENCE_PRICE, QuoteMethod, QuoteState, RouterPreference, @@ -23,36 +25,10 @@ if (UNISWAP_API_URL === undefined) { throw new Error(`UNISWAP_API_URL must be a defined environment variable`) } -// This is excluded from `RouterPreference` enum because it's only used -// internally for token -> USDC trades to get a USD value. -export const INTERNAL_ROUTER_PREFERENCE_PRICE = 'price' as const - const CLIENT_PARAMS = { protocols: [Protocol.V2, Protocol.V3, Protocol.MIXED], } -export interface GetQuoteArgs { - tokenInAddress: string - tokenInChainId: ChainId - tokenInDecimals: number - tokenInSymbol?: string - tokenOutAddress: string - tokenOutChainId: ChainId - tokenOutDecimals: number - tokenOutSymbol?: string - amount: string - account?: string - routerPreference: RouterPreference | typeof INTERNAL_ROUTER_PREFERENCE_PRICE - tradeType: TradeType - needsWrapIfUniswapX: boolean - uniswapXEnabled: boolean - uniswapXForceSyntheticQuotes: boolean - forceUniswapXOn: boolean - userDisabledUniswapX: boolean - isRoutingAPIPrice?: boolean - uniswapXEthOutputEnabled: boolean -} - const protocols: Protocol[] = [Protocol.V2, Protocol.V3, Protocol.MIXED] // routing API quote query params: https://github.com/Uniswap/routing-api/blob/main/lib/handlers/quote/schema/quote-schema.ts @@ -214,7 +190,7 @@ export const routingApi = createApi({ return { error: { status: 'CUSTOM_ERROR', error: error?.detail ?? error?.message ?? error } } } }, - keepUnusedDataFor: ms`10s`, + keepUnusedDataFor: ms(`10s`), extraOptions: { maxRetries: 0, }, diff --git a/src/state/routing/types.ts b/src/state/routing/types.ts index 0f5c9bc92a..49649eac91 100644 --- a/src/state/routing/types.ts +++ b/src/state/routing/types.ts @@ -1,5 +1,5 @@ import { MixedRouteSDK, Protocol, Trade } from '@uniswap/router-sdk' -import { Currency, CurrencyAmount, Percent, Token, TradeType } from '@uniswap/sdk-core' +import { ChainId, Currency, CurrencyAmount, Percent, Token, TradeType } from '@uniswap/sdk-core' import { DutchOrderInfo, DutchOrderInfoJSON, DutchOrderTrade as IDutchOrderTrade } from '@uniswap/uniswapx-sdk' import { Route as V2Route } from '@uniswap/v2-sdk' import { Route as V3Route } from '@uniswap/v3-sdk' @@ -18,12 +18,38 @@ export enum QuoteMethod { CLIENT_SIDE_FALLBACK = 'CLIENT_SIDE_FALLBACK', // If client-side was used after the routing-api call failed. } +// This is excluded from `RouterPreference` enum because it's only used +// internally for token -> USDC trades to get a USD value. +export const INTERNAL_ROUTER_PREFERENCE_PRICE = 'price' as const + export enum RouterPreference { X = 'uniswapx', API = 'api', CLIENT = 'client', } +export interface GetQuoteArgs { + tokenInAddress: string + tokenInChainId: ChainId + tokenInDecimals: number + tokenInSymbol?: string + tokenOutAddress: string + tokenOutChainId: ChainId + tokenOutDecimals: number + tokenOutSymbol?: string + amount: string + account?: string + routerPreference: RouterPreference | typeof INTERNAL_ROUTER_PREFERENCE_PRICE + tradeType: TradeType + needsWrapIfUniswapX: boolean + uniswapXEnabled: boolean + uniswapXForceSyntheticQuotes: boolean + uniswapXEthOutputEnabled: boolean + forceUniswapXOn: boolean + userDisabledUniswapX: boolean + isRoutingAPIPrice?: boolean +} + // from https://github.com/Uniswap/routing-api/blob/main/lib/handlers/schema.ts type TokenInRoute = Pick diff --git a/src/state/routing/useRoutingAPITrade.ts b/src/state/routing/useRoutingAPITrade.ts index 34ab580942..c6affe93a4 100644 --- a/src/state/routing/useRoutingAPITrade.ts +++ b/src/state/routing/useRoutingAPITrade.ts @@ -4,12 +4,19 @@ import { IMetric, MetricLoggerUnit, setGlobalMetric } from '@uniswap/smart-order import { sendTiming } from 'components/analytics' import { AVERAGE_L1_BLOCK_TIME } from 'constants/chainInfo' import { useRoutingAPIArguments } from 'lib/hooks/routing/useRoutingAPIArguments' -import ms from 'ms.macro' +import ms from 'ms' import { useMemo } from 'react' -import { INTERNAL_ROUTER_PREFERENCE_PRICE } from 'state/routing/slice' -import { useGetQuoteQuery } from 'state/routing/slice' -import { ClassicTrade, InterfaceTrade, QuoteMethod, QuoteState, RouterPreference, TradeState } from './types' +import { useGetQuoteQuery } from './slice' +import { + ClassicTrade, + InterfaceTrade, + INTERNAL_ROUTER_PREFERENCE_PRICE, + QuoteMethod, + QuoteState, + RouterPreference, + TradeState, +} from './types' const TRADE_NOT_FOUND = { state: TradeState.NO_ROUTE_FOUND, trade: undefined } as const const TRADE_LOADING = { state: TradeState.LOADING, trade: undefined } as const @@ -80,7 +87,7 @@ export function useRoutingAPITrade( currentData: currentTradeResult, } = useGetQuoteQuery(queryArgs ?? skipToken, { // Price-fetching is informational and costly, so it's done less frequently. - pollingInterval: routerPreference === INTERNAL_ROUTER_PREFERENCE_PRICE ? ms`1m` : AVERAGE_L1_BLOCK_TIME, + pollingInterval: routerPreference === INTERNAL_ROUTER_PREFERENCE_PRICE ? ms(`1m`) : AVERAGE_L1_BLOCK_TIME, // If latest quote from cache was fetched > 2m ago, instantly repoll for another instead of waiting for next poll period refetchOnMountOrArgChange: 2 * 60, }) diff --git a/src/state/routing/utils.ts b/src/state/routing/utils.ts index 2f2664d59c..a0ad403dae 100644 --- a/src/state/routing/utils.ts +++ b/src/state/routing/utils.ts @@ -11,12 +11,13 @@ import { isAvalanche, isBsc, isMatic, nativeOnChain } from 'constants/tokens' import { toSlippagePercent } from 'utils/slippage' import { getApproveInfo, getWrapInfo } from './gas' -import { GetQuoteArgs, INTERNAL_ROUTER_PREFERENCE_PRICE } from './slice' import { ClassicQuoteData, ClassicTrade, DutchOrderTrade, + GetQuoteArgs, InterfaceTrade, + INTERNAL_ROUTER_PREFERENCE_PRICE, isClassicQuoteResponse, PoolType, QuoteMethod, diff --git a/src/theme/components/SegmentedControl.tsx b/src/theme/components/SegmentedControl.tsx index edcd9e76cc..9963f24178 100644 --- a/src/theme/components/SegmentedControl.tsx +++ b/src/theme/components/SegmentedControl.tsx @@ -1,7 +1,7 @@ import Row, { AutoRow } from 'components/Row' import { PropsWithChildren } from 'react' import { Icon } from 'react-feather' -import styled, { css } from 'styled-components/macro' +import styled, { css } from 'styled-components' import { ThemedText } from 'theme' const SegmentWrapper = styled(AutoRow)<{ active?: boolean }>` diff --git a/src/theme/components/ThemeToggle.tsx b/src/theme/components/ThemeToggle.tsx index 3e67284975..c7cd5f26d4 100644 --- a/src/theme/components/ThemeToggle.tsx +++ b/src/theme/components/ThemeToggle.tsx @@ -2,7 +2,7 @@ import { Trans } from '@lingui/macro' import Row from 'components/Row' import { atom, useAtom } from 'jotai' import { atomWithStorage, useAtomValue, useUpdateAtom } from 'jotai/utils' -import ms from 'ms.macro' +import ms from 'ms' import { useCallback, useEffect, useMemo } from 'react' import { Moon, Sun } from 'react-feather' import { addMediaQueryListener, removeMediaQueryListener } from 'utils/matchMedia' @@ -10,7 +10,7 @@ import { addMediaQueryListener, removeMediaQueryListener } from 'utils/matchMedi import { Segment, SegmentedControl } from './SegmentedControl' import { ThemedText } from './text' -const THEME_UPDATE_DELAY = ms`0.1s` +const THEME_UPDATE_DELAY = ms(`0.1s`) const DARKMODE_MEDIA_QUERY = window.matchMedia('(prefers-color-scheme: dark)') export enum ThemeMode { diff --git a/src/theme/components/index.tsx b/src/theme/components/index.tsx index 0018861c45..b733642d11 100644 --- a/src/theme/components/index.tsx +++ b/src/theme/components/index.tsx @@ -22,7 +22,7 @@ import { X, } from 'react-feather' import { Link } from 'react-router-dom' -import styled, { css, keyframes } from 'styled-components/macro' +import styled, { css, keyframes } from 'styled-components' import { Z_INDEX } from 'theme/zIndex' import { ReactComponent as TooltipTriangle } from '../../assets/svg/tooltip_triangle.svg' diff --git a/src/theme/components/text.tsx b/src/theme/components/text.tsx index a0e3b3f6fb..d18b3ce3b9 100644 --- a/src/theme/components/text.tsx +++ b/src/theme/components/text.tsx @@ -3,7 +3,7 @@ */ import { Text, TextProps as TextPropsOriginal } from 'rebass' -import styled from 'styled-components/macro' +import styled from 'styled-components' const TextWrapper = styled(Text).withConfig({ shouldForwardProp: (prop) => prop !== 'color', diff --git a/src/theme/index.tsx b/src/theme/index.tsx index e1b7756076..a4f236b6dc 100644 --- a/src/theme/index.tsx +++ b/src/theme/index.tsx @@ -1,6 +1,6 @@ import { rootCssString } from 'nft/css/cssStringFromTheme' import React, { useMemo } from 'react' -import { createGlobalStyle, css, ThemeProvider as StyledComponentsThemeProvider } from 'styled-components/macro' +import { createGlobalStyle, css, ThemeProvider as StyledComponentsThemeProvider } from 'styled-components' import { useIsDarkMode } from 'theme/components/ThemeToggle' import { navDimensions } from '../nft/css/sprinkles.css' diff --git a/src/theme/styled.d.ts b/src/theme/styled.d.ts index 18a1069784..031cf3a181 100644 --- a/src/theme/styled.d.ts +++ b/src/theme/styled.d.ts @@ -2,7 +2,7 @@ import { getTheme } from './index' type InferredTheme = ReturnType -declare module 'styled-components/macro' { +declare module 'styled-components' { export interface DefaultTheme extends InferredTheme { // An interface declaring no members is equivalent to its supertype. // That's why we redeclare a `darkMode` property in order to tell TypeScript our Theme is an InferredTheme diff --git a/src/theme/styles.ts b/src/theme/styles.ts index 30494d8e05..9061e5449f 100644 --- a/src/theme/styles.ts +++ b/src/theme/styles.ts @@ -1,4 +1,4 @@ -import { css, keyframes } from 'styled-components/macro' +import { css, keyframes } from 'styled-components' export const flexColumnNoWrap = css` display: flex; diff --git a/yarn.lock b/yarn.lock index a2d9cf15c4..72bd40effd 100644 --- a/yarn.lock +++ b/yarn.lock @@ -173,31 +173,31 @@ dependencies: "@babel/highlight" "^7.22.5" -"@babel/compat-data@^7.17.7", "@babel/compat-data@^7.20.5", "@babel/compat-data@^7.22.5", "@babel/compat-data@^7.22.6": - version "7.22.6" - resolved "https://registry.yarnpkg.com/@babel/compat-data/-/compat-data-7.22.6.tgz#15606a20341de59ba02cd2fcc5086fcbe73bf544" - integrity sha512-29tfsWTq2Ftu7MXmimyC0C5FDZv5DYxOZkh3XD3+QW4V/BYuv/LyEsjj3c0hqedEaDt6DBfDvexMKU8YevdqFg== +"@babel/compat-data@^7.17.7", "@babel/compat-data@^7.20.5", "@babel/compat-data@^7.22.5", "@babel/compat-data@^7.22.6", "@babel/compat-data@^7.22.9": + version "7.22.9" + resolved "https://registry.yarnpkg.com/@babel/compat-data/-/compat-data-7.22.9.tgz#71cdb00a1ce3a329ce4cbec3a44f9fef35669730" + integrity sha512-5UamI7xkUcJ3i9qVDS+KFDEK8/7oJ55/sJMB1Ge7IEapr7KfdfV/HErR+koZwOfd+SgtFKOKRhRakdg++DcJpQ== -"@babel/core@^7.1.0", "@babel/core@^7.11.1", "@babel/core@^7.11.6", "@babel/core@^7.12.3", "@babel/core@^7.13.10", "@babel/core@^7.14.0", "@babel/core@^7.16.0", "@babel/core@^7.20.7", "@babel/core@^7.7.2", "@babel/core@^7.7.5", "@babel/core@^7.8.0": - version "7.22.5" - resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.22.5.tgz#d67d9747ecf26ee7ecd3ebae1ee22225fe902a89" - integrity sha512-SBuTAjg91A3eKOvD+bPEz3LlhHZRNu1nFOVts9lzDJTXshHTjII0BAtDS3Y2DAkdZdDKWVZGVwkDfc4Clxn1dg== +"@babel/core@^7.1.0", "@babel/core@^7.11.1", "@babel/core@^7.11.6", "@babel/core@^7.12.3", "@babel/core@^7.14.0", "@babel/core@^7.16.0", "@babel/core@^7.20.7", "@babel/core@^7.21.0", "@babel/core@^7.7.2", "@babel/core@^7.7.5", "@babel/core@^7.8.0": + version "7.22.9" + resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.22.9.tgz#bd96492c68822198f33e8a256061da3cf391f58f" + integrity sha512-G2EgeufBcYw27U4hhoIwFcgc1XU7TlXJ3mv04oOv1WCuo900U/anZSPzEqNjwdjgffkk2Gs0AN0dW1CKVLcG7w== dependencies: "@ampproject/remapping" "^2.2.0" "@babel/code-frame" "^7.22.5" - "@babel/generator" "^7.22.5" - "@babel/helper-compilation-targets" "^7.22.5" - "@babel/helper-module-transforms" "^7.22.5" - "@babel/helpers" "^7.22.5" - "@babel/parser" "^7.22.5" + "@babel/generator" "^7.22.9" + "@babel/helper-compilation-targets" "^7.22.9" + "@babel/helper-module-transforms" "^7.22.9" + "@babel/helpers" "^7.22.6" + "@babel/parser" "^7.22.7" "@babel/template" "^7.22.5" - "@babel/traverse" "^7.22.5" + "@babel/traverse" "^7.22.8" "@babel/types" "^7.22.5" convert-source-map "^1.7.0" debug "^4.1.0" gensync "^1.0.0-beta.2" json5 "^2.2.2" - semver "^6.3.0" + semver "^6.3.1" "@babel/eslint-parser@^7.16.3": version "7.21.3" @@ -208,10 +208,10 @@ eslint-visitor-keys "^2.1.0" semver "^6.3.0" -"@babel/generator@^7.11.6", "@babel/generator@^7.14.0", "@babel/generator@^7.18.13", "@babel/generator@^7.22.5", "@babel/generator@^7.7.2": - version "7.22.5" - resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.22.5.tgz#1e7bf768688acfb05cf30b2369ef855e82d984f7" - integrity sha512-+lcUbnTRhd0jOewtFSedLyiPsD5tswKkbgcezOqqWFUVNEwoUTlpPOBmvhG7OXWLR4jMdv0czPGH5XbflnD1EA== +"@babel/generator@^7.14.0", "@babel/generator@^7.18.13", "@babel/generator@^7.21.1", "@babel/generator@^7.22.7", "@babel/generator@^7.22.9", "@babel/generator@^7.7.2": + version "7.22.9" + resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.22.9.tgz#572ecfa7a31002fa1de2a9d91621fd895da8493d" + integrity sha512-KtLMbmicyuK2Ak/FTCJVbDnkN1SlT8/kceFTiuDiiRUUSMnHMidxSCdG4ndkTOHHpoomWe/4xkvHkEOncwjYIw== dependencies: "@babel/types" "^7.22.5" "@jridgewell/gen-mapping" "^0.3.2" @@ -232,16 +232,16 @@ dependencies: "@babel/types" "^7.22.5" -"@babel/helper-compilation-targets@^7.17.7", "@babel/helper-compilation-targets@^7.20.7", "@babel/helper-compilation-targets@^7.22.5", "@babel/helper-compilation-targets@^7.22.6": - version "7.22.6" - resolved "https://registry.yarnpkg.com/@babel/helper-compilation-targets/-/helper-compilation-targets-7.22.6.tgz#e30d61abe9480aa5a83232eb31c111be922d2e52" - integrity sha512-534sYEqWD9VfUm3IPn2SLcH4Q3P86XL+QvqdC7ZsFrzyyPF3T4XGiVghF6PTYNdWg6pXuoqXxNQAhbYeEInTzA== +"@babel/helper-compilation-targets@^7.17.7", "@babel/helper-compilation-targets@^7.20.7", "@babel/helper-compilation-targets@^7.22.5", "@babel/helper-compilation-targets@^7.22.6", "@babel/helper-compilation-targets@^7.22.9": + version "7.22.9" + resolved "https://registry.yarnpkg.com/@babel/helper-compilation-targets/-/helper-compilation-targets-7.22.9.tgz#f9d0a7aaaa7cd32a3f31c9316a69f5a9bcacb892" + integrity sha512-7qYrNM6HjpnPHJbopxmb8hSPoZ0gsX8IvUS32JGVoy+pU9e5N0nLr1VjJoR6kA4d9dmGLxNYOjeB8sUDal2WMw== dependencies: - "@babel/compat-data" "^7.22.6" + "@babel/compat-data" "^7.22.9" "@babel/helper-validator-option" "^7.22.5" - "@nicolo-ribaudo/semver-v6" "^6.3.3" browserslist "^4.21.9" lru-cache "^5.1.1" + semver "^6.3.1" "@babel/helper-create-class-features-plugin@^7.18.6", "@babel/helper-create-class-features-plugin@^7.21.0", "@babel/helper-create-class-features-plugin@^7.22.5": version "7.22.6" @@ -324,19 +324,16 @@ dependencies: "@babel/types" "^7.22.5" -"@babel/helper-module-transforms@^7.22.5": - version "7.22.5" - resolved "https://registry.yarnpkg.com/@babel/helper-module-transforms/-/helper-module-transforms-7.22.5.tgz#0f65daa0716961b6e96b164034e737f60a80d2ef" - integrity sha512-+hGKDt/Ze8GFExiVHno/2dvG5IdstpzCq0y4Qc9OJ25D4q3pKfiIP/4Vp3/JvhDkLKsDK2api3q3fpIgiIF5bw== +"@babel/helper-module-transforms@^7.22.5", "@babel/helper-module-transforms@^7.22.9": + version "7.22.9" + resolved "https://registry.yarnpkg.com/@babel/helper-module-transforms/-/helper-module-transforms-7.22.9.tgz#92dfcb1fbbb2bc62529024f72d942a8c97142129" + integrity sha512-t+WA2Xn5K+rTeGtC8jCsdAH52bjggG5TKRuRrAGNM/mjIbO4GxvlLMFOEz9wXY5I2XQ60PMFsAG2WIcG82dQMQ== dependencies: "@babel/helper-environment-visitor" "^7.22.5" "@babel/helper-module-imports" "^7.22.5" "@babel/helper-simple-access" "^7.22.5" - "@babel/helper-split-export-declaration" "^7.22.5" + "@babel/helper-split-export-declaration" "^7.22.6" "@babel/helper-validator-identifier" "^7.22.5" - "@babel/template" "^7.22.5" - "@babel/traverse" "^7.22.5" - "@babel/types" "^7.22.5" "@babel/helper-optimise-call-expression@^7.22.5": version "7.22.5" @@ -386,7 +383,7 @@ dependencies: "@babel/types" "^7.22.5" -"@babel/helper-split-export-declaration@^7.18.6", "@babel/helper-split-export-declaration@^7.22.5", "@babel/helper-split-export-declaration@^7.22.6": +"@babel/helper-split-export-declaration@^7.18.6", "@babel/helper-split-export-declaration@^7.22.6": version "7.22.6" resolved "https://registry.yarnpkg.com/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.22.6.tgz#322c61b7310c0997fe4c323955667f18fcefb91c" integrity sha512-AsUnxuLhRYsisFiaJwvp1QF+I3KjD5FOxut14q/GzovUe6orHLesW2C7d754kRm53h5gqrz6sFl6sxc4BVtE/g== @@ -418,13 +415,13 @@ "@babel/traverse" "^7.22.5" "@babel/types" "^7.22.5" -"@babel/helpers@^7.22.5": - version "7.22.5" - resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.22.5.tgz#74bb4373eb390d1ceed74a15ef97767e63120820" - integrity sha512-pSXRmfE1vzcUIDFQcSGA5Mr+GxBV9oiRKDuDxXvWQQBCh8HoIjs/2DlDB7H8smac1IVrB9/xdXj2N3Wol9Cr+Q== +"@babel/helpers@^7.22.6": + version "7.22.6" + resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.22.6.tgz#8e61d3395a4f0c5a8060f309fb008200969b5ecd" + integrity sha512-YjDs6y/fVOYFV8hAf1rxd1QvR9wJe1pDBZ2AREKq/SDayfPzgk0PBnVuTCE5X1acEpMMNOVUqoe+OwiZGJ+OaA== dependencies: "@babel/template" "^7.22.5" - "@babel/traverse" "^7.22.5" + "@babel/traverse" "^7.22.6" "@babel/types" "^7.22.5" "@babel/highlight@^7.10.4", "@babel/highlight@^7.22.5": @@ -436,10 +433,10 @@ chalk "^2.0.0" js-tokens "^4.0.0" -"@babel/parser@^7.1.0", "@babel/parser@^7.11.5", "@babel/parser@^7.14.0", "@babel/parser@^7.14.7", "@babel/parser@^7.16.8", "@babel/parser@^7.20.7", "@babel/parser@^7.22.5": - version "7.22.5" - resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.22.5.tgz#721fd042f3ce1896238cf1b341c77eb7dee7dbea" - integrity sha512-DFZMC9LJUG9PLOclRC32G63UXwzqS2koQC8dkx+PLdmt1xSePYpbT/NbsrJy8Q/muXz7o/h/d4A7Fuyixm559Q== +"@babel/parser@^7.1.0", "@babel/parser@^7.14.0", "@babel/parser@^7.14.7", "@babel/parser@^7.16.8", "@babel/parser@^7.20.7", "@babel/parser@^7.21.2", "@babel/parser@^7.22.5", "@babel/parser@^7.22.7": + version "7.22.7" + resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.22.7.tgz#df8cf085ce92ddbdbf668a7f186ce848c9036cae" + integrity sha512-7NF8pOkHP5o2vpmGgNGcfAeCvOYhGLyA3Z4eBQkT1RJlWu47n63bCs93QfJ2hIAFCil7L5P2IWhs1oToVgrL0Q== "@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression@^7.22.5": version "7.22.5" @@ -525,16 +522,6 @@ resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-private-property-in-object/-/plugin-proposal-private-property-in-object-7.21.0-placeholder-for-preset-env.2.tgz#7844f9289546efa9febac2de4cfe358a050bd703" integrity sha512-SOSkfJDddaM7mak6cPEpswyTRnuRltl429hMraQEglW+OkovnCzsiszTmsrlY//qLFjCpQDFRvjdm2wA5pPm9w== -"@babel/plugin-proposal-private-property-in-object@^7.21.11": - version "7.21.11" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-private-property-in-object/-/plugin-proposal-private-property-in-object-7.21.11.tgz#69d597086b6760c4126525cfa154f34631ff272c" - integrity sha512-0QZ8qP/3RLDVBwBFoWAwCtgcDZJVwA5LUJRZU8x2YFfKNuFq161wK3cuGrALu5yiPu+vzwTAg/sMWVNeWeNyaw== - dependencies: - "@babel/helper-annotate-as-pure" "^7.18.6" - "@babel/helper-create-class-features-plugin" "^7.21.0" - "@babel/helper-plugin-utils" "^7.20.2" - "@babel/plugin-syntax-private-property-in-object" "^7.14.5" - "@babel/plugin-proposal-unicode-property-regex@^7.4.4": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-unicode-property-regex/-/plugin-proposal-unicode-property-regex-7.18.6.tgz#af613d2cd5e643643b65cded64207b15c85cb78e" @@ -634,7 +621,7 @@ dependencies: "@babel/helper-plugin-utils" "^7.8.0" -"@babel/plugin-syntax-jsx@^7.0.0", "@babel/plugin-syntax-jsx@^7.10.4", "@babel/plugin-syntax-jsx@^7.18.6", "@babel/plugin-syntax-jsx@^7.21.4", "@babel/plugin-syntax-jsx@^7.7.2": +"@babel/plugin-syntax-jsx@^7.0.0", "@babel/plugin-syntax-jsx@^7.18.6", "@babel/plugin-syntax-jsx@^7.21.4", "@babel/plugin-syntax-jsx@^7.7.2": version "7.22.5" resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-jsx/-/plugin-syntax-jsx-7.22.5.tgz#a6b68e84fb76e759fc3b93e901876ffabbe1d918" integrity sha512-gvyP4hZrgrs/wWMaocvxZ44Hw0b3W8Pe+cMxc8V1ULQ07oh8VNbIRaoD1LRZVTvD+0nieDKjfgKg89sD7rrKrg== @@ -1303,14 +1290,14 @@ core-js-pure "^3.16.0" regenerator-runtime "^0.13.4" -"@babel/runtime@^7.0.0", "@babel/runtime@^7.10.1", "@babel/runtime@^7.10.2", "@babel/runtime@^7.11.2", "@babel/runtime@^7.12.1", "@babel/runtime@^7.12.13", "@babel/runtime@^7.12.5", "@babel/runtime@^7.16.3", "@babel/runtime@^7.17.2", "@babel/runtime@^7.18.3", "@babel/runtime@^7.20.7", "@babel/runtime@^7.21.0", "@babel/runtime@^7.5.5", "@babel/runtime@^7.6.2", "@babel/runtime@^7.7.2", "@babel/runtime@^7.7.6", "@babel/runtime@^7.8.4", "@babel/runtime@^7.9.2": - version "7.21.5" - resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.21.5.tgz#8492dddda9644ae3bda3b45eabe87382caee7200" - integrity sha512-8jI69toZqqcsnqGGqwGS4Qb1VwLOEp4hz+CXPywcvjs60u3B4Pom/U/7rm4W8tMOYEB+E9wgD0mW1l3r8qlI9Q== +"@babel/runtime@^7.0.0", "@babel/runtime@^7.10.1", "@babel/runtime@^7.10.2", "@babel/runtime@^7.11.2", "@babel/runtime@^7.12.1", "@babel/runtime@^7.12.13", "@babel/runtime@^7.12.5", "@babel/runtime@^7.16.3", "@babel/runtime@^7.17.2", "@babel/runtime@^7.18.3", "@babel/runtime@^7.20.13", "@babel/runtime@^7.20.7", "@babel/runtime@^7.21.0", "@babel/runtime@^7.5.5", "@babel/runtime@^7.6.2", "@babel/runtime@^7.7.2", "@babel/runtime@^7.7.6", "@babel/runtime@^7.8.4", "@babel/runtime@^7.9.2": + version "7.22.6" + resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.22.6.tgz#57d64b9ae3cff1d67eb067ae117dac087f5bd438" + integrity sha512-wDb5pWm4WDdF6LFUde3Jl8WzPA+3ZbxYqkC6xAXuD3irdEHN1k0NfTRrJD8ZD378SJ61miMLCqIOXYhd8x+AJQ== dependencies: regenerator-runtime "^0.13.11" -"@babel/template@^7.12.13", "@babel/template@^7.18.10", "@babel/template@^7.20.7", "@babel/template@^7.22.5", "@babel/template@^7.3.3": +"@babel/template@^7.18.10", "@babel/template@^7.20.7", "@babel/template@^7.22.5", "@babel/template@^7.3.3": version "7.22.5" resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.22.5.tgz#0c8c4d944509875849bd0344ff0050756eefc6ec" integrity sha512-X7yV7eiwAxdj9k94NEylvbVHLiVG1nvzCV2EAowhxLTwODV1jl9UzZ48leOC0sH7OnuHrIkllaBgneUykIcZaw== @@ -1319,23 +1306,23 @@ "@babel/parser" "^7.22.5" "@babel/types" "^7.22.5" -"@babel/traverse@^7.14.0", "@babel/traverse@^7.16.8", "@babel/traverse@^7.22.5", "@babel/traverse@^7.4.5", "@babel/traverse@^7.7.2": - version "7.22.5" - resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.22.5.tgz#44bd276690db6f4940fdb84e1cb4abd2f729ccd1" - integrity sha512-7DuIjPgERaNo6r+PZwItpjCZEa5vyw4eJGufeLxrPdBXBoLcCJCIasvK6pK/9DVNrLZTLFhUGqaC6X/PA007TQ== +"@babel/traverse@^7.14.0", "@babel/traverse@^7.16.8", "@babel/traverse@^7.22.5", "@babel/traverse@^7.22.6", "@babel/traverse@^7.22.8", "@babel/traverse@^7.4.5", "@babel/traverse@^7.7.2": + version "7.22.8" + resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.22.8.tgz#4d4451d31bc34efeae01eac222b514a77aa4000e" + integrity sha512-y6LPR+wpM2I3qJrsheCTwhIinzkETbplIgPBbwvqPKc+uljeA5gP+3nP8irdYt1mjQaDnlIcG+dw8OjAco4GXw== dependencies: "@babel/code-frame" "^7.22.5" - "@babel/generator" "^7.22.5" + "@babel/generator" "^7.22.7" "@babel/helper-environment-visitor" "^7.22.5" "@babel/helper-function-name" "^7.22.5" "@babel/helper-hoist-variables" "^7.22.5" - "@babel/helper-split-export-declaration" "^7.22.5" - "@babel/parser" "^7.22.5" + "@babel/helper-split-export-declaration" "^7.22.6" + "@babel/parser" "^7.22.7" "@babel/types" "^7.22.5" debug "^4.1.0" globals "^11.1.0" -"@babel/types@^7.0.0", "@babel/types@^7.11.5", "@babel/types@^7.12.6", "@babel/types@^7.16.8", "@babel/types@^7.18.13", "@babel/types@^7.20.7", "@babel/types@^7.21.0", "@babel/types@^7.22.5", "@babel/types@^7.3.0", "@babel/types@^7.3.3", "@babel/types@^7.4.4": +"@babel/types@^7.0.0", "@babel/types@^7.12.6", "@babel/types@^7.16.8", "@babel/types@^7.18.13", "@babel/types@^7.20.7", "@babel/types@^7.21.0", "@babel/types@^7.21.2", "@babel/types@^7.22.5", "@babel/types@^7.3.0", "@babel/types@^7.3.3", "@babel/types@^7.4.4": version "7.22.5" resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.22.5.tgz#cd93eeaab025880a3a47ec881f4b096a5b786fbe" integrity sha512-zo3MIHGOkPOfoRXitsgHLjEXmlDaD/5KU1Uzuc9GNiZPhSqVxVRtxuPaSBZDsYZ9qV88AjtMtWW7ww98loJ9KA== @@ -1751,16 +1738,6 @@ resolved "https://registry.npmjs.org/@emotion/weak-memoize/-/weak-memoize-0.2.5.tgz" integrity sha512-6U71C2Wp7r5XtFtQzYrW5iKFT67OixrSxjI4MptCHzdSVlgabczzqLe0ZSgnub/5Kp4hSbpDB1tMytZY9pwxxA== -"@endemolshinegroup/cosmiconfig-typescript-loader@^3.0.2": - version "3.0.2" - resolved "https://registry.npmjs.org/@endemolshinegroup/cosmiconfig-typescript-loader/-/cosmiconfig-typescript-loader-3.0.2.tgz" - integrity sha512-QRVtqJuS1mcT56oHpVegkKBlgtWjXw/gHNWO3eL9oyB5Sc7HBoc2OLG/nYpVfT/Jejvo3NUrD0Udk7XgoyDKkA== - dependencies: - lodash.get "^4" - make-error "^1" - ts-node "^9" - tslib "^2" - "@esbuild-plugins/node-globals-polyfill@^0.1.1": version "0.1.1" resolved "https://registry.yarnpkg.com/@esbuild-plugins/node-globals-polyfill/-/node-globals-polyfill-0.1.1.tgz#a313ab3efbb2c17c8ce376aa216c627c9b40f9d7" @@ -1779,10 +1756,10 @@ resolved "https://registry.yarnpkg.com/@esbuild/android-arm64/-/android-arm64-0.16.3.tgz#6af6d16be6d534d776a51fc215bfd81a68906d2c" integrity sha512-RolFVeinkeraDvN/OoRf1F/lP0KUfGNb5jxy/vkIMeRRChkrX/HTYN6TYZosRJs3a1+8wqpxAo5PI5hFmxyPRg== -"@esbuild/android-arm64@0.17.18": - version "0.17.18" - resolved "https://registry.yarnpkg.com/@esbuild/android-arm64/-/android-arm64-0.17.18.tgz#4aa8d8afcffb4458736ca9b32baa97d7cb5861ea" - integrity sha512-/iq0aK0eeHgSC3z55ucMAHO05OIqmQehiGay8eP5l/5l+iEr4EIbh4/MI8xD9qRFjqzgkc0JkX0LculNC9mXBw== +"@esbuild/android-arm64@0.17.19": + version "0.17.19" + resolved "https://registry.yarnpkg.com/@esbuild/android-arm64/-/android-arm64-0.17.19.tgz#bafb75234a5d3d1b690e7c2956a599345e84a2fd" + integrity sha512-KBMWvEZooR7+kzY0BtbTQn0OAYY7CsiydT63pVEaPtVYF0hXbUaOyZog37DKxK7NF3XacBJOpYT4adIJh+avxA== "@esbuild/android-arm64@0.17.6": version "0.17.6" @@ -1794,10 +1771,10 @@ resolved "https://registry.yarnpkg.com/@esbuild/android-arm/-/android-arm-0.16.3.tgz#2a091222f3b1928e3246fb3c5202eaca88baab67" integrity sha512-mueuEoh+s1eRbSJqq9KNBQwI4QhQV6sRXIfTyLXSHGMpyew61rOK4qY21uKbXl1iBoMb0AdL1deWFCQVlN2qHA== -"@esbuild/android-arm@0.17.18": - version "0.17.18" - resolved "https://registry.yarnpkg.com/@esbuild/android-arm/-/android-arm-0.17.18.tgz#74a7e95af4ee212ebc9db9baa87c06a594f2a427" - integrity sha512-EmwL+vUBZJ7mhFCs5lA4ZimpUH3WMAoqvOIYhVQwdIgSpHC8ImHdsRyhHAVxpDYUSm0lWvd63z0XH1IlImS2Qw== +"@esbuild/android-arm@0.17.19": + version "0.17.19" + resolved "https://registry.yarnpkg.com/@esbuild/android-arm/-/android-arm-0.17.19.tgz#5898f7832c2298bc7d0ab53701c57beb74d78b4d" + integrity sha512-rIKddzqhmav7MSmoFCmDIb6e2W57geRsM94gV2l38fzhXMwq7hZoClug9USI2pFRGL06f4IOPHHpFNOkWieR8A== "@esbuild/android-arm@0.17.6": version "0.17.6" @@ -1809,10 +1786,10 @@ resolved "https://registry.yarnpkg.com/@esbuild/android-x64/-/android-x64-0.16.3.tgz#a6d749c58b022d371dc40d50ac1bb4aebd1eb953" integrity sha512-SFpTUcIT1bIJuCCBMCQWq1bL2gPTjWoLZdjmIhjdcQHaUfV41OQfho6Ici5uvvkMmZRXIUGpM3GxysP/EU7ifQ== -"@esbuild/android-x64@0.17.18": - version "0.17.18" - resolved "https://registry.yarnpkg.com/@esbuild/android-x64/-/android-x64-0.17.18.tgz#1dcd13f201997c9fe0b204189d3a0da4eb4eb9b6" - integrity sha512-x+0efYNBF3NPW2Xc5bFOSFW7tTXdAcpfEg2nXmxegm4mJuVeS+i109m/7HMiOQ6M12aVGGFlqJX3RhNdYM2lWg== +"@esbuild/android-x64@0.17.19": + version "0.17.19" + resolved "https://registry.yarnpkg.com/@esbuild/android-x64/-/android-x64-0.17.19.tgz#658368ef92067866d95fb268719f98f363d13ae1" + integrity sha512-uUTTc4xGNDT7YSArp/zbtmbhO0uEEK9/ETW29Wk1thYUJBz3IVnvgEiEwEa9IeLyvnpKrWK64Utw2bgUmDveww== "@esbuild/android-x64@0.17.6": version "0.17.6" @@ -1824,10 +1801,10 @@ resolved "https://registry.yarnpkg.com/@esbuild/darwin-arm64/-/darwin-arm64-0.16.3.tgz#92d1826ed2f21dcac5830b70d7215c6afbb744e2" integrity sha512-DO8WykMyB+N9mIDfI/Hug70Dk1KipavlGAecxS3jDUwAbTpDXj0Lcwzw9svkhxfpCagDmpaTMgxWK8/C/XcXvw== -"@esbuild/darwin-arm64@0.17.18": - version "0.17.18" - resolved "https://registry.yarnpkg.com/@esbuild/darwin-arm64/-/darwin-arm64-0.17.18.tgz#444f3b961d4da7a89eb9bd35cfa4415141537c2a" - integrity sha512-6tY+djEAdF48M1ONWnQb1C+6LiXrKjmqjzPNPWXhu/GzOHTHX2nh8Mo2ZAmBFg0kIodHhciEgUBtcYCAIjGbjQ== +"@esbuild/darwin-arm64@0.17.19": + version "0.17.19" + resolved "https://registry.yarnpkg.com/@esbuild/darwin-arm64/-/darwin-arm64-0.17.19.tgz#584c34c5991b95d4d48d333300b1a4e2ff7be276" + integrity sha512-80wEoCfF/hFKM6WE1FyBHc9SfUblloAWx6FJkFWTWiCoht9Mc0ARGEM47e67W9rI09YoUxJL68WHfDRYEAvOhg== "@esbuild/darwin-arm64@0.17.6": version "0.17.6" @@ -1839,10 +1816,10 @@ resolved "https://registry.yarnpkg.com/@esbuild/darwin-x64/-/darwin-x64-0.16.3.tgz#7fc3570c2b16e9ff4fc178593a0a4adb1ae8ea57" integrity sha512-uEqZQ2omc6BvWqdCiyZ5+XmxuHEi1SPzpVxXCSSV2+Sh7sbXbpeNhHIeFrIpRjAs0lI1FmA1iIOxFozKBhKgRQ== -"@esbuild/darwin-x64@0.17.18": - version "0.17.18" - resolved "https://registry.yarnpkg.com/@esbuild/darwin-x64/-/darwin-x64-0.17.18.tgz#a6da308d0ac8a498c54d62e0b2bfb7119b22d315" - integrity sha512-Qq84ykvLvya3dO49wVC9FFCNUfSrQJLbxhoQk/TE1r6MjHo3sFF2tlJCwMjhkBVq3/ahUisj7+EpRSz0/+8+9A== +"@esbuild/darwin-x64@0.17.19": + version "0.17.19" + resolved "https://registry.yarnpkg.com/@esbuild/darwin-x64/-/darwin-x64-0.17.19.tgz#7751d236dfe6ce136cce343dce69f52d76b7f6cb" + integrity sha512-IJM4JJsLhRYr9xdtLytPLSH9k/oxR3boaUIYiHkAawtwNOXKE8KoU8tMvryogdcT8AU+Bflmh81Xn6Q0vTZbQw== "@esbuild/darwin-x64@0.17.6": version "0.17.6" @@ -1854,10 +1831,10 @@ resolved "https://registry.yarnpkg.com/@esbuild/freebsd-arm64/-/freebsd-arm64-0.16.3.tgz#16735ce16f8c9a4e7289e9e259aa01a8d9874307" integrity sha512-nJansp3sSXakNkOD5i5mIz2Is/HjzIhFs49b1tjrPrpCmwgBmH9SSzhC/Z1UqlkivqMYkhfPwMw1dGFUuwmXhw== -"@esbuild/freebsd-arm64@0.17.18": - version "0.17.18" - resolved "https://registry.yarnpkg.com/@esbuild/freebsd-arm64/-/freebsd-arm64-0.17.18.tgz#b83122bb468889399d0d63475d5aea8d6829c2c2" - integrity sha512-fw/ZfxfAzuHfaQeMDhbzxp9mc+mHn1Y94VDHFHjGvt2Uxl10mT4CDavHm+/L9KG441t1QdABqkVYwakMUeyLRA== +"@esbuild/freebsd-arm64@0.17.19": + version "0.17.19" + resolved "https://registry.yarnpkg.com/@esbuild/freebsd-arm64/-/freebsd-arm64-0.17.19.tgz#cacd171665dd1d500f45c167d50c6b7e539d5fd2" + integrity sha512-pBwbc7DufluUeGdjSU5Si+P3SoMF5DQ/F/UmTSb8HXO80ZEAJmrykPyzo1IfNbAoaqw48YRpv8shwd1NoI0jcQ== "@esbuild/freebsd-arm64@0.17.6": version "0.17.6" @@ -1869,10 +1846,10 @@ resolved "https://registry.yarnpkg.com/@esbuild/freebsd-x64/-/freebsd-x64-0.16.3.tgz#f4edd1464cb072799ed6b8ab5178478e71c13459" integrity sha512-TfoDzLw+QHfc4a8aKtGSQ96Wa+6eimljjkq9HKR0rHlU83vw8aldMOUSJTUDxbcUdcgnJzPaX8/vGWm7vyV7ug== -"@esbuild/freebsd-x64@0.17.18": - version "0.17.18" - resolved "https://registry.yarnpkg.com/@esbuild/freebsd-x64/-/freebsd-x64-0.17.18.tgz#af59e0e03fcf7f221b34d4c5ab14094862c9c864" - integrity sha512-FQFbRtTaEi8ZBi/A6kxOC0V0E9B/97vPdYjY9NdawyLd4Qk5VD5g2pbWN2VR1c0xhzcJm74HWpObPszWC+qTew== +"@esbuild/freebsd-x64@0.17.19": + version "0.17.19" + resolved "https://registry.yarnpkg.com/@esbuild/freebsd-x64/-/freebsd-x64-0.17.19.tgz#0769456eee2a08b8d925d7c00b79e861cb3162e4" + integrity sha512-4lu+n8Wk0XlajEhbEffdy2xy53dpR06SlzvhGByyg36qJw6Kpfk7cp45DR/62aPH9mtJRmIyrXAS5UWBrJT6TQ== "@esbuild/freebsd-x64@0.17.6": version "0.17.6" @@ -1884,10 +1861,10 @@ resolved "https://registry.yarnpkg.com/@esbuild/linux-arm64/-/linux-arm64-0.16.3.tgz#4b7ae6fe3618d9a40d6ca39c6edc991ac1447203" integrity sha512-7I3RlsnxEFCHVZNBLb2w7unamgZ5sVwO0/ikE2GaYvYuUQs9Qte/w7TqWcXHtCwxvZx/2+F97ndiUQAWs47ZfQ== -"@esbuild/linux-arm64@0.17.18": - version "0.17.18" - resolved "https://registry.yarnpkg.com/@esbuild/linux-arm64/-/linux-arm64-0.17.18.tgz#8551d72ba540c5bce4bab274a81c14ed01eafdcf" - integrity sha512-R7pZvQZFOY2sxUG8P6A21eq6q+eBv7JPQYIybHVf1XkQYC+lT7nDBdC7wWKTrbvMXKRaGudp/dzZCwL/863mZQ== +"@esbuild/linux-arm64@0.17.19": + version "0.17.19" + resolved "https://registry.yarnpkg.com/@esbuild/linux-arm64/-/linux-arm64-0.17.19.tgz#38e162ecb723862c6be1c27d6389f48960b68edb" + integrity sha512-ct1Tg3WGwd3P+oZYqic+YZF4snNl2bsnMKRkb3ozHmnM0dGWuxcPTTntAF6bOP0Sp4x0PjSF+4uHQ1xvxfRKqg== "@esbuild/linux-arm64@0.17.6": version "0.17.6" @@ -1899,10 +1876,10 @@ resolved "https://registry.yarnpkg.com/@esbuild/linux-arm/-/linux-arm-0.16.3.tgz#4b3e9f849822e16a76a70844c4db68075b259a58" integrity sha512-VwswmSYwVAAq6LysV59Fyqk3UIjbhuc6wb3vEcJ7HEJUtFuLK9uXWuFoH1lulEbE4+5GjtHi3MHX+w1gNHdOWQ== -"@esbuild/linux-arm@0.17.18": - version "0.17.18" - resolved "https://registry.yarnpkg.com/@esbuild/linux-arm/-/linux-arm-0.17.18.tgz#e09e76e526df4f665d4d2720d28ff87d15cdf639" - integrity sha512-jW+UCM40LzHcouIaqv3e/oRs0JM76JfhHjCavPxMUti7VAPh8CaGSlS7cmyrdpzSk7A+8f0hiedHqr/LMnfijg== +"@esbuild/linux-arm@0.17.19": + version "0.17.19" + resolved "https://registry.yarnpkg.com/@esbuild/linux-arm/-/linux-arm-0.17.19.tgz#1a2cd399c50040184a805174a6d89097d9d1559a" + integrity sha512-cdmT3KxjlOQ/gZ2cjfrQOtmhG4HJs6hhvm3mWSRDPtZ/lP5oe8FWceS10JaSJC13GBd4eH/haHnqf7hhGNLerA== "@esbuild/linux-arm@0.17.6": version "0.17.6" @@ -1914,10 +1891,10 @@ resolved "https://registry.yarnpkg.com/@esbuild/linux-ia32/-/linux-ia32-0.16.3.tgz#2ff3936b91bfff62f9ecf7f6411ef399b29ed22d" integrity sha512-X8FDDxM9cqda2rJE+iblQhIMYY49LfvW4kaEjoFbTTQ4Go8G96Smj2w3BRTwA8IHGoi9dPOPGAX63dhuv19UqA== -"@esbuild/linux-ia32@0.17.18": - version "0.17.18" - resolved "https://registry.yarnpkg.com/@esbuild/linux-ia32/-/linux-ia32-0.17.18.tgz#47878860ce4fe73a36fd8627f5647bcbbef38ba4" - integrity sha512-ygIMc3I7wxgXIxk6j3V00VlABIjq260i967Cp9BNAk5pOOpIXmd1RFQJQX9Io7KRsthDrQYrtcx7QCof4o3ZoQ== +"@esbuild/linux-ia32@0.17.19": + version "0.17.19" + resolved "https://registry.yarnpkg.com/@esbuild/linux-ia32/-/linux-ia32-0.17.19.tgz#e28c25266b036ce1cabca3c30155222841dc035a" + integrity sha512-w4IRhSy1VbsNxHRQpeGCHEmibqdTUx61Vc38APcsRbuVgK0OPEnQ0YD39Brymn96mOx48Y2laBQGqgZ0j9w6SQ== "@esbuild/linux-ia32@0.17.6": version "0.17.6" @@ -1929,10 +1906,10 @@ resolved "https://registry.yarnpkg.com/@esbuild/linux-loong64/-/linux-loong64-0.16.3.tgz#ff8aa59f49d9ccbc1ff952ba1f5cd01a534562df" integrity sha512-hIbeejCOyO0X9ujfIIOKjBjNAs9XD/YdJ9JXAy1lHA+8UXuOqbFe4ErMCqMr8dhlMGBuvcQYGF7+kO7waj2KHw== -"@esbuild/linux-loong64@0.17.18": - version "0.17.18" - resolved "https://registry.yarnpkg.com/@esbuild/linux-loong64/-/linux-loong64-0.17.18.tgz#3f8fbf5267556fc387d20b2e708ce115de5c967a" - integrity sha512-bvPG+MyFs5ZlwYclCG1D744oHk1Pv7j8psF5TfYx7otCVmcJsEXgFEhQkbhNW8otDHL1a2KDINW20cfCgnzgMQ== +"@esbuild/linux-loong64@0.17.19": + version "0.17.19" + resolved "https://registry.yarnpkg.com/@esbuild/linux-loong64/-/linux-loong64-0.17.19.tgz#0f887b8bb3f90658d1a0117283e55dbd4c9dcf72" + integrity sha512-2iAngUbBPMq439a+z//gE+9WBldoMp1s5GWsUSgqHLzLJ9WoZLZhpwWuym0u0u/4XmZ3gpHmzV84PonE+9IIdQ== "@esbuild/linux-loong64@0.17.6": version "0.17.6" @@ -1944,10 +1921,10 @@ resolved "https://registry.yarnpkg.com/@esbuild/linux-mips64el/-/linux-mips64el-0.16.3.tgz#5dd5e118071c3912df69beedbfd11fb117f0fe5e" integrity sha512-znFRzICT/V8VZQMt6rjb21MtAVJv/3dmKRMlohlShrbVXdBuOdDrGb+C2cZGQAR8RFyRe7HS6klmHq103WpmVw== -"@esbuild/linux-mips64el@0.17.18": - version "0.17.18" - resolved "https://registry.yarnpkg.com/@esbuild/linux-mips64el/-/linux-mips64el-0.17.18.tgz#9d896d8f3c75f6c226cbeb840127462e37738226" - integrity sha512-oVqckATOAGuiUOa6wr8TXaVPSa+6IwVJrGidmNZS1cZVx0HqkTMkqFGD2HIx9H1RvOwFeWYdaYbdY6B89KUMxA== +"@esbuild/linux-mips64el@0.17.19": + version "0.17.19" + resolved "https://registry.yarnpkg.com/@esbuild/linux-mips64el/-/linux-mips64el-0.17.19.tgz#f5d2a0b8047ea9a5d9f592a178ea054053a70289" + integrity sha512-LKJltc4LVdMKHsrFe4MGNPp0hqDFA1Wpt3jE1gEyM3nKUvOiO//9PheZZHfYRfYl6AwdTH4aTcXSqBerX0ml4A== "@esbuild/linux-mips64el@0.17.6": version "0.17.6" @@ -1959,10 +1936,10 @@ resolved "https://registry.yarnpkg.com/@esbuild/linux-ppc64/-/linux-ppc64-0.16.3.tgz#36c62e24eae7fa3f0d921506da8fc1e6098a1364" integrity sha512-EV7LuEybxhXrVTDpbqWF2yehYRNz5e5p+u3oQUS2+ZFpknyi1NXxr8URk4ykR8Efm7iu04//4sBg249yNOwy5Q== -"@esbuild/linux-ppc64@0.17.18": - version "0.17.18" - resolved "https://registry.yarnpkg.com/@esbuild/linux-ppc64/-/linux-ppc64-0.17.18.tgz#3d9deb60b2d32c9985bdc3e3be090d30b7472783" - integrity sha512-3dLlQO+b/LnQNxgH4l9rqa2/IwRJVN9u/bK63FhOPB4xqiRqlQAU0qDU3JJuf0BmaH0yytTBdoSBHrb2jqc5qQ== +"@esbuild/linux-ppc64@0.17.19": + version "0.17.19" + resolved "https://registry.yarnpkg.com/@esbuild/linux-ppc64/-/linux-ppc64-0.17.19.tgz#876590e3acbd9fa7f57a2c7d86f83717dbbac8c7" + integrity sha512-/c/DGybs95WXNS8y3Ti/ytqETiW7EU44MEKuCAcpPto3YjQbyK3IQVKfF6nbghD7EcLUGl0NbiL5Rt5DMhn5tg== "@esbuild/linux-ppc64@0.17.6": version "0.17.6" @@ -1974,10 +1951,10 @@ resolved "https://registry.yarnpkg.com/@esbuild/linux-riscv64/-/linux-riscv64-0.16.3.tgz#f0fec8e7affb5bcc817fefc61a21cbb95539e393" integrity sha512-uDxqFOcLzFIJ+r/pkTTSE9lsCEaV/Y6rMlQjUI9BkzASEChYL/aSQjZjchtEmdnVxDKETnUAmsaZ4pqK1eE5BQ== -"@esbuild/linux-riscv64@0.17.18": - version "0.17.18" - resolved "https://registry.yarnpkg.com/@esbuild/linux-riscv64/-/linux-riscv64-0.17.18.tgz#8a943cf13fd24ff7ed58aefb940ef178f93386bc" - integrity sha512-/x7leOyDPjZV3TcsdfrSI107zItVnsX1q2nho7hbbQoKnmoeUWjs+08rKKt4AUXju7+3aRZSsKrJtaRmsdL1xA== +"@esbuild/linux-riscv64@0.17.19": + version "0.17.19" + resolved "https://registry.yarnpkg.com/@esbuild/linux-riscv64/-/linux-riscv64-0.17.19.tgz#7f49373df463cd9f41dc34f9b2262d771688bf09" + integrity sha512-FC3nUAWhvFoutlhAkgHf8f5HwFWUL6bYdvLc/TTuxKlvLi3+pPzdZiFKSWz/PF30TB1K19SuCxDTI5KcqASJqA== "@esbuild/linux-riscv64@0.17.6": version "0.17.6" @@ -1989,10 +1966,10 @@ resolved "https://registry.yarnpkg.com/@esbuild/linux-s390x/-/linux-s390x-0.16.3.tgz#22e10edd6e91f53c2e1f60e46abd453d7794409b" integrity sha512-NbeREhzSxYwFhnCAQOQZmajsPYtX71Ufej3IQ8W2Gxskfz9DK58ENEju4SbpIj48VenktRASC52N5Fhyf/aliQ== -"@esbuild/linux-s390x@0.17.18": - version "0.17.18" - resolved "https://registry.yarnpkg.com/@esbuild/linux-s390x/-/linux-s390x-0.17.18.tgz#66cb01f4a06423e5496facabdce4f7cae7cb80e5" - integrity sha512-cX0I8Q9xQkL/6F5zWdYmVf5JSQt+ZfZD2bJudZrWD+4mnUvoZ3TDDXtDX2mUaq6upMFv9FlfIh4Gfun0tbGzuw== +"@esbuild/linux-s390x@0.17.19": + version "0.17.19" + resolved "https://registry.yarnpkg.com/@esbuild/linux-s390x/-/linux-s390x-0.17.19.tgz#e2afd1afcaf63afe2c7d9ceacd28ec57c77f8829" + integrity sha512-IbFsFbxMWLuKEbH+7sTkKzL6NJmG2vRyy6K7JJo55w+8xDk7RElYn6xvXtDW8HCfoKBFK69f3pgBJSUSQPr+4Q== "@esbuild/linux-s390x@0.17.6": version "0.17.6" @@ -2004,10 +1981,10 @@ resolved "https://registry.yarnpkg.com/@esbuild/linux-x64/-/linux-x64-0.16.3.tgz#38388b73fd9eebe45b073d7d8099b9c2e54f7139" integrity sha512-SDiG0nCixYO9JgpehoKgScwic7vXXndfasjnD5DLbp1xltANzqZ425l7LSdHynt19UWOcDjG9wJJzSElsPvk0w== -"@esbuild/linux-x64@0.17.18": - version "0.17.18" - resolved "https://registry.yarnpkg.com/@esbuild/linux-x64/-/linux-x64-0.17.18.tgz#23c26050c6c5d1359c7b774823adc32b3883b6c9" - integrity sha512-66RmRsPlYy4jFl0vG80GcNRdirx4nVWAzJmXkevgphP1qf4dsLQCpSKGM3DUQCojwU1hnepI63gNZdrr02wHUA== +"@esbuild/linux-x64@0.17.19": + version "0.17.19" + resolved "https://registry.yarnpkg.com/@esbuild/linux-x64/-/linux-x64-0.17.19.tgz#8a0e9738b1635f0c53389e515ae83826dec22aa4" + integrity sha512-68ngA9lg2H6zkZcyp22tsVt38mlhWde8l3eJLWkyLrp4HwMUr3c1s/M2t7+kHIhvMjglIBrFpncX1SzMckomGw== "@esbuild/linux-x64@0.17.6": version "0.17.6" @@ -2019,10 +1996,10 @@ resolved "https://registry.yarnpkg.com/@esbuild/netbsd-x64/-/netbsd-x64-0.16.3.tgz#e0270569567f1530b8dbe6d11d5b4930b9cc71ae" integrity sha512-AzbsJqiHEq1I/tUvOfAzCY15h4/7Ivp3ff/o1GpP16n48JMNAtbW0qui2WCgoIZArEHD0SUQ95gvR0oSO7ZbdA== -"@esbuild/netbsd-x64@0.17.18": - version "0.17.18" - resolved "https://registry.yarnpkg.com/@esbuild/netbsd-x64/-/netbsd-x64-0.17.18.tgz#789a203d3115a52633ff6504f8cbf757f15e703b" - integrity sha512-95IRY7mI2yrkLlTLb1gpDxdC5WLC5mZDi+kA9dmM5XAGxCME0F8i4bYH4jZreaJ6lIZ0B8hTrweqG1fUyW7jbg== +"@esbuild/netbsd-x64@0.17.19": + version "0.17.19" + resolved "https://registry.yarnpkg.com/@esbuild/netbsd-x64/-/netbsd-x64-0.17.19.tgz#c29fb2453c6b7ddef9a35e2c18b37bda1ae5c462" + integrity sha512-CwFq42rXCR8TYIjIfpXCbRX0rp1jo6cPIUPSaWwzbVI4aOfX96OXY8M6KNmtPcg7QjYeDmN+DD0Wp3LaBOLf4Q== "@esbuild/netbsd-x64@0.17.6": version "0.17.6" @@ -2034,10 +2011,10 @@ resolved "https://registry.yarnpkg.com/@esbuild/openbsd-x64/-/openbsd-x64-0.16.3.tgz#3b16642d443848bca605f33ee3978a1890911e6d" integrity sha512-gSABi8qHl8k3Cbi/4toAzHiykuBuWLZs43JomTcXkjMZVkp0gj3gg9mO+9HJW/8GB5H89RX/V0QP4JGL7YEEVg== -"@esbuild/openbsd-x64@0.17.18": - version "0.17.18" - resolved "https://registry.yarnpkg.com/@esbuild/openbsd-x64/-/openbsd-x64-0.17.18.tgz#d7b998a30878f8da40617a10af423f56f12a5e90" - integrity sha512-WevVOgcng+8hSZ4Q3BKL3n1xTv5H6Nb53cBrtzzEjDbbnOmucEVcZeGCsCOi9bAOcDYEeBZbD2SJNBxlfP3qiA== +"@esbuild/openbsd-x64@0.17.19": + version "0.17.19" + resolved "https://registry.yarnpkg.com/@esbuild/openbsd-x64/-/openbsd-x64-0.17.19.tgz#95e75a391403cb10297280d524d66ce04c920691" + integrity sha512-cnq5brJYrSZ2CF6c35eCmviIN3k3RczmHz8eYaVlNasVqsNY+JKohZU5MKmaOI+KkllCdzOKKdPs762VCPC20g== "@esbuild/openbsd-x64@0.17.6": version "0.17.6" @@ -2049,10 +2026,10 @@ resolved "https://registry.yarnpkg.com/@esbuild/sunos-x64/-/sunos-x64-0.16.3.tgz#a838f247867380f0ae25ce1936dc5ab6f57b7734" integrity sha512-SF9Kch5Ete4reovvRO6yNjMxrvlfT0F0Flm+NPoUw5Z4Q3r1d23LFTgaLwm3Cp0iGbrU/MoUI+ZqwCv5XJijCw== -"@esbuild/sunos-x64@0.17.18": - version "0.17.18" - resolved "https://registry.yarnpkg.com/@esbuild/sunos-x64/-/sunos-x64-0.17.18.tgz#ecad0736aa7dae07901ba273db9ef3d3e93df31f" - integrity sha512-Rzf4QfQagnwhQXVBS3BYUlxmEbcV7MY+BH5vfDZekU5eYpcffHSyjU8T0xucKVuOcdCsMo+Ur5wmgQJH2GfNrg== +"@esbuild/sunos-x64@0.17.19": + version "0.17.19" + resolved "https://registry.yarnpkg.com/@esbuild/sunos-x64/-/sunos-x64-0.17.19.tgz#722eaf057b83c2575937d3ffe5aeb16540da7273" + integrity sha512-vCRT7yP3zX+bKWFeP/zdS6SqdWB8OIpaRq/mbXQxTGHnIxspRtigpkUcDMlSCOejlHowLqII7K2JKevwyRP2rg== "@esbuild/sunos-x64@0.17.6": version "0.17.6" @@ -2064,10 +2041,10 @@ resolved "https://registry.yarnpkg.com/@esbuild/win32-arm64/-/win32-arm64-0.16.3.tgz#bedd9bef5fb41f89ce2599f1761973cf6d6a67b6" integrity sha512-u5aBonZIyGopAZyOnoPAA6fGsDeHByZ9CnEzyML9NqntK6D/xl5jteZUKm/p6nD09+v3pTM6TuUIqSPcChk5gg== -"@esbuild/win32-arm64@0.17.18": - version "0.17.18" - resolved "https://registry.yarnpkg.com/@esbuild/win32-arm64/-/win32-arm64-0.17.18.tgz#58dfc177da30acf956252d7c8ae9e54e424887c4" - integrity sha512-Kb3Ko/KKaWhjeAm2YoT/cNZaHaD1Yk/pa3FTsmqo9uFh1D1Rfco7BBLIPdDOozrObj2sahslFuAQGvWbgWldAg== +"@esbuild/win32-arm64@0.17.19": + version "0.17.19" + resolved "https://registry.yarnpkg.com/@esbuild/win32-arm64/-/win32-arm64-0.17.19.tgz#9aa9dc074399288bdcdd283443e9aeb6b9552b6f" + integrity sha512-yYx+8jwowUstVdorcMdNlzklLYhPxjniHWFKgRqH7IFlUEa0Umu3KuYplf1HUZZ422e3NU9F4LGb+4O0Kdcaag== "@esbuild/win32-arm64@0.17.6": version "0.17.6" @@ -2079,10 +2056,10 @@ resolved "https://registry.yarnpkg.com/@esbuild/win32-ia32/-/win32-ia32-0.16.3.tgz#49800aa812d8cc35ceef61e8d3b01224684cc0b1" integrity sha512-GlgVq1WpvOEhNioh74TKelwla9KDuAaLZrdxuuUgsP2vayxeLgVc+rbpIv0IYF4+tlIzq2vRhofV+KGLD+37EQ== -"@esbuild/win32-ia32@0.17.18": - version "0.17.18" - resolved "https://registry.yarnpkg.com/@esbuild/win32-ia32/-/win32-ia32-0.17.18.tgz#340f6163172b5272b5ae60ec12c312485f69232b" - integrity sha512-0/xUMIdkVHwkvxfbd5+lfG7mHOf2FRrxNbPiKWg9C4fFrB8H0guClmaM3BFiRUYrznVoyxTIyC/Ou2B7QQSwmw== +"@esbuild/win32-ia32@0.17.19": + version "0.17.19" + resolved "https://registry.yarnpkg.com/@esbuild/win32-ia32/-/win32-ia32-0.17.19.tgz#95ad43c62ad62485e210f6299c7b2571e48d2b03" + integrity sha512-eggDKanJszUtCdlVs0RB+h35wNlb5v4TWEkq4vZcmVt5u/HiDZrTXe2bWFQUez3RgNHwx/x4sk5++4NSSicKkw== "@esbuild/win32-ia32@0.17.6": version "0.17.6" @@ -2094,10 +2071,10 @@ resolved "https://registry.yarnpkg.com/@esbuild/win32-x64/-/win32-x64-0.16.3.tgz#94047dae921949cfb308117d993c4b941291ae10" integrity sha512-5/JuTd8OWW8UzEtyf19fbrtMJENza+C9JoPIkvItgTBQ1FO2ZLvjbPO6Xs54vk0s5JB5QsfieUEshRQfu7ZHow== -"@esbuild/win32-x64@0.17.18": - version "0.17.18" - resolved "https://registry.yarnpkg.com/@esbuild/win32-x64/-/win32-x64-0.17.18.tgz#3a8e57153905308db357fd02f57c180ee3a0a1fa" - integrity sha512-qU25Ma1I3NqTSHJUOKi9sAH1/Mzuvlke0ioMJRthLXKm7JiSKVwFghlGbDLOO2sARECGhja4xYfRAZNPAkooYg== +"@esbuild/win32-x64@0.17.19": + version "0.17.19" + resolved "https://registry.yarnpkg.com/@esbuild/win32-x64/-/win32-x64-0.17.19.tgz#8cfaf2ff603e9aabb910e9c0558c26cf32744061" + integrity sha512-lAhycmKnVOuRYNtRtatQR1LPQf2oYCkRGkSFnseDAKPl8lu5SOsK/e1sXe5a0Pc5kHIHe6P2I/ilntNv2xf3cA== "@esbuild/win32-x64@0.17.6": version "0.17.6" @@ -3185,6 +3162,13 @@ slash "^3.0.0" strip-ansi "^6.0.0" +"@jest/create-cache-key-function@^27.4.2": + version "27.5.1" + resolved "https://registry.yarnpkg.com/@jest/create-cache-key-function/-/create-cache-key-function-27.5.1.tgz#7448fae15602ea95c828f5eceed35c202a820b31" + integrity sha512-dmH1yW+makpTSURTy8VzdUwFnfQh1G8R+DxO2Ho2FFmBbKFEVm+3jWdvFhE2VqB/LATCTokkP0dotjyQyw5/AQ== + dependencies: + "@jest/types" "^27.5.1" + "@jest/environment@^27.5.1": version "27.5.1" resolved "https://registry.yarnpkg.com/@jest/environment/-/environment-27.5.1.tgz#d7425820511fe7158abbecc010140c3fd3be9c74" @@ -3622,10 +3606,10 @@ resolved "https://registry.yarnpkg.com/@jridgewell/set-array/-/set-array-1.1.2.tgz#7c6cf998d6d20b914c0a55a91ae928ff25965e72" integrity sha512-xnkseuNADM0gt2bs+BvhO0p78Mk762YnZdsuzFV018NoG1Sj1SCQvpSqa7XUaTam5vAGasABV9qXASMKnFMwMw== -"@jridgewell/source-map@^0.3.2": - version "0.3.3" - resolved "https://registry.yarnpkg.com/@jridgewell/source-map/-/source-map-0.3.3.tgz#8108265659d4c33e72ffe14e33d6cc5eb59f2fda" - integrity sha512-b+fsZXeLYi9fEULmfBrhxn4IrPlINf8fiNarzTof004v3lFdntdwa9PF7vFJqm3mg7s+ScJMxXaE3Acp1irZcg== +"@jridgewell/source-map@^0.3.3": + version "0.3.5" + resolved "https://registry.yarnpkg.com/@jridgewell/source-map/-/source-map-0.3.5.tgz#a3bb4d5c6825aab0d281268f47f6ad5853431e91" + integrity sha512-UTYAUj/wviwdsMfzoSJspJxbkH5o1snzwX0//0ENX1u/55kkZZkcTZP6u9bwKGkv+dkk9at4m1Cpt0uY80kcpQ== dependencies: "@jridgewell/gen-mapping" "^0.3.0" "@jridgewell/trace-mapping" "^0.3.9" @@ -3661,90 +3645,107 @@ resolved "https://registry.yarnpkg.com/@leichtgewicht/ip-codec/-/ip-codec-2.0.4.tgz#b2ac626d6cb9c8718ab459166d4bb405b8ffa78b" integrity sha512-Hcv+nVC0kZnQ3tD9GVu5xSMR4VVYOteQIr/hwFPVEvPdlXqgGEuRjiheChHgdM+JyqdgNcmzZOX/tnl0JOiI7A== -"@lingui/babel-plugin-extract-messages@^3.9.0": - version "3.9.0" - resolved "https://registry.npmjs.org/@lingui/babel-plugin-extract-messages/-/babel-plugin-extract-messages-3.9.0.tgz" - integrity sha512-twxAdsIfRihUGQzJ9ZIKZbZAny/Aq3hVpY8Q2rDHEynD2/WhBv0MD/OeqXwfj/C0sGyG1Tgnq17NaCqQu9UX2g== - dependencies: - "@babel/generator" "^7.11.6" - "@babel/runtime" "^7.11.2" - "@lingui/conf" "^3.9.0" - mkdirp "^1.0.4" +"@lingui/babel-plugin-extract-messages@4.3.0": + version "4.3.0" + resolved "https://registry.yarnpkg.com/@lingui/babel-plugin-extract-messages/-/babel-plugin-extract-messages-4.3.0.tgz#2cf9486880318804d846e9ef96cef9841a68c14e" + integrity sha512-X23evX574Pv5wRpg9HytCuE0dsRaFi0kkrj8uQC++Dk1Iti0ptRFeuMU4jxINlfa972Ri3GF6ckGQ+Req3drYg== -"@lingui/cli@^3.9.0": - version "3.9.0" - resolved "https://registry.npmjs.org/@lingui/cli/-/cli-3.9.0.tgz" - integrity sha512-4msr6Nrz/VYd5x5evD6J2rBoQTye2cAFHcObXRzJWmgcE76/lJ9Sn9TTpm6hszMdz+0zojJqaoaVNDuBEO4kNA== +"@lingui/cli@^4.3.0": + version "4.3.0" + resolved "https://registry.yarnpkg.com/@lingui/cli/-/cli-4.3.0.tgz#7c0530ef2caf0902c13fafd4db4b8b552d57446e" + integrity sha512-Z44IxdK7kzmL+5TB2Kuu2xB3O6n1WCsBG0nUXOMtwTWHNxBLdr89hFogO3Orf7QNyxpfw6yZ3Go3xRm3JO3rJg== dependencies: - "@babel/generator" "^7.11.6" - "@babel/parser" "^7.11.5" - "@babel/plugin-syntax-jsx" "^7.10.4" - "@babel/runtime" "^7.11.2" - "@babel/types" "^7.11.5" - "@lingui/babel-plugin-extract-messages" "^3.9.0" - "@lingui/conf" "^3.9.0" + "@babel/core" "^7.21.0" + "@babel/generator" "^7.21.1" + "@babel/parser" "^7.21.2" + "@babel/runtime" "^7.21.0" + "@babel/types" "^7.21.2" + "@lingui/babel-plugin-extract-messages" "4.3.0" + "@lingui/conf" "4.3.0" + "@lingui/core" "4.3.0" + "@lingui/format-po" "4.3.0" + "@lingui/message-utils" "4.3.0" babel-plugin-macros "^3.0.1" - bcp-47 "^1.0.7" chalk "^4.1.0" chokidar "3.5.1" - cli-table "^0.3.1" - commander "^6.1.0" + cli-table "0.3.6" + commander "^10.0.0" + convert-source-map "^2.0.0" date-fns "^2.16.1" - fs-extra "^9.0.1" - fuzzaldrin "^2.1.0" + esbuild "^0.17.10" glob "^7.1.4" inquirer "^7.3.3" - make-plural "^6.2.2" - messageformat-parser "^4.1.3" micromatch "4.0.2" - mkdirp "^1.0.4" - node-gettext "^3.0.0" normalize-path "^3.0.0" ora "^5.1.0" - papaparse "^5.3.0" + pathe "^1.1.0" pkg-up "^3.1.0" - plurals-cldr "^1.0.4" - pofile "^1.1.0" - pseudolocale "^1.1.0" + pofile "^1.1.4" + pseudolocale "^2.0.0" ramda "^0.27.1" + source-map "^0.8.0-beta.0" -"@lingui/conf@^3.14.0", "@lingui/conf@^3.9.0": - version "3.14.0" - resolved "https://registry.yarnpkg.com/@lingui/conf/-/conf-3.14.0.tgz#1b2c20d556b6ea78e530a07a934be219a0d6c662" - integrity sha512-5GMAbIRad9FavqYsfZCRAwjcOLzE7tONDJe9lSYE5SSJbbG01RI5kR5P0B84DUhTI6cGXau+1dAcP9K+JbEx+g== +"@lingui/conf@4.3.0": + version "4.3.0" + resolved "https://registry.yarnpkg.com/@lingui/conf/-/conf-4.3.0.tgz#714c6b1b0415cb8af922daf0bc38c7339b40fada" + integrity sha512-ZflR/igJi3+MUr1VeJDNkYMpnNvinRdw9m17G7mxmemxtnYV+RsIiUB+aR3AcgbQbEEmF95XmZb8jlUFYWlvtw== dependencies: - "@babel/runtime" "^7.11.2" - "@endemolshinegroup/cosmiconfig-typescript-loader" "^3.0.2" + "@babel/runtime" "^7.20.13" chalk "^4.1.0" - cosmiconfig "^7.0.0" - jest-validate "^26.5.2" + cosmiconfig "^8.0.0" + jest-validate "^29.4.3" + jiti "^1.17.1" lodash.get "^4.4.2" -"@lingui/core@^3.14.0": - version "3.14.0" - resolved "https://registry.yarnpkg.com/@lingui/core/-/core-3.14.0.tgz#62e6b5e3d17b3f2ecd84b3f821d591763055aa89" - integrity sha512-ertREq9oi9B/umxpd/pInm9uFO8FLK2/0FXfDmMqvH5ydswWn/c9nY5YO4W1h4/8LWO45mewypOIyjoue4De1w== +"@lingui/core@4.3.0", "@lingui/core@^4.3.0": + version "4.3.0" + resolved "https://registry.yarnpkg.com/@lingui/core/-/core-4.3.0.tgz#239e9fed6e858185ecfd59355b09678df1335393" + integrity sha512-nx9UM3ndYaK9VG6xQpF0OD/n0W35o5EPbiIzxgNvdNzRFtv9l1Z3pBipHXurRuZX0oDepGhVyXFD0ykPDeF7jA== dependencies: - "@babel/runtime" "^7.11.2" - make-plural "^6.2.2" - messageformat-parser "^4.1.3" + "@babel/runtime" "^7.20.13" + "@lingui/message-utils" "4.3.0" + unraw "^2.0.1" -"@lingui/macro@^3.14.0": - version "3.14.0" - resolved "https://registry.yarnpkg.com/@lingui/macro/-/macro-3.14.0.tgz#4d97cd548967c2b4b2b2f92715eec4d69e84545c" - integrity sha512-NxTRrhrZ/cUO9PX/4vWys90Ku58+ExxHuE30IuDnnDldWhWlOdycmjDt9tB+yIiUdFym/veSxBs+h114FzG5mA== +"@lingui/format-po@4.3.0": + version "4.3.0" + resolved "https://registry.yarnpkg.com/@lingui/format-po/-/format-po-4.3.0.tgz#ce4281ea047749842c1ebcbe4cb01fefd102571a" + integrity sha512-iwqMve+VMxfRisTCk2evcnhAfn54v5qXTXZUDGZQrSQ60r2A4VGtS8VdCzqHwKxvbIatjq4NfWGa0v0zb092jg== dependencies: - "@babel/runtime" "^7.11.2" - "@lingui/conf" "^3.14.0" - ramda "^0.27.1" + "@lingui/conf" "4.3.0" + "@lingui/message-utils" "4.3.0" + date-fns "^2.29.3" + pofile "^1.1.4" -"@lingui/react@^3.14.0": - version "3.14.0" - resolved "https://registry.yarnpkg.com/@lingui/react/-/react-3.14.0.tgz#e3e6732a9d172c8ecb4f82fb8558b1766f5cee31" - integrity sha512-ow9Mtru7f0T2S9AwnPWRejppcucCW0LmoDR3P4wqHjL+eH5f8a6nxd2doxGieC91/2i4qqW88y4K/zXJxwRSQw== +"@lingui/macro@^4.3.0": + version "4.3.0" + resolved "https://registry.yarnpkg.com/@lingui/macro/-/macro-4.3.0.tgz#e2209bdd73a932647ed2402143f4cb55d99fc3b5" + integrity sha512-MkeYKshuEp2j8Nx0IOhppcSiN3wEw3UxMPXsHzMe34U/MPrrriYaxMRY7CSsQrXqftcacQTm9IiDWvJAj4/V9w== dependencies: - "@babel/runtime" "^7.11.2" - "@lingui/core" "^3.14.0" + "@babel/runtime" "^7.20.13" + "@babel/types" "^7.20.7" + "@lingui/conf" "4.3.0" + "@lingui/core" "4.3.0" + "@lingui/message-utils" "4.3.0" + +"@lingui/message-utils@4.3.0": + version "4.3.0" + resolved "https://registry.yarnpkg.com/@lingui/message-utils/-/message-utils-4.3.0.tgz#e5ace0103261e2611c8a86748f7c9711e47e3db7" + integrity sha512-UtgO5pm6LpJKqmZctr2R2hT+qicb8UijFDG3dctKGBuwkkwunFZUswOLJ+AxfhaO652Vov/yf5qsymJ6UFXPBA== + dependencies: + "@messageformat/parser" "^5.0.0" + +"@lingui/react@^4.3.0": + version "4.3.0" + resolved "https://registry.yarnpkg.com/@lingui/react/-/react-4.3.0.tgz#d08fe2b3a6b97c891adc26bee68c83451ba24198" + integrity sha512-EbkS5J2i26ENuAie70Fb+urOlajOTpa0xF3wZ78Zt4XKJSruZQ1Vg0U7vndpD5QeLsIpjGmJONkLjg8KzyVmBA== + dependencies: + "@babel/runtime" "^7.20.13" + "@lingui/core" "4.3.0" + +"@lingui/swc-plugin@^4.0.4": + version "4.0.4" + resolved "https://registry.yarnpkg.com/@lingui/swc-plugin/-/swc-plugin-4.0.4.tgz#1e6e753b8aae50edd929eb4905db24a186513dca" + integrity sha512-xRnR96Mqi6zwGlVfGJMfoM8QykBbUz/sSnwmcFL9BZ8Y9YBZxzLAVf4t1BbiIQsAs+pMYu/HfujTBD4y/r1ucA== "@lit-labs/ssr-dom-shim@^1.0.0", "@lit-labs/ssr-dom-shim@^1.1.0": version "1.1.1" @@ -3763,6 +3764,13 @@ resolved "https://registry.yarnpkg.com/@looksrare/sdk/-/sdk-0.10.2.tgz#08b14cb6d3a5499ad0417c817dbb2da924477f4f" integrity sha512-K3VVq7rpS0hD5IwfhAcAPJZO5IjL0VbL89Zl04x8WnLsFOwXHzsUkxUpRrL8ko2/bgZdgTqWgUWCvbSoVr8hzw== +"@messageformat/parser@^5.0.0": + version "5.1.0" + resolved "https://registry.yarnpkg.com/@messageformat/parser/-/parser-5.1.0.tgz#05e4851c782d633ad735791dd0a68ee65d2a7201" + integrity sha512-jKlkls3Gewgw6qMjKZ9SFfHUpdzEVdovKFtW1qRhJ3WI4FW5R/NnGDqr8SDGz+krWDO3ki94boMmQvGke1HwUQ== + dependencies: + moo "^0.5.1" + "@metamask/detect-provider@^1.2.0": version "1.2.0" resolved "https://registry.yarnpkg.com/@metamask/detect-provider/-/detect-provider-1.2.0.tgz#3667a7531f2a682e3c3a43eaf3a1958bdb42a696" @@ -5083,6 +5091,85 @@ "@svgr/plugin-svgo" "^5.5.0" loader-utils "^2.0.0" +"@swc/core-darwin-arm64@1.3.72": + version "1.3.72" + resolved "https://registry.yarnpkg.com/@swc/core-darwin-arm64/-/core-darwin-arm64-1.3.72.tgz#73ab213a2a07bfbf6ff71ce5f5bef7fb6857a032" + integrity sha512-oNSI5hVfZ+1xpj+dH1g4kQqA0VsGtqd8S9S+cDqkHZiOOVOevw9KN6dzVtmLOcPtlULVypVc0TVvsB55KdVZhQ== + +"@swc/core-darwin-x64@1.3.72": + version "1.3.72" + resolved "https://registry.yarnpkg.com/@swc/core-darwin-x64/-/core-darwin-x64-1.3.72.tgz#b9d7d5ba3b68ae507e48e038f91d97aafd6bd907" + integrity sha512-y5O/WQ1g0/VfTgeNahWIOutbdD5U2Gi703jaefdcoJo3FUx8WU108QQdbVGwGMgaqapo3iQB6Qs9paixYQAYsA== + +"@swc/core-linux-arm-gnueabihf@1.3.72": + version "1.3.72" + resolved "https://registry.yarnpkg.com/@swc/core-linux-arm-gnueabihf/-/core-linux-arm-gnueabihf-1.3.72.tgz#af8fd09684d5a1327949cf64cad3a1e45b082c4f" + integrity sha512-05JdWcso0OomHF+7bk5MBDgI8MZ9skcQ/4nhSv5gboSgSiuBmKM15Bg3lZ5iAUwGByNj7pGkSmmd3YwTrXEB+g== + +"@swc/core-linux-arm64-gnu@1.3.72": + version "1.3.72" + resolved "https://registry.yarnpkg.com/@swc/core-linux-arm64-gnu/-/core-linux-arm64-gnu-1.3.72.tgz#2c0e365431e25d0fb0d1be3f6cb71ff6b315287e" + integrity sha512-8qRELJaeYshhJgqvyOeXCKqBOpai+JYdWuouMbvvDUL85j3OcZhzR+bipexEbbJKcOCdRnoYB7Qg6mjqZ0t7VA== + +"@swc/core-linux-arm64-musl@1.3.72": + version "1.3.72" + resolved "https://registry.yarnpkg.com/@swc/core-linux-arm64-musl/-/core-linux-arm64-musl-1.3.72.tgz#dbb6579daed116657d7ee6994bea75abb385ba6f" + integrity sha512-tOqAGZw+Pe7YrBHFrwFVyRiKqjgjzwYbJmY+UDxLrzWrZSVtC3eO2TPrp7kWmhirg40Og81BbdfRAl8ds48w0Q== + +"@swc/core-linux-x64-gnu@1.3.72": + version "1.3.72" + resolved "https://registry.yarnpkg.com/@swc/core-linux-x64-gnu/-/core-linux-x64-gnu-1.3.72.tgz#80dcbf6d71cb7ef0b92aa868ef605427305e83a8" + integrity sha512-U2W2xWR3s9nplGVWz376GiBlcLTgxyYKlpZPBNZk0w3OvTcjKC62gW1Pe7PUkk4NgJUnaQDBa/mb4V4Zl+GZPA== + +"@swc/core-linux-x64-musl@1.3.72": + version "1.3.72" + resolved "https://registry.yarnpkg.com/@swc/core-linux-x64-musl/-/core-linux-x64-musl-1.3.72.tgz#0a8ef179f89cc1f62dae8061e759d987c596ccb3" + integrity sha512-3+2dUiZBsifKgvnFEHWdysXjInK8K+BfPBw2tTZJmq1+fZLt0rvuErYDVMLfIJnVWLCcJMnDtTXrvkFV1y/6iA== + +"@swc/core-win32-arm64-msvc@1.3.72": + version "1.3.72" + resolved "https://registry.yarnpkg.com/@swc/core-win32-arm64-msvc/-/core-win32-arm64-msvc-1.3.72.tgz#ac1a858b3777ba5dba2d55db7648f5a1ad7b840e" + integrity sha512-ndI8xZ2AId806D25xgqw2SFJ9gc/jhg21+5hA8XPq9ZL+oDiaYDztaP3ijVmZ1G5xXKD9DpgB7xmylv/f6o6GA== + +"@swc/core-win32-ia32-msvc@1.3.72": + version "1.3.72" + resolved "https://registry.yarnpkg.com/@swc/core-win32-ia32-msvc/-/core-win32-ia32-msvc-1.3.72.tgz#3b7764bee0e276b2545e21a85a54381bdc34c3b8" + integrity sha512-F3TK8JHP3SRFjLRlzcRVZPnvvGm2CQ5/cwbIkaEq0Dla3kyctU8SiRqvtYwWCW4JuY10cUygIg93Ec/C9Lkk4g== + +"@swc/core-win32-x64-msvc@1.3.72": + version "1.3.72" + resolved "https://registry.yarnpkg.com/@swc/core-win32-x64-msvc/-/core-win32-x64-msvc-1.3.72.tgz#d3fba8398bb7844353eacb859d61cc1e70c39470" + integrity sha512-FXMnIUtLl0yEmGkw+xbUg/uUPExvUxUlLSHbX7CnbSuOIHqMHzvEd9skIueLAst4bvmJ8kT1hDyAIWQcTIAJYQ== + +"@swc/core@^1.3.72": + version "1.3.72" + resolved "https://registry.yarnpkg.com/@swc/core/-/core-1.3.72.tgz#6eb7eb0388f98c5934343b2db1cbc616831afe03" + integrity sha512-+AKjwLH3/STfPrd7CHzB9+NG1FVT0UKJMUChuWq9sQ8b9xlV8vUeRgZXgh/EHYvNQgl/OUTQKtL6xU2yOLuEuA== + optionalDependencies: + "@swc/core-darwin-arm64" "1.3.72" + "@swc/core-darwin-x64" "1.3.72" + "@swc/core-linux-arm-gnueabihf" "1.3.72" + "@swc/core-linux-arm64-gnu" "1.3.72" + "@swc/core-linux-arm64-musl" "1.3.72" + "@swc/core-linux-x64-gnu" "1.3.72" + "@swc/core-linux-x64-musl" "1.3.72" + "@swc/core-win32-arm64-msvc" "1.3.72" + "@swc/core-win32-ia32-msvc" "1.3.72" + "@swc/core-win32-x64-msvc" "1.3.72" + +"@swc/jest@^0.2.27": + version "0.2.27" + resolved "https://registry.yarnpkg.com/@swc/jest/-/jest-0.2.27.tgz#f6cbd0b6f95cf689c3344c63fc379fa680cdbf52" + integrity sha512-Xt8EJ6Wy0NYVL8KDPcDMsuUSzyV2UAByamyy28x2iDZCJw2eVz3acedCGBYxxlPR/DNr6QbA35OSymuXhC9QVA== + dependencies: + "@jest/create-cache-key-function" "^27.4.2" + jsonc-parser "^3.2.0" + +"@swc/plugin-styled-components@^1.5.70": + version "1.5.70" + resolved "https://registry.yarnpkg.com/@swc/plugin-styled-components/-/plugin-styled-components-1.5.70.tgz#90a569515fde5a8c0baab93149222191ebff7801" + integrity sha512-/SqUvdxl9yxDKlpBxl2cymmZlj5EgIzMVTLSPr0eXKU0+hAA8RiEHp9LZqcTMK9a7wzo3j25f5dreTu9I0NYUg== + "@testing-library/dom@^7.11.0": version "7.31.2" resolved "https://registry.yarnpkg.com/@testing-library/dom/-/dom-7.31.2.tgz#df361db38f5212b88555068ab8119f5d841a8c4a" @@ -5675,10 +5762,10 @@ resolved "https://registry.yarnpkg.com/@types/mime/-/mime-1.3.2.tgz#93e25bf9ee75fe0fd80b594bc4feb0e862111b5a" integrity sha512-YATxVxgRqNH6nHEIsvg6k2Boc1JHI9ZbH5iWFFv/MTkchz3b1ieGDa5T0a9RznNdI0KhVbdbWSN+KWWrQZRxTw== -"@types/ms.macro@^2.0.0": - version "2.0.0" - resolved "https://registry.yarnpkg.com/@types/ms.macro/-/ms.macro-2.0.0.tgz#a27e14d8e409fc973715701465e18be5edcfd4c0" - integrity sha512-xT4rTPFfZv2KZa0PLgB6e4RC5SuIr+8NDq2iZ4YxNtbByZRR98qbnS4WyNCQZIC5Jwn55AFok2CEqEb95w/CQQ== +"@types/ms@^0.7.31": + version "0.7.31" + resolved "https://registry.yarnpkg.com/@types/ms/-/ms-0.7.31.tgz#31b7ca6407128a3d2bbc27fe2d21b345397f6197" + integrity sha512-iiUgKzV9AuaEkZqkOLDIvlQiL6ltuZd9tGcW3gwpnX8JbuiuhFlEGmmFXEXkN50Cvq7Os88IY2v0dkDqXYWVgA== "@types/multicodec@^1.0.0": version "1.0.0" @@ -6387,30 +6474,21 @@ dependencies: "@babel/core" "^7.20.7" -"@vanilla-extract/babel-plugin@^1.1.7": - version "1.1.7" - resolved "https://registry.yarnpkg.com/@vanilla-extract/babel-plugin/-/babel-plugin-1.1.7.tgz#b086875db3f66963223b7eb9e6a961796c041ef9" - integrity sha512-nTCOb1N/u1FUxACxV/jvpLm4xchiCdEHTUZrxCWjYOrIxqkfgpJXE4T7q/1VyEje/M929DFBUaD+YkPzaqGMzA== - dependencies: - "@babel/core" "^7.13.10" - "@babel/template" "^7.12.13" - "@vanilla-extract/integration" "^5.0.0" +"@vanilla-extract/css-utils@^0.1.3": + version "0.1.3" + resolved "https://registry.yarnpkg.com/@vanilla-extract/css-utils/-/css-utils-0.1.3.tgz#cadeb6bc563547b20e9b903647d8b334d3a79ef8" + integrity sha512-PZAcHROlgtCUGI2y0JntdNwvPwCNyeVnkQu6KTYKdmxBbK3w72XJUmLFYapfaFfgami4I9CTLnrJTPdtmS3gpw== -"@vanilla-extract/css-utils@^0.1.2": - version "0.1.2" - resolved "https://registry.yarnpkg.com/@vanilla-extract/css-utils/-/css-utils-0.1.2.tgz#6bcd3e45f187d56c319ce9bc36ae1814b373c581" - integrity sha512-qoxIu5E/UhJtoKsPL1JaU9nhTN0Xl5zYV0pScOgsvc3JN46TvTTt0L3GV8x3PQpZP7x3elw8BsC9czYbhJy9Gg== - -"@vanilla-extract/css@^1.10.0", "@vanilla-extract/css@^1.7.2": - version "1.11.0" - resolved "https://registry.yarnpkg.com/@vanilla-extract/css/-/css-1.11.0.tgz#ad285f31e0b0dff0d7a02cab6a2e5c39e5f2ddf3" - integrity sha512-uohj+8cGWbnrVzTfrjlJeXqdGjH3d3TcscdQxKe3h5bb5QQXTpPSq+c+SeWADIGiZybzcW0CBvZV8jsy1ywY9w== +"@vanilla-extract/css@^1.10.0", "@vanilla-extract/css@^1.12.0": + version "1.12.0" + resolved "https://registry.yarnpkg.com/@vanilla-extract/css/-/css-1.12.0.tgz#aa7af9a5afac97d0cbabbc2387ab1a7adc6c8cb2" + integrity sha512-TEttZfnqTRtwgVYiBWQSGGUiVaYWReHp59DsavITEvh4TpJNifZFGhBznHx4wQFEsyio6xA513jps4tmqR6zmw== dependencies: "@emotion/hash" "^0.9.0" "@vanilla-extract/private" "^1.0.3" ahocorasick "1.0.2" chalk "^4.1.1" - css-what "^5.0.1" + css-what "^6.1.0" cssesc "^3.0.0" csstype "^3.0.7" deep-object-diff "^1.1.9" @@ -6418,27 +6496,14 @@ media-query-parser "^2.0.2" outdent "^0.8.0" -"@vanilla-extract/dynamic@^2.0.2": - version "2.0.2" - resolved "https://registry.yarnpkg.com/@vanilla-extract/dynamic/-/dynamic-2.0.2.tgz#13a3e461964c8029a52e6b6b631009ca6a8b27f5" - integrity sha512-U4nKaEQ8Kuz+exXEr51DUpyaOuzo24/S/k1YbDPQR06cYcNjQqvwFRnwWtZ+9ImocqM1wTKtzrdUgSTtLGIwAg== +"@vanilla-extract/dynamic@^2.0.3": + version "2.0.3" + resolved "https://registry.yarnpkg.com/@vanilla-extract/dynamic/-/dynamic-2.0.3.tgz#44b4e018cbdfb6af3d27e73c78b38617dfe419ad" + integrity sha512-Rglfw2gXAYiBzAQ4jgUG7rBgE2c88e/zcG27ZVoIqMHVq56wf2C1katGMm1yFMNBgzqM7oBNYzz4YOMzznydkg== dependencies: "@vanilla-extract/private" "^1.0.3" -"@vanilla-extract/integration@^5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@vanilla-extract/integration/-/integration-5.0.0.tgz#6652f5bf8effb8f29719f6df8cd754c2d16d5b04" - integrity sha512-HwglsIxGYtV4IXFfyQ6GzZLFoaWaW+QkNx8UhXbgsCWUoPqpSbioukCOA+SuSuzsIcEZ3hkD0Y5ixITQNtnzjQ== - dependencies: - "@vanilla-extract/css" "^1.7.2" - esbuild "^0.11.16" - eval "0.1.6" - find-up "^5.0.0" - javascript-stringify "^2.0.1" - lodash "^4.17.21" - outdent "^0.8.0" - -"@vanilla-extract/integration@^6.2.0": +"@vanilla-extract/integration@^6.0.0", "@vanilla-extract/integration@^6.2.0": version "6.2.1" resolved "https://registry.yarnpkg.com/@vanilla-extract/integration/-/integration-6.2.1.tgz#e87849ed3d8e9ddd2703b8b8597fdbff08cf62ad" integrity sha512-+xYJz07G7TFAMZGrOqArOsURG+xcYvqctujEkANjw2McCBvGEK505RxQqOuNiA9Mi9hgGdNp2JedSa94f3eoLg== @@ -6470,17 +6535,17 @@ resolved "https://registry.yarnpkg.com/@vanilla-extract/private/-/private-1.0.3.tgz#7ec72bc2ff6fe51f9d650f962e8d1989b073690f" integrity sha512-17kVyLq3ePTKOkveHxXuIJZtGYs+cSoev7BlP+Lf4916qfDhk/HBjvlYDe8egrea7LNPHKwSZJK/bzZC+Q6AwQ== -"@vanilla-extract/sprinkles@^1.4.1": - version "1.4.1" - resolved "https://registry.yarnpkg.com/@vanilla-extract/sprinkles/-/sprinkles-1.4.1.tgz#8c8703ddedaac355c1187db909119816c0fc771c" - integrity sha512-aW6CfMMToX4a+baLuVxwcT0FSACjX3xrNt8wdi/3LLRlLAfhyue8OK7kJxhcYNZfydBeWTP59aRy8p5FUTIeew== +"@vanilla-extract/sprinkles@^1.6.1": + version "1.6.1" + resolved "https://registry.yarnpkg.com/@vanilla-extract/sprinkles/-/sprinkles-1.6.1.tgz#2c8a832757a0d8104dc6bd5d961db2c70d1dbdcb" + integrity sha512-N/RGKwGAAidBupZ436RpuweRQHEFGU+mvAqBo8PRMAjJEmHoPDttV8RObaMLrJHWLqvX+XUMinHUnD0hFRQISw== -"@vanilla-extract/webpack-plugin@^2.1.11": - version "2.1.11" - resolved "https://registry.yarnpkg.com/@vanilla-extract/webpack-plugin/-/webpack-plugin-2.1.11.tgz#ca67aa95c0b1e3511e787dd715c0158dd4a6d1d3" - integrity sha512-jCm2TT1jSN/m0TZXYtByuHOsX+ZDimku1SJzvDWF1Eqs3f0If2W1zcd+gaXR6lSaVJ/1MSB/evmeutsT/D3MoA== +"@vanilla-extract/webpack-plugin@^2.2.0": + version "2.2.0" + resolved "https://registry.yarnpkg.com/@vanilla-extract/webpack-plugin/-/webpack-plugin-2.2.0.tgz#e7d07543d531a9fe283c37eebaabe746a44fbe30" + integrity sha512-EQrnT7gIki+Wm57eIRZRw6pi4M4VVnwiSp5OOcQF81XdZvoYXo51Ern7+dHKS+Xxli151BWTUsg/UZSpaAz29Q== dependencies: - "@vanilla-extract/integration" "^5.0.0" + "@vanilla-extract/integration" "^6.0.0" chalk "^4.1.1" debug "^4.3.1" loader-utils "^2.0.0" @@ -7324,10 +7389,10 @@ acorn-globals@^6.0.0: acorn "^7.1.1" acorn-walk "^7.1.1" -acorn-import-assertions@^1.7.6: - version "1.8.0" - resolved "https://registry.yarnpkg.com/acorn-import-assertions/-/acorn-import-assertions-1.8.0.tgz#ba2b5939ce62c238db6d93d81c9b111b29b855e9" - integrity sha512-m7VZ3jwz4eK6A4Vtt8Ew1/mNbP24u0FhdyfA7fSvnJR6LMdfOYnmuIrrJAgrYfYJ10F/otaHTtrtrtmHdMNzEw== +acorn-import-assertions@^1.9.0: + version "1.9.0" + resolved "https://registry.yarnpkg.com/acorn-import-assertions/-/acorn-import-assertions-1.9.0.tgz#507276249d684797c84e0734ef84860334cfb1ac" + integrity sha512-cmMwop9x+8KFhxvKrKfPYmN6/pKTYYHBqLa0DfvVZcKMJWNyWLnaqND7dx/qn66R7ewM1UX5XMaDVP5wlVTaVA== acorn-jsx@^5.3.1, acorn-jsx@^5.3.2: version "5.3.2" @@ -7349,7 +7414,7 @@ acorn@^7.1.1, acorn@^7.4.0: resolved "https://registry.npmjs.org/acorn/-/acorn-7.4.1.tgz" integrity sha512-nQyp0o1/mNdbTO1PO6kHkwSrmgZ0MT/jCCpNiwbUjGoRN4dlBhqJtoQuCnEOKzgTVwg0ZWiCoQy6SxMebQVh8A== -acorn@^8.2.4, acorn@^8.4.1, acorn@^8.5.0, acorn@^8.7.1, acorn@^8.8.0, acorn@^8.8.2: +acorn@^8.2.4, acorn@^8.4.1, acorn@^8.7.1, acorn@^8.8.0, acorn@^8.8.2: version "8.8.2" resolved "https://registry.yarnpkg.com/acorn/-/acorn-8.8.2.tgz#1b2f25db02af965399b9776b0c2c391276d37c4a" integrity sha512-xjIYgE8HBrkpd/sJqOGNspf8uHG+NOHGOw6a/Urj8taM2EXfdNAH2oFcPeIFfsv3+kz/mJrS5VuMqbNLjCa2vw== @@ -8128,15 +8193,6 @@ batch@0.6.1: resolved "https://registry.yarnpkg.com/batch/-/batch-0.6.1.tgz#dc34314f4e679318093fc760272525f94bf25c16" integrity sha1-3DQxT05nkxgJP8dgJyUl+UvyXBY= -bcp-47@^1.0.7: - version "1.0.8" - resolved "https://registry.npmjs.org/bcp-47/-/bcp-47-1.0.8.tgz" - integrity sha512-Y9y1QNBBtYtv7hcmoX0tR+tUNSFZGZ6OL6vKPObq8BbOhkCoyayF6ogfLTgAli/KuAEbsYHYUNq2AQuY6IuLag== - dependencies: - is-alphabetical "^1.0.0" - is-alphanumerical "^1.0.0" - is-decimal "^1.0.0" - bcrypt-pbkdf@^1.0.0: version "1.0.2" resolved "https://registry.yarnpkg.com/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.2.tgz#a4301d389b6a43f9b67ff3ca11a3f6637e360e9e" @@ -8912,9 +8968,9 @@ cli-table3@~0.6.1: optionalDependencies: "@colors/colors" "1.5.0" -cli-table@^0.3.1: +cli-table@0.3.6: version "0.3.6" - resolved "https://registry.npmjs.org/cli-table/-/cli-table-0.3.6.tgz" + resolved "https://registry.yarnpkg.com/cli-table/-/cli-table-0.3.6.tgz#e9d6aa859c7fe636981fd3787378c2a20bce92fc" integrity sha512-ZkNZbnZjKERTY5NwC2SeMeLeifSPq/pubeRoTpdr3WchLlnZg6hEgvHkK5zL7KNFdd9PmHN8lxrENUwI3cE8vQ== dependencies: colors "1.0.3" @@ -9096,11 +9152,6 @@ command-line-args@^4.0.7: find-replace "^1.0.3" typical "^2.6.1" -commander@*, commander@^9.4.0: - version "9.5.0" - resolved "https://registry.yarnpkg.com/commander/-/commander-9.5.0.tgz#bc08d1eb5cedf7ccb797a96199d41c7bc3e60d30" - integrity sha512-KRs7WVDKg86PWiuAqhDrAQnTXZKraVcCc6vFdL14qrZ/DcWwuRo7VoiYXalXO7S5GKpqYiVEwCbgFDfxNHKJBQ== - commander@3.0.2: version "3.0.2" resolved "https://registry.yarnpkg.com/commander/-/commander-3.0.2.tgz#6837c3fb677ad9933d1cfba42dd14d5117d6b39e" @@ -9111,6 +9162,11 @@ commander@7, commander@^7.2.0: resolved "https://registry.npmjs.org/commander/-/commander-7.2.0.tgz" integrity sha512-QrWXB+ZQSVPmIWIhtEO9H+gwHaMGYiF5ChvoJ+K9ZGHG/sVsa6yiesAD1GC/x46sET00Xlwo1u49RVVVzvcSkw== +commander@^10.0.0: + version "10.0.1" + resolved "https://registry.yarnpkg.com/commander/-/commander-10.0.1.tgz#881ee46b4f77d1c1dccc5823433aa39b022cbe06" + integrity sha512-y4Mg2tXshplEbSGzx7amzPwKKOCGuoSRP/CjEdwwk0FOGlUbq6lKuoyDZTNZkmxHdJtp54hdfY/JUrdL7Xfdug== + commander@^2.20.0, commander@^2.20.3: version "2.20.3" resolved "https://registry.yarnpkg.com/commander/-/commander-2.20.3.tgz#fd485e84c03eb4881c20722ba48035e8531aeb33" @@ -9126,7 +9182,7 @@ commander@^5.1.0: resolved "https://registry.yarnpkg.com/commander/-/commander-5.1.0.tgz#46abbd1652f8e059bddaef99bbdcb2ad9cf179ae" integrity sha512-P0CysNDQ7rtVw4QIQtm+MRxV66vKFSvlsQvGYXZWR3qFU0jlMKHZZZgw8e+8DSah4UDKMqnknRDQz+xuQXQ/Zg== -commander@^6.1.0, commander@^6.2.1: +commander@^6.2.1: version "6.2.1" resolved "https://registry.npmjs.org/commander/-/commander-6.2.1.tgz" integrity sha512-U7VdrJFnJgo4xjrHpTzu0yrHPGImdsmD95ZlgYSEajAn2JKzDhDTPG9kBTefmObL2w/ngeZnilk+OV9CG3d7UA== @@ -9136,6 +9192,11 @@ commander@^8.3.0: resolved "https://registry.yarnpkg.com/commander/-/commander-8.3.0.tgz#4837ea1b2da67b9c616a67afbb0fafee567bca66" integrity sha512-OkTL9umf+He2DZkUq8f8J9of7yL6RJKI24dVITBmNfZBmri9zYZQrKkuXiKhyfPSu8tUhnVBB1iKXevvnlR4Ww== +commander@^9.4.0: + version "9.5.0" + resolved "https://registry.yarnpkg.com/commander/-/commander-9.5.0.tgz#bc08d1eb5cedf7ccb797a96199d41c7bc3e60d30" + integrity sha512-KRs7WVDKg86PWiuAqhDrAQnTXZKraVcCc6vFdL14qrZ/DcWwuRo7VoiYXalXO7S5GKpqYiVEwCbgFDfxNHKJBQ== + common-path-prefix@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/common-path-prefix/-/common-path-prefix-3.0.0.tgz#7d007a7e07c58c4b4d5f433131a19141b29f11e0" @@ -9336,6 +9397,16 @@ cosmiconfig@^7, cosmiconfig@^7.0.0, cosmiconfig@^7.0.1: path-type "^4.0.0" yaml "^1.10.0" +cosmiconfig@^8.0.0: + version "8.2.0" + resolved "https://registry.yarnpkg.com/cosmiconfig/-/cosmiconfig-8.2.0.tgz#f7d17c56a590856cd1e7cee98734dca272b0d8fd" + integrity sha512-3rTMnFJA1tCOPwRxtgF4wd7Ab2qvDbL8jX+3smjIbS4HlZBagTlpERbdN7iAbWlrfxE3M8c27kTwTawQ7st+OQ== + dependencies: + import-fresh "^3.2.1" + js-yaml "^4.1.0" + parse-json "^5.0.0" + path-type "^4.0.0" + crc-32@^1.2.0: version "1.2.2" resolved "https://registry.yarnpkg.com/crc-32/-/crc-32-1.2.2.tgz#3cad35a934b8bf71f25ca524b6da51fb7eace2ff" @@ -9515,11 +9586,16 @@ css-what@^3.2.1: resolved "https://registry.yarnpkg.com/css-what/-/css-what-3.4.2.tgz#ea7026fcb01777edbde52124e21f327e7ae950e4" integrity sha512-ACUm3L0/jiZTqfzRM3Hi9Q8eZqd6IK37mMWPLz9PJxkLWllYeRf+EHUSHYEtFop2Eqytaq1FizFVh7XfBnXCDQ== -css-what@^5.0.0, css-what@^5.0.1: +css-what@^5.0.0: version "5.1.0" resolved "https://registry.yarnpkg.com/css-what/-/css-what-5.1.0.tgz#3f7b707aadf633baf62c2ceb8579b545bb40f7fe" integrity sha512-arSMRWIIFY0hV8pIxZMEfmMI47Wj3R/aWpZDDxWYCPEiOMv6tfOrnpDtgxBYPEQD4V0Y/958+1TdC3iWTFcUPw== +css-what@^6.1.0: + version "6.1.0" + resolved "https://registry.yarnpkg.com/css-what/-/css-what-6.1.0.tgz#fb5effcf76f1ddea2c81bdfaa4de44e79bac70f4" + integrity sha512-HTUrgRJ7r4dsZKU6GjmpfRK1O76h97Z8MfS1G0FozR+oF2kG6Vfe8JE6zwrkbxigziPHinCJ+gCPjA9EaBDtRw== + css.escape@^1.5.1: version "1.5.1" resolved "https://registry.yarnpkg.com/css.escape/-/css.escape-1.5.1.tgz#42e27d4fa04ae32f931a4b4d4191fa9cddee97cb" @@ -10568,10 +10644,10 @@ end-of-stream@^1.1.0, end-of-stream@^1.4.1: dependencies: once "^1.4.0" -enhanced-resolve@^5.10.0, enhanced-resolve@^5.13.0: - version "5.13.0" - resolved "https://registry.yarnpkg.com/enhanced-resolve/-/enhanced-resolve-5.13.0.tgz#26d1ecc448c02de997133217b5c1053f34a0a275" - integrity sha512-eyV8f0y1+bzyfh8xAwW/WTSZpLbjhqc4ne9eGSH4Zo2ejdyiNG9pU6mf9DG8a7+Auk6MFTlNOT4Y2y/9k8GKVg== +enhanced-resolve@^5.10.0, enhanced-resolve@^5.15.0: + version "5.15.0" + resolved "https://registry.yarnpkg.com/enhanced-resolve/-/enhanced-resolve-5.15.0.tgz#1af946c7d93603eb88e9896cee4904dc012e9c35" + integrity sha512-LXYT42KJ7lpIKECr2mAXIaMldcNCh/7E0KBKOu4KSfkHmP+mZmSs+8V5gBAqisWBy0OO4W5Oyys0GO1Y8KtdKg== dependencies: graceful-fs "^4.2.4" tapable "^2.2.0" @@ -10754,38 +10830,33 @@ esbuild@0.17.6: "@esbuild/win32-ia32" "0.17.6" "@esbuild/win32-x64" "0.17.6" -esbuild@^0.11.16: - version "0.11.23" - resolved "https://registry.yarnpkg.com/esbuild/-/esbuild-0.11.23.tgz#c42534f632e165120671d64db67883634333b4b8" - integrity sha512-iaiZZ9vUF5wJV8ob1tl+5aJTrwDczlvGP0JoMmnpC2B0ppiMCu8n8gmy5ZTGl5bcG081XBVn+U+jP+mPFm5T5Q== - -esbuild@^0.17.5: - version "0.17.18" - resolved "https://registry.yarnpkg.com/esbuild/-/esbuild-0.17.18.tgz#f4f8eb6d77384d68cd71c53eb6601c7efe05e746" - integrity sha512-z1lix43jBs6UKjcZVKOw2xx69ffE2aG0PygLL5qJ9OS/gy0Ewd1gW/PUQIOIQGXBHWNywSc0floSKoMFF8aK2w== +esbuild@^0.17.10, esbuild@^0.17.5: + version "0.17.19" + resolved "https://registry.yarnpkg.com/esbuild/-/esbuild-0.17.19.tgz#087a727e98299f0462a3d0bcdd9cd7ff100bd955" + integrity sha512-XQ0jAPFkK/u3LcVRcvVHQcTIqD6E2H1fvZMA5dQPSOWb3suUbWbfbRf94pjc0bNzRYLfIrDRQXr7X+LHIm5oHw== optionalDependencies: - "@esbuild/android-arm" "0.17.18" - "@esbuild/android-arm64" "0.17.18" - "@esbuild/android-x64" "0.17.18" - "@esbuild/darwin-arm64" "0.17.18" - "@esbuild/darwin-x64" "0.17.18" - "@esbuild/freebsd-arm64" "0.17.18" - "@esbuild/freebsd-x64" "0.17.18" - "@esbuild/linux-arm" "0.17.18" - "@esbuild/linux-arm64" "0.17.18" - "@esbuild/linux-ia32" "0.17.18" - "@esbuild/linux-loong64" "0.17.18" - "@esbuild/linux-mips64el" "0.17.18" - "@esbuild/linux-ppc64" "0.17.18" - "@esbuild/linux-riscv64" "0.17.18" - "@esbuild/linux-s390x" "0.17.18" - "@esbuild/linux-x64" "0.17.18" - "@esbuild/netbsd-x64" "0.17.18" - "@esbuild/openbsd-x64" "0.17.18" - "@esbuild/sunos-x64" "0.17.18" - "@esbuild/win32-arm64" "0.17.18" - "@esbuild/win32-ia32" "0.17.18" - "@esbuild/win32-x64" "0.17.18" + "@esbuild/android-arm" "0.17.19" + "@esbuild/android-arm64" "0.17.19" + "@esbuild/android-x64" "0.17.19" + "@esbuild/darwin-arm64" "0.17.19" + "@esbuild/darwin-x64" "0.17.19" + "@esbuild/freebsd-arm64" "0.17.19" + "@esbuild/freebsd-x64" "0.17.19" + "@esbuild/linux-arm" "0.17.19" + "@esbuild/linux-arm64" "0.17.19" + "@esbuild/linux-ia32" "0.17.19" + "@esbuild/linux-loong64" "0.17.19" + "@esbuild/linux-mips64el" "0.17.19" + "@esbuild/linux-ppc64" "0.17.19" + "@esbuild/linux-riscv64" "0.17.19" + "@esbuild/linux-s390x" "0.17.19" + "@esbuild/linux-x64" "0.17.19" + "@esbuild/netbsd-x64" "0.17.19" + "@esbuild/openbsd-x64" "0.17.19" + "@esbuild/sunos-x64" "0.17.19" + "@esbuild/win32-arm64" "0.17.19" + "@esbuild/win32-ia32" "0.17.19" + "@esbuild/win32-x64" "0.17.19" escalade@^3.1.1: version "3.1.1" @@ -12108,11 +12179,6 @@ functions-have-names@^1.2.2, functions-have-names@^1.2.3: resolved "https://registry.yarnpkg.com/functions-have-names/-/functions-have-names-1.2.3.tgz#0404fe4ee2ba2f607f0e0ec3c80bae994133b834" integrity sha512-xckBUXyTIqT97tq2x2AMb+g163b5JFysYk0x4qxNFwbfQkmNZoiRHb6sPzI9/QV33WeuvVYBUIiD4NzNIyqaRQ== -fuzzaldrin@^2.1.0: - version "2.1.0" - resolved "https://registry.npmjs.org/fuzzaldrin/-/fuzzaldrin-2.1.0.tgz" - integrity sha1-kCBMPi/appQbso0WZF1BgGOpDps= - gensync@^1.0.0-beta.2: version "1.0.0-beta.2" resolved "https://registry.yarnpkg.com/gensync/-/gensync-1.0.0-beta.2.tgz#32a6ee76c3d7f52d46b2b1ae5d93fea8580a25e0" @@ -13918,11 +13984,6 @@ jest-get-type@^25.2.6: resolved "https://registry.npmjs.org/jest-get-type/-/jest-get-type-25.2.6.tgz" integrity sha512-DxjtyzOHjObRM+sM1knti6or+eOgcGU4xVSb2HNP1TqO4ahsT+rqZg+nyqHWJSvWgKC5cG3QjGFBqxLghiF/Ig== -jest-get-type@^26.3.0: - version "26.3.0" - resolved "https://registry.yarnpkg.com/jest-get-type/-/jest-get-type-26.3.0.tgz#e97dc3c3f53c2b406ca7afaed4493b1d099199e0" - integrity sha512-TpfaviN1R2pQWkIihlfEanwOXK0zcxrKEE4MlU6Tn7keoXdN6/3gK/xl0yEh8DOunn5pOVGKf8hB4R9gVh04ig== - jest-get-type@^27.5.1: version "27.5.1" resolved "https://registry.yarnpkg.com/jest-get-type/-/jest-get-type-27.5.1.tgz#3cd613c507b0f7ace013df407a1c1cd578bcb4f1" @@ -14377,18 +14438,6 @@ jest-util@^29.0.0, jest-util@^29.6.1: graceful-fs "^4.2.9" picomatch "^2.2.3" -jest-validate@^26.5.2: - version "26.6.2" - resolved "https://registry.npmjs.org/jest-validate/-/jest-validate-26.6.2.tgz" - integrity sha512-NEYZ9Aeyj0i5rQqbq+tpIOom0YS1u2MVu6+euBsvpgIme+FOfRmoC4R5p0JiAUpaFvFy24xgrpMknarR/93XjQ== - dependencies: - "@jest/types" "^26.6.2" - camelcase "^6.0.0" - chalk "^4.0.0" - jest-get-type "^26.3.0" - leven "^3.1.0" - pretty-format "^26.6.2" - jest-validate@^27.5.1: version "27.5.1" resolved "https://registry.yarnpkg.com/jest-validate/-/jest-validate-27.5.1.tgz#9197d54dc0bdb52260b8db40b46ae668e04df067" @@ -14401,17 +14450,17 @@ jest-validate@^27.5.1: leven "^3.1.0" pretty-format "^27.5.1" -jest-validate@^29.6.1: - version "29.6.1" - resolved "https://registry.yarnpkg.com/jest-validate/-/jest-validate-29.6.1.tgz#765e684af6e2c86dce950aebefbbcd4546d69f7b" - integrity sha512-r3Ds69/0KCN4vx4sYAbGL1EVpZ7MSS0vLmd3gV78O+NAx3PDQQukRU5hNHPXlyqCgFY8XUk7EuTMLugh0KzahA== +jest-validate@^29.4.3, jest-validate@^29.6.1: + version "29.6.2" + resolved "https://registry.yarnpkg.com/jest-validate/-/jest-validate-29.6.2.tgz#25d972af35b2415b83b1373baf1a47bb266c1082" + integrity sha512-vGz0yMN5fUFRRbpJDPwxMpgSXW1LDKROHfBopAvDcmD6s+B/s8WJrwi+4bfH4SdInBA5C3P3BI19dBtKzx1Arg== dependencies: "@jest/types" "^29.6.1" camelcase "^6.2.0" chalk "^4.0.0" jest-get-type "^29.4.3" leven "^3.1.0" - pretty-format "^29.6.1" + pretty-format "^29.6.2" jest-watch-typeahead@^1.0.0: version "1.1.0" @@ -15036,7 +15085,7 @@ lodash.flattendeep@^4.4.0: resolved "https://registry.yarnpkg.com/lodash.flattendeep/-/lodash.flattendeep-4.4.0.tgz#fb030917f86a3134e5bc9bec0d69e0013ddfedb2" integrity sha512-uHaJFihxmJcEX3kT4I23ABqKKalJ/zDrDg0lsFtc1h+3uw49SIJ5beyhx5ExVRti3AvKoOJngIj7xz3oylPdWQ== -lodash.get@^4, lodash.get@^4.4.2: +lodash.get@^4.4.2: version "4.4.2" resolved "https://registry.npmjs.org/lodash.get/-/lodash.get-4.4.2.tgz" integrity sha1-LRd/ZS+jHpObRDjVNBSZ36OCXpk= @@ -15166,16 +15215,11 @@ make-dir@^3.0.0, make-dir@^3.0.2, make-dir@^3.1.0: dependencies: semver "^6.0.0" -make-error@1.x, make-error@^1, make-error@^1.1.1: +make-error@1.x, make-error@^1.1.1: version "1.3.6" resolved "https://registry.npmjs.org/make-error/-/make-error-1.3.6.tgz" integrity sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw== -make-plural@^6.2.2: - version "6.2.2" - resolved "https://registry.npmjs.org/make-plural/-/make-plural-6.2.2.tgz" - integrity sha512-8iTuFioatnTTmb/YJjywkVIHLjcwkFD9Ms0JpxjEm9Mo8eQYkh1z+55dwv4yc1jQ8ftVBxWQbihvZL1DfzGGWA== - make-plural@^7.0.0: version "7.0.0" resolved "https://registry.yarnpkg.com/make-plural/-/make-plural-7.0.0.tgz#f4c9c5c3334b935788f10815ffbaa55c9b2e8393" @@ -15321,11 +15365,6 @@ mersenne-twister@^1.1.0: resolved "https://registry.yarnpkg.com/mersenne-twister/-/mersenne-twister-1.1.0.tgz#f916618ee43d7179efcf641bec4531eb9670978a" integrity sha1-+RZhjuQ9cXnvz2Qb7EUx65Zwl4o= -messageformat-parser@^4.1.3: - version "4.1.3" - resolved "https://registry.npmjs.org/messageformat-parser/-/messageformat-parser-4.1.3.tgz" - integrity sha512-2fU3XDCanRqeOCkn7R5zW5VQHWf+T3hH65SzuqRvjatBK7r4uyFa5mEX+k6F9Bd04LVM5G4/BHBTUJsOdW7uyg== - methods@~1.1.2: version "1.1.2" resolved "https://registry.yarnpkg.com/methods/-/methods-1.1.2.tgz#5529a4d67654134edcc5266656835b0f851afcee" @@ -15408,10 +15447,10 @@ min-indent@^1.0.0: resolved "https://registry.yarnpkg.com/min-indent/-/min-indent-1.0.1.tgz#a63f681673b30571fbe8bc25686ae746eefa9869" integrity sha512-I9jwMn07Sy/IwOj3zVkVik2JTvgpaykDZEigL6Rx6N9LbMywwUSMtxET+7lVoDLLd3O3IXwJwvuuns8UB/HeAg== -mini-css-extract-plugin@^2.4.5: - version "2.7.5" - resolved "https://registry.yarnpkg.com/mini-css-extract-plugin/-/mini-css-extract-plugin-2.7.5.tgz#afbb344977659ec0f1f6e050c7aea456b121cfc5" - integrity sha512-9HaR++0mlgom81s95vvNjxkg52n2b5s//3ZTI1EtzFb98awsLSivs2LMsVqnQ3ay0PVhqWcGNyDaTE961FOcjQ== +mini-css-extract-plugin@^2.4.5, mini-css-extract-plugin@^2.7.6: + version "2.7.6" + resolved "https://registry.yarnpkg.com/mini-css-extract-plugin/-/mini-css-extract-plugin-2.7.6.tgz#282a3d38863fddcd2e0c220aaed5b90bc156564d" + integrity sha512-Qk7HcgaPkGG6eD77mLvZS1nmxlao3j+9PkrT9Uc7HAE1id3F41+DdBRYRYkbyfNRGzm8/YWtzhw7nVPmwhqTQw== dependencies: schema-utils "^4.0.0" @@ -15558,6 +15597,11 @@ moment@^2.19.3: resolved "https://registry.yarnpkg.com/moment/-/moment-2.29.1.tgz#b2be769fa31940be9eeea6469c075e35006fa3d3" integrity sha512-kHmoybcPV8Sqy59DwNDY3Jefr64lK/by/da0ViFcuA4DH0vQg5Q6Ze5VimxkfQNSC+Mls/Kx53s7TjP1RhFEDQ== +moo@^0.5.1: + version "0.5.2" + resolved "https://registry.yarnpkg.com/moo/-/moo-0.5.2.tgz#f9fe82473bc7c184b0d32e2215d3f6e67278733c" + integrity sha512-iSAJLHYKnX41mKcJKjqvnAN9sf0LMDTXDEvFv+ffuRR9a1MIuXLjMNL6EsnDHSkKLTWNqQQ5uo61P4EbU4NU+Q== + motion@10.16.2: version "10.16.2" resolved "https://registry.yarnpkg.com/motion/-/motion-10.16.2.tgz#7dc173c6ad62210a7e9916caeeaf22c51e598d21" @@ -15570,14 +15614,6 @@ motion@10.16.2: "@motionone/utils" "^10.15.1" "@motionone/vue" "^10.16.2" -ms.macro@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/ms.macro/-/ms.macro-2.0.0.tgz#ff72d230cde33797d30b9b61eb57d4940dddd66f" - integrity sha512-vkb83Sa4BZ2ynF/C1x5D8ofExja36mYW6OB7JNh6Ek0NSw3Oj4moM0nN69rfbm28aHlON52E+dTEgW+3up3x1g== - dependencies: - babel-plugin-macros "^2.0.0" - ms "^2.0.0" - ms@2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/ms/-/ms-2.0.0.tgz#5608aeadfc00be6c2901df5f9861788de0d597c8" @@ -15588,7 +15624,7 @@ ms@2.1.2: resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.2.tgz#d09d1f357b443f493382a8eb3ccd183872ae6009" integrity sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w== -ms@2.1.3, ms@^2.0.0, ms@^2.1.1: +ms@2.1.3, ms@^2.0.0, ms@^2.1.1, ms@^2.1.3: version "2.1.3" resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.3.tgz#574c8138ce1d2b5861f0b44579dbadd60c6615b2" integrity sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA== @@ -15764,13 +15800,6 @@ node-forge@^1: resolved "https://registry.yarnpkg.com/node-forge/-/node-forge-1.3.1.tgz#be8da2af243b2417d5f646a770663a92b7e9ded3" integrity sha512-dPEtOeMvF9VMcYV/1Wb8CPoVAXtp6MKMlcbAt4ddqmGqUJ6fQZFXkNZNkNlfevtNkGtaSoXf/vNNNSvgrdXwtA== -node-gettext@^3.0.0: - version "3.0.0" - resolved "https://registry.npmjs.org/node-gettext/-/node-gettext-3.0.0.tgz" - integrity sha512-/VRYibXmVoN6tnSAY2JWhNRhWYJ8Cd844jrZU/DwLVoI4vBI6ceYbd8i42sYZ9uOgDH3S7vslIKOWV/ZrT2YBA== - dependencies: - lodash.get "^4.4.2" - node-gyp-build@^4.2.0, node-gyp-build@^4.3.0: version "4.5.0" resolved "https://registry.yarnpkg.com/node-gyp-build/-/node-gyp-build-4.5.0.tgz#7a64eefa0b21112f89f58379da128ac177f20e40" @@ -16237,11 +16266,6 @@ pako@^1.0.5: resolved "https://registry.npmjs.org/pako/-/pako-1.0.11.tgz" integrity sha512-4hLB8Py4zZce5s4yd9XzopqwVv/yGNhV1Bl8NTmCq1763HeK2+EwVTv+leGeL13Dnh2wfbqowVPXCIO0z4taYw== -papaparse@^5.3.0: - version "5.3.0" - resolved "https://registry.npmjs.org/papaparse/-/papaparse-5.3.0.tgz" - integrity sha512-Lb7jN/4bTpiuGPrYy4tkKoUS8sTki8zacB5ke1p5zolhcSE4TlWgrlsxjrDTbG/dFVh07ck7X36hUf/b5V68pg== - param-case@^3.0.4: version "3.0.4" resolved "https://registry.npmjs.org/param-case/-/param-case-3.0.4.tgz" @@ -16540,11 +16564,6 @@ pkg-up@^3.1.0: dependencies: find-up "^3.0.0" -plurals-cldr@^1.0.4: - version "1.0.4" - resolved "https://registry.npmjs.org/plurals-cldr/-/plurals-cldr-1.0.4.tgz" - integrity sha512-4nLXqtel7fsCgzi8dvRZvUjfL8SXpP982sKg7b2TgpnR8rDnes06iuQ83trQ/+XdtyMIQkBBbKzX6x97eLfsJQ== - pngjs@^3.0.0, pngjs@^3.3.3: version "3.4.0" resolved "https://registry.npmjs.org/pngjs/-/pngjs-3.4.0.tgz" @@ -16555,10 +16574,10 @@ pngjs@^5.0.0: resolved "https://registry.yarnpkg.com/pngjs/-/pngjs-5.0.0.tgz#e79dd2b215767fd9c04561c01236df960bce7fbb" integrity sha512-40QW5YalBNfQo5yRYmiw7Yz6TKKVr3h6970B2YE+3fQpsWcrbj1PzJgxeJ19DRQjhMbKPIuMY8rFaXc8moolVw== -pofile@^1.1.0: - version "1.1.1" - resolved "https://registry.npmjs.org/pofile/-/pofile-1.1.1.tgz" - integrity sha512-RVAzFGo1Mx9+YukVKSgTLut6r4ZVBW8IVrqGHAPfEsVJN93WSp5HRD6+qNa7av1q/joPKDNJd55m5AJl9GBQGA== +pofile@^1.1.4: + version "1.1.4" + resolved "https://registry.yarnpkg.com/pofile/-/pofile-1.1.4.tgz#eab7e29f5017589b2a61b2259dff608c0cad76a2" + integrity sha512-r6Q21sKsY1AjTVVjOuU02VYKVNQGJNQHjTIvs4dEbeuuYfxgYk/DGD2mqqq4RDaVkwdSq0VEtmQUOPe/wH8X3g== polished@^3.3.2: version "3.7.1" @@ -17316,12 +17335,12 @@ proxy-from-env@1.0.0: resolved "https://registry.yarnpkg.com/proxy-from-env/-/proxy-from-env-1.0.0.tgz#33c50398f70ea7eb96d21f7b817630a55791c7ee" integrity sha512-F2JHgJQ1iqwnHDcQjVBsq3n/uoaFL+iPW/eAeL7kVxy/2RrWaN4WroKjjvbsoRtv0ftelNyC01bjRhn/bhcf4A== -pseudolocale@^1.1.0: - version "1.2.0" - resolved "https://registry.npmjs.org/pseudolocale/-/pseudolocale-1.2.0.tgz" - integrity sha512-k0OQFvIlvpRdzR0dPVrrbWX7eE9EaZ6gpZtTlFSDi1Gf9tMy9wiANCNu7JZ0drcKgUri/39a2mBbH0goiQmrmQ== +pseudolocale@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/pseudolocale/-/pseudolocale-2.0.0.tgz#4dbe725a6b5a6fb71aba8ba64ae2be71f5267316" + integrity sha512-g1K9tCQYY4e3UGtnW8qs3kGWAOONxt7i5wuOFvf3N1EIIRhiLVIhZ9AM/ZyGTxsp231JbFywJU/EbJ5ZoqnZdg== dependencies: - commander "*" + commander "^10.0.0" pseudomap@^1.0.2: version "1.0.2" @@ -18487,10 +18506,10 @@ schema-utils@^2.6.5: ajv "^6.12.4" ajv-keywords "^3.5.2" -schema-utils@^3.0.0, schema-utils@^3.1.1, schema-utils@^3.1.2: - version "3.1.2" - resolved "https://registry.yarnpkg.com/schema-utils/-/schema-utils-3.1.2.tgz#36c10abca6f7577aeae136c804b0c741edeadc99" - integrity sha512-pvjEHOgWc9OWA/f/DE3ohBWTD6EleVLf7iFUkoSwAxttdBhB9QUebQgxER2kWueOvRJXPHNnyrvvh9eZINB8Eg== +schema-utils@^3.0.0, schema-utils@^3.1.1, schema-utils@^3.2.0: + version "3.3.0" + resolved "https://registry.yarnpkg.com/schema-utils/-/schema-utils-3.3.0.tgz#f50a88877c3c01652a15b622ae9e9795df7a60fe" + integrity sha512-pN/yOAvcC+5rQ5nERGuwrjLlYvLTbCibnZ1I7B1LaiAz9BRBlE9GMgE/eqV30P7aJQUf7Ddimy/RsbYO/GrVGg== dependencies: "@types/json-schema" "^7.0.8" ajv "^6.12.5" @@ -18542,10 +18561,10 @@ semver@^5.5.0: resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.1.tgz#a954f931aeba508d307bbf069eff0c01c96116f7" integrity sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ== -semver@^6.0.0, semver@^6.1.1, semver@^6.1.2, semver@^6.3.0: - version "6.3.0" - resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.0.tgz#ee0a64c8af5e8ceea67687b133761e1becbd1d3d" - integrity sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw== +semver@^6.0.0, semver@^6.1.1, semver@^6.1.2, semver@^6.3.0, semver@^6.3.1: + version "6.3.1" + resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.1.tgz#556d2ef8689146e46dcea4bfdd095f3434dffcb4" + integrity sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA== semver@^7.2.1, semver@^7.3.2, semver@^7.3.5, semver@^7.3.7, semver@^7.3.8, semver@^7.5.3: version "7.5.3" @@ -18892,7 +18911,7 @@ source-map-support@0.5.13: buffer-from "^1.0.0" source-map "^0.6.0" -source-map-support@0.5.21, source-map-support@^0.5.13, source-map-support@^0.5.17, source-map-support@^0.5.21, source-map-support@^0.5.6, source-map-support@~0.5.20: +source-map-support@0.5.21, source-map-support@^0.5.13, source-map-support@^0.5.21, source-map-support@^0.5.6, source-map-support@~0.5.20: version "0.5.21" resolved "https://registry.yarnpkg.com/source-map-support/-/source-map-support-0.5.21.tgz#04fe7c7f9e1ed2d662233c28cb2b35b9f63f6e4f" integrity sha512-uBHU3L3czsIyYXKX88fdrGovxdSCoTGDRZ6SYXtSRxLZUzHg5P/66Ht6uoUlHu9EZod+inXhKo3qQgwXUT/y1w== @@ -19427,6 +19446,11 @@ swap-case@^2.0.2: dependencies: tslib "^2.0.3" +swc-loader@^0.2.3: + version "0.2.3" + resolved "https://registry.yarnpkg.com/swc-loader/-/swc-loader-0.2.3.tgz#6792f1c2e4c9ae9bf9b933b3e010210e270c186d" + integrity sha512-D1p6XXURfSPleZZA/Lipb3A8pZ17fP4NObZvFCDjK/OKljroqDpPmsBdTraWhVBqUNpcWBQY1imWdoPScRlQ7A== + symbol-observable@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/symbol-observable/-/symbol-observable-4.0.0.tgz#5b425f192279e87f2f9b937ac8540d1984b39205" @@ -19555,24 +19579,24 @@ terminal-link@^2.0.0: ansi-escapes "^4.2.1" supports-hyperlinks "^2.0.0" -terser-webpack-plugin@^5.2.5, terser-webpack-plugin@^5.3.7: - version "5.3.7" - resolved "https://registry.yarnpkg.com/terser-webpack-plugin/-/terser-webpack-plugin-5.3.7.tgz#ef760632d24991760f339fe9290deb936ad1ffc7" - integrity sha512-AfKwIktyP7Cu50xNjXF/6Qb5lBNzYaWpU6YfoX3uZicTx0zTy0stDDCsvjDapKsSDvOeWo5MEq4TmdBy2cNoHw== +terser-webpack-plugin@^5.2.5, terser-webpack-plugin@^5.3.7, terser-webpack-plugin@^5.3.9: + version "5.3.9" + resolved "https://registry.yarnpkg.com/terser-webpack-plugin/-/terser-webpack-plugin-5.3.9.tgz#832536999c51b46d468067f9e37662a3b96adfe1" + integrity sha512-ZuXsqE07EcggTWQjXUj+Aot/OMcD0bMKGgF63f7UxYcu5/AJF53aIpK1YoP5xR9l6s/Hy2b+t1AM0bLNPRuhwA== dependencies: "@jridgewell/trace-mapping" "^0.3.17" jest-worker "^27.4.5" schema-utils "^3.1.1" serialize-javascript "^6.0.1" - terser "^5.16.5" + terser "^5.16.8" -terser@^5.0.0, terser@^5.10.0, terser@^5.16.5: - version "5.17.1" - resolved "https://registry.yarnpkg.com/terser/-/terser-5.17.1.tgz#948f10830454761e2eeedc6debe45c532c83fd69" - integrity sha512-hVl35zClmpisy6oaoKALOpS0rDYLxRFLHhRuDlEGTKey9qHjS1w9GMORjuwIMt70Wan4lwsLYyWDVnWgF+KUEw== +terser@^5.0.0, terser@^5.10.0, terser@^5.16.8: + version "5.19.2" + resolved "https://registry.yarnpkg.com/terser/-/terser-5.19.2.tgz#bdb8017a9a4a8de4663a7983f45c506534f9234e" + integrity sha512-qC5+dmecKJA4cpYxRa5aVkKehYsQKc+AHeKl0Oe62aYjBL8ZA33tTljktDHJSaxxMnbI5ZYw+o/S2DxxLu8OfA== dependencies: - "@jridgewell/source-map" "^0.3.2" - acorn "^8.5.0" + "@jridgewell/source-map" "^0.3.3" + acorn "^8.8.2" commander "^2.20.0" source-map-support "~0.5.20" @@ -19851,18 +19875,6 @@ ts-node@^10.7.0: v8-compile-cache-lib "^3.0.1" yn "3.1.1" -ts-node@^9: - version "9.1.1" - resolved "https://registry.npmjs.org/ts-node/-/ts-node-9.1.1.tgz" - integrity sha512-hPlt7ZACERQGf03M253ytLY3dHbGNGrAq9qIHWUY9XHYl1z7wYngSr3OQ5xmui8o2AaxsONxIzjafLUiWBo1Fg== - dependencies: - arg "^4.1.0" - create-require "^1.1.0" - diff "^4.0.1" - make-error "^1.1.1" - source-map-support "^0.5.17" - yn "3.1.1" - ts-transform-graphql-tag@^0.2.1: version "0.2.1" resolved "https://registry.yarnpkg.com/ts-transform-graphql-tag/-/ts-transform-graphql-tag-0.2.1.tgz#f596c491196b6a6a65b65a8b99bf6e2314c78017" @@ -19883,7 +19895,7 @@ tslib@1.14.1, tslib@^1.0.0, tslib@^1.8.1, tslib@^1.9.0, tslib@^1.9.3: resolved "https://registry.yarnpkg.com/tslib/-/tslib-1.14.1.tgz#cf2d38bdc34a134bcaf1091c41f6619e2f672d00" integrity sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg== -tslib@^2, tslib@^2.0.0, tslib@^2.0.3, tslib@^2.1.0, tslib@^2.2.0, tslib@^2.3.0, tslib@^2.3.1, tslib@^2.4.0, tslib@^2.4.1, tslib@^2.5.0: +tslib@^2.0.0, tslib@^2.0.3, tslib@^2.1.0, tslib@^2.2.0, tslib@^2.3.0, tslib@^2.3.1, tslib@^2.4.0, tslib@^2.4.1, tslib@^2.5.0: version "2.6.1" resolved "https://registry.yarnpkg.com/tslib/-/tslib-2.6.1.tgz#fd8c9a0ff42590b25703c0acb3de3d3f4ede0410" integrity sha512-t0hLfiEKfMUoqhG+U1oid7Pva4bbDPHYfJNiB7BiIjRkj1pyC++4N3huJfqY6aRH6VTB0rvtzQwjM4K6qpfOig== @@ -20189,6 +20201,11 @@ unquote@~1.1.1: resolved "https://registry.yarnpkg.com/unquote/-/unquote-1.1.1.tgz#8fded7324ec6e88a0ff8b905e7c098cdc086d544" integrity sha1-j97XMk7G6IoP+LkF58CYzcCG1UQ= +unraw@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/unraw/-/unraw-2.0.1.tgz#7b51dcdfb1e43d59d5e52cdb44d349d029edbaba" + integrity sha512-tdOvLfRzHolwYcHS6HIX860MkK9LQ4+oLuNwFYL7bpgTEO64PZrcQxkisgwJYCfF8sKiWLwwu1c83DvMkbefIQ== + untildify@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/untildify/-/untildify-4.0.0.tgz#2bc947b953652487e4600949fb091e3ae8cd919b" @@ -20678,10 +20695,10 @@ webpack-sources@^3.2.3: resolved "https://registry.yarnpkg.com/webpack-sources/-/webpack-sources-3.2.3.tgz#2d4daab8451fd4b240cc27055ff6a0c2ccea0cde" integrity sha512-/DyMEOrDgLKKIG0fmvtz+4dUX/3Ghozwgm6iPp8KRhvn+eQf9+Q7GWxVNMk3+uCPWfdXYC4ExGBckIXdFEfH1w== -webpack@^5.64.4: - version "5.81.0" - resolved "https://registry.yarnpkg.com/webpack/-/webpack-5.81.0.tgz#27a2e8466c8b4820d800a8d90f06ef98294f9956" - integrity sha512-AAjaJ9S4hYCVODKLQTgG5p5e11hiMawBwV2v8MYLE0C/6UAGLuAF4n1qa9GOwdxnicaP+5k6M5HrLmD4+gIB8Q== +webpack@^5.64.4, webpack@^5.88.2: + version "5.88.2" + resolved "https://registry.yarnpkg.com/webpack/-/webpack-5.88.2.tgz#f62b4b842f1c6ff580f3fcb2ed4f0b579f4c210e" + integrity sha512-JmcgNZ1iKj+aiR0OvTYtWQqJwq37Pf683dY9bVORwVbUrDhLhdn/PlO2sHsFHPkj7sHNQF3JwaAkp49V+Sq1tQ== dependencies: "@types/eslint-scope" "^3.7.3" "@types/estree" "^1.0.0" @@ -20689,10 +20706,10 @@ webpack@^5.64.4: "@webassemblyjs/wasm-edit" "^1.11.5" "@webassemblyjs/wasm-parser" "^1.11.5" acorn "^8.7.1" - acorn-import-assertions "^1.7.6" + acorn-import-assertions "^1.9.0" browserslist "^4.14.5" chrome-trace-event "^1.0.2" - enhanced-resolve "^5.13.0" + enhanced-resolve "^5.15.0" es-module-lexer "^1.2.1" eslint-scope "5.1.1" events "^3.2.0" @@ -20702,7 +20719,7 @@ webpack@^5.64.4: loader-runner "^4.2.0" mime-types "^2.1.27" neo-async "^2.6.2" - schema-utils "^3.1.2" + schema-utils "^3.2.0" tapable "^2.1.1" terser-webpack-plugin "^5.3.7" watchpack "^2.4.0"