@pagopa/selfcare-common-frontend 1.34.78 → 1.34.79
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +10 -2
- package/build.info +2 -2
- package/lib/components/Header/Header.js +8 -3
- package/lib/components/Header/Header.js.map +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -4,8 +4,9 @@ All notable changes to this project will be documented in this file. Dates are d
|
|
|
4
4
|
|
|
5
5
|
Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
|
|
6
6
|
|
|
7
|
-
#### [v1.34.
|
|
7
|
+
#### [v1.34.79](https://github.com/pagopa/selfcare-common-frontend/compare/v1.35.0...v1.34.79)
|
|
8
8
|
|
|
9
|
+
- update product rendering logic in Header component based on user type [`#315`](https://github.com/pagopa/selfcare-common-frontend/pull/315)
|
|
9
10
|
- [SELC-7957] feat: add fixedParty prop to Header component and update product selection logic [`#314`](https://github.com/pagopa/selfcare-common-frontend/pull/314)
|
|
10
11
|
- [SELC-7939] feat: add isPagoPaUser utility and chip label [`#313`](https://github.com/pagopa/selfcare-common-frontend/pull/313)
|
|
11
12
|
- Bump validator from 13.15.15 to 13.15.20 [`#311`](https://github.com/pagopa/selfcare-common-frontend/pull/311)
|
|
@@ -135,10 +136,17 @@ Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
|
|
|
135
136
|
- Bump rimraf from 3.0.2 to 6.0.1 [`e6941b9`](https://github.com/pagopa/selfcare-common-frontend/commit/e6941b9e6b05c973d991e2470a851b5ca03926ce)
|
|
136
137
|
- Used a environment variable to manage correct links in the footer based to product and actual environment [`960e2fb`](https://github.com/pagopa/selfcare-common-frontend/commit/960e2fbaa8aa8f79061639b26dc1a27f28b8aae3)
|
|
137
138
|
|
|
138
|
-
#### [v1.35.0](https://github.com/pagopa/selfcare-common-frontend/compare/v1.34.
|
|
139
|
+
#### [v1.35.0](https://github.com/pagopa/selfcare-common-frontend/compare/v1.34.78...v1.35.0)
|
|
139
140
|
|
|
140
141
|
> 20 July 2023
|
|
141
142
|
|
|
143
|
+
#### [v1.34.78](https://github.com/pagopa/selfcare-common-frontend/compare/v1.34.77...v1.34.78)
|
|
144
|
+
|
|
145
|
+
> 13 November 2025
|
|
146
|
+
|
|
147
|
+
- [SELC-7957] feat: add fixedParty prop to Header component and update product selection logic [`#314`](https://github.com/pagopa/selfcare-common-frontend/pull/314)
|
|
148
|
+
- [SELC-7957] feat: add fixedParty prop to Header component and update product selection logic (#314) [`#7957`](https://pagopa.atlassian.net/browse/7957)
|
|
149
|
+
|
|
142
150
|
#### [v1.34.77](https://github.com/pagopa/selfcare-common-frontend/compare/v1.34.76...v1.34.77)
|
|
143
151
|
|
|
144
152
|
> 5 November 2025
|
package/build.info
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
tags/v1.29.0~1^2
|
|
1
|
+
20251114.1 - selfcare-common-frontend.deploy(244606)
|
|
2
|
+
tags/v1.29.0~1^2 4c296c8ef75feb49f2c2f510fd984cb46801c256
|
|
@@ -20,7 +20,6 @@ const selfcareBackstageProduct = {
|
|
|
20
20
|
productUrl: env_1.CONFIG.HEADER.LINK.PRODUCTURL,
|
|
21
21
|
linkType: 'internal',
|
|
22
22
|
};
|
|
23
|
-
const productToRender = storage_1.isPagoPaUser && location.pathname.includes('/admin') ? selfcareBackstageProduct : selfcareProduct;
|
|
24
23
|
const rootLink = {
|
|
25
24
|
label: 'PagoPA S.p.A.',
|
|
26
25
|
href: env_1.CONFIG.HEADER.LINK.ROOTLINK,
|
|
@@ -28,11 +27,17 @@ const rootLink = {
|
|
|
28
27
|
title: 'Sito di PagoPA S.p.A.',
|
|
29
28
|
};
|
|
30
29
|
/** SelfCare Header component */
|
|
31
|
-
const Header = ({ withSecondHeader, productsList = [], selectedPartyId, selectedProductId
|
|
30
|
+
const Header = ({ withSecondHeader, productsList = [], selectedPartyId, selectedProductId, partyList = [], loggedUser, assistanceEmail, enableLogin = true, userActions = [], enableDropdown = false, addSelfcareProduct = true, onExit = (exitAction) => exitAction(), onSelectedProduct, onSelectedParty, maxCharactersNumberMultiLineButton, maxCharactersNumberMultiLineItem, enableAssistanceButton = true, onDocumentationClick, onLogoutClick, fixedParty, }) => {
|
|
31
|
+
const [productToRender, setProductToRender] = (0, react_1.useState)(selfcareProduct);
|
|
32
32
|
const { t } = (0, react_i18next_1.useTranslation)();
|
|
33
33
|
const effectivePartyList = fixedParty ? [fixedParty] : partyList;
|
|
34
34
|
const effectivePartyId = fixedParty ? fixedParty.id : selectedPartyId;
|
|
35
|
-
|
|
35
|
+
(0, react_1.useEffect)(() => {
|
|
36
|
+
setProductToRender(storage_1.isPagoPaUser && location.pathname.includes('/admin')
|
|
37
|
+
? selfcareBackstageProduct
|
|
38
|
+
: selfcareProduct);
|
|
39
|
+
}, [location.pathname]);
|
|
40
|
+
return ((0, jsx_runtime_1.jsxs)(react_1.Fragment, { children: [(0, jsx_runtime_1.jsx)("header", { children: (0, jsx_runtime_1.jsx)(HeaderAccount_1.HeaderAccount, { rootLink: rootLink, loggedUser: loggedUser, onAssistanceClick: () => onExit(() => window.location.assign((0, assistanceService_1.buildAssistanceURI)(assistanceEmail))), onLogin: () => onExit(() => window.location.assign(env_1.CONFIG.URL_FE.LOGIN)), onLogout: onLogoutClick !== null && onLogoutClick !== void 0 ? onLogoutClick : (() => onExit(() => window.location.assign(env_1.CONFIG.URL_FE.LOGOUT))), enableLogin: enableLogin, userActions: userActions, enableDropdown: enableDropdown, enableAssistanceButton: enableAssistanceButton, onDocumentationClick: onDocumentationClick }) }), withSecondHeader === true ? ((0, jsx_runtime_1.jsx)("nav", { children: (0, jsx_runtime_1.jsx)(HeaderProduct_1.HeaderProduct, { productId: selectedProductId || productToRender.id, productsList: addSelfcareProduct ? [productToRender].concat(productsList) : productsList, partyId: effectivePartyId, partyList: effectivePartyList, onSelectedProduct: onSelectedProduct, onSelectedParty: onSelectedParty, maxCharactersNumberMultiLineButton: maxCharactersNumberMultiLineButton, maxCharactersNumberMultiLineItem: maxCharactersNumberMultiLineItem, ...(storage_1.isPagoPaUser && {
|
|
36
41
|
chipLabel: t('common.header.chipLabel'),
|
|
37
42
|
chipColor: 'primary',
|
|
38
43
|
chipSize: 'medium',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Header.js","sourceRoot":"","sources":["../../../../src/lib/components/Header/Header.tsx"],"names":[],"mappings":";;;AAOA,kGAA+F;AAC/F,kGAA+F;AAE/F,
|
|
1
|
+
{"version":3,"file":"Header.js","sourceRoot":"","sources":["../../../../src/lib/components/Header/Header.tsx"],"names":[],"mappings":";;;AAOA,kGAA+F;AAC/F,kGAA+F;AAE/F,iCAAsD;AACtD,iDAA+C;AAC/C,0CAA0C;AAC1C,wEAAsE;AACtE,iDAAmD;AA8CnD,MAAM,eAAe,GAAkB;IACrC,EAAE,EAAE,eAAe;IACnB,KAAK,EAAE,gBAAgB;IACvB,UAAU,EAAE,YAAM,CAAC,MAAM,CAAC,IAAI,CAAC,UAAU;IACzC,QAAQ,EAAE,UAAU;CACrB,CAAC;AAEF,MAAM,wBAAwB,GAAkB;IAC9C,EAAE,EAAE,yBAAyB;IAC7B,KAAK,EAAE,0BAA0B;IACjC,UAAU,EAAE,YAAM,CAAC,MAAM,CAAC,IAAI,CAAC,UAAU;IACzC,QAAQ,EAAE,UAAU;CACrB,CAAC;AAEF,MAAM,QAAQ,GAAiB;IAC7B,KAAK,EAAE,eAAe;IACtB,IAAI,EAAE,YAAM,CAAC,MAAM,CAAC,IAAI,CAAC,QAAQ;IACjC,SAAS,EAAE,oCAAoC;IAC/C,KAAK,EAAE,uBAAuB;CAC/B,CAAC;AAEF,gCAAgC;AAChC,MAAM,MAAM,GAAG,CAAC,EACd,gBAAgB,EAChB,YAAY,GAAG,EAAE,EACjB,eAAe,EACf,iBAAiB,EACjB,SAAS,GAAG,EAAE,EACd,UAAU,EACV,eAAe,EACf,WAAW,GAAG,IAAI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AC,YAAM,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,EACxE,QAAQ,EACN,aAAa,aAAb,aAAa,cAAb,aAAa,GAAI,CAAC,GAAG,EAAE,CAAC,MAAM,CAAC,GAAG,EAAE,CAAC,MAAM,CAAC,QAAQ,CAAC,MAAM,CAAC,YAAM,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,EAErF,WAAW,EAAE,WAAW,EACxB,WAAW,EAAE,WAAW,EACxB,cAAc,EAAE,cAAc,EAC9B,sBAAsB,EAAE,sBAAsB,EAC9C,oBAAoB,EAAE,oBAAoB,GAC1C,GACK,EACR,gBAAgB,KAAK,IAAI,CAAC,CAAC,CAAC,CAC3B,0CACE,uBAAC,6BAAa,IACZ,SAAS,EAAE,iBAAiB,IAAI,eAAe,CAAC,EAAE,EAClD,YAAY,EACV,kBAAkB,CAAC,CAAC,CAAC,CAAC,eAAe,CAAC,CAAC,MAAM,CAAC,YAAY,CAAC,CAAC,CAAC,CAAC,YAAY,EAE5E,OAAO,EAAE,gBAAgB,EACzB,SAAS,EAAE,kBAAkB,EAC7B,iBAAiB,EAAE,iBAAiB,EACpC,eAAe,EAAE,eAAe,EAChC,kCAAkC,EAAE,kCAAkC,EACtE,gCAAgC,EAAE,gCAAgC,KAC9D,CAAC,sBAAY,IAAI;wBACnB,SAAS,EAAE,CAAC,CAAC,yBAAyB,CAAC;wBACvC,SAAS,EAAE,SAAkB;wBAC7B,QAAQ,EAAE,QAAiB;qBAC5B,CAAC,GACF,GACE,CACP,CAAC,CAAC,CAAC,CACF,EAAE,CACH,IACQ,CACZ,CAAC;AACJ,CAAC,CAAC;AAEF,kBAAe,MAAM,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pagopa/selfcare-common-frontend",
|
|
3
3
|
"description": "Shared React components for the pagopa selfcare project",
|
|
4
|
-
"version": "1.34.
|
|
4
|
+
"version": "1.34.79",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": "https://github.com/pagopa/selfcare-common-frontend",
|
|
7
7
|
"author": "https://www.pagopa.gov.it",
|