programlibs/Format/demos/invoice.xtl
An invoice: items, quantities and prices set as a table, money to 2 places, a total with thousands separated, the tax as a percentage. Run with "just demo Format invoice".
body : Box Char
body ← (5 1 r̲eshape items) c̲at₂ (5 1 r̲eshape 'f̲ormat m̲ap qty) c̲at₂ (5 1 r̲eshape 2 ᶠf̲ixed price) c̲at₂ 5 1 r̲eshape 2 ᶠf̲ixed amount
Used in: libs/Format/demos/invoice.xtl:15