Skip to content

Commit

Permalink
style: make unimportant definition parts muted color
Browse files Browse the repository at this point in the history
  • Loading branch information
louismollick committed Oct 17, 2024
1 parent 461de12 commit cbb3311
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 7 deletions.
14 changes: 9 additions & 5 deletions src/app/_components/wordReadingCard.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -43,15 +43,15 @@ function WordConj({ conj }: { conj?: Conj[] }) {
{!!conj.prop?.length &&
conj.prop.map((prop, propIdx) => (
<p key={propIdx} className="mb-1">
<span className="mr-1 text-green-600">[{prop.pos}]</span>
<span>{prop.type}</span>
<span className="mr-1 text-green-600">{`[${prop.pos}]`}</span>
<span className="text-muted-foreground">{prop.type}</span>
</p>
))}
{conj.reading && <p className="font-bold">{conj.reading}</p>}
<WordGloss gloss={conj.gloss} className="ml-3 mt-1" />
{conj.via?.length && (
<div className="ml-4">
via
<span className="text-muted-foreground">{"via"}</span>
<WordConj conj={conj.via} />
</div>
)}
Expand All @@ -73,7 +73,8 @@ function WordReadingContent({
{showReading && <p className="py-1 font-bold">{wordReading.reading}</p>}
{wordReading.compound?.length && (
<p className="my-1">
Compound word: {wordReading.compound.join(" + ")}
<span className="text-muted-foreground">{"Compound word: "}</span>
{wordReading.compound.join(" + ")}
</p>
)}
{wordReading.components?.length && (
Expand All @@ -84,7 +85,10 @@ function WordReadingContent({
</ol>
)}
{wordReading.suffix && (
<p className="ml-3 mt-1">Suffix: {wordReading.suffix}</p>
<p className="ml-3 mt-1">
<span className="text-muted-foreground">{"Suffix: "}</span>
{wordReading.suffix}
</p>
)}
<WordConj conj={wordReading.conj} />
<WordGloss gloss={wordReading.gloss} />
Expand Down
4 changes: 2 additions & 2 deletions src/types/ichiran.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ export type Word = [

export type WordAlternatives =
| {
alternative: WordReading[];
}
alternative: WordReading[];
}
| WordReading;

// Raw format we receive fromt Ichiran
Expand Down

0 comments on commit cbb3311

Please sign in to comment.