@plone/volto 16.22.0 → 16.22.1

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.
Files changed (68) hide show
  1. package/.changelog.draft +15 -22
  2. package/.gitignore~ +71 -0
  3. package/.yarn/install-state.gz +0 -0
  4. package/CHANGELOG.md +27 -1
  5. package/locales/ca/LC_MESSAGES/volto.po +37 -2
  6. package/locales/ca.json +1 -1
  7. package/locales/de/LC_MESSAGES/volto.po +38 -3
  8. package/locales/de.json +1 -1
  9. package/locales/en/LC_MESSAGES/volto.po +37 -2
  10. package/locales/en.json +1 -1
  11. package/locales/es/LC_MESSAGES/volto.po +37 -2
  12. package/locales/es.json +1 -1
  13. package/locales/eu/LC_MESSAGES/volto.po +37 -2
  14. package/locales/eu.json +1 -1
  15. package/locales/fi/LC_MESSAGES/volto.po +37 -2
  16. package/locales/fi.json +1 -1
  17. package/locales/fr/LC_MESSAGES/volto.po +37 -2
  18. package/locales/fr.json +1 -1
  19. package/locales/it/LC_MESSAGES/volto.po +228 -193
  20. package/locales/it.json +1 -1
  21. package/locales/ja/LC_MESSAGES/volto.po +37 -2
  22. package/locales/ja.json +1 -1
  23. package/locales/nl/LC_MESSAGES/volto.po +37 -2
  24. package/locales/nl.json +1 -1
  25. package/locales/pt/LC_MESSAGES/volto.po +37 -2
  26. package/locales/pt.json +1 -1
  27. package/locales/pt_BR/LC_MESSAGES/volto.po +37 -2
  28. package/locales/pt_BR.json +1 -1
  29. package/locales/ro/LC_MESSAGES/volto.po +37 -2
  30. package/locales/ro.json +1 -1
  31. package/locales/volto.pot +38 -3
  32. package/locales/volto.pot~ +4705 -0
  33. package/locales/zh_CN/LC_MESSAGES/volto.po +37 -2
  34. package/locales/zh_CN.json +1 -1
  35. package/news/4547.breaking~ +1 -0
  36. package/package.json +1 -1
  37. package/package.json~ +444 -0
  38. package/packages/volto-slate/package.json +1 -1
  39. package/src/components/manage/Blocks/Image/schema.js +5 -1
  40. package/src/components/manage/Blocks/Search/components/SearchInput.jsx +9 -2
  41. package/src/components/manage/Blocks/Search/hocs/withSearch.jsx +12 -1
  42. package/src/components/manage/Blocks/ToC/Schema.jsx +36 -7
  43. package/src/components/manage/Contents/ContentsPropertiesModal.jsx +1 -13
  44. package/src/components/manage/Controlpanels/Groups/RenderGroups.jsx +2 -2
  45. package/src/components/manage/Controlpanels/Users/RenderUsers.jsx +2 -2
  46. package/src/components/manage/Controlpanels/Users/UsersControlpanel.jsx +25 -10
  47. package/src/components/manage/Widgets/SelectUtils.js +1 -1
  48. package/src/components/theme/Error/ServerError.jsx +29 -0
  49. package/src/config/Views.jsx +2 -0
  50. package/src/config/index.js~ +223 -0
  51. package/src/express-middleware/files.js +8 -6
  52. package/src/express-middleware/images.js +7 -1
  53. package/src/middleware/api.js +14 -2
  54. package/src/reducers/actions/actions.js +7 -5
  55. package/src/reducers/actions/actions.test.js +70 -0
  56. package/src/server.jsx +9 -0
  57. package/packages/volto-slate/build/messages/src/blocks/Table/TableBlockEdit.json +0 -90
  58. package/packages/volto-slate/build/messages/src/blocks/Text/DefaultTextBlockEditor.json +0 -6
  59. package/packages/volto-slate/build/messages/src/blocks/Text/DetachedTextBlockEditor.json +0 -6
  60. package/packages/volto-slate/build/messages/src/blocks/Text/SlashMenu.json +0 -6
  61. package/packages/volto-slate/build/messages/src/editor/plugins/AdvancedLink/index.json +0 -10
  62. package/packages/volto-slate/build/messages/src/editor/plugins/Link/index.json +0 -10
  63. package/packages/volto-slate/build/messages/src/editor/plugins/Table/index.json +0 -30
  64. package/packages/volto-slate/build/messages/src/elementEditor/messages.json +0 -10
  65. package/packages/volto-slate/build/messages/src/widgets/HtmlSlateWidget.json +0 -6
  66. package/packages/volto-slate/build/messages/src/widgets/RichTextWidgetView.json +0 -6
  67. package/pyvenv.cfg +0 -3
  68. package/share/man/man1/ttx.1 +0 -225
package/package.json~ ADDED
@@ -0,0 +1,444 @@
1
+ {
2
+ "name": "@plone/volto",
3
+ "description": "Volto",
4
+ "maintainers": [
5
+ {
6
+ "name": "Plone Foundation",
7
+ "email": "plone-developers@lists.sourceforge.net",
8
+ "url": "http://plone.org"
9
+ }
10
+ ],
11
+ "license": "MIT",
12
+ "version": "17.0.0-alpha.23",
13
+ "repository": {
14
+ "type": "git",
15
+ "url": "git@github.com:plone/volto.git"
16
+ },
17
+ "customizationPaths": [
18
+ "src/customizations/"
19
+ ],
20
+ "bugs": {
21
+ "url": "https://github.com/plone/volto/issues",
22
+ "email": "plone-developers@lists.sourceforge.net"
23
+ },
24
+ "homepage": "https://plone.org",
25
+ "keywords": [
26
+ "volto",
27
+ "plone",
28
+ "react"
29
+ ],
30
+ "packagesFolderAddons": {
31
+ "volto-slate": {
32
+ "package": "@plone/volto-slate"
33
+ }
34
+ },
35
+ "scripts": {
36
+ "postinstall": "make patches",
37
+ "analyze": "BUNDLE_ANALYZE=true razzle build",
38
+ "start": "razzle start",
39
+ "start:coresandbox": "ADDONS=coresandbox razzle start",
40
+ "build": "razzle build --noninteractive",
41
+ "prepare": "husky install",
42
+ "test": "razzle test --maxWorkers=50%",
43
+ "test:ci": "CI=true NODE_ICU_DATA=node_modules/full-icu razzle test",
44
+ "test:husky": "CI=true yarn test --bail --findRelatedTests",
45
+ "test:debug": "node --inspect node_modules/.bin/jest --runInBand",
46
+ "start:prod": "NODE_ENV=production node build/server.js",
47
+ "prettier": "./node_modules/.bin/prettier --single-quote --check 'src/**/*.{js,jsx,ts,tsx,json}'",
48
+ "prettier:fix": "./node_modules/.bin/prettier --single-quote --write 'src/**/*.{js,jsx,ts,tsx,json}'",
49
+ "stylelint": "./node_modules/.bin/stylelint 'theme/**/*.{css,less}' 'src/**/*.{css,less}'",
50
+ "stylelint:overrides": "./node_modules/.bin/stylelint 'theme/**/*.overrides' 'src/**/*.overrides'",
51
+ "stylelint:fix": "yarn stylelint --fix && yarn stylelint:overrides --fix",
52
+ "lint": "./node_modules/eslint/bin/eslint.js --max-warnings=0 'src/**/*.{js,jsx,json}'",
53
+ "lint:fix": "./node_modules/eslint/bin/eslint.js --fix 'src/**/*.{js,jsx,json}'",
54
+ "i18n": "rm -rf build/messages && NODE_ENV=production i18n",
55
+ "i18n:ci": "yarn i18n && git diff -G'^[^\"POT]' --exit-code",
56
+ "dry-release": "release-it --dry-run",
57
+ "release": "release-it",
58
+ "release-major-alpha": "release-it major --preRelease=alpha",
59
+ "release-alpha": "release-it --preRelease=alpha",
60
+ "storybook": "start-storybook -p 6006",
61
+ "build-storybook": "build-storybook"
62
+ },
63
+ "bundlewatch": {
64
+ "files": [
65
+ {
66
+ "path": "build/public/static/js/*.js",
67
+ "maxSize": "700kB"
68
+ }
69
+ ]
70
+ },
71
+ "jest": {
72
+ "modulePathIgnorePatterns": [
73
+ "api",
74
+ "packages"
75
+ ],
76
+ "transform": {
77
+ "^.+\\.js(x)?$": "babel-jest",
78
+ "^.+\\.(png)$": "jest-file",
79
+ "^.+\\.(jpg)$": "jest-file",
80
+ "^.+\\.(svg)$": "./jest-svgsystem-transform.js"
81
+ },
82
+ "moduleNameMapper": {
83
+ "@plone/volto/package.json": "<rootDir>/package.json",
84
+ "@plone/volto/babel": "<rootDir>/babel.js",
85
+ "@plone/volto/(.*)$": "<rootDir>/src/$1",
86
+ "@plone/volto-slate/(.*)$": "<rootDir>/packages/volto-slate/src/$1",
87
+ "~/config": "<rootDir>/src/config",
88
+ "~/../locales/${lang}.json": "<rootDir>/locales/en.json",
89
+ "(.*)/locales/(.*)": "<rootDir>/locales/$2",
90
+ "load-volto-addons": "<rootDir>/jest-addons-loader.js",
91
+ "@package/(.*)$": "<rootDir>/src/$1",
92
+ "@root/config": "<rootDir>/jest-addons-loader.js",
93
+ "@root/(.*)$": "<rootDir>/src/$1",
94
+ "@voltoconfig": "<rootDir>/jest-addons-loader.js",
95
+ "\\.(css|less|scss|sass)$": "identity-obj-proxy"
96
+ },
97
+ "coverageThreshold": {
98
+ "global": {
99
+ "branches": 10,
100
+ "functions": 10,
101
+ "lines": 10,
102
+ "statements": 10
103
+ }
104
+ },
105
+ "setupFiles": [
106
+ "./test-setup-globals.js",
107
+ "./test-setup-config.js"
108
+ ],
109
+ "globalSetup": "./global-test-setup.js",
110
+ "globals": {
111
+ "__DEV__": true
112
+ },
113
+ "testMatch": [
114
+ "<rootDir>/src/**/__tests__/**/*.{js,jsx,mjs}",
115
+ "<rootDir>/src/**/?(*.)(spec|test).{js,jsx,mjs}",
116
+ "<rootDir>/__tests__/**/?(*.)(spec|test).{js,jsx,mjs}",
117
+ "<rootDir>/packages/volto-slate/src/**/?(*.)(spec|test).{js,jsx,mjs}"
118
+ ]
119
+ },
120
+ "prettier": {
121
+ "trailingComma": "all",
122
+ "singleQuote": true,
123
+ "overrides": [
124
+ {
125
+ "files": "*.overrides",
126
+ "options": {
127
+ "parser": "less"
128
+ }
129
+ }
130
+ ]
131
+ },
132
+ "stylelint": {
133
+ "extends": [
134
+ "stylelint-config-idiomatic-order"
135
+ ],
136
+ "plugins": [
137
+ "stylelint-prettier"
138
+ ],
139
+ "overrides": [
140
+ {
141
+ "files": [
142
+ "**/*.scss"
143
+ ],
144
+ "customSyntax": "postcss-scss"
145
+ },
146
+ {
147
+ "files": [
148
+ "**/*.less"
149
+ ],
150
+ "customSyntax": "postcss-less"
151
+ },
152
+ {
153
+ "files": [
154
+ "**/*.overrides"
155
+ ],
156
+ "customSyntax": "postcss-less"
157
+ }
158
+ ],
159
+ "rules": {
160
+ "prettier/prettier": true,
161
+ "rule-empty-line-before": [
162
+ "always-multi-line",
163
+ {
164
+ "except": [
165
+ "first-nested"
166
+ ],
167
+ "ignore": [
168
+ "after-comment"
169
+ ]
170
+ }
171
+ ]
172
+ },
173
+ "ignoreFiles": "theme/themes/default/**/*.overrides"
174
+ },
175
+ "browserslist": [
176
+ ">1%",
177
+ "last 4 versions",
178
+ "Firefox ESR",
179
+ "not ie 11",
180
+ "not dead"
181
+ ],
182
+ "release-it": {
183
+ "hooks": {
184
+ "before:bump": [
185
+ "yarn i18n",
186
+ "git add locales"
187
+ ],
188
+ "after:bump": "pipx run towncrier build --draft --yes --version ${version} > .changelog.draft && pipx run towncrier build --yes --version ${version} && make corepackagebump VERSION=${version}",
189
+ "after:release": "rm .changelog.draft"
190
+ },
191
+ "git": {
192
+ "changelog": "pipx run towncrier build --draft --yes --version 0.0.0",
193
+ "requireUpstream": false,
194
+ "requireCleanWorkingDir": false
195
+ },
196
+ "github": {
197
+ "release": true,
198
+ "releaseName": "${version}",
199
+ "releaseNotes": "cat .changelog.draft"
200
+ }
201
+ },
202
+ "lint-staged": {
203
+ "src/**/*.{js,jsx,ts,tsx,json}": [
204
+ "npx eslint --max-warnings=0 --fix",
205
+ "npx prettier --single-quote --write",
206
+ "yarn test:husky"
207
+ ],
208
+ "src/**/*.{jsx}": [
209
+ "yarn i18n"
210
+ ],
211
+ "theme/**/*.{css,less}": [
212
+ "npx stylelint --fix"
213
+ ],
214
+ "src/**/*.{css,less}": [
215
+ "npx stylelint --fix"
216
+ ],
217
+ "theme/**/*.overrides": [
218
+ "npx stylelint --fix"
219
+ ],
220
+ "src/**/*.overrides": [
221
+ "npx stylelint --fix"
222
+ ]
223
+ },
224
+ "engines": {
225
+ "node": "^16 || ^18"
226
+ },
227
+ "dependencies": {
228
+ "@babel/core": "^7.0.0",
229
+ "@babel/plugin-proposal-export-default-from": "7.18.9",
230
+ "@babel/plugin-proposal-export-namespace-from": "7.18.9",
231
+ "@babel/plugin-proposal-json-strings": "7.18.6",
232
+ "@babel/plugin-proposal-nullish-coalescing-operator": "7.18.6",
233
+ "@babel/plugin-proposal-throw-expressions": "7.18.6",
234
+ "@babel/plugin-syntax-export-namespace-from": "7.8.3",
235
+ "@babel/runtime": "7.20.6",
236
+ "@babel/types": "7.20.5",
237
+ "@loadable/babel-plugin": "5.13.2",
238
+ "@loadable/component": "5.14.1",
239
+ "@loadable/server": "5.14.0",
240
+ "@loadable/webpack-plugin": "5.15.2",
241
+ "@plone/scripts": "2.1.2",
242
+ "@testing-library/cypress": "9.0.0",
243
+ "@testing-library/jest-dom": "5.16.4",
244
+ "@testing-library/react": "12.1.5",
245
+ "@testing-library/react-hooks": "8.0.1",
246
+ "autoprefixer": "10.4.8",
247
+ "axe-core": "4.4.2",
248
+ "babel-eslint": "10.1.0",
249
+ "babel-plugin-add-module-exports": "0.2.1",
250
+ "babel-plugin-lodash": "3.3.4",
251
+ "babel-plugin-react-intl": "5.1.17",
252
+ "babel-plugin-root-import": "6.1.0",
253
+ "babel-preset-razzle": "4.2.17",
254
+ "circular-dependency-plugin": "5.2.2",
255
+ "classnames": "2.2.6",
256
+ "commander": "8.2.0",
257
+ "connected-react-router": "6.8.0",
258
+ "crypto-random-string": "3.2.0",
259
+ "css-loader": "5.2.7",
260
+ "cypress": "12.17.1",
261
+ "cypress-axe": "1.4.0",
262
+ "cypress-file-upload": "5.0.8",
263
+ "debug": "4.3.2",
264
+ "decorate-component-with-props": "1.2.1",
265
+ "deep-freeze": "0.0.1",
266
+ "dependency-graph": "0.10.0",
267
+ "detect-browser": "5.1.0",
268
+ "diff": "3.5.0",
269
+ "draft-js": "0.10.5",
270
+ "draft-js-block-breakout-plugin": "2.0.1",
271
+ "draft-js-buttons": "2.0.2",
272
+ "draft-js-import-html": "1.4.1",
273
+ "draft-js-inline-toolbar-plugin": "2.0.3",
274
+ "draft-js-plugins-editor": "2.1.1",
275
+ "draft-js-plugins-utils": "2.0.3",
276
+ "draftjs-filters": "2.3.0",
277
+ "eslint": "6.8.0",
278
+ "eslint-config-airbnb": "18.1.0",
279
+ "eslint-config-prettier": "6.11.0",
280
+ "eslint-config-react-app": "5.2.1",
281
+ "eslint-import-resolver-alias": "1.1.2",
282
+ "eslint-import-resolver-babel-plugin-root-import": "1.1.1",
283
+ "eslint-plugin-flowtype": "4.7.0",
284
+ "eslint-plugin-import": "2.20.2",
285
+ "eslint-plugin-jsx-a11y": "6.2.3",
286
+ "eslint-plugin-prettier": "3.1.3",
287
+ "eslint-plugin-react": "7.20.0",
288
+ "eslint-plugin-react-hooks": "4.0.2",
289
+ "express": "4.17.3",
290
+ "filesize": "6",
291
+ "github-slugger": "1.4.0",
292
+ "glob": "7.1.6",
293
+ "history": "4.10.1",
294
+ "hoist-non-react-statics": "3.3.2",
295
+ "html-webpack-plugin": "5.5.0",
296
+ "http-proxy-middleware": "2.0.1",
297
+ "husky": "8.0.1",
298
+ "identity-obj-proxy": "3.0.0",
299
+ "image-extensions": "1.1.0",
300
+ "immutable": "3",
301
+ "is-hotkey": "0.2.0",
302
+ "is-url": "1.2.4",
303
+ "jest-file": "1.0.0",
304
+ "jotai": "2.0.3",
305
+ "jwt-decode": "2.2.0",
306
+ "less": "3.11.1",
307
+ "less-loader": "11.1.0",
308
+ "linkify-it": "3.0.2",
309
+ "lint-staged": "10.2.2",
310
+ "locale": "0.1.0",
311
+ "lodash": "4.17.21",
312
+ "lodash-move": "1.1.1",
313
+ "lodash-webpack-plugin": "0.11.6",
314
+ "mini-css-extract-plugin": "2.7.2",
315
+ "moment": "2.29.4",
316
+ "object-assign": "4.1.1",
317
+ "pofile": "1.0.10",
318
+ "postcss": "8.4.13",
319
+ "postcss-flexbugs-fixes": "5.0.2",
320
+ "postcss-less": "6.0.0",
321
+ "postcss-load-config": "3.1.4",
322
+ "postcss-loader": "7.0.2",
323
+ "postcss-overrides": "3.1.4",
324
+ "postcss-scss": "4.0.6",
325
+ "prepend-http": "2",
326
+ "prettier": "2.0.5",
327
+ "pretty-bytes": "5.3.0",
328
+ "prismjs": "1.27.0",
329
+ "promise-file-reader": "1.0.2",
330
+ "prop-types": "15.7.2",
331
+ "query-string": "7.1.0",
332
+ "razzle": "4.2.18",
333
+ "razzle-dev-utils": "4.2.18",
334
+ "razzle-plugin-bundle-analyzer": "4.2.18",
335
+ "razzle-plugin-scss": "4.2.18",
336
+ "rc-time-picker": "3.7.3",
337
+ "react": "17.0.2",
338
+ "react-anchor-link-smooth-scroll": "1.0.12",
339
+ "react-animate-height": "2.0.17",
340
+ "react-beautiful-dnd": "13.0.0",
341
+ "react-cookie": "4.1.1",
342
+ "react-dates": "21.5.1",
343
+ "react-detect-click-outside": "1.1.1",
344
+ "react-dnd": "5.0.0",
345
+ "react-dnd-html5-backend": "5.0.1",
346
+ "react-dom": "17.0.2",
347
+ "react-dropzone": "11.1.0",
348
+ "react-fast-compare": "2.0.4",
349
+ "react-image-gallery": "1.2.7",
350
+ "react-intersection-observer": "9.1.0",
351
+ "react-intl": "3.8.0",
352
+ "react-intl-redux": "2.2.0",
353
+ "react-medium-image-zoom": "3.0.15",
354
+ "react-portal": "4.2.1",
355
+ "react-redux": "7.2.4",
356
+ "react-router": "5.2.0",
357
+ "react-router-config": "5.1.1",
358
+ "react-router-dom": "5.2.0",
359
+ "react-router-hash-link": "2.4.3",
360
+ "react-select": "4.3.1",
361
+ "react-select-async-paginate": "0.5.3",
362
+ "react-share": "2.3.1",
363
+ "react-side-effect": "2.1.0",
364
+ "react-simple-code-editor": "0.7.1",
365
+ "react-sortable-hoc": "2.0.0",
366
+ "react-test-renderer": "17.0.2",
367
+ "react-toastify": "5.4.1",
368
+ "react-transition-group": "4.4.5",
369
+ "react-virtualized": "9.22.3",
370
+ "redraft": "0.10.2",
371
+ "redux": "4.1.0",
372
+ "redux-actions": "2.6.5",
373
+ "redux-connect": "10.0.0",
374
+ "redux-devtools-extension": "2.13.8",
375
+ "redux-localstorage-simple": "2.3.1",
376
+ "redux-mock-store": "1.5.4",
377
+ "redux-thunk": "2.3.0",
378
+ "rrule": "2.7.1",
379
+ "semantic-ui-less": "2.4.1",
380
+ "semantic-ui-react": "2.0.3",
381
+ "serialize-javascript": "3.1.0",
382
+ "slate": "0.84.0",
383
+ "slate-hyperscript": "0.81.3",
384
+ "slate-react": "0.83.2",
385
+ "start-server-and-test": "1.14.0",
386
+ "style-loader": "3.3.1",
387
+ "stylelint": "14.0.1",
388
+ "stylelint-config-idiomatic-order": "8.1.0",
389
+ "stylelint-config-prettier": "8.0.1",
390
+ "stylelint-prettier": "1.1.2",
391
+ "superagent": "3.8.2",
392
+ "svg-loader": "0.0.2",
393
+ "svgo-loader": "3.0.3",
394
+ "terser-webpack-plugin": "5.3.6",
395
+ "tlds": "1.203.1",
396
+ "undoo": "0.5.0",
397
+ "universal-cookie": "4.0.4",
398
+ "universal-cookie-express": "4.0.3",
399
+ "use-deep-compare-effect": "1.8.1",
400
+ "uuid": "^8.3.2",
401
+ "webpack": "5.76.1",
402
+ "webpack-dev-server": "4.11.1",
403
+ "webpack-node-externals": "3.0.0",
404
+ "xmlrpc": "1.3.2",
405
+ "yarnhook": "0.5.1"
406
+ },
407
+ "devDependencies": {
408
+ "@storybook/addon-actions": "^6.5.15",
409
+ "@storybook/addon-controls": "6.5.15",
410
+ "@storybook/addon-essentials": "^6.5.15",
411
+ "@storybook/addon-links": "^6.5.15",
412
+ "@storybook/builder-webpack5": "^6.5.15",
413
+ "@storybook/manager-webpack5": "^6.5.15",
414
+ "@storybook/react": "^6.5.15",
415
+ "babel-loader": "9.1.0",
416
+ "bundlewatch": "0.3.3",
417
+ "full-icu": "1.4.0",
418
+ "identity-obj-proxy": "3.0.0",
419
+ "jest": "26.6.3",
420
+ "jest-environment-jsdom": "^26",
421
+ "jsonwebtoken": "9.0.0",
422
+ "react-error-overlay": "6.0.9",
423
+ "react-is": "^16.13.1",
424
+ "release-it": "^16.1.3",
425
+ "semver": "^7.5.4",
426
+ "tmp": "0.2.1",
427
+ "use-trace-update": "1.3.2",
428
+ "why": "0.6.2"
429
+ },
430
+ "resolutions-comments": {
431
+ "ua-parser-js": "See https://github.com/faisalman/ua-parser-js/issues/536"
432
+ },
433
+ "resolutions": {
434
+ "clean-css": "5.3.1",
435
+ "http-proxy": "^1.18.1",
436
+ "react-dev-utils": "^12",
437
+ "react-error-overlay": "6.0.9",
438
+ "ua-parser-js": "0.7.28"
439
+ },
440
+ "volta": {
441
+ "node": "18.13.0"
442
+ },
443
+ "packageManager": "yarn@3.2.3"
444
+ }
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@plone/volto-slate",
3
- "version": "16.22.0",
3
+ "version": "16.22.1",
4
4
  "description": "Slate.js integration with Volto",
5
5
  "main": "src/index.js",
6
6
  "author": "European Environment Agency: IDM2 A-Team",
@@ -37,6 +37,10 @@ const messages = defineMessages({
37
37
  id: 'Alt text hint link text',
38
38
  defaultMessage: 'Describe the purpose of the image.',
39
39
  },
40
+ linkSettings: {
41
+ id: 'Link settings',
42
+ defaultMessage: 'Link settings',
43
+ },
40
44
  });
41
45
 
42
46
  export function ImageSchema({ formData, intl }) {
@@ -51,7 +55,7 @@ export function ImageSchema({ formData, intl }) {
51
55
  ? [
52
56
  {
53
57
  id: 'link_settings',
54
- title: 'Link settings',
58
+ title: intl.formatMessage(messages.linkSettings),
55
59
  fields: ['href', 'openLinkInNewTab'],
56
60
  },
57
61
  ]
@@ -13,7 +13,14 @@ const messages = defineMessages({
13
13
  });
14
14
 
15
15
  const SearchInput = (props) => {
16
- const { data, searchText, setSearchText, isLive, onTriggerSearch } = props;
16
+ const {
17
+ data,
18
+ searchText,
19
+ setSearchText,
20
+ isLive,
21
+ onTriggerSearch,
22
+ removeSearchQuery,
23
+ } = props;
17
24
  const intl = useIntl();
18
25
 
19
26
  return (
@@ -44,7 +51,7 @@ const SearchInput = (props) => {
44
51
  className="search-input-clear-icon-button"
45
52
  onClick={() => {
46
53
  setSearchText('');
47
- onTriggerSearch('');
54
+ removeSearchQuery();
48
55
  }}
49
56
  >
50
57
  <Icon name={clearSVG} />
@@ -301,7 +301,7 @@ const withSearch = (options) => (WrappedComponent) => {
301
301
  id,
302
302
  query: data.query || {},
303
303
  facets: toSearchFacets || facets,
304
- searchText: toSearchText || searchText,
304
+ searchText: toSearchText ? toSearchText.trim() : '',
305
305
  sortOn: toSortOn || sortOn,
306
306
  sortOrder: toSortOrder || sortOrder,
307
307
  facetSettings,
@@ -329,6 +329,16 @@ const withSearch = (options) => (WrappedComponent) => {
329
329
  ],
330
330
  );
331
331
 
332
+ const removeSearchQuery = () => {
333
+ searchData.query = searchData.query.reduce(
334
+ // Remove SearchableText from query
335
+ (acc, kvp) => (kvp.i === 'SearchableText' ? acc : [...acc, kvp]),
336
+ [],
337
+ );
338
+ setSearchData(searchData);
339
+ setLocationSearchData(getSearchFields(searchData));
340
+ };
341
+
332
342
  const querystringResults = useSelector(
333
343
  (state) => state.querystringsearch.subrequests,
334
344
  );
@@ -347,6 +357,7 @@ const withSearch = (options) => (WrappedComponent) => {
347
357
  sortOrder={sortOrder}
348
358
  searchedText={urlSearchText}
349
359
  searchText={searchText}
360
+ removeSearchQuery={removeSearchQuery}
350
361
  setSearchText={setSearchText}
351
362
  onTriggerSearch={onTriggerSearch}
352
363
  totalItems={totalItems}
@@ -1,8 +1,37 @@
1
- const TableOfContentsSchema = ({ data }) => {
1
+ import { defineMessages } from 'react-intl';
2
+
3
+ const messages = defineMessages({
4
+ toc: {
5
+ id: 'toc',
6
+ defaultMessage: 'Table of Contents',
7
+ },
8
+ Title: {
9
+ id: 'Title',
10
+ defaultMessage: 'Title',
11
+ },
12
+ HideTitle: {
13
+ id: 'Hide title',
14
+ defaultMessage: 'Hide title',
15
+ },
16
+ Entries: {
17
+ id: 'Entries',
18
+ defaultMessage: 'Entries',
19
+ },
20
+ Ordered: {
21
+ id: 'Ordered',
22
+ defaultMessage: 'Ordered',
23
+ },
24
+ Sticky: {
25
+ id: 'Sticky',
26
+ defaultMessage: 'Sticky',
27
+ },
28
+ });
29
+
30
+ const TableOfContentsSchema = ({ data, intl }) => {
2
31
  const { variation = 'default' } = data;
3
32
 
4
33
  return {
5
- title: 'Table of Contents',
34
+ title: intl.formatMessage(messages.toc),
6
35
  fieldsets: [
7
36
  {
8
37
  id: 'default',
@@ -17,14 +46,14 @@ const TableOfContentsSchema = ({ data }) => {
17
46
  ],
18
47
  properties: {
19
48
  title: {
20
- title: 'Block title',
49
+ title: intl.formatMessage(messages.Title),
21
50
  },
22
51
  hide_title: {
23
- title: 'Hide title',
52
+ title: intl.formatMessage(messages.HideTitle),
24
53
  type: 'boolean',
25
54
  },
26
55
  levels: {
27
- title: 'Entries',
56
+ title: intl.formatMessage(messages.Entries),
28
57
  isMulti: true,
29
58
  choices: [
30
59
  ['h1', 'h1'],
@@ -36,11 +65,11 @@ const TableOfContentsSchema = ({ data }) => {
36
65
  ],
37
66
  },
38
67
  ordered: {
39
- title: 'Ordered',
68
+ title: intl.formatMessage(messages.Ordered),
40
69
  type: 'boolean',
41
70
  },
42
71
  sticky: {
43
- title: 'Sticky',
72
+ title: intl.formatMessage(messages.Sticky),
44
73
  type: 'boolean',
45
74
  },
46
75
  },
@@ -70,14 +70,6 @@ const messages = defineMessages({
70
70
  defaultMessage:
71
71
  'If selected, this item will not appear in the navigation tree',
72
72
  },
73
- yes: {
74
- id: 'Yes',
75
- defaultMessage: 'Yes',
76
- },
77
- no: {
78
- id: 'No',
79
- defaultMessage: 'No',
80
- },
81
73
  });
82
74
 
83
75
  /**
@@ -209,11 +201,7 @@ class ContentsPropertiesModal extends Component {
209
201
  title: this.props.intl.formatMessage(
210
202
  messages.excludeFromNavTitle,
211
203
  ),
212
- type: 'array',
213
- choices: [
214
- [true, this.props.intl.formatMessage(messages.yes)],
215
- [false, this.props.intl.formatMessage(messages.no)],
216
- ],
204
+ type: 'boolean',
217
205
  },
218
206
  },
219
207
  required: [],
@@ -57,7 +57,7 @@ class RenderGroups extends Component {
57
57
  * @memberof UsersControlpanelUser
58
58
  */
59
59
  onChange(event, { value }) {
60
- const [group, role] = value.split('.');
60
+ const [group, role] = value.split('&role=');
61
61
  this.props.updateGroups(group, role);
62
62
  }
63
63
 
@@ -97,7 +97,7 @@ class RenderGroups extends Component {
97
97
  : this.props.group.roles.includes(role.id)
98
98
  }
99
99
  onChange={this.onChange}
100
- value={`${this.props.group.id}.${role.id}`}
100
+ value={`${this.props.group.id}&role=${role.id}`}
101
101
  />
102
102
  )}
103
103
  </Table.Cell>
@@ -53,7 +53,7 @@ class RenderUsers extends Component {
53
53
  */
54
54
 
55
55
  onChange(event, { value }) {
56
- const [user, role] = value.split('.');
56
+ const [user, role] = value.split('&role=');
57
57
  this.props.updateUser(user, role);
58
58
  }
59
59
  /**
@@ -83,7 +83,7 @@ class RenderUsers extends Component {
83
83
  <Checkbox
84
84
  checked={this.props.user.roles.includes(role.id)}
85
85
  onChange={this.onChange}
86
- value={`${this.props.user.id}.${role.id}`}
86
+ value={`${this.props.user.id}&role=${role.id}`}
87
87
  />
88
88
  )}
89
89
  </Table.Cell>