ntfy 1.15.1 → 1.15.2
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/NtfyClient.js +3 -0
- package/dist/interfaces.d.ts +14 -0
- package/package.json +1 -2
package/dist/NtfyClient.js
CHANGED
|
@@ -58,6 +58,9 @@ export async function publish(publishConfig) {
|
|
|
58
58
|
if (publishConfig.emailAddress) {
|
|
59
59
|
requestConfig.headers['X-Email'] = publishConfig.emailAddress;
|
|
60
60
|
}
|
|
61
|
+
if (publishConfig.markdown) {
|
|
62
|
+
requestConfig.headers['X-Markdown'] = publishConfig.markdown.toString();
|
|
63
|
+
}
|
|
61
64
|
if (ConfigHasMessage(publishConfig) && publishConfig.fileURL) {
|
|
62
65
|
if (typeof publishConfig.fileURL === 'string') {
|
|
63
66
|
requestConfig.headers['X-Attach'] = publishConfig.fileURL;
|
package/dist/interfaces.d.ts
CHANGED
|
@@ -162,6 +162,20 @@ export interface BaseConfig {
|
|
|
162
162
|
* deleted. **Only JPEG and PNG images are supported at this time**.
|
|
163
163
|
*/
|
|
164
164
|
iconURL?: string;
|
|
165
|
+
/**
|
|
166
|
+
* By default, messages sent to ntfy are rendered as plain text.
|
|
167
|
+
*
|
|
168
|
+
* You can format messages using Markdown 🤩. That means you can use bold text, italicized text, links, images, and more. Supported Markdown features (web app only for now):
|
|
169
|
+
* - Emphasis such as bold (**bold**), italics (*italics*)
|
|
170
|
+
* - Links ([some tool](https://ntfy.sh))
|
|
171
|
+
* - Images ()
|
|
172
|
+
* - Code blocks (```code blocks```) and inline code (`inline code`)
|
|
173
|
+
* - Headings (# headings, ## headings, etc.)
|
|
174
|
+
* - Lists (- lists, 1. lists, etc.)
|
|
175
|
+
* - Blockquotes (> blockquotes)
|
|
176
|
+
* - Horizontal rules (---)
|
|
177
|
+
*/
|
|
178
|
+
markdown?: boolean;
|
|
165
179
|
/**
|
|
166
180
|
* All messages have a priority, which defines how urgently your phone notifies you. On Android, you can set custom
|
|
167
181
|
* notification sounds and vibration patterns on your phone to map to these priorities (see
|