@alfalab/core-components-notification 6.1.4 → 6.1.5
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.d.ts +1 -1
- package/Component.js +5 -14
- package/cssm/Component.d.ts +1 -1
- package/cssm/Component.js +4 -13
- package/cssm/index.js +2 -2
- package/esm/Component.d.ts +1 -1
- package/esm/Component.js +4 -13
- package/esm/index.css +8 -8
- package/esm/index.js +2 -2
- package/index.css +8 -8
- package/index.js +2 -2
- package/modern/Component.d.ts +1 -1
- package/modern/Component.js +7 -16
- package/modern/index.css +8 -8
- package/modern/index.js +2 -2
- package/package.json +2 -2
package/Component.d.ts
CHANGED
|
@@ -47,7 +47,7 @@ declare const Notification: React.ForwardRefExoticComponent<React.HTMLAttributes
|
|
|
47
47
|
actionSectionClassName?: string | undefined;
|
|
48
48
|
children?: React.ReactNode;
|
|
49
49
|
title?: React.ReactNode;
|
|
50
|
-
badge?: "
|
|
50
|
+
badge?: "positive" | "attention" | "negative" | undefined;
|
|
51
51
|
leftAddons?: React.ReactNode;
|
|
52
52
|
actionButton?: React.ReactNode;
|
|
53
53
|
dataTestId?: string | undefined;
|
package/Component.js
CHANGED
|
@@ -3,23 +3,23 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
var React = require('react');
|
|
6
|
-
var cn = require('classnames');
|
|
7
6
|
var mergeRefs = require('react-merge-refs');
|
|
8
7
|
var reactSwipeable = require('react-swipeable');
|
|
8
|
+
var cn = require('classnames');
|
|
9
9
|
var elementClosest = require('element-closest');
|
|
10
10
|
var coreComponentsPortal = require('@alfalab/core-components-portal');
|
|
11
|
-
var coreComponentsToastPlate = require('@alfalab/core-components-toast-plate');
|
|
12
11
|
var coreComponentsStack = require('@alfalab/core-components-stack');
|
|
12
|
+
var coreComponentsToastPlate = require('@alfalab/core-components-toast-plate');
|
|
13
13
|
var utils_index = require('./utils/index.js');
|
|
14
14
|
|
|
15
15
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
16
16
|
|
|
17
17
|
var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
|
|
18
|
-
var cn__default = /*#__PURE__*/_interopDefaultLegacy(cn);
|
|
19
18
|
var mergeRefs__default = /*#__PURE__*/_interopDefaultLegacy(mergeRefs);
|
|
19
|
+
var cn__default = /*#__PURE__*/_interopDefaultLegacy(cn);
|
|
20
20
|
var elementClosest__default = /*#__PURE__*/_interopDefaultLegacy(elementClosest);
|
|
21
21
|
|
|
22
|
-
|
|
22
|
+
/******************************************************************************
|
|
23
23
|
Copyright (c) Microsoft Corporation.
|
|
24
24
|
|
|
25
25
|
Permission to use, copy, modify, and/or distribute this software for any
|
|
@@ -58,7 +58,7 @@ function __rest(s, e) {
|
|
|
58
58
|
return t;
|
|
59
59
|
}
|
|
60
60
|
|
|
61
|
-
var styles = {"notificationComponent":"
|
|
61
|
+
var styles = {"notificationComponent":"notification__notificationComponent_ah0tp","isVisible":"notification__isVisible_ah0tp","isClosing":"notification__isClosing_ah0tp","toastContent":"notification__toastContent_ah0tp","actionSection":"notification__actionSection_ah0tp"};
|
|
62
62
|
require('./index.css')
|
|
63
63
|
|
|
64
64
|
var notificationClassNameSelector = "." + styles.notificationComponent;
|
|
@@ -142,14 +142,5 @@ var Notification = React.forwardRef(function (_a, ref) {
|
|
|
142
142
|
_a), className), contentClassName: styles.toastContent, actionSectionClassName: cn__default['default'](actionSectionClassName, styles.actionSection), style: __assign({ top: offset, zIndex: computedZIndex }, style), onMouseEnter: handleMouseEnter, onMouseLeave: handleMouseLeave, ref: mergeRefs__default['default']([ref, notificationRef]), role: visible ? 'alert' : undefined, hasCloser: hasCloser, onClose: onClose }, restProps), children))));
|
|
143
143
|
}));
|
|
144
144
|
});
|
|
145
|
-
/**
|
|
146
|
-
* Для отображения в сторибуке
|
|
147
|
-
*/
|
|
148
|
-
Notification.defaultProps = {
|
|
149
|
-
autoCloseDelay: 5000,
|
|
150
|
-
offset: 108,
|
|
151
|
-
hasCloser: true,
|
|
152
|
-
usePortal: true,
|
|
153
|
-
};
|
|
154
145
|
|
|
155
146
|
exports.Notification = Notification;
|
package/cssm/Component.d.ts
CHANGED
|
@@ -47,7 +47,7 @@ declare const Notification: React.ForwardRefExoticComponent<React.HTMLAttributes
|
|
|
47
47
|
actionSectionClassName?: string | undefined;
|
|
48
48
|
children?: React.ReactNode;
|
|
49
49
|
title?: React.ReactNode;
|
|
50
|
-
badge?: "
|
|
50
|
+
badge?: "positive" | "attention" | "negative" | undefined;
|
|
51
51
|
leftAddons?: React.ReactNode;
|
|
52
52
|
actionButton?: React.ReactNode;
|
|
53
53
|
dataTestId?: string | undefined;
|
package/cssm/Component.js
CHANGED
|
@@ -3,25 +3,25 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
var React = require('react');
|
|
6
|
-
var cn = require('classnames');
|
|
7
6
|
var mergeRefs = require('react-merge-refs');
|
|
8
7
|
var reactSwipeable = require('react-swipeable');
|
|
8
|
+
var cn = require('classnames');
|
|
9
9
|
var elementClosest = require('element-closest');
|
|
10
10
|
var coreComponentsPortal = require('@alfalab/core-components-portal/cssm');
|
|
11
|
-
var coreComponentsToastPlate = require('@alfalab/core-components-toast-plate/cssm');
|
|
12
11
|
var coreComponentsStack = require('@alfalab/core-components-stack/cssm');
|
|
12
|
+
var coreComponentsToastPlate = require('@alfalab/core-components-toast-plate/cssm');
|
|
13
13
|
var utils_index = require('./utils/index.js');
|
|
14
14
|
var styles = require('./index.module.css');
|
|
15
15
|
|
|
16
16
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
17
17
|
|
|
18
18
|
var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
|
|
19
|
-
var cn__default = /*#__PURE__*/_interopDefaultLegacy(cn);
|
|
20
19
|
var mergeRefs__default = /*#__PURE__*/_interopDefaultLegacy(mergeRefs);
|
|
20
|
+
var cn__default = /*#__PURE__*/_interopDefaultLegacy(cn);
|
|
21
21
|
var elementClosest__default = /*#__PURE__*/_interopDefaultLegacy(elementClosest);
|
|
22
22
|
var styles__default = /*#__PURE__*/_interopDefaultLegacy(styles);
|
|
23
23
|
|
|
24
|
-
|
|
24
|
+
/******************************************************************************
|
|
25
25
|
Copyright (c) Microsoft Corporation.
|
|
26
26
|
|
|
27
27
|
Permission to use, copy, modify, and/or distribute this software for any
|
|
@@ -141,14 +141,5 @@ var Notification = React.forwardRef(function (_a, ref) {
|
|
|
141
141
|
_a), className), contentClassName: styles__default['default'].toastContent, actionSectionClassName: cn__default['default'](actionSectionClassName, styles__default['default'].actionSection), style: __assign({ top: offset, zIndex: computedZIndex }, style), onMouseEnter: handleMouseEnter, onMouseLeave: handleMouseLeave, ref: mergeRefs__default['default']([ref, notificationRef]), role: visible ? 'alert' : undefined, hasCloser: hasCloser, onClose: onClose }, restProps), children))));
|
|
142
142
|
}));
|
|
143
143
|
});
|
|
144
|
-
/**
|
|
145
|
-
* Для отображения в сторибуке
|
|
146
|
-
*/
|
|
147
|
-
Notification.defaultProps = {
|
|
148
|
-
autoCloseDelay: 5000,
|
|
149
|
-
offset: 108,
|
|
150
|
-
hasCloser: true,
|
|
151
|
-
usePortal: true,
|
|
152
|
-
};
|
|
153
144
|
|
|
154
145
|
exports.Notification = Notification;
|
package/cssm/index.js
CHANGED
|
@@ -4,13 +4,13 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
4
4
|
|
|
5
5
|
var Component = require('./Component.js');
|
|
6
6
|
require('react');
|
|
7
|
-
require('classnames');
|
|
8
7
|
require('react-merge-refs');
|
|
9
8
|
require('react-swipeable');
|
|
9
|
+
require('classnames');
|
|
10
10
|
require('element-closest');
|
|
11
11
|
require('@alfalab/core-components-portal/cssm');
|
|
12
|
-
require('@alfalab/core-components-toast-plate/cssm');
|
|
13
12
|
require('@alfalab/core-components-stack/cssm');
|
|
13
|
+
require('@alfalab/core-components-toast-plate/cssm');
|
|
14
14
|
require('./utils/index.js');
|
|
15
15
|
require('./index.module.css');
|
|
16
16
|
|
package/esm/Component.d.ts
CHANGED
|
@@ -47,7 +47,7 @@ declare const Notification: React.ForwardRefExoticComponent<React.HTMLAttributes
|
|
|
47
47
|
actionSectionClassName?: string | undefined;
|
|
48
48
|
children?: React.ReactNode;
|
|
49
49
|
title?: React.ReactNode;
|
|
50
|
-
badge?: "
|
|
50
|
+
badge?: "positive" | "attention" | "negative" | undefined;
|
|
51
51
|
leftAddons?: React.ReactNode;
|
|
52
52
|
actionButton?: React.ReactNode;
|
|
53
53
|
dataTestId?: string | undefined;
|
package/esm/Component.js
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import React, { forwardRef, useRef, useState, useCallback, useEffect, Fragment } from 'react';
|
|
2
|
-
import cn from 'classnames';
|
|
3
2
|
import mergeRefs from 'react-merge-refs';
|
|
4
3
|
import { useSwipeable } from 'react-swipeable';
|
|
4
|
+
import cn from 'classnames';
|
|
5
5
|
import elementClosest from 'element-closest';
|
|
6
6
|
import { Portal } from '@alfalab/core-components-portal/esm';
|
|
7
|
-
import { ToastPlate } from '@alfalab/core-components-toast-plate/esm';
|
|
8
7
|
import { stackingOrder, Stack } from '@alfalab/core-components-stack/esm';
|
|
8
|
+
import { ToastPlate } from '@alfalab/core-components-toast-plate/esm';
|
|
9
9
|
import { useClickOutside } from './utils/index.js';
|
|
10
10
|
|
|
11
|
-
|
|
11
|
+
/******************************************************************************
|
|
12
12
|
Copyright (c) Microsoft Corporation.
|
|
13
13
|
|
|
14
14
|
Permission to use, copy, modify, and/or distribute this software for any
|
|
@@ -47,7 +47,7 @@ function __rest(s, e) {
|
|
|
47
47
|
return t;
|
|
48
48
|
}
|
|
49
49
|
|
|
50
|
-
var styles = {"notificationComponent":"
|
|
50
|
+
var styles = {"notificationComponent":"notification__notificationComponent_ah0tp","isVisible":"notification__isVisible_ah0tp","isClosing":"notification__isClosing_ah0tp","toastContent":"notification__toastContent_ah0tp","actionSection":"notification__actionSection_ah0tp"};
|
|
51
51
|
require('./index.css')
|
|
52
52
|
|
|
53
53
|
var notificationClassNameSelector = "." + styles.notificationComponent;
|
|
@@ -131,14 +131,5 @@ var Notification = forwardRef(function (_a, ref) {
|
|
|
131
131
|
_a), className), contentClassName: styles.toastContent, actionSectionClassName: cn(actionSectionClassName, styles.actionSection), style: __assign({ top: offset, zIndex: computedZIndex }, style), onMouseEnter: handleMouseEnter, onMouseLeave: handleMouseLeave, ref: mergeRefs([ref, notificationRef]), role: visible ? 'alert' : undefined, hasCloser: hasCloser, onClose: onClose }, restProps), children))));
|
|
132
132
|
}));
|
|
133
133
|
});
|
|
134
|
-
/**
|
|
135
|
-
* Для отображения в сторибуке
|
|
136
|
-
*/
|
|
137
|
-
Notification.defaultProps = {
|
|
138
|
-
autoCloseDelay: 5000,
|
|
139
|
-
offset: 108,
|
|
140
|
-
hasCloser: true,
|
|
141
|
-
usePortal: true,
|
|
142
|
-
};
|
|
143
134
|
|
|
144
135
|
export { Notification };
|
package/esm/index.css
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: clgr7 */
|
|
2
2
|
:root {
|
|
3
3
|
|
|
4
4
|
/* Hard */
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
:root {
|
|
18
18
|
--notification-desktop-content-width: 278px;
|
|
19
19
|
}
|
|
20
|
-
.
|
|
20
|
+
.notification__notificationComponent_ah0tp {
|
|
21
21
|
visibility: hidden;
|
|
22
22
|
position: fixed;
|
|
23
23
|
right: var(--gap-s);
|
|
@@ -30,31 +30,31 @@
|
|
|
30
30
|
transition: transform 0.4s ease-out
|
|
31
31
|
}
|
|
32
32
|
@media screen and (min-width: 600px) {
|
|
33
|
-
.
|
|
33
|
+
.notification__notificationComponent_ah0tp {
|
|
34
34
|
right: var(--gap-4xl);
|
|
35
35
|
width: auto;
|
|
36
36
|
transform: translate(calc(100% + var(--gap-4xl)), 0)
|
|
37
37
|
}
|
|
38
38
|
}
|
|
39
|
-
.
|
|
39
|
+
.notification__notificationComponent_ah0tp.notification__isVisible_ah0tp {
|
|
40
40
|
visibility: visible;
|
|
41
41
|
transform: translate(0, 0);
|
|
42
42
|
}
|
|
43
|
-
.
|
|
43
|
+
.notification__notificationComponent_ah0tp.notification__isClosing_ah0tp {
|
|
44
44
|
transition: transform 0.1s ease-out;
|
|
45
45
|
transform: translate(100vw, 0)
|
|
46
46
|
}
|
|
47
47
|
@media screen and (min-width: 600px) {
|
|
48
|
-
.
|
|
48
|
+
.notification__notificationComponent_ah0tp.notification__isClosing_ah0tp {
|
|
49
49
|
transform: translate(calc(100% + var(--gap-4xl)), 0)
|
|
50
50
|
}
|
|
51
51
|
}
|
|
52
52
|
@media screen and (min-width: 600px) {
|
|
53
|
-
.
|
|
53
|
+
.notification__toastContent_ah0tp {
|
|
54
54
|
width: var(--notification-desktop-content-width)
|
|
55
55
|
}
|
|
56
56
|
}
|
|
57
|
-
.
|
|
57
|
+
.notification__actionSection_ah0tp {
|
|
58
58
|
min-width: 104px;
|
|
59
59
|
min-height: 48px;
|
|
60
60
|
padding: 0 var(--gap-xs);
|
package/esm/index.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
export { Notification } from './Component.js';
|
|
2
2
|
import 'react';
|
|
3
|
-
import 'classnames';
|
|
4
3
|
import 'react-merge-refs';
|
|
5
4
|
import 'react-swipeable';
|
|
5
|
+
import 'classnames';
|
|
6
6
|
import 'element-closest';
|
|
7
7
|
import '@alfalab/core-components-portal/esm';
|
|
8
|
-
import '@alfalab/core-components-toast-plate/esm';
|
|
9
8
|
import '@alfalab/core-components-stack/esm';
|
|
9
|
+
import '@alfalab/core-components-toast-plate/esm';
|
|
10
10
|
import './utils/index.js';
|
package/index.css
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: clgr7 */
|
|
2
2
|
:root {
|
|
3
3
|
|
|
4
4
|
/* Hard */
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
:root {
|
|
18
18
|
--notification-desktop-content-width: 278px;
|
|
19
19
|
}
|
|
20
|
-
.
|
|
20
|
+
.notification__notificationComponent_ah0tp {
|
|
21
21
|
visibility: hidden;
|
|
22
22
|
position: fixed;
|
|
23
23
|
right: var(--gap-s);
|
|
@@ -30,31 +30,31 @@
|
|
|
30
30
|
transition: transform 0.4s ease-out
|
|
31
31
|
}
|
|
32
32
|
@media screen and (min-width: 600px) {
|
|
33
|
-
.
|
|
33
|
+
.notification__notificationComponent_ah0tp {
|
|
34
34
|
right: var(--gap-4xl);
|
|
35
35
|
width: auto;
|
|
36
36
|
transform: translate(calc(100% + var(--gap-4xl)), 0)
|
|
37
37
|
}
|
|
38
38
|
}
|
|
39
|
-
.
|
|
39
|
+
.notification__notificationComponent_ah0tp.notification__isVisible_ah0tp {
|
|
40
40
|
visibility: visible;
|
|
41
41
|
transform: translate(0, 0);
|
|
42
42
|
}
|
|
43
|
-
.
|
|
43
|
+
.notification__notificationComponent_ah0tp.notification__isClosing_ah0tp {
|
|
44
44
|
transition: transform 0.1s ease-out;
|
|
45
45
|
transform: translate(100vw, 0)
|
|
46
46
|
}
|
|
47
47
|
@media screen and (min-width: 600px) {
|
|
48
|
-
.
|
|
48
|
+
.notification__notificationComponent_ah0tp.notification__isClosing_ah0tp {
|
|
49
49
|
transform: translate(calc(100% + var(--gap-4xl)), 0)
|
|
50
50
|
}
|
|
51
51
|
}
|
|
52
52
|
@media screen and (min-width: 600px) {
|
|
53
|
-
.
|
|
53
|
+
.notification__toastContent_ah0tp {
|
|
54
54
|
width: var(--notification-desktop-content-width)
|
|
55
55
|
}
|
|
56
56
|
}
|
|
57
|
-
.
|
|
57
|
+
.notification__actionSection_ah0tp {
|
|
58
58
|
min-width: 104px;
|
|
59
59
|
min-height: 48px;
|
|
60
60
|
padding: 0 var(--gap-xs);
|
package/index.js
CHANGED
|
@@ -4,13 +4,13 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
4
4
|
|
|
5
5
|
var Component = require('./Component.js');
|
|
6
6
|
require('react');
|
|
7
|
-
require('classnames');
|
|
8
7
|
require('react-merge-refs');
|
|
9
8
|
require('react-swipeable');
|
|
9
|
+
require('classnames');
|
|
10
10
|
require('element-closest');
|
|
11
11
|
require('@alfalab/core-components-portal');
|
|
12
|
-
require('@alfalab/core-components-toast-plate');
|
|
13
12
|
require('@alfalab/core-components-stack');
|
|
13
|
+
require('@alfalab/core-components-toast-plate');
|
|
14
14
|
require('./utils/index.js');
|
|
15
15
|
|
|
16
16
|
|
package/modern/Component.d.ts
CHANGED
|
@@ -47,7 +47,7 @@ declare const Notification: React.ForwardRefExoticComponent<React.HTMLAttributes
|
|
|
47
47
|
actionSectionClassName?: string | undefined;
|
|
48
48
|
children?: React.ReactNode;
|
|
49
49
|
title?: React.ReactNode;
|
|
50
|
-
badge?: "
|
|
50
|
+
badge?: "positive" | "attention" | "negative" | undefined;
|
|
51
51
|
leftAddons?: React.ReactNode;
|
|
52
52
|
actionButton?: React.ReactNode;
|
|
53
53
|
dataTestId?: string | undefined;
|
package/modern/Component.js
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import React, { forwardRef, useRef, useState, useCallback, useEffect, Fragment } from 'react';
|
|
2
|
-
import cn from 'classnames';
|
|
3
2
|
import mergeRefs from 'react-merge-refs';
|
|
4
3
|
import { useSwipeable } from 'react-swipeable';
|
|
4
|
+
import cn from 'classnames';
|
|
5
5
|
import elementClosest from 'element-closest';
|
|
6
6
|
import { Portal } from '@alfalab/core-components-portal/modern';
|
|
7
|
-
import { ToastPlate } from '@alfalab/core-components-toast-plate/modern';
|
|
8
7
|
import { stackingOrder, Stack } from '@alfalab/core-components-stack/modern';
|
|
8
|
+
import { ToastPlate } from '@alfalab/core-components-toast-plate/modern';
|
|
9
9
|
import { useClickOutside } from './utils/index.js';
|
|
10
10
|
|
|
11
|
-
var styles = {"notificationComponent":"
|
|
11
|
+
var styles = {"notificationComponent":"notification__notificationComponent_ah0tp","isVisible":"notification__isVisible_ah0tp","isClosing":"notification__isClosing_ah0tp","toastContent":"notification__toastContent_ah0tp","actionSection":"notification__actionSection_ah0tp"};
|
|
12
12
|
require('./index.css')
|
|
13
13
|
|
|
14
14
|
const notificationClassNameSelector = `.${styles.notificationComponent}`;
|
|
@@ -80,25 +80,16 @@ const Notification = forwardRef(({ className, actionSectionClassName, children,
|
|
|
80
80
|
delta: 100,
|
|
81
81
|
});
|
|
82
82
|
const Wrapper = usePortal ? Portal : Fragment;
|
|
83
|
-
return (React.createElement(Stack, { value: zIndex }, computedZIndex => (React.createElement(Wrapper, null,
|
|
84
|
-
React.createElement("div",
|
|
85
|
-
React.createElement(ToastPlate,
|
|
83
|
+
return (React.createElement(Stack, { value: zIndex }, (computedZIndex) => (React.createElement(Wrapper, null,
|
|
84
|
+
React.createElement("div", { ...swipeableHandlers },
|
|
85
|
+
React.createElement(ToastPlate, { className: cn(styles.notificationComponent, {
|
|
86
86
|
[styles.isVisible]: visible,
|
|
87
87
|
[styles.isClosing]: isClosing,
|
|
88
88
|
}, className), contentClassName: styles.toastContent, actionSectionClassName: cn(actionSectionClassName, styles.actionSection), style: {
|
|
89
89
|
top: offset,
|
|
90
90
|
zIndex: computedZIndex,
|
|
91
91
|
...style,
|
|
92
|
-
}, onMouseEnter: handleMouseEnter, onMouseLeave: handleMouseLeave, ref: mergeRefs([ref, notificationRef]), role: visible ? 'alert' : undefined, hasCloser: hasCloser, onClose: onClose
|
|
92
|
+
}, onMouseEnter: handleMouseEnter, onMouseLeave: handleMouseLeave, ref: mergeRefs([ref, notificationRef]), role: visible ? 'alert' : undefined, hasCloser: hasCloser, onClose: onClose, ...restProps }, children))))));
|
|
93
93
|
});
|
|
94
|
-
/**
|
|
95
|
-
* Для отображения в сторибуке
|
|
96
|
-
*/
|
|
97
|
-
Notification.defaultProps = {
|
|
98
|
-
autoCloseDelay: 5000,
|
|
99
|
-
offset: 108,
|
|
100
|
-
hasCloser: true,
|
|
101
|
-
usePortal: true,
|
|
102
|
-
};
|
|
103
94
|
|
|
104
95
|
export { Notification };
|
package/modern/index.css
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: clgr7 */
|
|
2
2
|
:root {
|
|
3
3
|
|
|
4
4
|
/* Hard */
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
:root {
|
|
18
18
|
--notification-desktop-content-width: 278px;
|
|
19
19
|
}
|
|
20
|
-
.
|
|
20
|
+
.notification__notificationComponent_ah0tp {
|
|
21
21
|
visibility: hidden;
|
|
22
22
|
position: fixed;
|
|
23
23
|
right: var(--gap-s);
|
|
@@ -30,31 +30,31 @@
|
|
|
30
30
|
transition: transform 0.4s ease-out
|
|
31
31
|
}
|
|
32
32
|
@media screen and (min-width: 600px) {
|
|
33
|
-
.
|
|
33
|
+
.notification__notificationComponent_ah0tp {
|
|
34
34
|
right: var(--gap-4xl);
|
|
35
35
|
width: auto;
|
|
36
36
|
transform: translate(calc(100% + var(--gap-4xl)), 0)
|
|
37
37
|
}
|
|
38
38
|
}
|
|
39
|
-
.
|
|
39
|
+
.notification__notificationComponent_ah0tp.notification__isVisible_ah0tp {
|
|
40
40
|
visibility: visible;
|
|
41
41
|
transform: translate(0, 0);
|
|
42
42
|
}
|
|
43
|
-
.
|
|
43
|
+
.notification__notificationComponent_ah0tp.notification__isClosing_ah0tp {
|
|
44
44
|
transition: transform 0.1s ease-out;
|
|
45
45
|
transform: translate(100vw, 0)
|
|
46
46
|
}
|
|
47
47
|
@media screen and (min-width: 600px) {
|
|
48
|
-
.
|
|
48
|
+
.notification__notificationComponent_ah0tp.notification__isClosing_ah0tp {
|
|
49
49
|
transform: translate(calc(100% + var(--gap-4xl)), 0)
|
|
50
50
|
}
|
|
51
51
|
}
|
|
52
52
|
@media screen and (min-width: 600px) {
|
|
53
|
-
.
|
|
53
|
+
.notification__toastContent_ah0tp {
|
|
54
54
|
width: var(--notification-desktop-content-width)
|
|
55
55
|
}
|
|
56
56
|
}
|
|
57
|
-
.
|
|
57
|
+
.notification__actionSection_ah0tp {
|
|
58
58
|
min-width: 104px;
|
|
59
59
|
min-height: 48px;
|
|
60
60
|
padding: 0 var(--gap-xs);
|
package/modern/index.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import 'react';
|
|
2
|
-
import 'classnames';
|
|
3
2
|
import 'react-merge-refs';
|
|
4
3
|
import 'react-swipeable';
|
|
4
|
+
import 'classnames';
|
|
5
5
|
import 'element-closest';
|
|
6
6
|
import '@alfalab/core-components-portal/modern';
|
|
7
|
-
import '@alfalab/core-components-toast-plate/modern';
|
|
8
7
|
import '@alfalab/core-components-stack/modern';
|
|
8
|
+
import '@alfalab/core-components-toast-plate/modern';
|
|
9
9
|
import './utils/index.js';
|
|
10
10
|
export { Notification } from './Component.js';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@alfalab/core-components-notification",
|
|
3
|
-
"version": "6.1.
|
|
3
|
+
"version": "6.1.5",
|
|
4
4
|
"description": "",
|
|
5
5
|
"keywords": [],
|
|
6
6
|
"license": "MIT",
|
|
@@ -19,7 +19,7 @@
|
|
|
19
19
|
"dependencies": {
|
|
20
20
|
"@alfalab/core-components-portal": "^3.1.0",
|
|
21
21
|
"@alfalab/core-components-stack": "^4.0.1",
|
|
22
|
-
"@alfalab/core-components-toast-plate": "^5.1.
|
|
22
|
+
"@alfalab/core-components-toast-plate": "^5.1.4",
|
|
23
23
|
"classnames": "^2.3.1",
|
|
24
24
|
"element-closest": "^3.0.2",
|
|
25
25
|
"react-merge-refs": "^1.1.0",
|