npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

pi-comfy-ui

v0.2.2

Published

Comfortable spacing and panel styling for Pi's interactive TUI.

Readme

pi-comfy-ui

Comfortable spacing and panel styling for Pi's interactive TUI.

pi-comfy-ui preview

Install

pi install npm:pi-comfy-ui

Project-local install only:

pi install -l npm:pi-comfy-ui

Then restart Pi, or run /reload if Pi is already open.

For project-local installs, Pi loads this extension only after the project is approved/trusted. The first trust prompt itself uses Pi's default styling; pi-comfy-ui applies after approval.

Configure

The package defaults to comfortable internal padding without modifying global settings:

{
  "editorPaddingX": 1,
  "contentPaddingX": 1
}

Override either value in Pi settings when you want different spacing:

  • Global/user settings: ~/.pi/agent/settings.json

  • Project/local settings: .pi/settings.json (overrides global)

  • editorPaddingX is Pi's native inner input/editor padding. If unset, this package uses 1 internally for its custom editor.

  • contentPaddingX is this package's outer layout padding for transcript, widgets, footer, input panel alignment, and interactive prompt overlays. If unset, this package uses 1 internally.

  • The input/editor background is painted from the active theme token customMessageBg.

  • Interactive prompt panels, such as settings, model selection, confirms, selects, and structured questions, are painted from the active theme token userMessageBg.

  • The input/editor keeps Pi's original editor border color, but renders that border on the left and right sides only; Pi's native top/bottom editor border is hidden.

  • Interactive prompt panels keep Pi's original border line color, but replace the top/bottom border shape with left/right side rails.

Supported aliases for outer layout padding:

  • contentPaddingX
  • layoutPaddingX
  • PI_CONTENT_PADDING_X environment variable

The extension clamps editor and content padding to safe ranges and reduces content padding automatically on narrow terminals.

How it works

Pi does not currently expose a public root-layout wrapper hook for extensions. This package uses a narrow monkey patch on root TUI.render() to apply outer padding to the rendered frame. It also patches overlay component rendering so interactive prompt overlays stay inside the same contentPaddingX boundary.

This keeps the change package-local, avoids editing the globally installed Pi files, and keeps Pi's native editorPaddingX responsible for input padding.

The input background uses Pi's theme palette through customMessageBg; there is no separate extension color setting. Interactive prompt panel backgrounds use userMessageBg. In both cases, pi-comfy-ui preserves the original border color and only changes the border shape plus the painted background.

Because this extension monkey-patches shared TUI rendering, it may conflict with another extension that patches the same render surfaces. The patch is guarded with global Symbols to avoid double-patching itself.

contentPaddingX is an outer margin. editorPaddingX remains the inner padding inside the input panel.