@equinor/eds-core-react 0.41.3 → 0.41.4-dev02092024
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/eds-core-react.cjs
CHANGED
|
@@ -6398,9 +6398,11 @@ const Popover$1 = /*#__PURE__*/react.forwardRef(function Popover({
|
|
|
6398
6398
|
const {
|
|
6399
6399
|
getFloatingProps
|
|
6400
6400
|
} = react$1.useInteractions([react$1.useDismiss(context)]);
|
|
6401
|
-
|
|
6401
|
+
react.useEffect(() => {
|
|
6402
6402
|
if (open) {
|
|
6403
|
-
refs.floating.current
|
|
6403
|
+
if (refs.floating.current) {
|
|
6404
|
+
refs.floating.current?.showPopover();
|
|
6405
|
+
}
|
|
6404
6406
|
} else {
|
|
6405
6407
|
refs.floating.current?.hidePopover();
|
|
6406
6408
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { forwardRef, useRef, useMemo, useEffect } from 'react';
|
|
2
2
|
import styled, { css, ThemeProvider } from 'styled-components';
|
|
3
|
-
import { typographyTemplate, bordersTemplate, outlineTemplate, mergeRefs,
|
|
3
|
+
import { typographyTemplate, bordersTemplate, outlineTemplate, mergeRefs, useToken } from '@equinor/eds-utils';
|
|
4
4
|
import { popover } from './Popover.tokens.js';
|
|
5
5
|
import { useFloating, offset, flip, shift, arrow, autoUpdate, useInteractions, useDismiss, FloatingFocusManager } from '@floating-ui/react';
|
|
6
6
|
import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
|
|
@@ -96,9 +96,11 @@ const Popover = /*#__PURE__*/forwardRef(function Popover({
|
|
|
96
96
|
const {
|
|
97
97
|
getFloatingProps
|
|
98
98
|
} = useInteractions([useDismiss(context)]);
|
|
99
|
-
|
|
99
|
+
useEffect(() => {
|
|
100
100
|
if (open) {
|
|
101
|
-
refs.floating.current
|
|
101
|
+
if (refs.floating.current) {
|
|
102
|
+
refs.floating.current?.showPopover();
|
|
103
|
+
}
|
|
102
104
|
} else {
|
|
103
105
|
refs.floating.current?.hidePopover();
|
|
104
106
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@equinor/eds-core-react",
|
|
3
|
-
"version": "0.41.
|
|
3
|
+
"version": "0.41.4-dev02092024",
|
|
4
4
|
"description": "The React implementation of the Equinor Design System",
|
|
5
5
|
"sideEffects": [
|
|
6
6
|
"**/*.css"
|
|
@@ -85,11 +85,11 @@
|
|
|
85
85
|
"@react-stately/calendar": "^3.5.3",
|
|
86
86
|
"@react-stately/datepicker": "^3.10.1",
|
|
87
87
|
"@react-types/shared": "^3.24.1",
|
|
88
|
-
"@tanstack/react-virtual": "3.
|
|
89
|
-
"downshift": "9.0.
|
|
88
|
+
"@tanstack/react-virtual": "3.10.6",
|
|
89
|
+
"downshift": "9.0.8",
|
|
90
90
|
"react-aria": "^3.34.1",
|
|
91
|
-
"@equinor/eds-tokens": "0.9.2",
|
|
92
91
|
"@equinor/eds-icons": "^0.21.0",
|
|
92
|
+
"@equinor/eds-tokens": "0.9.2",
|
|
93
93
|
"@equinor/eds-utils": "0.8.5"
|
|
94
94
|
},
|
|
95
95
|
"scripts": {
|