def spend.body
import cswap-bend-cli@0.1.0.0/render.bend as Renderimport Base
import cswap-bend-cli@0.1.0.0/view.bend as View
106def spend.body(c: Maybe<&2, View.Cell>, +pct: U32, +used: String, +limit: String) -> String:
107 match c:
108 case Some{View.Cell{cd, ck}}:
109 pct_text(pct) ++ " resets " ++ padr(ck, 12n) ++ " $" ++ used ++ " / $" ++ limit
110 case None{}:
111 pct_text(pct) ++ " $" ++ used ++ " / $" ++ limit