-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Add separate components for each step of alert list - Update GO UI version - Update map color shading to reflect number of alerts - Add column sizes in table view - Improve alert details for map sidebar
- Loading branch information
1 parent
758d444
commit 7dac84e
Showing
31 changed files
with
1,091 additions
and
830 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
.alerts-table { | ||
.event { | ||
width: 0%; | ||
min-width: 8rem; | ||
} | ||
|
||
.category { | ||
width: 0%; | ||
min-width: 5rem; | ||
} | ||
|
||
.region { | ||
width: 0%; | ||
min-width: 5rem; | ||
} | ||
|
||
.country { | ||
width: 0%; | ||
min-width: 6rem; | ||
} | ||
|
||
.admins { | ||
min-width: 14rem; | ||
} | ||
|
||
.actions, | ||
.sent { | ||
width: 7%; | ||
min-width: 7rem; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,67 @@ | ||
import { createContext } from 'react'; | ||
|
||
type Id = string; | ||
// type SetStateFn<T> = React.Dispatch<React.SetStateAction<T | undefined>>; | ||
type SetStateFn<T> = (newValue: T | undefined) => void; | ||
|
||
export interface AlertContextProps { | ||
bbox: unknown; | ||
setBbox: SetStateFn<unknown>; | ||
activeCountryName: string | undefined; | ||
|
||
activeCountryId: Id | undefined; | ||
activeAdmin1Id: Id | undefined; | ||
activeAlertId: Id | undefined; | ||
|
||
activeGoCountryId: Id | undefined; | ||
activeGoAdmin1Id: Id | undefined; | ||
|
||
setActiveCountryId: SetStateFn<Id>; | ||
setActiveAdmin1Id: SetStateFn<Id>; | ||
|
||
setActiveGoCountryId: SetStateFn<Id>; | ||
setActiveGoAdmin1Id: SetStateFn<Id>; | ||
|
||
setActiveAlertId: SetStateFn<Id>; | ||
setActiveCountryName: SetStateFn<string>; | ||
} | ||
|
||
const AlertContext = createContext<AlertContextProps>({ | ||
bbox: undefined, | ||
activeCountryId: undefined, | ||
activeGoCountryId: undefined, | ||
activeCountryName: undefined, | ||
activeAdmin1Id: undefined, | ||
activeGoAdmin1Id: undefined, | ||
activeAlertId: undefined, | ||
setBbox: () => { | ||
// eslint-disable-next-line no-console | ||
console.warn('AlertContext::setBbox called without provider'); | ||
}, | ||
setActiveAdmin1Id: () => { | ||
// eslint-disable-next-line no-console | ||
console.warn('AlertContext::setActiveAlertId called without provider'); | ||
}, | ||
setActiveGoAdmin1Id: () => { | ||
// eslint-disable-next-line no-console | ||
console.warn('AlertContext::setActiveGoAlertId called without provider'); | ||
}, | ||
setActiveGoCountryId: () => { | ||
// eslint-disable-next-line no-console | ||
console.warn('AlertContext::setActiveGoCountryId called without provider'); | ||
}, | ||
setActiveCountryId: () => { | ||
// eslint-disable-next-line no-console | ||
console.warn('AlertContext::setActiveCountryId called without provider'); | ||
}, | ||
setActiveAlertId: () => { | ||
// eslint-disable-next-line no-console | ||
console.warn('AlertContext::setActiveAlertId called without provider'); | ||
}, | ||
setActiveCountryName: () => { | ||
// eslint-disable-next-line no-console | ||
console.warn('AlertContext::setActiveCountryName called without provider'); | ||
}, | ||
}); | ||
|
||
export default AlertContext; |
Oops, something went wrong.