seemore 1.12.22 → 1.12.24
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 +3 -3
- package/dist/cli/index.js +11 -9
- package/dist/cli/index.js.map +1 -1
- package/package.json +2 -1
- package/src/app/export/exportPage.ts +5 -1
package/README.md
CHANGED
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
<a href="https://www.npmjs.com/package/seemore">
|
|
8
8
|
<img src="https://img.shields.io/npm/v/seemore"/>
|
|
9
9
|
</a>
|
|
10
|
-
<a href="https://arifszn.github.io/seemore/
|
|
10
|
+
<a href="https://arifszn.github.io/seemore/desktop-app">
|
|
11
11
|
<img src="https://img.shields.io/badge/Desktop-macOS%20%C2%B7%20Windows%20%C2%B7%20Linux-111111"/>
|
|
12
12
|
</a>
|
|
13
13
|
<a href="https://open-vsx.org/extension/arifszn/seemore-vscode">
|
|
@@ -49,7 +49,7 @@ You can use seemore in two ways.
|
|
|
49
49
|
|
|
50
50
|
### Desktop app
|
|
51
51
|
|
|
52
|
-
Download the app for macOS, Windows or Linux from the [download page](https://arifszn.github.io/seemore/
|
|
52
|
+
Download the app for macOS, Windows or Linux from the [download page](https://arifszn.github.io/seemore/desktop-app). Open a folder or a `.md` file, and it opens as a site.
|
|
53
53
|
|
|
54
54
|
### Command line
|
|
55
55
|
|
|
@@ -136,7 +136,7 @@ Inline editing works only for local previews.
|
|
|
136
136
|
|
|
137
137
|
## Open with the desktop app
|
|
138
138
|
|
|
139
|
-
Download the app from the [download page](https://arifszn.github.io/seemore/
|
|
139
|
+
Download the app from the [download page](https://arifszn.github.io/seemore/desktop-app). It opens a folder or a `.md` file as a site in its own window, with an integrated terminal.
|
|
140
140
|
|
|
141
141
|
<p align="center">
|
|
142
142
|
<img src="https://raw.githubusercontent.com/arifszn/seemore/main/packages/site/assets/desktop-app.png" alt="The seemore desktop app in the black theme, showing a folder of research notes as a site: a paragraph's Markdown source open in the inline editor above a flowchart, and the integrated terminal listing the folder's Markdown files" width="640"/>
|
package/dist/cli/index.js
CHANGED
|
@@ -2433,6 +2433,7 @@ async function loadPrerenderModule(ctx, ssrOutDir) {
|
|
|
2433
2433
|
// src/node/social/cards.ts
|
|
2434
2434
|
import { mkdirSync as mkdirSync2, writeFileSync as writeFileSync6 } from "fs";
|
|
2435
2435
|
import { dirname as dirname9, join as join11 } from "path";
|
|
2436
|
+
import { createElement } from "react";
|
|
2436
2437
|
|
|
2437
2438
|
// src/shared/og.ts
|
|
2438
2439
|
function ogImagePath(url) {
|
|
@@ -2463,8 +2464,13 @@ async function generateSocialCards(ctx, outDir) {
|
|
|
2463
2464
|
return written;
|
|
2464
2465
|
}
|
|
2465
2466
|
async function renderCard(takumi, site, title, description) {
|
|
2466
|
-
const
|
|
2467
|
-
|
|
2467
|
+
const children = [
|
|
2468
|
+
createElement("div", { style: { fontSize: 28, opacity: 0.6 } }, site),
|
|
2469
|
+
createElement("div", { style: { fontSize: 64, fontWeight: 700 } }, title),
|
|
2470
|
+
...typeof description === "string" ? [createElement("div", { style: { fontSize: 30, opacity: 0.8 } }, description)] : []
|
|
2471
|
+
];
|
|
2472
|
+
const node = createElement(
|
|
2473
|
+
"div",
|
|
2468
2474
|
{
|
|
2469
2475
|
style: {
|
|
2470
2476
|
width: 1200,
|
|
@@ -2478,13 +2484,9 @@ async function renderCard(takumi, site, title, description) {
|
|
|
2478
2484
|
gap: 24
|
|
2479
2485
|
}
|
|
2480
2486
|
},
|
|
2481
|
-
|
|
2482
|
-
takumi.text(site, { style: { fontSize: 28, opacity: 0.6 } }),
|
|
2483
|
-
takumi.text(title, { style: { fontSize: 64, fontWeight: 700 } }),
|
|
2484
|
-
...typeof description === "string" ? [takumi.text(description, { style: { fontSize: 30, opacity: 0.8 } })] : []
|
|
2485
|
-
]
|
|
2487
|
+
children
|
|
2486
2488
|
);
|
|
2487
|
-
return await
|
|
2489
|
+
return await takumi.render(node, { width: 1200, height: 630 });
|
|
2488
2490
|
}
|
|
2489
2491
|
async function importOptional(specifier) {
|
|
2490
2492
|
return await import(specifier);
|
|
@@ -2886,7 +2888,7 @@ function withExportToc(html) {
|
|
|
2886
2888
|
(match) => ({
|
|
2887
2889
|
depth: Number(match[1]),
|
|
2888
2890
|
id: match[2] ?? "",
|
|
2889
|
-
text: decodeEntities((match[3] ?? "").replace(/<[^>]+>/g, ""))
|
|
2891
|
+
text: decodeEntities((match[3] ?? "").replace(/<button\b[\s\S]*?<\/button>/gi, "").replace(/<[^>]+>/g, "")).trim()
|
|
2890
2892
|
})
|
|
2891
2893
|
);
|
|
2892
2894
|
if (headings.length === 0) return html;
|