From 378218e89a40a19f9d886fda932fcec92d6b7095 Mon Sep 17 00:00:00 2001 From: bao Date: Fri, 9 Aug 2024 09:40:31 +0700 Subject: [PATCH 01/12] Prepare for release --- package.json | 4 ++-- yarn.lock | 8 ++++---- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/package.json b/package.json index da9624e..5bb6e12 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "aesirx-analytics", - "version": "2.2.15", + "version": "2.2.16", "license": "GPL-3.0-only", "author": "AesirX", "repository": "https://gitlab.redweb.dk/aesirx/analytics", @@ -14,7 +14,7 @@ "@concordium/web-sdk": "^7.0.4-rc.3", "@web3modal/ethereum": "^2.7.0", "@web3modal/react": "^2.7.0", - "aesirx-sso": "^1.4.13", + "aesirx-sso": "^1.4.14", "axios": "^1.6.0", "bootstrap": "^5.3.2", "bowser": "^2.11.0", diff --git a/yarn.lock b/yarn.lock index 86b2430..b64846c 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3592,10 +3592,10 @@ aesirx-lib@^2.0.11: query-string "7" react-secure-storage "^1.3.2" -aesirx-sso@^1.4.13: - version "1.4.13" - resolved "https://registry.yarnpkg.com/aesirx-sso/-/aesirx-sso-1.4.13.tgz#63a3dfcf55b6a837b4e71c567d45758da486d5fb" - integrity sha512-CEKAUyKJfFyOi+AN3mLR/0YbFNVM/GmQKHoH74IP+FV5gA2A5/bpF7vm1OotTu5DSZehm/Vocqx020rBOIe9zA== +aesirx-sso@^1.4.14: + version "1.4.14" + resolved "https://registry.yarnpkg.com/aesirx-sso/-/aesirx-sso-1.4.14.tgz#da2aabb5bfa24ea32290cc41dff69812417e571c" + integrity sha512-Ff0eeCBx6Pk3dd4Op0s2VwlILxYKkf3XE2LJe55diQGlo+26R1vd4pvvJkNDEOJhgiOTdTitzuMXeWx8+EsFnA== dependencies: "@concordium/browser-wallet-api-helpers" "^3.0.0" "@concordium/react-components" "^0.4.0-rc.7" From d45150c5f6a433a9bfb71cf4a3b0f4758cac91f4 Mon Sep 17 00:00:00 2001 From: Viet Date: Mon, 12 Aug 2024 14:54:03 +0700 Subject: [PATCH 02/12] Update translate text --- src/translations/dk/common.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/translations/dk/common.json b/src/translations/dk/common.json index 10038fb..4039c43 100644 --- a/src/translations/dk/common.json +++ b/src/translations/dk/common.json @@ -103,7 +103,7 @@ "txt_more_info_at": "Mere info på https://shield. aesirx.io.", "txt_select_your_preferred": "Vælg din foretrukne mulighed for decentraliseret samtykke:", "txt_decentralized_wallet": "Decentraliseret samtykke", - "txt_decentralized_wallet_will_be_loaded": "Se cargará el consentimiento descentralizado", + "txt_decentralized_wallet_will_be_loaded": "Decentraliseret samtykke vil blive indlæst", "txt_both_first_party_third_party": "Både førsteparts- og tredjepartssporingsdata vil blive aktiveret.", "txt_all_consented_data_will_be_collected": "Alle samtykkede data vil blive indsamlet.", "txt_users_can_revoke": "Brugere kan til enhver tid tilbagekalde samtykke på stedet.", From 5b24f4f5d721fb03f02fdd3a55f27fbf140e3eba Mon Sep 17 00:00:00 2001 From: bao Date: Mon, 12 Aug 2024 15:22:20 +0700 Subject: [PATCH 03/12] prepare for release --- package.json | 4 ++-- yarn.lock | 18 +++++++++--------- 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/package.json b/package.json index 5bb6e12..7fb8b7c 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "aesirx-analytics", - "version": "2.2.16", + "version": "2.2.17", "license": "GPL-3.0-only", "author": "AesirX", "repository": "https://gitlab.redweb.dk/aesirx/analytics", @@ -14,7 +14,7 @@ "@concordium/web-sdk": "^7.0.4-rc.3", "@web3modal/ethereum": "^2.7.0", "@web3modal/react": "^2.7.0", - "aesirx-sso": "^1.4.14", + "aesirx-sso": "^1.4.15", "axios": "^1.6.0", "bootstrap": "^5.3.2", "bowser": "^2.11.0", diff --git a/yarn.lock b/yarn.lock index b64846c..3d77b06 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3578,10 +3578,10 @@ aes-js@^3.1.2: resolved "https://registry.yarnpkg.com/aes-js/-/aes-js-3.1.2.tgz#db9aabde85d5caabbfc0d4f2a4446960f627146a" integrity sha512-e5pEa2kBnBOgR4Y/p20pskXI74UEz7de8ZGVo58asOtvSVG5YAbJeELPZxOmt+Bnz3rX753YKhfIn4X4l1PPRQ== -aesirx-lib@^2.0.11: - version "2.0.11" - resolved "https://registry.yarnpkg.com/aesirx-lib/-/aesirx-lib-2.0.11.tgz#242e737510569ba23e2f93685a88af551c0ba55e" - integrity sha512-HLYRiZt+vxffccJZXKyfXSliFr4W7XB0KquU6rplJA2DSVXTcOF6DHACI1HWg7kByNS65heb4+eKDPMhMXo6nw== +aesirx-lib@^2.0.12: + version "2.0.12" + resolved "https://registry.yarnpkg.com/aesirx-lib/-/aesirx-lib-2.0.12.tgz#0a57dc2070fa2534ac2635ee142a05c5c4be3cb6" + integrity sha512-SU+1wwmK0wCE/zwXYEQuZrC7uinoXe6iGcuovjbeHQW8HGFLXfOq4lTauC3oxrV1tVrPBKCFxF4aNmU3HHrcZQ== dependencies: axios "^1.6.0" axios-auth-refresh "^3.3.6" @@ -3592,10 +3592,10 @@ aesirx-lib@^2.0.11: query-string "7" react-secure-storage "^1.3.2" -aesirx-sso@^1.4.14: - version "1.4.14" - resolved "https://registry.yarnpkg.com/aesirx-sso/-/aesirx-sso-1.4.14.tgz#da2aabb5bfa24ea32290cc41dff69812417e571c" - integrity sha512-Ff0eeCBx6Pk3dd4Op0s2VwlILxYKkf3XE2LJe55diQGlo+26R1vd4pvvJkNDEOJhgiOTdTitzuMXeWx8+EsFnA== +aesirx-sso@^1.4.15: + version "1.4.15" + resolved "https://registry.yarnpkg.com/aesirx-sso/-/aesirx-sso-1.4.15.tgz#fb9f1b3629dad8a01ffa63430b0480376da58032" + integrity sha512-2HmnUAmStuiFBiUxLjNcdC6L4XYXOvGmpuLWW4EGaRk2ws3yBx/k1wYqqYRPgot0HaXS62MrmgD3Ly31obbBkg== dependencies: "@concordium/browser-wallet-api-helpers" "^3.0.0" "@concordium/react-components" "^0.4.0-rc.7" @@ -3607,7 +3607,7 @@ aesirx-sso@^1.4.14: "@wagmi/core" "^1.3.8" "@web3modal/ethereum" "^2.7.0" "@web3modal/react" "^2.7.0" - aesirx-lib "^2.0.11" + aesirx-lib "^2.0.12" axios "^1.6.0" bootstrap "^5.3.3" bowser "^2.11.0" From a40b72ed40370eacfb44f603f2023c9607442b3e Mon Sep 17 00:00:00 2001 From: Viet Date: Mon, 12 Aug 2024 16:39:50 +0700 Subject: [PATCH 04/12] Fix conflict css --- src/styles/style.scss | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/styles/style.scss b/src/styles/style.scss index 7719268..ecbb138 100644 --- a/src/styles/style.scss +++ b/src/styles/style.scss @@ -537,4 +537,14 @@ body { } } } +.aesirxsso .fade, +.aesirxconsent .fade, +.aesirxsso.fade, +.aesirxconsent.fade { + opacity: 1; +} +.aesirxsso.modal.fade .modal-dialog, +.aesirxconsent.modal.fade .modal-dialog { + transform: none; +} @import './color-mode.scss'; From 7db84ebf15e433e3919d4812d262631c83c87057 Mon Sep 17 00:00:00 2001 From: Viet Date: Mon, 12 Aug 2024 16:50:25 +0700 Subject: [PATCH 05/12] Update title --- src/Components/Terms.tsx | 6 +++--- src/translations/dk/common.json | 4 +++- src/translations/en/common.json | 4 +++- src/translations/es/common.json | 4 +++- src/translations/fr/common.json | 4 +++- src/translations/hr/common.json | 4 +++- src/translations/th/common.json | 4 +++- src/translations/ua/common.json | 4 +++- src/translations/vi/common.json | 4 +++- 9 files changed, 27 insertions(+), 11 deletions(-) diff --git a/src/Components/Terms.tsx b/src/Components/Terms.tsx index c5541fa..78aa1c2 100644 --- a/src/Components/Terms.tsx +++ b/src/Components/Terms.tsx @@ -139,7 +139,7 @@ const TermsComponent = ({ > {isRejectedLayout ? ( @@ -240,7 +240,7 @@ const TermsComponent = ({ )} - +

{t('txt_manage_your_consent')} @@ -350,7 +350,7 @@ const TermsComponent = ({

- +

{t('txt_our_commitment_in_action')} diff --git a/src/translations/dk/common.json b/src/translations/dk/common.json index 4039c43..4ca3554 100644 --- a/src/translations/dk/common.json +++ b/src/translations/dk/common.json @@ -125,5 +125,7 @@ "txt_payment_1": "Denne tjeneste vil sætte cookies og indsamle data for at understøtte betalingsgateway-behandling.", "txt_payment_2": "For at fuldføre dit køb vil ordre- & brugerdata blive delt med Sellix & Stripe som vores betalingsbehandlere. (*Google reCaptcha bruges af betalingsbehandlerne af sikkerhedsmæssige årsager.)", "txt_payment_3": "Hvis du ikke giver samtykke til denne dataudveksling, vil du ikke kunne fuldføre betalingen.", - "txt_payment_4": "For mere information, henvises til vores privatlivspolitik.." + "txt_payment_4": "For mere information, henvises til vores privatlivspolitik..", + "txt_consent_nanagement": "Samtykkestyring", + "txt_details": "Detaljer" } diff --git a/src/translations/en/common.json b/src/translations/en/common.json index 2c057ad..ac23fcf 100644 --- a/src/translations/en/common.json +++ b/src/translations/en/common.json @@ -125,5 +125,7 @@ "txt_payment_1": "This service will set cookies & collect data to support payment gateway processing.", "txt_payment_2": "To complete your purchase, order & user data will be shared with Sellix & Stripe as our payment processors. (*Google reCaptcha is used by the payment processors for security purposes.)", "txt_payment_3": "If you do not consent to this data sharing, you will not be able to complete the payment.", - "txt_payment_4": "For more information, please refer to our privacy policy." + "txt_payment_4": "For more information, please refer to our privacy policy.", + "txt_consent_nanagement": "Consent Management", + "txt_details": "Details" } diff --git a/src/translations/es/common.json b/src/translations/es/common.json index f1e7825..085285b 100644 --- a/src/translations/es/common.json +++ b/src/translations/es/common.json @@ -125,5 +125,7 @@ "txt_payment_1": "Este servicio establecerá cookies y recopilará datos para respaldar el procesamiento de la pasarela de pagos.", "txt_payment_2": "Para completar su compra, los datos del pedido & del usuario se compartirán con Sellix & Stripe como nuestros procesadores de pagos. (*Google reCaptcha es utilizado por los procesadores de pagos por razones de seguridad.)", "txt_payment_3": "Si no consiente compartir estos datos, no podrá completar el pago.", - "txt_payment_4": "Para más información, por favor consulte nuestra política de privacidad." + "txt_payment_4": "Para más información, por favor consulte nuestra política de privacidad.", + "txt_consent_nanagement": "Gestión del consentimiento", + "txt_details": "Detalles" } diff --git a/src/translations/fr/common.json b/src/translations/fr/common.json index b0a1b56..328b285 100644 --- a/src/translations/fr/common.json +++ b/src/translations/fr/common.json @@ -125,5 +125,7 @@ "txt_payment_1": "Ce service installera des cookies et collectera des données pour prendre en charge le traitement de la passerelle de paiement.", "txt_payment_2": "Pour finaliser votre achat, les données de commande & d'utilisateur seront partagées avec Sellix & Stripe nos processeurs de paiement. (*Google reCaptcha est utilisé par les processeurs de paiement pour des raisons de sécurité.)", "txt_payment_3": "Si vous ne consentez pas à ce partage de données, vous ne pourrez pas finaliser le paiement.", - "txt_payment_4": "Pour plus d'informations, veuillez consulter notre politique de confidentialité." + "txt_payment_4": "Pour plus d'informations, veuillez consulter notre politique de confidentialité.", + "txt_consent_nanagement": "Gestion du consentement", + "txt_details": "Détails" } diff --git a/src/translations/hr/common.json b/src/translations/hr/common.json index 3c80355..7131d43 100644 --- a/src/translations/hr/common.json +++ b/src/translations/hr/common.json @@ -125,5 +125,7 @@ "txt_payment_1": "Ova usluga postavit će kolačiće i prikupljati podatke za podršku obradi platnog prolaza.", "txt_payment_2": "Za dovršetak kupnje, podaci o narudžbi & korisniku će biti podijeljeni s Sellix & Stripe kao našim procesorima plaćanja. (*Google reCaptcha koristi se od strane procesora plaćanja iz sigurnosnih razloga.)", "txt_payment_3": "Ako ne pristanete na ovo dijeljenje podataka, nećete moći dovršiti plaćanje.", - "txt_payment_4": "Za više informacija, molimo pogledajte našu politiku privatnosti." + "txt_payment_4": "Za više informacija, molimo pogledajte našu politiku privatnosti.", + "txt_consent_nanagement": "Upravljanje pristankom", + "txt_details": "Detalji" } diff --git a/src/translations/th/common.json b/src/translations/th/common.json index 86dafbf..85b1577 100644 --- a/src/translations/th/common.json +++ b/src/translations/th/common.json @@ -125,5 +125,7 @@ "txt_payment_1": "บริการนี้จะตั้งค่าคุกกี้และรวบรวมข้อมูลเพื่อรองรับการประมวลผลเกตเวย์การชำระเงิน.", "txt_payment_2": "เพื่อทำการซื้อให้เสร็จสมบูรณ์ ข้อมูลการสั่งซื้อและข้อมูลผู้ใช้ จะถูกแบ่งปันกับ Sellix & Stripe ในฐานะ ตัวประมวลผลการชำระเงิน ของเรา (*Google reCaptcha ถูกใช้โดย ตัวประมวลผลการชำระเงิน เพื่อวัตถุประสงค์ด้าน ความปลอดภัย)", "txt_payment_3": "หากคุณไม่ยินยอมให้แบ่งปันข้อมูลนี้ คุณจะไม่สามารถทำการชำระเงินให้เสร็จสมบูรณ์ได้", - "txt_payment_4": "สำหรับข้อมูลเพิ่มเติม โปรดดู นโยบายความเป็นส่วนตัว ของเรา" + "txt_payment_4": "สำหรับข้อมูลเพิ่มเติม โปรดดู นโยบายความเป็นส่วนตัว ของเรา", + "txt_consent_nanagement": "การจัดการความยินยอม", + "txt_details": "รายละเอียด" } diff --git a/src/translations/ua/common.json b/src/translations/ua/common.json index 5fb0ba9..bef8e58 100644 --- a/src/translations/ua/common.json +++ b/src/translations/ua/common.json @@ -125,5 +125,7 @@ "txt_payment_1": "Ця послуга буде встановлювати файли cookie та збирати дані для підтримки обробки платіжного шлюзу.", "txt_payment_2": "To complete your purchase, order & user data will be shared with Sellix & Stripe as our payment processors. (*Google reCaptcha is used by the payment processors for security purposes.)", "txt_payment_3": "Якщо ви не погоджуєтеся на передачу цих даних, ви не зможете завершити платіж.", - "txt_payment_4": "Для отримання додаткової інформації, будь ласка, ознайомтеся з нашою політикою конфіденційності." + "txt_payment_4": "Для отримання додаткової інформації, будь ласка, ознайомтеся з нашою політикою конфіденційності.", + "txt_consent_nanagement": "Керування згодою", + "txt_details": "Деталі" } diff --git a/src/translations/vi/common.json b/src/translations/vi/common.json index ed0c99f..8456adf 100644 --- a/src/translations/vi/common.json +++ b/src/translations/vi/common.json @@ -125,5 +125,7 @@ "txt_payment_1": "Dịch vụ này sẽ cài đặt cookie và thu thập dữ liệu để hỗ trợ xử lý cổng thanh toán.", "txt_payment_2": "Để hoàn tất việc mua hàng, dữ liệu đơn hàng & người dùng sẽ được chia sẻ với Sellix & Stripe là những bộ xử lý thanh toán của chúng tôi. (*Google reCaptcha được các bộ xử lý thanh toán sử dụng cho mục đích security bảo mật.)", "txt_payment_3": "Nếu bạn không đồng ý chia sẻ dữ liệu này, bạn sẽ không thể hoàn tất thanh toán.", - "txt_payment_4": "Để biết thêm thông tin, vui lòng tham khảo chính sách bảo mật của chúng tôi." + "txt_payment_4": "Để biết thêm thông tin, vui lòng tham khảo chính sách bảo mật của chúng tôi.", + "txt_consent_nanagement": "Quản lý sự đồng ý", + "txt_details": "Chi tiết" } From 62afa3b175169dc74b5e8ab8f55e2f9e7064435f Mon Sep 17 00:00:00 2001 From: Viet Date: Tue, 13 Aug 2024 15:35:34 +0700 Subject: [PATCH 06/12] Update css --- src/styles/style.scss | 23 ++++++++++++++--------- 1 file changed, 14 insertions(+), 9 deletions(-) diff --git a/src/styles/style.scss b/src/styles/style.scss index ecbb138..e4e5886 100644 --- a/src/styles/style.scss +++ b/src/styles/style.scss @@ -537,14 +537,19 @@ body { } } } -.aesirxsso .fade, -.aesirxconsent .fade, -.aesirxsso.fade, -.aesirxconsent.fade { - opacity: 1; -} -.aesirxsso.modal.fade .modal-dialog, -.aesirxconsent.modal.fade .modal-dialog { - transform: none; + +.aesirxsso, +.aesirxconsent { + .fade, + &.fade { + opacity: 1; + } + &.modal.fade .modal-dialog { + transform: none; + } + .btn { + text-transform: unset; + white-space: normal; + } } @import './color-mode.scss'; From 84886ef88b9ef54eb2f05ac3785470065e0eecbd Mon Sep 17 00:00:00 2001 From: Viet Date: Wed, 14 Aug 2024 15:08:31 +0700 Subject: [PATCH 07/12] Update --- README.md | 9 +++------ src/Components/Consent.tsx | 2 +- src/Components/ConsentCustom.tsx | 12 ++++++------ src/Components/Ethereum/index.tsx | 4 ++-- src/Hooks/useConsentStatus.ts | 4 ++-- src/utils/consent.ts | 2 +- 6 files changed, 15 insertions(+), 18 deletions(-) diff --git a/README.md b/README.md index 00da483..b3d0a4a 100644 --- a/README.md +++ b/README.md @@ -286,13 +286,10 @@ Please follow below CSS example: ## Choose template for Consent modal There is 5 template for Consent modal -1. original -2. default (recommend) -3. simple-consent-mode - 1. Support Basic Consent Mode v2 -4. advance-consent-mode +1. default (recommend) 1. Support Advance Consent Mode v2 -5. simple-web-2 +2. simple-consent-mode + 1. Support Basic Consent Mode v2 #### Usage in SSR site: ``` diff --git a/src/Components/Consent.tsx b/src/Components/Consent.tsx index 5e6cc26..9c52a13 100644 --- a/src/Components/Consent.tsx +++ b/src/Components/Consent.tsx @@ -632,7 +632,7 @@ const ConsentComponentApp = (props: WalletConnectionPropsExtends) => { if (gtmId) { dataLayer.push({ 'gtm.start': new Date().getTime(), event: 'gtm.js' }); } - if (layout === 'advance-consent-mode') { + if (layout !== 'simple-consent-mode') { gtagId && loadGtagScript(gtagId); gtmId && loadGtmScript(gtmId); gtag('set', 'url_passthrough', true); diff --git a/src/Components/ConsentCustom.tsx b/src/Components/ConsentCustom.tsx index 9a1d1db..2b9a2ac 100644 --- a/src/Components/ConsentCustom.tsx +++ b/src/Components/ConsentCustom.tsx @@ -195,12 +195,12 @@ const ConsentComponentCustomApp = (props: any) => { const revoke = sessionStorage.getItem('aesirx-analytics-revoke'); // Metamask const { address, connector } = - (layout === 'simple-consent-mode' || layout === 'simple-web-2' || level === 1) && + (layout === 'simple-consent-mode' || level === 1) && (!revoke || revoke === '0' || revoke === '1') ? { address: '', connector: '' } : useAccount(); const { signMessage }: any = - (layout === 'simple-consent-mode' || layout === 'simple-web-2' || level === 1) && + (layout === 'simple-consent-mode' || level === 1) && (!revoke || revoke === '0' || revoke === '1') ? { signMessage: {} } : useSignMessage({ @@ -769,7 +769,7 @@ const ConsentComponentCustomApp = (props: any) => { if (gtmId) { dataLayer.push({ 'gtm.start': new Date().getTime(), event: 'gtm.js' }); } - if (layout === 'advance-consent-mode') { + if (layout !== 'simple-consent-mode') { gtagId && loadGtagScript(gtagId); gtmId && loadGtmScript(gtmId); gtag('set', 'url_passthrough', true); @@ -1163,7 +1163,7 @@ const ConsentComponentCustomApp = (props: any) => { level === 4 && !account && !address ? '' : 'd-none' }`} > - {layout !== 'simple-consent-mode' && layout !== 'simple-web-2' && ( + {layout !== 'simple-consent-mode' && ( @@ -1262,7 +1262,7 @@ const ConsentComponentCustomApp = (props: any) => { {t('txt_yes_i_consent')} )} - {layout === 'simple-consent-mode' || layout === 'simple-web-2' ? ( + {layout === 'simple-consent-mode' ? ( <> ) : ( <> @@ -1341,7 +1341,7 @@ const ConsentComponentCustomApp = (props: any) => { {t('txt_yes_i_consent')} )} - {layout === 'simple-consent-mode' || layout === 'simple-web-2' ? ( + {layout === 'simple-consent-mode' ? ( <> ) : ( <> diff --git a/src/Components/Ethereum/index.tsx b/src/Components/Ethereum/index.tsx index 878ee2c..620f8a4 100644 --- a/src/Components/Ethereum/index.tsx +++ b/src/Components/Ethereum/index.tsx @@ -119,7 +119,7 @@ const SSOEthereumProvider = ({ children, layout, level }: any) => { ]); const revoke = sessionStorage.getItem('aesirx-analytics-revoke'); const wagmiConfig: any = - (layout === 'simple-consent-mode' || layout === 'simple-web-2' || level === 1) && + (layout === 'simple-consent-mode' || level === 1) && (!revoke || revoke === '0' || revoke === '1') ? {} : createConfig({ @@ -132,7 +132,7 @@ const SSOEthereumProvider = ({ children, layout, level }: any) => { const ethereumClient = new EthereumClient(wagmiConfig, chains); return ( <> - {(layout === 'simple-consent-mode' || layout === 'simple-web-2' || level === 1) && + {(layout === 'simple-consent-mode' || level === 1) && (!revoke || revoke === '0' || revoke === '1') ? ( <>{children} ) : ( diff --git a/src/Hooks/useConsentStatus.ts b/src/Hooks/useConsentStatus.ts index 9c0a5d5..30b7444 100644 --- a/src/Hooks/useConsentStatus.ts +++ b/src/Hooks/useConsentStatus.ts @@ -84,7 +84,7 @@ const useConsentStatus = (endpoint?: string, layout?: string, props?: WalletConn const rpc = useGrpcClient(network); useEffect(() => { - if (rpc && layout !== 'simple-consent-mode' && layout !== 'simple-web-2' && level !== 1) { + if (rpc && layout !== 'simple-consent-mode' && level !== 1) { setRpcGenesisHash(undefined); rpc .getConsensusStatus() @@ -134,7 +134,7 @@ const useConsentStatus = (endpoint?: string, layout?: string, props?: WalletConn const handleLevel = useCallback( async (_level: number) => { - if (layout !== 'simple-consent-mode' && layout !== 'simple-web-2') { + if (layout !== 'simple-consent-mode') { setLevel(_level); if (_level > 3 && isDesktop && !connection && window['concordium']) { setActiveConnectorType(BROWSER_WALLET); diff --git a/src/utils/consent.ts b/src/utils/consent.ts index 7efd66d..006e6df 100644 --- a/src/utils/consent.ts +++ b/src/utils/consent.ts @@ -71,7 +71,7 @@ const agreeConsents = async ( declare const dataLayer: any[]; const consentModeGrant = async (isGtag: any, id: any, layout: any) => { - if (layout !== 'advance-consent-mode') { + if (layout === 'simple-consent-mode') { isGtag ? loadGtagScript(id) : loadGtmScript(id); } sessionStorage.setItem('consentGranted', 'true'); From c96b9e97e8a5d8873963f18d57c2851107735650 Mon Sep 17 00:00:00 2001 From: Viet Date: Wed, 14 Aug 2024 17:40:49 +0700 Subject: [PATCH 08/12] Update consent mode 2.0 --- src/AnalyticsNext/index.tsx | 4 ++- src/AnalyticsReact/index.tsx | 4 ++- src/Components/Consent.tsx | 59 ++++++++++++++++++++++---------- src/Components/ConsentCustom.tsx | 59 ++++++++++++++++++++++---------- src/analytics.tsx | 2 +- src/utils/consent.ts | 30 +++++++++++----- 6 files changed, 111 insertions(+), 47 deletions(-) diff --git a/src/AnalyticsNext/index.tsx b/src/AnalyticsNext/index.tsx index 2c7b803..31a9246 100644 --- a/src/AnalyticsNext/index.tsx +++ b/src/AnalyticsNext/index.tsx @@ -28,7 +28,9 @@ const AnalyticsNext = ({ isOptInReplaceAnalytics = false, children, }: AnalyticsNext) => { - const [layout, setLayout] = useState(process.env.NEXT_PUBLIC_CONSENT_LAYOUT ?? 'simple-web-2'); + const [layout, setLayout] = useState( + process.env.NEXT_PUBLIC_CONSENT_LAYOUT ?? 'simple-consent-mode' + ); const [gtagId, setGtagId] = useState(process.env.NEXT_PUBLIC_ANALYTICS_GTAG_ID); const [gtmId, setGtmId] = useState(process.env.NEXT_PUBLIC_ANALYTICS_GTM_ID); useEffect(() => { diff --git a/src/AnalyticsReact/index.tsx b/src/AnalyticsReact/index.tsx index 8cc6f57..9c98073 100644 --- a/src/AnalyticsReact/index.tsx +++ b/src/AnalyticsReact/index.tsx @@ -22,7 +22,9 @@ const AnalyticsReact = ({ isOptInReplaceAnalytics = false, children, }: AnalyticsReact) => { - const [layout, setLayout] = useState(process.env.REACT_APP_CONSENT_LAYOUT ?? 'simple-web-2'); + const [layout, setLayout] = useState( + process.env.REACT_APP_CONSENT_LAYOUT ?? 'simple-consent-mode' + ); const [gtagId, setGtagId] = useState(process.env.REACT_APP_ANALYTICS_GTAG_ID); const [gtmId, setGtmId] = useState(process.env.REACT_APP_ANALYTICS_GTM_ID); useEffect(() => { diff --git a/src/Components/Consent.tsx b/src/Components/Consent.tsx index 9c52a13..e304df8 100644 --- a/src/Components/Consent.tsx +++ b/src/Components/Consent.tsx @@ -608,7 +608,7 @@ const ConsentComponentApp = (props: WalletConnectionPropsExtends) => { element.click(); }; - const loadConsentDefault = (gtagId: any, gtmId: any) => { + const loadConsentDefault = async (gtagId: any, gtmId: any) => { window.dataLayer = window.dataLayer || []; function gtag( // eslint-disable-next-line @typescript-eslint/no-unused-vars p0: string, // eslint-disable-next-line @typescript-eslint/no-unused-vars @@ -618,25 +618,45 @@ const ConsentComponentApp = (props: WalletConnectionPropsExtends) => { // eslint-disable-next-line prefer-rest-params dataLayer.push(arguments); } - gtag('consent', 'default', { - ad_user_data: 'denied', - ad_personalization: 'denied', - ad_storage: 'denied', - analytics_storage: 'denied', - wait_for_update: 500, - }); - if (gtagId) { - gtag('js', new Date()); - gtag('config', `${gtagId}`); - } - if (gtmId) { - dataLayer.push({ 'gtm.start': new Date().getTime(), event: 'gtm.js' }); + if ( + (layout !== 'simple-consent-mode' || sessionStorage.getItem('consentGranted') === 'true') && + ((gtmId && + !document.querySelector( + `script[src="https://www.googletagmanager.com/gtm.js?id=${gtmId}"]` + )) || + (gtagId && + !document.querySelector( + `script[src="https://www.googletagmanager.com/gtag/js?id=${gtagId}"]` + ))) + ) { + gtagId && (await loadGtagScript(gtagId)); + gtmId && (await loadGtmScript(gtmId)); + if (gtagId) { + gtag('js', new Date()); + gtag('config', `${gtagId}`); + } + if (gtmId) { + dataLayer.push({ 'gtm.start': new Date().getTime(), event: 'gtm.js' }); + } } - if (layout !== 'simple-consent-mode') { - gtagId && loadGtagScript(gtagId); - gtmId && loadGtmScript(gtmId); + if (layout !== 'simple-consent-mode' && sessionStorage.getItem('consentGranted') !== 'true') { gtag('set', 'url_passthrough', true); gtag('set', 'ads_data_redaction', true); + gtag('consent', 'default', { + ad_user_data: 'denied', + ad_personalization: 'denied', + ad_storage: 'denied', + analytics_storage: 'denied', + wait_for_update: 500, + }); + } + if (sessionStorage.getItem('consentGranted') === 'true') { + gtag('consent', 'update', { + ad_user_data: 'granted', + ad_personalization: 'granted', + ad_storage: 'granted', + analytics_storage: 'granted', + }); } }; @@ -651,9 +671,12 @@ const ConsentComponentApp = (props: WalletConnectionPropsExtends) => { setShowBackdrop(false); setShowExpandConsent(false); } - (gtagId || gtmId) && loadConsentDefault(gtagId, gtmId); }, []); + useEffect(() => { + (gtagId || gtmId) && loadConsentDefault(gtagId, gtmId); + }, [layout]); + console.log('level', uuid, level, web3ID, account, loading); return ( diff --git a/src/Components/ConsentCustom.tsx b/src/Components/ConsentCustom.tsx index 2b9a2ac..6f402ad 100644 --- a/src/Components/ConsentCustom.tsx +++ b/src/Components/ConsentCustom.tsx @@ -703,9 +703,12 @@ const ConsentComponentCustomApp = (props: any) => { ) { window.funcAfterConsent && window.funcAfterConsent(); } - (gtagId || gtmId) && loadConsentDefault(gtagId, gtmId); }, []); + useEffect(() => { + (gtagId || gtmId) && loadConsentDefault(gtagId, gtmId); + }, [layout]); + useEffect(() => { if ( showExpandRevoke && @@ -745,7 +748,7 @@ const ConsentComponentCustomApp = (props: any) => {

); }; - const loadConsentDefault = (gtagId: any, gtmId: any) => { + const loadConsentDefault = async (gtagId: any, gtmId: any) => { window.dataLayer = window.dataLayer || []; function gtag( // eslint-disable-next-line @typescript-eslint/no-unused-vars p0: string, // eslint-disable-next-line @typescript-eslint/no-unused-vars @@ -755,25 +758,45 @@ const ConsentComponentCustomApp = (props: any) => { // eslint-disable-next-line prefer-rest-params dataLayer.push(arguments); } - gtag('consent', 'default', { - ad_user_data: 'denied', - ad_personalization: 'denied', - ad_storage: 'denied', - analytics_storage: 'denied', - wait_for_update: 500, - }); - if (gtagId) { - gtag('js', new Date()); - gtag('config', `${gtagId}`); - } - if (gtmId) { - dataLayer.push({ 'gtm.start': new Date().getTime(), event: 'gtm.js' }); + if ( + (layout !== 'simple-consent-mode' || sessionStorage.getItem('consentGranted') === 'true') && + ((gtmId && + !document.querySelector( + `script[src="https://www.googletagmanager.com/gtm.js?id=${gtmId}"]` + )) || + (gtagId && + !document.querySelector( + `script[src="https://www.googletagmanager.com/gtag/js?id=${gtagId}"]` + ))) + ) { + gtagId && (await loadGtagScript(gtagId)); + gtmId && (await loadGtmScript(gtmId)); + if (gtagId) { + gtag('js', new Date()); + gtag('config', `${gtagId}`); + } + if (gtmId) { + dataLayer.push({ 'gtm.start': new Date().getTime(), event: 'gtm.js' }); + } } - if (layout !== 'simple-consent-mode') { - gtagId && loadGtagScript(gtagId); - gtmId && loadGtmScript(gtmId); + if (layout !== 'simple-consent-mode' && sessionStorage.getItem('consentGranted') !== 'true') { gtag('set', 'url_passthrough', true); gtag('set', 'ads_data_redaction', true); + gtag('consent', 'default', { + ad_user_data: 'denied', + ad_personalization: 'denied', + ad_storage: 'denied', + analytics_storage: 'denied', + wait_for_update: 500, + }); + } + if (sessionStorage.getItem('consentGranted') === 'true') { + gtag('consent', 'update', { + ad_user_data: 'granted', + ad_personalization: 'granted', + ad_storage: 'granted', + analytics_storage: 'granted', + }); } }; const paymentRevoke = sessionStorage.getItem('aesirx-analytics-opt-payment'); diff --git a/src/analytics.tsx b/src/analytics.tsx index 92bf8e4..cf267b4 100644 --- a/src/analytics.tsx +++ b/src/analytics.tsx @@ -27,7 +27,7 @@ declare global { } const ConsentPopup = ({ visitor_uuid, event_uuid }: any) => { window.process = { env: '' }; - const [layout, setLayout] = useState(window['consentLayout'] ?? 'simple-web-2'); + const [layout, setLayout] = useState(window['consentLayout'] ?? 'simple-consent-mode'); const [gtagId, setGtagId] = useState(window['analyticsGtagId']); const [gtmId, setGtmId] = useState(window['analyticsGtmId']); useEffect(() => { diff --git a/src/utils/consent.ts b/src/utils/consent.ts index 006e6df..1b34f94 100644 --- a/src/utils/consent.ts +++ b/src/utils/consent.ts @@ -71,18 +71,32 @@ const agreeConsents = async ( declare const dataLayer: any[]; const consentModeGrant = async (isGtag: any, id: any, layout: any) => { - if (layout === 'simple-consent-mode') { - isGtag ? loadGtagScript(id) : loadGtmScript(id); - } - sessionStorage.setItem('consentGranted', 'true'); - function gtag( // eslint-disable-next-line @typescript-eslint/no-unused-vars + async function gtag( // eslint-disable-next-line @typescript-eslint/no-unused-vars p0: any, // eslint-disable-next-line @typescript-eslint/no-unused-vars p1: any, // eslint-disable-next-line @typescript-eslint/no-unused-vars - p2: any + p2?: any ) { // eslint-disable-next-line prefer-rest-params dataLayer.push(arguments); } + if (layout === 'simple-consent-mode') { + if ( + isGtag && + !document.querySelector(`script[src="https://www.googletagmanager.com/gtag/js?id=${id}"]`) + ) { + await loadGtagScript(id); + gtag('js', new Date()); + gtag('config', `${id}`); + } else if ( + !isGtag && + !document.querySelector(`script[src="https://www.googletagmanager.com/gtm.js?id=${id}"]`) + ) { + await loadGtmScript(id); + dataLayer.push({ 'gtm.start': new Date().getTime(), event: 'gtm.js' }); + } + } + sessionStorage.setItem('consentGranted', 'true'); + gtag('consent', 'update', { ad_user_data: 'granted', ad_personalization: 'granted', @@ -91,7 +105,7 @@ const consentModeGrant = async (isGtag: any, id: any, layout: any) => { }); }; -const loadGtagScript = (gtagId: any) => { +const loadGtagScript = async (gtagId: any) => { // Load gtag.js script. const gtagScript = document.createElement('script'); gtagScript.async = true; @@ -101,7 +115,7 @@ const loadGtagScript = (gtagId: any) => { firstScript.parentNode.insertBefore(gtagScript, firstScript); }; -const loadGtmScript = (gtmId: any) => { +const loadGtmScript = async (gtmId: any) => { // Load Tag Manager script. const gtmScript = document.createElement('script'); gtmScript.async = true; From 4ce0ce3d262b71c1bd8407592308991e8557842c Mon Sep 17 00:00:00 2001 From: Viet Date: Wed, 14 Aug 2024 17:52:54 +0700 Subject: [PATCH 09/12] update priority --- src/Components/Consent.tsx | 23 ++++++++++++----------- 1 file changed, 12 insertions(+), 11 deletions(-) diff --git a/src/Components/Consent.tsx b/src/Components/Consent.tsx index e304df8..acba35d 100644 --- a/src/Components/Consent.tsx +++ b/src/Components/Consent.tsx @@ -618,6 +618,17 @@ const ConsentComponentApp = (props: WalletConnectionPropsExtends) => { // eslint-disable-next-line prefer-rest-params dataLayer.push(arguments); } + if (layout !== 'simple-consent-mode' && sessionStorage.getItem('consentGranted') !== 'true') { + gtag('consent', 'default', { + ad_user_data: 'denied', + ad_personalization: 'denied', + ad_storage: 'denied', + analytics_storage: 'denied', + wait_for_update: 500, + }); + gtag('set', 'url_passthrough', true); + gtag('set', 'ads_data_redaction', true); + } if ( (layout !== 'simple-consent-mode' || sessionStorage.getItem('consentGranted') === 'true') && ((gtmId && @@ -639,17 +650,7 @@ const ConsentComponentApp = (props: WalletConnectionPropsExtends) => { dataLayer.push({ 'gtm.start': new Date().getTime(), event: 'gtm.js' }); } } - if (layout !== 'simple-consent-mode' && sessionStorage.getItem('consentGranted') !== 'true') { - gtag('set', 'url_passthrough', true); - gtag('set', 'ads_data_redaction', true); - gtag('consent', 'default', { - ad_user_data: 'denied', - ad_personalization: 'denied', - ad_storage: 'denied', - analytics_storage: 'denied', - wait_for_update: 500, - }); - } + if (sessionStorage.getItem('consentGranted') === 'true') { gtag('consent', 'update', { ad_user_data: 'granted', From 8b5a55c99b74946ee5f737595f5e9bcd943f88fe Mon Sep 17 00:00:00 2001 From: Viet Date: Thu, 15 Aug 2024 14:35:35 +0700 Subject: [PATCH 10/12] Custom consent text --- src/AnalyticsNext/index.tsx | 8 ++ src/AnalyticsReact/index.tsx | 8 ++ src/Components/ConsentCustom.tsx | 5 ++ src/Components/Terms.tsx | 132 +++++++++++++++++-------------- src/analytics.tsx | 4 + 5 files changed, 99 insertions(+), 58 deletions(-) diff --git a/src/AnalyticsNext/index.tsx b/src/AnalyticsNext/index.tsx index 31a9246..8c03970 100644 --- a/src/AnalyticsNext/index.tsx +++ b/src/AnalyticsNext/index.tsx @@ -33,6 +33,9 @@ const AnalyticsNext = ({ ); const [gtagId, setGtagId] = useState(process.env.NEXT_PUBLIC_ANALYTICS_GTAG_ID); const [gtmId, setGtmId] = useState(process.env.NEXT_PUBLIC_ANALYTICS_GTM_ID); + const [customConsentText, setCustomConsentText] = useState( + process.env.NEXT_PUBLIC_ANALYTICS_CONSENT_TEXT + ); useEffect(() => { const init = async () => { const data: any = await getConsentTemplate( @@ -42,6 +45,9 @@ const AnalyticsNext = ({ setLayout(data?.data?.template ?? process.env.NEXT_PUBLIC_CONSENT_LAYOUT); setGtagId(data?.data?.gtag_id ?? process.env.NEXT_PUBLIC_ANALYTICS_GTAG_ID); setGtmId(data?.data?.gtm_id ?? process.env.NEXT_PUBLIC_ANALYTICS_GTM_ID); + setCustomConsentText( + data?.data?.consent_text ?? process.env.NEXT_PUBLIC_ANALYTICS_CONSENT_TEXT + ); }; init(); }, []); @@ -61,6 +67,7 @@ const AnalyticsNext = ({ isLoggedApp={isLoggedApp} gtagId={gtagId} gtmId={gtmId} + customConsentText={customConsentText} /> ) : ( diff --git a/src/AnalyticsReact/index.tsx b/src/AnalyticsReact/index.tsx index 9c98073..e26e545 100644 --- a/src/AnalyticsReact/index.tsx +++ b/src/AnalyticsReact/index.tsx @@ -27,6 +27,9 @@ const AnalyticsReact = ({ ); const [gtagId, setGtagId] = useState(process.env.REACT_APP_ANALYTICS_GTAG_ID); const [gtmId, setGtmId] = useState(process.env.REACT_APP_ANALYTICS_GTM_ID); + const [customConsentText, setCustomConsentText] = useState( + process.env.REACT_APP_ANALYTICS_CONSENT_TEXT + ); useEffect(() => { const init = async () => { const data: any = await getConsentTemplate( @@ -36,6 +39,9 @@ const AnalyticsReact = ({ setLayout(data?.data?.template ?? process.env.REACT_APP_CONSENT_LAYOUT); setGtagId(data?.data?.gtag_id ?? process.env.REACT_APP_ANALYTICS_GTAG_ID); setGtmId(data?.data?.gtm_id ?? process.env.REACT_APP_ANALYTICS_GTM_ID); + setCustomConsentText( + data?.data?.consent_text ?? process.env.REACT_APP_ANALYTICS_CONSENT_TEXT + ); }; init(); }, []); @@ -52,6 +58,7 @@ const AnalyticsReact = ({ aesirXEndpoint={process.env.REACT_APP_ENDPOINT_URL ?? 'https://api.aesirx.io'} gtagId={gtagId} gtmId={gtmId} + customConsentText={customConsentText} /> ) : ( diff --git a/src/Components/ConsentCustom.tsx b/src/Components/ConsentCustom.tsx index 6f402ad..5507bd6 100644 --- a/src/Components/ConsentCustom.tsx +++ b/src/Components/ConsentCustom.tsx @@ -68,6 +68,7 @@ const ConsentComponentCustom = ({ gtmId, layout, isOptInReplaceAnalytics, + customConsentText, }: any) => { return ( <> @@ -84,6 +85,7 @@ const ConsentComponentCustom = ({ gtagId={gtagId} gtmId={gtmId} layout={layout} + customConsentText={customConsentText} /> )} @@ -121,6 +123,7 @@ const ConsentComponentCustomWrapper = (props: any) => { gtagId={props?.gtagId} gtmId={props?.gtmId} layout={props?.layout} + customConsentText={props?.customConsentText} uuid={uuid} level={level} connection={connection} @@ -146,6 +149,7 @@ const ConsentComponentCustomApp = (props: any) => { gtagId, gtmId, layout, + customConsentText, activeConnectorType, activeConnector, activeConnectorError, @@ -1315,6 +1319,7 @@ const ConsentComponentCustomApp = (props: any) => { handleLevel={handleLevel} isCustom={true} layout={layout} + customConsentText={customConsentText} >
{ const { t } = useTranslation(); const handleReadmore = (status: boolean) => { @@ -177,66 +178,81 @@ const TermsComponent = ({ ) : ( <> -

- {t('txt_manage_your_consent')} -

-

- {layout === 'simple-consent-mode' - ? t('txt_choose_how_we_use_simple') - : t('txt_choose_how_we_use')} -

-
-

{t('txt_by_consenting')}

-
- - - -
-
{t('txt_analytics_behavioral')}
-
-
-
- - - -
-
{t('txt_form_data')}
-
-
-
-
-

{t('txt_please_note')}

-
- - - -
-
{t('txt_we_do_not_share')}
-
-
-
- - - -
-
{t('txt_you_can_opt_in')}
+ {customConsentText ? ( + <> +
+ + ) : ( + <> + {' '} +

+ {t('txt_manage_your_consent')} +

+

+ {layout === 'simple-consent-mode' + ? t('txt_choose_how_we_use_simple') + : t('txt_choose_how_we_use')} +

+
+

+ {t('txt_by_consenting')} +

+
+ + + +
+
{t('txt_analytics_behavioral')}
+
+
+
+ + + +
+
{t('txt_form_data')}
+
+
-
-
- - - -
-
+
+

{t('txt_please_note')}

+
+ + + +
+
{t('txt_we_do_not_share')}
+
+
+
+ + + +
+
{t('txt_you_can_opt_in')}
+
+
+
+ + + +
+
+
+
-
-
+ + )} )} diff --git a/src/analytics.tsx b/src/analytics.tsx index cf267b4..5ee88dd 100644 --- a/src/analytics.tsx +++ b/src/analytics.tsx @@ -30,6 +30,7 @@ const ConsentPopup = ({ visitor_uuid, event_uuid }: any) => { const [layout, setLayout] = useState(window['consentLayout'] ?? 'simple-consent-mode'); const [gtagId, setGtagId] = useState(window['analyticsGtagId']); const [gtmId, setGtmId] = useState(window['analyticsGtmId']); + const [customConsentText, setCustomConsentText] = useState(window['analyticsConsentText']); useEffect(() => { const init = async () => { const data: any = await getConsentTemplate( @@ -39,6 +40,7 @@ const ConsentPopup = ({ visitor_uuid, event_uuid }: any) => { setLayout(data?.data?.template ?? window['consentLayout']); setGtagId(data?.data?.gtag_id ?? window['analyticsGtagId']); setGtmId(data?.data?.gtm_id ?? window['analyticsGtmId']); + setCustomConsentText(data?.data?.consent_text ?? window['analyticsConsentText']); }; init(); }, []); @@ -60,6 +62,7 @@ const ConsentPopup = ({ visitor_uuid, event_uuid }: any) => { aesirXEndpoint={window['aesirxEndpoint'] ?? 'https://api.aesirx.io'} gtagId={gtagId} gtmId={gtmId} + customConsentText={customConsentText} /> ) : ( { gtagId={gtagId} gtmId={gtmId} layout={layout} + customConsentText={customConsentText} /> )} From 943f0e6a658985766257c575752e3bffc5e3ea93 Mon Sep 17 00:00:00 2001 From: Viet Date: Thu, 15 Aug 2024 17:02:47 +0700 Subject: [PATCH 11/12] Update readme --- README.md | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index b3d0a4a..be29f95 100644 --- a/README.md +++ b/README.md @@ -322,7 +322,10 @@ NEXT_PUBLIC_CONSENT_LAYOUT=default "title":"payment", "content":"
YOUR_CONTENT_INPUT_HERE
" } - ]` + ]`; + + //trigger open optIn consent with Javascript + document.querySelector('.opt-in-consent.payment').classList.add('show'); ``` From 03b307bd6797dd0771a483fc740d34c1a8c0c26e Mon Sep 17 00:00:00 2001 From: Viet Date: Mon, 19 Aug 2024 13:47:52 +0700 Subject: [PATCH 12/12] Update wallet condition --- src/Components/Connect.tsx | 57 +++++++++++++++++++++----------------- 1 file changed, 31 insertions(+), 26 deletions(-) diff --git a/src/Components/Connect.tsx b/src/Components/Connect.tsx index 2a5d4f6..908e67e 100644 --- a/src/Components/Connect.tsx +++ b/src/Components/Connect.tsx @@ -1,6 +1,6 @@ import React, { Suspense, useState } from 'react'; import { Modal } from 'react-bootstrap'; -import { isMobile, isDesktop } from 'react-device-detect'; +import { isMobile, isDesktop, OsTypes, osName } from 'react-device-detect'; import { BROWSER_WALLET, WALLET_CONNECT } from '../Hooks/config'; import concordium_logo from '../Assets/concordium_logo.png'; import { useTranslation } from 'react-i18next'; @@ -65,31 +65,36 @@ const ConnectModal = ({ )} )} - - + {osName !== OsTypes?.IOS ? ( + <> + + + ) : ( + <> + )}
{' '}