From 661b0951a237299178bc11f80a75481d50c8886d Mon Sep 17 00:00:00 2001 From: "Luiz Gomes - LuizAsFight.eth" <8636507+LuizAsFight@users.noreply.github.com> Date: Thu, 22 Feb 2024 14:28:24 -0300 Subject: [PATCH] chore: add alert (#211) --- .github/workflows/pr-tests.yml | 50 ++++++++--------- .github/workflows/pr.yaml | 50 ++++++++--------- .../Core/components/DeprecatedAlert.tsx | 56 +++++++++++++++++++ .../src/systems/Core/components/Layout.tsx | 2 + .../app/src/systems/Core/styles/scrollbar.css | 20 +++++++ 5 files changed, 128 insertions(+), 50 deletions(-) create mode 100644 packages/app/src/systems/Core/components/DeprecatedAlert.tsx create mode 100644 packages/app/src/systems/Core/styles/scrollbar.css diff --git a/.github/workflows/pr-tests.yml b/.github/workflows/pr-tests.yml index 6b3a8a5f..0d8759e2 100644 --- a/.github/workflows/pr-tests.yml +++ b/.github/workflows/pr-tests.yml @@ -11,39 +11,39 @@ concurrency: jobs: tests-e2e: - name: E2E Tests + name: E2E Tests (Disabled) runs-on: ubuntu-latest steps: - name: Checkout uses: actions/checkout@v3 - - name: Setup Node - uses: FuelLabs/github-actions/setups/node@master + # - name: Setup Node + # uses: FuelLabs/github-actions/setups/node@master - - name: Setup Docker - uses: FuelLabs/github-actions/setups/docker@master - with: - username: ${{ github.repository_owner }} - password: ${{ secrets.GITHUB_TOKEN }} + # - name: Setup Docker + # uses: FuelLabs/github-actions/setups/docker@master + # with: + # username: ${{ github.repository_owner }} + # password: ${{ secrets.GITHUB_TOKEN }} - - name: Start Test Node - run: pnpm node:start + # - name: Start Test Node + # run: pnpm node:start - # E2E tests running with Playwright - - name: Install Playwright Browsers - run: pnpm exec playwright install --with-deps chromium + # # E2E tests running with Playwright + # - name: Install Playwright Browsers + # run: pnpm exec playwright install --with-deps chromium - - name: Run E2E Tests - run: xvfb-run --auto-servernum -- pnpm test:all - env: - NODE_ENV: test + # - name: Run E2E Tests + # run: xvfb-run --auto-servernum -- pnpm test:all + # env: + # NODE_ENV: test - - uses: actions/upload-artifact@v2 - if: always() - with: - name: playwright-report - path: packages/app/playwright-report/ - retention-days: 30 + # - uses: actions/upload-artifact@v2 + # if: always() + # with: + # name: playwright-report + # path: packages/app/playwright-report/ + # retention-days: 30 - - name: Stop Test Node - run: pnpm node:stop + # - name: Stop Test Node + # run: pnpm node:stop diff --git a/.github/workflows/pr.yaml b/.github/workflows/pr.yaml index fc177224..7f30e4d3 100644 --- a/.github/workflows/pr.yaml +++ b/.github/workflows/pr.yaml @@ -17,34 +17,34 @@ jobs: env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - audit: - name: Audit - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - - uses: FuelLabs/github-actions/setups/node@master - env: - PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1 - - run: pnpm audit --prod + # audit: + # name: Audit + # runs-on: ubuntu-latest + # steps: + # - uses: actions/checkout@v3 + # - uses: FuelLabs/github-actions/setups/node@master + # env: + # PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1 + # - run: pnpm audit --prod - lint: - name: Lint - runs-on: ubuntu-latest - permissions: - checks: write - pull-requests: write - contents: write - steps: - - name: Checkout - uses: actions/checkout@v3 + # lint: + # name: Lint + # runs-on: ubuntu-latest + # permissions: + # checks: write + # pull-requests: write + # contents: write + # steps: + # - name: Checkout + # uses: actions/checkout@v3 - - name: Setup Node - uses: FuelLabs/github-actions/setups/node@master + # - name: Setup Node + # uses: FuelLabs/github-actions/setups/node@master - - name: Run lint - run: | - pnpm ts:check - pnpm lint + # - name: Run lint + # run: | + # pnpm ts:check + # pnpm lint build: name: Build diff --git a/packages/app/src/systems/Core/components/DeprecatedAlert.tsx b/packages/app/src/systems/Core/components/DeprecatedAlert.tsx new file mode 100644 index 00000000..8a501ac1 --- /dev/null +++ b/packages/app/src/systems/Core/components/DeprecatedAlert.tsx @@ -0,0 +1,56 @@ +import { Box, Flex, Icon, Link, Text } from '@fuel-ui/react'; + +export function DeprecatedAlert() { + const colors = { + backgroundColor: '#fffab8', + color: '#a06e00', + }; + + return ( + <> + + + + + + + + This app is compatible with beta-4 network and Fuel Wallet version + 0.13.2. For newer versions access:   + + https://app.fuel.network + +
+ This app will be shutdown on March 1st. +
+
+
+
+ + ); +} diff --git a/packages/app/src/systems/Core/components/Layout.tsx b/packages/app/src/systems/Core/components/Layout.tsx index cfdeda76..b69e55a0 100644 --- a/packages/app/src/systems/Core/components/Layout.tsx +++ b/packages/app/src/systems/Core/components/Layout.tsx @@ -8,6 +8,7 @@ import { OverlayDialog } from '~/systems/Overlay'; import { coreStyles } from '../styles'; +import { DeprecatedAlert } from './DeprecatedAlert'; import { Header } from './Header'; type ContentProps = { @@ -57,6 +58,7 @@ export const Layout: LayoutComponent = ({ title, children }: LayoutProps) => {
+ {children} diff --git a/packages/app/src/systems/Core/styles/scrollbar.css b/packages/app/src/systems/Core/styles/scrollbar.css new file mode 100644 index 00000000..ad5beb20 --- /dev/null +++ b/packages/app/src/systems/Core/styles/scrollbar.css @@ -0,0 +1,20 @@ +@tailwind base; +@tailwind components; +@tailwind utilities; + +@layer base { + .custom-scrollbar { + &::-webkit-scrollbar { + @apply w-[14px] bg-transparent; + } + &::-webkit-scrollbar-track { + @apply bg-transparent; + } + &::-webkit-scrollbar-thumb { + @apply bg-gray-8 opacity-50 border-4 border-transparent rounded-3xl bg-clip-content-box; + } + &::-webkit-scrollbar-thumb:hover { + @apply bg-gray-10; + } + } +}