Interactive interface for browsing global, full-resolution satellite imagery
bypass `react/no-array-index-key` errors so we can enable
Jason Kent71fc5d094edc
diff --git a/.eslintrc b/.eslintrcindex 72c70ceb2..aabda97be 100644--- a/.eslintrc+++ b/.eslintrc@@ -127,8 +127,7 @@"react/no-unused-prop-types": "warn", // 66 errors"react/forbid-prop-types": "off", // 216 errors"react/require-default-props": "off", // 965 errors- "react/destructuring-assignment": "warn", // 464 errors- "react/no-array-index-key": "warn"+ "react/destructuring-assignment": "warn" // 464 errors}}]diff --git a/web/js/components/layer/product-picker/category-cell.js b/web/js/components/layer/product-picker/category-cell.jsindex 0c68215a0..42c1048d7 100644--- a/web/js/components/layer/product-picker/category-cell.js+++ b/web/js/components/layer/product-picker/category-cell.js@@ -70,6 +70,7 @@ class CategoryCell extends React.Component {return index === 6 ? (<liclassName="layer-category-item"+ /* eslint react/no-array-index-key: 1 */key={category.id + index}><adiff --git a/web/js/components/layer/settings/vector-style.js b/web/js/components/layer/settings/vector-style.jsindex 28613cb29..121356e72 100644--- a/web/js/components/layer/settings/vector-style.js+++ b/web/js/components/layer/settings/vector-style.js@@ -84,6 +84,7 @@ class VectorStyleSelect extends React.Component {}}return organizedArray.map((obj, i) => (+ /* eslint react/no-array-index-key: 1 */<div key={vectorStyleId + i} className={caseDefaultClassName}><label><spandiff --git a/web/js/components/notifications/notification-block.js b/web/js/components/notifications/notification-block.jsindex 4e2add5cf..12c5c9cb3 100644--- a/web/js/components/notifications/notification-block.js+++ b/web/js/components/notifications/notification-block.js@@ -30,6 +30,7 @@ class NotificationBlock extends React.Component {dateObject.getFullYear()}`;const activeClass = numberNotSeen > i ? `${type}-notification-item` : '';return (+ /* eslint react/no-array-index-key: 1 */<li key={type + i} className={activeClass}><h2><FontAwesomeIcon icon={listIcons[type]} />diff --git a/web/js/components/sidebar/product.js b/web/js/components/sidebar/product.jsindex 58b7da779..930b17088 100644--- a/web/js/components/sidebar/product.js+++ b/web/js/components/sidebar/product.js@@ -67,6 +67,7 @@ class Data extends React.Component {<ul className="wv-datacategory" id={`wv-data${id}`}>{productObject.items.map((layer, index) => (<li+ /* eslint react/no-array-index-key: 1 */key={layer + index}id={`${listId}-${id}${util.encodeId(layer.value)}`}className="item item-static"diff --git a/web/js/components/timeline/timeline-axis/grid-range/grid-range.js b/web/js/components/timeline/timeline-axis/grid-range/grid-range.jsindex 340bb920e..e4c11f2a7 100644--- a/web/js/components/timeline/timeline-axis/grid-range/grid-range.js+++ b/web/js/components/timeline/timeline-axis/grid-range/grid-range.js@@ -53,6 +53,7 @@ class GridRange extends PureComponent {{timeRange.map((item, index) => (item.withinRange? (+ /* eslint react/no-array-index-key: 1 */<React.Fragment key={index}><TileRectitem={item}diff --git a/web/js/components/tooltip/tooltip.js b/web/js/components/tooltip/tooltip.jsindex cc0f94cbb..57a70de11 100644--- a/web/js/components/tooltip/tooltip.js+++ b/web/js/components/tooltip/tooltip.js@@ -1,3 +1,4 @@+import React from 'react';import PropTypes from 'prop-types';@@ -40,6 +41,7 @@ class Tooltip extends React.Component {<ul>{this.props.dataArray.map((dataEl, i) => (<li+ /* eslint react/no-array-index-key: 1 */key={`tooltip-${dataEl}-${i}`}id={dataEl}onClick={this.onClick.bind(this, dataEl)}diff --git a/web/js/components/tour/modal-tour-complete.js b/web/js/components/tour/modal-tour-complete.jsindex be3c0ac25..6563e33a2 100644--- a/web/js/components/tour/modal-tour-complete.js+++ b/web/js/components/tour/modal-tour-complete.js@@ -20,6 +20,7 @@ class ModalComplete extends React.Component {<p>Read more about this story at the links below:</p><ul>{readMoreLinks.map((linkId, i) => (+ /* eslint react/no-array-index-key: 1 */<li key={i} index={i}><a href={linkId.link} target="_blank" rel="noopener noreferrer">{linkId.title}diff --git a/web/js/components/tour/tour-boxes.js b/web/js/components/tour/tour-boxes.jsindex 6c9e6b8c6..bb1e82945 100644--- a/web/js/components/tour/tour-boxes.js+++ b/web/js/components/tour/tour-boxes.js@@ -1,3 +1,4 @@+import React from 'react';import PropTypes from 'prop-types';import TourBox from './tour-box';@@ -10,6 +11,7 @@ class TourBoxes extends React.Component {<div className="tour-box-row">{storyOrder.map((storyId, i) => {const story = stories[storyId];+ /* eslint react/no-array-index-key: 1 */return (<TourBox key={i} index={i} story={story} storyId={story.id} storyOrder={storyOrder} title={story.title} description={story.description} backgroundImage={story.backgroundImage} backgroundImageHover={story.backgroundImageHover} selectTour={selectTour} className={`tour-box ${story.type}`} />);})}</div>diff --git a/web/js/components/util/selector.js b/web/js/components/util/selector.jsindex 6f4db0e77..625e0c70a 100644--- a/web/js/components/util/selector.js+++ b/web/js/components/util/selector.js@@ -27,6 +27,7 @@ export default class Selector extends React.Component {onChange={this.handleChange.bind(this)}>{this.props.optionArray.values.map((dataEl, i) => (+ /* eslint react/no-array-index-key: 1 */<option key={`${dataEl.value}-${i}`} value={dataEl.value}>{dataEl.text}</option>