@trudb/tru-common-lib 0.0.521 → 0.0.523

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.
@@ -2549,6 +2549,14 @@ class TruMatSelectPanel {
2549
2549
  panelParentElement.style.width = 'auto';
2550
2550
  panelOverlayContainerElement.style.position = 'static';
2551
2551
  panelOverlayBackdropElement.style.display = 'none';
2552
+ let optionSpans = panelElement.querySelectorAll('span');
2553
+ let maxWidth = 0;
2554
+ optionSpans.forEach((optionSpan) => {
2555
+ let currentWidth = parseInt(optionSpan.width, 10);
2556
+ if (currentWidth > maxWidth)
2557
+ maxWidth = currentWidth;
2558
+ });
2559
+ panelParentElement.style.minWidth = (maxWidth + 60) + 'px';
2552
2560
  this.documentMouseUpEventFn = this.renderer.listen(document, 'mouseup', (event) => {
2553
2561
  if (event.target !== this.select.panel.nativeElement && event.button !== 2) {
2554
2562
  this.removeListeners();