Interactive interface for browsing global, full-resolution satellite imagery
add luxor blue line y height fix, return tooltip width fix lost in merge, add leading zero to num
Ed Plato001d6efd6514
diff --git a/web/js/components/timeline/timeline-axis/date-tooltip/axis-hover-line.js b/web/js/components/timeline/timeline-axis/date-tooltip/axis-hover-line.jsindex 802dca8b8..6dac2eb6f 100644--- a/web/js/components/timeline/timeline-axis/date-tooltip/axis-hover-line.js+++ b/web/js/components/timeline/timeline-axis/date-tooltip/axis-hover-line.js@@ -42,7 +42,7 @@ class AxisHoverLine extends PureComponent {const layerLengthCoef = Math.max(layers.length, 1);// handle active layer count dependent tooltip heightif (isDataCoveragePanelOpen) {- lineHeight = 111;+ lineHeight = 112;const addHeight = Math.min(layerLengthCoef, 5) * 40;lineHeight += addHeight;lineHeightInner = lineHeight;@@ -56,7 +56,7 @@ class AxisHoverLine extends PureComponent {linePosition = selectedDraggerPosition + 47;// lineheight for draggerconst minusY1Height = Math.min(layerLengthCoef, 5) * 40.5;- lineHeightInner = 40.5 + minusY1Height;+ lineHeightInner = 47 + minusY1Height;}return (diff --git a/web/js/components/timeline/timeline-axis/date-tooltip/date-tooltip.js b/web/js/components/timeline/timeline-axis/date-tooltip/date-tooltip.jsindex 4dcd1dfa0..9e96a92d9 100644--- a/web/js/components/timeline/timeline-axis/date-tooltip/date-tooltip.js+++ b/web/js/components/timeline/timeline-axis/date-tooltip/date-tooltip.js@@ -101,6 +101,19 @@ class DateToolTip extends PureComponent {toolTipHeightOffset -= addHeight;toolTipHeightOffset = Math.max(toolTipHeightOffset, -357);}++ // eslint-disable-next-line no-nested-ternary+ const toolTipWidth = hasSubdailyLayers+ ? toolTipDayOfYear >= 100+ ? '239px'+ : '232px'+ : '165px';++ // add leading zero for single digits+ toolTipDayOfYear = toolTipDayOfYear < 10+ ? `0${toolTipDayOfYear}`+ : toolTipDayOfYear;+return (shouldDisplayDraggerToolTip && (<div@@ -108,7 +121,7 @@ class DateToolTip extends PureComponent {style={{transform: `translate(${toolTipLeftOffset}px, ${toolTipHeightOffset}px)`,display: toolTipDisplay,- width: hasSubdailyLayers ? '232px' : '165px',+ width: toolTipWidth,}}>{ toolTipDate }