Compare commits
1 Commits
| Author | SHA1 | Date |
|---|---|---|
|
|
124685b712 |
|
|
@ -137,12 +137,25 @@ export function EovDetailRenderer({
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!isEmptyValue(data.pathway)) {
|
if (!isEmptyValue(data.pathway)) {
|
||||||
|
const pathwayItems = Array.isArray(data.pathway)
|
||||||
|
? asStringArray(data.pathway)
|
||||||
|
: typeof data.pathway === "string"
|
||||||
|
? data.pathway
|
||||||
|
.split(/(?<=[.!?])\s+/)
|
||||||
|
.map((s) => s.trim())
|
||||||
|
.filter((s) => s.length > 0)
|
||||||
|
: [];
|
||||||
|
|
||||||
items.push({
|
items.push({
|
||||||
key: "pathway",
|
key: "pathway",
|
||||||
order: orderFor("pathway", 120),
|
order: orderFor("pathway", 120),
|
||||||
render: () => (
|
render: () => (
|
||||||
<SectionCard title="Pathway">
|
<SectionCard title="Pathway">
|
||||||
<Text style={styles.pathway}>{asString(data.pathway)}</Text>
|
{pathwayItems.length > 0 ? (
|
||||||
|
<BulletList items={pathwayItems} />
|
||||||
|
) : (
|
||||||
|
<Text style={styles.pathway}>{asString(data.pathway)}</Text>
|
||||||
|
)}
|
||||||
</SectionCard>
|
</SectionCard>
|
||||||
),
|
),
|
||||||
});
|
});
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue