Changeset 15263 in josm


Ignore:
Timestamp:
2019-07-30T21:22:37+02:00 (4 weeks ago)
Author:
Klumbumbus
Message:

fix #17880, see #12247 - replace diaper by changing_table and add validator rules according to https://wiki.openstreetmap.org/wiki/Key:changing_table#Comparison_with_the_deprecated_diaper.3D.2A_key (icon self created, CC0 and PD licensed)

Location:
trunk
Files:
1 added
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/data/defaultpresets.xml

    r15262 r15263  
    38723872                <text key="operator" text="Operator" />
    38733873                <combo key="toilets:position" text="Usage Position" values="seated,seated;urinal,squat,urinal" />
    3874                 <combo key="diaper" text="Diaper" values="yes,no,room,1,2,3,4,5" text_context="toilets" />
    38753874                <reference ref="wheelchair" />
    38763875                <check key="drinking_water" text="Drinking Water" />
    38773876            </optional>
     3877            <preset_link preset_name="Changing table" />
    38783878        </item> <!-- Toilets/Restrooms -->
    38793879        <item name="Shower" icon="presets/service/shower.svg" type="node,closedway" preset_name_label="true">
     
    38893889                </checkgroup>
    38903890                <text key="description" text="Description" />
    3891                 <combo key="fee" text="Fee" values="yes,no" />
     3891                <reference ref="fee" />
    38923892                <text key="operator" text="Operator" />
    38933893                <reference ref="oh_wheelchair" />
    38943894            </optional>
    38953895        </item> <!-- Shower -->
     3896        <item name="Changing table" icon="presets/service/changing_table.svg" type="node,closedway" preset_name_label="true">
     3897            <link wiki="Key:changing_table" />
     3898            <space />
     3899            <combo key="changing_table" text="Changing table" values="yes,limited,no" default="yes" match="keyvalue!" />
     3900            <optional>
     3901                <check key="changing_table:fee" text="Fee" />
     3902                <combo key="changing_table:count" text="Count" values="1,2,3,4,5" />
     3903                <multiselect key="changing_table:location" text="Location" text_context="Changing table" values="dedicated_room;female_toilet;male_toilet;room;sales_area;unisex_toilet;wheelchair_toilet" />
     3904                <text key="operator" text="Operator" />
     3905                <reference ref="wheelchair" />
     3906            </optional>
     3907        </item> <!-- Changing table -->
    38963908        <separator/>
    38973909        <item name="Post Box" icon="presets/service/post_box.svg" type="node" preset_name_label="true">
  • trunk/data/validator/deprecated.mapcss

    r15262 r15263  
    16341634  fixAdd: "guest_house=bed_and_breakfast";
    16351635}
     1636
     1637/* #17880 */
     1638*[diaper=yes],
     1639*[diaper=no] {
     1640  throwWarning: tr("{0} is deprecated", "{0.tag}");
     1641  suggestAlternative: concat("changing_table=", "{0.value}");
     1642  group: tr("deprecated tagging");
     1643  fixChangeKey: "diaper => changing_table";
     1644  set diaper_checked;
     1645}
     1646*[diaper][diaper =~ /^[1-9][0-9]*$/] {
     1647  throwWarning: tr("{0} is deprecated", "{0.tag}");
     1648  suggestAlternative: concat("changing_table=yes + changing_table:count=", "{0.value}");
     1649  group: tr("deprecated tagging");
     1650  fixChangeKey: "diaper => changing_table:count";
     1651  fixAdd: "changing_table=yes";
     1652  set diaper_checked;
     1653}
     1654*[diaper=room] {
     1655  throwWarning: tr("{0} is deprecated", "{0.tag}");
     1656  suggestAlternative: "changing_table=room";
     1657  suggestAlternative: "changing_table=dedicated_room";
     1658  group: tr("deprecated tagging");
     1659  set diaper_checked;
     1660}
     1661*[diaper]!.diaper_checked {
     1662  throwWarning: tr("{0} is deprecated", "{0.key}");
     1663  suggestAlternative: "changing_table";
     1664  group: tr("deprecated tagging");
     1665}
     1666*[diaper:male=yes] {
     1667  throwWarning: tr("{0} is deprecated", "{0.tag}");
     1668  suggestAlternative: "changing_table:location=male_toilet";
     1669  group: tr("deprecated tagging");
     1670  fixAdd: "changing_table:location=male_toilet";
     1671  fixRemove: "diaper:male";
     1672  set diaper___checked;
     1673}
     1674*[diaper:female=yes] {
     1675  throwWarning: tr("{0} is deprecated", "{0.tag}");
     1676  suggestAlternative: "changing_table:location=female_toilet";
     1677  group: tr("deprecated tagging");
     1678  fixAdd: "changing_table:location=female_toilet";
     1679  fixRemove: "diaper:female";
     1680  set diaper___checked;
     1681}
     1682*[diaper:unisex=yes] {
     1683  throwWarning: tr("{0} is deprecated", "{0.tag}");
     1684  suggestAlternative: "changing_table:location=unisex_toilet";
     1685  group: tr("deprecated tagging");
     1686  fixAdd: "changing_table:location=unisex_toilet";
     1687  fixRemove: "diaper:unisex";
     1688  set diaper___checked;
     1689}
     1690*[diaper:wheelchair=yes],
     1691*[diaper:wheelchair=no] {
     1692  throwWarning: tr("{0} is deprecated", "{0.tag}");
     1693  suggestAlternative: concat("changing_table:wheelchair=", "{0.value}");
     1694  group: tr("deprecated tagging");
     1695  fixChangeKey: "diaper:wheelchair => changing_table:wheelchair";
     1696  set diaper___checked;
     1697}
     1698*[diaper:fee=yes],
     1699*[diaper:fee=no] {
     1700  throwWarning: tr("{0} is deprecated", "{0.tag}");
     1701  suggestAlternative: concat("changing_table:fee=", "{0.value}");
     1702  group: tr("deprecated tagging");
     1703  fixChangeKey: "diaper:fee => changing_table:fee";
     1704  set diaper___checked;
     1705}
     1706*[/^diaper:/]!.diaper___checked {
     1707  throwWarning: tr("{0} is deprecated", "diaper:*");
     1708  suggestAlternative: "changing_table:*";
     1709  group: tr("deprecated tagging");
     1710}
     1711*[changing_table][changing_table!~/^(yes|no|limited)$/] {
     1712  throwWarning: tr("wrong value: {0}", "{0.tag}");
     1713  suggestAlternative: "changing_table=yes";
     1714  suggestAlternative: "changing_table=no";
     1715  suggestAlternative: "changing_table=limited";
     1716}
  • trunk/styles/standard/elemstyles.mapcss

    r15260 r15263  
    277277node[traffic_sign][toll][!is_prop_set(icon-image)] {
    278278    icon-image: "presets/misc/no_icon.svg";
     279    set icon_z17;
     280}
     281
     282/*************************************/
     283/* low rendering priority properties */
     284/*************************************/
     285
     286area[changing_table=yes],
     287area[changing_table=limited] {
     288    fill-color: changing_table#f7efb7; /* same as amenity */
     289}
     290node[changing_table=yes],
     291node[changing_table=limited] {
     292    icon-image: "presets/service/changing_table.svg";
    279293    set icon_z17;
    280294}
Note: See TracChangeset for help on using the changeset viewer.