@jxsuite/markup 0.4.8 → 0.4.10

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/README.md +6 -19
  2. package/package.json +2 -2
package/README.md CHANGED
@@ -2,17 +2,10 @@
2
2
 
3
3
  Browser-safe markup conversion utilities shared by the Jx core packages:
4
4
 
5
- - `@jxsuite/markup/html-to-jx`: `htmlToJx(html)` converts an HTML string into
6
- an array of Jx tree nodes (`JxElement | string`), mapping attributes through
7
- `property-information` and inline `style` strings into style objects.
8
- - `@jxsuite/markup/md-html`: `markdownToHtml(markdown)` renders untrusted
9
- markdown (GFM tables/strikethrough/task lists) to a **sanitized** HTML
10
- string. Raw HTML is dropped, event handlers and `javascript:` URLs are
11
- stripped.
12
-
13
- Both pipelines are DOM-free and node-free, with no `node:*` imports, so they
14
- are safe for any bundle target (Jx Studio, Cloudflare Workers, node/Bun CLIs).
15
- The package root re-exports both functions.
5
+ - `@jxsuite/markup/html-to-jx`: `htmlToJx(html)` converts an HTML string into an array of Jx tree nodes (`JxElement | string`), mapping attributes through `property-information` and inline `style` strings into style objects.
6
+ - `@jxsuite/markup/md-html`: `markdownToHtml(markdown)` renders untrusted markdown (GFM tables/strikethrough/task lists) to a **sanitized** HTML string. Raw HTML is dropped, event handlers and `javascript:` URLs are stripped.
7
+
8
+ Both pipelines are DOM-free and node-free, with no `node:*` imports, so they are safe for any bundle target (Jx Studio, Cloudflare Workers, node/Bun CLIs). The package root re-exports both functions.
16
9
 
17
10
  ```ts
18
11
  import { htmlToJx, markdownToHtml } from "@jxsuite/markup";
@@ -24,14 +17,8 @@ markdownToHtml("# Hi\n\n**bold**");
24
17
  // → "<h1>Hi</h1>\n<p><strong>bold</strong></p>"
25
18
  ```
26
19
 
27
- For markdown → Jx _document_ transpilation (frontmatter, directives, Jx
28
- markdown), use `@jxsuite/parser`. This package deliberately stays a thin,
29
- dependency-light conversion layer.
20
+ For markdown → Jx _document_ transpilation (frontmatter, directives, Jx markdown), use `@jxsuite/parser`. This package deliberately stays a thin, dependency-light conversion layer.
30
21
 
31
22
  ## Versioning
32
23
 
33
- The types are published as TypeScript source (like every `@jxsuite` package)
34
- and follow the monorepo's release train. Within the monorepo, packages depend
35
- on it via `workspace:^`. Consumers install `@jxsuite/markup` and import its
36
- `/html-to-jx` and `/md-html` entrypoints (or the root re-export); its only
37
- `@jxsuite` runtime dependency is `@jxsuite/schema`.
24
+ The types are published as TypeScript source (like every `@jxsuite` package) and follow the monorepo's release train. Within the monorepo, packages depend on it via `workspace:^`. Consumers install `@jxsuite/markup` and import its `/html-to-jx` and `/md-html` entrypoints (or the root re-export); its only `@jxsuite` runtime dependency is `@jxsuite/schema`.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jxsuite/markup",
3
- "version": "0.4.8",
3
+ "version": "0.4.10",
4
4
  "description": "Browser-safe markup conversion: HTML → Jx nodes, markdown → sanitized HTML",
5
5
  "license": "MIT",
6
6
  "repository": {
@@ -26,7 +26,7 @@
26
26
  "upgrade": "bun update --latest && bun install"
27
27
  },
28
28
  "dependencies": {
29
- "@jxsuite/schema": "^2.0.0",
29
+ "@jxsuite/schema": "^2.2.0",
30
30
  "hast-util-from-html": "^2.0.3",
31
31
  "hast-util-whitespace": "^3.0.0",
32
32
  "property-information": "^7.2.0",