@haklex/rich-ext-embed 0.40.0 → 0.41.1

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.
@@ -618,7 +618,7 @@ var EmbedNode = class EmbedNode extends DecoratorNode {
618
618
  }
619
619
  static importJSON(_serializedNode) {
620
620
  const serializedNode = _serializedNode;
621
- return $createEmbedNode(serializedNode.url, serializedNode.source);
621
+ return $createEmbedNode(serializedNode.url, serializedNode.source).updateFromJSON(_serializedNode);
622
622
  }
623
623
  exportJSON() {
624
624
  return {
package/dist/index.mjs CHANGED
@@ -1,4 +1,4 @@
1
- import { _ as EmbedRendererProvider, a as EmbedStaticRenderer, c as isAppleMusicUrl, d as isGistUrl, f as isGithubFilePreviewUrl, g as matchEmbedUrl, h as isYoutubeUrl, i as EmbedNode, l as isBilibiliVideoUrl, m as isTweetUrl, n as $createEmbedNode, o as _defineProperty, p as isSpotifyUrl, r as $isEmbedNode, s as createSelfThinkingMatcher, t as EmbedLinkRenderer, u as isCodesandboxUrl, v as useEmbedRenderers } from "./EmbedLinkRenderer-Df_Ta40q.js";
1
+ import { _ as EmbedRendererProvider, a as EmbedStaticRenderer, c as isAppleMusicUrl, d as isGistUrl, f as isGithubFilePreviewUrl, g as matchEmbedUrl, h as isYoutubeUrl, i as EmbedNode, l as isBilibiliVideoUrl, m as isTweetUrl, n as $createEmbedNode, o as _defineProperty, p as isSpotifyUrl, r as $isEmbedNode, s as createSelfThinkingMatcher, t as EmbedLinkRenderer, u as isCodesandboxUrl, v as useEmbedRenderers } from "./EmbedLinkRenderer--U3gl5KD.js";
2
2
  import { $insertNodes, COMMAND_PRIORITY_LOW, PASTE_COMMAND, createCommand } from "lexical";
3
3
  import { createElement, useEffect, useMemo } from "react";
4
4
  import { Code } from "lucide-react";
@@ -10,7 +10,7 @@ var EmbedEditNode = class EmbedEditNode extends EmbedNode {
10
10
  }
11
11
  static importJSON(_serializedNode) {
12
12
  const serializedNode = _serializedNode;
13
- return new EmbedEditNode(serializedNode.url, serializedNode.source);
13
+ return new EmbedEditNode(serializedNode.url, serializedNode.source).updateFromJSON(_serializedNode);
14
14
  }
15
15
  decorate(_editor, _config) {
16
16
  return createElement(EmbedLinkRenderer, {
@@ -1 +1 @@
1
- {"version":3,"file":"EmbedEditNode.d.ts","sourceRoot":"","sources":["../../src/nodes/EmbedEditNode.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,8BAA8B,CAAC;AACtE,OAAO,KAAK,EAAE,YAAY,EAAE,aAAa,EAAE,WAAW,EAAE,qBAAqB,EAAE,MAAM,SAAS,CAAC;AAG/F,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,OAAO,CAAC;AAI1C,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AACjD,OAAO,EAAE,SAAS,EAA4B,MAAM,aAAa,CAAC;AAElE,qBAAa,aAAc,SAAQ,SAAS;IAC1C,MAAM,CAAC,YAAY,EAAE,iBAAiB,EAAE,CAetC;IAEF,MAAM,CAAC,KAAK,CAAC,IAAI,EAAE,aAAa,GAAG,aAAa;IAIhD,MAAM,CAAC,UAAU,CACf,eAAe,EAAE,qBAAqB,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAC/D,aAAa;IAKhB,QAAQ,CAAC,OAAO,EAAE,aAAa,EAAE,OAAO,EAAE,YAAY,GAAG,YAAY;CAOtE;AAED,wBAAgB,oBAAoB,CAAC,GAAG,EAAE,MAAM,EAAE,MAAM,EAAE,SAAS,GAAG,IAAI,GAAG,aAAa,CAEzF;AAED,wBAAgB,gBAAgB,CAAC,IAAI,EAAE,WAAW,GAAG,IAAI,GAAG,SAAS,GAAG,IAAI,IAAI,aAAa,CAE5F"}
1
+ {"version":3,"file":"EmbedEditNode.d.ts","sourceRoot":"","sources":["../../src/nodes/EmbedEditNode.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,8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,SAAS,GAAG,IAAI,GAAG,SAAS,CAEjF;AAED,wBAAgB,YAAY,CAAC,IAAI,EAAE,WAAW,GAAG,IAAI,GAAG,SAAS,GAAG,IAAI,IAAI,SAAS,CAEpF"}
package/dist/static.mjs CHANGED
@@ -1,4 +1,4 @@
1
- import { _ as EmbedRendererProvider, a as EmbedStaticRenderer, c as isAppleMusicUrl, d as isGistUrl, f as isGithubFilePreviewUrl, g as matchEmbedUrl, h as isYoutubeUrl, i as EmbedNode, l as isBilibiliVideoUrl, m as isTweetUrl, n as $createEmbedNode, p as isSpotifyUrl, r as $isEmbedNode, s as createSelfThinkingMatcher, t as EmbedLinkRenderer, u as isCodesandboxUrl, v as useEmbedRenderers } from "./EmbedLinkRenderer-Df_Ta40q.js";
1
+ import { _ as EmbedRendererProvider, a as EmbedStaticRenderer, c as isAppleMusicUrl, d as isGistUrl, f as isGithubFilePreviewUrl, g as matchEmbedUrl, h as isYoutubeUrl, i as EmbedNode, l as isBilibiliVideoUrl, m as isTweetUrl, n as $createEmbedNode, p as isSpotifyUrl, r as $isEmbedNode, s as createSelfThinkingMatcher, t as EmbedLinkRenderer, u as isCodesandboxUrl, v as useEmbedRenderers } from "./EmbedLinkRenderer--U3gl5KD.js";
2
2
  //#region src/static.ts
3
3
  var embedNodes = [EmbedNode];
4
4
  //#endregion
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@haklex/rich-ext-embed",
3
- "version": "0.40.0",
3
+ "version": "0.41.1",
4
4
  "description": "Embed extension for Twitter, YouTube, etc.",
5
5
  "repository": {
6
6
  "type": "git",
@@ -49,9 +49,9 @@
49
49
  "react": ">=19",
50
50
  "react-dom": ">=19",
51
51
  "shiki": ">=4.0.0",
52
- "@haklex/rich-editor": "^0.40.0",
53
- "@haklex/rich-style-token": "^0.40.0",
54
- "@haklex/rich-editor-ui": "^0.40.0"
52
+ "@haklex/rich-editor": "^0.41.1",
53
+ "@haklex/rich-editor-ui": "^0.41.1",
54
+ "@haklex/rich-style-token": "^0.41.1"
55
55
  },
56
56
  "peerDependenciesMeta": {
57
57
  "shiki": {