From 63b5a15d6d5419680aadc33fdc7f179b6898a4db Mon Sep 17 00:00:00 2001 From: Radu Mojic Date: Mon, 30 Oct 2023 17:55:26 +0200 Subject: [PATCH 1/2] persistent tooltips on denominate full sum ( keep tooltip visible while hovering on hooltip ) --- src/components/Denominate/Denominate.tsx | 48 +++++++++++++++++------- 1 file changed, 35 insertions(+), 13 deletions(-) diff --git a/src/components/Denominate/Denominate.tsx b/src/components/Denominate/Denominate.tsx index 3b32d9c00..e9a222e02 100644 --- a/src/components/Denominate/Denominate.tsx +++ b/src/components/Denominate/Denominate.tsx @@ -1,3 +1,4 @@ +import { useState, useRef } from 'react'; import { stringIsInteger } from '@multiversx/sdk-dapp/utils/validation/stringIsInteger'; import { OverlayTrigger, Tooltip } from 'react-bootstrap'; import { useSelector } from 'react-redux'; @@ -24,19 +25,40 @@ const CompleteValueTooltip = ({ }: { completeValue: string; children: React.ReactNode; -}) => ( - ( - - {completeValue} - - )} - > - {children} - -); +}) => { + const [show, setShow] = useState(false); + const handleOnMouseEnter = () => { + setShow(true); + }; + const handleOnMouseLeave = () => { + setShow(false); + }; + const ref = useRef(null); + + return ( + + {completeValue} + + } + > + + {children} + + + ); +}; const denominateInvalid = (props: DenominateType) => { return ( From 4427c65b75954199ffe235c581f153a7c3d8d643 Mon Sep 17 00:00:00 2001 From: Radu Mojic Date: Wed, 1 Nov 2023 09:02:45 +0200 Subject: [PATCH 2/2] added devnet-old config --- .github/workflows/deploy-devnet-old.yml | 50 +++++++++++++++++++++++++ .gitignore | 1 + package.json | 5 +++ 3 files changed, 56 insertions(+) create mode 100644 .github/workflows/deploy-devnet-old.yml diff --git a/.github/workflows/deploy-devnet-old.yml b/.github/workflows/deploy-devnet-old.yml new file mode 100644 index 000000000..6d6340778 --- /dev/null +++ b/.github/workflows/deploy-devnet-old.yml @@ -0,0 +1,50 @@ +name: deploy-devnet-old + +on: + push: + branches: [main] + repository_dispatch: + types: deploy-devnet-old + workflow_dispatch: + +jobs: + build: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v2 + with: + ref: main + - name: Use Node.js + uses: actions/setup-node@v1 + with: + node-version: '18.x' + - name: Setup yarn + run: npm install -g yarn + - run: npm config set '//npm.fontawesome.com/:_authToken' "${{ secrets.FONTAWESOME_NPM_AUTH_TOKEN }}" + - run: yarn install + - run: yarn run prepare-pro-icons + - run: yarn run build-devnet-old + env: + CI: false + VITE_APP_MARKERS_API_URL: ${{ secrets.MARKERS_API_URL }} + VITE_APP_VERSION_URL: ${{ secrets.APP_VERSION_URL }} + - name: Configure AWS Credentials + uses: aws-actions/configure-aws-credentials@v1 + with: + aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }} + aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }} + aws-region: 'us-east-1' + - name: Deploy to S3 bucket + run: aws s3 sync ./build/ s3://${{ secrets.AWS_S3_BUCKET_DEVNET_OLD }} --delete + - name: No-cache index.html + run: aws s3 cp s3://${{ secrets.AWS_S3_BUCKET_DEVNET_OLD }}/index.html s3://${{ secrets.AWS_S3_BUCKET_DEVNET_OLD }}/index.html --metadata-directive REPLACE --cache-control max-age=0,no-cache,no-store,must-revalidate --content-type text/html --acl public-read + - name: Slack Notification + uses: rtCamp/action-slack-notify@master + env: + SLACK_ICON_EMOJI: ':globe_with_meridians:' + SLACK_USERNAME: ${{ secrets.AWS_S3_BUCKET_DEVNET_OLD }} + SLACK_MESSAGE: ${{ secrets.AWS_S3_BUCKET_DEVNET_OLD }} + SLACK_FOOTER: '' + MSG_MINIMAL: true + SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }} diff --git a/.gitignore b/.gitignore index 33e726d98..960b7a054 100644 --- a/.gitignore +++ b/.gitignore @@ -43,6 +43,7 @@ dist-ssr /src/config/* !/src/config.devnet.ts !/src/config.devnet2.ts +!/src/config.devnet-old.ts !/src/config.testnet.ts !/src/config.mainnet.ts !/src/config.multiple.ts diff --git a/package.json b/package.json index 1edf3178c..8854664b7 100644 --- a/package.json +++ b/package.json @@ -51,10 +51,12 @@ "start": "cross-env VITE_APP_CACHE_BUST=$(git rev-parse --short HEAD || echo 'local') vite", "start-devnet": "yarn run copy-devnet-config & cross-env VITE_APP_SHARE_PREFIX=devnet- yarn run start", "start-devnet2": "yarn run copy-devnet2-config & cross-env VITE_APP_SHARE_PREFIX=devnet2- yarn run start", + "start-devnet-old": "yarn run copy-devnet-old-config & cross-env VITE_APP_SHARE_PREFIX=devnet-old- yarn run start", "start-mainnet": "yarn run copy-mainnet-config & yarn run start", "start-testnet": "yarn run copy-testnet-config & cross-env VITE_APP_SHARE_PREFIX=testnet- yarn run start", "build-devnet": "yarn run copy-devnet-config & cross-env VITE_APP_SHARE_PREFIX=devnet- VITE_APP_GA_ID=G-QE38EW59B8 yarn run build", "build-devnet2": "yarn run copy-devnet2-config & cross-env VITE_APP_SHARE_PREFIX=devnet2- VITE_APP_GA_ID=G-QE38EW59B8 yarn run build", + "build-devnet-old": "yarn run copy-devnet-old-config & cross-env VITE_APP_SHARE_PREFIX=devnet-old- VITE_APP_GA_ID=G-QE38EW59B8 yarn run build", "build-mainnet": "yarn run copy-mainnet-config & cross-env VITE_APP_SHARE_PREFIX= VITE_APP_GA_ID=G-EFN7QYSMQS yarn run build", "build-testnet": "yarn run copy-testnet-config & cross-env VITE_APP_SHARE_PREFIX=testnet- VITE_APP_GA_ID=G-EFN7QYSMQS yarn run build", "build-staging": "yarn run copy-mainnet-config & cross-env VITE_APP_SHARE_PREFIX=staging- VITE_APP_GA_ID=G-EFN7QYSMQS VITE_APP_IS_STAGING=true yarn run build", @@ -65,18 +67,21 @@ "preview": "vite preview", "copy-devnet-config": "run-script-os", "copy-devnet2-config": "run-script-os", + "copy-devnet-old-config": "run-script-os", "copy-mainnet-config": "run-script-os", "copy-testnet-config": "run-script-os", "copy-multiple-config": "run-script-os", "copy-base-interceptor": "run-script-os", "copy-devnet-config:nix": "cp ./src/config/config.devnet.ts ./src/config/index.ts", "copy-devnet2-config:nix": "cp ./src/config/config.devnet2.ts ./src/config/index.ts", + "copy-devnet-old-config:nix": "cp ./src/config/config.devnet-old.ts ./src/config/index.ts", "copy-mainnet-config:nix": "cp ./src/config/config.mainnet.ts ./src/config/index.ts", "copy-testnet-config:nix": "cp ./src/config/config.testnet.ts ./src/config/index.ts", "copy-multiple-config:nix": "cp ./src/config/config.multiple.ts ./src/config/index.ts", "copy-base-interceptor:nix": "cp ./src/interceptors/Interceptor.tsx ./src/interceptors/index.tsx", "copy-devnet-config:windows": "copy .\\src\\config\\config.devnet.ts .\\src\\config\\index.ts", "copy-devnet2-config:windows": "copy .\\src\\config\\config.devnet2.ts .\\src\\config\\index.ts", + "copy-devnet-old-config:windows": "copy .\\src\\config\\config.devnet-old.ts .\\src\\config\\index.ts", "copy-mainnet-config:windows": "copy .\\src\\config\\config.mainnet.ts .\\src\\config\\index.ts", "copy-testnet-config:windows": "copy .\\src\\config\\config.testnet.ts .\\src\\config\\index.ts", "copy-multiple-config:windows": "copy .\\src\\config\\config.multiple.ts .\\src\\config\\index.ts",