@haklex/rich-static-renderer 0.0.71 → 0.0.73

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.
package/README.md CHANGED
@@ -10,9 +10,10 @@ pnpm add @haklex/rich-static-renderer
10
10
 
11
11
  ## Peer Dependencies
12
12
 
13
+ `@lexical/code` is provided transitively via `lexical-code-no-prism`. Install it separately only if your app imports `@lexical/code` directly.
14
+
13
15
  | Package | Version |
14
16
  | --- | --- |
15
- | `@lexical/code` | `^0.41.0` |
16
17
  | `@lexical/extension` | `^0.41.0` |
17
18
  | `@lexical/link` | `^0.41.0` |
18
19
  | `@lexical/list` | `^0.41.0` |
@@ -1 +1 @@
1
- {"version":3,"file":"renderBuiltinNode.d.ts","sourceRoot":"","sources":["../../src/engine/renderBuiltinNode.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAiB,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AAsBtD,wBAAgB,iBAAiB,CAC/B,IAAI,EAAE,GAAG,EACT,GAAG,EAAE,MAAM,EACX,QAAQ,EAAE,SAAS,EAAE,GAAG,IAAI,EAC5B,YAAY,EAAE,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,EACjC,WAAW,CAAC,EAAE,MAAM,GACnB,SAAS,CAyLX"}
1
+ {"version":3,"file":"renderBuiltinNode.d.ts","sourceRoot":"","sources":["../../src/engine/renderBuiltinNode.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAiB,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AAsBtD,wBAAgB,iBAAiB,CAC/B,IAAI,EAAE,GAAG,EACT,GAAG,EAAE,MAAM,EACX,QAAQ,EAAE,SAAS,EAAE,GAAG,IAAI,EAC5B,YAAY,EAAE,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,EACjC,WAAW,CAAC,EAAE,MAAM,GACnB,SAAS,CAgMX"}
package/dist/index.mjs CHANGED
@@ -1,5 +1,5 @@
1
1
  import { jsx, jsxs, Fragment } from "react/jsx-runtime";
2
- import { RendererWrapper, RubyRenderer, LinkFavicon, getVariantClass, allNodes, ColorSchemeProvider, RendererConfigProvider, FootnoteDefinitionsProvider, NestedContentRendererProvider, editorTheme } from "@haklex/rich-editor/static";
2
+ import { RendererWrapper, RubyRenderer, getTagBgColor, LinkFavicon, getVariantClass, allNodes, ColorSchemeProvider, RendererConfigProvider, FootnoteDefinitionsProvider, NestedContentRendererProvider, editorTheme } from "@haklex/rich-editor/static";
3
3
  import { PortalThemeProvider } from "@haklex/rich-style-token";
4
4
  import { createHeadlessEditor } from "@lexical/headless";
5
5
  import { $getRoot } from "lexical";
@@ -128,6 +128,9 @@ function renderBuiltinNode(node, key, children, headingSlugs, textContent) {
128
128
  case "spoiler": {
129
129
  return /* @__PURE__ */ jsx("span", { className: "rich-spoiler", role: "button", tabIndex: 0, children }, key);
130
130
  }
131
+ case "tag": {
132
+ return /* @__PURE__ */ jsx("span", { className: "rich-tag", style: { backgroundColor: getTagBgColor(node.text) }, children: node.text }, key);
133
+ }
131
134
  case "ruby": {
132
135
  return createElement(RendererWrapper, {
133
136
  key,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@haklex/rich-static-renderer",
3
- "version": "0.0.71",
3
+ "version": "0.0.73",
4
4
  "description": "Headless SSR engine for Lexical rich content",
5
5
  "repository": {
6
6
  "type": "git",
@@ -20,13 +20,13 @@
20
20
  "dist"
21
21
  ],
22
22
  "dependencies": {
23
+ "@lexical/code": "npm:lexical-code-no-prism@0.41.0",
23
24
  "@lexical/headless": "^0.41.0",
24
25
  "lucide-react": "^0.577.0",
25
- "@haklex/rich-editor": "0.0.71",
26
- "@haklex/rich-style-token": "0.0.71"
26
+ "@haklex/rich-editor": "0.0.73",
27
+ "@haklex/rich-style-token": "0.0.73"
27
28
  },
28
29
  "devDependencies": {
29
- "@lexical/code": "^0.41.0",
30
30
  "@lexical/extension": "^0.41.0",
31
31
  "@lexical/link": "^0.41.0",
32
32
  "@lexical/list": "^0.41.0",
@@ -43,7 +43,6 @@
43
43
  "vite-plugin-dts": "^4.5.4"
44
44
  },
45
45
  "peerDependencies": {
46
- "@lexical/code": "^0.41.0",
47
46
  "@lexical/extension": "^0.41.0",
48
47
  "@lexical/link": "^0.41.0",
49
48
  "@lexical/list": "^0.41.0",