Skip to content

Commit

Permalink
affiliations: exporting helper functions
Browse files Browse the repository at this point in the history
  • Loading branch information
0einstein0 committed Nov 25, 2024
1 parent f6ac055 commit 470cce7
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import { Image } from "../../../Image";
import { Header } from "semantic-ui-react";
import Overridable from "react-overridable";

const makeIdEntry = (identifier) => {
export const makeIdEntry = (identifier) => {
let icon, link;

switch (identifier.scheme) {
Expand Down Expand Up @@ -45,7 +45,7 @@ const makeIdEntry = (identifier) => {
);
};

const makeSubheader = (creatibutor, isOrganization) => {
export const makeSubheader = (creatibutor, isOrganization) => {
if (isOrganization) {
const locationPart = [creatibutor?.location_name, creatibutor?.country_name]
?.filter(Boolean)
Expand Down
3 changes: 2 additions & 1 deletion src/lib/elements/contrib/invenioRDM/records/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,5 @@
* // under the terms of the MIT License; see LICENSE file for more details.
*/

export { AffiliationsSuggestions } from "./AffiliationsSuggestions";
export { AffiliationsSuggestions, makeIdEntry, makeSubheader } from "./AffiliationsSuggestions";

Check failure on line 9 in src/lib/elements/contrib/invenioRDM/records/index.js

View workflow job for this annotation

GitHub Actions / Tests (18.x)

Replace `·AffiliationsSuggestions,·makeIdEntry,·makeSubheader·` with `⏎··AffiliationsSuggestions,⏎··makeIdEntry,⏎··makeSubheader,⏎`

Check failure on line 9 in src/lib/elements/contrib/invenioRDM/records/index.js

View workflow job for this annotation

GitHub Actions / Tests (16.x)

Replace `·AffiliationsSuggestions,·makeIdEntry,·makeSubheader·` with `⏎··AffiliationsSuggestions,⏎··makeIdEntry,⏎··makeSubheader,⏎`

Check failure on line 9 in src/lib/elements/contrib/invenioRDM/records/index.js

View workflow job for this annotation

GitHub Actions / Tests (18.x)

Replace `·AffiliationsSuggestions,·makeIdEntry,·makeSubheader·` with `⏎··AffiliationsSuggestions,⏎··makeIdEntry,⏎··makeSubheader,⏎`

Check failure on line 9 in src/lib/elements/contrib/invenioRDM/records/index.js

View workflow job for this annotation

GitHub Actions / Tests (16.x)

Replace `·AffiliationsSuggestions,·makeIdEntry,·makeSubheader·` with `⏎··AffiliationsSuggestions,⏎··makeIdEntry,⏎··makeSubheader,⏎`

Check failure on line 10 in src/lib/elements/contrib/invenioRDM/records/index.js

View workflow job for this annotation

GitHub Actions / Tests (18.x)

Delete `⏎`

Check failure on line 10 in src/lib/elements/contrib/invenioRDM/records/index.js

View workflow job for this annotation

GitHub Actions / Tests (16.x)

Delete `⏎`

Check failure on line 10 in src/lib/elements/contrib/invenioRDM/records/index.js

View workflow job for this annotation

GitHub Actions / Tests (18.x)

Delete `⏎`

Check failure on line 10 in src/lib/elements/contrib/invenioRDM/records/index.js

View workflow job for this annotation

GitHub Actions / Tests (16.x)

Delete `⏎`

0 comments on commit 470cce7

Please sign in to comment.