diff --git a/package-lock.json b/package-lock.json index d872a5588..21571043b 100644 --- a/package-lock.json +++ b/package-lock.json @@ -7,25 +7,25 @@ "resolved": "https://registry.npmjs.org/@cljs-oss/module-deps/-/module-deps-1.1.1.tgz", "integrity": "sha1-YmZ/KCFk8/EParnxJLpBb9EkOfo=", "requires": { - "JSONStream": "^1.0.3", - "babel-traverse": "^6.23.1", - "babylon": "^6.15.0", - "browser-resolve": "^1.7.0", - "cached-path-relative": "^1.0.0", - "concat-stream": "~1.5.0", - "defined": "^1.0.0", - "detective": "^4.0.0", - "duplexer2": "^0.1.2", + "JSONStream": "1.3.2", + "babel-traverse": "6.26.0", + "babylon": "6.18.0", + "browser-resolve": "1.11.2", + "cached-path-relative": "1.0.2", + "concat-stream": "1.5.2", + "defined": "1.0.0", + "detective": "4.7.1", + "duplexer2": "0.1.4", "enhanced-resolve": "3.4.1", - "inherits": "^2.0.1", + "inherits": "2.0.3", "konan": "1.1.0", - "parents": "^1.0.0", - "readable-stream": "^2.0.2", - "resolve": "^1.1.3", - "stream-combiner2": "^1.1.1", - "subarg": "^1.0.0", - "through2": "^2.0.0", - "xtend": "^4.0.0" + "parents": "1.0.1", + "readable-stream": "2.3.5", + "resolve": "1.6.0", + "stream-combiner2": "1.1.1", + "subarg": "1.0.0", + "through2": "2.0.3", + "xtend": "4.0.1" } }, "@material/animation": { @@ -48,10 +48,10 @@ "resolved": "https://registry.npmjs.org/@material/button/-/button-0.32.0.tgz", "integrity": "sha512-3PBA+o8T5lFJbCo2GZD8sm5U4VXiHDN6nHkrKlysuvcbo6QQK1C3ZMP4BIj2nmSpodvNRXOk8opG3feDcubg3g==", "requires": { - "@material/elevation": "^0.28.0", - "@material/ripple": "^0.32.0", - "@material/theme": "^0.30.0", - "@material/typography": "^0.28.0" + "@material/elevation": "0.28.0", + "@material/ripple": "0.32.0", + "@material/theme": "0.30.0", + "@material/typography": "0.28.0" } }, "@material/card": { @@ -59,10 +59,10 @@ "resolved": "https://registry.npmjs.org/@material/card/-/card-0.32.0.tgz", "integrity": "sha512-Y/o8Mekvlt3su0K80gcLpmcdFUa+D57nKDI3nVcM1Xi2r5/ra3qjAmFda5mauxZK/8PzyB/FJzF1fy/RH5s+9g==", "requires": { - "@material/elevation": "^0.28.0", - "@material/ripple": "^0.32.0", - "@material/rtl": "^0.30.0", - "@material/theme": "^0.30.0" + "@material/elevation": "0.28.0", + "@material/ripple": "0.32.0", + "@material/rtl": "0.30.0", + "@material/theme": "0.30.0" } }, "@material/checkbox": { @@ -70,12 +70,12 @@ "resolved": "https://registry.npmjs.org/@material/checkbox/-/checkbox-0.32.0.tgz", "integrity": "sha512-Rc6sidCCsc+wyktwd6KhNqAt14H6zSEarwLnvqCaYLv/Ml+lqg2SjQ3mg9rRKt1JREaN7G9BGKQKAnB//OMY4g==", "requires": { - "@material/animation": "^0.25.0", - "@material/base": "^0.29.0", - "@material/ripple": "^0.32.0", - "@material/rtl": "^0.30.0", - "@material/selection-control": "^0.32.0", - "@material/theme": "^0.30.0" + "@material/animation": "0.25.0", + "@material/base": "0.29.0", + "@material/ripple": "0.32.0", + "@material/rtl": "0.30.0", + "@material/selection-control": "0.32.0", + "@material/theme": "0.30.0" } }, "@material/chips": { @@ -83,8 +83,8 @@ "resolved": "https://registry.npmjs.org/@material/chips/-/chips-0.32.0.tgz", "integrity": "sha512-bw4LSzF+Ejyi4Z7iZHZE5J2k437b2iLVM9bGjkXYZ4bkFR+gqjjfB9787FEQGoowHwKOWmuVwYrsO+Vsomf6jg==", "requires": { - "@material/base": "^0.29.0", - "@material/ripple": "^0.32.0" + "@material/base": "0.29.0", + "@material/ripple": "0.32.0" } }, "@material/dialog": { @@ -92,14 +92,14 @@ "resolved": "https://registry.npmjs.org/@material/dialog/-/dialog-0.32.0.tgz", "integrity": "sha512-tmOdwpFAT5aI4nI43ldzgZ5ONPEZzhE8Nf95DnP8najwKni/aY3D61yo3KwrE2Q0fuuXL1e6AEojX83IHEEciw==", "requires": { - "@material/animation": "^0.25.0", - "@material/base": "^0.29.0", - "@material/elevation": "^0.28.0", - "@material/ripple": "^0.32.0", - "@material/rtl": "^0.30.0", - "@material/theme": "^0.30.0", - "@material/typography": "^0.1.1", - "focus-trap": "^2.3.0" + "@material/animation": "0.25.0", + "@material/base": "0.29.0", + "@material/elevation": "0.28.0", + "@material/ripple": "0.32.0", + "@material/rtl": "0.30.0", + "@material/theme": "0.30.0", + "@material/typography": "0.1.1", + "focus-trap": "2.4.3" }, "dependencies": { "@material/typography": { @@ -114,12 +114,12 @@ "resolved": "https://registry.npmjs.org/@material/drawer/-/drawer-0.30.0.tgz", "integrity": "sha512-NZyp6jVd6cDucBPUl391cTuIkR5Vy5OdrdNQxvH+pTjvb7R2yQJKVv2a7PxuR1uKjGM1vRudFOdXpviwbplr9A==", "requires": { - "@material/animation": "^0.25.0", - "@material/base": "^0.29.0", - "@material/elevation": "^0.28.0", - "@material/rtl": "^0.30.0", - "@material/theme": "^0.30.0", - "@material/typography": "^0.28.0" + "@material/animation": "0.25.0", + "@material/base": "0.29.0", + "@material/elevation": "0.28.0", + "@material/rtl": "0.30.0", + "@material/theme": "0.30.0", + "@material/typography": "0.28.0" } }, "@material/elevation": { @@ -127,8 +127,8 @@ "resolved": "https://registry.npmjs.org/@material/elevation/-/elevation-0.28.0.tgz", "integrity": "sha512-U2utCuMDDhrJ8Cyisz16GAejN9h9xyS4jvVkt2uIOUyPZRjnaJyoAbpyf0mOzFxIdBuRpNGJYm2PoAwHsSA+xw==", "requires": { - "@material/animation": "^0.25.0", - "@material/theme": "^0.4.0" + "@material/animation": "0.25.0", + "@material/theme": "0.4.0" }, "dependencies": { "@material/theme": { @@ -143,10 +143,10 @@ "resolved": "https://registry.npmjs.org/@material/fab/-/fab-0.32.0.tgz", "integrity": "sha512-VWzka0qpDxDuqPai9alrFUQadpyEwSGuwt+vgqV0gL5vs0VxLlEa1XP8McZSvdCdHGPNEZtohUif2ZaDEiMSzQ==", "requires": { - "@material/animation": "^0.25.0", - "@material/elevation": "^0.28.0", - "@material/ripple": "^0.32.0", - "@material/theme": "^0.30.0" + "@material/animation": "0.25.0", + "@material/elevation": "0.28.0", + "@material/ripple": "0.32.0", + "@material/theme": "0.30.0" } }, "@material/floating-label": { @@ -154,9 +154,9 @@ "resolved": "https://registry.npmjs.org/@material/floating-label/-/floating-label-0.32.0.tgz", "integrity": "sha512-YrcRSK04EnvmVJw2bH0if9zOaag6zUbk41vW2FQZJkkaKd3kQt02d0RqlAJ9qSKciGNb0J0h/EDMcdGpNDAp6Q==", "requires": { - "@material/base": "^0.29.0", - "@material/rtl": "^0.30.0", - "@material/theme": "^0.30.0" + "@material/base": "0.29.0", + "@material/rtl": "0.30.0", + "@material/theme": "0.30.0" } }, "@material/form-field": { @@ -164,11 +164,11 @@ "resolved": "https://registry.npmjs.org/@material/form-field/-/form-field-0.32.0.tgz", "integrity": "sha512-DrUSzqS73H+ksyI0HM66q7IRVSuIIN5dvapayaCXscoSVq5jU1jObqDNtu7PmBxEqvXj68SHrRWm7M06m06a5w==", "requires": { - "@material/base": "^0.29.0", - "@material/rtl": "^0.30.0", - "@material/selection-control": "^0.32.0", - "@material/theme": "^0.30.0", - "@material/typography": "^0.28.0" + "@material/base": "0.29.0", + "@material/rtl": "0.30.0", + "@material/selection-control": "0.32.0", + "@material/theme": "0.30.0", + "@material/typography": "0.28.0" } }, "@material/grid-list": { @@ -176,10 +176,10 @@ "resolved": "https://registry.npmjs.org/@material/grid-list/-/grid-list-0.30.0.tgz", "integrity": "sha512-RjL5npvXRWqYE1ro83JjzF2JTimIqVrshCcjSCkiFcDY0AKyEBfihvtHA2JhngLgCgKBBcSHDzNL8sqGMT8AJg==", "requires": { - "@material/base": "^0.29.0", - "@material/rtl": "^0.30.0", - "@material/theme": "^0.30.0", - "@material/typography": "^0.28.0" + "@material/base": "0.29.0", + "@material/rtl": "0.30.0", + "@material/theme": "0.30.0", + "@material/typography": "0.28.0" } }, "@material/icon-toggle": { @@ -187,10 +187,10 @@ "resolved": "https://registry.npmjs.org/@material/icon-toggle/-/icon-toggle-0.32.0.tgz", "integrity": "sha512-49jrIvP64yVkhVuwek4PmPumMllB3CkqGHgGaSlNJHGdZ3VaSD4DqxnKD0avxhPxEUWg/NXy1dEE+3YFrI/Caw==", "requires": { - "@material/animation": "^0.25.0", - "@material/base": "^0.29.0", - "@material/ripple": "^0.32.0", - "@material/theme": "^0.30.0" + "@material/animation": "0.25.0", + "@material/base": "0.29.0", + "@material/ripple": "0.32.0", + "@material/theme": "0.30.0" } }, "@material/layout-grid": { @@ -203,9 +203,9 @@ "resolved": "https://registry.npmjs.org/@material/line-ripple/-/line-ripple-0.32.0.tgz", "integrity": "sha512-vd/jlnK/paWZnsr9rvKkeo4qjIDTd59TljSUzqgXN4wiOwiCqXWtNgsy+veKG4fNLVqwad7ECKizUn2iQ/+IMQ==", "requires": { - "@material/animation": "^0.25.0", - "@material/base": "^0.29.0", - "@material/theme": "^0.30.0" + "@material/animation": "0.25.0", + "@material/base": "0.29.0", + "@material/theme": "0.30.0" } }, "@material/linear-progress": { @@ -213,9 +213,9 @@ "resolved": "https://registry.npmjs.org/@material/linear-progress/-/linear-progress-0.30.0.tgz", "integrity": "sha512-xKeC22ni5B2xEoYwY8bBJABS3Xkxa1qjKb+bWu0zf90F7e3bQ0rp2pvzHSp0GGJHTAChu1COMXOyZ1QzaBYtGg==", "requires": { - "@material/animation": "^0.25.0", - "@material/base": "^0.29.0", - "@material/theme": "^0.30.0" + "@material/animation": "0.25.0", + "@material/base": "0.29.0", + "@material/theme": "0.30.0" } }, "@material/list": { @@ -223,10 +223,10 @@ "resolved": "https://registry.npmjs.org/@material/list/-/list-0.32.0.tgz", "integrity": "sha512-03eZsHYRSS7b+fUsx5gBkRhUubfPYYg5Nr7PwLdEPLR5VuQ6RzgcNYcBnLtIa5rdvrd6NugNNSL9c2k27Qjt6g==", "requires": { - "@material/ripple": "^0.32.0", - "@material/rtl": "^0.30.0", - "@material/theme": "^0.30.0", - "@material/typography": "^0.28.0" + "@material/ripple": "0.32.0", + "@material/rtl": "0.30.0", + "@material/theme": "0.30.0", + "@material/typography": "0.28.0" } }, "@material/menu": { @@ -234,11 +234,11 @@ "resolved": "https://registry.npmjs.org/@material/menu/-/menu-0.31.0.tgz", "integrity": "sha512-9318W8Ws1lnJzsXC9+3hVaYJkGxJOXNHR4PaIpvI9T4ZmyRu5+E6Cp0hf42RTQ1bHTDLOSG/tPuKvsN9VW/6hQ==", "requires": { - "@material/animation": "^0.25.0", - "@material/base": "^0.29.0", - "@material/elevation": "^0.28.0", - "@material/theme": "^0.30.0", - "@material/typography": "^0.28.0" + "@material/animation": "0.25.0", + "@material/base": "0.29.0", + "@material/elevation": "0.28.0", + "@material/theme": "0.30.0", + "@material/typography": "0.28.0" } }, "@material/radio": { @@ -246,11 +246,11 @@ "resolved": "https://registry.npmjs.org/@material/radio/-/radio-0.32.0.tgz", "integrity": "sha512-a+uUiCem0ULjcdH3mwOz/dabLGiiCshqr/Gu5xN1kB6bDLmXybM50DMgw3TowRXyyS4YOX6tm6j+af4dsiNJNQ==", "requires": { - "@material/animation": "^0.25.0", - "@material/base": "^0.29.0", - "@material/ripple": "^0.32.0", - "@material/selection-control": "^0.32.0", - "@material/theme": "^0.30.0" + "@material/animation": "0.25.0", + "@material/base": "0.29.0", + "@material/ripple": "0.32.0", + "@material/selection-control": "0.32.0", + "@material/theme": "0.30.0" } }, "@material/ripple": { @@ -258,8 +258,8 @@ "resolved": "https://registry.npmjs.org/@material/ripple/-/ripple-0.32.0.tgz", "integrity": "sha512-pfG16d1/46f4QnrUHG66aV22kbY7sh7n2HR/cFALX6D0l0Kae3+xjuUnr1yy32Y1tzLAc84U9jGEzTDykVff9A==", "requires": { - "@material/base": "^0.29.0", - "@material/theme": "^0.30.0" + "@material/base": "0.29.0", + "@material/theme": "0.30.0" } }, "@material/rtl": { @@ -272,14 +272,14 @@ "resolved": "https://registry.npmjs.org/@material/select/-/select-0.32.0.tgz", "integrity": "sha512-KLlP4i1QDzsDJoIW4qA1JB17zSrgHSG2PpxKeqhUjqb9W5Q71LJ6QjhPynFA897sq1Wd9WTSHl41BAu2qUZlFA==", "requires": { - "@material/animation": "^0.25.0", - "@material/base": "^0.29.0", - "@material/list": "^0.32.0", - "@material/menu": "^0.31.0", - "@material/ripple": "^0.32.0", - "@material/rtl": "^0.30.0", - "@material/theme": "^0.30.0", - "@material/typography": "^0.28.0" + "@material/animation": "0.25.0", + "@material/base": "0.29.0", + "@material/list": "0.32.0", + "@material/menu": "0.31.0", + "@material/ripple": "0.32.0", + "@material/rtl": "0.30.0", + "@material/theme": "0.30.0", + "@material/typography": "0.28.0" } }, "@material/selection-control": { @@ -287,7 +287,7 @@ "resolved": "https://registry.npmjs.org/@material/selection-control/-/selection-control-0.32.0.tgz", "integrity": "sha512-zlq6x5n0pN3eKJQBYkWdh4UQScF7Ui7g7XIeeuKnNFo99oxJoKtuGk3WX5/OBc0wU4qe38rfQW6XGeFG4Adk3Q==", "requires": { - "@material/ripple": "^0.32.0" + "@material/ripple": "0.32.0" } }, "@material/slider": { @@ -295,10 +295,10 @@ "resolved": "https://registry.npmjs.org/@material/slider/-/slider-0.32.0.tgz", "integrity": "sha512-FmV9tjzhj9KfTpxXL2YNgV3STQTWXmROp7SJqrz8v2JpDXiVyI/pq/DhcFLEMvs096cIZWgH+iyZPQGFTPH12A==", "requires": { - "@material/animation": "^0.25.0", - "@material/base": "^0.29.0", - "@material/rtl": "^0.30.0", - "@material/theme": "^0.30.0" + "@material/animation": "0.25.0", + "@material/base": "0.29.0", + "@material/rtl": "0.30.0", + "@material/theme": "0.30.0" } }, "@material/snackbar": { @@ -306,11 +306,11 @@ "resolved": "https://registry.npmjs.org/@material/snackbar/-/snackbar-0.30.0.tgz", "integrity": "sha512-zQamWIxco7wZGYHXZ5G6TGTUKeZgS/EZ+YgRhA5hm6ZwfZrQYhn8coWRPOfsgHHlDN511sA8svU41h6HArlSFA==", "requires": { - "@material/animation": "^0.25.0", - "@material/base": "^0.29.0", - "@material/rtl": "^0.30.0", - "@material/theme": "^0.30.0", - "@material/typography": "^0.28.0" + "@material/animation": "0.25.0", + "@material/base": "0.29.0", + "@material/rtl": "0.30.0", + "@material/theme": "0.30.0", + "@material/typography": "0.28.0" } }, "@material/switch": { @@ -318,9 +318,9 @@ "resolved": "https://registry.npmjs.org/@material/switch/-/switch-0.32.0.tgz", "integrity": "sha512-nn5HN8AdSb4aSOJEEG9wGvPg+wPhg2rMD3j8WTX1HZ7c0HklgM07SuNKI+Yz5VFgfA28m3qFJAdHIv7OdzSuaQ==", "requires": { - "@material/animation": "^0.25.0", - "@material/elevation": "^0.28.0", - "@material/theme": "^0.30.0" + "@material/animation": "0.25.0", + "@material/elevation": "0.28.0", + "@material/theme": "0.30.0" } }, "@material/tabs": { @@ -328,12 +328,12 @@ "resolved": "https://registry.npmjs.org/@material/tabs/-/tabs-0.32.0.tgz", "integrity": "sha512-RWzxlQoR6MPqxCP2kVNrxg4+D2A5eT7WO0cqkoxsbDz8wAPeNlU/vdr17bnTlhAiiwcDCKulxHRNX7Gztwwg0A==", "requires": { - "@material/animation": "^0.25.0", - "@material/base": "^0.29.0", - "@material/ripple": "^0.32.0", - "@material/rtl": "^0.30.0", - "@material/theme": "^0.30.0", - "@material/typography": "^0.28.0" + "@material/animation": "0.25.0", + "@material/base": "0.29.0", + "@material/ripple": "0.32.0", + "@material/rtl": "0.30.0", + "@material/theme": "0.30.0", + "@material/typography": "0.28.0" } }, "@material/textfield": { @@ -341,14 +341,14 @@ "resolved": "https://registry.npmjs.org/@material/textfield/-/textfield-0.32.0.tgz", "integrity": "sha512-5gLDjBE14LqRT3NcToYZu/vVL/FzPY/kPT+oqzyZaRfvx3iyTBXSPsE0LOfGIgPv+Z65Z4g1PoccLWW/cZWHbw==", "requires": { - "@material/animation": "^0.25.0", - "@material/base": "^0.29.0", - "@material/floating-label": "^0.32.0", - "@material/line-ripple": "^0.32.0", - "@material/ripple": "^0.32.0", - "@material/rtl": "^0.30.0", - "@material/theme": "^0.30.0", - "@material/typography": "^0.28.0" + "@material/animation": "0.25.0", + "@material/base": "0.29.0", + "@material/floating-label": "0.32.0", + "@material/line-ripple": "0.32.0", + "@material/ripple": "0.32.0", + "@material/rtl": "0.30.0", + "@material/theme": "0.30.0", + "@material/typography": "0.28.0" } }, "@material/theme": { @@ -361,12 +361,12 @@ "resolved": "https://registry.npmjs.org/@material/toolbar/-/toolbar-0.32.0.tgz", "integrity": "sha512-eDouRzRFqOpOigm1nOr8QrfEGJW87gdzhqlM8YbrIzUchm3JouAQgV62wvDs+mMpy2jXj1rMBZOTbtff78myqA==", "requires": { - "@material/base": "^0.29.0", - "@material/elevation": "^0.28.0", - "@material/ripple": "^0.32.0", - "@material/rtl": "^0.30.0", - "@material/theme": "^0.30.0", - "@material/typography": "^0.28.0" + "@material/base": "0.29.0", + "@material/elevation": "0.28.0", + "@material/ripple": "0.32.0", + "@material/rtl": "0.30.0", + "@material/theme": "0.30.0", + "@material/typography": "0.28.0" } }, "@material/top-app-bar": { @@ -374,13 +374,13 @@ "resolved": "https://registry.npmjs.org/@material/top-app-bar/-/top-app-bar-0.32.0.tgz", "integrity": "sha512-zdL70MN10Hd1831o0xdGGAASemY4ht2Wz2juANaK3fCf9uvv2UFouS8eJa4BX16rHenIzwrffuA1EKn96RauaQ==", "requires": { - "@material/animation": "^0.25.0", - "@material/base": "^0.29.0", - "@material/elevation": "^0.28.0", - "@material/ripple": "^0.32.0", - "@material/rtl": "^0.30.0", - "@material/theme": "^0.30.0", - "@material/typography": "^0.28.0" + "@material/animation": "0.25.0", + "@material/base": "0.29.0", + "@material/elevation": "0.28.0", + "@material/ripple": "0.32.0", + "@material/rtl": "0.30.0", + "@material/theme": "0.30.0", + "@material/typography": "0.28.0" } }, "@material/typography": { @@ -393,8 +393,8 @@ "resolved": "https://registry.npmjs.org/JSONStream/-/JSONStream-1.3.2.tgz", "integrity": "sha1-wQI3G27Dp887hHygDCC7D85Mbeo=", "requires": { - "jsonparse": "^1.2.0", - "through": ">=2.2.7 <3" + "jsonparse": "1.3.1", + "through": "2.3.8" } }, "acorn": { @@ -422,9 +422,9 @@ "resolved": "https://registry.npmjs.org/babel-code-frame/-/babel-code-frame-6.26.0.tgz", "integrity": "sha1-Y/1D99weO7fONZR9uP42mj9Yx0s=", "requires": { - "chalk": "^1.1.3", - "esutils": "^2.0.2", - "js-tokens": "^3.0.2" + "chalk": "1.1.3", + "esutils": "2.0.2", + "js-tokens": "3.0.2" } }, "babel-messages": { @@ -432,7 +432,7 @@ "resolved": "https://registry.npmjs.org/babel-messages/-/babel-messages-6.23.0.tgz", "integrity": "sha1-8830cDhYA1sqKVHG7F7fbGLyYw4=", "requires": { - "babel-runtime": "^6.22.0" + "babel-runtime": "6.26.0" } }, "babel-runtime": { @@ -440,8 +440,8 @@ "resolved": "https://registry.npmjs.org/babel-runtime/-/babel-runtime-6.26.0.tgz", "integrity": "sha1-llxwWGaOgrVde/4E/yM3vItWR/4=", "requires": { - "core-js": "^2.4.0", - "regenerator-runtime": "^0.11.0" + "core-js": "2.5.4", + "regenerator-runtime": "0.11.1" } }, "babel-traverse": { @@ -449,15 +449,15 @@ "resolved": "https://registry.npmjs.org/babel-traverse/-/babel-traverse-6.26.0.tgz", "integrity": "sha1-RqnL1+3MYsjlwGTi0tjQ9ANXZu4=", "requires": { - "babel-code-frame": "^6.26.0", - "babel-messages": "^6.23.0", - "babel-runtime": "^6.26.0", - "babel-types": "^6.26.0", - "babylon": "^6.18.0", - "debug": "^2.6.8", - "globals": "^9.18.0", - "invariant": "^2.2.2", - "lodash": "^4.17.4" + "babel-code-frame": "6.26.0", + "babel-messages": "6.23.0", + "babel-runtime": "6.26.0", + "babel-types": "6.26.0", + "babylon": "6.18.0", + "debug": "2.6.9", + "globals": "9.18.0", + "invariant": "2.2.4", + "lodash": "4.17.11" } }, "babel-types": { @@ -465,10 +465,10 @@ "resolved": "https://registry.npmjs.org/babel-types/-/babel-types-6.26.0.tgz", "integrity": "sha1-o7Bz+Uq0nrb6Vc1lInozQ4BjJJc=", "requires": { - "babel-runtime": "^6.26.0", - "esutils": "^2.0.2", - "lodash": "^4.17.4", - "to-fast-properties": "^1.0.3" + "babel-runtime": "6.26.0", + "esutils": "2.0.2", + "lodash": "4.17.11", + "to-fast-properties": "1.0.3" } }, "babylon": { @@ -501,11 +501,11 @@ "resolved": "https://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz", "integrity": "sha1-qBFcVeSnAv5NFQq9OHKCKn4J/Jg=", "requires": { - "ansi-styles": "^2.2.1", - "escape-string-regexp": "^1.0.2", - "has-ansi": "^2.0.0", - "strip-ansi": "^3.0.0", - "supports-color": "^2.0.0" + "ansi-styles": "2.2.1", + "escape-string-regexp": "1.0.5", + "has-ansi": "2.0.0", + "strip-ansi": "3.0.1", + "supports-color": "2.0.0" } }, "classnames": { @@ -518,9 +518,9 @@ "resolved": "https://registry.npmjs.org/concat-stream/-/concat-stream-1.5.2.tgz", "integrity": "sha1-cIl4Yk2FavQaWnQd790mHadSwmY=", "requires": { - "inherits": "~2.0.1", - "readable-stream": "~2.0.0", - "typedarray": "~0.0.5" + "inherits": "2.0.3", + "readable-stream": "2.0.6", + "typedarray": "0.0.6" }, "dependencies": { "readable-stream": { @@ -528,12 +528,12 @@ "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.0.6.tgz", "integrity": "sha1-j5A0HmilPMySh4jaz80Rs265t44=", "requires": { - "core-util-is": "~1.0.0", - "inherits": "~2.0.1", - "isarray": "~1.0.0", - "process-nextick-args": "~1.0.6", - "string_decoder": "~0.10.x", - "util-deprecate": "~1.0.1" + "core-util-is": "1.0.2", + "inherits": "2.0.3", + "isarray": "1.0.0", + "process-nextick-args": "1.0.7", + "string_decoder": "0.10.31", + "util-deprecate": "1.0.2" } } } @@ -553,9 +553,9 @@ "resolved": "https://registry.npmjs.org/create-react-class/-/create-react-class-15.6.3.tgz", "integrity": "sha512-M+/3Q6E6DLO6Yx3OwrWjwHBnvfXXYA7W+dFjt/ZDBemHO1DDZhsalX/NUtnTYclN6GfnBDRh4qRHjcDHmlJBJg==", "requires": { - "fbjs": "^0.8.9", - "loose-envify": "^1.3.1", - "object-assign": "^4.1.1" + "fbjs": "0.8.16", + "loose-envify": "1.3.1", + "object-assign": "4.1.1" } }, "debug": { @@ -576,8 +576,8 @@ "resolved": "https://registry.npmjs.org/detective/-/detective-4.7.1.tgz", "integrity": "sha512-H6PmeeUcZloWtdt4DAkFyzFL94arpHr3NOwwmVILFiy+9Qd4JTxxXrzfyGk/lmct2qVGBwTSwSXagqu2BxmWig==", "requires": { - "acorn": "^5.2.1", - "defined": "^1.0.0" + "acorn": "5.5.3", + "defined": "1.0.0" } }, "duplexer2": { @@ -585,7 +585,7 @@ "resolved": "https://registry.npmjs.org/duplexer2/-/duplexer2-0.1.4.tgz", "integrity": "sha1-ixLauHjA1p4+eJEFFmKjL8a93ME=", "requires": { - "readable-stream": "^2.0.2" + "readable-stream": "2.3.5" } }, "encoding": { @@ -593,7 +593,7 @@ "resolved": "https://registry.npmjs.org/encoding/-/encoding-0.1.12.tgz", "integrity": "sha1-U4tm8+5izRq1HsMjgp0flIDHS+s=", "requires": { - "iconv-lite": "~0.4.13" + "iconv-lite": "0.4.19" } }, "enhanced-resolve": { @@ -601,10 +601,10 @@ "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-3.4.1.tgz", "integrity": "sha1-BCHjOf1xQZs9oT0Smzl5BAIwR24=", "requires": { - "graceful-fs": "^4.1.2", - "memory-fs": "^0.4.0", - "object-assign": "^4.0.1", - "tapable": "^0.2.7" + "graceful-fs": "4.1.11", + "memory-fs": "0.4.1", + "object-assign": "4.1.1", + "tapable": "0.2.8" } }, "errno": { @@ -612,7 +612,7 @@ "resolved": "https://registry.npmjs.org/errno/-/errno-0.1.7.tgz", "integrity": "sha512-MfrRBDWzIWifgq6tJj60gkAwtLNb6sQPlcFrSOflcP1aFmmruKQ2wRnze/8V6kgyz7H3FF8Npzv78mZ7XLLflg==", "requires": { - "prr": "~1.0.1" + "prr": "1.0.1" } }, "escape-string-regexp": { @@ -630,13 +630,13 @@ "resolved": "https://registry.npmjs.org/fbjs/-/fbjs-0.8.16.tgz", "integrity": "sha1-XmdDL1UNxBtXK/VYR7ispk5TN9s=", "requires": { - "core-js": "^1.0.0", - "isomorphic-fetch": "^2.1.1", - "loose-envify": "^1.0.0", - "object-assign": "^4.1.0", - "promise": "^7.1.1", - "setimmediate": "^1.0.5", - "ua-parser-js": "^0.7.9" + "core-js": "1.2.7", + "isomorphic-fetch": "2.2.1", + "loose-envify": "1.3.1", + "object-assign": "4.1.1", + "promise": "7.3.1", + "setimmediate": "1.0.5", + "ua-parser-js": "0.7.17" }, "dependencies": { "core-js": { @@ -651,7 +651,7 @@ "resolved": "https://registry.npmjs.org/focus-trap/-/focus-trap-2.4.3.tgz", "integrity": "sha512-sT5Ip9nyAIxWq8Apt1Fdv6yTci5GotaOtO5Ro1/+F3PizttNBcCYz8j/Qze54PPFK73KUbOqh++HUCiyNPqvhA==", "requires": { - "tabbable": "^1.0.3" + "tabbable": "1.1.2" } }, "globals": { @@ -669,7 +669,7 @@ "resolved": "https://registry.npmjs.org/has-ansi/-/has-ansi-2.0.0.tgz", "integrity": "sha1-NPUEnOHs3ysGSa8+8k5F7TVBbZE=", "requires": { - "ansi-regex": "^2.0.0" + "ansi-regex": "2.1.1" } }, "iconv-lite": { @@ -687,7 +687,7 @@ "resolved": "https://registry.npmjs.org/invariant/-/invariant-2.2.4.tgz", "integrity": "sha512-phJfQVBuaJM5raOpJjSfkiD6BpbCE4Ns//LaXl6wGYtUBY83nWS6Rf9tXm2e8VaK60JEjYldbPif/A2B1C2gNA==", "requires": { - "loose-envify": "^1.0.0" + "loose-envify": "1.3.1" } }, "is-stream": { @@ -705,8 +705,8 @@ "resolved": "https://registry.npmjs.org/isomorphic-fetch/-/isomorphic-fetch-2.2.1.tgz", "integrity": "sha1-YRrhrPFPXoH3KVB0coGf6XM1WKk=", "requires": { - "node-fetch": "^1.0.1", - "whatwg-fetch": ">=0.10.0" + "node-fetch": "1.7.3", + "whatwg-fetch": "2.0.4" } }, "js-tokens": { @@ -724,8 +724,8 @@ "resolved": "https://registry.npmjs.org/konan/-/konan-1.1.0.tgz", "integrity": "sha1-M3dDxLl7S9Hvi2KiSzFeuLxLIJQ=", "requires": { - "babel-traverse": "^6.23.1", - "babylon": "^6.15.0" + "babel-traverse": "6.26.0", + "babylon": "6.18.0" } }, "lodash": { @@ -738,7 +738,7 @@ "resolved": "https://registry.npmjs.org/loose-envify/-/loose-envify-1.3.1.tgz", "integrity": "sha1-0aitM/qc4OcT1l/dCsi3SNR4yEg=", "requires": { - "js-tokens": "^3.0.0" + "js-tokens": "3.0.2" } }, "material-components-web": { @@ -746,40 +746,40 @@ "resolved": "https://registry.npmjs.org/material-components-web/-/material-components-web-0.32.0.tgz", "integrity": "sha512-f2etJyWzZu/5U1qYnybzHXuUhyEAG19a/OFjSLi6rYJtjY1BtPS+Az9IHvnKDB7ahLET00vEtMKZbNsSa8Eksw==", "requires": { - "@material/animation": "^0.25.0", - "@material/auto-init": "^0.32.0", - "@material/base": "^0.29.0", - "@material/button": "^0.32.0", - "@material/card": "^0.32.0", - "@material/checkbox": "^0.32.0", - "@material/chips": "^0.32.0", - "@material/dialog": "^0.32.0", - "@material/drawer": "^0.30.0", - "@material/elevation": "^0.28.0", - "@material/fab": "^0.32.0", - "@material/floating-label": "^0.32.0", - "@material/form-field": "^0.32.0", - "@material/grid-list": "^0.30.0", - "@material/icon-toggle": "^0.32.0", - "@material/layout-grid": "^0.24.0", - "@material/line-ripple": "^0.32.0", - "@material/linear-progress": "^0.30.0", - "@material/list": "^0.32.0", - "@material/menu": "^0.31.0", - "@material/radio": "^0.32.0", - "@material/ripple": "^0.32.0", - "@material/rtl": "^0.30.0", - "@material/select": "^0.32.0", - "@material/selection-control": "^0.32.0", - "@material/slider": "^0.32.0", - "@material/snackbar": "^0.30.0", - "@material/switch": "^0.32.0", - "@material/tabs": "^0.32.0", - "@material/textfield": "^0.32.0", - "@material/theme": "^0.30.0", - "@material/toolbar": "^0.32.0", - "@material/top-app-bar": "^0.32.0", - "@material/typography": "^0.28.0" + "@material/animation": "0.25.0", + "@material/auto-init": "0.32.0", + "@material/base": "0.29.0", + "@material/button": "0.32.0", + "@material/card": "0.32.0", + "@material/checkbox": "0.32.0", + "@material/chips": "0.32.0", + "@material/dialog": "0.32.0", + "@material/drawer": "0.30.0", + "@material/elevation": "0.28.0", + "@material/fab": "0.32.0", + "@material/floating-label": "0.32.0", + "@material/form-field": "0.32.0", + "@material/grid-list": "0.30.0", + "@material/icon-toggle": "0.32.0", + "@material/layout-grid": "0.24.0", + "@material/line-ripple": "0.32.0", + "@material/linear-progress": "0.30.0", + "@material/list": "0.32.0", + "@material/menu": "0.31.0", + "@material/radio": "0.32.0", + "@material/ripple": "0.32.0", + "@material/rtl": "0.30.0", + "@material/select": "0.32.0", + "@material/selection-control": "0.32.0", + "@material/slider": "0.32.0", + "@material/snackbar": "0.30.0", + "@material/switch": "0.32.0", + "@material/tabs": "0.32.0", + "@material/textfield": "0.32.0", + "@material/theme": "0.30.0", + "@material/toolbar": "0.32.0", + "@material/top-app-bar": "0.32.0", + "@material/typography": "0.28.0" } }, "memory-fs": { @@ -787,8 +787,8 @@ "resolved": "https://registry.npmjs.org/memory-fs/-/memory-fs-0.4.1.tgz", "integrity": "sha1-OpoguEYlI+RHz7x+i7gO1me/xVI=", "requires": { - "errno": "^0.1.3", - "readable-stream": "^2.0.1" + "errno": "0.1.7", + "readable-stream": "2.3.5" } }, "minimist": { @@ -806,8 +806,8 @@ "resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-1.7.3.tgz", "integrity": "sha512-NhZ4CsKx7cYm2vSrBAr2PvFOe6sWDf0UYLRqA6svUYg7+/TSfVAu49jYC4BvQ4Sms9SZgdqGBgroqfDhJdTyKQ==", "requires": { - "encoding": "^0.1.11", - "is-stream": "^1.0.1" + "encoding": "0.1.12", + "is-stream": "1.1.0" } }, "object-assign": { @@ -820,7 +820,7 @@ "resolved": "https://registry.npmjs.org/parents/-/parents-1.0.1.tgz", "integrity": "sha1-/t1NK/GTp3dF/nHjcdc8MwfZx1E=", "requires": { - "path-platform": "~0.11.15" + "path-platform": "0.11.15" } }, "path-parse": { @@ -843,7 +843,7 @@ "resolved": "https://registry.npmjs.org/promise/-/promise-7.3.1.tgz", "integrity": "sha512-nolQXZ/4L+bP/UGlkfaIujX9BKxGwmQ9OT4mOt5yvy8iK1h3wqTEJCijzGANTCCl9nWjY41juyAn2K3Q1hLLTg==", "requires": { - "asap": "~2.0.3" + "asap": "2.0.6" } }, "prop-types": { @@ -851,9 +851,9 @@ "resolved": "https://registry.npmjs.org/prop-types/-/prop-types-15.6.1.tgz", "integrity": "sha512-4ec7bY1Y66LymSUOH/zARVYObB23AT2h8cf6e/O6ZALB/N0sqZFEx7rq6EYPX2MkOdKORuooI/H5k9TlR4q7kQ==", "requires": { - "fbjs": "^0.8.16", - "loose-envify": "^1.3.1", - "object-assign": "^4.1.1" + "fbjs": "0.8.16", + "loose-envify": "1.3.1", + "object-assign": "4.1.1" } }, "prr": { @@ -866,10 +866,10 @@ "resolved": "https://registry.npmjs.org/react/-/react-15.5.4.tgz", "integrity": "sha1-+oPrAVBqsjfNwcjDsc6o3gEr8Ec=", "requires": { - "fbjs": "^0.8.9", - "loose-envify": "^1.1.0", - "object-assign": "^4.1.0", - "prop-types": "^15.5.7" + "fbjs": "0.8.16", + "loose-envify": "1.3.1", + "object-assign": "4.1.1", + "prop-types": "15.6.1" } }, "react-dom": { @@ -877,10 +877,10 @@ "resolved": "https://registry.npmjs.org/react-dom/-/react-dom-15.5.4.tgz", "integrity": "sha1-ugwoeG/VLtfk8hNf4CiNRirvk9o=", "requires": { - "fbjs": "^0.8.9", - "loose-envify": "^1.1.0", - "object-assign": "^4.1.0", - "prop-types": "~15.5.7" + "fbjs": "0.8.16", + "loose-envify": "1.3.1", + "object-assign": "4.1.1", + "prop-types": "15.5.10" }, "dependencies": { "prop-types": { @@ -888,8 +888,8 @@ "resolved": "https://registry.npmjs.org/prop-types/-/prop-types-15.5.10.tgz", "integrity": "sha1-J5ffwxJhguOpXj37suiT3ddFYVQ=", "requires": { - "fbjs": "^0.8.9", - "loose-envify": "^1.3.1" + "fbjs": "0.8.16", + "loose-envify": "1.3.1" } } } @@ -907,7 +907,7 @@ "resolved": "https://registry.npmjs.org/prop-types/-/prop-types-15.5.8.tgz", "integrity": "sha1-a3suFBCDvjjIWVqlH8VXdccZk5Q=", "requires": { - "fbjs": "^0.8.9" + "fbjs": "0.8.16" } } } @@ -917,13 +917,13 @@ "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.5.tgz", "integrity": "sha512-tK0yDhrkygt/knjowCUiWP9YdV7c5R+8cR0r/kt9ZhBU906Fs6RpQJCEilamRJj1Nx2rWI6LkW9gKqjTkshhEw==", "requires": { - "core-util-is": "~1.0.0", - "inherits": "~2.0.3", - "isarray": "~1.0.0", - "process-nextick-args": "~2.0.0", - "safe-buffer": "~5.1.1", - "string_decoder": "~1.0.3", - "util-deprecate": "~1.0.1" + "core-util-is": "1.0.2", + "inherits": "2.0.3", + "isarray": "1.0.0", + "process-nextick-args": "2.0.0", + "safe-buffer": "5.1.1", + "string_decoder": "1.0.3", + "util-deprecate": "1.0.2" }, "dependencies": { "process-nextick-args": { @@ -936,7 +936,7 @@ "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.0.3.tgz", "integrity": "sha512-4AH6Z5fzNNBcH+6XDMfA/BTt87skxqJlO0lAh3Dker5zThcAxG6mKz+iGu308UKoPPQ8Dcqx/4JhujzltRa+hQ==", "requires": { - "safe-buffer": "~5.1.0" + "safe-buffer": "5.1.1" } } } @@ -951,7 +951,7 @@ "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.6.0.tgz", "integrity": "sha512-mw7JQNu5ExIkcw4LPih0owX/TZXjD/ZUF/ZQ/pDnkw3ZKhDcZZw5klmBlj6gVMwjQ3Pz5Jgu7F3d0jcDVuEWdw==", "requires": { - "path-parse": "^1.0.5" + "path-parse": "1.0.5" } }, "rmwc": { @@ -959,7 +959,7 @@ "resolved": "https://registry.npmjs.org/rmwc/-/rmwc-1.4.1.tgz", "integrity": "sha512-Y8mZoc5tUgnQm/fTCz0lJIgJq2HzR+yTJxkhq6bunw56bJE1D09MNklfltQit5ss8olb0Dv7xwIARv4C+wGvqw==", "requires": { - "classnames": "^2.2.5", + "classnames": "2.2.5", "material-components-web": "0.32.0" } }, @@ -978,8 +978,8 @@ "resolved": "https://registry.npmjs.org/stream-combiner2/-/stream-combiner2-1.1.1.tgz", "integrity": "sha1-+02KFCDqNidk4hrUeAOXvry0HL4=", "requires": { - "duplexer2": "~0.1.0", - "readable-stream": "^2.0.2" + "duplexer2": "0.1.4", + "readable-stream": "2.3.5" } }, "string_decoder": { @@ -992,7 +992,7 @@ "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", "requires": { - "ansi-regex": "^2.0.0" + "ansi-regex": "2.1.1" } }, "subarg": { @@ -1000,7 +1000,7 @@ "resolved": "https://registry.npmjs.org/subarg/-/subarg-1.0.0.tgz", "integrity": "sha1-9izxdYHplrSPyWVpn1TAauJouNI=", "requires": { - "minimist": "^1.1.0" + "minimist": "1.2.0" } }, "supports-color": { @@ -1028,8 +1028,8 @@ "resolved": "https://registry.npmjs.org/through2/-/through2-2.0.3.tgz", "integrity": "sha1-AARWmzfHx0ujnEPzzteNGtlBQL4=", "requires": { - "readable-stream": "^2.1.5", - "xtend": "~4.0.1" + "readable-stream": "2.3.5", + "xtend": "4.0.1" } }, "to-fast-properties": { diff --git a/resources/sass/site2.scss b/resources/sass/site2.scss index 2e3d80a24..97f357d18 100644 --- a/resources/sass/site2.scss +++ b/resources/sass/site2.scss @@ -113,6 +113,9 @@ header { position: absolute; right: $margin-page; bottom: -27px; + > i { + align-self: center; + } } } @@ -606,12 +609,29 @@ form.vertical, .fields-vertical { } } +.coverage-setting { + p, label { + color: rgba(0, 0, 0, 0.6); + font-size: 0.75rem; + } + .mdc-slider .mdc-slider__pin { + background-color: transparent; + color: $mdc-theme-primary; + top: 24px; + transform: rotate(-45deg); + > .mdc-slider__pin-value-marker::selection { + // remove selection color in firefox + background-color: transparent; + } + } +} + .action-input { max-width: 100px; } .percentage-input { display: inline-flex; - align-items: end; + align-items: baseline; div { margin-right: 0.8rem; > input { @@ -831,6 +851,7 @@ form.vertical, .fields-vertical { } .wizard { + padding-bottom: 0; .steps { display: flex; flex-direction: row; @@ -848,7 +869,7 @@ form.vertical, .fields-vertical { display: flex; align-items: center; i { - background-color: #999999; + background-color: #999999; color: #ffffff; font-style: normal; padding: 5px 11px; @@ -871,7 +892,7 @@ form.vertical, .fields-vertical { border: none; } } - + .complete { i { background-color: $mdc-theme-primary; @@ -891,8 +912,20 @@ form.vertical, .fields-vertical { } } .map { + display: flex; + align-items: stretch; min-height: 500px; - height: 100%; + height: calc(100% + 24px); + min-width: 500px; + margin: -24px -24px 0 0; + * { + z-index: 0; + } + + > div { + width: 100%; + // height: 100%; + } } } diff --git a/src/planwise/client/coverage.cljs b/src/planwise/client/coverage.cljs index 5841420d7..ae57ef25d 100644 --- a/src/planwise/client/coverage.cljs +++ b/src/planwise/client/coverage.cljs @@ -53,15 +53,23 @@ (defn- criteria-option-select-component [{:keys [label value options on-change]}] - [m/Select {:label label - :disabled (empty? options) - :value (str value) - :options options - :onChange #(on-change (js/parseInt (-> % .-target .-value)))}]) + (let [sorted-options (sort-by :value options) + step (- (:value (second sorted-options)) (:value (first sorted-options))) + value-label (:label (first (filter #(= value (:value %)) options)))] + [:div.coverage-setting + [:label label] + [m/Slider {:value value + :onInput #(on-change (-> % .-detail .-value)) + :onChange #(on-change (-> % .-detail .-value)) + :min (:value (first sorted-options)) + :max (:value (last sorted-options)) + :discrete true + :step step}] + [:p value-label]])) (defn- criteria-option [{:keys [config value on-change disabled?]}] - (let [options (map #(update % :value str) (:options config)) + (let [options (:options config) label (:label config) component (if disabled? disabled-input-component diff --git a/src/planwise/client/projects2/components/settings.cljs b/src/planwise/client/projects2/components/settings.cljs index c46c875c4..98d3c70a2 100644 --- a/src/planwise/client/projects2/components/settings.cljs +++ b/src/planwise/client/projects2/components/settings.cljs @@ -17,12 +17,8 @@ [planwise.client.ui.rmwc :as m] [planwise.client.utils :as utils] [clojure.spec.alpha :as s] - [planwise.model.project-consumers] - [planwise.model.project-actions] - [planwise.model.project-coverage] - [planwise.model.project-providers] - [planwise.model.project-review] - [planwise.model.project-goal])) + [leaflet.core :as l] + [planwise.client.mapping :as mapping])) ;;------------------------------------------------------------------------ ;;Current Project updating @@ -85,11 +81,12 @@ :on-click #(reset! state true)} "Delete"]) (defn- project-back-button - [] - ; TODO - add on-click function and don't show it in first step - [m/Button {:type "button" - :theme ["text-secondary-on-secondary-light"]} - "Back"]) + [project step] + (when step + [m/Button {:type "button" + :theme ["text-secondary-on-secondary-light"] + :on-click (utils/prevent-default #(dispatch [:projects2/navigate-to-step-project (:id project) step]))} + "Back"])) (defn- tag-chip [props index input read-only] @@ -241,32 +238,71 @@ (defn- current-project-step-review [read-only] - (let [current-project (subscribe [:projects2/current-project])] + (let [current-project (subscribe [:projects2/current-project]) + algorithms (rf/subscribe [:coverage/supported-algorithms]) + providers (subscribe [:providers-set/dropdown-options]) + provider-set-id (:provider-set-id @current-project) + provider (first (filter #(= provider-set-id (:value %)) @providers)) + algorithm (get-in @algorithms [(keyword (:coverage-algorithm @current-project))]) + criteria (first (vals (:criteria algorithm))) + coverage-amount (first (vals (get-in @current-project [:config :coverage :filter-options]))) + sources (subscribe [:sources/list]) + source (first (filter #(= (:source-set-id @current-project) (:id %)) @sources)) + budget (get-in @current-project [:config :actions :budget]) + workload (get-in @current-project [:config :providers :capacity]) + consumers-unit (get-in @current-project [:config :demographics :unit-name]) + capacities (get-in @current-project [:config :actions :build])] + (dispatch [:sources/load]) + (dispatch [:providers-set/load-providers-set]) [:section {:class "project-settings-section"} [section-header 6 "Review"] [:div {:class "step-info"} "After this step the system will search for different improvements scenarios based on the given parameters. Once started, the process will continue even if you leave the site. From the dashboard you will be able to see the scenarios found so far, pause the search and review the performed work."] - [project-setting-title "location_on" "Kenya health facilities - ResMap 8902"] - [project-setting-title "account_balance" "K 25,000,000"] - [project-setting-title "people" "Kenya census 2005"] - [project-setting-title "directions" "120 min walking distance, 40 min driving"] - [project-setting-title "info" "A hospital with a capacity of 100 beds will provide service for 1000 pregnancies per year"]])) + (if (some? provider) + [project-setting-title "location_on" (:label provider)] + [project-setting-title "warning" "The provider dataset field in the \"providers\" tab is needed"]) + (if (some? budget) + [project-setting-title "account_balance" (str "K " budget)] + [project-setting-title "warning" "The budget field in the \"actions\" tab is needed"]) + (if (some? source) + [project-setting-title "people" (:name source)] + [project-setting-title "warning" "The \"consumers\" tab information is needed"]) + (if (and (some? coverage-amount) (some? provider-set-id)) + [project-setting-title "directions" (str + (:label (first (filter #(= coverage-amount (:value %)) (:options criteria)))) + " of " + (:label (first (vals (:criteria algorithm)))))] + [project-setting-title "warning" "The \"providers\" and \"coverage\" tabs information is needed"]) + (map (fn [action] + [project-setting-title "info" (join " " ["A facility with a capacity of" + (:capacity action) + "will provide service for" + (* (:capacity action) workload) + (or (not-empty consumers-unit) "consumers units") + " per year"])]) capacities)])) + + +(def map-preview-size {:width 373 :height 278}) (defn current-project-settings-view [{:keys [read-only step sections]}] (let [current-project (subscribe [:projects2/current-project]) build-actions (subscribe [:projects2/build-actions]) upgrade-actions (subscribe [:projects2/upgrade-actions]) - tags (subscribe [:projects2/tags])] - + tags (subscribe [:projects2/tags]) + regions (subscribe [:regions/list])] (fn [{:keys [read-only step]}] (let [project @current-project - step-data (first (filter #(= (:step %) step) sections))] - + step-data (first (filter #(= (:step %) step) sections)) + bbox (:bbox (first (filter #(= (:id %) (:region-id @current-project)) @regions))) + region-geo (subscribe [:regions/preview-geojson (:region-id @current-project)]) + preview-map-url (if (:region-id @current-project) (static-image @region-geo map-preview-size))] + (dispatch [:regions/load-regions-with-preview [(:region-id @current-project)]]) [m/Grid {:class-name "wizard"} + [m/GridCell {:span 12 :class-name "steps"} (map-indexed (fn [i iteration-step] [:a {:key i - :class-name (join " " [(if (= (:step iteration-step) step) "active") (if (s/valid? (keyword (str "planwise.model.project-" (:step iteration-step)) "validation") project) "complete")]) + :class-name (join " " [(if (= (:step iteration-step) step) "active") (if (s/valid? (:spec iteration-step) project) "complete")]) :href (routes/projects2-show-with-step {:id (:id project) :step (:step iteration-step)})} (if (s/valid? (:spec iteration-step) project) [m/Icon "done"] [:i (inc i)]) [:div (:title iteration-step)]]) sections)] @@ -276,7 +312,19 @@ (dispatch [:projects2/infer-step @current-project]) ((:component step-data) read-only))]] [m/GridCell {:span 6} - [:div.map]]])))) + [:div.map + (if (some? bbox) + [l/map-widget {:position (mapping/bbox-center bbox) + :controls [] + :initial-bbox bbox} + mapping/default-base-tile-layer + [:geojson-layer {:data @region-geo} + :group {:pane "tilePane"} + :lat-fn (fn [polygon-point] (:lat polygon-point)) + :lon-fn (fn [polygon-point] (:lon polygon-point)) + :color :orange + :stroke true]])]]])))) + (defn edit-current-project [] @@ -296,8 +344,10 @@ [current-project-settings-view {:read-only false :step (:step @page-params) :sections sections}] [:div {:class-name "project-settings-actions"} - [project-back-button] - [project-delete-button delete?] + (let [previous-step (:step (first (filter #(= (:next-step %) (:step @page-params)) sections)))] + (if (nil? previous-step) + [project-delete-button delete?] + [project-back-button @current-project previous-step])) [project-next-step-button @current-project (:next-step (first (filter #(= (:step %) (:step @page-params)) sections)))]]] [delete-project-dialog {:open? @delete? :cancel-fn hide-dialog diff --git a/src/planwise/client/projects2/handlers.cljs b/src/planwise/client/projects2/handlers.cljs index 5de2de992..999c7f47b 100644 --- a/src/planwise/client/projects2/handlers.cljs +++ b/src/planwise/client/projects2/handlers.cljs @@ -6,13 +6,7 @@ [planwise.client.effects :as effects] [planwise.client.projects2.db :as db] [planwise.client.utils :as utils] - [clojure.spec.alpha :as s] - [planwise.model.project-consumers] - [planwise.model.project-actions] - [planwise.model.project-coverage] - [planwise.model.project-providers] - [planwise.model.project-review] - [planwise.model.project-goal])) + [clojure.spec.alpha :as s])) (def in-projects2 (rf/path [:projects2])) @@ -44,7 +38,7 @@ in-projects2 (fn [{:keys [db]} [_ project]] (let [steps ["goal", "consumers", "providers", "coverage", "actions", "review"] - first-invalid-step (first (filter #(not (s/valid? (keyword (str "planwise.model.project-" %) "validation") project)) steps)) + first-invalid-step (first (filter #(not (s/valid? (keyword "planwise.model.project" (str % "-step")) project)) steps)) selected-step (if (not-empty first-invalid-step) first-invalid-step "review")] {:navigate (routes/projects2-show-with-step {:id (:id project) :step selected-step})}))) diff --git a/src/planwise/client/providers_set/subs.cljs b/src/planwise/client/providers_set/subs.cljs index 5a7651ee5..9f9fc870c 100644 --- a/src/planwise/client/providers_set/subs.cljs +++ b/src/planwise/client/providers_set/subs.cljs @@ -12,7 +12,7 @@ :providers-set/dropdown-options (fn [db _] (let [list (get-in db [:providers-set :list :value])] - (mapv (fn [provider-set] (let [{:keys [id name]} provider-set] {:value (str id) :label name})) list)))) + (mapv (fn [provider-set] (let [{:keys [id name]} provider-set] {:value id :label name})) list)))) (rf/reg-sub :providers-set/view-state @@ -47,4 +47,4 @@ (rf/reg-sub :providers-set/delete-selected-provider-set (fn [db _] - (get-in db [:providers-set :selected-provider]))) \ No newline at end of file + (get-in db [:providers-set :selected-provider]))) diff --git a/src/planwise/component/coverage.clj b/src/planwise/component/coverage.clj index 4c2c2a17d..955c26e59 100644 --- a/src/planwise/component/coverage.clj +++ b/src/planwise/component/coverage.clj @@ -26,7 +26,7 @@ (s/def ::driving-time #{30 60 90 120}) (s/def ::driving-friction-criteria (s/keys :req-un [::driving-time])) -(s/def ::distance #{5 10 20 50 100}) +(s/def ::distance #{5 10 15 20 25 30 35 40 45 50 55 60 65 70 75 80 85 90 95 100}) (s/def ::simple-buffer-criteria (s/keys :req-un [::distance])) (s/def ::walking-time #{60 120 180}) @@ -70,8 +70,23 @@ :type :enum :options [{:value 5 :label "5 km"} {:value 10 :label "10 km"} + {:value 15 :label "15 km"} {:value 20 :label "20 km"} + {:value 25 :label "25 km"} + {:value 30 :label "30 km"} + {:value 35 :label "35 km"} + {:value 40 :label "40 km"} + {:value 45 :label "45 km"} {:value 50 :label "50 km"} + {:value 55 :label "55 km"} + {:value 60 :label "60 km"} + {:value 65 :label "65 km"} + {:value 70 :label "70 km"} + {:value 75 :label "75 km"} + {:value 80 :label "80 km"} + {:value 85 :label "85 km"} + {:value 90 :label "90 km"} + {:value 95 :label "95 km"} {:value 100 :label "100 km"}]}}}}) diff --git a/src/planwise/model/project_actions.cljc b/src/planwise/model/project_actions.cljc deleted file mode 100644 index a354412f9..000000000 --- a/src/planwise/model/project_actions.cljc +++ /dev/null @@ -1,9 +0,0 @@ -(ns planwise.model.project-actions - (:require [clojure.spec.alpha :as s] - [clojure.string :refer [blank?]])) - -(s/def ::budget number?) -(s/def ::actions (s/keys :req-un [::budget])) -(s/def ::config (s/keys :req-un [::actions])) - -(s/def ::validation (s/keys :req-un [::config])) diff --git a/src/planwise/model/project_consumers.cljc b/src/planwise/model/project_consumers.cljc deleted file mode 100644 index 63f2c95d8..000000000 --- a/src/planwise/model/project_consumers.cljc +++ /dev/null @@ -1,11 +0,0 @@ -(ns planwise.model.project-consumers - (:require [clojure.spec.alpha :as s] - [clojure.string :refer [blank?]])) - -(s/def ::target number?) -(s/def ::unit-name (s/and string? (comp not blank?))) -(s/def ::demographics (s/keys :req-un [::unit-name ::target])) -(s/def ::source-set-id number?) - -(s/def ::config (s/keys :req-un [::demographics])) -(s/def ::validation (s/keys :req-un [::source-set-id ::config])) diff --git a/src/planwise/model/project_coverage.cljc b/src/planwise/model/project_coverage.cljc deleted file mode 100644 index cd97ef582..000000000 --- a/src/planwise/model/project_coverage.cljc +++ /dev/null @@ -1,20 +0,0 @@ -(ns planwise.model.project-coverage - (:require [clojure.spec.alpha :as s] - [clojure.string :refer [blank?]])) - - -(s/def ::driving-time number?) -(s/def ::walking-time number?) -(s/def ::distance number?) - -(s/def ::driving-options (s/keys :req-un [::driving-time])) -(s/def ::walking-options (s/keys :req-un [::walking-time])) -(s/def ::distance-options (s/keys :req-un [::distance])) - -(s/def ::filter-options (s/or :driving-options ::driving-options - :walking-options ::walking-options - :distance-options ::distance-options)) -(s/def ::coverage (s/keys :req-un [::filter-options])) - -(s/def ::config (s/keys :req-un [::coverage])) -(s/def ::validation (s/keys :req-un [::config])) diff --git a/src/planwise/model/project_goal.cljc b/src/planwise/model/project_goal.cljc deleted file mode 100644 index a11fa5a61..000000000 --- a/src/planwise/model/project_goal.cljc +++ /dev/null @@ -1,7 +0,0 @@ -(ns planwise.model.project-goal - (:require [clojure.spec.alpha :as s] - [clojure.string :refer [blank?]])) - -(s/def ::name (s/and string? (comp not blank?))) -(s/def ::region-id number?) -(s/def ::validation (s/keys :req-un [::name ::region-id])) diff --git a/src/planwise/model/project_providers.cljc b/src/planwise/model/project_providers.cljc deleted file mode 100644 index 6ccfc9287..000000000 --- a/src/planwise/model/project_providers.cljc +++ /dev/null @@ -1,10 +0,0 @@ -(ns planwise.model.project-providers - (:require [clojure.spec.alpha :as s] - [clojure.string :refer [blank?]])) - - -(s/def ::provider-set-id number?) -(s/def ::capacity number?) -(s/def ::providers (s/keys :req-un [::capacity])) -(s/def ::config (s/keys :req-un [::providers])) -(s/def ::validation (s/keys :req-un [::provider-set-id]))