data-for-change / anyway-newsflash-infographics Goto Github PK
View Code? Open in Web Editor NEWDevelopment branch deployed automatically to website:
Home Page: https://anyway-infographics-staging.web.app/
License: MIT License
Development branch deployed automatically to website:
Home Page: https://anyway-infographics-staging.web.app/
License: MIT License
WidgetType
would work better as an enum with textual values.
Update Text.stories.tsx
so it will contain all Text options
Create a Link Atom component
Guidlines
styles/_globals.ts
Improve README.md
add link to Diving in section:
Report for any other missing links in README.md
At the moment SelectButton is hard coded and needs to be connected to API, MobX
Needs to be a reusable component for other types of filters
Is your feature request related to a problem? Please describe.
Each newsflash should have its own URL that could be linked to, sent, bookmarked...
Describe the solution you'd like
Our main page should have a path with a variable (/:id) that represents the newsflash.
When the page loads or the path changes, the page will launch a request to fetch the relevant newsflash's data, then display it.
This will replace the current behavior of loading the data in an onClick callback.
Additional context
This should work with the implementation for issue #71.
change the tile layer for the location and heat maps to google maps
Currently most_severe_accidents
is not displayed.
This widget should show:
LocationMap
component)Add a widget that receives an array of data of the format:
{
"accident_year": 2010,
"count": 39
}
and displays it on a bar chart.
Keep in mind: The Goal here is to help new contributors to understand the project and it needs. It should provide a good replacement to AnyWay introduction talk in case a project leader is not around to give one.
side bar cover the footer
steps
Add a widget that receives an array of data in the format:
{
"accident_severity": "קלה",
"count": 197
}
And shows it on a pie charts/
See notes from #92
// TODO: Move to init.service once it's merged.
L.Icon.Default.mergeOptions({
iconRetinaUrl: require('leaflet/dist/images/marker-icon-2x.png'),
iconUrl: require('leaflet/dist/images/marker-icon.png'),
shadowUrl: require('leaflet/dist/images/marker-shadow.png')
})
Change scroll design on widget area to look more aesthetic.
We would like to support different themes in the future.
For that, we will support basic theme as following
theme
observable to RootStore
. it should be of enum type with the following values: DEFAULT, YNETtheme
value is DEFAULT - app will have the current appearance.theme
value is YNET - The application bar will have red background.Example:
// atoms/index.ts
export {default as Button} from './AnyWayCard';
export {default as Text} from './Text';
export {default as AnyWayCard} from './AnyWayCard';
export {default as AnyWayGrid} from './AnyWayGrid';
Example:
// HomePage.ts - before:
import AnyWayCard from '../components/atoms/AnyWayCard';
import AnyWayGrid from '../components/atoms/AnyWayGrid'
// HomePage.ts - after:
import {AnyWayCard, AnyWayGrid} from '../components/atoms'
connect the news flash collection to fetch from the API established in https://anyway.co.il/api/
Is your feature request related to a problem? Please describe.
Make sure that map widgets show all of the data initially.
Add a widget that receives an array of data in the format:
{
"longitude": 34.9780568296871,
"latitude": 32.4543458814189,
"accident_severity": "קשה",
"accident_timestamp": "2016-05-15 21:00:00"
}
And shows it on a map.
There's a location widget component that you can use for this, but it might need modification to work with multiple locations.
add footer
click on Hasadna logo should go to hasadna home page
Use Anyway site as a reference. no need to add facebook / twitter buttons / icons
Describe the solution you'd like
We should have a Thanks page that displays some content.
Ask @atalyaalon about it. If no content is available yet. a boilerplate is a good start.
When clicking on "תודות" in the footer, the link should navigate to this page.
Describe the solution you'd like
We should have an about page that displays some content.
Ask @atalyaalon about it. If no content is available yet. a boilerplate is a good start.
When clicking on "אודות" in the footer, the link should navigate to this page.
Each newsflash should have its own URL. Newsflash items on the sidebar should navigate to these URLs instead of running an onClick event.
This will work once we have a component and a path that could detect the identifier in the URL and use it.
we now use the method for Initialization , and for update after getting data from data.service
Changing design of sidebar to include location map and scroll option for the news feed using Material UI components
connect news component to store
Here is an example:
const News: React.FC = () => {
const store = useStore();
return useObserver(() => (
<div> num of news flash items: {store.newsFlashCollection.length}</div>
)
}
for more info see:
https://github.com/mobxjs/mobx-react-lite
Solve Compilation Warning:
./src/components/templates/News.tsx
Line 13:6: React Hook useCallback has a missing dependency: 'store'. Either include it or remove the dependency array react-hooks/exhaustive-deps
Task: add store to useCallback
as a dependency
const onNewsClick = useCallback((id: number) => {
store.selectNewsFlash(id)
}, [store]);
Add a widget that receives an array of data of the format:
{
"accident_year": 2010,
"count": 39
}
and displays it on a pie chart.
in SideBar LocationMap ,
a tile don't load on first render :
<Box flexBasis={300} flexShrink={0} p={1}>
<LocationMap data={[{latitude: 32.0853, longitude: 34.7818}]} center={{lat: 32.0853, lng: 34.7818}}/>
</Box>
1 - can fix it with change in css of container (copied form AnyWayCard)
const cardStyles: object = {
padding: '10px',
margin: '10px',
width: '300px',
height: '350px',
display: 'flex',
justifyContent: 'space-evenly',
flexDirection: 'column'
}
...
<Box style={cardStyles}>
<LocationMap data={[{latitude: 32.0853, longitude: 34.7818}]} center={{lat: 32.0853, lng: 34.7818}}/>
</Box>
2- need to adjust the css.
3- in case of resize - maybe need to use
mapRef.current.leafletElement.invalidateSize(false);
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.