@nocobase/plugin-notifications 0.17.0-alpha.6 → 0.18.0-alpha.1

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.
@@ -434,7 +434,7 @@ class SMTPConnection extends EventEmitter {
434
434
  }
435
435
 
436
436
  if (this._authMethod !== 'XOAUTH2' && (!this._auth.credentials || !this._auth.credentials.user || !this._auth.credentials.pass)) {
437
- if (this._auth.user && this._auth.pass) {
437
+ if ((this._auth.user && this._auth.pass) || this.customAuth.has(this._authMethod)) {
438
438
  this._auth.credentials = {
439
439
  user: this._auth.user,
440
440
  pass: this._auth.pass,
@@ -5,13 +5,20 @@
5
5
  "secure": true,
6
6
  "authMethod": "LOGIN"
7
7
  },
8
-
8
+
9
+ "Aliyun": {
10
+ "domains": ["aliyun.com"],
11
+ "host": "smtp.aliyun.com",
12
+ "port": 465,
13
+ "secure": true
14
+ },
15
+
9
16
  "AOL": {
10
17
  "domains": ["aol.com"],
11
18
  "host": "smtp.aol.com",
12
19
  "port": 587
13
20
  },
14
-
21
+
15
22
  "Bluewin": {
16
23
  "host": "smtpauths.bluewin.ch",
17
24
  "domains": ["bluewin.ch"],
@@ -212,7 +219,8 @@
212
219
  },
213
220
 
214
221
  "SendinBlue": {
215
- "host": "smtp-relay.sendinblue.com",
222
+ "aliases": ["Brevo"],
223
+ "host": "smtp-relay.brevo.com",
216
224
  "port": 587
217
225
  },
218
226
 
@@ -246,6 +254,42 @@
246
254
  "secure": true
247
255
  },
248
256
 
257
+ "SES-AP-SOUTH-1": {
258
+ "host": "email-smtp.ap-south-1.amazonaws.com",
259
+ "port": 465,
260
+ "secure": true
261
+ },
262
+
263
+ "SES-AP-NORTHEAST-1": {
264
+ "host": "email-smtp.ap-northeast-1.amazonaws.com",
265
+ "port": 465,
266
+ "secure": true
267
+ },
268
+
269
+ "SES-AP-NORTHEAST-2": {
270
+ "host": "email-smtp.ap-northeast-2.amazonaws.com",
271
+ "port": 465,
272
+ "secure": true
273
+ },
274
+
275
+ "SES-AP-NORTHEAST-3": {
276
+ "host": "email-smtp.ap-northeast-3.amazonaws.com",
277
+ "port": 465,
278
+ "secure": true
279
+ },
280
+
281
+ "SES-AP-SOUTHEAST-1": {
282
+ "host": "email-smtp.ap-southeast-1.amazonaws.com",
283
+ "port": 465,
284
+ "secure": true
285
+ },
286
+
287
+ "SES-AP-SOUTHEAST-2": {
288
+ "host": "email-smtp.ap-southeast-2.amazonaws.com",
289
+ "port": 465,
290
+ "secure": true
291
+ },
292
+
249
293
  "Sparkpost": {
250
294
  "aliases": ["SparkPost", "SparkPost Mail"],
251
295
  "domains": ["sparkpost.com"],
@@ -1 +1 @@
1
- {"name":"nodemailer","version":"6.9.3","description":"Easy as cake e-mail sending from your Node.js applications","main":"lib/nodemailer.js","scripts":{"test":"grunt --trace-warnings"},"repository":{"type":"git","url":"https://github.com/nodemailer/nodemailer.git"},"keywords":["Nodemailer"],"author":"Andris Reinman","license":"MIT-0","bugs":{"url":"https://github.com/nodemailer/nodemailer/issues"},"homepage":"https://nodemailer.com/","devDependencies":{"@aws-sdk/client-ses":"3.341.0","aws-sdk":"2.1386.0","bunyan":"1.8.15","chai":"4.3.7","eslint-config-nodemailer":"1.2.0","eslint-config-prettier":"8.8.0","grunt":"1.6.1","grunt-cli":"1.4.3","grunt-eslint":"24.1.0","grunt-mocha-test":"0.13.3","libbase64":"1.2.1","libmime":"5.2.1","libqp":"2.0.1","mocha":"10.2.0","nodemailer-ntlm-auth":"1.0.3","proxy":"1.0.2","proxy-test-server":"1.0.0","sinon":"15.1.0","smtp-server":"3.12.0"},"engines":{"node":">=6.0.0"},"_lastModified":"2023-12-13T08:46:14.425Z"}
1
+ {"name":"nodemailer","version":"6.9.7","description":"Easy as cake e-mail sending from your Node.js applications","main":"lib/nodemailer.js","scripts":{"test":"grunt --trace-warnings","update":"rm -rf node_modules/ package-lock.json && ncu -u && npm install"},"repository":{"type":"git","url":"https://github.com/nodemailer/nodemailer.git"},"keywords":["Nodemailer"],"author":"Andris Reinman","license":"MIT-0","bugs":{"url":"https://github.com/nodemailer/nodemailer/issues"},"homepage":"https://nodemailer.com/","devDependencies":{"@aws-sdk/client-ses":"3.433.0","aws-sdk":"2.1478.0","bunyan":"1.8.15","chai":"4.3.10","eslint-config-nodemailer":"1.2.0","eslint-config-prettier":"9.0.0","grunt":"1.6.1","grunt-cli":"1.4.3","grunt-eslint":"24.3.0","grunt-mocha-test":"0.13.3","libbase64":"1.2.1","libmime":"5.2.1","libqp":"2.0.1","mocha":"10.2.0","nodemailer-ntlm-auth":"1.0.4","proxy":"1.0.2","proxy-test-server":"1.0.0","sinon":"17.0.0","smtp-server":"3.13.0"},"engines":{"node":">=6.0.0"},"_lastModified":"2023-12-21T12:50:11.387Z"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nocobase/plugin-notifications",
3
- "version": "0.17.0-alpha.6",
3
+ "version": "0.18.0-alpha.1",
4
4
  "description": "",
5
5
  "license": "AGPL-3.0",
6
6
  "main": "./dist/server/index.js",
@@ -16,5 +16,5 @@
16
16
  "@nocobase/test": "0.x",
17
17
  "@nocobase/utils": "0.x"
18
18
  },
19
- "gitHead": "f92f8bcdf6d5baf07566381e9425ebca11e19626"
19
+ "gitHead": "0f5f1c0a37dc397a9dc4c8eec0c4ec20fd8107b0"
20
20
  }
@@ -1,101 +0,0 @@
1
- /* eslint no-control-regex:0 */
2
- 'use strict';
3
-
4
- const packageData = require('./package.json');
5
- const isEnabled = value => !!value && value !== '0' && value !== 'false';
6
- const canUseColor = isEnabled(process.env.npm_config_color);
7
-
8
- const title = `=== Nodemailer ${packageData.version} ===`;
9
- const text = `
10
- Thank you for using Nodemailer for your email sending needs! While Nodemailer itself is mostly meant to be a SMTP client there are other related projects in the Nodemailer project as well.
11
-
12
- > IMAP API ( https://imapapi.com ) is a server application to easily access IMAP accounts via REST API
13
- > ImapFlow ( https://imapflow.com/ ) is an async IMAP client library for Node.js
14
- > NodemailerApp ( https://nodemailer.com/app/ ) is a cross platform GUI app to debug emails
15
- > Project Pending ( https://projectpending.com/ ) allows you to host DNS of your project domains
16
- > Pending DNS ( https://pendingdns.com/ ) is the DNS server used that powers Project Pending
17
- > Ethereal Email ( https://ethereal.email/ ) is an email testing service that accepts all your test emails
18
- `;
19
-
20
- const footer = `Don't like this message?
21
- There's a Github Sponsors goal to remove it
22
- https://github.com/sponsors/andris9
23
- `;
24
-
25
- const secs = 4;
26
-
27
- const formatCentered = (row, columns) => {
28
- return row
29
- .split(/\r?\n/)
30
- .map(row => {
31
- if (columns <= row.length) {
32
- return row;
33
- }
34
-
35
- return ' '.repeat(Math.round(columns / 2 - row.length / 2)) + row;
36
- })
37
- .join('\n');
38
- };
39
-
40
- const formatRow = (row, columns) => {
41
- if (row.length <= columns) {
42
- return [row];
43
- }
44
- // wrap!
45
- let lines = [];
46
- while (row.length) {
47
- if (row.length <= columns) {
48
- lines.push(row);
49
- break;
50
- }
51
- let slice = row.substr(0, columns);
52
-
53
- let prefix = slice.charAt(0) === '>' ? ' ' : '';
54
-
55
- let match = slice.match(/(\s+)[^\s]*$/);
56
- if (match && match.index) {
57
- let line = row.substr(0, match.index);
58
- row = prefix + row.substr(line.length + match[1].length);
59
- lines.push(line);
60
- } else {
61
- lines.push(row);
62
- break;
63
- }
64
- }
65
- return lines;
66
- };
67
-
68
- const wrapText = text => {
69
- let columns = Number(process.stdout.columns) || 80;
70
- columns = Math.min(columns, 80) - 1;
71
-
72
- return (
73
- (formatCentered(title, columns) + '\n' + text)
74
- .split('\n')
75
- .flatMap(row => formatRow(row, columns))
76
- .join('\n') +
77
- '\n' +
78
- formatCentered(footer, columns)
79
- );
80
- };
81
-
82
- const banner = wrapText(text)
83
- .replace(/^/gm, '\u001B[96m')
84
- .replace(/$/gm, '\u001B[0m')
85
- .replace(/(https:[^\s)]+)/g, '\u001B[94m $1 \u001B[96m');
86
-
87
- console.log(canUseColor ? banner : banner.replace(/\u001B\[\d+m/g, ''));
88
- if (canUseColor) {
89
- process.stdout.write('\u001B[96m');
90
- }
91
-
92
- setInterval(() => {
93
- process.stdout.write('.');
94
- }, 500);
95
-
96
- setTimeout(() => {
97
- if (canUseColor) {
98
- process.stdout.write('\u001B[0m\n');
99
- }
100
- process.exit(0);
101
- }, secs * 1000 + 100);