Pad a part with spaces in all directions.
import {Draw} from 'effect-tree'const {drawPart, padPart, text} = Drawconst part = text('foo')const padded = padPart( part, {top: 1, right: 1, bottom: 1, left: 1},)expect(drawPart(padded)).toEqual([ ' ', ' foo ', ' ',]) Copy
import {Draw} from 'effect-tree'const {drawPart, padPart, text} = Drawconst part = text('foo')const padded = padPart( part, {top: 1, right: 1, bottom: 1, left: 1},)expect(drawPart(padded)).toEqual([ ' ', ' foo ', ' ',])
Pad a part with spaces in all directions.
Example