Skip to content

Commit 7e11a77

Browse files
Merge pull request #229 from urbanriskmap/dev
Merge dev changes (removal of cards)
2 parents 1f99683 + 77f1a38 commit 7e11a77

File tree

152 files changed

+1984
-2433
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

152 files changed

+1984
-2433
lines changed

.gitignore

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,15 @@ node_modules/
33
.DS_STORE
44
npm-debug.log
55

6+
assets/graphics/
7+
assets/icons/
68
scripts/
79
dist/
810
coverage/
911
src/environment.js
12+
src/deployment.js
13+
src/components/side-pane/
14+
src/resources/locales/local_lang.js
1015

1116
#for vim:
1217
*.swp

.travis.yml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,11 @@ node_js:
33
- "6.10.0"
44
sudo: false
55

6-
addons:
7-
chrome: stable
8-
96
branches:
107
only:
118
- master
129
- dev
10+
- e2eCasper
1311

1412
notifications:
1513
webhooks:
@@ -19,9 +17,14 @@ notifications:
1917
on_failure: always # options: [always|never|change] default: always
2018
on_start: always # options: [always|never|change] default: always
2119

20+
before_script:
21+
- export DISPLAY=:99.0
22+
- sh -e /etc/init.d/xvfb start
23+
2224
before_install:
2325
- if [[ `npm -v` != 3* ]]; then npm i -g npm@3; fi
2426

2527
install:
2628
- npm install
2729
- npm install aurelia-cli -g
30+
- npm install casperjs -g

LICENSE

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -631,7 +631,7 @@ to attach them to the start of each source file to most effectively
631631
state the exclusion of warranty; and each file should have at least
632632
the "copyright" line and a pointer to where the full notice is found.
633633

634-
PetaBencana.id Crowd Sourced Flood Map
634+
UrbanRiskMap Crowd Sourced Flood Map
635635
Copyright (C) 2017 Urban Risk Lab at Massachusetts Institute of Technology
636636

637637
This program is free software: you can redistribute it and/or modify
@@ -652,7 +652,7 @@ Also add information on how to contact you by electronic and paper mail.
652652
If the program does terminal interaction, make it output a short
653653
notice like this when it starts in an interactive mode:
654654

655-
PetaBencana.id Copyright (C) 2017 Urban Risk Lab at Massachusetts Institute of Technology
655+
UrbanRiskMap Copyright (C) 2017 Urban Risk Lab at Massachusetts Institute of Technology
656656
Contributors Tomas Holderness, Etienne Turpin, Mayank Ojha, Aditya Shankar Barve,
657657
Maanasa Priyaa Dharmapuri Sridhar, Abraham Quintero, Miho Mazereeuw
658658

README.md

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@ This platform is built using the Aurelia framework, which has a few prerequisite
1010
DOI for current stable release [v1.0.0](https://github.com/urbanriskmap/petabencana.id/releases/tag/v1.0.0)
1111

1212
[![DOI](https://zenodo.org/badge/70249665.svg)](https://zenodo.org/badge/latestdoi/70249665)
13-
1413
____
1514

1615
### Machine setup
@@ -47,21 +46,20 @@ The project structure is as follows:
4746
___
4847

4948
### Card Decks
50-
- Currently contains single fixed card deck for disaster type - Flood.
51-
- The deck has location, flood depth, description, photo, and review cards along with error, terms of service, and thank you cards.
52-
- Addition of a new card involves updates in cards.js router mapping
49+
- Refer assets/card-decks/README.md
5350
___
5451

5552
### Routing
5653
* *App router is configured in /src/app.js*
5754
* '/' & '/map' *map landing page*
5855
* '/map/:city' *query parameter (city): flyTo supported city*
5956
* '/map/:city/:report' *query parameter (city & report): flyTo queried report id in a supported city*
60-
* '/cards/:id' *query parameter (one time card id): link to access report cards, (use test123 as card id in dev & local environments*
57+
* '/cards/:disaster/:id' *query parameter (disaster type & one time card id): Disaster type specifies which card-deck to load, card id is the link to access report cards, (use test123 as card id in dev & local environments*
6158

6259
* *Additional query parameters*
6360
* ?lang : Use for setting language to one of the supported languages (en || id).
6461
* ?tab : Use for opening the side pane set to one of the following tabs (report || map || info)
62+
* ?terms : Use for directly opening the privacy policy or user agreement popup (u_a || p_p)
6563
* eg. https://dev.petabencana.id/map?lang=en&tab=info
6664

6765
___

assets/README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
**Card decks**
2+
Store card deck jsons in assets, for them to be accessed off of the server.
3+
Having them in src/resources fails.
4+
15
**Folder structure and file types:**
26
assets/graphics/*
37
- Place vector graphics here, used as backgrounds to enhance UX.

assets/fonts/fontello/config.json

100755100644
Lines changed: 155 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -161,7 +161,7 @@
161161
},
162162
{
163163
"uid": "d1bf47cf34f10c5d8e691bbfef37f3bb",
164-
"css": "flood",
164+
"css": "flood-img",
165165
"code": 59402,
166166
"src": "custom_icons",
167167
"selected": true,
@@ -249,6 +249,160 @@
249249
"css": "android",
250250
"code": 61819,
251251
"src": "fontawesome"
252+
},
253+
{
254+
"uid": "f9fd25a7b65501c6187c4e49d04c65ba",
255+
"css": "map-drain",
256+
"code": 59417,
257+
"src": "custom_icons",
258+
"selected": true,
259+
"svg": {
260+
"path": "M500 181.3C676 181.3 819.3 324.7 819.3 500.7S676 820 500 820 180.7 676.7 180.7 500.7 324 181.3 500 181.3ZM766.7 499.3C766.7 488.7 766 478 764.7 468 742.7 468.7 733.3 478.7 733.3 478.7 709.3 497.3 688 494 657.3 473.3 640 462 612.7 464.7 592.7 478 566 496 551.3 491.3 523.3 475.3 502 462.7 482.7 462.7 461.3 475.3 432.7 491.3 419.3 496 392 478 372.7 465.3 344.7 461.3 327.3 473.3 296.7 494 275.3 497.3 252 478.7 252 478.7 246.7 474 236 470.7 235.3 480 234.7 489.3 234.7 499.3 234.7 646 354 765.3 500.7 765.3S766.7 646 766.7 499.3ZM500 11.3C770 11.3 988.7 230 988.7 500S770 988.7 500 988.7 11.3 770 11.3 500 230 11.3 500 11.3ZM886 500C886 287.3 712.7 114 500 114S114 287.3 114 500 287.3 886 500 886 886 713.3 886 500Z",
261+
"width": 1000
262+
},
263+
"search": [
264+
"drain"
265+
]
266+
},
267+
{
268+
"uid": "3657befd06c616a85df1686ada9acb5f",
269+
"css": "map-bg",
270+
"code": 59419,
271+
"src": "custom_icons",
272+
"selected": true,
273+
"svg": {
274+
"path": "M0 500C0 776 224 1000 500 1000 776 1000 1000 776 1000 500S776 0 500 0C224 0 0 224 0 500Z",
275+
"width": 1000
276+
},
277+
"search": [
278+
"circle"
279+
]
280+
},
281+
{
282+
"uid": "1563f1916ec07417163e82f03e472fee",
283+
"css": "drain",
284+
"code": 59421,
285+
"src": "custom_icons",
286+
"selected": true,
287+
"svg": {
288+
"path": "M248.7 497.3C272 516 293.3 512.7 324 492 341.3 480 369.3 484 388.7 496.7 416 514.7 429.3 510 458 494 479.3 481.3 498.7 481.3 520 494 548 510 562.7 514.7 589.3 496.7 609.3 483.3 636.7 480.7 654 492 684.7 512.7 706 516 730 497.3 730 497.3 739.3 487.3 761.3 486.7 762.7 496.7 763.3 507.3 763.3 518 763.3 664.7 644 784 497.3 784S231.3 664.7 231.3 518C231.3 508 232 498.7 232.7 489.3 243.3 492.7 248.7 497.3 248.7 497.3ZM496.7 904.7C284 904.7 110.7 731.3 110.7 518.7 110.7 306 284 132.7 496.7 132.7 709.3 132.7 882.7 306 882.7 518.7 882.7 732 709.3 904.7 496.7 904.7ZM496.7 200C320.7 200 177.3 343.3 177.3 519.3 177.3 695.3 320.7 838.7 496.7 838.7 672.7 838.7 816 695.3 816 519.3 816 343.3 672.7 200 496.7 200Z",
289+
"width": 1000
290+
},
291+
"search": [
292+
"drain"
293+
]
294+
},
295+
{
296+
"uid": "ca5b15b05ecae0a92db8758ed2d9189e",
297+
"css": "treeclearing",
298+
"code": 59415,
299+
"src": "custom_icons",
300+
"selected": true,
301+
"svg": {
302+
"path": "M451.3 556C463.3 580 479.3 610 489.3 608 499.3 606 503.3 586 505.3 566 501.3 566 497.3 566 493.3 566 479.3 566 463.3 562 451.3 556ZM421.3 584.7C447.3 602.7 457.3 598.7 457.3 598.7L439.3 560C435.3 568 429.3 576 421.3 584.7ZM529.3 560C523.3 586 509.3 632 531.3 626 541.3 624 553.3 614 567.3 604 553.3 590 545.3 574 543.3 554 540 556 533.3 558 529.3 560ZM730.7 556C724.7 604 684.7 640.7 636 640.7 618 640.7 600 634.7 584 624.7L539.3 666C536.7 668.7 534.7 672 534 676 532 688 527.3 716.7 527.3 735.3 527.3 736 527.3 736.7 527.3 738 530 761.3 554 824 554 824H441.3C449.3 792 471.3 798 470.7 724.7 481.3 689.3 458 629.3 458 629.3 446 631.3 420 615.3 402 603.3 388 609.3 373.3 613.3 357.3 613.3 305.3 612.7 264 568.7 264 516V512.7C242 494.7 228 468.7 228 438.7 228 406.7 244 378 268 361.3 269.3 358.7 271.3 355.3 272.7 352.7 271.3 299.3 314 256 367.3 256 372 252.7 376.7 249.3 381.3 246 391.3 206.7 429.3 178 472 178 508 178 538 198 554.7 226 568.7 216 584.7 212 602.7 212 642.7 212 676.7 238 691.3 274 739.3 280 776 320 776 368.7 776 380.7 774 392.7 772 406.7 788 422.7 796 444.7 796 468.7 792.7 508 766.7 542 730.7 556Z",
303+
"width": 1000
304+
},
305+
"search": [
306+
"treeclearingicon"
307+
]
308+
},
309+
{
310+
"uid": "ed3a258bade3bf4780a28360de948006",
311+
"css": "map-treeclearing",
312+
"code": 59416,
313+
"src": "custom_icons",
314+
"selected": true,
315+
"svg": {
316+
"path": "M451.3 556C463.3 580 479.3 610 489.3 608 499.3 606 503.3 586 505.3 566 501.3 566 497.3 566 493.3 566 479.3 566 463.3 562 451.3 556ZM421.3 584.7C447.3 602.7 457.3 598.7 457.3 598.7L439.3 560C435.3 568 429.3 576 421.3 584.7ZM529.3 560C523.3 586 509.3 632 531.3 626 541.3 624 553.3 614 567.3 604 553.3 590 545.3 574 543.3 554 540 556 533.3 558 529.3 560ZM500 11.3C230 11.3 11.3 230 11.3 500S230 988.7 500 988.7 988.7 770 988.7 500 770 11.3 500 11.3ZM730.7 556C724.7 604 684.7 640.7 636 640.7 618 640.7 600 634.7 584 624.7L539.3 666C536.7 668.7 534.7 672 534 676 532 688 527.3 716.7 527.3 735.3 527.3 736 527.3 736.7 527.3 738 530 761.3 554 824 554 824H441.3C449.3 792 471.3 798 470.7 724.7 481.3 689.3 458 629.3 458 629.3 446 631.3 420 615.3 402 603.3 388 609.3 373.3 613.3 357.3 613.3 305.3 612.7 264 568.7 264 516V512.7C242 494.7 228 468.7 228 438.7 228 406.7 244 378 268 361.3 269.3 358.7 271.3 355.3 272.7 352.7 271.3 299.3 314 256 367.3 256 372 252.7 376.7 249.3 381.3 246 391.3 206.7 429.3 178 472 178 508 178 538 198 554.7 226 568.7 216 584.7 212 602.7 212 642.7 212 676.7 238 691.3 274 739.3 280 776 320 776 368.7 776 380.7 774 392.7 772 406.7 788 422.7 796 444.7 796 468.7 792.7 508 766.7 542 730.7 556Z",
317+
"width": 1000
318+
},
319+
"search": [
320+
"treeclearing"
321+
]
322+
},
323+
{
324+
"uid": "34c64c242c4cbf1b09bc2de0efb62af6",
325+
"css": "map-desilting",
326+
"code": 59418,
327+
"src": "custom_icons",
328+
"selected": true,
329+
"svg": {
330+
"path": "M350.7 197.3L386.7 253.3 369.3 340.7 280.7 322 244.7 266 350.7 197.3ZM11.3 500C11.3 770 230 988.7 500 988.7S988.7 770 988.7 500 770 11.3 500 11.3 11.3 230 11.3 500ZM682 848C682 848 610.7 852.7 544.7 835.3S377.3 649.3 377.3 649.3L482 582 356 373.3 258 351.3 214.7 282.7 196 294 169.3 256.7 372 128.7 397.3 168 379.3 180 422.7 248.7 400.7 347.3 526.7 554.7 630 487.3C630 487.3 739.3 650 728 718.7 717.3 785.3 682 848 682 848Z",
331+
"width": 1000
332+
},
333+
"search": [
334+
"desilting"
335+
]
336+
},
337+
{
338+
"uid": "42262f2e6115132a6f291ca999d3d29e",
339+
"css": "map-canalrepair",
340+
"code": 59420,
341+
"src": "custom_icons",
342+
"selected": true,
343+
"svg": {
344+
"path": "M500 11.3C230 11.3 11.3 230 11.3 500S230 988.7 500 988.7 988.7 770 988.7 500 770 11.3 500 11.3ZM373.3 342C397.3 342 412.7 324.7 436.7 324.7 460.7 324.7 476 342 500 342H500C524 342 539.3 324.7 563.3 324.7 587.3 324.7 602.7 342 626.7 342 646 342 660.7 330.7 678.7 326L660.7 386C654.7 388 633.3 393.3 626.7 393.3 602.7 393.3 587.3 376 563.3 376 539.3 376 524 393.3 500 393.3 476 393.3 460.7 376 436.7 376S397.3 393.3 373.3 393.3C366.7 393.3 345.3 388 339.3 386L321.3 326C339.3 330.7 353.3 342 373.3 342ZM564 478C540 478 524 495.3 500 495.3S460 478 436 478C412 478 396 495.3 372 495.3L356 440.7C361.3 442 366.7 443.3 372 443.3 396 443.3 412 426 436 426S476 443.3 500 443.3H500C524 443.3 540 426 564 426 588 426 604 443.3 628 443.3 634 443.3 639.3 442 644 440.7L628 495.3C604 495.3 588 478 564 478ZM612.7 542L598.7 588.7C588.7 584.7 576 578.7 564 578.7 540 578.7 524 596 500 596 476 596 460 578.7 436 578.7 424 578.7 411.3 584 401.3 588.7L387.3 542C403.3 537.3 417.3 527.3 436 527.3 460 527.3 476 544.7 500 544.7 524 544.7 540 527.3 564 527.3 582.7 527.3 596 537.3 612.7 542ZM788 733.3H212V266.7H260L373.3 624H626.7L740 266.7H788.7V733.3Z",
345+
"width": 1000
346+
},
347+
"search": [
348+
"canalrepair"
349+
]
350+
},
351+
{
352+
"uid": "465b6c48e945913d8b41770d97d3efb3",
353+
"css": "desilting",
354+
"code": 59422,
355+
"src": "custom_icons",
356+
"selected": true,
357+
"svg": {
358+
"path": "M630 487.3L526.7 554.7 400.7 347.3 422.7 248.7 379.3 180 397.3 168 372 128.7 169.3 256.7 196 294 214.7 282.7 258 351.3 356 373.3 482 582 377.3 649.3C377.3 649.3 478.7 818 544.7 835.3S682 848 682 848 717.3 785.3 728 718.7C739.3 650 630 487.3 630 487.3ZM369.3 340.7L280.7 322 244.7 266 350.7 197.3 386.7 253.3 369.3 340.7Z",
359+
"width": 1000
360+
},
361+
"search": [
362+
"desiltingicon"
363+
]
364+
},
365+
{
366+
"uid": "d358e533508d4dc1f86cd3646074a482",
367+
"css": "canalrepair",
368+
"code": 59423,
369+
"src": "custom_icons",
370+
"selected": true,
371+
"svg": {
372+
"path": "M373.3 342C397.3 342 412.7 324.7 436.7 324.7S476 342 500 342L500 342C524 342 539.3 324.7 563.3 324.7S602.7 342 626.7 342C646 342 660.7 330.7 678.7 326L660.7 386C654.7 388 633.3 393.3 626.7 393.3 602.7 393.3 587.3 376 563.3 376S524 393.3 500 393.3 460.7 376 436.7 376 397.3 393.3 373.3 393.3C366.7 393.3 345.3 388 339.3 386L321.3 326C339.3 330.7 353.3 342 373.3 342ZM564 478C540 478 524 495.3 500 495.3S460 478 436 478 396 495.3 372 495.3L356 440.7C361.3 442 366.7 443.3 372 443.3 396 443.3 412 426 436 426S476 443.3 500 443.3L500 443.3C524 443.3 540 426 564 426S604 443.3 628 443.3C634 443.3 639.3 442 644 440.7L628 495.3C604 495.3 588 478 564 478ZM612.7 542L598.7 588.7C588.7 584.7 576 578.7 564 578.7 540 578.7 524 596 500 596S460 578.7 436 578.7C424 578.7 411.3 584 401.3 588.7L387.3 542C403.3 537.3 417.3 527.3 436 527.3 460 527.3 476 544.7 500 544.7S540 527.3 564 527.3C582.7 527.3 596 537.3 612.7 542ZM788 733.3H212V266.7H260L373.3 624H626.7L740 266.7H788.7V733.3H788Z",
373+
"width": 1000
374+
},
375+
"search": [
376+
"canalrepairicon"
377+
]
378+
},
379+
{
380+
"uid": "b01310588002367c480ff6e25ff2bbb8",
381+
"css": "map-flood",
382+
"code": 59424,
383+
"src": "custom_icons",
384+
"selected": true,
385+
"svg": {
386+
"path": "M500 11.3C230 11.3 11.3 230 11.3 500S230 988.7 500 988.7 988.7 770 988.7 500 770 11.3 500 11.3ZM508.7 842C388 844 270 756.7 253.3 618.7 248.7 582.7 255.3 547.3 268 514 304 420 358.7 336 416 254 435.3 226.7 455.3 200 476 173.3 492 152.7 508.7 152.7 524 173.3 593.3 264 658 356.7 708.7 459.3 736.7 516.7 748 556.7 748 602 748 734 640 840 508.7 842ZM546.7 772C526 772 514 762.7 513.3 746 513.3 730 524 720 543.3 718.7 592 714 623.3 682.7 628 634 630 614.7 640 603.3 655.3 604 671.3 604.7 681.3 616.7 680.7 637.3 681.3 708.7 618 771.3 546.7 772Z",
387+
"width": 1000
388+
},
389+
"search": [
390+
"flood"
391+
]
392+
},
393+
{
394+
"uid": "d744fa99c7dd9996643943c0473e1592",
395+
"css": "flood",
396+
"code": 59426,
397+
"src": "custom_icons",
398+
"selected": true,
399+
"svg": {
400+
"path": "M500 887.5C337.5 887.5 207.5 757.5 207.5 595 207.5 445 450 135 477.5 97.5 487.5 87.5 492.5 87.5 500 87.5 510 87.5 517.5 92.5 522.5 97.5 550 135 792.5 440 792.5 595 792.5 752.5 662.5 887.5 500 887.5ZM500 762.5C485 762.5 467.5 747.5 467.5 730 467.5 715 482.5 697.5 500 697.5 555 697.5 602.5 650 602.5 595 602.5 580 617.5 562.5 635 562.5 652.5 562.5 667.5 577.5 667.5 595 667.5 687.5 592.5 762.5 500 762.5Z",
401+
"width": 1000
402+
},
403+
"search": [
404+
"flood_icon"
405+
]
252406
}
253407
]
254408
}

assets/fonts/fontello/css/animation.css

100755100644
File mode changed.

assets/fonts/fontello/css/fontello-codes.css

100755100644
Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
.icon-trash-empty:before { content: '\e807'; } /* '' */
1010
.icon-cancel-circled-outline:before { content: '\e808'; } /* '' */
1111
.icon-picture:before { content: '\e809'; } /* '' */
12-
.icon-flood:before { content: '\e80a'; } /* '' */
12+
.icon-flood-img:before { content: '\e80a'; } /* '' */
1313
.icon-watch:before { content: '\e80b'; } /* '' */
1414
.icon-info:before { content: '\e80c'; } /* '' */
1515
.icon-block:before { content: '\e80d'; } /* '' */
@@ -22,6 +22,17 @@
2222
.icon-error-alt:before { content: '\e814'; } /* '' */
2323
.icon-add-report:before { content: '\e815'; } /* '' */
2424
.icon-otherapps:before { content: '\e816'; } /* '' */
25+
.icon-treeclearing:before { content: '\e817'; } /* '' */
26+
.icon-map-treeclearing:before { content: '\e818'; } /* '' */
27+
.icon-map-drain:before { content: '\e819'; } /* '' */
28+
.icon-map-desilting:before { content: '\e81a'; } /* '' */
29+
.icon-map-bg:before { content: '\e81b'; } /* '' */
30+
.icon-map-canalrepair:before { content: '\e81c'; } /* '' */
31+
.icon-drain:before { content: '\e81d'; } /* '' */
32+
.icon-desilting:before { content: '\e81e'; } /* '' */
33+
.icon-canalrepair:before { content: '\e81f'; } /* '' */
34+
.icon-map-flood:before { content: '\e820'; } /* '' */
35+
.icon-flood:before { content: '\e822'; } /* '' */
2536
.icon-spin4:before { content: '\e834'; } /* '' */
2637
.icon-menu:before { content: '\f0c9'; } /* '' */
2738
.icon-angle-double-right:before { content: '\f101'; } /* '' */

0 commit comments

Comments
 (0)