extra-ordinary-vessel #70
|
|
@ -126,6 +126,22 @@ export function ExtraOrdinaryVesselsDetailRenderer({
|
||||||
}, [data, definitions, presentationAttributes]);
|
}, [data, definitions, presentationAttributes]);
|
||||||
|
|
||||||
const renderAttributeValue = (key: string, value: unknown, emptyText: string | null) => {
|
const renderAttributeValue = (key: string, value: unknown, emptyText: string | null) => {
|
||||||
|
if (key === "clinical_manifestation" || key === "clinical_manifestations") {
|
||||||
|
const items = Array.isArray(value)
|
||||||
|
? asStringArray(value)
|
||||||
|
: typeof value === "string"
|
||||||
|
? value
|
||||||
|
.split(/,\s*(?![^()]*\))/)
|
||||||
|
.map((s) => s.trim().replace(/\.$/, ""))
|
||||||
|
.filter(Boolean)
|
||||||
|
.map((s) => s.charAt(0).toUpperCase() + s.slice(1))
|
||||||
|
: [];
|
||||||
|
|
||||||
|
if (items.length > 0) {
|
||||||
|
return <BulletList items={items} />;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (Array.isArray(value)) {
|
if (Array.isArray(value)) {
|
||||||
const strings = asStringArray(value);
|
const strings = asStringArray(value);
|
||||||
if (strings.length > 0) {
|
if (strings.length > 0) {
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue