From 46ab124df32f20b3662ea5a8161d084469100780 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Markus=20Kl=C3=B6pper?= Date: Wed, 3 Jul 2024 13:04:02 +0200 Subject: [PATCH] Add OverridableContext.Provider to CreatibutorsModal --- .../CreatibutorsField/CreatibutorsField.js | 35 +++++++++++-------- 1 file changed, 20 insertions(+), 15 deletions(-) diff --git a/invenio_rdm_records/assets/semantic-ui/js/invenio_rdm_records/src/deposit/fields/CreatibutorsField/CreatibutorsField.js b/invenio_rdm_records/assets/semantic-ui/js/invenio_rdm_records/src/deposit/fields/CreatibutorsField/CreatibutorsField.js index 2a7064df3..86a0f25b6 100644 --- a/invenio_rdm_records/assets/semantic-ui/js/invenio_rdm_records/src/deposit/fields/CreatibutorsField/CreatibutorsField.js +++ b/invenio_rdm_records/assets/semantic-ui/js/invenio_rdm_records/src/deposit/fields/CreatibutorsField/CreatibutorsField.js @@ -20,6 +20,9 @@ import { CreatibutorsFieldItem } from "./CreatibutorsFieldItem"; import { CREATIBUTOR_TYPE } from "./type"; import { sortOptions } from "../../utils"; import { i18next } from "@translations/invenio_rdm_records/i18next"; +import { OverridableContext, overrideStore } from "react-overridable"; + +const overriddenComponents = overrideStore.getAll(); const creatibutorNameDisplay = (value) => { const creatibutorType = _get(value, "person_or_org.type", CREATIBUTOR_TYPE.PERSON); @@ -107,21 +110,23 @@ class CreatibutorsFieldForm extends Component { ); })} - - - {addButtonLabel} - - } - /> + + + + {addButtonLabel} + + } + /> + {creatibutorsError && typeof creatibutorsError == "string" && (