forked from italia/design-comuni-plone-theme
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: added component to show update_note field on Bandi view (#543)
* fix: added component to show update_note field on Bandi view * chore: generated translation files * chore: added label in EN
- Loading branch information
1 parent
9747bd7
commit a9e33fe
Showing
10 changed files
with
69 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
msgid "" | ||
msgstr "" | ||
"Project-Id-Version: Plone\n" | ||
"POT-Creation-Date: 2024-02-15T11:19:07.787Z\n" | ||
"POT-Creation-Date: 2024-02-19T11:08:36.048Z\n" | ||
"Last-Translator: Plone i18n <[email protected]>\n" | ||
"Language-Team: Plone i18n <[email protected]>\n" | ||
"MIME-Version: 1.0\n" | ||
|
@@ -2551,6 +2551,11 @@ msgstr "" | |
msgid "nominativo" | ||
msgstr "" | ||
|
||
#: components/ItaliaTheme/View/BandoView/BandoNoteAggiornamento | ||
# defaultMessage: Note di aggiornamento | ||
msgid "note_aggiornamento" | ||
msgstr "" | ||
|
||
#: components/ItaliaTheme/View/Commons/RelatedItems | ||
# defaultMessage: Novità | ||
msgid "novita" | ||
|
29 changes: 29 additions & 0 deletions
29
src/components/ItaliaTheme/View/BandoView/BandoNoteAggiornamento.jsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
import React from 'react'; | ||
import PropTypes from 'prop-types'; | ||
import { defineMessages, useIntl } from 'react-intl'; | ||
|
||
const messages = defineMessages({ | ||
note_aggiornamento: { | ||
id: 'note_aggiornamento', | ||
defaultMessage: 'Note di aggiornamento', | ||
}, | ||
}); | ||
|
||
const BandoNoteAggiornamento = ({ content }) => { | ||
const intl = useIntl(); | ||
return content?.update_note ? ( | ||
<div className="mb-4"> | ||
<h3 className="h5">{intl.formatMessage(messages.note_aggiornamento)}</h3> | ||
<span>{content?.update_note}</span> | ||
</div> | ||
) : ( | ||
<></> | ||
); | ||
}; | ||
|
||
BandoNoteAggiornamento.propTypes = { | ||
content: PropTypes.shape({ | ||
update_note: PropTypes.shape(PropTypes.string), | ||
}).isRequired, | ||
}; | ||
export default BandoNoteAggiornamento; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters