@alfalab/core-components-notification 6.1.25 → 6.1.27
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/Component.js +1 -1
- package/esm/Component.js +1 -1
- package/esm/index.css +8 -8
- package/index.css +8 -8
- package/modern/Component.js +1 -1
- package/modern/index.css +8 -8
- package/package.json +3 -6
- package/send-stats.js +0 -82
package/Component.js
CHANGED
|
@@ -20,7 +20,7 @@ var mergeRefs__default = /*#__PURE__*/_interopDefaultCompat(mergeRefs);
|
|
|
20
20
|
var cn__default = /*#__PURE__*/_interopDefaultCompat(cn);
|
|
21
21
|
var elementClosest__default = /*#__PURE__*/_interopDefaultCompat(elementClosest);
|
|
22
22
|
|
|
23
|
-
var styles = {"notificationComponent":"
|
|
23
|
+
var styles = {"notificationComponent":"notification__notificationComponent_1iv1d","isVisible":"notification__isVisible_1iv1d","isClosing":"notification__isClosing_1iv1d","toastContent":"notification__toastContent_1iv1d","actionSection":"notification__actionSection_1iv1d"};
|
|
24
24
|
require('./index.css')
|
|
25
25
|
|
|
26
26
|
var notificationClassNameSelector = ".".concat(styles.notificationComponent);
|
package/esm/Component.js
CHANGED
|
@@ -9,7 +9,7 @@ import { stackingOrder, Stack } from '@alfalab/core-components-stack/esm';
|
|
|
9
9
|
import { ToastPlate } from '@alfalab/core-components-toast-plate/esm';
|
|
10
10
|
import { useClickOutside } from './utils/index.js';
|
|
11
11
|
|
|
12
|
-
var styles = {"notificationComponent":"
|
|
12
|
+
var styles = {"notificationComponent":"notification__notificationComponent_1iv1d","isVisible":"notification__isVisible_1iv1d","isClosing":"notification__isClosing_1iv1d","toastContent":"notification__toastContent_1iv1d","actionSection":"notification__actionSection_1iv1d"};
|
|
13
13
|
require('./index.css')
|
|
14
14
|
|
|
15
15
|
var notificationClassNameSelector = ".".concat(styles.notificationComponent);
|
package/esm/index.css
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: 7cu0f */
|
|
2
2
|
:root {
|
|
3
3
|
} /* deprecated */ :root { /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */
|
|
4
4
|
} :root { /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */
|
|
@@ -21,7 +21,7 @@
|
|
|
21
21
|
} :root {
|
|
22
22
|
} :root {
|
|
23
23
|
--notification-desktop-content-width: 278px;
|
|
24
|
-
} .
|
|
24
|
+
} .notification__notificationComponent_1iv1d {
|
|
25
25
|
visibility: hidden;
|
|
26
26
|
position: fixed;
|
|
27
27
|
right: var(--gap-s);
|
|
@@ -32,24 +32,24 @@
|
|
|
32
32
|
-webkit-user-select: none;
|
|
33
33
|
user-select: none;
|
|
34
34
|
transition: transform 0.4s ease-out
|
|
35
|
-
} @media screen and (min-width: 600px) { .
|
|
35
|
+
} @media screen and (min-width: 600px) { .notification__notificationComponent_1iv1d {
|
|
36
36
|
right: var(--gap-4xl);
|
|
37
37
|
width: auto;
|
|
38
38
|
transform: translate(calc(100% + var(--gap-4xl)), 0)
|
|
39
39
|
}
|
|
40
|
-
} .
|
|
40
|
+
} .notification__notificationComponent_1iv1d.notification__isVisible_1iv1d {
|
|
41
41
|
visibility: visible;
|
|
42
42
|
transform: translate(0, 0);
|
|
43
|
-
} .
|
|
43
|
+
} .notification__notificationComponent_1iv1d.notification__isClosing_1iv1d {
|
|
44
44
|
transition: transform 0.1s ease-out;
|
|
45
45
|
transform: translate(100vw, 0)
|
|
46
|
-
} @media screen and (min-width: 600px) { .
|
|
46
|
+
} @media screen and (min-width: 600px) { .notification__notificationComponent_1iv1d.notification__isClosing_1iv1d {
|
|
47
47
|
transform: translate(calc(100% + var(--gap-4xl)), 0)
|
|
48
48
|
}
|
|
49
|
-
} @media screen and (min-width: 600px) { .
|
|
49
|
+
} @media screen and (min-width: 600px) { .notification__toastContent_1iv1d {
|
|
50
50
|
width: var(--notification-desktop-content-width)
|
|
51
51
|
}
|
|
52
|
-
} .
|
|
52
|
+
} .notification__actionSection_1iv1d {
|
|
53
53
|
min-width: 104px;
|
|
54
54
|
min-height: 48px;
|
|
55
55
|
padding: 0 var(--gap-xs);
|
package/index.css
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: 7cu0f */
|
|
2
2
|
:root {
|
|
3
3
|
} /* deprecated */ :root { /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */
|
|
4
4
|
} :root { /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */
|
|
@@ -21,7 +21,7 @@
|
|
|
21
21
|
} :root {
|
|
22
22
|
} :root {
|
|
23
23
|
--notification-desktop-content-width: 278px;
|
|
24
|
-
} .
|
|
24
|
+
} .notification__notificationComponent_1iv1d {
|
|
25
25
|
visibility: hidden;
|
|
26
26
|
position: fixed;
|
|
27
27
|
right: var(--gap-s);
|
|
@@ -32,24 +32,24 @@
|
|
|
32
32
|
-webkit-user-select: none;
|
|
33
33
|
user-select: none;
|
|
34
34
|
transition: transform 0.4s ease-out
|
|
35
|
-
} @media screen and (min-width: 600px) { .
|
|
35
|
+
} @media screen and (min-width: 600px) { .notification__notificationComponent_1iv1d {
|
|
36
36
|
right: var(--gap-4xl);
|
|
37
37
|
width: auto;
|
|
38
38
|
transform: translate(calc(100% + var(--gap-4xl)), 0)
|
|
39
39
|
}
|
|
40
|
-
} .
|
|
40
|
+
} .notification__notificationComponent_1iv1d.notification__isVisible_1iv1d {
|
|
41
41
|
visibility: visible;
|
|
42
42
|
transform: translate(0, 0);
|
|
43
|
-
} .
|
|
43
|
+
} .notification__notificationComponent_1iv1d.notification__isClosing_1iv1d {
|
|
44
44
|
transition: transform 0.1s ease-out;
|
|
45
45
|
transform: translate(100vw, 0)
|
|
46
|
-
} @media screen and (min-width: 600px) { .
|
|
46
|
+
} @media screen and (min-width: 600px) { .notification__notificationComponent_1iv1d.notification__isClosing_1iv1d {
|
|
47
47
|
transform: translate(calc(100% + var(--gap-4xl)), 0)
|
|
48
48
|
}
|
|
49
|
-
} @media screen and (min-width: 600px) { .
|
|
49
|
+
} @media screen and (min-width: 600px) { .notification__toastContent_1iv1d {
|
|
50
50
|
width: var(--notification-desktop-content-width)
|
|
51
51
|
}
|
|
52
|
-
} .
|
|
52
|
+
} .notification__actionSection_1iv1d {
|
|
53
53
|
min-width: 104px;
|
|
54
54
|
min-height: 48px;
|
|
55
55
|
padding: 0 var(--gap-xs);
|
package/modern/Component.js
CHANGED
|
@@ -8,7 +8,7 @@ import { Stack, stackingOrder } from '@alfalab/core-components-stack/modern';
|
|
|
8
8
|
import { ToastPlate } from '@alfalab/core-components-toast-plate/modern';
|
|
9
9
|
import { useClickOutside } from './utils/index.js';
|
|
10
10
|
|
|
11
|
-
const styles = {"notificationComponent":"
|
|
11
|
+
const styles = {"notificationComponent":"notification__notificationComponent_1iv1d","isVisible":"notification__isVisible_1iv1d","isClosing":"notification__isClosing_1iv1d","toastContent":"notification__toastContent_1iv1d","actionSection":"notification__actionSection_1iv1d"};
|
|
12
12
|
require('./index.css')
|
|
13
13
|
|
|
14
14
|
const notificationClassNameSelector = `.${styles.notificationComponent}`;
|
package/modern/index.css
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: 7cu0f */
|
|
2
2
|
:root {
|
|
3
3
|
} /* deprecated */ :root { /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */
|
|
4
4
|
} :root { /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */
|
|
@@ -21,7 +21,7 @@
|
|
|
21
21
|
} :root {
|
|
22
22
|
} :root {
|
|
23
23
|
--notification-desktop-content-width: 278px;
|
|
24
|
-
} .
|
|
24
|
+
} .notification__notificationComponent_1iv1d {
|
|
25
25
|
visibility: hidden;
|
|
26
26
|
position: fixed;
|
|
27
27
|
right: var(--gap-s);
|
|
@@ -32,24 +32,24 @@
|
|
|
32
32
|
-webkit-user-select: none;
|
|
33
33
|
user-select: none;
|
|
34
34
|
transition: transform 0.4s ease-out
|
|
35
|
-
} @media screen and (min-width: 600px) { .
|
|
35
|
+
} @media screen and (min-width: 600px) { .notification__notificationComponent_1iv1d {
|
|
36
36
|
right: var(--gap-4xl);
|
|
37
37
|
width: auto;
|
|
38
38
|
transform: translate(calc(100% + var(--gap-4xl)), 0)
|
|
39
39
|
}
|
|
40
|
-
} .
|
|
40
|
+
} .notification__notificationComponent_1iv1d.notification__isVisible_1iv1d {
|
|
41
41
|
visibility: visible;
|
|
42
42
|
transform: translate(0, 0);
|
|
43
|
-
} .
|
|
43
|
+
} .notification__notificationComponent_1iv1d.notification__isClosing_1iv1d {
|
|
44
44
|
transition: transform 0.1s ease-out;
|
|
45
45
|
transform: translate(100vw, 0)
|
|
46
|
-
} @media screen and (min-width: 600px) { .
|
|
46
|
+
} @media screen and (min-width: 600px) { .notification__notificationComponent_1iv1d.notification__isClosing_1iv1d {
|
|
47
47
|
transform: translate(calc(100% + var(--gap-4xl)), 0)
|
|
48
48
|
}
|
|
49
|
-
} @media screen and (min-width: 600px) { .
|
|
49
|
+
} @media screen and (min-width: 600px) { .notification__toastContent_1iv1d {
|
|
50
50
|
width: var(--notification-desktop-content-width)
|
|
51
51
|
}
|
|
52
|
-
} .
|
|
52
|
+
} .notification__actionSection_1iv1d {
|
|
53
53
|
min-width: 104px;
|
|
54
54
|
min-height: 48px;
|
|
55
55
|
padding: 0 var(--gap-xs);
|
package/package.json
CHANGED
|
@@ -1,14 +1,11 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@alfalab/core-components-notification",
|
|
3
|
-
"version": "6.1.
|
|
3
|
+
"version": "6.1.27",
|
|
4
4
|
"description": "",
|
|
5
5
|
"keywords": [],
|
|
6
6
|
"license": "MIT",
|
|
7
7
|
"main": "index.js",
|
|
8
8
|
"module": "./esm/index.js",
|
|
9
|
-
"scripts": {
|
|
10
|
-
"postinstall": "node -e \"if (require('fs').existsSync('./send-stats.js')){require('./send-stats.js')} \""
|
|
11
|
-
},
|
|
12
9
|
"publishConfig": {
|
|
13
10
|
"access": "public",
|
|
14
11
|
"directory": "dist"
|
|
@@ -17,9 +14,9 @@
|
|
|
17
14
|
"react": "^16.9.0 || ^17.0.1 || ^18.0.0"
|
|
18
15
|
},
|
|
19
16
|
"dependencies": {
|
|
20
|
-
"@alfalab/core-components-portal": "^3.1.
|
|
17
|
+
"@alfalab/core-components-portal": "^3.1.5",
|
|
21
18
|
"@alfalab/core-components-stack": "^4.0.4",
|
|
22
|
-
"@alfalab/core-components-toast-plate": "^5.1.
|
|
19
|
+
"@alfalab/core-components-toast-plate": "^5.1.24",
|
|
23
20
|
"classnames": "^2.3.1",
|
|
24
21
|
"element-closest": "^3.0.2",
|
|
25
22
|
"react-merge-refs": "^1.1.0",
|
package/send-stats.js
DELETED
|
@@ -1,82 +0,0 @@
|
|
|
1
|
-
const http = require('http');
|
|
2
|
-
const fs = require('fs');
|
|
3
|
-
const { promisify } = require('util');
|
|
4
|
-
const path = require('path');
|
|
5
|
-
|
|
6
|
-
const readFile = promisify(fs.readFile);
|
|
7
|
-
|
|
8
|
-
async function main() {
|
|
9
|
-
const remoteHost = process.env.NIS_HOST || 'digital';
|
|
10
|
-
const remotePort = process.env.NIS_PORT || 80;
|
|
11
|
-
const remotePath = process.env.NIS_PATH || '/npm-install-stats/api/install-stats';
|
|
12
|
-
|
|
13
|
-
try {
|
|
14
|
-
const [_, node, os, arch] =
|
|
15
|
-
/node\/v(\d+\.\d+\.\d+) (\w+) (\w+)/.exec(process.env.npm_config_user_agent) || [];
|
|
16
|
-
const [__, npm] = /npm\/(\d+\.\d+\.\d+)/.exec(process.env.npm_config_user_agent) || [];
|
|
17
|
-
const [___, yarn] = /yarn\/(\d+\.\d+\.\d+)/.exec(process.env.npm_config_user_agent) || [];
|
|
18
|
-
|
|
19
|
-
let ownPackageJson, packageJson;
|
|
20
|
-
|
|
21
|
-
try {
|
|
22
|
-
const result = await Promise.all([
|
|
23
|
-
readFile(path.join(process.cwd(), 'package.json'), 'utf-8'),
|
|
24
|
-
readFile(path.join(process.cwd(), '../../../package.json'), 'utf-8'),
|
|
25
|
-
]);
|
|
26
|
-
|
|
27
|
-
ownPackageJson = JSON.parse(result[0]);
|
|
28
|
-
packageJson = JSON.parse(result[1]);
|
|
29
|
-
} catch (err) {
|
|
30
|
-
ownPackageJson = '';
|
|
31
|
-
packageJson = '';
|
|
32
|
-
}
|
|
33
|
-
|
|
34
|
-
const data = {
|
|
35
|
-
node,
|
|
36
|
-
npm,
|
|
37
|
-
yarn,
|
|
38
|
-
os,
|
|
39
|
-
arch,
|
|
40
|
-
ownPackageJson: JSON.stringify(ownPackageJson),
|
|
41
|
-
packageJson: JSON.stringify(packageJson),
|
|
42
|
-
};
|
|
43
|
-
|
|
44
|
-
const body = JSON.stringify(data);
|
|
45
|
-
|
|
46
|
-
const options = {
|
|
47
|
-
host: remoteHost,
|
|
48
|
-
port: remotePort,
|
|
49
|
-
path: remotePath,
|
|
50
|
-
method: 'POST',
|
|
51
|
-
headers: {
|
|
52
|
-
'Content-Type': 'application/json',
|
|
53
|
-
'Content-Length': body.length,
|
|
54
|
-
},
|
|
55
|
-
};
|
|
56
|
-
|
|
57
|
-
return new Promise((resolve, reject) => {
|
|
58
|
-
const req = http.request(options, (res) => {
|
|
59
|
-
res.on('end', () => {
|
|
60
|
-
resolve();
|
|
61
|
-
});
|
|
62
|
-
});
|
|
63
|
-
|
|
64
|
-
req.on('error', () => {
|
|
65
|
-
reject();
|
|
66
|
-
});
|
|
67
|
-
|
|
68
|
-
req.write(body);
|
|
69
|
-
req.end();
|
|
70
|
-
});
|
|
71
|
-
} catch (error) {
|
|
72
|
-
throw error;
|
|
73
|
-
}
|
|
74
|
-
}
|
|
75
|
-
|
|
76
|
-
main()
|
|
77
|
-
.then(() => {
|
|
78
|
-
process.exit(0);
|
|
79
|
-
})
|
|
80
|
-
.catch(() => {
|
|
81
|
-
process.exit(0);
|
|
82
|
-
});
|