ROR |
- Name |
+ {/* Name | */}
Number of affiliations |
Added by |
Removed by |
@@ -441,14 +449,16 @@ export default function Affiliations() {
uniqueRor.rorId,
) ? ({` https://ror.org/${uniqueRor.rorId}`}) : (` https://ror.org/${uniqueRor.rorId}`)}
-
-
- {getFlagEmoji(uniqueRor.rorCountry)}
-
+ {/* |
+ */}
+
+
+
{removeList.includes(
uniqueRor.rorId,
) ? ({uniqueRor.rorName}) : (uniqueRor.rorName)}
+ {getFlagEmoji(uniqueRor.rorCountry)}
|
{uniqueRor.countAffiliations}
@@ -460,11 +470,12 @@ export default function Affiliations() {
| {uniqueRor.addedBy} |
{uniqueRor.removedBy} |
- {removeList.includes(
- uniqueRor.rorId,
- ) ? (
- <>
-
+ ) : (
+ setRemoveList((prevList) => [
+ ...prevList,
+ uniqueRor.rorId,
+ ])}
+ size="sm"
+ title="Remove ROR"
+ variant="secondary"
>
- Removed
-
- >
- ) : (
+ Remove this ROR
+
+ )}
+ {(uniqueRor.countAffiliations < selectedOpenAlex.length) && (
setRemoveList((prevList) => [
+ aria-label="Propagate ROR to all affiliations"
+ className="fr-ml-1w"
+ color="green-emeraude"
+ disabled={
+ uniqueRor.countAffiliations
+ === selectedOpenAlex.length
+ }
+ icon="chat-check-line"
+ onClick={() => setAddList((prevList) => [
...prevList,
uniqueRor.rorId,
])}
size="sm"
- title="Remove ROR"
- />
+ title={`Propagate ROR to ${selectedOpenAlex?.length ?? 0 - uniqueRor.countAffiliations} affiliations`}
+ variant="secondary"
+ >
+ Propagate this ROR
+
)}
- {(uniqueRor.countAffiliations < selectedOpenAlex.length) && (
- setAddList((prevList) => [
- ...prevList,
- uniqueRor.rorId,
- ])}
- size="sm"
- title={`Propagate ROR to ${selectedOpenAlex?.length ?? 0 - uniqueRor.countAffiliations} affiliations`}
- />
- )}
- {(addList.includes(uniqueRor.rorId)) && (
+ {/* {(addList.includes(uniqueRor.rorId)) && (
Added
- )}
+ )} */}
+
|
),
@@ -556,10 +570,11 @@ export default function Affiliations() {
aria-label="Add ROR"
color="blue-ecume"
disabled={['', 'error'].includes(rorMessageType)}
- onClick={() => {
- setAddList([...addList, ror]);
- setRor('');
- }}
+ // onClick={() => {
+ // setAddList([...addList, ror]);
+ // setRor('');
+ // }}
+ onClick={() => getRorData()}
title="Add ROR"
>
+ Add