Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

💡 Per-side border colors

Open
#69 0 comments 0 reactions 1 assignee View on GitHub

@rauhryan is already working on this.

Since Jun 10, 2026.

Assessment

This issue has not been assessed yet.

Description

enhancement

Is your feature request related to a problem?

A border applies one color to all four sides—there's no way to color sides independently. You can't draw a box with, say, a red top edge and a green bottom edge, or give one side its own background. The border op only takes scalar per-side widths plus a single shared color.

Describe the solution you'd like

Let each side accept a structured form { width, color? } (in addition to the scalar width), overriding the shared color for that edge:

open("box", {
  border: {
    color: rgba(255, 255, 255), // shared fallback
    top: { width: 1, color: rgba(255, 0, 0) }, // red top
    bottom: { width: 1, color: rgba(0, 255, 0) }, // green bottom
    left: 1,
    right: 1,
  },
});

The shared color stays the fallback for any side that doesn't override. Once #68 lands, the same design should apply for bg.

Describe alternatives you've considered

Nesting four separate single-edge bordered elements to recolor each side is possible but explodes the element count, doesn't share corners cleanly, and is fragile under resize. Per-side data belongs on the one border op.

Additional context

Failing test case on nm/repro/border-per-side (test · diff).

Today the border op carries one color plus a single packed width word; render_border (src/clayterm.c:300) draws every edge with that one color. Per-side color/bg needs the border type (ops.ts) to accept { width, color?, bg? } per side and additional words in the border wire format—ideally the same per-side encoding being added in the feat/border-style branch.

Dominant language
TypeScript
Stars
42
Forks
2
Avg merge
2d 5h
Merged PRs (30d)
12

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from bombshell-dev/tty

All issues in bombshell-dev/tty

Similar issues

More TypeScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.