Proto-UI/Proto-UI

[shadcn] Project Base Textarea into the shadcn design language

已關閉

#382 建立於 2026年8月13日

 (1 則留言) (0 個反應) (0 位負責人)TypeScript (12 個分叉)auto 404
F3 – Moderatearea: prototypeshelp wanted

倉庫指標

星標
 (29 顆星)
PR 合併指標
 (PR 指標待抓取)

描述

Classification

  • Ledger: shadcn design-language projection
  • Base owner: P-BASE-TEXTAREA (status: draft)
  • New Base protocol: none

Goal

Project the current merged host-mediated Base Textarea protocol into @proto.ui/prototypes-shadcn while keeping the physical plain-text multiline editor and editing lifecycle host-owned.

Contract boundary

  • Base owns controlled/uncontrolled value, normalized input/change/IME events, accessibility projection, focus/blur, and one physical editor.
  • The shadcn projection owns classes, sizing, border, focus-ring, disabled, and invalid presentation only where those states already exist.
  • The renderer stays contentless; authored children do not become a fake editor.

Delivery surface

  • packages/prototypes/shadcn/src/textarea/
  • P-SHADCN-TEXTAREA
  • exact package/root exports and public CLI registry projection
  • packages/prototypes/shadcn/test/textarea.test.ts
  • EN/ZH docs at apps/www/src/content/docs/{en,zh-cn}/ui-libraries/shadcn/textarea.mdx
  • real demo apps/www/src/content/docs/zh-cn/demo-shadcn-textarea.demo.ts
  • preview registry, component preset/token closure, and generated Agent projection

Acceptance criteria

  • The projection consumes Base Textarea and materializes exactly one host-owned multiline editor.
  • Controlled/uncontrolled value, dirty-value preservation, IME, live properties, accessibility, and physical focus behavior remain unchanged.
  • No second editor, authored-child renderer, form workflow, validation message, auto-resize, rich-text, or announcement protocol is introduced.
  • Exact exports and supported visual states are asserted.
  • Docs distinguish Base editing guarantees from shadcn visual choices.
  • The real package export renders through Web Component, React, and Vue previews.
  • Focused tests, catalog, preset/token, types, docs, and proportional workspace checks pass.

Out of scope

  • Base Input or a generalized Native Control protocol.
  • Auto-grow, rich text, form submission, and validation orchestration.

貢獻者指南