@alfalab/core-components-base-modal 5.0.10 → 5.1.0
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 -0
- package/Component.js +3 -1
- package/cssm/Component.d.ts +1 -0
- package/cssm/Component.js +2 -0
- package/esm/Component.d.ts +1 -0
- package/esm/Component.js +3 -1
- package/esm/index.css +13 -13
- package/index.css +13 -13
- package/modern/Component.d.ts +1 -0
- package/modern/Component.js +3 -1
- package/modern/index.css +13 -13
- package/package.json +1 -1
package/Component.d.ts
CHANGED
package/Component.js
CHANGED
|
@@ -21,11 +21,12 @@ var FocusLock__default = /*#__PURE__*/_interopDefaultCompat(FocusLock);
|
|
|
21
21
|
var mergeRefs__default = /*#__PURE__*/_interopDefaultCompat(mergeRefs);
|
|
22
22
|
var cn__default = /*#__PURE__*/_interopDefaultCompat(cn);
|
|
23
23
|
|
|
24
|
-
var styles = {"component":"base-
|
|
24
|
+
var styles = {"component":"base-modal__component_11i04","wrapper":"base-modal__wrapper_11i04","content":"base-modal__content_11i04","hidden":"base-modal__hidden_11i04","backdrop":"base-modal__backdrop_11i04","appear":"base-modal__appear_11i04","enter":"base-modal__enter_11i04","appearActive":"base-modal__appearActive_11i04","enterActive":"base-modal__enterActive_11i04","exit":"base-modal__exit_11i04","exitActive":"base-modal__exitActive_11i04","exitDone":"base-modal__exitDone_11i04"};
|
|
25
25
|
require('./index.css')
|
|
26
26
|
|
|
27
27
|
// eslint-disable-next-line @typescript-eslint/no-redeclare
|
|
28
28
|
var BaseModalContext = React__default.default.createContext({
|
|
29
|
+
parentRef: { current: null },
|
|
29
30
|
hasFooter: false,
|
|
30
31
|
hasHeader: false,
|
|
31
32
|
hasScroll: false,
|
|
@@ -205,6 +206,7 @@ var BaseModal = React.forwardRef(function (_a, ref) {
|
|
|
205
206
|
};
|
|
206
207
|
}, []);
|
|
207
208
|
var contextValue = React.useMemo(function () { return ({
|
|
209
|
+
parentRef: wrapperRef,
|
|
208
210
|
hasHeader: hasHeader,
|
|
209
211
|
hasFooter: hasFooter,
|
|
210
212
|
hasScroll: hasScroll,
|
package/cssm/Component.d.ts
CHANGED
package/cssm/Component.js
CHANGED
|
@@ -25,6 +25,7 @@ var styles__default = /*#__PURE__*/_interopDefaultCompat(styles);
|
|
|
25
25
|
|
|
26
26
|
// eslint-disable-next-line @typescript-eslint/no-redeclare
|
|
27
27
|
var BaseModalContext = React__default.default.createContext({
|
|
28
|
+
parentRef: { current: null },
|
|
28
29
|
hasFooter: false,
|
|
29
30
|
hasHeader: false,
|
|
30
31
|
hasScroll: false,
|
|
@@ -204,6 +205,7 @@ var BaseModal = React.forwardRef(function (_a, ref) {
|
|
|
204
205
|
};
|
|
205
206
|
}, []);
|
|
206
207
|
var contextValue = React.useMemo(function () { return ({
|
|
208
|
+
parentRef: wrapperRef,
|
|
207
209
|
hasHeader: hasHeader,
|
|
208
210
|
hasFooter: hasFooter,
|
|
209
211
|
hasScroll: hasScroll,
|
package/esm/Component.d.ts
CHANGED
package/esm/Component.js
CHANGED
|
@@ -12,11 +12,12 @@ import { isScrolledToTop, isScrolledToBottom, handleContainer, restoreContainerS
|
|
|
12
12
|
import './matches-polyfill.js';
|
|
13
13
|
import '@alfalab/core-components-global-store/esm';
|
|
14
14
|
|
|
15
|
-
var styles = {"component":"base-
|
|
15
|
+
var styles = {"component":"base-modal__component_11i04","wrapper":"base-modal__wrapper_11i04","content":"base-modal__content_11i04","hidden":"base-modal__hidden_11i04","backdrop":"base-modal__backdrop_11i04","appear":"base-modal__appear_11i04","enter":"base-modal__enter_11i04","appearActive":"base-modal__appearActive_11i04","enterActive":"base-modal__enterActive_11i04","exit":"base-modal__exit_11i04","exitActive":"base-modal__exitActive_11i04","exitDone":"base-modal__exitDone_11i04"};
|
|
16
16
|
require('./index.css')
|
|
17
17
|
|
|
18
18
|
// eslint-disable-next-line @typescript-eslint/no-redeclare
|
|
19
19
|
var BaseModalContext = React.createContext({
|
|
20
|
+
parentRef: { current: null },
|
|
20
21
|
hasFooter: false,
|
|
21
22
|
hasHeader: false,
|
|
22
23
|
hasScroll: false,
|
|
@@ -196,6 +197,7 @@ var BaseModal = forwardRef(function (_a, ref) {
|
|
|
196
197
|
};
|
|
197
198
|
}, []);
|
|
198
199
|
var contextValue = useMemo(function () { return ({
|
|
200
|
+
parentRef: wrapperRef,
|
|
199
201
|
hasHeader: hasHeader,
|
|
200
202
|
hasFooter: hasFooter,
|
|
201
203
|
hasScroll: hasScroll,
|
package/esm/index.css
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: n3prj */
|
|
2
2
|
:root {
|
|
3
3
|
} /* deprecated */ :root {
|
|
4
4
|
--color-light-bg-primary: #fff;
|
|
@@ -15,13 +15,13 @@
|
|
|
15
15
|
} :root {
|
|
16
16
|
} :root {
|
|
17
17
|
} :root {
|
|
18
|
-
} .base-
|
|
18
|
+
} .base-modal__component_11i04 {
|
|
19
19
|
position: relative;
|
|
20
20
|
box-sizing: border-box;
|
|
21
21
|
background: var(--color-light-bg-primary);
|
|
22
22
|
margin: auto;
|
|
23
23
|
flex-shrink: 0;
|
|
24
|
-
} .base-
|
|
24
|
+
} .base-modal__wrapper_11i04 {
|
|
25
25
|
position: fixed;
|
|
26
26
|
top: 0;
|
|
27
27
|
left: 0;
|
|
@@ -33,27 +33,27 @@
|
|
|
33
33
|
flex-direction: column;
|
|
34
34
|
align-items: center;
|
|
35
35
|
outline: 0;
|
|
36
|
-
} .base-
|
|
36
|
+
} .base-modal__content_11i04 {
|
|
37
37
|
width: 100%;
|
|
38
38
|
height: 100%;
|
|
39
39
|
display: flex;
|
|
40
40
|
flex-direction: column;
|
|
41
41
|
flex: 1;
|
|
42
|
-
} .base-
|
|
42
|
+
} .base-modal__hidden_11i04 {
|
|
43
43
|
display: none;
|
|
44
|
-
} .base-
|
|
44
|
+
} .base-modal__backdrop_11i04 {
|
|
45
45
|
z-index: 0;
|
|
46
|
-
} .base-
|
|
47
|
-
.base-
|
|
46
|
+
} .base-modal__appear_11i04,
|
|
47
|
+
.base-modal__enter_11i04 {
|
|
48
48
|
opacity: 0;
|
|
49
|
-
} .base-
|
|
50
|
-
.base-
|
|
49
|
+
} .base-modal__appearActive_11i04,
|
|
50
|
+
.base-modal__enterActive_11i04 {
|
|
51
51
|
opacity: 1;
|
|
52
52
|
transition: opacity 200ms ease-in;
|
|
53
|
-
} .base-
|
|
53
|
+
} .base-modal__exit_11i04 {
|
|
54
54
|
opacity: 1;
|
|
55
|
-
} .base-
|
|
56
|
-
.base-
|
|
55
|
+
} .base-modal__exitActive_11i04,
|
|
56
|
+
.base-modal__exitDone_11i04 {
|
|
57
57
|
opacity: 0;
|
|
58
58
|
transition: opacity 200ms ease-out;
|
|
59
59
|
}
|
package/index.css
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: n3prj */
|
|
2
2
|
:root {
|
|
3
3
|
} /* deprecated */ :root {
|
|
4
4
|
--color-light-bg-primary: #fff;
|
|
@@ -15,13 +15,13 @@
|
|
|
15
15
|
} :root {
|
|
16
16
|
} :root {
|
|
17
17
|
} :root {
|
|
18
|
-
} .base-
|
|
18
|
+
} .base-modal__component_11i04 {
|
|
19
19
|
position: relative;
|
|
20
20
|
box-sizing: border-box;
|
|
21
21
|
background: var(--color-light-bg-primary);
|
|
22
22
|
margin: auto;
|
|
23
23
|
flex-shrink: 0;
|
|
24
|
-
} .base-
|
|
24
|
+
} .base-modal__wrapper_11i04 {
|
|
25
25
|
position: fixed;
|
|
26
26
|
top: 0;
|
|
27
27
|
left: 0;
|
|
@@ -33,27 +33,27 @@
|
|
|
33
33
|
flex-direction: column;
|
|
34
34
|
align-items: center;
|
|
35
35
|
outline: 0;
|
|
36
|
-
} .base-
|
|
36
|
+
} .base-modal__content_11i04 {
|
|
37
37
|
width: 100%;
|
|
38
38
|
height: 100%;
|
|
39
39
|
display: flex;
|
|
40
40
|
flex-direction: column;
|
|
41
41
|
flex: 1;
|
|
42
|
-
} .base-
|
|
42
|
+
} .base-modal__hidden_11i04 {
|
|
43
43
|
display: none;
|
|
44
|
-
} .base-
|
|
44
|
+
} .base-modal__backdrop_11i04 {
|
|
45
45
|
z-index: 0;
|
|
46
|
-
} .base-
|
|
47
|
-
.base-
|
|
46
|
+
} .base-modal__appear_11i04,
|
|
47
|
+
.base-modal__enter_11i04 {
|
|
48
48
|
opacity: 0;
|
|
49
|
-
} .base-
|
|
50
|
-
.base-
|
|
49
|
+
} .base-modal__appearActive_11i04,
|
|
50
|
+
.base-modal__enterActive_11i04 {
|
|
51
51
|
opacity: 1;
|
|
52
52
|
transition: opacity 200ms ease-in;
|
|
53
|
-
} .base-
|
|
53
|
+
} .base-modal__exit_11i04 {
|
|
54
54
|
opacity: 1;
|
|
55
|
-
} .base-
|
|
56
|
-
.base-
|
|
55
|
+
} .base-modal__exitActive_11i04,
|
|
56
|
+
.base-modal__exitDone_11i04 {
|
|
57
57
|
opacity: 0;
|
|
58
58
|
transition: opacity 200ms ease-out;
|
|
59
59
|
}
|
package/modern/Component.d.ts
CHANGED
package/modern/Component.js
CHANGED
|
@@ -11,12 +11,13 @@ import { isScrolledToTop, isScrolledToBottom, handleContainer, restoreContainerS
|
|
|
11
11
|
import './matches-polyfill.js';
|
|
12
12
|
import '@alfalab/core-components-global-store/modern';
|
|
13
13
|
|
|
14
|
-
const styles = {"component":"base-
|
|
14
|
+
const styles = {"component":"base-modal__component_11i04","wrapper":"base-modal__wrapper_11i04","content":"base-modal__content_11i04","hidden":"base-modal__hidden_11i04","backdrop":"base-modal__backdrop_11i04","appear":"base-modal__appear_11i04","enter":"base-modal__enter_11i04","appearActive":"base-modal__appearActive_11i04","enterActive":"base-modal__enterActive_11i04","exit":"base-modal__exit_11i04","exitActive":"base-modal__exitActive_11i04","exitDone":"base-modal__exitDone_11i04"};
|
|
15
15
|
require('./index.css')
|
|
16
16
|
|
|
17
17
|
/* eslint-disable jsx-a11y/no-noninteractive-element-interactions */
|
|
18
18
|
// eslint-disable-next-line @typescript-eslint/no-redeclare
|
|
19
19
|
const BaseModalContext = React.createContext({
|
|
20
|
+
parentRef: { current: null },
|
|
20
21
|
hasFooter: false,
|
|
21
22
|
hasHeader: false,
|
|
22
23
|
hasScroll: false,
|
|
@@ -194,6 +195,7 @@ const BaseModal = forwardRef(({ open, container, children, scrollHandler = 'wrap
|
|
|
194
195
|
};
|
|
195
196
|
}, []);
|
|
196
197
|
const contextValue = useMemo(() => ({
|
|
198
|
+
parentRef: wrapperRef,
|
|
197
199
|
hasHeader,
|
|
198
200
|
hasFooter,
|
|
199
201
|
hasScroll,
|
package/modern/index.css
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: n3prj */
|
|
2
2
|
:root {
|
|
3
3
|
} /* deprecated */ :root {
|
|
4
4
|
--color-light-bg-primary: #fff;
|
|
@@ -15,13 +15,13 @@
|
|
|
15
15
|
} :root {
|
|
16
16
|
} :root {
|
|
17
17
|
} :root {
|
|
18
|
-
} .base-
|
|
18
|
+
} .base-modal__component_11i04 {
|
|
19
19
|
position: relative;
|
|
20
20
|
box-sizing: border-box;
|
|
21
21
|
background: var(--color-light-bg-primary);
|
|
22
22
|
margin: auto;
|
|
23
23
|
flex-shrink: 0;
|
|
24
|
-
} .base-
|
|
24
|
+
} .base-modal__wrapper_11i04 {
|
|
25
25
|
position: fixed;
|
|
26
26
|
top: 0;
|
|
27
27
|
left: 0;
|
|
@@ -33,27 +33,27 @@
|
|
|
33
33
|
flex-direction: column;
|
|
34
34
|
align-items: center;
|
|
35
35
|
outline: 0;
|
|
36
|
-
} .base-
|
|
36
|
+
} .base-modal__content_11i04 {
|
|
37
37
|
width: 100%;
|
|
38
38
|
height: 100%;
|
|
39
39
|
display: flex;
|
|
40
40
|
flex-direction: column;
|
|
41
41
|
flex: 1;
|
|
42
|
-
} .base-
|
|
42
|
+
} .base-modal__hidden_11i04 {
|
|
43
43
|
display: none;
|
|
44
|
-
} .base-
|
|
44
|
+
} .base-modal__backdrop_11i04 {
|
|
45
45
|
z-index: 0;
|
|
46
|
-
} .base-
|
|
47
|
-
.base-
|
|
46
|
+
} .base-modal__appear_11i04,
|
|
47
|
+
.base-modal__enter_11i04 {
|
|
48
48
|
opacity: 0;
|
|
49
|
-
} .base-
|
|
50
|
-
.base-
|
|
49
|
+
} .base-modal__appearActive_11i04,
|
|
50
|
+
.base-modal__enterActive_11i04 {
|
|
51
51
|
opacity: 1;
|
|
52
52
|
transition: opacity 200ms ease-in;
|
|
53
|
-
} .base-
|
|
53
|
+
} .base-modal__exit_11i04 {
|
|
54
54
|
opacity: 1;
|
|
55
|
-
} .base-
|
|
56
|
-
.base-
|
|
55
|
+
} .base-modal__exitActive_11i04,
|
|
56
|
+
.base-modal__exitDone_11i04 {
|
|
57
57
|
opacity: 0;
|
|
58
58
|
transition: opacity 200ms ease-out;
|
|
59
59
|
}
|