mirror of
https://github.com/bellingcat/ukraine-timemap.git
synced 2026-06-13 05:48:36 +03:00
Fixed linting issues
This commit is contained in:
@@ -1,2 +1,2 @@
|
|||||||
export const FILTER_MODE = 'FILTER'
|
export const FILTER_MODE = 'FILTER'
|
||||||
export const NARRATIVE_MODE = 'NARRATIVE'
|
export const NARRATIVE_MODE = 'NARRATIVE'
|
||||||
|
|||||||
@@ -139,7 +139,7 @@ class Dashboard extends React.Component {
|
|||||||
activeFilters = activeFilters.map(f => ({ name: f }))
|
activeFilters = activeFilters.map(f => ({ name: f }))
|
||||||
|
|
||||||
const evs = domain.events.filter(ev => {
|
const evs = domain.events.filter(ev => {
|
||||||
let hasOne = false
|
let hasOne = false
|
||||||
// add event if it has at least one matching filter
|
// add event if it has at least one matching filter
|
||||||
for (let i = 0; i < activeFilters.length; i++) {
|
for (let i = 0; i < activeFilters.length; i++) {
|
||||||
if (ev.associations.includes(activeFilters[i].name)) {
|
if (ev.associations.includes(activeFilters[i].name)) {
|
||||||
|
|||||||
@@ -126,7 +126,7 @@ function toggleFilter (appState, action) {
|
|||||||
...appState,
|
...appState,
|
||||||
associations: {
|
associations: {
|
||||||
...appState.associations,
|
...appState.associations,
|
||||||
filters: newFilters,
|
filters: newFilters
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ import associationsSchema from './associationsSchema'
|
|||||||
import sourceSchema from './sourceSchema'
|
import sourceSchema from './sourceSchema'
|
||||||
import shapeSchema from './shapeSchema'
|
import shapeSchema from './shapeSchema'
|
||||||
|
|
||||||
import { calcDatetime, capitalize, isFilterLeaf, isFilterDuplicate } from '../../common/utilities'
|
import { calcDatetime, capitalize } from '../../common/utilities'
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Create an error notification object
|
* Create an error notification object
|
||||||
|
|||||||
@@ -86,7 +86,7 @@ export const selectNarratives = createSelector(
|
|||||||
events.forEach(evt => {
|
events.forEach(evt => {
|
||||||
evt.associations.forEach(association => {
|
evt.associations.forEach(association => {
|
||||||
const foundNarrative = narrativesMeta.find(narr => narr.id === association)
|
const foundNarrative = narrativesMeta.find(narr => narr.id === association)
|
||||||
if (!!foundNarrative) {
|
if (foundNarrative) {
|
||||||
const { id: narrId } = foundNarrative
|
const { id: narrId } = foundNarrative
|
||||||
// initialise
|
// initialise
|
||||||
if (!narratives[narrId]) { narratives[narrId] = narrativeSkeleton(narrId) }
|
if (!narratives[narrId]) { narratives[narrId] = narrativeSkeleton(narrId) }
|
||||||
@@ -104,7 +104,7 @@ export const selectNarratives = createSelector(
|
|||||||
|
|
||||||
const existingAssociatedNarrative = narrativesMeta.find(n => n.id === key)
|
const existingAssociatedNarrative = narrativesMeta.find(n => n.id === key)
|
||||||
|
|
||||||
if (!!existingAssociatedNarrative) {
|
if (existingAssociatedNarrative) {
|
||||||
narratives[key] = {
|
narratives[key] = {
|
||||||
...existingAssociatedNarrative,
|
...existingAssociatedNarrative,
|
||||||
...narratives[key]
|
...narratives[key]
|
||||||
|
|||||||
Reference in New Issue
Block a user