@lobehub/ui 5.10.2 → 5.10.4
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/es/Highlighter/style.mjs +1 -1
- package/es/HtmlPreview/HtmlPreview.d.mts +8 -0
- package/es/HtmlPreview/HtmlPreview.mjs +329 -0
- package/es/HtmlPreview/HtmlPreview.mjs.map +1 -0
- package/es/HtmlPreview/Iframe.d.mts +8 -0
- package/es/HtmlPreview/Iframe.mjs +159 -0
- package/es/HtmlPreview/Iframe.mjs.map +1 -0
- package/es/HtmlPreview/buildShellSrcDoc.mjs +235 -0
- package/es/HtmlPreview/buildShellSrcDoc.mjs.map +1 -0
- package/es/HtmlPreview/buildStaticSrcDoc.mjs +44 -0
- package/es/HtmlPreview/buildStaticSrcDoc.mjs.map +1 -0
- package/es/HtmlPreview/const.d.mts +42 -0
- package/es/HtmlPreview/const.mjs +63 -0
- package/es/HtmlPreview/const.mjs.map +1 -0
- package/es/HtmlPreview/index.d.mts +6 -0
- package/es/HtmlPreview/index.d.ts +1 -0
- package/es/HtmlPreview/index.js +1 -0
- package/es/HtmlPreview/index.mjs +5 -0
- package/es/HtmlPreview/injectAutoHeightScript.d.mts +5 -0
- package/es/HtmlPreview/injectAutoHeightScript.mjs +37 -0
- package/es/HtmlPreview/injectAutoHeightScript.mjs.map +1 -0
- package/es/HtmlPreview/injectStorageShim.mjs +62 -0
- package/es/HtmlPreview/injectStorageShim.mjs.map +1 -0
- package/es/HtmlPreview/type.d.mts +114 -0
- package/es/Markdown/Markdown.mjs +7 -3
- package/es/Markdown/Markdown.mjs.map +1 -1
- package/es/Markdown/SyntaxMarkdown/StreamdownRender.mjs +2 -17
- package/es/Markdown/SyntaxMarkdown/StreamdownRender.mjs.map +1 -1
- package/es/Markdown/SyntaxMarkdown/fenceState.mjs +40 -0
- package/es/Markdown/SyntaxMarkdown/fenceState.mjs.map +1 -0
- package/es/Markdown/SyntaxMarkdown/useSmoothStreamContent.mjs +13 -0
- package/es/Markdown/SyntaxMarkdown/useSmoothStreamContent.mjs.map +1 -1
- package/es/Markdown/components/CodeBlock.mjs +10 -2
- package/es/Markdown/components/CodeBlock.mjs.map +1 -1
- package/es/Markdown/type.d.mts +3 -0
- package/es/NeuralNetworkLoading/NeuralNetworkLoading.d.mts +8 -0
- package/es/NeuralNetworkLoading/NeuralNetworkLoading.mjs +142 -0
- package/es/NeuralNetworkLoading/NeuralNetworkLoading.mjs.map +1 -0
- package/es/NeuralNetworkLoading/index.d.mts +3 -0
- package/es/NeuralNetworkLoading/index.d.ts +1 -0
- package/es/NeuralNetworkLoading/index.js +1 -0
- package/es/NeuralNetworkLoading/index.mjs +2 -0
- package/es/NeuralNetworkLoading/type.d.mts +12 -0
- package/es/ScrollShadow/ScrollShadow.mjs +5 -1
- package/es/ScrollShadow/ScrollShadow.mjs.map +1 -1
- package/es/ScrollShadow/useScrollOverflow.mjs +13 -9
- package/es/ScrollShadow/useScrollOverflow.mjs.map +1 -1
- package/es/Tag/Tag.mjs +1 -1
- package/es/Tag/Tag.mjs.map +1 -1
- package/es/hooks/useMarkdown/useMarkdownComponents.mjs +9 -2
- package/es/hooks/useMarkdown/useMarkdownComponents.mjs.map +1 -1
- package/es/hooks/useStableValue.mjs +30 -0
- package/es/hooks/useStableValue.mjs.map +1 -0
- package/es/index.d.mts +8 -1
- package/es/index.mjs +7 -2
- package/es/mdx/mdxComponents/Pre.mjs +14 -1
- package/es/mdx/mdxComponents/Pre.mjs.map +1 -1
- package/es/utils/isDeepEqual.mjs +21 -0
- package/es/utils/isDeepEqual.mjs.map +1 -0
- package/package.json +4 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"isDeepEqual.mjs","names":[],"sources":["../../src/utils/isDeepEqual.ts"],"sourcesContent":["// Structural equality for prop/config-shaped values: primitives, plain\n// records, and arrays. Functions and class instances are compared by\n// reference (caller is expected to memoise callbacks via useCallback).\n// Lifted out of StreamdownRender so the same definition powers\n// `useStableValue` at the Markdown boundary — keep them in sync if you\n// extend the rules here.\nconst isRecord = (value: unknown): value is Record<string, unknown> =>\n typeof value === 'object' && value !== null;\n\nexport const isDeepEqual = (a: unknown, b: unknown): boolean => {\n if (a === b) return true;\n\n if (Array.isArray(a) || Array.isArray(b)) {\n if (!Array.isArray(a) || !Array.isArray(b)) return false;\n if (a.length !== b.length) return false;\n for (let i = 0; i < a.length; i++) {\n if (!isDeepEqual(a[i], b[i])) return false;\n }\n return true;\n }\n\n if (!isRecord(a) || !isRecord(b)) return false;\n\n const keysA = Object.keys(a);\n const keysB = Object.keys(b);\n if (keysA.length !== keysB.length) return false;\n\n for (const key of keysA) {\n if (!isDeepEqual(a[key], b[key])) return false;\n }\n\n return true;\n};\n"],"mappings":";AAMA,MAAM,YAAY,UAChB,OAAO,UAAU,YAAY,UAAU;AAEzC,MAAa,eAAe,GAAY,MAAwB;AAC9D,KAAI,MAAM,EAAG,QAAO;AAEpB,KAAI,MAAM,QAAQ,EAAE,IAAI,MAAM,QAAQ,EAAE,EAAE;AACxC,MAAI,CAAC,MAAM,QAAQ,EAAE,IAAI,CAAC,MAAM,QAAQ,EAAE,CAAE,QAAO;AACnD,MAAI,EAAE,WAAW,EAAE,OAAQ,QAAO;AAClC,OAAK,IAAI,IAAI,GAAG,IAAI,EAAE,QAAQ,IAC5B,KAAI,CAAC,YAAY,EAAE,IAAI,EAAE,GAAG,CAAE,QAAO;AAEvC,SAAO;;AAGT,KAAI,CAAC,SAAS,EAAE,IAAI,CAAC,SAAS,EAAE,CAAE,QAAO;CAEzC,MAAM,QAAQ,OAAO,KAAK,EAAE;CAC5B,MAAM,QAAQ,OAAO,KAAK,EAAE;AAC5B,KAAI,MAAM,WAAW,MAAM,OAAQ,QAAO;AAE1C,MAAK,MAAM,OAAO,MAChB,KAAI,CAAC,YAAY,EAAE,MAAM,EAAE,KAAK,CAAE,QAAO;AAG3C,QAAO"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lobehub/ui",
|
|
3
|
-
"version": "5.10.
|
|
3
|
+
"version": "5.10.4",
|
|
4
4
|
"description": "Lobe UI is an open-source UI component library for building AIGC web apps",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"lobehub",
|
|
@@ -243,6 +243,9 @@
|
|
|
243
243
|
"lint-staged": "^16.4.0",
|
|
244
244
|
"mdast-util-to-markdown": "^2.1.2",
|
|
245
245
|
"prettier": "^3.8.3",
|
|
246
|
+
"prettier-plugin-packagejson": "^3.0.2",
|
|
247
|
+
"prettier-plugin-sh": "^0.18.1",
|
|
248
|
+
"prettier-plugin-sort-json": "^4.2.0",
|
|
246
249
|
"react": "^19.2.5",
|
|
247
250
|
"react-dom": "^19.2.5",
|
|
248
251
|
"remark": "^15.0.1",
|