feat: wrap folder content in .markdown-preview-view and .markdown-rendered for Obsidian theme compat

This commit is contained in:
saberzero1 2026-04-25 22:57:05 +02:00
parent c72a92f00d
commit 8e51a6144d
No known key found for this signature in database
5 changed files with 7 additions and 5 deletions

View file

@ -2773,7 +2773,7 @@ var FolderContent_default = ((opts) => {
const content = hastRoot.children.length === 0 ? fileData?.description : htmlToJsx(hastRoot);
const pageListContent = PageList(listProps);
return /* @__PURE__ */ jsxs("div", { class: "popover-hint", children: [
/* @__PURE__ */ jsx("article", { class: classes, children: content }),
/* @__PURE__ */ jsx("article", { class: classes, children: /* @__PURE__ */ jsx("div", { class: "markdown-preview-view markdown-rendered", children: content }) }),
/* @__PURE__ */ jsxs("div", { class: "page-listing", children: [
options.showFolderCount && /* @__PURE__ */ jsx("p", { children: i18n(
cfg?.locale ?? "en-US"

File diff suppressed because one or more lines are too long

2
dist/index.js vendored
View file

@ -2758,7 +2758,7 @@ var FolderContent_default = ((opts) => {
const content = hastRoot.children.length === 0 ? fileData?.description : htmlToJsx(hastRoot);
const pageListContent = PageList(listProps);
return /* @__PURE__ */ jsxs("div", { class: "popover-hint", children: [
/* @__PURE__ */ jsx("article", { class: classes, children: content }),
/* @__PURE__ */ jsx("article", { class: classes, children: /* @__PURE__ */ jsx("div", { class: "markdown-preview-view markdown-rendered", children: content }) }),
/* @__PURE__ */ jsxs("div", { class: "page-listing", children: [
options.showFolderCount && /* @__PURE__ */ jsx("p", { children: i18n(
cfg?.locale ?? "en-US"

2
dist/index.js.map vendored

File diff suppressed because one or more lines are too long

View file

@ -188,7 +188,9 @@ export default ((opts?: Partial<FolderContentOptions>) => {
return (
<div class="popover-hint">
<article class={classes}>{content}</article>
<article class={classes}>
<div class="markdown-preview-view markdown-rendered">{content}</div>
</article>
<div class="page-listing">
{options.showFolderCount && (
<p>