Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ A pnpm workspace. Every package in `packages/` is published to npm under its own
- `packages/zoom` is `comark-zoom`.
- `src/index.ts` is the parse plugin. It marks content images and adds one `zoom-runtime` node to a document with anything to zoom.
- `src/script.ts` is the browser script. `script()` is self-contained because the HTML renderer inlines its source. `src/client.ts` exports `start()`, which runs it with the bundled styles; Vue, React, and Svelte components call it on mount and stop it on unmount.
- `src/theme.ts` resolves the shared `--comark-*` tokens, and `comark-zoom/theme` exports it alone. `comark-github-callouts` has it as a dev dependency and bundles only this entry, so callouts don't install zoom or carry its styles.
- `src/html.ts`, `src/vue.ts`, `src/react.ts`, and `src/svelte/` are the renderers. They all output the same markup.
- `docs/` builds the docs site with the plugins themselves. Cloudflare serves it from `docs/dist`.

Expand Down
4 changes: 1 addition & 3 deletions packages/github-callouts/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -55,16 +55,14 @@
"doctor": "vite-doctor . --no-cache --max-warnings 0 --format text",
"prepack": "pnpm --filter comark-github-callouts... build"
},
"dependencies": {
"comark-zoom": "workspace:*"
},
"devDependencies": {
"@comark/html": "catalog:",
"@comark/react": "catalog:",
"@comark/vue": "catalog:",
"@types/react": "catalog:",
"@types/react-dom": "catalog:",
"comark": "catalog:",
"comark-zoom": "workspace:*",
"react": "catalog:",
"react-dom": "catalog:",
"svelte": "catalog:",
Expand Down
2 changes: 1 addition & 1 deletion packages/github-callouts/src/styles.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { theme } from "comark-zoom/client";
import { theme } from "comark-zoom/theme";

const types = ["note", "tip", "important", "warning", "caution"];

Expand Down
1 change: 1 addition & 0 deletions packages/zoom/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@
"svelte": "./dist/svelte/index.js",
"default": "./dist/svelte/index.js"
},
"./theme": "./dist/theme.mjs",
"./vue": "./dist/vue.mjs",
"./package.json": "./package.json"
},
Expand Down
9 changes: 8 additions & 1 deletion packages/zoom/tsdown.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,14 @@ import { defineConfig } from "tsdown";
import { css } from "./src/styles.ts";

export default defineConfig({
entry: ["src/index.ts", "src/html.ts", "src/client.ts", "src/vue.ts", "src/react.ts"],
entry: [
"src/index.ts",
"src/html.ts",
"src/client.ts",
"src/theme.ts",
"src/vue.ts",
"src/react.ts",
],
format: ["esm"],
dts: true,
clean: true,
Expand Down
7 changes: 3 additions & 4 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading