apple-notes-mcp 2.9.6 → 2.9.7
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 +6 -2
- package/build/index.js +5 -3
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1658,8 +1658,12 @@ or `mailto:`. Tables render as GitHub tables. Attachments stay in body order:
|
|
|
1658
1658
|
with `assetsDir` they link to copies of their files (images inline, drawings
|
|
1659
1659
|
through Notes' fallback image, scans as their PDF), and without it they render
|
|
1660
1660
|
as labeled placeholders such as `\[Image: name\]`. An attachment whose file
|
|
1661
|
-
cannot be found renders as `\[Image unavailable: name\]`.
|
|
1662
|
-
|
|
1661
|
+
cannot be found renders as `\[Image unavailable: name\]`. Body text that
|
|
1662
|
+
Markdown would read as block syntax (a leading `#` to `######`, `>`, `-`, `+`,
|
|
1663
|
+
`*`, `1.` or `1)`, a `---` line, a code fence or a table row) is
|
|
1664
|
+
backslash-escaped, so a plain paragraph such as `## Notes` stays a paragraph,
|
|
1665
|
+
and `wrap` never starts a continuation line with such a marker. This tool
|
|
1666
|
+
leaves `get-note-markdown` unchanged.
|
|
1663
1667
|
|
|
1664
1668
|
A folder export is one presentation document with notes separated by `---`.
|
|
1665
1669
|
It is not a backup or restore format; use `export-notes-json` for that.
|
package/build/index.js
CHANGED
|
@@ -50782,11 +50782,13 @@ function escapeMarkdown(text2) {
|
|
|
50782
50782
|
return text2.replace(/[\\`*_[\]<>~|]/g, (char) => `\\${char}`).replace(/&(?=#?[A-Za-z0-9]+;)/g, "&").replace(/==/g, "\\=\\=");
|
|
50783
50783
|
}
|
|
50784
50784
|
function escapeLineStart(line) {
|
|
50785
|
+
if (/^\s*(?:-[ \t]*){3,}$/.test(line)) return line.replace("-", "\\-");
|
|
50785
50786
|
return line.replace(
|
|
50786
|
-
/^(\s*)([
|
|
50787
|
+
/^(\s*)(#{1,6}|[>+-]|\d{1,9}[.)])(?=\s|$)/,
|
|
50787
50788
|
(_, space, marker) => /^\d/.test(marker) ? `${space}${marker.slice(0, -1)}\\${marker.slice(-1)}` : `${space}\\${marker}`
|
|
50788
50789
|
);
|
|
50789
50790
|
}
|
|
50791
|
+
var BLOCK_START_WORD = /^(?:#{1,6}|[-+*]|-+|=+|\d{1,9}[.)])$/;
|
|
50790
50792
|
function linkDestination(url) {
|
|
50791
50793
|
return url.replace(
|
|
50792
50794
|
/[\s()<>]/g,
|
|
@@ -50958,7 +50960,7 @@ function renderLine(block, body, first2, isTitle, counters) {
|
|
|
50958
50960
|
counters[level] = 0;
|
|
50959
50961
|
if (block.style === "checklist") marker = block.checklist?.done ? "- [x]" : "- [ ]";
|
|
50960
50962
|
}
|
|
50961
|
-
return { text: `${indent}${marker} ${body}`, group: "list", quote };
|
|
50963
|
+
return { text: `${indent}${marker} ${escapeLineStart(body)}`, group: "list", quote };
|
|
50962
50964
|
}
|
|
50963
50965
|
function joinLines(lines) {
|
|
50964
50966
|
let out = "";
|
|
@@ -50991,7 +50993,7 @@ function wrapMarkdown(markdown, width) {
|
|
|
50991
50993
|
let current = prefix;
|
|
50992
50994
|
let empty = true;
|
|
50993
50995
|
for (const word of words) {
|
|
50994
|
-
if (!empty && current.length + 1 + word.length > width) {
|
|
50996
|
+
if (!empty && current.length + 1 + word.length > width && !BLOCK_START_WORD.test(word)) {
|
|
50995
50997
|
out.push(current);
|
|
50996
50998
|
current = hang + word;
|
|
50997
50999
|
} else current += (empty ? "" : " ") + word;
|
package/package.json
CHANGED