├── .github ├── actions │ └── yarn-nm-install │ │ └── action.yml ├── dependabot.yml └── workflows │ ├── cleanup-pr-caches.yaml │ └── test.yaml ├── .gitignore ├── .npmrc ├── .nvmrc ├── .prettierrc ├── .yarn └── releases │ └── yarn-4.1.1.cjs ├── .yarnrc.yml ├── README.md ├── apps └── directory │ ├── .eslintrc.js │ ├── README.md │ ├── components.json │ ├── next-env.d.ts │ ├── next.config.mjs │ ├── package.json │ ├── postcss.config.js │ ├── public │ └── directory-landing.png │ ├── src │ ├── app │ │ ├── layout.tsx │ │ └── page.tsx │ ├── components │ │ ├── filters.tsx │ │ ├── footer.tsx │ │ ├── grid-pattern.tsx │ │ ├── header.tsx │ │ ├── hero.tsx │ │ ├── icons │ │ │ ├── github.tsx │ │ │ ├── swing.tsx │ │ │ └── twitter.tsx │ │ ├── template-grid.tsx │ │ ├── templates.tsx │ │ ├── theme-provider.tsx │ │ └── ui │ │ │ ├── accordion.tsx │ │ │ ├── avatar.tsx │ │ │ ├── badge.tsx │ │ │ ├── button.tsx │ │ │ ├── card.tsx │ │ │ ├── checkbox.tsx │ │ │ ├── dialog.tsx │ │ │ └── drawer.tsx │ ├── hooks │ │ └── use-media-query.tsx │ ├── lib │ │ ├── keywords.ts │ │ ├── slugify.ts │ │ ├── templates.ts │ │ └── utils.ts │ └── styles │ │ └── globals.css │ ├── tailwind.config.js │ └── tsconfig.json ├── examples ├── gas-widget-nextjs │ ├── .eslintrc.js │ ├── .gitignore │ ├── README.md │ ├── next.config.mjs │ ├── package.json │ ├── postcss.config.js │ ├── public │ │ ├── favicon.ico │ │ └── vercel.svg │ ├── src │ │ ├── app │ │ │ ├── layout.tsx │ │ │ └── page.tsx │ │ ├── components │ │ │ ├── Button.tsx │ │ │ └── Sidebar.tsx │ │ └── styles │ │ │ └── globals.css │ ├── tailwind.config.js │ └── tsconfig.json ├── staking-api-nextjs │ └── README.md ├── staking-sdk-nextjs │ ├── .eslintrc.js │ ├── .gitignore │ ├── README.md │ ├── components.json │ ├── next.config.mjs │ ├── package.json │ ├── postcss.config.js │ ├── public │ │ ├── favicon.ico │ │ └── vercel.svg │ ├── src │ │ ├── app │ │ │ ├── layout.tsx │ │ │ └── page.tsx │ │ ├── components │ │ │ ├── ConnectWallet.tsx │ │ │ ├── Sidebar.tsx │ │ │ ├── Stake.tsx │ │ │ ├── SwingSdkProvider.tsx │ │ │ ├── WagmiProvider.tsx │ │ │ └── ui │ │ │ │ ├── avatar.tsx │ │ │ │ ├── button.tsx │ │ │ │ └── dialog.tsx │ │ ├── hooks │ │ │ └── useConnectWallet.tsx │ │ ├── lib │ │ │ └── utils.ts │ │ └── styles │ │ │ └── globals.css │ ├── tailwind.config.js │ └── tsconfig.json ├── staking-widget-nextjs │ ├── .eslintrc.js │ ├── .gitignore │ ├── README.md │ ├── next.config.mjs │ ├── package.json │ ├── postcss.config.js │ ├── public │ │ ├── favicon.ico │ │ └── vercel.svg │ ├── src │ │ ├── app │ │ │ ├── layout.tsx │ │ │ └── page.tsx │ │ ├── components │ │ │ ├── ConnectWallet.tsx │ │ │ ├── Sidebar.tsx │ │ │ ├── WagmiProvider.tsx │ │ │ └── ui │ │ │ │ ├── avatar.tsx │ │ │ │ ├── button.tsx │ │ │ │ └── dialog.tsx │ │ ├── lib │ │ │ └── utils.ts │ │ └── styles │ │ │ └── globals.css │ ├── tailwind.config.js │ └── tsconfig.json ├── swaps-api-nextjs-bitcoin │ ├── .eslintrc.js │ ├── .gitignore │ ├── README.md │ ├── components.json │ ├── next-env.d.ts │ ├── next.config.mjs │ ├── package.json │ ├── postcss.config.js │ ├── public │ │ ├── favicon.ico │ │ └── fonts │ │ │ ├── Inter-italic.var.woff2 │ │ │ └── Inter-roman.var.woff2 │ ├── src │ │ ├── app │ │ │ ├── layout.tsx │ │ │ └── page.tsx │ │ ├── components │ │ │ ├── Swap.tsx │ │ │ ├── ThirdwebProvider.tsx │ │ │ └── ui │ │ │ │ ├── Button.tsx │ │ │ │ ├── Container.tsx │ │ │ │ ├── Footer.tsx │ │ │ │ ├── Header.tsx │ │ │ │ ├── Hero.tsx │ │ │ │ ├── NavLinks.tsx │ │ │ │ ├── input.tsx │ │ │ │ ├── label.tsx │ │ │ │ ├── popover.tsx │ │ │ │ ├── toast.tsx │ │ │ │ ├── toaster.tsx │ │ │ │ └── use-toast.ts │ │ ├── images │ │ │ └── logos │ │ │ │ ├── cnn.svg │ │ │ │ ├── forbes.svg │ │ │ │ ├── techcrunch.svg │ │ │ │ └── wired.svg │ │ ├── interfaces │ │ │ ├── quote.interface.ts │ │ │ ├── send.interface.ts │ │ │ └── status.interface.ts │ │ ├── lib.ts │ │ ├── services │ │ │ └── requests.ts │ │ ├── styles │ │ │ └── globals.css │ │ └── utils │ │ │ └── ethToWei.ts │ ├── styles │ │ └── globals.css │ ├── tailwind.config.js │ ├── tsconfig.json │ └── turbo.json ├── swaps-api-nextjs-solana │ ├── .eslintrc.js │ ├── .gitignore │ ├── README.md │ ├── components.json │ ├── next-env.d.ts │ ├── next.config.mjs │ ├── package.json │ ├── postcss.config.js │ ├── public │ │ ├── favicon.ico │ │ └── fonts │ │ │ ├── Inter-italic.var.woff2 │ │ │ └── Inter-roman.var.woff2 │ ├── src │ │ ├── app │ │ │ ├── layout.tsx │ │ │ └── page.tsx │ │ ├── components │ │ │ ├── Swap.tsx │ │ │ ├── ThirdwebProvider.tsx │ │ │ └── ui │ │ │ │ ├── Backdrop.tsx │ │ │ │ ├── Button.tsx │ │ │ │ ├── ChainTokenItem.tsx │ │ │ │ ├── Container.tsx │ │ │ │ ├── Header.tsx │ │ │ │ ├── Hero.tsx │ │ │ │ ├── NavLinks.tsx │ │ │ │ ├── SelectChainPanel.tsx │ │ │ │ ├── SelectTokenPanel.tsx │ │ │ │ ├── TransferHistoryPanel.tsx │ │ │ │ ├── input.tsx │ │ │ │ ├── label.tsx │ │ │ │ ├── popover.tsx │ │ │ │ ├── toast.tsx │ │ │ │ ├── toaster.tsx │ │ │ │ └── use-toast.ts │ │ ├── images │ │ │ └── logos │ │ │ │ ├── cnn.svg │ │ │ │ ├── forbes.svg │ │ │ │ ├── sols.png │ │ │ │ ├── techcrunch.svg │ │ │ │ └── wired.svg │ │ ├── interfaces │ │ │ ├── allowance.interface.ts │ │ │ ├── approval.interface.ts │ │ │ ├── chain.interface.ts │ │ │ ├── history.interface.ts │ │ │ ├── quote.interface.ts │ │ │ ├── send.interface.ts │ │ │ ├── status.interface.ts │ │ │ ├── swing-service.interface.ts │ │ │ └── token.interface.ts │ │ ├── lib.ts │ │ ├── services │ │ │ └── requests.ts │ │ ├── styles │ │ │ └── globals.css │ │ ├── types │ │ │ ├── global.d.ts │ │ │ └── transfer.types.ts │ │ └── utils │ │ │ └── ethToWei.ts │ ├── styles │ │ └── globals.css │ ├── tailwind.config.js │ ├── tsconfig.json │ └── turbo.json ├── swaps-api-nextjs-ton │ ├── .eslintrc.js │ ├── .gitignore │ ├── README.md │ ├── components.json │ ├── next-env.d.ts │ ├── next.config.mjs │ ├── package.json │ ├── postcss.config.js │ ├── public │ │ ├── favicon.ico │ │ └── fonts │ │ │ ├── Inter-italic.var.woff2 │ │ │ └── Inter-roman.var.woff2 │ ├── src │ │ ├── app │ │ │ ├── api │ │ │ │ └── ton-connect │ │ │ │ │ └── route.ts │ │ │ ├── layout.tsx │ │ │ └── page.tsx │ │ ├── components │ │ │ ├── Swap.tsx │ │ │ ├── ThirdwebProvider.tsx │ │ │ └── ui │ │ │ │ ├── Backdrop.tsx │ │ │ │ ├── Button.tsx │ │ │ │ ├── ChainTokenItem.tsx │ │ │ │ ├── Container.tsx │ │ │ │ ├── Header.tsx │ │ │ │ ├── Hero.tsx │ │ │ │ ├── NavLinks.tsx │ │ │ │ ├── SelectChainPanel.tsx │ │ │ │ ├── SelectTokenPanel.tsx │ │ │ │ ├── TransferHistoryPanel.tsx │ │ │ │ ├── input.tsx │ │ │ │ ├── label.tsx │ │ │ │ ├── popover.tsx │ │ │ │ ├── toast.tsx │ │ │ │ ├── toaster.tsx │ │ │ │ └── use-toast.ts │ │ ├── images │ │ │ └── logos │ │ │ │ ├── cnn.svg │ │ │ │ ├── forbes.svg │ │ │ │ ├── sols.png │ │ │ │ ├── techcrunch.svg │ │ │ │ └── wired.svg │ │ ├── interfaces │ │ │ ├── allowance.interface.ts │ │ │ ├── approval.interface.ts │ │ │ ├── chain.interface.ts │ │ │ ├── history.interface.ts │ │ │ ├── quote.interface.ts │ │ │ ├── send.interface.ts │ │ │ ├── status.interface.ts │ │ │ ├── swing-service.interface.ts │ │ │ └── token.interface.ts │ │ ├── lib.ts │ │ ├── providers │ │ │ └── DefaultProviders.tsx │ │ ├── services │ │ │ └── requests.ts │ │ ├── styles │ │ │ └── globals.css │ │ ├── types │ │ │ ├── global.d.ts │ │ │ └── transfer.types.ts │ │ └── utils │ │ │ └── ethToWei.ts │ ├── styles │ │ └── globals.css │ ├── tailwind.config.js │ ├── tonconnect-manifest.json │ ├── tsconfig.json │ └── turbo.json ├── swaps-api-nextjs-tron │ ├── .eslintrc.js │ ├── .gitignore │ ├── README.md │ ├── components.json │ ├── next-env.d.ts │ ├── next.config.mjs │ ├── package.json │ ├── postcss.config.js │ ├── public │ │ ├── favicon.ico │ │ └── fonts │ │ │ ├── Inter-italic.var.woff2 │ │ │ └── Inter-roman.var.woff2 │ ├── src │ │ ├── app │ │ │ ├── layout.tsx │ │ │ └── page.tsx │ │ ├── components │ │ │ ├── Swap.tsx │ │ │ ├── ThirdwebProvider.tsx │ │ │ └── ui │ │ │ │ ├── Backdrop.tsx │ │ │ │ ├── Button.tsx │ │ │ │ ├── ChainTokenItem.tsx │ │ │ │ ├── Container.tsx │ │ │ │ ├── Header.tsx │ │ │ │ ├── Hero.tsx │ │ │ │ ├── NavLinks.tsx │ │ │ │ ├── SelectChainPanel.tsx │ │ │ │ ├── SelectTokenPanel.tsx │ │ │ │ ├── TransferHistoryPanel.tsx │ │ │ │ ├── input.tsx │ │ │ │ ├── label.tsx │ │ │ │ ├── popover.tsx │ │ │ │ ├── toast.tsx │ │ │ │ ├── toaster.tsx │ │ │ │ └── use-toast.ts │ │ ├── images │ │ │ └── logos │ │ │ │ ├── cnn.svg │ │ │ │ ├── forbes.svg │ │ │ │ ├── sols.png │ │ │ │ ├── techcrunch.svg │ │ │ │ └── wired.svg │ │ ├── interfaces │ │ │ ├── allowance.interface.ts │ │ │ ├── approval.interface.ts │ │ │ ├── chain.interface.ts │ │ │ ├── history.interface.ts │ │ │ ├── quote.interface.ts │ │ │ ├── send.interface.ts │ │ │ ├── status.interface.ts │ │ │ ├── swing-service.interface.ts │ │ │ └── token.interface.ts │ │ ├── lib.ts │ │ ├── services │ │ │ └── requests.ts │ │ ├── styles │ │ │ └── globals.css │ │ ├── types │ │ │ ├── global.d.ts │ │ │ └── transfer.types.ts │ │ └── utils │ │ │ └── ethToWei.ts │ ├── styles │ │ └── globals.css │ ├── tailwind.config.js │ ├── tsconfig.json │ └── turbo.json ├── swaps-api-nextjs │ └── README.md ├── swaps-sdk-nextjs-thirdweb-embedded-wallet │ ├── .eslintrc.js │ ├── .gitignore │ ├── README.md │ ├── components.json │ ├── next-env.d.ts │ ├── next.config.mjs │ ├── package.json │ ├── postcss.config.js │ ├── public │ │ ├── favicon.ico │ │ └── fonts │ │ │ ├── Inter-italic.var.woff2 │ │ │ └── Inter-roman.var.woff2 │ ├── src │ │ ├── app │ │ │ ├── interfaces │ │ │ │ ├── IChainSelector.tsx │ │ │ │ ├── IModal.tsx │ │ │ │ └── IRouteSelector.tsx │ │ │ ├── layout.tsx │ │ │ └── page.tsx │ │ ├── components │ │ │ ├── Swap.tsx │ │ │ ├── ThirdwebProvider.tsx │ │ │ ├── hooks │ │ │ │ ├── useModal.tsx │ │ │ │ ├── useSelectChain.tsx │ │ │ │ └── useSwingSDK.tsx │ │ │ ├── lib │ │ │ │ └── utils.ts │ │ │ └── ui │ │ │ │ ├── AppScreen.tsx │ │ │ │ ├── Backdrop.tsx │ │ │ │ ├── Button.tsx │ │ │ │ ├── Chain.tsx │ │ │ │ ├── Container.tsx │ │ │ │ ├── Footer.tsx │ │ │ │ ├── Header.tsx │ │ │ │ ├── Hero.tsx │ │ │ │ ├── Modal.tsx │ │ │ │ ├── NavLinks.tsx │ │ │ │ ├── Route.tsx │ │ │ │ ├── SelectChain.tsx │ │ │ │ ├── SelectRoute.tsx │ │ │ │ ├── Token.tsx │ │ │ │ ├── modals │ │ │ │ ├── SelectChainModal.tsx │ │ │ │ └── SelectRouteModal.tsx │ │ │ │ ├── toast.tsx │ │ │ │ ├── toaster.tsx │ │ │ │ └── use-toast.ts │ │ ├── images │ │ │ ├── logos │ │ │ │ ├── bbc.svg │ │ │ │ ├── cbs.svg │ │ │ │ ├── cnn.svg │ │ │ │ ├── fast-company.svg │ │ │ │ ├── forbes.svg │ │ │ │ ├── huffpost.svg │ │ │ │ ├── techcrunch.svg │ │ │ │ └── wired.svg │ │ │ ├── phone-frame.svg │ │ │ └── qr-code.svg │ │ └── styles │ │ │ └── globals.css │ ├── tailwind.config.js │ ├── tsconfig.json │ └── turbo.json ├── swaps-sdk-nextjs-web3-react │ ├── .eslintrc.js │ ├── .gitignore │ ├── README.md │ ├── components.json │ ├── next-env.d.ts │ ├── next.config.mjs │ ├── package.json │ ├── postcss.config.js │ ├── public │ │ ├── favicon.ico │ │ └── fonts │ │ │ ├── Inter-italic.var.woff2 │ │ │ └── Inter-roman.var.woff2 │ ├── src │ │ ├── app │ │ │ ├── layout.tsx │ │ │ └── page.tsx │ │ ├── components │ │ │ ├── Swap.tsx │ │ │ ├── Web3ReactProvider.tsx │ │ │ ├── lib │ │ │ │ └── utils.ts │ │ │ └── ui │ │ │ │ ├── Button.tsx │ │ │ │ ├── CircleBackground.tsx │ │ │ │ ├── Container.tsx │ │ │ │ ├── Footer.tsx │ │ │ │ ├── Header.tsx │ │ │ │ ├── Hero.tsx │ │ │ │ ├── NavLinks.tsx │ │ │ │ ├── StatusSheet.tsx │ │ │ │ ├── drawer.tsx │ │ │ │ ├── scroll-area.tsx │ │ │ │ ├── select.tsx │ │ │ │ ├── tabs.tsx │ │ │ │ ├── toast.tsx │ │ │ │ ├── toaster.tsx │ │ │ │ └── use-toast.ts │ │ └── styles │ │ │ └── globals.css │ ├── tailwind.config.js │ ├── tsconfig.json │ └── turbo.json ├── swaps-sdk-nextjs │ ├── .eslintrc.js │ ├── .gitignore │ ├── README.md │ ├── next-env.d.ts │ ├── next.config.mjs │ ├── package.json │ ├── postcss.config.js │ ├── public │ │ ├── favicon.ico │ │ └── fonts │ │ │ ├── Inter-italic.var.woff2 │ │ │ └── Inter-roman.var.woff2 │ ├── src │ │ ├── app │ │ │ ├── layout.tsx │ │ │ └── page.tsx │ │ ├── components │ │ │ ├── Swap.tsx │ │ │ ├── ThirdwebProvider.tsx │ │ │ └── ui │ │ │ │ ├── AppScreen.tsx │ │ │ │ ├── Button.tsx │ │ │ │ ├── CallToAction.tsx │ │ │ │ ├── CircleBackground.tsx │ │ │ │ ├── Container.tsx │ │ │ │ ├── Fields.tsx │ │ │ │ ├── Footer.tsx │ │ │ │ ├── Header.tsx │ │ │ │ ├── Hero.tsx │ │ │ │ ├── Logo.tsx │ │ │ │ ├── NavLinks.tsx │ │ │ │ ├── PhoneFrame.tsx │ │ │ │ ├── PrimaryFeatures.tsx │ │ │ │ ├── Reviews.tsx │ │ │ │ ├── SecondaryFeatures.tsx │ │ │ │ └── StockLogos.tsx │ │ ├── images │ │ │ ├── logos │ │ │ │ ├── bbc.svg │ │ │ │ ├── cbs.svg │ │ │ │ ├── cnn.svg │ │ │ │ ├── fast-company.svg │ │ │ │ ├── forbes.svg │ │ │ │ ├── huffpost.svg │ │ │ │ ├── techcrunch.svg │ │ │ │ └── wired.svg │ │ │ ├── phone-frame.svg │ │ │ └── qr-code.svg │ │ └── styles │ │ │ └── globals.css │ ├── tailwind.config.js │ ├── tsconfig.json │ └── turbo.json ├── swaps-widget-angular │ ├── README.md │ ├── angular.json │ ├── package.json │ ├── src │ │ ├── app │ │ │ ├── app.component.html │ │ │ ├── app.component.ts │ │ │ └── app.module.ts │ │ ├── favicon.ico │ │ ├── index.html │ │ ├── main.ts │ │ └── polyfills.ts │ ├── tsconfig.app.json │ ├── tsconfig.json │ └── turbo.json ├── swaps-widget-html │ ├── index.html │ └── package.json ├── swaps-widget-nextjs-pages │ ├── .eslintrc.js │ ├── .gitignore │ ├── README.md │ ├── next.config.js │ ├── package.json │ ├── postcss.config.js │ ├── public │ │ ├── favicon.ico │ │ ├── next.svg │ │ └── vercel.svg │ ├── src │ │ ├── pages │ │ │ ├── _app.tsx │ │ │ ├── _document.tsx │ │ │ └── index.tsx │ │ └── styles │ │ │ └── globals.css │ ├── tailwind.config.ts │ └── tsconfig.json ├── swaps-widget-nextjs │ ├── .eslintrc.js │ ├── .gitignore │ ├── README.md │ ├── next.config.mjs │ ├── package.json │ ├── postcss.config.js │ ├── public │ │ ├── favicon.ico │ │ └── vercel.svg │ ├── src │ │ ├── app │ │ │ ├── layout.tsx │ │ │ └── page.tsx │ │ ├── components │ │ │ ├── Button.tsx │ │ │ └── Sidebar.tsx │ │ └── styles │ │ │ └── globals.css │ ├── tailwind.config.js │ └── tsconfig.json ├── swaps-widget-webpack │ ├── .eslintrc.js │ ├── .gitignore │ ├── README.md │ ├── config │ │ ├── env.js │ │ ├── getHttpsConfig.js │ │ ├── modules.js │ │ ├── paths.js │ │ ├── webpack.config.js │ │ ├── webpack │ │ │ └── persistentCache │ │ │ │ └── createEnvironmentHash.js │ │ └── webpackDevServer.config.js │ ├── package.json │ ├── public │ │ ├── favicon.ico │ │ ├── index.html │ │ ├── logo192.png │ │ ├── logo512.png │ │ ├── manifest.json │ │ └── robots.txt │ ├── scripts │ │ ├── build.js │ │ └── start.js │ ├── src │ │ ├── App.tsx │ │ ├── index.tsx │ │ └── react-app-env.d.ts │ ├── tsconfig.json │ └── turbo.json └── withdraw-widget-nextjs │ ├── .eslintrc.js │ ├── .gitignore │ ├── README.md │ ├── next.config.mjs │ ├── package.json │ ├── postcss.config.js │ ├── public │ ├── favicon.ico │ └── vercel.svg │ ├── src │ ├── app │ │ ├── layout.tsx │ │ └── page.tsx │ ├── components │ │ ├── Button.tsx │ │ └── Sidebar.tsx │ └── styles │ │ └── globals.css │ ├── tailwind.config.js │ └── tsconfig.json ├── package.json ├── packages ├── config-eslint │ ├── index.js │ └── package.json └── config-typescript │ ├── base.json │ ├── nextjs.json │ ├── package.json │ └── react-app.json ├── prettier.config.mjs ├── turbo.json └── yarn.lock /.github/dependabot.yml: -------------------------------------------------------------------------------- 1 | # To get started with Dependabot version updates, you'll need to specify which 2 | # package ecosystems to update and where the package manifests are located. 3 | # Please see the documentation for all configuration options: 4 | # https://docs.github.com/github/administering-a-repository/configuration-options-for-dependency-updates 5 | 6 | version: 2 7 | updates: 8 | - package-ecosystem: "npm" # See documentation for possible values 9 | directory: "/" # Location of package manifests 10 | versioning-strategy: increase 11 | schedule: 12 | interval: "daily" 13 | reviewers: 14 | - "lottamus" 15 | allow: 16 | - dependency-name: "@swing.xyz/*" 17 | groups: 18 | swing: 19 | patterns: 20 | - "@swing.xyz/*" 21 | -------------------------------------------------------------------------------- /.github/workflows/cleanup-pr-caches.yaml: -------------------------------------------------------------------------------- 1 | # https://docs.github.com/en/actions/using-workflows/caching-dependencies-to-speed-up-workflows#force-deleting-cache-entries 2 | name: Cleanup caches for closed branches 3 | 4 | on: 5 | pull_request: 6 | types: [closed] 7 | workflow_dispatch: 8 | 9 | jobs: 10 | cleanup: 11 | runs-on: ubuntu-latest 12 | steps: 13 | - name: Check out code 14 | uses: actions/checkout@v3 15 | 16 | - name: 🧹 Cleanup 17 | run: | 18 | gh extension install actions/gh-actions-cache 19 | 20 | REPO=${{ github.repository }} 21 | BRANCH="refs/pull/${{ github.event.pull_request.number }}/merge" 22 | 23 | echo "Fetching list of cache key" 24 | cacheKeysForPR=$(gh actions-cache list -R $REPO -B $BRANCH | cut -f 1 ) 25 | 26 | ## Setting this to not fail the workflow while deleting cache keys. 27 | set +e 28 | echo "Deleting caches..." 29 | for cacheKey in $cacheKeysForPR 30 | do 31 | gh actions-cache delete $cacheKey -R $REPO -B $BRANCH --confirm 32 | done 33 | echo "Done" 34 | env: 35 | GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} 36 | -------------------------------------------------------------------------------- /.github/workflows/test.yaml: -------------------------------------------------------------------------------- 1 | name: Build & Test 2 | 3 | on: 4 | push: 5 | branches: [main] 6 | pull_request: 7 | types: [opened, synchronize, reopened] 8 | 9 | concurrency: 10 | group: ${{ github.head_ref || github.run_id }} 11 | cancel-in-progress: true 12 | 13 | env: 14 | TURBO_TOKEN: ${{ secrets.TURBO_TOKEN }} 15 | TURBO_TEAM: ${{ vars.TURBO_TEAM }} 16 | 17 | jobs: 18 | test: 19 | runs-on: ubuntu-latest 20 | timeout-minutes: 15 21 | steps: 22 | - uses: actions/checkout@v3 23 | 24 | - uses: actions/setup-node@v3 25 | with: 26 | node-version-file: ".nvmrc" 27 | 28 | - name: 📥 Monorepo install 29 | uses: ./.github/actions/yarn-nm-install 30 | 31 | - name: Lint 32 | run: yarn lint -- --quiet 33 | 34 | - name: Build 35 | run: yarn build 36 | env: 37 | NODE_ENV: production 38 | 39 | - name: Unit tests 40 | run: yarn test 41 | env: 42 | NODE_ENV: test 43 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | node_modules 5 | .pnp 6 | .pnp.js 7 | .angular 8 | 9 | # testing 10 | coverage 11 | 12 | # next.js 13 | .next/ 14 | out/ 15 | build 16 | dist 17 | 18 | # misc 19 | .DS_Store 20 | *.pem 21 | 22 | # debug 23 | npm-debug.log* 24 | yarn-debug.log* 25 | yarn-error.log* 26 | .pnpm-debug.log* 27 | 28 | # local env files 29 | .env.local 30 | .env.development.local 31 | .env.test.local 32 | .env.production.local 33 | 34 | # turbo 35 | .turbo 36 | 37 | # https://yarnpkg.com/getting-started/qa#which-files-should-be-gitignored 38 | .pnp.* 39 | .yarn/* 40 | !.yarn/patches 41 | !.yarn/plugins 42 | !.yarn/releases 43 | !.yarn/sdks 44 | !.yarn/versions -------------------------------------------------------------------------------- /.npmrc: -------------------------------------------------------------------------------- 1 | auto-install-peers = true 2 | -------------------------------------------------------------------------------- /.nvmrc: -------------------------------------------------------------------------------- 1 | 20 -------------------------------------------------------------------------------- /.prettierrc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/swing-xyz/examples/c46e4dd4a47f96050e736f64c4a41c45f3e2d45d/.prettierrc -------------------------------------------------------------------------------- /.yarnrc.yml: -------------------------------------------------------------------------------- 1 | compressionLevel: mixed 2 | 3 | enableGlobalCache: false 4 | 5 | nodeLinker: node-modules 6 | 7 | yarnPath: .yarn/releases/yarn-4.1.1.cjs 8 | -------------------------------------------------------------------------------- /apps/directory/.eslintrc.js: -------------------------------------------------------------------------------- 1 | /** @type {import("eslint").Linter.Config} */ 2 | module.exports = { 3 | extends: ["eslint-config-examples/index.js"], 4 | parser: "@typescript-eslint/parser", 5 | parserOptions: { 6 | project: true, 7 | }, 8 | }; 9 | -------------------------------------------------------------------------------- /apps/directory/README.md: -------------------------------------------------------------------------------- 1 |

2 | 3 | 4 | 5 | 6 |

Swing Examples

7 | 8 |

9 | -------------------------------------------------------------------------------- /apps/directory/components.json: -------------------------------------------------------------------------------- 1 | { 2 | "$schema": "https://ui.shadcn.com/schema.json", 3 | "style": "default", 4 | "rsc": true, 5 | "tsx": true, 6 | "tailwind": { 7 | "config": "tailwind.config.js", 8 | "css": "src/styles/globals.css", 9 | "baseColor": "slate", 10 | "cssVariables": true 11 | }, 12 | "aliases": { 13 | "components": "components", 14 | "utils": "lib/utils" 15 | } 16 | } -------------------------------------------------------------------------------- /apps/directory/next-env.d.ts: -------------------------------------------------------------------------------- 1 | /// 2 | /// 3 | 4 | // NOTE: This file should not be edited 5 | // see https://nextjs.org/docs/basic-features/typescript for more information. 6 | -------------------------------------------------------------------------------- /apps/directory/next.config.mjs: -------------------------------------------------------------------------------- 1 | /** @type {import('next').NextConfig} */ 2 | const nextConfig = { 3 | reactStrictMode: true, 4 | 5 | redirects: async () => [ 6 | { 7 | // Examples directory was hosted from https://developers.swing.xyz/examples at one time. 8 | // It has since been moved to https://examples.swing.xyz 9 | source: "/examples", 10 | destination: "/", 11 | permanent: true, 12 | }, 13 | ], 14 | }; 15 | 16 | export default nextConfig; 17 | -------------------------------------------------------------------------------- /apps/directory/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "private": true, 3 | "name": "directory", 4 | "version": "0.0.0", 5 | "scripts": { 6 | "dev": "next dev", 7 | "build": "next build", 8 | "lint": "eslint src", 9 | "start": "next start", 10 | "clean": "rm -rf .next node_modules", 11 | "shadcn": "yarn dlx shadcn-ui@latest" 12 | }, 13 | "dependencies": { 14 | "@radix-ui/react-accordion": "^1.1.2", 15 | "@radix-ui/react-avatar": "^1.0.4", 16 | "@radix-ui/react-checkbox": "^1.0.4", 17 | "@radix-ui/react-dialog": "^1.0.5", 18 | "@radix-ui/react-dropdown-menu": "1.0.0", 19 | "@radix-ui/react-icons": "1.3.0", 20 | "class-variance-authority": "^0.7.0", 21 | "clsx": "^2.1.0", 22 | "fast-glob": "^3.3.2", 23 | "geist": "^1.3.0", 24 | "lucide-react": "^0.364.0", 25 | "next": "^14.1.4", 26 | "next-themes": "^0.3.0", 27 | "react": "^18.2.0", 28 | "react-dom": "^18.2.0", 29 | "tailwind-merge": "^2.2.2", 30 | "tailwindcss-animate": "^1.0.7", 31 | "vaul": "^0.9.0" 32 | }, 33 | "devDependencies": { 34 | "@types/node": "20.12.4", 35 | "@types/react": "18.2.74", 36 | "autoprefixer": "10.4.19", 37 | "eslint": "^8.57.0", 38 | "eslint-config-examples": "workspace:*", 39 | "postcss": "8.4.38", 40 | "tailwindcss": "3.4.3", 41 | "typescript": "^5.4.4", 42 | "typescript-config": "workspace:*" 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /apps/directory/postcss.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | plugins: { 3 | tailwindcss: {}, 4 | autoprefixer: {}, 5 | }, 6 | } 7 | -------------------------------------------------------------------------------- /apps/directory/public/directory-landing.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/swing-xyz/examples/c46e4dd4a47f96050e736f64c4a41c45f3e2d45d/apps/directory/public/directory-landing.png -------------------------------------------------------------------------------- /apps/directory/src/app/layout.tsx: -------------------------------------------------------------------------------- 1 | import { ThemeProvider } from "components/theme-provider"; 2 | import "styles/globals.css"; 3 | 4 | import { GeistSans } from "geist/font/sans"; 5 | import { GeistMono } from "geist/font/mono"; 6 | import { Header } from "components/header"; 7 | import { Footer } from "components/footer"; 8 | 9 | export default function Layout({ children }: { children: React.ReactNode }) { 10 | return ( 11 | 12 | 13 | 14 | 17 | 18 |
19 | 20 |
{children}
21 | 22 |