design-comuni-plone-theme 11.29.2 → 12.0.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/.github/workflows/main.yml +16 -16
- package/.github/workflows/npm.yml +1 -1
- package/.github/workflows/withnewsletter.yml +47 -0
- package/.release-it.json +1 -0
- package/.yarn/cache/@babel-helper-module-imports-npm-7.24.3-edb733448b-c23492189b.zip +0 -0
- package/.yarn/cache/@babel-types-npm-7.24.0-a0508cb308-4b574a37d4.zip +0 -0
- package/.yarn/cache/babel-plugin-lodash-npm-3.3.4-c7161075b6-044a4261e6.zip +0 -0
- package/.yarn/cache/braces-npm-3.0.3-582c14023c-b95aa0b3bd.zip +0 -0
- package/.yarn/cache/fill-range-npm-7.1.1-bf491486db-b4abfbca38.zip +0 -0
- package/.yarn/cache/micromatch-npm-4.0.8-c9570e4aca-79920eb634.zip +0 -0
- package/.yarn/cache/require-package-name-npm-2.0.1-ac9a206b63-00f4e9e467.zip +0 -0
- package/.yarn/install-state.gz +0 -0
- package/CHANGELOG.md +1728 -1659
- package/RELEASE.md +6 -0
- package/locales/de/LC_MESSAGES/volto.po +86 -19
- package/locales/en/LC_MESSAGES/volto.po +86 -19
- package/locales/es/LC_MESSAGES/volto.po +86 -19
- package/locales/fr/LC_MESSAGES/volto.po +86 -19
- package/locales/it/LC_MESSAGES/volto.po +87 -20
- package/locales/volto.pot +87 -20
- package/package.json +3 -1
- package/publiccode.yml +2 -2
- package/src/components/Collapse.jsx +1 -0
- package/src/components/ItaliaTheme/AppExtras/SiteSettingsExtras.jsx +0 -6
- package/src/components/ItaliaTheme/Blocks/Accordion/Block/EditBlock.jsx +29 -24
- package/src/components/ItaliaTheme/Blocks/Accordion/Block/ViewBlock.jsx +4 -12
- package/src/components/ItaliaTheme/Blocks/Accordion/Edit.jsx +118 -42
- package/src/components/ItaliaTheme/Blocks/Accordion/View.jsx +4 -18
- package/src/components/ItaliaTheme/Blocks/Alert/Edit.jsx +60 -113
- package/src/components/ItaliaTheme/Blocks/Alert/Sidebar.jsx +1 -0
- package/src/components/ItaliaTheme/Blocks/Alert/View.jsx +5 -14
- package/src/components/ItaliaTheme/Blocks/ArgumentsInEvidence/Block.jsx +16 -11
- package/src/components/ItaliaTheme/Blocks/ArgumentsInEvidence/Body.jsx +2 -1
- package/src/components/ItaliaTheme/Blocks/ArgumentsInEvidence/Edit.jsx +39 -1
- package/src/components/ItaliaTheme/Blocks/CTABlock/Block.jsx +35 -95
- package/src/components/ItaliaTheme/Blocks/Callout/Edit.jsx +108 -0
- package/src/components/ItaliaTheme/Blocks/Callout/Sidebar.jsx +173 -0
- package/src/components/ItaliaTheme/Blocks/Callout/View.jsx +45 -0
- package/src/components/ItaliaTheme/Blocks/ContactsBlock/Block/EditBlock.jsx +86 -63
- package/src/components/ItaliaTheme/Blocks/ContactsBlock/Block/ViewBlock.jsx +19 -39
- package/src/components/ItaliaTheme/Blocks/ContactsBlock/Edit.jsx +101 -22
- package/src/components/ItaliaTheme/Blocks/ContactsBlock/View.jsx +13 -21
- package/src/components/ItaliaTheme/Blocks/CountDown/Edit.jsx +21 -25
- package/src/components/ItaliaTheme/Blocks/CountDown/View.jsx +6 -15
- package/src/components/ItaliaTheme/Blocks/IconBlocks/Block/EditBlock.jsx +52 -22
- package/src/components/ItaliaTheme/Blocks/IconBlocks/Block/ViewBlock.jsx +9 -29
- package/src/components/ItaliaTheme/Blocks/IconBlocks/Edit.jsx +108 -21
- package/src/components/ItaliaTheme/Blocks/IconBlocks/Sidebar.jsx +1 -9
- package/src/components/ItaliaTheme/Blocks/IconBlocks/View.jsx +6 -14
- package/src/components/ItaliaTheme/Blocks/Listing/CardWithSlideUpTextTemplate.jsx +0 -1
- package/src/components/ItaliaTheme/Blocks/NumbersBlock/Block/EditBlock.jsx +45 -15
- package/src/components/ItaliaTheme/Blocks/NumbersBlock/Block/ViewBlock.jsx +2 -18
- package/src/components/ItaliaTheme/Blocks/NumbersBlock/Edit.jsx +98 -11
- package/src/components/ItaliaTheme/Blocks/NumbersBlock/View.jsx +2 -7
- package/src/components/ItaliaTheme/Blocks/TextCard/CardWithImage/Block.jsx +35 -67
- package/src/components/ItaliaTheme/Blocks/TextCard/CardWithImage/Edit.jsx +2 -8
- package/src/components/ItaliaTheme/Blocks/TextCard/SimpleCard/BodyWrapper.jsx +2 -1
- package/src/components/ItaliaTheme/Blocks/TextCard/SimpleCard/Edit.jsx +98 -84
- package/src/components/ItaliaTheme/Blocks/TextCard/SimpleCard/View.jsx +20 -3
- package/src/components/ItaliaTheme/Blocks/UOSearch/Sidebar.jsx +11 -11
- package/src/components/ItaliaTheme/Blocks/__tests__/Accordion.test.jsx +11 -28
- package/src/components/ItaliaTheme/Blocks/__tests__/Alert.test.jsx +10 -14
- package/src/components/ItaliaTheme/Blocks/__tests__/ArgumentsInEvidence.test.jsx +20 -28
- package/src/components/ItaliaTheme/Blocks/__tests__/CTABlock.test.jsx +14 -29
- package/src/components/ItaliaTheme/Blocks/__tests__/CardWithImage.test.jsx +11 -28
- package/src/components/ItaliaTheme/Blocks/__tests__/ContactsBlock.test.jsx +75 -140
- package/src/components/ItaliaTheme/Blocks/__tests__/Countdown.test.jsx +20 -28
- package/src/components/ItaliaTheme/Blocks/__tests__/IconBlocks.test.jsx +22 -56
- package/src/components/ItaliaTheme/Blocks/__tests__/NumbersBlock.test.jsx +14 -43
- package/src/components/ItaliaTheme/Blocks/__tests__/SimpleCard.test.jsx +14 -30
- package/src/components/ItaliaTheme/BrandText/BrandText.jsx +8 -14
- package/src/components/ItaliaTheme/BrandTextFooter/BrandTextFooter.jsx +31 -2
- package/src/components/ItaliaTheme/Footer/FooterInfos.jsx +21 -8
- package/src/components/ItaliaTheme/Footer/FooterNavigation.jsx +3 -3
- package/src/components/ItaliaTheme/Header/HeaderSlim/HeaderSlim.jsx +0 -7
- package/src/components/ItaliaTheme/Icons/Icon.jsx +0 -1
- package/src/components/ItaliaTheme/MegaMenu/MegaMenu.jsx +5 -1
- package/src/components/ItaliaTheme/View/BandoView/BandoApprofondimenti.jsx +1 -2
- package/src/components/ItaliaTheme/View/CartellaModulisticaView/DocRow.jsx +14 -5
- package/src/components/ItaliaTheme/View/Commons/Attachment.jsx +19 -3
- package/src/components/ItaliaTheme/View/Commons/Attachments.jsx +0 -1
- package/src/components/ItaliaTheme/View/Commons/DownloadFileFormat.jsx +11 -7
- package/src/components/ItaliaTheme/View/Commons/Gallery.jsx +1 -0
- package/src/components/ItaliaTheme/View/Commons/PageHeader/PageHeaderEventDates.jsx +0 -1
- package/src/components/ItaliaTheme/View/Commons/PageHeader/PageHeaderLinkServizio.jsx +6 -2
- package/src/components/ItaliaTheme/View/Commons/RichTextRender.jsx +8 -6
- package/src/components/ItaliaTheme/View/Commons/__tests__/RichText.test.jsx +14 -17
- package/src/components/ItaliaTheme/View/EventoView/EventoContattiOrganizzatoreEsterno.jsx +1 -1
- package/src/components/ItaliaTheme/View/EventoView/EventoUlterioriInformazioni.jsx +0 -4
- package/src/components/ItaliaTheme/View/ServizioView/ServizioAccedi.jsx +10 -7
- package/src/components/ItaliaTheme/View/ServizioView/ServizioMetatag.jsx +4 -3
- package/src/components/ItaliaTheme/View/__disabled_tests__/IncaricoView.test__disabled.jsx +24 -30
- package/src/components/ItaliaTheme/View/__tests__/CartellaModulisticaView.test.jsx +12 -1
- package/src/components/ItaliaTheme/View/__tests__/PageView.test.jsx +24 -2
- package/src/components/ItaliaTheme/View/__tests__/PersonaView.test.jsx +96 -92
- package/src/components/ItaliaTheme/View/__tests__/ServizioAChiSiRivolge.test.jsx +240 -286
- package/src/components/ItaliaTheme/View/__tests__/ServizioAccedi.test.jsx +240 -286
- package/src/components/ItaliaTheme/View/__tests__/ServizioCasiParticolari.test.jsx +240 -286
- package/src/components/ItaliaTheme/View/__tests__/ServizioComeFare.test.jsx +240 -286
- package/src/components/ItaliaTheme/View/__tests__/ServizioCondizioni.test.jsx +240 -286
- package/src/components/ItaliaTheme/View/__tests__/ServizioContatti.test.jsx +240 -286
- package/src/components/ItaliaTheme/View/__tests__/ServizioCosE.test.jsx +240 -286
- package/src/components/ItaliaTheme/View/__tests__/ServizioCosaServe.test.jsx +240 -286
- package/src/components/ItaliaTheme/View/__tests__/ServizioCosaSiOttiene.test.jsx +240 -286
- package/src/components/ItaliaTheme/View/__tests__/ServizioCostiVincoli.test.jsx +240 -286
- package/src/components/ItaliaTheme/View/__tests__/ServizioMetadati.test.jsx +240 -286
- package/src/components/ItaliaTheme/View/__tests__/ServizioModulistica.test.jsx +240 -286
- package/src/components/ItaliaTheme/View/__tests__/ServizioProcedure.test.jsx +240 -286
- package/src/components/ItaliaTheme/View/__tests__/ServizioSitiEsterni.test.jsx +240 -286
- package/src/components/ItaliaTheme/View/__tests__/ServizioTempiScadenze.test.jsx +240 -286
- package/src/components/ItaliaTheme/View/__tests__/ServizioUlterioriInformazioni.test.jsx +240 -286
- package/src/components/ItaliaTheme/View/__tests__/ServizioView.test.jsx +470 -560
- package/src/components/ItaliaTheme/View/__tests__/TrasparenzaView.test.jsx +12 -1
- package/src/components/ItaliaTheme/index.js +0 -1
- package/src/components/ItaliaTheme/manage/Widgets/ColorListWidget.jsx +11 -2
- package/src/components/ItaliaTheme/manage/Widgets/HtmlSlateWidget.jsx +156 -0
- package/src/components/ItaliaTheme/manage/Widgets/RichTextWidget.jsx +88 -0
- package/src/components/ItaliaTheme/manage/Widgets/SimpleTextEditorWidget.jsx +158 -0
- package/src/components/ItaliaTheme/manage/Widgets/TextEditorWidget.jsx +167 -270
- package/src/config/Blocks/ListingOptions/index.js +0 -1
- package/src/config/Blocks/ListingOptions/utils.js +0 -7
- package/src/config/Blocks/blocks.js +29 -8
- package/src/config/Blocks/listingVariations.js +1 -1
- package/src/config/Slate/Alignment/AlignMenu.jsx +169 -0
- package/src/config/Slate/Alignment/index.js +42 -0
- package/src/config/Slate/Blockquote/BlockquoteMenu.jsx +151 -0
- package/src/config/Slate/Blockquote/index.js +19 -0
- package/src/config/Slate/Headings/HeadingsMenu.jsx +139 -0
- package/src/config/Slate/Headings/headingsMenu.scss +44 -0
- package/src/config/Slate/Headings/index.js +62 -0
- package/src/config/Slate/Link/deserializer.js +25 -0
- package/src/config/Slate/Link/index.js +126 -0
- package/src/config/Slate/Link/renderer.jsx +99 -0
- package/src/config/Slate/LinkButton/index.js +47 -0
- package/src/config/Slate/TextLarger/index.js +51 -0
- package/src/config/Slate/Underline/index.js +10 -0
- package/src/config/Slate/config.js +43 -0
- package/src/config/Slate/deserializers.js +66 -0
- package/src/config/Slate/dropdownStyle.scss +14 -0
- package/src/config/Slate/dropdownUtils.js +422 -0
- package/src/config/Slate/extensions/breakList.js +91 -0
- package/src/config/Slate/handlers.js +243 -0
- package/src/config/Slate/utils.js +73 -0
- package/src/config/Widgets/widgets.js +1 -2
- package/src/config/italiaConfig.js +5 -53
- package/src/customizations/volto/components/manage/AnchorPlugin/components/LinkButton/AddLinkForm.jsx +361 -0
- package/src/customizations/volto/components/manage/Blocks/HeroImageLeft/Edit.jsx +75 -200
- package/src/customizations/volto/components/manage/Blocks/Video/Body.jsx +0 -1
- package/src/customizations/volto/components/manage/Blocks/Video/Edit.jsx +1 -1
- package/src/customizations/volto/components/manage/Form/BlocksToolbar.jsx +1 -1
- package/src/customizations/volto/components/manage/UniversalLink/UniversalLink.jsx +76 -18
- package/src/customizations/volto/components/manage/Widgets/RecurrenceWidget/RecurrenceWidget.jsx +4 -0
- package/src/customizations/volto-form-block/components/Field.jsx +45 -22
- package/src/helpers/EnhanceLink.js +44 -0
- package/src/helpers/FormValidation/FormValidationHelpers.js +3 -0
- package/src/helpers/blocks.js +80 -0
- package/src/helpers/files.js +13 -13
- package/src/helpers/index.js +4 -3
- package/src/helpers/richTextHelper.js +10 -0
- package/src/icons/Group.svg +1 -0
- package/src/icons/blocco-icone.svg +0 -3
- package/src/icons/blockquote-card-dark.svg +1 -0
- package/src/icons/blockquote-card.svg +1 -0
- package/src/icons/blockquote-simple.svg +1 -0
- package/src/icons/text-larger.svg +1 -0
- package/src/theme/ItaliaTheme/Blocks/_accordion.scss +2 -22
- package/src/theme/ItaliaTheme/Blocks/_alert.scss +51 -4
- package/src/theme/ItaliaTheme/Blocks/_bandiInEvidenceTemplate.scss +1 -0
- package/src/theme/ItaliaTheme/Blocks/_callout.scss +32 -0
- package/src/theme/ItaliaTheme/Blocks/_contacts.scss +17 -51
- package/src/theme/ItaliaTheme/Blocks/_countdown.scss +10 -1
- package/src/theme/ItaliaTheme/Blocks/_ctaBlock.scss +7 -23
- package/src/theme/ItaliaTheme/Blocks/_gridBlock.scss +1 -1
- package/src/theme/ItaliaTheme/Blocks/_hero.scss +1 -8
- package/src/theme/ItaliaTheme/Blocks/_iconBlocks.scss +6 -77
- package/src/theme/ItaliaTheme/Blocks/_imageCardTextBlock.scss +3 -2
- package/src/theme/ItaliaTheme/Blocks/_numbers.scss +6 -20
- package/src/theme/ItaliaTheme/Blocks/_simpleCardTextBlock.scss +8 -2
- package/src/theme/ItaliaTheme/Blocks/_subblocks-edit.scss +3 -1
- package/src/theme/ItaliaTheme/Blocks/_tableOfContents.scss +1 -0
- package/src/theme/ItaliaTheme/Components/_megamenu.scss +0 -4
- package/src/theme/ItaliaTheme/Components/_mobileMenu.scss +12 -16
- package/src/theme/ItaliaTheme/Print/_page.scss +1 -1
- package/src/theme/ItaliaTheme/Subsites/ItaliaTheme/Blocks/_contacts.scss +3 -0
- package/src/theme/ItaliaTheme/Subsites/ItaliaTheme/Blocks/_cta.scss +1 -0
- package/src/theme/ItaliaTheme/Subsites/ItaliaTheme/Blocks/_searchSections.scss +1 -0
- package/src/theme/ItaliaTheme/Subsites/bootstrap-italia/custom/_headercenter.scss +1 -0
- package/src/theme/ItaliaTheme/Views/_cartellaModulistica.scss +11 -2
- package/src/theme/ItaliaTheme/Views/_servizio.scss +2 -2
- package/src/theme/ItaliaTheme/Views/_slider.scss +3 -0
- package/src/theme/ItaliaTheme/Widgets/_iconWidget.scss +4 -0
- package/src/theme/ItaliaTheme/_common.scss +1 -0
- package/src/theme/ItaliaTheme/_home.scss +0 -4
- package/src/theme/ItaliaTheme/_main.scss +78 -84
- package/src/theme/_cms-ui.scss +63 -160
- package/src/theme/_mixins.scss +13 -0
- package/src/theme/bootstrap-override/_bootstrap-italia-site.scss +1 -0
- package/src/theme/bootstrap-override/bootstrap-italia/_footer.scss +1 -1
- package/src/theme/bootstrap-override/bootstrap-italia/_forms.scss +7 -0
- package/src/theme/bootstrap-override/bootstrap-italia/_headercenter.scss +8 -3
- package/src/theme/extras/_forms.scss +2 -14
- package/src/theme/site.scss +1 -1
- package/test-setup-config.js +58 -0
- package/.yarn/cache/braces-npm-3.0.2-782240b28a-e2a8e769a8.zip +0 -0
- package/.yarn/cache/fill-range-npm-7.0.1-b8b1817caa-cc283f4e65.zip +0 -0
- package/.yarn/cache/micromatch-npm-4.0.5-cfab5d7669-02a17b671c.zip +0 -0
- package/src/components/ItaliaTheme/Blocks/TextCard/SimpleCard/Block.jsx +0 -151
- package/src/components/ItaliaTheme/RemoveBodyClass/RemoveBodyClass.jsx +0 -84
- package/src/config/RichTextEditor/LinkEntity.jsx +0 -27
- package/src/config/RichTextEditor/Plugins/AnchorPlugin/components/Link/index.jsx +0 -44
- package/src/config/RichTextEditor/Plugins/AnchorPlugin/components/LinkButton/AddLinkForm.jsx +0 -349
- package/src/config/RichTextEditor/Plugins/AnchorPlugin/components/LinkButton/index.js +0 -150
- package/src/config/RichTextEditor/Plugins/AnchorPlugin/index.js +0 -88
- package/src/config/RichTextEditor/ToolbarButtons/AlignButton.jsx +0 -61
- package/src/config/RichTextEditor/ToolbarButtons/ButtonsButton.jsx +0 -14
- package/src/config/RichTextEditor/ToolbarButtons/CalloutsButton.jsx +0 -38
- package/src/config/RichTextEditor/ToolbarButtons/DraftJsDropdownButton.jsx +0 -106
- package/src/config/RichTextEditor/ToolbarButtons/HeadingsButton.jsx +0 -57
- package/src/config/RichTextEditor/ToolbarButtons/TextSizeButton.jsx +0 -65
- package/src/config/RichTextEditor/ToolbarButtons/UnderlineButton.jsx +0 -14
- package/src/config/RichTextEditor/config.js +0 -253
- package/src/config/volto-gdpr-privacy-defaultPanelConfig.js +0 -292
- package/src/customizations/volto/components/manage/Blocks/ToC/View.jsx +0 -134
- package/src/customizations/volto/components/manage/Blocks/ToC/variations/DefaultTocRenderer.jsx +0 -99
- package/src/customizations/volto/config/RichTextEditor/Plugins.jsx +0 -63
- package/src/helpers/redraftHelper.js +0 -9
- package/src/theme/ItaliaTheme/Components/_logo.scss +0 -10
package/src/customizations/volto/components/manage/Blocks/ToC/variations/DefaultTocRenderer.jsx
DELETED
|
@@ -1,99 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* CUSTOMIZATIONS: Fix slug variable to work with 'id' if overrride_toc is not set
|
|
3
|
-
* View toc block.
|
|
4
|
-
* @module components/manage/Blocks/ToC/View
|
|
5
|
-
*/
|
|
6
|
-
|
|
7
|
-
import React from 'react';
|
|
8
|
-
import PropTypes from 'prop-types';
|
|
9
|
-
import { map } from 'lodash';
|
|
10
|
-
import { List } from 'semantic-ui-react';
|
|
11
|
-
import { FormattedMessage, injectIntl } from 'react-intl';
|
|
12
|
-
import { useHistory } from 'react-router-dom';
|
|
13
|
-
import AnchorLink from 'react-anchor-link-smooth-scroll';
|
|
14
|
-
import Slugger from 'github-slugger';
|
|
15
|
-
|
|
16
|
-
const RenderListItems = ({ items, data, history }) => {
|
|
17
|
-
return map(items, (item) => {
|
|
18
|
-
const { id, level, title, override_toc, plaintext } = item;
|
|
19
|
-
/*
|
|
20
|
-
//volto version:
|
|
21
|
-
const slug = override_toc
|
|
22
|
-
? Slugger.slug(plaintext)
|
|
23
|
-
: Slugger.slug(title) || id;
|
|
24
|
-
*/
|
|
25
|
-
const slug = override_toc
|
|
26
|
-
? Slugger.slug(plaintext)
|
|
27
|
-
: id || Slugger.slug(title);
|
|
28
|
-
return (
|
|
29
|
-
item && (
|
|
30
|
-
<List.Item key={id} className={`item headline-${level}`} as="li">
|
|
31
|
-
<AnchorLink
|
|
32
|
-
href={`#${slug}`}
|
|
33
|
-
onClick={(e) => {
|
|
34
|
-
history.push({ hash: slug });
|
|
35
|
-
}}
|
|
36
|
-
>
|
|
37
|
-
{title}
|
|
38
|
-
</AnchorLink>
|
|
39
|
-
{item.items?.length > 0 && (
|
|
40
|
-
<List
|
|
41
|
-
ordered={data.ordered}
|
|
42
|
-
bulleted={!data.ordered}
|
|
43
|
-
as={data.ordered ? 'ol' : 'ul'}
|
|
44
|
-
>
|
|
45
|
-
<RenderListItems
|
|
46
|
-
items={item.items}
|
|
47
|
-
data={data}
|
|
48
|
-
history={history}
|
|
49
|
-
/>
|
|
50
|
-
</List>
|
|
51
|
-
)}
|
|
52
|
-
</List.Item>
|
|
53
|
-
)
|
|
54
|
-
);
|
|
55
|
-
});
|
|
56
|
-
};
|
|
57
|
-
|
|
58
|
-
/**
|
|
59
|
-
* View toc block class.
|
|
60
|
-
* @class View
|
|
61
|
-
* @extends Component
|
|
62
|
-
*/
|
|
63
|
-
const View = ({ data, tocEntries }) => {
|
|
64
|
-
const history = useHistory();
|
|
65
|
-
return (
|
|
66
|
-
<>
|
|
67
|
-
{data.title && !data.hide_title ? (
|
|
68
|
-
<h2>
|
|
69
|
-
{data.title || (
|
|
70
|
-
<FormattedMessage
|
|
71
|
-
id="Table of Contents"
|
|
72
|
-
defaultMessage="Table of Contents"
|
|
73
|
-
/>
|
|
74
|
-
)}
|
|
75
|
-
</h2>
|
|
76
|
-
) : (
|
|
77
|
-
''
|
|
78
|
-
)}
|
|
79
|
-
<List
|
|
80
|
-
ordered={data.ordered}
|
|
81
|
-
bulleted={!data.ordered}
|
|
82
|
-
as={data.ordered ? 'ol' : 'ul'}
|
|
83
|
-
>
|
|
84
|
-
<RenderListItems items={tocEntries} data={data} history={history} />
|
|
85
|
-
</List>
|
|
86
|
-
</>
|
|
87
|
-
);
|
|
88
|
-
};
|
|
89
|
-
|
|
90
|
-
/**
|
|
91
|
-
* Property types.
|
|
92
|
-
* @property {Object} propTypes Property types.
|
|
93
|
-
* @static
|
|
94
|
-
*/
|
|
95
|
-
View.propTypes = {
|
|
96
|
-
properties: PropTypes.objectOf(PropTypes.any).isRequired,
|
|
97
|
-
};
|
|
98
|
-
|
|
99
|
-
export default injectIntl(View);
|
|
@@ -1,63 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Customizzato:
|
|
3
|
-
* - cambiato l'import di AnchorPlugin per poterlo customizzare
|
|
4
|
-
*/
|
|
5
|
-
import createLinkPlugin from 'design-comuni-plone-theme/config/RichTextEditor/Plugins/AnchorPlugin';
|
|
6
|
-
|
|
7
|
-
import Styles from '@plone/volto/config/RichTextEditor/Styles';
|
|
8
|
-
|
|
9
|
-
const breakOutOptions = {
|
|
10
|
-
doubleBreakoutBlocks: [
|
|
11
|
-
'unordered-list-item',
|
|
12
|
-
'ordered-list-item',
|
|
13
|
-
'code-block',
|
|
14
|
-
],
|
|
15
|
-
breakoutBlocks: [
|
|
16
|
-
'header-one',
|
|
17
|
-
'header-two',
|
|
18
|
-
'header-three',
|
|
19
|
-
'highlight',
|
|
20
|
-
'blockquote',
|
|
21
|
-
'callout',
|
|
22
|
-
],
|
|
23
|
-
};
|
|
24
|
-
|
|
25
|
-
//const linkDetectionPlugin = createLinkDetectionPlugin();
|
|
26
|
-
|
|
27
|
-
const plugins = (props) => {
|
|
28
|
-
const { draftJsInlineToolbarPlugin, draftJsBlockBreakoutPlugin } = props;
|
|
29
|
-
const { Separator } = draftJsInlineToolbarPlugin;
|
|
30
|
-
const blockBreakoutPlugin =
|
|
31
|
-
draftJsBlockBreakoutPlugin.default(breakOutOptions);
|
|
32
|
-
|
|
33
|
-
const linkPlugin = createLinkPlugin({ libraries: props });
|
|
34
|
-
|
|
35
|
-
const buttons = Styles(props);
|
|
36
|
-
const {
|
|
37
|
-
BoldButton,
|
|
38
|
-
ItalicButton,
|
|
39
|
-
HeadlineTwoButton,
|
|
40
|
-
HeadlineThreeButton,
|
|
41
|
-
UnorderedListButton,
|
|
42
|
-
OrderedListButton,
|
|
43
|
-
BlockquoteButton,
|
|
44
|
-
CalloutButton,
|
|
45
|
-
} = buttons;
|
|
46
|
-
|
|
47
|
-
const inlineToolbarButtons = [
|
|
48
|
-
BoldButton,
|
|
49
|
-
ItalicButton,
|
|
50
|
-
linkPlugin.LinkButton,
|
|
51
|
-
Separator,
|
|
52
|
-
HeadlineTwoButton,
|
|
53
|
-
HeadlineThreeButton,
|
|
54
|
-
UnorderedListButton,
|
|
55
|
-
OrderedListButton,
|
|
56
|
-
BlockquoteButton,
|
|
57
|
-
CalloutButton,
|
|
58
|
-
];
|
|
59
|
-
|
|
60
|
-
return { inlineToolbarButtons, plugins: [linkPlugin, blockBreakoutPlugin] }; //linkDetectionPlugin
|
|
61
|
-
};
|
|
62
|
-
|
|
63
|
-
export default plugins;
|