Skip to content

Commit

Permalink
Merge branch 'master' into IOAPPX-322-update-assistance-section-new-ds
Browse files Browse the repository at this point in the history
  • Loading branch information
dmnplb authored Sep 27, 2024
2 parents 280168d + 8833776 commit 982a370
Show file tree
Hide file tree
Showing 199 changed files with 6,415 additions and 9,544 deletions.
24 changes: 24 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,30 @@

All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.

## [2.71.0-rc.0](https://github.com/pagopa/io-app/compare/2.70.0-rc.2...2.71.0-rc.0) (2024-09-26)


### Features

* [[IOBP-766](https://pagopa.atlassian.net/browse/IOBP-766)] Add payments section mixpanel events ([#6208](https://github.com/pagopa/io-app/issues/6208)) ([25701ba](https://github.com/pagopa/io-app/commit/25701bafe2d1fdab604d286adfa61cf45e4137af))
* [[IOPID-2263](https://pagopa.atlassian.net/browse/IOPID-2263)] Cie ID Error screens ([#6192](https://github.com/pagopa/io-app/issues/6192)) ([4d5733c](https://github.com/pagopa/io-app/commit/4d5733c4acfdf26606df7c3c75d22c9b80c1ac5c))


### Bug Fixes

* **IT Wallet:** [[SIW-1681](https://pagopa.atlassian.net/browse/SIW-1681)] Authorization with CIE L3 to obtain an eID ([#6219](https://github.com/pagopa/io-app/issues/6219)) ([4407a73](https://github.com/pagopa/io-app/commit/4407a73ec046f0735a03d041f2bbdb41de0a6ae0))
* [[IOBP-808](https://pagopa.atlassian.net/browse/IOBP-808)] Add trim notice code workaround if pasted ([#6167](https://github.com/pagopa/io-app/issues/6167)) ([253d138](https://github.com/pagopa/io-app/commit/253d13860eb2905aee70d3294f39f61da4f59f5a))


### Chores

* [[IOBP-726](https://pagopa.atlassian.net/browse/IOBP-726)] Migrate IdPay machines to XState V5 ([#6135](https://github.com/pagopa/io-app/issues/6135)) ([8dbf986](https://github.com/pagopa/io-app/commit/8dbf986be63619309d8fe327237e03fbb18c3079))
* [[IOBP-841](https://pagopa.atlassian.net/browse/IOBP-841),[IOBP-842](https://pagopa.atlassian.net/browse/IOBP-842)] Edit new payment flow mixpanel property values ([#6152](https://github.com/pagopa/io-app/issues/6152)) ([21c3d3a](https://github.com/pagopa/io-app/commit/21c3d3a7e7d2f88c930418ae9a81e204982e2fdf))
* [[IOBP-854](https://pagopa.atlassian.net/browse/IOBP-854)] Add payment mixpanel event property for the `selected_psp_flag` ([#6180](https://github.com/pagopa/io-app/issues/6180)) ([c1d0664](https://github.com/pagopa/io-app/commit/c1d0664529ff391a79f8a5599e407f6d0ff9a54a))
* **Cross:** [[IOAPPX-370](https://pagopa.atlassian.net/browse/IOAPPX-370)] Enable discrete transition in the `BonusCardScreenComponent` ([#6171](https://github.com/pagopa/io-app/issues/6171)) ([523ee40](https://github.com/pagopa/io-app/commit/523ee4098c8dd2e880e2767bdfb50ef8e03c89cc))
* **Cross:** [[IOAPPX-373](https://pagopa.atlassian.net/browse/IOAPPX-373)] Update Sentry dependencies to support Xcode 16 ([#6193](https://github.com/pagopa/io-app/issues/6193)) ([529ea6c](https://github.com/pagopa/io-app/commit/529ea6c546a05f544c20253a90548024123340a2))
* **IT Wallet:** [[SIW-1636](https://pagopa.atlassian.net/browse/SIW-1636)] Handle the initial phase of async credential issuance ([#6200](https://github.com/pagopa/io-app/issues/6200)) ([d606ffc](https://github.com/pagopa/io-app/commit/d606ffc6fde34c83c92f25d89529c74e52ce24e7))

## [2.70.0-rc.2](https://github.com/pagopa/io-app/compare/2.70.0-rc.1...2.70.0-rc.2) (2024-09-20)


Expand Down
4 changes: 2 additions & 2 deletions android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -113,8 +113,8 @@ android {
applicationId "it.pagopa.io.app"
minSdkVersion rootProject.ext.minSdkVersion
targetSdkVersion rootProject.ext.targetSdkVersion
versionCode 100154851
versionName "2.70.0.2"
versionCode 100154852
versionName "2.71.0.0"
multiDexEnabled true
// The resConfigs attribute will remove all not required localized resources while building the application,
// including the localized resources from libraries.
Expand Down
4 changes: 2 additions & 2 deletions ios/ItaliaApp.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -767,7 +767,7 @@
CODE_SIGN_ENTITLEMENTS = ItaliaApp/ItaliaApp.entitlements;
CODE_SIGN_IDENTITY = "iPhone Developer";
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
CURRENT_PROJECT_VERSION = 2;
CURRENT_PROJECT_VERSION = 0;
DEAD_CODE_STRIPPING = YES;
DEVELOPMENT_TEAM = M2X5YQ4BJ7;
ENABLE_BITCODE = NO;
Expand Down Expand Up @@ -808,7 +808,7 @@
CODE_SIGN_ENTITLEMENTS = ItaliaApp/ItaliaApp.entitlements;
CODE_SIGN_IDENTITY = "iPhone Distribution";
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution";
CURRENT_PROJECT_VERSION = 2;
CURRENT_PROJECT_VERSION = 0;
DEAD_CODE_STRIPPING = YES;
DEVELOPMENT_TEAM = M2X5YQ4BJ7;
ENABLE_BITCODE = NO;
Expand Down
4 changes: 2 additions & 2 deletions ios/ItaliaApp/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleShortVersionString</key>
<string>2.70.0</string>
<string>2.71.0</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleURLTypes</key>
Expand All @@ -35,7 +35,7 @@
</dict>
</array>
<key>CFBundleVersion</key>
<string>2</string>
<string>0</string>
<key>ITSAppUsesNonExemptEncryption</key>
<false/>
<key>LSApplicationQueriesSchemes</key>
Expand Down
4 changes: 2 additions & 2 deletions ios/ItaliaAppTests/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,10 @@
<key>CFBundlePackageType</key>
<string>BNDL</string>
<key>CFBundleShortVersionString</key>
<string>2.70.0</string>
<string>2.71.0</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleVersion</key>
<string>2</string>
<string>0</string>
</dict>
</plist>
15 changes: 15 additions & 0 deletions locales/en/index.yml
Original file line number Diff line number Diff line change
Expand Up @@ -720,6 +720,16 @@ authentication:
generic:
title: Sorry, access was not available.
subtitle: A problem occurred while logging in. Please try again in a few minutes.
cie_id:
error_screen:
title: Can't log in with CieID?
cie_pin_supported:
description: "If you have your Electronic Identity Card handy, use it to access IO.\n\nInsert the CIE PIN and bring it close to the device to allow the data to be read."
primary_action_label: Login with CIE + PIN
cie_pin_not_supported:
description: If you have SPID, log in to IO by entering your credentials. You can also use your face or fingerprint or the code set for your SPID provider's app.
primary_action_label: Login with SPID
secondary_action_label: Close
cie:
genericTitle: Login with CIE
cie: CIE
Expand Down Expand Up @@ -3307,6 +3317,10 @@ features:
title: Non è possibile aggiungere il documento
body: Assicurati di avere il documento fisico valido prima di richiedere la sua versione digitale.
primaryAction: Ho capito
asyncCredentialError:
title: La tua richiesta è stata presa in carico
body: Riceverai un messaggio in app con l'esito della tua richiesta appena sarà disponibile.
primaryAction: Ho capito
unsupportedDevice:
text: Starting from 02.07.2024 your device may no longer be compatible with IO.
moreInfo: More info
Expand Down Expand Up @@ -3731,6 +3745,7 @@ idpay:
INSTRUMENTS_LIST_LOAD_FAILURE: "Errore nel caricamento della lista strumenti"
INSTRUMENT_ENROLL_FAILURE: "Errore durante l'aggiunta del metodo di pagamento"
INSTRUMENT_DELETE_FAILURE: "Errore durante la rimozione del metodo di pagamento"
SESSION_EXPIRED: "C'è stato un problema, riprova"
headerTitle: "Configure the initiative"
intro:
title: "We are almost there"
Expand Down
15 changes: 15 additions & 0 deletions locales/it/index.yml
Original file line number Diff line number Diff line change
Expand Up @@ -720,6 +720,16 @@ authentication:
generic:
title: Non è stato possibile accedere
subtitle: Si è verificato un problema durante l’accesso. Riprova tra qualche minuto.
cie_id:
error_screen:
title: Non riesci a entrare con CieID?
cie_pin_supported:
description: "Se hai la tua Carta di Identità Elettronica a portata di mano, usala per accedere a IO.\n\nInserisci il PIN della CIE e avvicinala al dispositivo per consentire la lettura dei dati."
primary_action_label: Entra con CIE + PIN
cie_pin_not_supported:
description: Se hai SPID, entra su IO inserendo le tue credenziali. Puoi usare anche il tuo volto o l’impronta o il codice impostato per l’app del tuo fornitore di SPID.
primary_action_label: Entra con SPID
secondary_action_label: Chiudi
cie:
genericTitle: Entra con CIE
cie: CIE
Expand Down Expand Up @@ -3307,6 +3317,10 @@ features:
title: Non è possibile aggiungere il documento
body: Assicurati di avere il documento fisico valido prima di richiedere la sua versione digitale.
primaryAction: Ho capito
asyncCredentialError:
title: La tua richiesta è stata presa in carico
body: Riceverai un messaggio in app con l'esito della tua richiesta appena sarà disponibile.
primaryAction: Ho capito
unsupportedDevice:
text: Starting from 02.07.2024 your device may no longer be compatible with IO.
moreInfo: More info
Expand Down Expand Up @@ -3731,6 +3745,7 @@ idpay:
INSTRUMENTS_LIST_LOAD_FAILURE: "Errore nel caricamento della lista strumenti"
INSTRUMENT_ENROLL_FAILURE: "Errore durante l'aggiunta del metodo di pagamento"
INSTRUMENT_DELETE_FAILURE: "Errore durante la rimozione del metodo di pagamento"
SESSION_EXPIRED: "C'è stato un problema, riprova"
headerTitle: "Configura l'iniziativa"
intro:
title: "Ci siamo quasi"
Expand Down
15 changes: 5 additions & 10 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "italia-app",
"version": "2.70.0-rc.2",
"version": "2.71.0-rc.0",
"io_backend_api": "https://raw.githubusercontent.com/pagopa/io-backend/v14.3.0-RELEASE/api_backend.yaml",
"io_session_manager_api": "https://raw.githubusercontent.com/pagopa/io-auth-n-identity-domain/[email protected]/apps/io-session-manager/api/internal.yaml",
"io_session_manager_public_api": "https://raw.githubusercontent.com/pagopa/io-auth-n-identity-domain/[email protected]/apps/io-session-manager/api/public.yaml",
Expand Down Expand Up @@ -94,7 +94,6 @@
"generate": "npm-run-all generate:*",
"locales_unused": "ts-node --skip-project -O '{\"lib\":[\"es2015\"]}' scripts/unused-locales.ts",
"remove_unused_locales": "ts-node --skip-project -O '{\"lib\":[\"es2015\"]}' scripts/remove-unused-locales.ts",
"generate:xstate-types": "xstate typegen \"ts/**/*.ts?(x)\"",
"prepare": "husky install"
},
"lint-staged": {
Expand All @@ -113,7 +112,7 @@
"@pagopa/io-react-native-integrity": "^0.3.0",
"@pagopa/io-react-native-jwt": "^1.2.0",
"@pagopa/io-react-native-login-utils": "1.0.5",
"@pagopa/io-react-native-wallet": "^0.16.3",
"@pagopa/io-react-native-wallet": "^0.17.1",
"@pagopa/io-react-native-zendesk": "^0.3.29",
"@pagopa/react-native-cie": "^1.3.0",
"@pagopa/ts-commons": "^10.15.0",
Expand All @@ -130,9 +129,8 @@
"@redux-saga/testing-utils": "^1.1.3",
"@sentry/react-native": "^5.32.0",
"@shopify/flash-list": "~1.7.0",
"@xstate/react": "^4.0.1",
"@textlint/markdown-to-ast": "^14.0.4",
"@xstate/react": "^3.0.1",
"@xstate5/react": "npm:@xstate/react@4",
"async-mutex": "^0.1.3",
"buffer": "^4.9.1",
"color": "^3.0.0",
Expand Down Expand Up @@ -227,8 +225,7 @@
"validator": "^13.7.0",
"xml2js": "^0.5.0",
"xss": "1.0.10",
"xstate": "^4.33.6",
"xstate5": "npm:xstate@5"
"xstate": "^5"
},
"devDependencies": {
"@babel/core": "^7.20.0",
Expand Down Expand Up @@ -270,7 +267,6 @@
"@types/xml2js": "^0.4.11",
"@typescript-eslint/eslint-plugin": "^5.9.1",
"@typescript-eslint/parser": "^7.13.0",
"@xstate/cli": "^0.3.3",
"abortcontroller-polyfill": "1.7.3",
"babel-jest": "^29.2.1",
"babel-plugin-macros": "^3.1.0",
Expand Down Expand Up @@ -320,8 +316,7 @@
"@babel/preset-typescript": "^7.23.3",
"@babel/plugin-transform-typescript": "^7.23.6",
"@babel/plugin-syntax-typescript": "^7.23.3",
"@babel/types": "^7.23.6",
"@xstate5/react/xstate": "^5.13.0"
"@babel/types": "^7.23.6"
},
"react-native": {
"path": "path-browserify",
Expand Down
4 changes: 2 additions & 2 deletions publiccode.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,11 @@
publiccodeYmlVersion: '0.2'
name: IO
logo: "img/app-logo.svg"
releaseDate: '2024-09-20'
releaseDate: '2024-09-26'
url: 'https://github.com/pagopa/io-app'
applicationSuite: IO
landingURL: 'https://io.italia.it/'
softwareVersion: 2.70.0-rc.2
softwareVersion: 2.71.0-rc.0
developmentStatus: beta
softwareType: standalone/mobile
roadmap: 'https://io.italia.it/'
Expand Down
101 changes: 34 additions & 67 deletions ts/components/BonusCard/BonusCardScreenComponent.tsx
Original file line number Diff line number Diff line change
@@ -1,96 +1,63 @@
import {
ActionProp,
ButtonLink,
ButtonSolid
} from "@pagopa/io-app-design-system";
import React, { ComponentProps } from "react";
import { ActionProp } from "@pagopa/io-app-design-system";
import { default as React, ReactNode } from "react";
import { Dimensions } from "react-native";
import { useSharedValue } from "react-native-reanimated";
import { useNavigation } from "@react-navigation/native";
import {
ContextualHelpProps,
ContextualHelpPropsMarkdown
} from "../screens/BaseScreenComponent";
import Animated, { useAnimatedRef } from "react-native-reanimated";
import { SupportRequestParams } from "../../hooks/useStartSupportRequest";
import { IOScrollView, IOScrollViewActions } from "../ui/IOScrollView";
import I18n from "../../i18n";
import { useStartSupportRequest } from "../../hooks/useStartSupportRequest";
import { useHeaderSecondLevel } from "../../hooks/useHeaderSecondLevel";
import { BonusCard } from "./BonusCard";

type SupportRequestProps = {
contextualHelp?: ContextualHelpProps;
contextualHelpMarkdown?: ContextualHelpPropsMarkdown;
};

type BaseProps = {
title?: string;
headerAction?: ActionProp;
children?: React.ReactNode;
footerCtaPrimary?: Omit<ComponentProps<typeof ButtonSolid>, "fullWidth">;
footerCtaSecondary?: Omit<ComponentProps<typeof ButtonLink>, "color">;
children?: ReactNode;
actions?: IOScrollViewActions;
};

export type BonusScreenComponentProps = BaseProps &
SupportRequestProps &
SupportRequestParams &
BonusCard;

const scrollTriggerOffsetValue: number = 88;

const deviceScreenHeightLogoThreshold = 700;
/*
Let's reuse the variable names set in the PR#6088 to make the
the eventual refactoring much easier.
In this specific case, we set the threshold to show/hide
the `BonusCard` logo
*/
export const MIN_HEIGHT_TO_SHOW_FULL_RENDER = 700;

const BonusCardScreenComponent = ({
title,
headerAction,
actions,
faqCategories,
contextualHelpMarkdown,
contextualHelp,
children,
footerCtaPrimary,
footerCtaSecondary,
...cardProps
}: BonusScreenComponentProps) => {
const navigation = useNavigation();

const scrollTranslationY = useSharedValue(0);
const animatedScrollViewRef = useAnimatedRef<Animated.ScrollView>();

const screenHeight = Dimensions.get("window").height;
const shouldHideLogo = screenHeight < deviceScreenHeightLogoThreshold;

const startSupportRequest = useStartSupportRequest({});
const shouldHideLogo = screenHeight < MIN_HEIGHT_TO_SHOW_FULL_RENDER;

const footerActions = ((): IOScrollViewActions | undefined => {
if (footerCtaPrimary && footerCtaSecondary) {
return {
type: "TwoButtons",
primary: footerCtaPrimary,
secondary: footerCtaSecondary
};
}
if (footerCtaPrimary) {
return { type: "SingleButton", primary: footerCtaPrimary };
}
return undefined;
})();
useHeaderSecondLevel({
title: title || "",
transparent: true,
supportRequest: true,
faqCategories,
contextualHelpMarkdown,
contextualHelp,
secondAction: headerAction,
enableDiscreteTransition: true,
animatedRef: animatedScrollViewRef
});

return (
<IOScrollView
headerConfig={{
type: "singleAction",
title: title || "",
transparent: true,
scrollValues: {
triggerOffset: scrollTriggerOffsetValue,
contentOffsetY: scrollTranslationY
},
goBack: navigation.goBack,
backAccessibilityLabel: I18n.t("global.buttons.back"),
firstAction: {
icon: "help",
onPress: startSupportRequest,
accessibilityLabel: I18n.t(
"global.accessibility.contextualHelp.open.label"
)
}
}}
actions={footerActions}
animatedRef={animatedScrollViewRef}
actions={actions}
includeContentMargins={false}
snapOffset={scrollTriggerOffsetValue}
>
<BonusCard hideLogo={shouldHideLogo} {...cardProps} />
{children}
Expand Down
Loading

0 comments on commit 982a370

Please sign in to comment.