Merge pull request #255 from tomalrussell/feature/reduce_number_of_storeys

Fix for issue #144 Reduce number of classes for 'Number of storeys'...
This commit is contained in:
Tom Russell 2019-04-18 17:15:24 +01:00 committed by GitHub
commit 339cf2ca88
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 10 additions and 30 deletions

View File

@ -63,39 +63,23 @@
</Style> </Style>
<Style name="size_storeys"> <Style name="size_storeys">
<Rule> <Rule>
<Filter>[size_storeys] &gt;= 20</Filter> <Filter>[size_storeys] &gt;= 40</Filter>
<PolygonSymbolizer fill="#ffffcc" /> <PolygonSymbolizer fill="#ffffcc" />
</Rule> </Rule>
<Rule> <Rule>
<Filter>[size_storeys] &gt;= 15 and [size_storeys] &lt; 20</Filter> <Filter>[size_storeys] &gt;= 20 and [size_storeys] &lt; 40</Filter>
<PolygonSymbolizer fill="#ffeda0" />
</Rule>
<Rule>
<Filter>[size_storeys] &gt;= 10 and [size_storeys] &lt; 15</Filter>
<PolygonSymbolizer fill="#fed976" /> <PolygonSymbolizer fill="#fed976" />
</Rule> </Rule>
<Rule> <Rule>
<Filter>[size_storeys] &gt;= 6 and [size_storeys] &lt; 10</Filter> <Filter>[size_storeys] &gt;= 10 and [size_storeys] &lt; 20</Filter>
<PolygonSymbolizer fill="#feb24c" />
</Rule>
<Rule>
<Filter>[size_storeys] = 5</Filter>
<PolygonSymbolizer fill="#fd8d3c" /> <PolygonSymbolizer fill="#fd8d3c" />
</Rule> </Rule>
<Rule> <Rule>
<Filter>[size_storeys] = 4</Filter> <Filter>[size_storeys] &gt;= 6 and [size_storeys] &lt; 10</Filter>
<PolygonSymbolizer fill="#fc4e2a" />
</Rule>
<Rule>
<Filter>[size_storeys] = 3</Filter>
<PolygonSymbolizer fill="#e31a1c" /> <PolygonSymbolizer fill="#e31a1c" />
</Rule> </Rule>
<Rule> <Rule>
<Filter>[size_storeys] = 2</Filter> <Filter>[size_storeys] &gt;= 1 and [size_storeys] &lt; 6</Filter>
<PolygonSymbolizer fill="#bd0026" />
</Rule>
<Rule>
<Filter>[size_storeys] = 1</Filter>
<PolygonSymbolizer fill="#800026" /> <PolygonSymbolizer fill="#800026" />
</Rule> </Rule>
</Style> </Style>

View File

@ -42,15 +42,11 @@ const LEGEND_CONFIG = {
size: { size: {
title: "Number of storeys", title: "Number of storeys",
elements: [ elements: [
{ color: '#ffffcc', text: '≥20' }, { color: '#ffffcc', text: '≥40' },
{ color: '#ffeda0', text: '15-20' }, { color: '#fed976', text: '2039' },
{ color: '#fed976', text: '1015' }, { color: '#fd8d3c', text: '10-19' },
{ color: '#feb24c', text: '610' }, { color: '#e31a1c', text: '6-9' },
{ color: '#fd8d3c', text: '5' }, { color: '#800026', text: '1-5' },
{ color: '#fc4e2a', text: '4' },
{ color: '#e31a1c', text: '3' },
{ color: '#bd0026', text: '2' },
{ color: '#800026', text: '1' },
] ]
}, },
like: { like: {