Fixed-size layout helpers for agent-code-style terminal shells.
Fixed-size layout helpers for agent-code-style terminal shells.
(block text width height & {:keys [from] :or {from :top}})Fit text into a fixed width/height block.
Options:
:from :top|:bottom controls which lines survive vertical overflow.Fit text into a fixed width/height block. Options: - `:from :top|:bottom` controls which lines survive vertical overflow.
(columns cols height)Join fixed-size columns into a block of height rows.
Each column is a map with :content, :width, and optional :from.
Join fixed-size columns into a block of `height` rows. Each column is a map with `:content`, `:width`, and optional `:from`.
(line text width)Fit one display line to width by truncating at the tail and right-padding.
Fit one display line to width by truncating at the tail and right-padding.
(rule width)(rule width ch)Return a horizontal rule of width columns.
Return a horizontal rule of `width` columns.
(split-lines text)Split text into terminal lines, preserving an empty line for nil/empty input.
Split text into terminal lines, preserving an empty line for nil/empty input.
(stack & parts)Join vertical blocks, skipping nil parts.
Join vertical blocks, skipping nil parts.
cljdoc builds & hosts documentation for Clojure/Script libraries
| Ctrl+k | Jump to recent docs |
| ← | Move to previous article |
| → | Move to next article |
| Ctrl+/ | Jump to the search field |