forstok-ui-lib 5.2.21 → 5.2.24

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.2.21",
3
+ "version": "5.2.24",
4
4
  "description": "Forstok UI Components Library",
5
5
  "path": "dist",
6
6
  "main": "dist/index.js",
@@ -194,7 +194,7 @@ export const InfoGroup = styled.div`
194
194
  width: 100%;
195
195
  justify-content: left;
196
196
  margin-bottom: 14px;
197
- span:first-child {
197
+ > span:first-child {
198
198
  position: relative;
199
199
  &:after {
200
200
  position: absolute;
@@ -28,7 +28,7 @@ const DropDownComponent = ({ children, title, subTitle, $externalWidth, $externa
28
28
  }
29
29
  }
30
30
  const refScrollContainerEl = document.querySelector('._refScrollContainer') as HTMLElement;
31
- refScrollContainerEl.removeEventListener('scroll', evScrollDropdown, true);
31
+ refScrollContainerEl && refScrollContainerEl.removeEventListener('scroll', evScrollDropdown, true);
32
32
  setTimeout(() => {
33
33
  if (portalId) {
34
34
  const portalContainerRef = document.getElementsByClassName('_refDropdownPortal is-shown') as HTMLCollectionOf<HTMLElement>;
@@ -71,7 +71,7 @@ const DropDownComponent = ({ children, title, subTitle, $externalWidth, $externa
71
71
  portalContainerRef.style.left = offsetPos.left + offsetPos.width - wrapperRef.getBoundingClientRect().width + 'px';
72
72
  portalContainerRef.style.top = offsetPos.top + parseInt($top || '0') - 32 + 'px';
73
73
  portalContainerRef.style.zIndex = '8';
74
- refScrollContainerEl.addEventListener('scroll', evScrollDropdown, true);
74
+ refScrollContainerEl && refScrollContainerEl.addEventListener('scroll', evScrollDropdown, true);
75
75
  }, 10);
76
76
  } else {
77
77
  portalContainerRef.style.left = offsetPos.left + ((parseInt($internalWidth || '0') + offsetPos.width) / 2) + 'px';
@@ -95,7 +95,7 @@ const DropDownComponent = ({ children, title, subTitle, $externalWidth, $externa
95
95
  portalContainerRef.style.left = '0px';
96
96
  portalContainerRef.style.top = '0px';
97
97
  if (wrapperRef) {
98
- refScrollContainerEl.removeEventListener('scroll', evScrollDropdown, true);
98
+ refScrollContainerEl && refScrollContainerEl.removeEventListener('scroll', evScrollDropdown, true);
99
99
  }
100
100
  }
101
101
  }
@@ -70,7 +70,7 @@ const getDropDownContainerModifiedStyled = ({ $top, $bottom, $placement, $alias,
70
70
  @media only screen and (min-width: 768px) {
71
71
  & ${DropDownWrapper} {
72
72
  display: grid;
73
- ${$placement === 'top' ? `animation: dropgodown .075s linear; bottom: ${$bottom || '35px'};` : `animation: droptodown .075s linear; top: ${$top || '35px'};`}
73
+ ${$placement === 'top' ? `animation: dropgodown .075s linear; bottom: ${$bottom || '35px'}; top: auto;` : `animation: droptodown .075s linear; top: ${$top || '35px'};`}
74
74
  left: ${($alias === "_dropdownFilterContainer" && $openPosition !== 'left') ? '100%': $openPosition === 'left' ? '0' : 'auto'};
75
75
  }
76
76
  }