@tomehq/theme 0.6.2 → 0.6.3
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/dist/{chunk-NIWVZJLG.js → chunk-26CZLWVW.js} +1 -1
- package/dist/entry.js +1 -1
- package/dist/index.js +1 -1
- package/package.json +5 -5
- package/src/Shell.tsx +1 -1
|
@@ -1069,7 +1069,7 @@ function Shell({
|
|
|
1069
1069
|
}, [currentPageId]);
|
|
1070
1070
|
useLayoutEffect(() => {
|
|
1071
1071
|
if (!htmlContentRef.current || !pageHtml) return;
|
|
1072
|
-
const stripped = pageHtml.replace(/<h1[^>]*>[
|
|
1072
|
+
const stripped = pageHtml.replace(/<h1\b[^>]*>(?:[^<]|<(?!\/h1>))*<\/h1>\s*/, "");
|
|
1073
1073
|
htmlContentRef.current.innerHTML = stripped;
|
|
1074
1074
|
lastHtmlRef.current = stripped;
|
|
1075
1075
|
}, [pageHtml, currentPageId]);
|
package/dist/entry.js
CHANGED
package/dist/index.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tomehq/theme",
|
|
3
|
-
"version": "0.6.
|
|
3
|
+
"version": "0.6.3",
|
|
4
4
|
"description": "Tome default theme and React app shell",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./src/index.tsx",
|
|
@@ -9,8 +9,8 @@
|
|
|
9
9
|
"./entry": "./src/entry.tsx"
|
|
10
10
|
},
|
|
11
11
|
"dependencies": {
|
|
12
|
-
"@tomehq/components": "0.6.
|
|
13
|
-
"@tomehq/core": "0.6.
|
|
12
|
+
"@tomehq/components": "0.6.3",
|
|
13
|
+
"@tomehq/core": "0.6.3"
|
|
14
14
|
},
|
|
15
15
|
"peerDependencies": {
|
|
16
16
|
"react": "^18.0.0 || ^19.0.0",
|
|
@@ -32,11 +32,11 @@
|
|
|
32
32
|
"@testing-library/user-event": "^14.6.1",
|
|
33
33
|
"@types/react": "^19.0.0",
|
|
34
34
|
"@types/react-dom": "^19.0.0",
|
|
35
|
-
"jsdom": "^
|
|
35
|
+
"jsdom": "^29.0.0",
|
|
36
36
|
"react": "^19.0.0",
|
|
37
37
|
"react-dom": "^19.0.0",
|
|
38
38
|
"tsup": "^8.0.0",
|
|
39
|
-
"typescript": "^
|
|
39
|
+
"typescript": "^6.0.0"
|
|
40
40
|
},
|
|
41
41
|
"license": "MIT",
|
|
42
42
|
"repository": {
|
package/src/Shell.tsx
CHANGED
|
@@ -614,7 +614,7 @@ export function Shell({
|
|
|
614
614
|
// useLayoutEffect ensures innerHTML is set synchronously before paint — no flash
|
|
615
615
|
useLayoutEffect(() => {
|
|
616
616
|
if (!htmlContentRef.current || !pageHtml) return;
|
|
617
|
-
const stripped = pageHtml.replace(/<h1[^>]*>[
|
|
617
|
+
const stripped = pageHtml.replace(/<h1\b[^>]*>(?:[^<]|<(?!\/h1>))*<\/h1>\s*/, "");
|
|
618
618
|
htmlContentRef.current.innerHTML = stripped;
|
|
619
619
|
lastHtmlRef.current = stripped;
|
|
620
620
|
}, [pageHtml, currentPageId]);
|