apple-notes-mcp 2.6.6 → 2.6.8
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/build/index.js +21 -17
- package/package.json +1 -1
package/build/index.js
CHANGED
|
@@ -39585,7 +39585,8 @@ var AppleNotesManager = class {
|
|
|
39585
39585
|
set modifiedParts to ""
|
|
39586
39586
|
end try
|
|
39587
39587
|
try
|
|
39588
|
-
set
|
|
39588
|
+
set noteContainer to container of n
|
|
39589
|
+
set noteFolder to name of noteContainer
|
|
39589
39590
|
on error
|
|
39590
39591
|
set noteFolder to "Notes"
|
|
39591
39592
|
end try
|
|
@@ -40622,12 +40623,9 @@ var AppleNotesManager = class {
|
|
|
40622
40623
|
tell application "Notes"
|
|
40623
40624
|
set theNote to note id "${safeNoteId}"
|
|
40624
40625
|
set theAttachment to missing value
|
|
40625
|
-
|
|
40626
|
-
|
|
40627
|
-
|
|
40628
|
-
exit repeat
|
|
40629
|
-
end if
|
|
40630
|
-
end repeat
|
|
40626
|
+
try
|
|
40627
|
+
set theAttachment to attachment id "${safeAttId}" of theNote
|
|
40628
|
+
end try
|
|
40631
40629
|
if theAttachment is missing value then
|
|
40632
40630
|
return "ERR" & ${AS_FIELD_SEP} & "attachment not found"
|
|
40633
40631
|
end if
|
|
@@ -40934,7 +40932,10 @@ var AppleNotesManager = class {
|
|
|
40934
40932
|
if (parts.length >= 3) {
|
|
40935
40933
|
attachments.push({
|
|
40936
40934
|
id: parts[0].trim(),
|
|
40937
|
-
name
|
|
40935
|
+
// Unnamed attachments render `name` as the AppleScript sentinel; surfacing
|
|
40936
|
+
// the literal "missing value" as a filename is worse than saying nothing,
|
|
40937
|
+
// and `name` is a required string, so fall back to the content identifier.
|
|
40938
|
+
name: normalizeAppleScriptText(parts[1]) ?? normalizeAppleScriptText(parts[2]) ?? "",
|
|
40938
40939
|
contentType: parts[2].trim(),
|
|
40939
40940
|
contentId: parts[2].trim() || void 0,
|
|
40940
40941
|
url: normalizeAppleScriptText(parts[3]),
|
|
@@ -41018,7 +41019,10 @@ var AppleNotesManager = class {
|
|
|
41018
41019
|
if (parts.length >= 3) {
|
|
41019
41020
|
attachments.push({
|
|
41020
41021
|
id: parts[0].trim(),
|
|
41021
|
-
name
|
|
41022
|
+
// Unnamed attachments render `name` as the AppleScript sentinel; surfacing
|
|
41023
|
+
// the literal "missing value" as a filename is worse than saying nothing,
|
|
41024
|
+
// and `name` is a required string, so fall back to the content identifier.
|
|
41025
|
+
name: normalizeAppleScriptText(parts[1]) ?? normalizeAppleScriptText(parts[2]) ?? "",
|
|
41022
41026
|
contentType: parts[2].trim(),
|
|
41023
41027
|
contentId: parts[2].trim() || void 0,
|
|
41024
41028
|
url: normalizeAppleScriptText(parts[3]),
|
|
@@ -41054,12 +41058,9 @@ var AppleNotesManager = class {
|
|
|
41054
41058
|
tell application "Notes"
|
|
41055
41059
|
set theNote to note id "${safeNoteId}"
|
|
41056
41060
|
set theAttachment to missing value
|
|
41057
|
-
|
|
41058
|
-
|
|
41059
|
-
|
|
41060
|
-
exit repeat
|
|
41061
|
-
end if
|
|
41062
|
-
end repeat
|
|
41061
|
+
try
|
|
41062
|
+
set theAttachment to attachment id "${safeAttId}" of theNote
|
|
41063
|
+
end try
|
|
41063
41064
|
if theAttachment is missing value then
|
|
41064
41065
|
return "ERR" & ${AS_FIELD_SEP} & "attachment not found"
|
|
41065
41066
|
end if
|
|
@@ -41099,8 +41100,11 @@ var AppleNotesManager = class {
|
|
|
41099
41100
|
return {
|
|
41100
41101
|
success: true,
|
|
41101
41102
|
savedPath: abs,
|
|
41102
|
-
|
|
41103
|
-
|
|
41103
|
+
// Unnamed attachments render as the AppleScript sentinel here too; leaving it
|
|
41104
|
+
// undefined lets save-attachment/fetch-attachment fall back to "attachment"
|
|
41105
|
+
// rather than reporting `Saved "missing value"`.
|
|
41106
|
+
name: normalizeAppleScriptText(parts[1]),
|
|
41107
|
+
contentType: normalizeAppleScriptText(parts[2])
|
|
41104
41108
|
};
|
|
41105
41109
|
}
|
|
41106
41110
|
/**
|
package/package.json
CHANGED