Native Shell
Native Shell:AI 生成的 UI,在你的应用中原生呈现,覆盖每个平台。iOS、Android、macOS、Windows 与 Linux 上的应用、GPUI 应用与网页在运行时加载已签名、沙箱隔离的 TSX 模块并绘制 th
AI 翻译
个人 GitHub 账号下公开仓库的所有者可以登录并验证所有权,自行管理介绍,无需管理员批准。
登录并生成验证文件,在 30 分钟内将其提交到此仓库的默认分支。其他分支或分叉仓库中的文件无效。然后在下方检查文件,即可无需管理员批准直接管理项目。请保留文件以维持管理权限。
如需登录,将前往登录页面。登录后请回到此处,再次点击所选的验证按钮。
在项目文件夹中运行 /nomorevibe verify,即可验证所有权并自行管理介绍。
一分钟完成验证Read and write Apple Pages, Numbers and Keynote documents in pure TypeScript. Zero runtime dependencies, byte-identical round trips, no Mac required.
翻译准备中
取自仓库 README
正在加载完整 README。
查看完整 README ↗Open, edit, and save Apple Pages, Numbers, and Keynote documents—anywhere JavaScript runs. Pure TypeScript, zero runtime dependencies, no Mac required. You work with paragraphs, cells, and slides; the bytes take care of themselves.
Docs: https://den-frie-vilje.github.io/cupertino-files/
npm install cupertino-files
import { readFileSync, writeFileSync } from "node:fs";
import { PagesDocument, NumbersDocument } from "cupertino-files";
const doc = PagesDocument.load(new Uint8Array(readFileSync("report.pages")));
doc.replaceText("2024", "2025");
doc.appendParagraph("Conclusion", "Heading 1");
writeFileSync("report-2025.pages", doc.save());
const sheet = NumbersDocument.load(new Uint8Array(readFileSync("budget.numbers")));
const table = sheet.tables()[0]!;
table.setCell(1, 1, 143_800);
table.setFormula(1, 2, "=B2*1.25", { value: 179_750 });
writeFileSync("budget.numbers", sheet.save());
Everything you don't touch is preserved byte-for-byte (how). Works in Node 22 or later and modern browsers, ESM-only. Bytes in, bytes out.
The format is undocumented; this library is an ongoing
reverse-engineering of it, measured from real documents.
docs/COVERAGE.md is the always-current answer to
"does it do X?". The short version:
=SUM(A1:A5), =Other::B2); 363 functionsNumbersDocument.blank() and friends: a fresh A4 document or 16:9 deck, no template file neededdoc.audit() names the faults a person otherwise finds by opening the document, and save() refuses an archive missing a required fieldDeeper detail, per capability and with the evidence: the capability matrix · what each open question waits on · the format itself.
npx -y cupertino-files dump info file.pages inspects; export file.key prints Markdown (--format csv a table); import notes.md deck.key builds a document; call runs any editing tool from the shellnpx -y cupertino-files mcp: an MCP server whose tools create, edit, format, and export documents, plus a Claude Code skill in the packageMore in For AI agents and the API reference.
npm install && npm test # unit + fixture suite; never launches an app
npm run test:e2e # macOS only: drives the real apps
Contributions are warmly welcome—CONTRIBUTING.md shows the way, and docs/BLOCKERS.md lists questions where a few minutes with a Mac genuinely helps. Test fixtures are real Apple-written documents from open-source test suites and public repositories (attribution).
Built on the shoulders of iWorkFileFormat, keynote-parser, numbers-parser and WorkKit.
An independent project, not affiliated with or endorsed by Apple Inc. Apple, iWork, Pages, Numbers, and Keynote are trademarks of Apple Inc., used only to name the formats this library interoperates with. It contains no Apple code and declines encrypted documents by design; details in docs/LEGAL.md.
MIT © Ole Kristensen