@delacour/react-native-ui

中文文档
0.9.0发布于 2026/11/11MITES Module构建来源已验证近 30 天下载 1.3万

反应原生UI组件——Unindow,再动,手势处理器

中文使用文档
文档目录6 节
  1. 安装
  2. 设置
  3. 使用量
  4. 构成部分
  5. 他们
  6. 文档

@delacour/反应-亲-ui

一个反应原生组件库. 时髦是 单风 — 尾风 v4 反应 原生;相互作用为再动和手势;偶发性为Pulsar.

包裹 生船 .tsx 没有建设步骤. Uninwind的变换必须 运行在消费应用的地铁管道, 所以预编成的建筑会 班级名已经死亡.

安装

bun add @delacour/react-native-ui

原生模块是 同行依赖关系,因为两份原生模块 注册两次,运行时中断。 完整列表——本地模块通过 expo install,其余的通过您的软件包管理器——来自 部件自进口并保持 安装页面。 。 。 . 六对等者是可选的,只有在您导入需要它们的子路径时才会解决:

端点需要时间
expo-router@delacour/react-native-ui/expo/navigation-theme
@legendapp/listScreen.LegendList, (中文(简体) ), Screen.ChatList 财务报告和审定财务报表 BottomSheet.LegendList
react-native-screens本地堆栈导航
@delacour/react-native-chartsChart
@delacour/react-native-bottom-sheetBottomSheet ——它剥取的发动机
react-native-teleportBottomSheet ——引擎的出入口;本地模块,在安装后重建dev客户端

颗粒出口才是安全之处:从未进口过子路径的应用程序 从来没有让Metro解决它的同行.

设置

1. 样式. 在你的应用 global.css数字 :

@import '@delacour/react-native-ui/styles';
@source '../../../../packages/react-native-ui/src';

使用真实的工作空间路径, 而不是一个 node_modules 1 — Bun 链接工作空间 软件包和Tailwind的扫描仪无法跟随符号链接,所以类是 静静地从生产建筑中掉下来.

2. 供应商. 包接应用程序的根 :

import { DelacourProvider } from "@delacour/react-native-ui/provider";

<DelacourProvider>{children}</DelacourProvider>;

这是手势根 每一个 Pressable 安全区供应商 键盘提供者 Screen 读取,并保存它们的键盘状态同步 诚实 一个应用与一个 BottomSheet 挂载 BottomSheetProvider 里面,从 @delacour/react-native-ui/bottom-sheet - 工作表的引擎是一个可选的对等器, 所以供养者不能.

使用量

有一个 没有包式枪管. 从子路径导入 :

import { Button } from "@delacour/react-native-ui/button";
import { Icon } from "@delacour/react-native-ui/icon";
import { IconArrowRight } from "@delacour/react-native-ui/icons/central";

// The icon inherits the button's size and its variant's colour.
<Button haptic="selection" onPress={next}>
  <Button.Label>Continue</Button.Label>
  <Icon icon={IconArrowRight} />
</Button>;

构成部分

构成部分导入
手风琴@delacour/react-native-ui/accordion选择模式、计量面板、指标
徽标@delacour/react-native-ui/badge备选案文、颜色、大小、删除
底盘@delacour/react-native-ui/bottom-sheet接合点、键盘、粘贴脚印、可滚动、步骤、可分解、可传送门户
按钮@delacour/react-native-ui/button变体、大小、图标、加载
复选框@delacour/react-native-ui/checkbox颜色、大小、不确定、组合
外地@delacour/react-native-ui/field形式布局、组合、状态级联
图标@delacour/react-native-ui/icon中央图标,带有继承大小和颜色
投入@delacour/react-native-ui/input变量、大小、前缀和后缀
列表组@delacour/react-native-ui/list-group分组行、分隔符、槽
可压缩@delacour/react-native-ui/pressable手势,险道, asChild
无线电@delacour/react-native-ui/radio组、选择、大小、方向
屏幕@delacour/react-native-ui/screen导航栏、页脚、可滚动键盘
分隔符@delacour/react-native-ui/separator方向、套件、重量
幻灯片@delacour/react-native-ui/slider范围、方向、颜色、步骤
旋转器@delacour/react-native-ui/spinner大小、 颜色、 自定义格言
切换@delacour/react-native-ui/switch拖放或自带、 颜色、 大小、 结尾内容
标签@delacour/react-native-ui/tabs变体、大小、刷取、滚动
文本@delacour/react-native-ui/text类型尺度、预设、内嵌式筑巢
德拉库尔提供商@delacour/react-native-ui/provider应用程序的根层堆栈

也导出 : hooks/*, (中文(简体) ), lib/*, (中文(简体) ), expo/navigation-theme, (中文(简体) ), icons/central,以及 页:1 styles/* CSS条目.

他们

键是 CSS 下的变量 @variant light 编号 : @variant dark组件 参考语义名称 - bg-background, (中文(简体) ), text-muted-foreground - 从不生 调色板颜色或一个 dark: 前缀。 对于需要颜色的道具 价值 相当 而非类,使用 useThemeColor。 。 。 .

文档

AGENTS.md 是参考文献——规则、模式和 每项决定背后的推理。 每个部分都有自己的来源 内 src/components。 。 。 .

版本与发布记录

@delacour/react-native-ui 共发布 160 个版本,首次发布于 2026/09/22;过去 12 个月发布了 160 个版本。最新版本附带 npm provenance 构建来源证明,可追溯到公开的 CI 构建记录。

版本发布日期距今
0.9.0latest2026/11/111 天前
0.9.0-alpha.20261110170610alpha2026/11/111 天前
0.9.0-alpha.202611092058422026/11/102 天前
0.9.0-alpha.202611092057322026/11/102 天前
0.9.0-alpha.202611092050532026/11/102 天前
0.9.0-alpha.202611092017592026/11/102 天前

关于 @delacour/react-native-ui 的常见问题

@delacour/react-native-ui 是什么?

反应原生UI组件——Unindow,再动,手势处理器

如何安装 @delacour/react-native-ui?

在项目目录运行 npm install @delacour/react-native-ui,或使用 pnpm add / yarn add / bun add。它还需要宿主项目提供 peer 依赖:react(>=19)、uniwind(^1.11.0)、tailwindcss(^4)、react-native(>=0.88)、react-native-svg(>=15)、react-native-pulsar(^1.7.0)、expo-linear-gradient(>=15)、react-native-worklets(>=0.5)、react-native-reanimated(>=4)、react-native-gesture-handler(>=3.3)、react-native-safe-area-context(>=5)、react-native-keyboard-controller(>=1.18)、@central-icons-react-native/round-outlined-radius-1-stroke-1.5(^1.1)。npm 7 及以上与 pnpm 8 及以上默认会自动安装必需的 peer 依赖,Yarn 需要手动安装。

@delacour/react-native-ui 支持 TypeScript 吗?

该包的 package.json 没有声明类型入口。需要类型提示时,可以在 npm 上查找社区维护的 @types/delacour__react-native-ui 是否存在。

@delacour/react-native-ui 支持 ESM 还是 CommonJS?

以 ES Module 形式发布,推荐使用 import 引入。在 CommonJS 项目中,Node.js 20.19+ / 22.12+ 可以直接 require() 不含顶层 await 的 ES Module,更早的版本需要改用动态 import()。

@delacour/react-native-ui 可以商用吗?

@delacour/react-native-ui 使用 MIT 许可。宽松许可:允许商业使用、修改和再分发,通常只需在分发时保留原版权与许可声明。以上为概括,不构成法律意见,请以许可原文为准。

@delacour/react-native-ui 的下载量有多少?

根据 npm 官方下载统计,@delacour/react-native-ui 在 2026/10/12 – 2026/11/10 这 30 天内被下载 13,376 次,日均约 446 次。下载量会把 CI 构建、镜像同步和作为其他包依赖的安装一并计入,适合横向比较热度,不能直接等同于使用人数。

@delacour/react-native-ui 还在维护吗?

最新版本 0.9.0 发布于 2026/11/11(1 天前);至今共发布 160 个版本,其中过去 12 个月发布了 160 个;首次发布于 2026/09/22。发布频率只是参考信号:功能稳定的工具可能很少需要更新,建议结合源码仓库的 issue 和提交记录判断。