Card.age_note: def of cswap-bend-cli@0.1.0.0 Import: import cswap-bend-cli@0.1.0.0/tui/card.bend as Card Lines 46-52 of cswap-bend-cli@0.1.0.0/tui/card.bend: https://jend.leeeet.dev/read.txt?path=cswap-bend-cli@0.1.0.0/tui/card.bend&start_line=46&end_line=52 import Base import cswap-bend-cli@0.1.0.0/tui/fmt.bend as F # The measurement age note, shown once a reading is at least 3 minutes old. def age_note(+g: Maybe<&2, U32>) -> List<&2, F.Seg>: match g: case None{}: [] case Some{s}: flag_if(U32.is_ge(s, 180), muted(" ยท " ++ F.duration(s) ++ " ago")) Uses (9): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=List https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Maybe https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=String.append https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32 https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32.is_ge https://jend.leeeet.dev/definition.txt?path=cswap-bend-cli@0.1.0.0/tui/card.bend&name=flag_if https://jend.leeeet.dev/definition.txt?path=cswap-bend-cli@0.1.0.0/tui/card.bend&name=muted https://jend.leeeet.dev/definition.txt?path=cswap-bend-cli@0.1.0.0/tui/fmt.bend&name=Seg https://jend.leeeet.dev/definition.txt?path=cswap-bend-cli@0.1.0.0/tui/fmt.bend&name=duration