design-comuni-plone-theme 11.24.5 → 11.25.0
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/.yarn/install-state.gz +0 -0
- package/CHANGELOG.md +38 -0
- package/RELEASE.md +13 -0
- package/locales/de/LC_MESSAGES/volto.po +6 -0
- package/locales/en/LC_MESSAGES/volto.po +6 -0
- package/locales/es/LC_MESSAGES/volto.po +6 -0
- package/locales/fr/LC_MESSAGES/volto.po +6 -0
- package/locales/it/LC_MESSAGES/volto.po +6 -0
- package/locales/volto.pot +7 -1
- package/package.json +1 -1
- package/publiccode.yml +2 -2
- package/src/components/ImageWithErrors/ImageWithErrors.jsx +18 -0
- package/src/components/ItaliaTheme/Blocks/EventSearch/Body.jsx +5 -1
- package/src/components/ItaliaTheme/Blocks/EventSearch/Sidebar.jsx +16 -5
- package/src/components/ItaliaTheme/Blocks/UOSearch/Body.jsx +5 -1
- package/src/components/ItaliaTheme/Blocks/UOSearch/Sidebar.jsx +16 -0
- package/src/components/ItaliaTheme/Header/HeaderSearch/SearchModal.jsx +11 -3
- package/src/components/ItaliaTheme/View/BandoView/BandoApprofondimenti.jsx +1 -1
- package/src/components/ItaliaTheme/View/Commons/Events.jsx +6 -3
- package/src/components/ItaliaTheme/View/Commons/LocationsMap.jsx +4 -18
- package/src/components/ItaliaTheme/View/Commons/Module.jsx +18 -33
- package/src/components/ItaliaTheme/View/Commons/Modules.jsx +3 -1
- package/src/components/ItaliaTheme/View/Commons/PageHeader/PageHeaderDates.jsx +0 -10
- package/src/components/ItaliaTheme/View/PaginaArgomentoView/PaginaArgomentoView.jsx +13 -34
- package/src/config/italiaConfig.js +4 -1
- package/src/theme/extras/_modals.scss +13 -0
package/.yarn/install-state.gz
CHANGED
|
Binary file
|
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,43 @@
|
|
|
1
1
|
|
|
2
2
|
|
|
3
|
+
## [11.25.0](https://github.com/RedTurtle/design-comuni-plone-theme/compare/v11.24.6...v11.25.0) (2024-11-26)
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
### Features
|
|
7
|
+
|
|
8
|
+
* added cardCalendar in children events for rassegne ([#817](https://github.com/RedTurtle/design-comuni-plone-theme/issues/817)) ([b2897c6](https://github.com/RedTurtle/design-comuni-plone-theme/commit/b2897c6e9bfc2a0f685fa8728ec64f3c5a6a060d))
|
|
9
|
+
* added checkbox for showing image for all cards in eventsSearch ([#815](https://github.com/RedTurtle/design-comuni-plone-theme/issues/815)) ([ba75e5b](https://github.com/RedTurtle/design-comuni-plone-theme/commit/ba75e5b4c403f362fbabd7e8638c5871832cf115))
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
### Bug Fixes
|
|
13
|
+
|
|
14
|
+
* no close search popup when loading results ([#819](https://github.com/RedTurtle/design-comuni-plone-theme/issues/819)) ([850da9d](https://github.com/RedTurtle/design-comuni-plone-theme/commit/850da9d2a1d00b427f8820ffea24f7a8b005730e))
|
|
15
|
+
* removed expiration date from event header ([#813](https://github.com/RedTurtle/design-comuni-plone-theme/issues/813)) ([93025d9](https://github.com/RedTurtle/design-comuni-plone-theme/commit/93025d9d1555a6b7921974a408dc9bdb398382a8))
|
|
16
|
+
* replace not found img message with placeholder image ([#809](https://github.com/RedTurtle/design-comuni-plone-theme/issues/809)) ([725d743](https://github.com/RedTurtle/design-comuni-plone-theme/commit/725d74314de67091018cc882c6a0e00c8536b23a))
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
### Maintenance
|
|
20
|
+
|
|
21
|
+
* realign release.md ([716d921](https://github.com/RedTurtle/design-comuni-plone-theme/commit/716d9217f490e877b57691b661d6e0f8a0499150))
|
|
22
|
+
|
|
23
|
+
|
|
24
|
+
### Documentation
|
|
25
|
+
|
|
26
|
+
* updated publiccode and release log ([330965d](https://github.com/RedTurtle/design-comuni-plone-theme/commit/330965d6cb03a0da9a0522545b4f0f9e7cc73c0d))
|
|
27
|
+
* updated publiccode and release log ([ef30dd0](https://github.com/RedTurtle/design-comuni-plone-theme/commit/ef30dd0f4a03d1794eb8f741579f8cdc4cc62876))
|
|
28
|
+
|
|
29
|
+
## [11.24.6](https://github.com/RedTurtle/design-comuni-plone-theme/compare/v11.24.5...v11.24.6) (2024-11-22)
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
### Bug Fixes
|
|
33
|
+
|
|
34
|
+
* removed getContent from Documento, Bando, Argomento and LocationsMap ([#803](https://github.com/RedTurtle/design-comuni-plone-theme/issues/803)) ([ca1f0f0](https://github.com/RedTurtle/design-comuni-plone-theme/commit/ca1f0f0b0e8b02d2a50d420e2aa371c97517a8f9))
|
|
35
|
+
|
|
36
|
+
|
|
37
|
+
### Documentation
|
|
38
|
+
|
|
39
|
+
* updated publiccode ([ebcf3d0](https://github.com/RedTurtle/design-comuni-plone-theme/commit/ebcf3d05408cc5e175e9f610ba752b53d28082b9))
|
|
40
|
+
|
|
3
41
|
## [11.24.5](https://github.com/RedTurtle/design-comuni-plone-theme/compare/v11.24.4...v11.24.5) (2024-11-22)
|
|
4
42
|
|
|
5
43
|
|
package/RELEASE.md
CHANGED
|
@@ -41,6 +41,19 @@
|
|
|
41
41
|
- ...
|
|
42
42
|
-->
|
|
43
43
|
|
|
44
|
+
## Versione 11.25.0 (26/11/2024)
|
|
45
|
+
|
|
46
|
+
### Migliorie
|
|
47
|
+
|
|
48
|
+
- Rimossa dal CT Evento la data di scadenza del CT per evitare confusione con le date effettive dell'evento
|
|
49
|
+
- Durante la ricerca nel sito dalla popup che compare cliccando sul bottone 'Cerca' nella testa del sito, viene mostrato un loader in overlay durante il caricamento della pagina dei risultati perchè questo potrebbe richiedere un po' di tempo. Prima di questa modifica non era chiaro se la ricerca fosse iniziata.
|
|
50
|
+
- Nel CT Evento per una rassegna, se gli eventi figli hanno una ricorrenza o un periodo di date impostato, il range di date verrà mostrato nella card all'interno dell'evento padre.
|
|
51
|
+
- Se l'url di una immagine è rotto, viene mostrato un avviso al posto dell'immagine rotta.
|
|
52
|
+
|
|
53
|
+
### Novità
|
|
54
|
+
|
|
55
|
+
- E' ora possibile decidere se mostrare l'immagine di anteprima per tutte le card nel blocco di ricerca Evento e Unità Organizzativa.
|
|
56
|
+
|
|
44
57
|
## Versione 11.24.5 (22/11/2024)
|
|
45
58
|
|
|
46
59
|
### Migliorie
|
|
@@ -3188,6 +3188,12 @@ msgstr ""
|
|
|
3188
3188
|
msgid "searchBlock"
|
|
3189
3189
|
msgstr ""
|
|
3190
3190
|
|
|
3191
|
+
#: components/ItaliaTheme/Blocks/EventSearch/Sidebar
|
|
3192
|
+
#: components/ItaliaTheme/Blocks/UOSearch/Sidebar
|
|
3193
|
+
# defaultMessage: Mostra l'immagine per tutti gli elementi
|
|
3194
|
+
msgid "searchBlock_always_show_image"
|
|
3195
|
+
msgstr ""
|
|
3196
|
+
|
|
3191
3197
|
#: components/ItaliaTheme/Blocks/BandiSearch/Sidebar
|
|
3192
3198
|
#: components/ItaliaTheme/Blocks/EventSearch/Sidebar
|
|
3193
3199
|
#: components/ItaliaTheme/Blocks/UOSearch/Sidebar
|
|
@@ -3173,6 +3173,12 @@ msgstr "Search by all topics"
|
|
|
3173
3173
|
msgid "searchBlock"
|
|
3174
3174
|
msgstr ""
|
|
3175
3175
|
|
|
3176
|
+
#: components/ItaliaTheme/Blocks/EventSearch/Sidebar
|
|
3177
|
+
#: components/ItaliaTheme/Blocks/UOSearch/Sidebar
|
|
3178
|
+
# defaultMessage: Mostra l'immagine per tutti gli elementi
|
|
3179
|
+
msgid "searchBlock_always_show_image"
|
|
3180
|
+
msgstr "Show image for every card"
|
|
3181
|
+
|
|
3176
3182
|
#: components/ItaliaTheme/Blocks/BandiSearch/Sidebar
|
|
3177
3183
|
#: components/ItaliaTheme/Blocks/EventSearch/Sidebar
|
|
3178
3184
|
#: components/ItaliaTheme/Blocks/UOSearch/Sidebar
|
|
@@ -3182,6 +3182,12 @@ msgstr "Buscar por todos los temas"
|
|
|
3182
3182
|
msgid "searchBlock"
|
|
3183
3183
|
msgstr "Búsqueda de eventos"
|
|
3184
3184
|
|
|
3185
|
+
#: components/ItaliaTheme/Blocks/EventSearch/Sidebar
|
|
3186
|
+
#: components/ItaliaTheme/Blocks/UOSearch/Sidebar
|
|
3187
|
+
# defaultMessage: Mostra l'immagine per tutti gli elementi
|
|
3188
|
+
msgid "searchBlock_always_show_image"
|
|
3189
|
+
msgstr ""
|
|
3190
|
+
|
|
3185
3191
|
#: components/ItaliaTheme/Blocks/BandiSearch/Sidebar
|
|
3186
3192
|
#: components/ItaliaTheme/Blocks/EventSearch/Sidebar
|
|
3187
3193
|
#: components/ItaliaTheme/Blocks/UOSearch/Sidebar
|
|
@@ -3190,6 +3190,12 @@ msgstr "Rechercher tous les sujets"
|
|
|
3190
3190
|
msgid "searchBlock"
|
|
3191
3191
|
msgstr ""
|
|
3192
3192
|
|
|
3193
|
+
#: components/ItaliaTheme/Blocks/EventSearch/Sidebar
|
|
3194
|
+
#: components/ItaliaTheme/Blocks/UOSearch/Sidebar
|
|
3195
|
+
# defaultMessage: Mostra l'immagine per tutti gli elementi
|
|
3196
|
+
msgid "searchBlock_always_show_image"
|
|
3197
|
+
msgstr ""
|
|
3198
|
+
|
|
3193
3199
|
#: components/ItaliaTheme/Blocks/BandiSearch/Sidebar
|
|
3194
3200
|
#: components/ItaliaTheme/Blocks/EventSearch/Sidebar
|
|
3195
3201
|
#: components/ItaliaTheme/Blocks/UOSearch/Sidebar
|
|
@@ -3173,6 +3173,12 @@ msgstr "Cerca tutti gli argomenti"
|
|
|
3173
3173
|
msgid "searchBlock"
|
|
3174
3174
|
msgstr "Ricerca eventi"
|
|
3175
3175
|
|
|
3176
|
+
#: components/ItaliaTheme/Blocks/EventSearch/Sidebar
|
|
3177
|
+
#: components/ItaliaTheme/Blocks/UOSearch/Sidebar
|
|
3178
|
+
# defaultMessage: Mostra l'immagine per tutti gli elementi
|
|
3179
|
+
msgid "searchBlock_always_show_image"
|
|
3180
|
+
msgstr ""
|
|
3181
|
+
|
|
3176
3182
|
#: components/ItaliaTheme/Blocks/BandiSearch/Sidebar
|
|
3177
3183
|
#: components/ItaliaTheme/Blocks/EventSearch/Sidebar
|
|
3178
3184
|
#: components/ItaliaTheme/Blocks/UOSearch/Sidebar
|
package/locales/volto.pot
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
msgid ""
|
|
2
2
|
msgstr ""
|
|
3
3
|
"Project-Id-Version: Plone\n"
|
|
4
|
-
"POT-Creation-Date: 2024-
|
|
4
|
+
"POT-Creation-Date: 2024-11-25T14:46:11.571Z\n"
|
|
5
5
|
"Last-Translator: Plone i18n <plone-i18n@lists.sourceforge.net>\n"
|
|
6
6
|
"Language-Team: Plone i18n <plone-i18n@lists.sourceforge.net>\n"
|
|
7
7
|
"MIME-Version: 1.0\n"
|
|
@@ -3175,6 +3175,12 @@ msgstr ""
|
|
|
3175
3175
|
msgid "searchBlock"
|
|
3176
3176
|
msgstr ""
|
|
3177
3177
|
|
|
3178
|
+
#: components/ItaliaTheme/Blocks/EventSearch/Sidebar
|
|
3179
|
+
#: components/ItaliaTheme/Blocks/UOSearch/Sidebar
|
|
3180
|
+
# defaultMessage: Mostra l'immagine per tutti gli elementi
|
|
3181
|
+
msgid "searchBlock_always_show_image"
|
|
3182
|
+
msgstr ""
|
|
3183
|
+
|
|
3178
3184
|
#: components/ItaliaTheme/Blocks/BandiSearch/Sidebar
|
|
3179
3185
|
#: components/ItaliaTheme/Blocks/EventSearch/Sidebar
|
|
3180
3186
|
#: components/ItaliaTheme/Blocks/UOSearch/Sidebar
|
package/package.json
CHANGED
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-11-
|
|
230
|
+
releaseDate: '2024-11-26'
|
|
231
231
|
softwareType: standalone/web
|
|
232
|
-
softwareVersion: 11.
|
|
232
|
+
softwareVersion: 11.25.0
|
|
233
233
|
url: 'https://github.com/italia/design-comuni-plone-theme'
|
|
234
234
|
usedBy:
|
|
235
235
|
- ASP Comuni Modenesi Area Nord
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
|
|
3
|
+
import { Image } from '@plone/volto/components';
|
|
4
|
+
|
|
5
|
+
const ImageWithErrors = (props) => {
|
|
6
|
+
return (
|
|
7
|
+
<Image
|
|
8
|
+
{...props}
|
|
9
|
+
onError={({ currentTarget }) => {
|
|
10
|
+
currentTarget.onerror = null; // prevents looping
|
|
11
|
+
currentTarget.src =
|
|
12
|
+
'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAA8AAAAMcCAMAAACo9Dz9AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyFpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuNS1jMDE0IDc5LjE1MTQ4MSwgMjAxMy8wMy8xMy0xMjowOToxNSAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvIiB4bWxuczp4bXBNTT0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL21tLyIgeG1sbnM6c3RSZWY9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9zVHlwZS9SZXNvdXJjZVJlZiMiIHhtcDpDcmVhdG9yVG9vbD0iQWRv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EsCSAJQEsASwJYEkASwBLAlgSwJIAlgCWBLAkgCUBLAEsCWBJAEsASwJYEsCSAJYAlgSwJIAlASwBLAlgSQBLAEsCWBLAkgCWAJYEsCSAJYAlASwJYEkASwBLAlgSwJIAlgCWBLAkgCWAJQEsCWBJAEsASwJYEsCSAJYAlgSwJIAlgCUBLAlgSQBLAEsCWBLAkgCWAJb0MJU+Amlu+38MX/XOo4IBUwAAAABJRU5ErkJggg==';
|
|
13
|
+
currentTarget.style = 'max-width: 200px;';
|
|
14
|
+
}}
|
|
15
|
+
/>
|
|
16
|
+
);
|
|
17
|
+
};
|
|
18
|
+
export default ImageWithErrors;
|
|
@@ -234,7 +234,11 @@ const Body = ({ data, id, inEditMode, path, onChangeBlock }) => {
|
|
|
234
234
|
items?.length > 0 ? (
|
|
235
235
|
<div className="mt-4" ref={resultsRef} aria-live="polite">
|
|
236
236
|
<div className="block listing">
|
|
237
|
-
<CardWithImageTemplate
|
|
237
|
+
<CardWithImageTemplate
|
|
238
|
+
items={items}
|
|
239
|
+
full_width={false}
|
|
240
|
+
always_show_image={data.always_show_image}
|
|
241
|
+
/>
|
|
238
242
|
</div>
|
|
239
243
|
{querystringResults.total > b_size && (
|
|
240
244
|
<Pagination
|
|
@@ -75,6 +75,10 @@ const messages = defineMessages({
|
|
|
75
75
|
id: 'searchBlock_show_default_results',
|
|
76
76
|
defaultMessage: 'Di default, mostra i risultati',
|
|
77
77
|
},
|
|
78
|
+
always_show_image: {
|
|
79
|
+
id: 'searchBlock_always_show_image',
|
|
80
|
+
defaultMessage: "Mostra l'immagine per tutti gli elementi",
|
|
81
|
+
},
|
|
78
82
|
});
|
|
79
83
|
|
|
80
84
|
const Sidebar = (props) => {
|
|
@@ -161,11 +165,18 @@ const Sidebar = (props) => {
|
|
|
161
165
|
<CheckboxWidget
|
|
162
166
|
id="show_default_results"
|
|
163
167
|
title={props.intl.formatMessage(messages.show_default_results)}
|
|
164
|
-
value={
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
168
|
+
value={props.data.show_default_results}
|
|
169
|
+
onChange={(id, value) => {
|
|
170
|
+
props.onChangeBlock(props.block, {
|
|
171
|
+
...props.data,
|
|
172
|
+
[id]: value,
|
|
173
|
+
});
|
|
174
|
+
}}
|
|
175
|
+
/>
|
|
176
|
+
<CheckboxWidget
|
|
177
|
+
id="always_show_image"
|
|
178
|
+
title={props.intl.formatMessage(messages.always_show_image)}
|
|
179
|
+
value={props.data.always_show_image}
|
|
169
180
|
onChange={(id, value) => {
|
|
170
181
|
props.onChangeBlock(props.block, {
|
|
171
182
|
...props.data,
|
|
@@ -211,7 +211,11 @@ const Body = ({ data, id, inEditMode, path, onChangeBlock }) => {
|
|
|
211
211
|
items?.length > 0 ? (
|
|
212
212
|
<div className="mt-4" ref={resultsRef} aria-live="polite">
|
|
213
213
|
<div className="block listing">
|
|
214
|
-
<CardWithImageTemplate
|
|
214
|
+
<CardWithImageTemplate
|
|
215
|
+
items={items}
|
|
216
|
+
full_width={false}
|
|
217
|
+
always_show_image={data.always_show_image}
|
|
218
|
+
/>
|
|
215
219
|
</div>
|
|
216
220
|
{querystringResults.total > b_size && (
|
|
217
221
|
<Pagination
|
|
@@ -6,6 +6,7 @@ import {
|
|
|
6
6
|
SelectWidget,
|
|
7
7
|
Icon,
|
|
8
8
|
ObjectBrowserWidget,
|
|
9
|
+
CheckboxWidget,
|
|
9
10
|
} from '@plone/volto/components';
|
|
10
11
|
import upSVG from '@plone/volto/icons/up-key.svg';
|
|
11
12
|
import downSVG from '@plone/volto/icons/down-key.svg';
|
|
@@ -72,6 +73,10 @@ const messages = defineMessages({
|
|
|
72
73
|
id: 'searchBlock_date_filter',
|
|
73
74
|
defaultMessage: 'Filtro per date',
|
|
74
75
|
},
|
|
76
|
+
always_show_image: {
|
|
77
|
+
id: 'searchBlock_always_show_image',
|
|
78
|
+
defaultMessage: "Mostra l'immagine per tutti gli elementi",
|
|
79
|
+
},
|
|
75
80
|
});
|
|
76
81
|
|
|
77
82
|
const Sidebar = (props) => {
|
|
@@ -154,6 +159,17 @@ const Sidebar = (props) => {
|
|
|
154
159
|
}}
|
|
155
160
|
/>
|
|
156
161
|
</div>
|
|
162
|
+
<CheckboxWidget
|
|
163
|
+
id="always_show_image"
|
|
164
|
+
title={props.intl.formatMessage(messages.always_show_image)}
|
|
165
|
+
value={props.data.always_show_image}
|
|
166
|
+
onChange={(id, value) => {
|
|
167
|
+
props.onChangeBlock(props.block, {
|
|
168
|
+
...props.data,
|
|
169
|
+
[id]: value,
|
|
170
|
+
});
|
|
171
|
+
}}
|
|
172
|
+
/>
|
|
157
173
|
</Segment>
|
|
158
174
|
<Accordion fluid styled className="form">
|
|
159
175
|
<Accordion.Title
|
|
@@ -28,6 +28,7 @@ import {
|
|
|
28
28
|
Input,
|
|
29
29
|
Label,
|
|
30
30
|
Toggle,
|
|
31
|
+
Spinner,
|
|
31
32
|
} from 'design-react-kit';
|
|
32
33
|
|
|
33
34
|
import { Icon } from 'design-comuni-plone-theme/components/ItaliaTheme';
|
|
@@ -173,6 +174,7 @@ const SearchModal = ({ closeModal, show }) => {
|
|
|
173
174
|
const dispatch = useDispatch();
|
|
174
175
|
const location = useLocation();
|
|
175
176
|
|
|
177
|
+
const [redirectingToResults, setRedirectingToResults] = useState(false);
|
|
176
178
|
const [advancedSearch, setAdvancedSearch] = useState(false);
|
|
177
179
|
const [advancedTab, setAdvancedTab] = useState(null);
|
|
178
180
|
const [searchableText, setSearchableText] = useState(
|
|
@@ -296,10 +298,11 @@ const SearchModal = ({ closeModal, show }) => {
|
|
|
296
298
|
setOptions((prevOptions) => ({ ...prevOptions, [optId]: value }));
|
|
297
299
|
|
|
298
300
|
const submitSearch = () => {
|
|
301
|
+
setRedirectingToResults(true);
|
|
299
302
|
setAdvancedSearch(false);
|
|
300
|
-
setTimeout(() => {
|
|
301
|
-
|
|
302
|
-
}, 500);
|
|
303
|
+
// setTimeout(() => {
|
|
304
|
+
// closeModal();
|
|
305
|
+
// }, 500);
|
|
303
306
|
};
|
|
304
307
|
|
|
305
308
|
const handleEnterSearch = (e) => {
|
|
@@ -923,6 +926,11 @@ const SearchModal = ({ closeModal, show }) => {
|
|
|
923
926
|
</div>
|
|
924
927
|
)}
|
|
925
928
|
</Container>
|
|
929
|
+
{redirectingToResults && (
|
|
930
|
+
<div className="overlay loading-results">
|
|
931
|
+
<Spinner active />
|
|
932
|
+
</div>
|
|
933
|
+
)}
|
|
926
934
|
</ModalBody>
|
|
927
935
|
</Modal>
|
|
928
936
|
);
|
|
@@ -34,7 +34,7 @@ const BandoApprofondimenti = ({ content }) => {
|
|
|
34
34
|
/>
|
|
35
35
|
// item={item} viene utilizzato nelle customizzazioni per ottenere altre proprietà
|
|
36
36
|
);
|
|
37
|
-
} else if (item.type === '
|
|
37
|
+
} else if (item.type === 'Collegamento') {
|
|
38
38
|
return (
|
|
39
39
|
<Card
|
|
40
40
|
className="card card-teaser shadow p-4 mt-3 rounded attachment"
|
|
@@ -6,6 +6,7 @@ import { UniversalLink } from '@plone/volto/components';
|
|
|
6
6
|
import { flattenToAppURL } from '@plone/volto/helpers';
|
|
7
7
|
import { RichTextSection } from 'design-comuni-plone-theme/components/ItaliaTheme/View';
|
|
8
8
|
import { viewDate } from 'design-comuni-plone-theme/helpers';
|
|
9
|
+
import { CardCalendar } from 'design-comuni-plone-theme/components/ItaliaTheme';
|
|
9
10
|
|
|
10
11
|
const messages = defineMessages({
|
|
11
12
|
events: {
|
|
@@ -41,9 +42,11 @@ const SubEvent = ({ event, show_image }) => {
|
|
|
41
42
|
/>
|
|
42
43
|
</figure>
|
|
43
44
|
{event.start && (
|
|
44
|
-
<
|
|
45
|
-
{
|
|
46
|
-
|
|
45
|
+
<CardCalendar
|
|
46
|
+
start={event.start}
|
|
47
|
+
end={event.end}
|
|
48
|
+
recurrence={event.recurrence}
|
|
49
|
+
/>
|
|
47
50
|
)}
|
|
48
51
|
</div>
|
|
49
52
|
</div>
|
|
@@ -1,7 +1,5 @@
|
|
|
1
|
-
import
|
|
2
|
-
import React, { useEffect } from 'react';
|
|
1
|
+
import React from 'react';
|
|
3
2
|
import { useIntl, defineMessages } from 'react-intl';
|
|
4
|
-
import { getContent, resetContent } from '@plone/volto/actions';
|
|
5
3
|
import { flattenToAppURL } from '@plone/volto/helpers';
|
|
6
4
|
import { OSMMap } from 'volto-venue';
|
|
7
5
|
import PropTypes from 'prop-types';
|
|
@@ -30,9 +28,7 @@ const messages = defineMessages({
|
|
|
30
28
|
});
|
|
31
29
|
|
|
32
30
|
const LocationsMap = ({ center, locations }) => {
|
|
33
|
-
const dispatch = useDispatch();
|
|
34
31
|
const intl = useIntl();
|
|
35
|
-
const fetchedLocations = useSelector((state) => state.content.subrequests);
|
|
36
32
|
const venues = locations.map((location) => {
|
|
37
33
|
let url = flattenToAppURL(location['@id']);
|
|
38
34
|
return {
|
|
@@ -41,18 +37,6 @@ const LocationsMap = ({ center, locations }) => {
|
|
|
41
37
|
};
|
|
42
38
|
});
|
|
43
39
|
|
|
44
|
-
useEffect(() => {
|
|
45
|
-
venues.forEach((loc) => {
|
|
46
|
-
dispatch(getContent(loc.url, null, loc.key));
|
|
47
|
-
});
|
|
48
|
-
|
|
49
|
-
return () =>
|
|
50
|
-
venues.forEach((loc) => {
|
|
51
|
-
dispatch(resetContent(loc.key));
|
|
52
|
-
});
|
|
53
|
-
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
54
|
-
}, [dispatch, locations]);
|
|
55
|
-
|
|
56
40
|
const pinContent = (item) => {
|
|
57
41
|
return (
|
|
58
42
|
<div className="map-pin-popup">
|
|
@@ -97,7 +81,9 @@ const LocationsMap = ({ center, locations }) => {
|
|
|
97
81
|
};
|
|
98
82
|
|
|
99
83
|
let venuesData = venues.reduce((acc, val) => {
|
|
100
|
-
let venue =
|
|
84
|
+
let venue = locations.find((el) => {
|
|
85
|
+
return el['@id'].includes(val.url);
|
|
86
|
+
});
|
|
101
87
|
|
|
102
88
|
if (venue?.geolocation?.latitude && venue?.geolocation?.longitude) {
|
|
103
89
|
return [
|
|
@@ -3,12 +3,9 @@
|
|
|
3
3
|
* @module components/theme/View/DocumentoView/Modules
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import React
|
|
7
|
-
import { useDispatch, useSelector } from 'react-redux';
|
|
6
|
+
import React from 'react';
|
|
8
7
|
import PropTypes from 'prop-types';
|
|
9
|
-
import { flattenToAppURL } from '@plone/volto/helpers';
|
|
10
8
|
import { UniversalLink } from '@plone/volto/components';
|
|
11
|
-
import { getContent, resetContent } from '@plone/volto/actions';
|
|
12
9
|
|
|
13
10
|
import { Card, CardBody, CardTitle } from 'design-react-kit';
|
|
14
11
|
|
|
@@ -21,20 +18,7 @@ import { DownloadFileFormat } from 'design-comuni-plone-theme/components/ItaliaT
|
|
|
21
18
|
* @returns {string} Markup of the component.
|
|
22
19
|
*/
|
|
23
20
|
const Module = ({ item }) => {
|
|
24
|
-
|
|
25
|
-
const subrequests = useSelector((state) => state.content.subrequests);
|
|
26
|
-
const url = flattenToAppURL(item['@id']);
|
|
27
|
-
const key = 'module_' + url;
|
|
28
|
-
|
|
29
|
-
useEffect(() => {
|
|
30
|
-
dispatch(getContent(url, null, key));
|
|
31
|
-
return () => dispatch(resetContent(key));
|
|
32
|
-
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
33
|
-
}, [key]);
|
|
34
|
-
|
|
35
|
-
let modulo = subrequests?.[key]?.data;
|
|
36
|
-
|
|
37
|
-
return modulo ? (
|
|
21
|
+
return item ? (
|
|
38
22
|
<Card
|
|
39
23
|
className="card card-teaser shadow p-4 mt-3 rounded modulo"
|
|
40
24
|
noWrapper={true}
|
|
@@ -42,37 +26,38 @@ const Module = ({ item }) => {
|
|
|
42
26
|
>
|
|
43
27
|
<CardBody tag="div">
|
|
44
28
|
<CardTitle className="h5">
|
|
45
|
-
{
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
{modulo.title ?? modulo.file_principale.filename}
|
|
51
|
-
</a>
|
|
52
|
-
) : modulo['@type'] === 'Link' ? (
|
|
53
|
-
<UniversalLink item={modulo} title={modulo.title}>
|
|
54
|
-
{modulo.title}
|
|
29
|
+
{item.file_principale ? (
|
|
30
|
+
item.title ?? item.file_principale.filename
|
|
31
|
+
) : item['@type'] === 'Link' ? (
|
|
32
|
+
<UniversalLink item={item} title={item.title}>
|
|
33
|
+
{item.title}
|
|
55
34
|
</UniversalLink>
|
|
56
35
|
) : (
|
|
57
|
-
|
|
36
|
+
item.title
|
|
58
37
|
)}
|
|
59
38
|
</CardTitle>
|
|
60
39
|
|
|
61
|
-
{
|
|
40
|
+
{item.description && <p>{item.description}</p>}
|
|
62
41
|
<div className="download-formats">
|
|
63
42
|
<DownloadFileFormat
|
|
64
|
-
file={
|
|
43
|
+
file={item.file_principale}
|
|
65
44
|
showLabel={true}
|
|
45
|
+
title={item.title ?? item.file_principale.filename}
|
|
46
|
+
hideFileFormatLabel={true}
|
|
66
47
|
className="mb-4"
|
|
67
48
|
/>
|
|
68
49
|
<DownloadFileFormat
|
|
69
|
-
file={
|
|
50
|
+
file={item.formato_alternativo_1}
|
|
70
51
|
showLabel={true}
|
|
52
|
+
title={item.title ?? item.formato_alternativo_1.filename}
|
|
53
|
+
hideFileFormatLabel={true}
|
|
71
54
|
className="mb-4"
|
|
72
55
|
/>
|
|
73
56
|
<DownloadFileFormat
|
|
74
|
-
file={
|
|
57
|
+
file={item.formato_alternativo_2}
|
|
75
58
|
showLabel={true}
|
|
59
|
+
title={item.title ?? item.formato_alternativo_2.filename}
|
|
60
|
+
hideFileFormatLabel={true}
|
|
76
61
|
/>
|
|
77
62
|
</div>
|
|
78
63
|
</CardBody>
|
|
@@ -18,7 +18,9 @@ import {
|
|
|
18
18
|
*/
|
|
19
19
|
const Modules = ({ content, title, id = 'documenti' }) => {
|
|
20
20
|
const moduli =
|
|
21
|
-
content.
|
|
21
|
+
content.moduli_del_documento ??
|
|
22
|
+
content.items?.filter((item) => item.id !== 'multimedia') ??
|
|
23
|
+
[];
|
|
22
24
|
|
|
23
25
|
return moduli.length > 0 ? (
|
|
24
26
|
<RichTextSection tag_id={id} title={title}>
|
|
@@ -39,16 +39,6 @@ const PageHeaderDates = ({ content }) => {
|
|
|
39
39
|
</div>
|
|
40
40
|
</div>
|
|
41
41
|
)}
|
|
42
|
-
{content.expires && content['@type'] !== 'News Item' && (
|
|
43
|
-
<div className="row">
|
|
44
|
-
<div className="col-12">
|
|
45
|
-
<small>{intl.formatMessage(messages.expire)}:</small>
|
|
46
|
-
<p className="font-monospace">
|
|
47
|
-
{viewDate(intl.locale, content.expires, 'DD-MM-Y')}
|
|
48
|
-
</p>
|
|
49
|
-
</div>
|
|
50
|
-
</div>
|
|
51
|
-
)}
|
|
52
42
|
</div>
|
|
53
43
|
)}
|
|
54
44
|
</>
|
|
@@ -3,9 +3,8 @@
|
|
|
3
3
|
* @module components/theme/View/PaginaArgomentoView/PaginaArgomentoView
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import React
|
|
6
|
+
import React from 'react';
|
|
7
7
|
import { useLocation } from 'react-router-dom';
|
|
8
|
-
import { useDispatch, useSelector } from 'react-redux';
|
|
9
8
|
import { Portal } from 'react-portal';
|
|
10
9
|
import cx from 'classnames';
|
|
11
10
|
|
|
@@ -16,7 +15,6 @@ import {
|
|
|
16
15
|
flattenToAppURL,
|
|
17
16
|
hasBlocksData,
|
|
18
17
|
} from '@plone/volto/helpers';
|
|
19
|
-
import { getContent, resetContent } from '@plone/volto/actions';
|
|
20
18
|
import {
|
|
21
19
|
CardCategory,
|
|
22
20
|
Breadcrumbs,
|
|
@@ -44,32 +42,6 @@ import config from '@plone/volto/registry';
|
|
|
44
42
|
const PaginaArgomentoView = ({ content }) => {
|
|
45
43
|
const Image = config.getComponent({ name: 'Image' }).component;
|
|
46
44
|
const location = useLocation();
|
|
47
|
-
const dispatch = useDispatch();
|
|
48
|
-
|
|
49
|
-
const searchResults = useSelector((state) => state.content?.subrequests);
|
|
50
|
-
|
|
51
|
-
// one request is made for every 'unita_amministrative_responsabili' selected
|
|
52
|
-
useEffect(() => {
|
|
53
|
-
if (content?.unita_amministrative_responsabili?.length > 0) {
|
|
54
|
-
content.unita_amministrative_responsabili.forEach((x) => {
|
|
55
|
-
const url = flattenToAppURL(x['@id']);
|
|
56
|
-
const loaded =
|
|
57
|
-
searchResults?.[url]?.loading || searchResults?.[url]?.loaded;
|
|
58
|
-
if (!loaded) {
|
|
59
|
-
dispatch(getContent(url, null, url));
|
|
60
|
-
}
|
|
61
|
-
});
|
|
62
|
-
}
|
|
63
|
-
|
|
64
|
-
return () => {
|
|
65
|
-
if (content?.unita_amministrative_responsabili?.length > 0) {
|
|
66
|
-
content.unita_amministrative_responsabili.forEach((x) => {
|
|
67
|
-
dispatch(resetContent(flattenToAppURL(x['@id'])));
|
|
68
|
-
});
|
|
69
|
-
}
|
|
70
|
-
};
|
|
71
|
-
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
72
|
-
}, [content]);
|
|
73
45
|
|
|
74
46
|
const rightHeaderHasContent =
|
|
75
47
|
richTextHasContent(content.ulteriori_informazioni) ||
|
|
@@ -99,12 +71,17 @@ const PaginaArgomentoView = ({ content }) => {
|
|
|
99
71
|
|
|
100
72
|
{content?.unita_amministrative_responsabili?.length > 0 &&
|
|
101
73
|
content?.unita_amministrative_responsabili?.map((u, index) => {
|
|
102
|
-
const uo_object =
|
|
103
|
-
searchResults[flattenToAppURL(u['@id'])]?.data;
|
|
74
|
+
const uo_object = u;
|
|
104
75
|
let alt = u.title;
|
|
105
|
-
if (
|
|
76
|
+
if (
|
|
77
|
+
uo_object.image_scales.preview_image.length > 0 &&
|
|
78
|
+
uo_object?.preview_caption
|
|
79
|
+
) {
|
|
106
80
|
alt = uo_object.preview_caption;
|
|
107
|
-
} else if (
|
|
81
|
+
} else if (
|
|
82
|
+
uo_object.image_scales.image.length > 0 &&
|
|
83
|
+
uo_object?.image_caption
|
|
84
|
+
) {
|
|
108
85
|
alt = uo_object.image_caption;
|
|
109
86
|
}
|
|
110
87
|
|
|
@@ -132,7 +109,9 @@ const PaginaArgomentoView = ({ content }) => {
|
|
|
132
109
|
</CardText>
|
|
133
110
|
</CardBody>
|
|
134
111
|
{uo_object &&
|
|
135
|
-
(uo_object.
|
|
112
|
+
(uo_object.image_scales.image.length > 0 ||
|
|
113
|
+
uo_object.image_scales.preview_image.length >
|
|
114
|
+
0) && (
|
|
136
115
|
<div className="image-container me-3">
|
|
137
116
|
<Image
|
|
138
117
|
item={uo_object}
|
|
@@ -8,7 +8,7 @@ import shareSVG from '@plone/volto/icons/share.svg';
|
|
|
8
8
|
import searchIcon from 'bootstrap-italia/src/svg/it-search.svg';
|
|
9
9
|
import { defineMessages } from 'react-intl';
|
|
10
10
|
import { Search } from '@plone/volto/components';
|
|
11
|
-
|
|
11
|
+
import ImageWithErrors from 'design-comuni-plone-theme/components/ImageWithErrors/ImageWithErrors';
|
|
12
12
|
import {
|
|
13
13
|
getItaliaListingVariations,
|
|
14
14
|
removeListingVariation,
|
|
@@ -535,6 +535,9 @@ export default function applyConfig(voltoConfig) {
|
|
|
535
535
|
config.components = {
|
|
536
536
|
...config.components,
|
|
537
537
|
BlockExtraTags: { component: () => null },
|
|
538
|
+
Image: {
|
|
539
|
+
component: ImageWithErrors,
|
|
540
|
+
},
|
|
538
541
|
};
|
|
539
542
|
config.registerComponent({
|
|
540
543
|
name: 'SiteSettingsExtras',
|
|
@@ -34,4 +34,17 @@
|
|
|
34
34
|
.chip {
|
|
35
35
|
cursor: pointer;
|
|
36
36
|
}
|
|
37
|
+
|
|
38
|
+
.overlay.loading-results {
|
|
39
|
+
width: 100%;
|
|
40
|
+
height: 100%;
|
|
41
|
+
position: fixed;
|
|
42
|
+
z-index: 9999;
|
|
43
|
+
top: 0;
|
|
44
|
+
left: 0;
|
|
45
|
+
background-color: hsl(0deg 0% 100% / 64%);
|
|
46
|
+
display: flex;
|
|
47
|
+
align-items: center;
|
|
48
|
+
justify-content: center;
|
|
49
|
+
}
|
|
37
50
|
}
|