Interactive interface for browsing global, full-resolution satellite imagery
add background position change
Ed Plato257220b29d00
diff --git a/web/css/timeline.css b/web/css/timeline.cssindex ffe391106..602460ae0 100644--- a/web/css/timeline.css+++ b/web/css/timeline.css@@ -860,13 +860,6 @@ button:focus {height: 12px;}-.data-panel-coverage-line-overlay {- position: absolute;- pointer-events: none;- height: 12px;- z-index: 5;-}-.data-panel-layer-empty {height: 41px;padding: 6px;diff --git a/web/js/components/timeline/timeline-data/layer-data-items.js b/web/js/components/timeline/timeline-data/layer-data-items.jsindex 14a01f44b..9e7df3b8d 100644--- a/web/js/components/timeline/timeline-data/layer-data-items.js+++ b/web/js/components/timeline/timeline-data/layer-data-items.js@@ -27,21 +27,9 @@ class LayerDataItems extends Component {constructor(props) {super(props);this.state = {- initPosition: '',};}- /**- * @desc setPropPosition set init position related to timeline axis- * @returns {void}- */- setPropPosition = () => {- const { position } = this.props;- this.setState({- initPosition: position,- });- }-/*** @desc get layer header with title, subtitle, and full date range* @param {Object} layer@@ -160,9 +148,6 @@ class LayerDataItems extends Component {position,transformX,} = this.props;- const {- initPosition,- } = this.state;const width = Math.max(options.width, 0);// get formatted dates based on line typeconst {@@ -175,11 +160,6 @@ class LayerDataItems extends Component {const toolTipOffset = -options.leftOffset - (width < axisWidth ? options.leftOffset : axisWidth / 2);const toolTipPlacement = 'auto';- // handle line overlay for wide lines- const needsLineOverlay = options.leftOffset === 0 && options.width >= axisWidth * 2;- const overlayWidth = width * 10;- const overlayTransform = -overlayWidth / 2 + initPosition + position + transformX;-// candy stripe colorconst altLineColor = color === 'rgb(0, 69, 123)'? '#164e7a'@@ -189,23 +169,13 @@ class LayerDataItems extends Component {${color} 20px,${altLineColor} 20px,${altLineColor} 40px)`;+ const bgPosition = `${options.leftOffset + width + position + transformX}px 0`;return (<divkey={index}className="data-panel-coverage-line-container">- { needsLineOverlay- && (- <div- className="data-panel-coverage-line-overlay"- style={{- width: `${width * 10}px`,- transform: `translate(${overlayTransform}px, 0)`,- background: stripeBackground,- }}- />- )}<divid={`data-coverage-line-${dateRangeStartEnd}`}className="data-panel-coverage-line"@@ -216,6 +186,7 @@ class LayerDataItems extends Component {width: `${width}px`,borderRadius: options.borderRadius,background: stripeBackground,+ backgroundPosition: width < axisWidth ? 0 : bgPosition,}}><Tooltip@@ -431,10 +402,6 @@ class LayerDataItems extends Component {};}- componentDidMount() {- this.setPropPosition();- }-render() {const {activeLayers,