import { Component, For, Match, Show, Switch } from "solid-js";
import { Anchor } from "../../Anchor";
import { FieldString } from "../typed/FieldString";
import { CellValueHpo } from "../../../types/configCellComposed";
type HpoTerm = {
label: string;
href: string;
};
export const FieldHpo: Component<{
value: CellValueHpo;
}> = (props) => {
const hpoTerms = (): HpoTerm[] =>
props.value.hpos.map((category) => ({
label: category!.label,
href: `https://hpo.jax.org/app/browse/term/${encodeURI(category!.value!)}`,
}));
const gadoPd = () => props.value.gadoPd || null;
return (
<>
{(hpoTerm, i) => (
<>
{i() !== 0 && , }
>
)}
{(gadoPd) => (
)}
>
);
};