forstok-ui-lib 5.8.7 → 5.8.8

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "forstok-ui-lib",
3
- "version": "5.8.7",
3
+ "version": "5.8.8",
4
4
  "description": "Forstok UI Components Library",
5
5
  "path": "dist",
6
6
  "main": "dist/index.js",
@@ -51,12 +51,16 @@ const DropDownComponent = ({ children, title, subTitle, $externalWidth, $externa
51
51
  return;
52
52
  }
53
53
  const containerEl = buttonEl.closest('._refContainer') as HTMLElement;
54
+ const bodyEl = document.getElementsByTagName("BODY")[0] as HTMLBodyElement;
54
55
  if (containerEl) {
56
+ const overlayEl = containerEl.querySelector(`._refDropdownOverlay`) as HTMLDivElement;
55
57
  const isCurOpen = containerEl.classList.contains('is-shown');
56
58
  const offsetPos = containerEl.getBoundingClientRect();
57
59
 
58
60
  if (!isCurOpen) {
59
61
  evResetDropdown();
62
+ overlayEl.style.display = 'block';
63
+ bodyEl.classList.add("is-immuned")
60
64
  containerEl.classList.add('is-shown');
61
65
  setTimeout(() => {
62
66
  if (portalId) {
@@ -84,6 +88,8 @@ const DropDownComponent = ({ children, title, subTitle, $externalWidth, $externa
84
88
  }, 10);
85
89
  onClick && onClick(e);
86
90
  } else {
91
+ overlayEl.style.display = 'none';
92
+ bodyEl.classList.remove("is-immuned");
87
93
  containerEl.classList.remove('is-shown');
88
94
  setTimeout(() => {
89
95
  if (portalId) {