Interactive interface for browsing global, full-resolution satellite imagery
revise custom selector to add static custom text that toggles dialog, fix height bug preventing mouseover, minor style fixes
Edward Platoc7b07c4f73e2
diff --git a/web/css/timeline.css b/web/css/timeline.cssindex 9227199e3..8f98684a8 100644--- a/web/css/timeline.css+++ b/web/css/timeline.css@@ -462,7 +462,7 @@ g.plot rect.data-bar-invisible {/* display: none; */position: absolute;bottom: 100%;- border-bottom: 8px solid transparent;+ /* border-bottom: 8px solid transparent; */z-index: 10;}diff --git a/web/js/components/timeline/interval-selector/interval-selector.js b/web/js/components/timeline/interval-selector/interval-selector.jsindex 9b205bf1c..6fba225cb 100644--- a/web/js/components/timeline/interval-selector/interval-selector.js+++ b/web/js/components/timeline/interval-selector/interval-selector.js@@ -86,7 +86,7 @@ class CustomIntervalSelectorWidget extends PureComponent {><div>Custom Interval Selector</div>- <div style={{ display: 'flex', flexDirection: 'row', justifyContent: 'space-between' }}>+ <div style={{ display: 'flex', flexDirection: 'row', justifyContent: 'space-between', height: '25px' }}><div style={{display: 'flex', flexDirection: 'row' }}><IntervalInputintervalValue={Number(this.state.intervalValue)}diff --git a/web/js/components/timeline/timeline-controls/interval-timescale-change.js b/web/js/components/timeline/timeline-controls/interval-timescale-change.jsindex b9c72fef2..7efdf46ad 100644--- a/web/js/components/timeline/timeline-controls/interval-timescale-change.js+++ b/web/js/components/timeline/timeline-controls/interval-timescale-change.js@@ -17,12 +17,12 @@ class TimeScaleIntervalChange extends Component {})}- handleClickZoom = (intervalSelected) => {+ handleClickZoom = (intervalSelected, openDialog) => {// close tooltip// send props function to change timescale zoom level throughout appthis.setState({toolTipHovered: false,- }, this.props.setTimeScaleIntervalChangeUnit(intervalSelected, intervalSelected === 'custom'));+ }, this.props.setTimeScaleIntervalChangeUnit(intervalSelected, intervalSelected === 'custom', openDialog));}// set custom text for custom interval@@ -106,10 +106,18 @@ class TimeScaleIntervalChange extends Component {<spanid="zoom-custom"className="zoom-btn zoom-btn-inactive zoom-custom custom-interval-text"+ style={{ display: this.state.customIntervalText === 'Custom' ? 'none' : 'block' }}onClick={() => this.handleClickZoom('custom')}>{this.state.customIntervalText}</span>+ <span+ id="zoom-custom-static"+ className="zoom-btn zoom-btn-inactive zoom-custom custom-interval-text"+ onClick={() => this.handleClickZoom('custom', true)}+ >+ Custom+ </span></div></div></div>diff --git a/web/js/components/timeline/timeline.css b/web/js/components/timeline/timeline.cssindex 69ec52f58..db8d3483c 100644--- a/web/js/components/timeline/timeline.css+++ b/web/js/components/timeline/timeline.css@@ -102,7 +102,7 @@ line {form button, form input, form select {border: none;- outline: 1px solid black;+ outline: thin solid black;width: 96px;text-align: center;}@@ -162,7 +162,7 @@ form select {height: 24px;color: #7890cd;opacity: 1;- font-size: 18px;+ font-size: 16px;background: transparent;border: 0;font-family: 'Roboto Mono', monospace;@@ -182,7 +182,7 @@ form select {height: 40px;color: #7890cd;opacity: 1;- font-size: 18px;+ font-size: 16px;background: transparent;border: 0;font-family: 'Roboto Mono', monospace;@@ -197,10 +197,11 @@ form select {.interval-timescale-select select {padding: 0;- background: #212121;+ /* background: #212121; */+ background: transparent;color: #7890cd;height: 24px;- font-size: 18px;+ font-size: 16px;width: 118px;border: thin solid #fff;/* margin-top: 1px; */@@ -273,13 +274,14 @@ form select {width: 225px;border-top-left-radius: 8px;border-top-right-radius: 8px;- background: #212121;+ /* background: #212121; */+ background: rgba(40, 40, 40, 0.85);position: absolute;top: -58px;left: 0;display: none;color: #fff;- border-bottom: 1px solid #444;+ border-bottom: thin solid #444;}.wv-animation-widget-custom-interval i.wv-close {diff --git a/web/js/components/timeline/timeline.js b/web/js/components/timeline/timeline.jsindex f703305b1..95019df31 100644--- a/web/js/components/timeline/timeline.js+++ b/web/js/components/timeline/timeline.js@@ -74,7 +74,7 @@ class Timeline extends React.Component {}// handle SELECT of LEFT/RIGHT interval selection- setTimeScaleIntervalChangeUnit = (intervalSelected, customSelected) => {+ setTimeScaleIntervalChangeUnit = (intervalSelected, customSelected, openDialog) => {let intervalChangeAmt;if (intervalSelected === 'custom') {intervalSelected = this.state.customIntervalZoomLevel;@@ -82,7 +82,7 @@ class Timeline extends React.Component {} else {intervalChangeAmt = 1;}- this.props.setSelectedInterval(intervalSelected, intervalChangeAmt, customSelected);+ this.props.setSelectedInterval(intervalSelected, intervalChangeAmt, customSelected, openDialog);}// left/right arrows increment datediff --git a/web/js/date/timeline.js b/web/js/date/timeline.jsindex f7bf55a05..56ae56359 100644--- a/web/js/date/timeline.js+++ b/web/js/date/timeline.js@@ -389,13 +389,13 @@ export function timeline(models, config, ui) {};// set selected interval either custom or standard delta of 1- var setSelectedInterval = (interval, intervalChangeAmt, customSelected) => {+ var setSelectedInterval = (interval, intervalChangeAmt, customSelected, openDialog) => {models.date.setSelectedInterval(timeScaleToNumberKey[interval], customSelected);self.reactComponent.setState({timeScaleChangeUnit: interval,customSelected: customSelected,intervalChangeAmt: intervalChangeAmt,- customIntervalModalOpen: customSelected+ customIntervalModalOpen: openDialog});};