untrusted
Helpers for text written by agents or people: removes code points that hide text from the reader.
stripInvisible("Pay\u{E0049}\u{E0047}\u{E004E}\u{E004F}\u{E0052}\u{E0045} the invoice") // "Pay the invoice"Installation
Once per app, set up Aedis UI. The CLI verifies the signed release before writing anything and pins every dependency:
npx @aedis/cli@0.1.0 initImport the theme once in your global CSS, after Tailwind:
app/globals.css
@import "tailwindcss";@import "./styles/aedis-theme.css";Then add the component:
npx @aedis/cli@0.1.0 add untrusted# pnpm dlx @aedis/cli@0.1.0 add untrusted · yarn dlx @aedis/cli@0.1.0 add untrusted · bunx @aedis/cli@0.1.0 add untrustedProps
| Prop | Type | Default | Description |
|---|---|---|---|
| stripInvisible | (text: string) => string | — | Removes zero-width, bidi-override and Unicode-tag code points. |
| hasInvisible | (text: string) => boolean | — | Whether the text carries any of them. |
Security
- Markdown, Chat, Approval Card and Hand Raise already apply it to what they show and send.
- Zero-width joiner/non-joiner and LRM/RLM are kept: emoji and right-to-left scripts need them.