Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
44 changes: 44 additions & 0 deletions time-zone-map-app/debug.log
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
[0826/211440.521:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/211440.522:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/211440.522:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/211440.522:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/211440.522:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/211440.522:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/211440.522:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/211440.522:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/211440.522:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/211440.522:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/211440.523:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/211556.607:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/211556.608:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/211556.608:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/211556.608:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/211556.608:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/211556.608:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/211556.608:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/211556.608:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/211556.608:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/211556.608:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/211556.608:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/232252.596:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/232252.597:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/232252.597:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/232252.597:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/232252.597:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/232252.597:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/232252.597:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/232252.597:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/232252.597:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/232252.597:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/232252.597:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/232723.223:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/232723.223:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/232723.223:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/232723.223:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/232723.223:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/232723.223:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/232723.223:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/232723.223:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/232723.223:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/232723.223:ERROR:crash_report_database_win.cc(469)] failed to stat report
[0826/232723.223:ERROR:crash_report_database_win.cc(469)] failed to stat report
33 changes: 30 additions & 3 deletions time-zone-map-app/src/App.css
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,18 @@
width: 100%;
height: var(--header-height);
line-height: var(--header-height);
font-size: 3.25vh;
}

.Header div{
min-width: 25vw;
}


select {
width: 300px;
min-width: 25vw;
max-width: 35vw;
font-size: 2vh;
}

.App-link {
Expand Down Expand Up @@ -53,14 +61,33 @@ select {
.map-frame {
width: 100%;
height: 100%;
flex-basis: 75%;
flex-grow: 10;
padding-top: var(--header-height);
}
.mapSVG {
width: 100%;
height: 100vh;
}

.sidebar {
width: 300px;
flex: auto;
background: gray;
height: 100vh;
padding-top: var(--header-height);
padding-left: 2vh;
padding-right:5px;
max-width: 15%;
font-size: 2vh;
}

@media screen and (min-width: 1440px) {
.sidebar {
max-width: 10%;
font-size: 30px;
}
.header {
font-size: 30px;
}
}

h3 {
Expand Down
4 changes: 2 additions & 2 deletions time-zone-map-app/src/App.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import tz_markers from "./data/locations.json"
import tz_count from "./data/timezone_count.json"
import team_zones from "./data/team_timezones.json"

let currentTeam = "Programmer Team";
let currentTeam = "All";
function updateFilter(value) {
currentTeam = value;
console.log(currentTeam);
Expand Down Expand Up @@ -45,7 +45,7 @@ function parse_markers(mrkrs){
for(let i = 0; i < marks.length; i++){
nMarkers.push({coordinates: [marks[i][1].long,marks[i][1].lat], name: marks[i][1].tz_name, markerOffset: marks[i][1].utc_offset});
}
console.log(nMarkers);

return nMarkers;
}
var newMarkers = parse_markers(tz_markers);
Expand Down
66 changes: 52 additions & 14 deletions time-zone-map-app/src/core/map/MapChart.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import { getTimezone } from 'countries-and-timezones';
import allStates from "../../data/allstates.json";
import topoJSON from "../../data/out_2.json"
// import topoJSON from "../../data/timezones-topo2.json"

import dropoptions from "../../data/dropdown_options.json";
import Color from "color"

import timezoneColors from "../../data/timezone_colors.json"
Expand Down Expand Up @@ -45,10 +45,15 @@ const rounded = num => {
let dotSize = 1;

const MapChart = ({ setTooltipContent, markers, team_stuff, current_team, markerScale = 1 }) => {





return (
<ComposableMap data-tip=""
projection="geoEqualEarth"
height={window.innerHeight / 2}
className="mapSVG"
projectionConfig={{
scale: 120,
center: [0, 0]
Expand Down Expand Up @@ -114,18 +119,51 @@ const MapChart = ({ setTooltipContent, markers, team_stuff, current_team, marker

{

markers.map(({ name, coordinates, markerOffset }) => (
<Marker key={name} coordinates={coordinates}>
<circle r={ team_stuff[current_team][name] * 2 } fill="#F00" stroke="#fff" strokeWidth={0.3} />
<text
textAnchor="middle"
y={2}
style={{ fontFamily: "system-ui", fill: "#5D5A6D", fontSize: "2px" }}
>
{name}
</text>
</Marker>
))}
markers.map(({ name, coordinates, markerOffset }) => {



let count = 0;
if(current_team === "All"){
for(let i = 1; i < dropoptions.length; i++){

if(typeof team_stuff[dropoptions[i].text][name] !== 'undefined'){
count += team_stuff[dropoptions[i].text][name];
}
}
} else {
if(typeof team_stuff[current_team][name] !== 'undefined'){
count = team_stuff[current_team][name];
}
}





return (
<Marker key={name} coordinates={coordinates}>
<circle r={ count * 2 } fill="#F00" stroke="#fff" strokeWidth={0.3} />
<text
textAnchor="middle"
y={2}
style={{ fontFamily: "system-ui", fill: "#5D5A6D", fontSize: "2px" }}>
{name}
</text>
</Marker>
)


}



)
}




</ZoomableGroup>
</ComposableMap>
);
Expand Down
6 changes: 5 additions & 1 deletion time-zone-map-app/src/data/dropdown_options.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
[
{
"value": "all",
"text": "All"
},
{
"value": "Programmer Team",
"text": "Programmer Team"
Expand Down Expand Up @@ -39,4 +43,4 @@
"value": "Testing Team",
"text": "Testing Team"
}
]
]