design-comuni-plone-theme 11.23.0 → 11.23.2

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.
Binary file
package/CHANGELOG.md CHANGED
@@ -1,5 +1,30 @@
1
1
 
2
2
 
3
+ ## [11.23.2](https://github.com/RedTurtle/design-comuni-plone-theme/compare/v11.23.1...v11.23.2) (2024-09-24)
4
+
5
+
6
+ ### Bug Fixes
7
+
8
+ * added condition for spid user link redirect ([#776](https://github.com/RedTurtle/design-comuni-plone-theme/issues/776)) ([8ab726b](https://github.com/RedTurtle/design-comuni-plone-theme/commit/8ab726b52fb22df66d76f1b00089cb4aa0f07968))
9
+
10
+
11
+ ### Documentation
12
+
13
+ * updated publiccode and release log ([19a712d](https://github.com/RedTurtle/design-comuni-plone-theme/commit/19a712d35570da2a97bf811c72f4d87343c4e2dc))
14
+
15
+ ## [11.23.1](https://github.com/RedTurtle/design-comuni-plone-theme/compare/v11.23.0...v11.23.1) (2024-09-19)
16
+
17
+
18
+ ### Bug Fixes
19
+
20
+ * **a11y:** used p with h classname to ensure correct heading order ([#770](https://github.com/RedTurtle/design-comuni-plone-theme/issues/770)) ([2ab487e](https://github.com/RedTurtle/design-comuni-plone-theme/commit/2ab487e1a799e48fbbb98e89ca7d195ed37b3ea6))
21
+ * changed focus color ([#772](https://github.com/RedTurtle/design-comuni-plone-theme/issues/772)) ([e3c4e45](https://github.com/RedTurtle/design-comuni-plone-theme/commit/e3c4e45cc06e18c10ae1c51327e4762d0197f767))
22
+
23
+
24
+ ### Documentation
25
+
26
+ * updated publiccode and release log ([de02c1e](https://github.com/RedTurtle/design-comuni-plone-theme/commit/de02c1e5ad7f71ecdd8f1dbd6b97dfe7bdec67d2))
27
+
3
28
  ## [11.23.0](https://github.com/RedTurtle/design-comuni-plone-theme/compare/v11.22.1...v11.23.0) (2024-09-19)
4
29
 
5
30
 
package/RELEASE.md CHANGED
@@ -41,6 +41,18 @@
41
41
  - ...
42
42
  -->
43
43
 
44
+ ## Versione 11.23.2 (24/09/2024)
45
+
46
+ ### Migliorie
47
+
48
+ - Gli utenti SPID vengono ora direttamente rediretti al link finale quando viene utilizzato un CT di tipo Collegamento
49
+
50
+ ## Versione 11.23.1 (19/09/2024)
51
+
52
+ ### Migliorie
53
+
54
+ - Il colore del focus da tastiera sugli elementi della pagina è ora bianco e nero per garantire sempre un contrasto ottimale su tutti gli sfondi.
55
+
44
56
  ## Versione 11.23.0 (19/09/2024)
45
57
 
46
58
  ### Migliorie
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "design-comuni-plone-theme",
3
3
  "description": "Volto Theme for Italia design guidelines",
4
4
  "license": "GPL-v3",
5
- "version": "11.23.0",
5
+ "version": "11.23.2",
6
6
  "main": "src/index.js",
7
7
  "repository": {
8
8
  "type": "git",
package/publiccode.yml CHANGED
@@ -227,9 +227,9 @@ maintenance:
227
227
  name: io-Comune - Il sito AgID per Comuni ed Enti Pubblici
228
228
  platforms:
229
229
  - web
230
- releaseDate: '2024-09-19'
230
+ releaseDate: '2024-09-24'
231
231
  softwareType: standalone/web
232
- softwareVersion: 11.23.0
232
+ softwareVersion: 11.23.2
233
233
  url: 'https://github.com/italia/design-comuni-plone-theme'
234
234
  usedBy:
235
235
  - ASP Comuni Modenesi Area Nord
@@ -26,9 +26,9 @@ const BottomBody = ({ data, intl, hasArguments }) => {
26
26
  <div
27
27
  className={data?.centerAlignment ? 'col-lg-12 mb-3' : 'col-lg-auto'}
28
28
  >
29
- <h6 className="text-uppercase text-center mt-1">
29
+ <p className="h6 text-uppercase text-center mt-1">
30
30
  {intl?.formatMessage(messages.otherArguments)}
31
- </h6>
31
+ </p>
32
32
  </div>
33
33
  <div className={data?.centerAlignment ? 'col-lg-12' : 'col-lg-auto'}>
34
34
  {data?.arguments?.map((argument, index) => (
@@ -62,7 +62,7 @@ const FooterInfos = () => {
62
62
  widths={['xs', 'sm', 'md', 'lg', 'xl']}
63
63
  key={index}
64
64
  >
65
- <h4>
65
+ <p className="h4">
66
66
  {column?.title && (
67
67
  <ConditionalLink
68
68
  condition={column.titleLink?.length > 0}
@@ -75,7 +75,7 @@ const FooterInfos = () => {
75
75
  {column.title}
76
76
  </ConditionalLink>
77
77
  )}
78
- </h4>
78
+ </p>
79
79
  {column.showSocial && <FooterSocials />}
80
80
 
81
81
  <div
@@ -63,7 +63,7 @@ const PageHeaderEventDates = ({ content, moment, rrule }) => {
63
63
  }
64
64
  }
65
65
  return content['@type'] === 'Event' ? (
66
- <h4 className="py-2">
66
+ <p className="h4 py-2">
67
67
  {!wholeDay &&
68
68
  !openEnd &&
69
69
  !renderOnlyStart &&
@@ -80,7 +80,7 @@ const PageHeaderEventDates = ({ content, moment, rrule }) => {
80
80
  {eventRecurrenceText && (
81
81
  <div className="recurrence small">{eventRecurrenceText}</div>
82
82
  )}
83
- </h4>
83
+ </p>
84
84
  ) : null;
85
85
  };
86
86
 
@@ -82,7 +82,9 @@ const RelatedItems = ({
82
82
  <>
83
83
  <Row>
84
84
  <Col className="text-center">
85
- <h3>{intl.formatMessage(messages.related_items)}</h3>
85
+ <h2 className="h3">
86
+ {intl.formatMessage(messages.related_items)} ???
87
+ </h2>
86
88
  </Col>
87
89
  </Row>
88
90
  <Row className="mt-lg-4">
@@ -131,7 +133,9 @@ const RelatedItems = ({
131
133
  <>
132
134
  <Row>
133
135
  <Col className="text-center">
134
- <h3>{intl.formatMessage(messages.related_items)}</h3>
136
+ <h2 className="h3">
137
+ {intl.formatMessage(messages.related_items)}
138
+ </h2>
135
139
  </Col>
136
140
  </Row>
137
141
  <Row className="mt-lg-4">
@@ -163,7 +163,7 @@ const SideMenu = ({ data, content_uid }) => {
163
163
  }}
164
164
  aria-controls="side-menu-body"
165
165
  >
166
- <h3>{intl.formatMessage(messages.index)}</h3>
166
+ <h2 className="h3">{intl.formatMessage(messages.index)}</h2>
167
167
  </AccordionHeader>
168
168
  <div className="mb-3">
169
169
  <Progress
@@ -105,7 +105,7 @@ const PuntoDiContattoView = (props) => {
105
105
  {content?.value_punto_contatto?.map((pdc, i) => {
106
106
  return (
107
107
  <div className="my-2" key={i}>
108
- <h5 className="h6">
108
+ <p className="h6">
109
109
  {messages[pdc?.pdc_type] === undefined
110
110
  ? pdc?.pdc_type
111
111
  : intl.formatMessage(messages[pdc.pdc_type])}
@@ -113,7 +113,7 @@ const PuntoDiContattoView = (props) => {
113
113
  <span className="ms-1">
114
114
  {renderPDCItemValue(pdc, intl)}
115
115
  </span>
116
- </h5>
116
+ </p>
117
117
  </div>
118
118
  );
119
119
  })}
@@ -39,7 +39,7 @@ const VenueWhere = ({ content }) => {
39
39
  <Card className="card card-teaser border-left-card preview-image-card card-big-io-comune shadow mt-3 rounded mb-4">
40
40
  <CardBody>
41
41
  <CardTitle>
42
- <h5 className="card-title">{content.title}</h5>
42
+ <h3 className="h5 card-title">{content.title}</h3>
43
43
  </CardTitle>
44
44
  <CardText>
45
45
  <p>
@@ -0,0 +1,75 @@
1
+ // CUSTOMIZATION:
2
+ // - Added condition to check if user is SPID user (16-18 and 21)
3
+
4
+ import { useEffect } from 'react';
5
+ import { useSelector } from 'react-redux';
6
+ import PropTypes from 'prop-types';
7
+ import { useHistory } from 'react-router-dom';
8
+ import { isInternalURL, flattenToAppURL } from '@plone/volto/helpers';
9
+ import { Container as SemanticContainer } from 'semantic-ui-react';
10
+ import { UniversalLink } from '@plone/volto/components';
11
+ import { FormattedMessage } from 'react-intl';
12
+ import config from '@plone/volto/registry';
13
+
14
+ const LinkView = ({ token, content }) => {
15
+ const history = useHistory();
16
+ const userIsSpidUser = useSelector(
17
+ (state) => state.users.user.roles.length === 0,
18
+ );
19
+
20
+ useEffect(() => {
21
+ if (!token || userIsSpidUser) {
22
+ const { remoteUrl } = content;
23
+ if (isInternalURL(remoteUrl)) {
24
+ history.replace(flattenToAppURL(remoteUrl));
25
+ } else if (!__SERVER__) {
26
+ window.location.href = flattenToAppURL(remoteUrl);
27
+ }
28
+ }
29
+ }, [content, history, token, userIsSpidUser]);
30
+ const { title, description, remoteUrl } = content;
31
+ const { openExternalLinkInNewTab } = config.settings;
32
+ const Container =
33
+ config.getComponent({ name: 'Container' }).component || SemanticContainer;
34
+
35
+ return (
36
+ <Container id="page-document">
37
+ <h1 className="documentFirstHeading">{title}</h1>
38
+ {content.description && (
39
+ <p className="documentDescription">{description}</p>
40
+ )}
41
+ {remoteUrl && (
42
+ <p>
43
+ <FormattedMessage
44
+ id="The link address is:"
45
+ defaultMessage="The link address is:"
46
+ />{' '}
47
+ <UniversalLink
48
+ href={remoteUrl}
49
+ openLinkInNewTab={
50
+ openExternalLinkInNewTab && !isInternalURL(remoteUrl)
51
+ }
52
+ >
53
+ {flattenToAppURL(remoteUrl)}
54
+ </UniversalLink>
55
+ </p>
56
+ )}
57
+ </Container>
58
+ );
59
+ };
60
+
61
+ LinkView.propTypes = {
62
+ content: PropTypes.shape({
63
+ title: PropTypes.string,
64
+ description: PropTypes.string,
65
+ remoteUrl: PropTypes.string,
66
+ }),
67
+ token: PropTypes.string,
68
+ };
69
+
70
+ LinkView.defaultProps = {
71
+ content: null,
72
+ token: null,
73
+ };
74
+
75
+ export default LinkView;
@@ -49,11 +49,6 @@
49
49
  outline: none;
50
50
  vertical-align: baseline;
51
51
 
52
- input:focus ~ label::before {
53
- box-shadow: $gdpr-focus-shadow !important;
54
- outline: none !important;
55
- }
56
-
57
52
  label {
58
53
  position: relative;
59
54
  display: block;
@@ -240,19 +235,6 @@ body.has-toolbar-collapsed {
240
235
  }
241
236
  }
242
237
 
243
- .gdpr-privacy-banner
244
- .gdpr-privacy-content-wrapper
245
- .gdpr-privacy-content
246
- .buttons
247
- button.gdpr-privacy-banner-button:focus,
248
- .gdpr-privacy-banner
249
- .gdpr-privacy-content-wrapper
250
- .gdpr-privacy-content
251
- a:focus {
252
- box-shadow: $gdpr-focus-shadow;
253
- outline: none !important;
254
- }
255
-
256
238
  .gdpr-privacy-banner
257
239
  .gdpr-privacy-content-wrapper
258
240
  .gdpr-privacy-content
@@ -15,7 +15,8 @@
15
15
  min-width: 150px;
16
16
 
17
17
  &:focus-within {
18
- box-shadow: 0 0 0 2px $focus-outline-color;
18
+ border: 2px solid $inner-focus-border !important;
19
+ box-shadow: 0 0 0 2px $outer-focus-outline !important;
19
20
  }
20
21
 
21
22
  .react-select__control {
@@ -57,7 +58,8 @@
57
58
  }
58
59
 
59
60
  &.DateInput_input__focused {
60
- box-shadow: 0 0 0 2px $focus-outline-color;
61
+ border: 2px solid $inner-focus-border !important;
62
+ box-shadow: 0 0 0 2px $outer-focus-outline !important;
61
63
  }
62
64
  }
63
65
 
@@ -20,6 +20,7 @@
20
20
  .react-select__control,
21
21
  .react-select__control:hover {
22
22
  &.react-select__control--is-focused {
23
- box-shadow: 0 0 0 2px $focus-outline-color !important;
23
+ border: 2px solid $inner-focus-border !important;
24
+ box-shadow: 0 0 0 2px $outer-focus-outline !important;
24
25
  }
25
26
  }
@@ -7,11 +7,8 @@
7
7
  button.btn,
8
8
  button.rounded-right {
9
9
  &:focus {
10
- border-color: $focus-outline-color !important;
11
- box-shadow:
12
- inset 0 1px 0 $focus-outline-color,
13
- 0 1px 1px $focus-outline-color,
14
- 0 0 0 0.2rem $focus-outline-color !important;
10
+ border: 2px solid $inner-focus-border !important;
11
+ box-shadow: 0 0 0 2px $outer-focus-outline !important;
15
12
  outline: none;
16
13
  }
17
14
  }
@@ -30,12 +30,7 @@ $gdpr-accept-all: #005700 !default;
30
30
  $gdpr-toggle-checked: #005700 !default;
31
31
  $gdpr-toggle: #b22515 !default;
32
32
  $gdpr-toggle-border: #000 !default;
33
- $gdpr-focus-color: #ff9800 !default;
34
33
  $gdpr-link-color: #004285 !default;
35
- $gdpr-focus-shadow:
36
- inset 0 1px 0 rgba(255, 255, 255, 0.15),
37
- 0 1px 1px rgba(0, 0, 0, 0.075),
38
- 0 0 0 0.2rem $gdpr-focus-color !default;
39
34
 
40
35
  $caption-text: #455b71 !default;
41
36
 
@@ -63,3 +58,7 @@ $dvt-navigation-v-padding: 15px !default;
63
58
  $spacer: 16px;
64
59
  $ribbon-spacing-h: calc($spacer * 3);
65
60
  $ribbon-width: calc($spacer * 2);
61
+
62
+ // accessible focus colors
63
+ $outer-focus-outline: #000 !default;
64
+ $inner-focus-border: #fff !default;
@@ -1,3 +1,9 @@
1
+ :focus:not(.focus--mouse),
2
+ %focus {
3
+ box-shadow: 0 0 0 2px $outer-focus-outline !important;
4
+ border: 2px solid $inner-focus-border !important;
5
+ }
6
+
1
7
  .skiplinks a:focus:not(.focus--mouse) {
2
8
  border: 2px solid;
3
9
  }
@@ -15,10 +15,11 @@
15
15
 
16
16
  .it-search-wrapper {
17
17
  a.search-link {
18
- outline: $header-center-bg-color 2px solid !important;
18
+ border: $header-center-bg-color 2px solid !important;
19
19
 
20
20
  &:focus {
21
- box-shadow: 0 0 0 5px $focus-outline-color !important;
21
+ outline: 2.5px solid $inner-focus-border !important;
22
+ box-shadow: 0 0 0 5px $outer-focus-outline !important;
22
23
  }
23
24
  }
24
25
  }