@gustavo-valsechi/client 1.4.128 → 1.4.130
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.
|
@@ -55,7 +55,7 @@ const TargetProviderContainer = ({ children }) => {
|
|
|
55
55
|
insideMemory.splice(import_lodash.default.findIndex(insideMemory, (i) => i === index), 1);
|
|
56
56
|
console.log("insideMemory in blur function", insideMemory);
|
|
57
57
|
elementFocusable(targets[index], index).focus();
|
|
58
|
-
elementFocusable(targets[index], index).blur();
|
|
58
|
+
setTimeout(() => elementFocusable(targets[index], index).blur(), 1);
|
|
59
59
|
};
|
|
60
60
|
const close = (index) => {
|
|
61
61
|
const element = containerRef.current[index];
|
|
@@ -120,7 +120,7 @@ const TargetProviderContainer = ({ children }) => {
|
|
|
120
120
|
element.addEventListener("click", () => {
|
|
121
121
|
const styles = window.getComputedStyle(targetElement);
|
|
122
122
|
if (styles.opacity === "1") {
|
|
123
|
-
|
|
123
|
+
blur(index);
|
|
124
124
|
return;
|
|
125
125
|
}
|
|
126
126
|
open(target, index);
|
|
@@ -183,15 +183,12 @@ const TargetProviderContainer = ({ children }) => {
|
|
|
183
183
|
import_styles.Container,
|
|
184
184
|
{
|
|
185
185
|
ref: (element) => containerRef.current[index] = element,
|
|
186
|
+
onMouseLeave: () => insideMemory.splice(import_lodash.default.findIndex(insideMemory, (i) => i === index), 1),
|
|
186
187
|
onMouseEnter: () => {
|
|
187
188
|
elementFocusable(target, index).focus();
|
|
188
189
|
if (import_lodash.default.some(insideMemory, (i) => i === index)) return;
|
|
189
190
|
insideMemory.push(index);
|
|
190
191
|
},
|
|
191
|
-
onMouseLeave: () => {
|
|
192
|
-
insideMemory.splice(import_lodash.default.findIndex(insideMemory, (i) => i === index), 1);
|
|
193
|
-
},
|
|
194
|
-
onClick: () => elementFocusable(target, index).focus(),
|
|
195
192
|
children: target.component
|
|
196
193
|
}
|
|
197
194
|
),
|
|
@@ -21,7 +21,7 @@ const TargetProviderContainer = ({ children }) => {
|
|
|
21
21
|
insideMemory.splice(_.findIndex(insideMemory, (i) => i === index), 1);
|
|
22
22
|
console.log("insideMemory in blur function", insideMemory);
|
|
23
23
|
elementFocusable(targets[index], index).focus();
|
|
24
|
-
elementFocusable(targets[index], index).blur();
|
|
24
|
+
setTimeout(() => elementFocusable(targets[index], index).blur(), 1);
|
|
25
25
|
};
|
|
26
26
|
const close = (index) => {
|
|
27
27
|
const element = containerRef.current[index];
|
|
@@ -86,7 +86,7 @@ const TargetProviderContainer = ({ children }) => {
|
|
|
86
86
|
element.addEventListener("click", () => {
|
|
87
87
|
const styles = window.getComputedStyle(targetElement);
|
|
88
88
|
if (styles.opacity === "1") {
|
|
89
|
-
|
|
89
|
+
blur(index);
|
|
90
90
|
return;
|
|
91
91
|
}
|
|
92
92
|
open(target, index);
|
|
@@ -149,15 +149,12 @@ const TargetProviderContainer = ({ children }) => {
|
|
|
149
149
|
Container,
|
|
150
150
|
{
|
|
151
151
|
ref: (element) => containerRef.current[index] = element,
|
|
152
|
+
onMouseLeave: () => insideMemory.splice(_.findIndex(insideMemory, (i) => i === index), 1),
|
|
152
153
|
onMouseEnter: () => {
|
|
153
154
|
elementFocusable(target, index).focus();
|
|
154
155
|
if (_.some(insideMemory, (i) => i === index)) return;
|
|
155
156
|
insideMemory.push(index);
|
|
156
157
|
},
|
|
157
|
-
onMouseLeave: () => {
|
|
158
|
-
insideMemory.splice(_.findIndex(insideMemory, (i) => i === index), 1);
|
|
159
|
-
},
|
|
160
|
-
onClick: () => elementFocusable(target, index).focus(),
|
|
161
158
|
children: target.component
|
|
162
159
|
}
|
|
163
160
|
),
|