diff --git a/css/00_reset.css b/css/00_reset.css index 55efa7b5d..a06b017d9 100644 --- a/css/00_reset.css +++ b/css/00_reset.css @@ -3,7 +3,7 @@ License: none (public domain) */ -html, body, div, span, applet, object, iframe, +div, span, applet, object, iframe, h1, h2, h3, h4, h5, h6, p, blockquote, pre, a, abbr, acronym, address, big, cite, code, del, dfn, em, img, ins, kbd, q, s, samp, @@ -28,9 +28,6 @@ article, aside, details, figcaption, figure, footer, header, hgroup, menu, nav, section { display: block; } -body { - line-height: 1; -} ol, ul { list-style: none; } @@ -80,19 +77,17 @@ display: none; } /* - * 1. Avoid the WebKit bug in Android 4.0.* where (2) destroys native `audio` - * and `video` controls. - * 2. Corrects inability to style clickable `input` types in iOS. - * 3. Improves usability and consistency of cursor style between image-type + * 1. Corrects inability to style clickable `input` types in iOS. + * 2. Improves usability and consistency of cursor style between image-type * `input` and others. */ button, -html input[type="button"], /* 1 */ +input[type="button"], input[type="reset"], input[type="submit"] { - -webkit-appearance: button; /* 2 */ - cursor: pointer; /* 3 */ + -webkit-appearance: button; /* 1 */ + cursor: pointer; /* 2 */ } /* diff --git a/css/20_map.css b/css/20_map.css index 018958bc5..6fc9dca0c 100644 --- a/css/20_map.css +++ b/css/20_map.css @@ -132,8 +132,8 @@ g.point.selected .shadow { g.point ellipse.stroke { display: none; } -.mode-drag-note g.note.active ellipse.stroke, -.mode-drag-node g.point.active ellipse.stroke { +.ideditor.mode-drag-note g.note.active ellipse.stroke, +.ideditor.mode-drag-node g.point.active ellipse.stroke { display: block; } diff --git a/css/55_cursors.css b/css/55_cursors.css index d7ff52e20..78f1106f7 100644 --- a/css/55_cursors.css +++ b/css/55_cursors.css @@ -11,96 +11,96 @@ cursor: url(img/cursor-grab.png) 9 9, auto; /* FF */ } -.mode-browse .point, -.mode-select .point { +.ideditor.mode-browse .point, +.ideditor.mode-select .point { cursor: pointer; /* Opera */ cursor: url(img/cursor-select-point.png), pointer; /* FF */ } -.mode-select .vertex, -.mode-browse .vertex { +.ideditor.mode-select .vertex, +.ideditor.mode-browse .vertex { cursor: pointer; /* Opera */ cursor: url(img/cursor-select-vertex.png), pointer; /* FF */ } -.mode-browse .line, -.mode-select .line { +.ideditor.mode-browse .line, +.ideditor.mode-select .line { cursor: pointer; /* Opera */ cursor: url(img/cursor-select-line.png), pointer; /* FF */ } -.mode-select .area, -.mode-browse .area { +.ideditor.mode-select .area, +.ideditor.mode-browse .area { cursor: pointer; /* Opera */ cursor: url(img/cursor-select-area.png), pointer; /* FF */ } -.mode-select .midpoint, -.mode-browse .midpoint { +.ideditor.mode-select .midpoint, +.ideditor.mode-browse .midpoint { cursor: pointer; /* Opera */ cursor: url(img/cursor-select-split.png), pointer; /* FF */ } -.mode-select .behavior-multiselect .point, -.mode-select .behavior-multiselect .vertex, -.mode-select .behavior-multiselect .line, -.mode-select .behavior-multiselect .area { +.ideditor.mode-select .behavior-multiselect .point, +.ideditor.mode-select .behavior-multiselect .vertex, +.ideditor.mode-select .behavior-multiselect .line, +.ideditor.mode-select .behavior-multiselect .area { cursor: pointer; /* Opera */ cursor: url(img/cursor-select-add.png), pointer; /* FF */ } -.mode-select .behavior-multiselect .selected { +.ideditor.mode-select .behavior-multiselect .selected { cursor: pointer; /* Opera */ cursor: url(img/cursor-select-remove.png), pointer; /* FF */ } -.mode-add-preset .main-map, -.mode-draw-line .main-map, -.mode-draw-area .main-map, -.mode-add-line .main-map, -.mode-add-area .main-map, -.mode-drag-node .main-map, -.mode-drag-note .main-map { +.ideditor.mode-add-preset .main-map, +.ideditor.mode-draw-line .main-map, +.ideditor.mode-draw-area .main-map, +.ideditor.mode-add-line .main-map, +.ideditor.mode-add-area .main-map, +.ideditor.mode-drag-node .main-map, +.ideditor.mode-drag-note .main-map { cursor: crosshair; /* Opera */ cursor: url(img/cursor-draw.png) 9 9, crosshair; /* FF */ } -.mode-draw-line .way.target, -.mode-draw-area .way.target, -.mode-add-line .way.target, -.mode-add-area .way.target, -.mode-drag-node .way.target { +.ideditor.mode-draw-line .way.target, +.ideditor.mode-draw-area .way.target, +.ideditor.mode-add-line .way.target, +.ideditor.mode-add-area .way.target, +.ideditor.mode-drag-node .way.target { cursor: crosshair; /* Opera */ cursor: url(img/cursor-draw-connect-line.png) 9 9, crosshair; /* FF */ } -.mode-draw-line .vertex.target, -.mode-draw-area .vertex.target, -.mode-add-line .vertex.target, -.mode-add-area .vertex.target, -.mode-drag-node .vertex.target { +.ideditor.mode-draw-line .vertex.target, +.ideditor.mode-draw-area .vertex.target, +.ideditor.mode-add-line .vertex.target, +.ideditor.mode-add-area .vertex.target, +.ideditor.mode-drag-node .vertex.target { cursor: crosshair; /* Opera */ cursor: url(img/cursor-draw-connect-vertex.png) 9 9, crosshair; /* FF */ } -.mode-add-point .main-map, -.mode-add-note .main-map, -.mode-browse.lasso .main-map, -.mode-browse.lasso .way, -.mode-browse.lasso .vertex, -.mode-browse.lasso .midpoint, -.mode-select.lasso .main-map, -.mode-select.lasso .way, -.mode-select.lasso .vertex, -.mode-select.lasso .midpoint { +.ideditor.mode-add-point .main-map, +.ideditor.mode-add-note .main-map, +.ideditor.mode-browse.lasso .main-map, +.ideditor.mode-browse.lasso .way, +.ideditor.mode-browse.lasso .vertex, +.ideditor.mode-browse.lasso .midpoint, +.ideditor.mode-select.lasso .main-map, +.ideditor.mode-select.lasso .way, +.ideditor.mode-select.lasso .vertex, +.ideditor.mode-select.lasso .midpoint { cursor: crosshair; /* Opera */ cursor: url(img/cursor-draw.png) 9 9, crosshair; /* FF */ } -.mode-browse .note, -.mode-browse .qaItem, -.mode-select .note, -.mode-select .qaItem, +.ideditor.mode-browse .note, +.ideditor.mode-browse .qaItem, +.ideditor.mode-select .note, +.ideditor.mode-select .qaItem, .turn rect, .turn circle { cursor: pointer; diff --git a/css/60_photos.css b/css/60_photos.css index 54910f366..6b9949c1c 100644 --- a/css/60_photos.css +++ b/css/60_photos.css @@ -99,8 +99,8 @@ .viewfield-group { pointer-events: none; } -.mode-browse .viewfield-group, -.mode-select .viewfield-group { +.ideditor.mode-browse .viewfield-group, +.ideditor.mode-select .viewfield-group { pointer-events: visible; cursor: pointer; } diff --git a/css/70_fills.css b/css/70_fills.css index 5aefc14d6..da181ff8d 100644 --- a/css/70_fills.css +++ b/css/70_fills.css @@ -46,7 +46,7 @@ .fill-partial path.area.fill.tag-indoor { stroke-width: 20px; } -.mode-browse .fill-partial path.area.fill, -.mode-select .fill-partial path.area.fill { +.ideditor.mode-browse .fill-partial path.area.fill, +.ideditor.mode-select .fill-partial path.area.fill { pointer-events: visibleStroke; } diff --git a/css/80_app.css b/css/80_app.css index 533592d8b..bfe97908a 100644 --- a/css/80_app.css +++ b/css/80_app.css @@ -1,39 +1,24 @@ /* Basics ------------------------------------------------------- */ -/* - Opera misbehaves when the window is resized vertically unless 100% width + height are - applied to both html and body. https://gist.github.com/jfirebaugh/bd225bcfdd3a633850c4 -*/ -html, body { - width: 100%; +/* the root element of iD */ +.ideditor { height: 100%; -} + width: 100%; + margin: 0; + padding: 0; + border: 0; + overflow: hidden; -body { font: normal 12px/1.6667 "-apple-system", BlinkMacSystemFont, "Segoe UI", "Roboto", "Oxygen", "Ubuntu", "Cantarell", "Fira Sans", "Droid Sans", "Helvetica Neue", "Arial", sans-serif; - margin: 0; - padding: 0; color: #333; - overflow: hidden; + -ms-user-select: none; -ms-content-zooming: none; } -.unsupported { - text-align: center; - vertical-align: middle; - padding-top: 100px; - font-size: 15px; -} - -.id-container { - height: 100%; - width: 100%; -} - .main-content { position: relative; overflow: hidden; @@ -181,13 +166,13 @@ input[type=email] { border-radius: 4px; text-overflow: ellipsis; } -[dir='rtl'] textarea, -[dir='rtl'] input[type=text], -[dir='rtl'] input[type=search], -[dir='rtl'] input[type=number], -[dir='rtl'] input[type=url], -[dir='rtl'] input[type=tel], -[dir='rtl'] input[type=email] { +.ideditor[dir='rtl'] textarea, +.ideditor[dir='rtl'] input[type=text], +.ideditor[dir='rtl'] input[type=search], +.ideditor[dir='rtl'] input[type=number], +.ideditor[dir='rtl'] input[type=url], +.ideditor[dir='rtl'] input[type=tel], +.ideditor[dir='rtl'] input[type=email] { padding: 5px 10px 5px 20px; } @@ -212,8 +197,8 @@ input[type="radio"] { margin-top: 3px; cursor: pointer; } -[dir='rtl'] input[type="checkbox"], -[dir='rtl'] input[type="radio"] { +.ideditor[dir='rtl'] input[type="checkbox"], +.ideditor[dir='rtl'] input[type="radio"] { float: right; margin-left: 5px; margin-right: 0; @@ -332,7 +317,7 @@ button.disabled { border-radius: 0; border-right: 1px solid rgba(0,0,0,.5); } -[dir='rtl'] .joined > * { +.ideditor[dir='rtl'] .joined > * { border-left: 1px solid rgba(0,0,0,.5); border-right: none; } @@ -343,14 +328,14 @@ button.disabled { .joined > *:first-child { border-radius: 4px 0 0 4px; } -[dir='rtl'] .joined > *:first-child { +.ideditor[dir='rtl'] .joined > *:first-child { border-radius: 0 4px 4px 0; } .joined > *:last-child { border-right-width: 0; border-radius: 0 4px 4px 0; } -[dir='rtl'] .joined > *.bar-button:last-child { +.ideditor[dir='rtl'] .joined > *.bar-button:last-child { border-radius: 4px 0 0 4px; } @@ -404,7 +389,7 @@ button[disabled].action:hover { .icon.pre-text { margin-right: 5px; } -[dir='rtl'] .icon.pre-text { +.ideditor[dir='rtl'] .icon.pre-text { margin-left: 5px; margin-right: 0; } @@ -482,12 +467,12 @@ button[disabled].action:hover { width: auto; margin: 0 5px; } -[dir='ltr'] .top-toolbar .toolbar-item:last-child .item-content, -[dir='rtl'] .top-toolbar .toolbar-item:first-child .item-content { +.ideditor[dir='ltr'] .top-toolbar .toolbar-item:last-child .item-content, +.ideditor[dir='rtl'] .top-toolbar .toolbar-item:first-child .item-content { margin-right: 10px; } -[dir='ltr'] .top-toolbar .toolbar-item:first-child .item-content, -[dir='rtl'] .top-toolbar .toolbar-item:last-child .item-content { +.ideditor[dir='ltr'] .top-toolbar .toolbar-item:first-child .item-content, +.ideditor[dir='rtl'] .top-toolbar .toolbar-item:last-child .item-content { margin-left: 10px; } .top-toolbar .toolbar-item .item-label { @@ -556,7 +541,7 @@ button.add-note svg.icon { margin-left: unset; margin-right: 4px; } -[dir='rtl'] button.add-note svg.icon { +.ideditor[dir='rtl'] button.add-note svg.icon { margin-left: 4px; margin-right: unset; } @@ -577,7 +562,7 @@ button.add-note svg.icon { background: transparent; border-radius: 100%; } -[dir='rtl'] .spinner img { +.ideditor[dir='rtl'] .spinner img { -moz-transform: scaleX(-1); -o-transform: scaleX(-1); -webkit-transform: scaleX(-1); @@ -596,10 +581,10 @@ button.add-note svg.icon { border-right-width: 0; } -[dir='ltr'] .undo-redo button:first-of-type { +.ideditor[dir='ltr'] .undo-redo button:first-of-type { margin-right: 1px; } -[dir='rtl'] .undo-redo button:first-of-type { +.ideditor[dir='rtl'] .undo-redo button:first-of-type { margin-left: 1px; } @@ -643,12 +628,12 @@ button.add-note svg.icon { right: 0; top: 0; } -[dir='rtl'] .field-help-title button.close, -[dir='rtl'] .sidebar-component .header button.data-editor-close, -[dir='rtl'] .sidebar-component .header button.note-editor-close, -[dir='rtl'] .sidebar-component .header button.qa-editor-close, -[dir='rtl'] .entity-editor-pane .header button.preset-close, -[dir='rtl'] .preset-list-pane .header button.preset-choose { +.ideditor[dir='rtl'] .field-help-title button.close, +.ideditor[dir='rtl'] .sidebar-component .header button.data-editor-close, +.ideditor[dir='rtl'] .sidebar-component .header button.note-editor-close, +.ideditor[dir='rtl'] .sidebar-component .header button.qa-editor-close, +.ideditor[dir='rtl'] .entity-editor-pane .header button.preset-close, +.ideditor[dir='rtl'] .preset-list-pane .header button.preset-choose { left: 0; right: auto; } @@ -658,7 +643,7 @@ button.add-note svg.icon { left: 0; top: 0; } -[dir='rtl'] .entity-editor-pane .header button.preset-choose { +.ideditor[dir='rtl'] .entity-editor-pane .header button.preset-choose { left: auto; right: 0; } @@ -676,7 +661,7 @@ button.add-note svg.icon { height: 59px; z-index: 50; } -[dir='rtl'] .modal > button { +.ideditor[dir='rtl'] .modal > button { left: 0; right: unset; } @@ -722,7 +707,7 @@ button.add-note svg.icon { height: 16px; margin-left: -3px; } -[dir='rtl'] .hide-toggle .icon.pre-text { +.ideditor[dir='rtl'] .hide-toggle .icon.pre-text { margin-left: 0; margin-right: -3px; } @@ -748,7 +733,7 @@ a.hide-toggle { border: 0px solid #ccc; border-right-width: 1px; } -[dir='rtl'] .sidebar { +.ideditor[dir='rtl'] .sidebar { float: right; border-right-width: 0px; border-left-width: 1px; @@ -762,7 +747,7 @@ a.hide-toggle { width: 6px; cursor: col-resize; } -[dir='rtl'] .sidebar-resizer { +.ideditor[dir='rtl'] .sidebar-resizer { right: auto; left: -6px; } @@ -772,7 +757,7 @@ a.hide-toggle { width: 10px; right: -10px; } -[dir='rtl'] .sidebar.collapsed .sidebar-resizer { +.ideditor[dir='rtl'] .sidebar.collapsed .sidebar-resizer { left: -10px; } @@ -856,7 +841,7 @@ a.hide-toggle { top: 80px; pointer-events: none; } -[dir='rtl'] .sidebar .search-header .icon { +.ideditor[dir='rtl'] .sidebar .search-header .icon { left: auto; right: 10px; } @@ -902,7 +887,7 @@ a.hide-toggle { border-radius: 2px; } -[dir='rtl'] .geocode-item { +.ideditor[dir='rtl'] .geocode-item { left: -25%; } @@ -931,7 +916,7 @@ a.hide-toggle { overflow: hidden; flex: 1 1 auto; } -[dir='rtl'] .feature-list-item .label { +.ideditor[dir='rtl'] .feature-list-item .label { text-align: right; } @@ -956,7 +941,7 @@ a.hide-toggle { color: #666; padding-left: 10px; } -[dir='rtl'] .feature-list-item .entity-name { +.ideditor[dir='rtl'] .feature-list-item .entity-name { padding-left: 0; padding-right: 10px; } @@ -1142,23 +1127,23 @@ a.hide-toggle { flex: 1 1 100%; align-self: stretch; } -[dir='rtl'] .preset-list-button .label { +.ideditor[dir='rtl'] .preset-list-button .label { text-align: right; border-left: none; border-right: 1px solid rgba(0, 0, 0, .1); } -[dir='ltr'] .preset-list-item.mixed-types .preset-list-button .label { +.ideditor[dir='ltr'] .preset-list-item.mixed-types .preset-list-button .label { border-top-right-radius: 4px; border-bottom-right-radius: 4px; } -[dir='rtl'] .preset-list-item.mixed-types .preset-list-button .label { +.ideditor[dir='rtl'] .preset-list-item.mixed-types .preset-list-button .label { border-top-left-radius: 4px; border-bottom-left-radius: 4px; } -[dir='ltr'] .category .preset-list-button .label { +.ideditor[dir='ltr'] .category .preset-list-button .label { border-radius: 0px 4px 4px 0px; } -[dir='rtl'] .category .preset-list-button .label { +.ideditor[dir='rtl'] .category .preset-list-button .label { border-radius: 4px 0px 0px 4px; } @@ -1190,16 +1175,16 @@ a.hide-toggle { flex: 0 0 auto; background: #f6f6f6; } -[dir='ltr'] .preset-list-item button.tag-reference-button { +.ideditor[dir='ltr'] .preset-list-item button.tag-reference-button { border-left: 1px solid #ccc; } -[dir='rtl'] .preset-list-item button.tag-reference-button { +.ideditor[dir='rtl'] .preset-list-item button.tag-reference-button { border-right: 1px solid #ccc; } -[dir='ltr'] .preset-list-item button:last-child { +.ideditor[dir='ltr'] .preset-list-item button:last-child { border-radius: 0 4px 4px 0; } -[dir='rtl'] .preset-list-item button:last-child { +.ideditor[dir='rtl'] .preset-list-item button:last-child { border-radius: 4px 0 0 4px; } @@ -1335,7 +1320,7 @@ a.hide-toggle { flex: 1 1 auto; padding: 5px 0 5px 10px; } -[dir='rtl'] .field-label .label-text { +.ideditor[dir='rtl'] .field-label .label-text { padding: 5px 10px 5px 0; } @@ -1356,7 +1341,7 @@ a.hide-toggle { border-radius: 0; background: #f6f6f6; } -[dir='rtl'] .field-label button { +.ideditor[dir='rtl'] .field-label button { border-left: none; border-right: 1px solid #ccc; } @@ -1424,7 +1409,7 @@ a.hide-toggle { border-left-width: 0; vertical-align: top; } -[dir='rtl'] .form-field-button { +.ideditor[dir='rtl'] .form-field-button { border-left-width: 1px; border-right-width: 0; } @@ -1441,7 +1426,7 @@ a.hide-toggle { .form-field-input-wrap > button:last-of-type { border-bottom-right-radius: 4px; } -[dir='rtl'] .form-field-input-wrap > button:last-of-type { +.ideditor[dir='rtl'] .form-field-input-wrap > button:last-of-type { border-bottom-left-radius: 4px; } @@ -1489,12 +1474,12 @@ a.hide-toggle { .form-field ul.rows li button { border-width: 0; } -[dir='ltr'] .form-field ul.rows li.labeled-input input, -[dir='ltr'] .form-field ul.rows li button { +.ideditor[dir='ltr'] .form-field ul.rows li.labeled-input input, +.ideditor[dir='ltr'] .form-field ul.rows li button { border-left-width: 1px; } -[dir='rtl'] .form-field ul.rows li.labeled-input input, -[dir='rtl'] .form-field ul.rows li button { +.ideditor[dir='rtl'] .form-field ul.rows li.labeled-input input, +.ideditor[dir='rtl'] .form-field ul.rows li button { border-right-width: 1px; } @@ -1546,10 +1531,10 @@ a.hide-toggle { margin-top: 3px; border-radius: 4px; } -[dir='ltr'] .form-field-input-multicombo li { +.ideditor[dir='ltr'] .form-field-input-multicombo li { margin-right: 6px; } -[dir='rtl'] .form-field-input-multicombo li { +.ideditor[dir='rtl'] .form-field-input-multicombo li { margin-left: 6px; } @@ -1559,10 +1544,10 @@ a.hide-toggle { line-height: 25px; max-width: 100%; } -[dir='ltr'] .form-field-input-multicombo li.chip { +.ideditor[dir='ltr'] .form-field-input-multicombo li.chip { padding: 2px 0px 2px 5px; } -[dir='rtl'] .form-field-input-multicombo li.chip { +.ideditor[dir='rtl'] .form-field-input-multicombo li.chip { padding: 2px 5px 2px 0px; } .form-field-input-multicombo li.chip.draggable { @@ -1632,24 +1617,24 @@ a.hide-toggle { .form-field-input-number > input:only-of-type { border-radius: 0 0 0 4px; } -[dir='rtl'] .form-field-input-number > input:only-of-type { +.ideditor[dir='rtl'] .form-field-input-number > input:only-of-type { border-radius: 0 0 4px 0; } .form-field-input-number > button:last-of-type { border-radius: 0 0 4px 0; } -[dir='rtl'] .form-field-input-number > button:last-of-type { +.ideditor[dir='rtl'] .form-field-input-number > button:last-of-type { border-radius: 0 0 0 4px; } -[dir='ltr'] .form-field-input-identifier > input:last-child, -[dir='rtl'] .form-field-input-identifier > input:first-child, -[dir='ltr'] .form-field-input-identifier > button { +.ideditor[dir='ltr'] .form-field-input-identifier > input:last-child, +.ideditor[dir='rtl'] .form-field-input-identifier > input:first-child, +.ideditor[dir='ltr'] .form-field-input-identifier > button { border-bottom-right-radius: 4px; } -[dir='ltr'] .form-field-input-identifier > input:first-child, -[dir='rtl'] .form-field-input-identifier > input:last-child, -[dir='rtl'] .form-field-input-identifier > button { +.ideditor[dir='ltr'] .form-field-input-identifier > input:first-child, +.ideditor[dir='rtl'] .form-field-input-identifier > input:last-child, +.ideditor[dir='rtl'] .form-field-input-identifier > button { border-bottom-left-radius: 4px; } @@ -1705,10 +1690,10 @@ a.hide-toggle { border-radius: 2px; padding: 0px 8px; } -[dir='ltr'] .form-field-input-check > .reverser.button { +.ideditor[dir='ltr'] .form-field-input-check > .reverser.button { padding-right: 2px; } -[dir='rtl'] .form-field-input-check > .reverser.button { +.ideditor[dir='rtl'] .form-field-input-check > .reverser.button { padding-left: 2px; } .form-field-input-check > .reverser.button.hide { @@ -1787,7 +1772,7 @@ a.hide-toggle { .form-field-input-maxspeed > input:first-of-type { border-radius: 0 0 0 4px; } -[dir='rtl'] .form-field-input-maxspeed > input:first-of-type { +.ideditor[dir='rtl'] .form-field-input-maxspeed > input:first-of-type { border-radius: 0 0 4px 0; } .form-field-input-maxspeed > input:last-of-type { /* unit field */ @@ -1796,7 +1781,7 @@ a.hide-toggle { border-left: 0; border-radius: 0 0 4px 0; } -[dir='rtl'] .form-field-input-maxspeed > input:last-of-type { +.ideditor[dir='rtl'] .form-field-input-maxspeed > input:last-of-type { border-right: 0; border-radius: 0 0 0 4px; } @@ -1807,13 +1792,13 @@ a.hide-toggle { .form-field-input-localized > input.localized-main { border-radius: 0 0 0 4px; } -[dir='rtl'] .form-field-input-localized > input.localized-main { +.ideditor[dir='rtl'] .form-field-input-localized > input.localized-main { border-radius: 0 0 4px 0; } .form-field-input-localized > button.localized-add { border-radius: 0 0 4px 0; } -[dir='rtl'] .form-field-input-localized > button.localized-add { +.ideditor[dir='rtl'] .form-field-input-localized > button.localized-add { border-radius: 0 0 0 4px; } @@ -1885,7 +1870,7 @@ a.hide-toggle { border-right: 0; border-bottom: 0; } -[dir='rtl'] .addr-row input { +.ideditor[dir='rtl'] .addr-row input { border-right: 1px solid #ccc; border-left: 0; } @@ -1896,19 +1881,19 @@ a.hide-toggle { .addr-row input:first-of-type { border-left: 0; } -[dir='rtl'] .addr-row input:first-of-type { +.ideditor[dir='rtl'] .addr-row input:first-of-type { border-right: 0; } .addr-row:last-of-type input:first-of-type { border-radius: 0 0 0 4px; } -[dir='rtl'] .addr-row:last-of-type input:first-of-type { +.ideditor[dir='rtl'] .addr-row:last-of-type input:first-of-type { border-radius: 0 0 4px 0; } .addr-row:last-of-type input:last-of-type { border-radius: 0 0 4px 0; } -[dir='rtl'] .addr-row:last-of-type input:last-of-type { +.ideditor[dir='rtl'] .addr-row:last-of-type input:last-of-type { border-radius: 0 0 0 4px; } @@ -1938,15 +1923,15 @@ a.hide-toggle { .wiki-title-container > input.wiki-title { border-radius: 0 0 0 4px; } -[dir='rtl'] .wiki-title-container > input.wiki-title { +.ideditor[dir='rtl'] .wiki-title-container > input.wiki-title { border-radius: 0 0 4px 0; } .wiki-title-container > button.wiki-link, .form-field-wikidata ul.rows li:last-child button.form-field-button:last-child { border-radius: 0 0 4px 0; } -[dir='rtl'] .wiki-title-container > button.wiki-link, -[dir='rtl'] .form-field-wikidata ul.rows li:last-child button.form-field-button:last-child { +.ideditor[dir='rtl'] .wiki-title-container > button.wiki-link, +.ideditor[dir='rtl'] .form-field-wikidata ul.rows li:last-child button.form-field-button:last-child { border-radius: 0 0 0 4px; } @@ -2108,7 +2093,7 @@ div.combobox { vertical-align: top; cursor: pointer; } -[dir='rtl'] .combobox-caret { +.ideditor[dir='rtl'] .combobox-caret { margin-left: 0; margin-right: -30px; } @@ -2245,7 +2230,7 @@ div.combobox { margin-left: 10px; flex: 1 1 50%; } -[dir='rtl'] .more-fields input { +.ideditor[dir='rtl'] .more-fields input { margin-left: auto; margin-right: 10px; } @@ -2288,7 +2273,7 @@ button.raw-tag-option svg.icon { height: 14px; vertical-align: text-bottom; } -[dir='ltr'] button.raw-tag-option-list { +.ideditor[dir='ltr'] button.raw-tag-option-list { -moz-transform: scaleX(-1); -o-transform: scaleX(-1); -webkit-transform: scaleX(-1); @@ -2343,7 +2328,7 @@ button.raw-tag-option svg.icon { border-left: 1px solid #ccc; width: 100%; } -[dir='rtl'] .tag-row input { +.ideditor[dir='rtl'] .tag-row input { border-left: none; border-right: 1px solid #ccc; } @@ -2357,7 +2342,7 @@ button.raw-tag-option svg.icon { .tag-row input.value { border-right: 1px solid #ccc; } -[dir='rtl'] .tag-row input.value { +.ideditor[dir='rtl'] .tag-row input.value { border-left: 1px solid #ccc; } @@ -2365,7 +2350,7 @@ button.raw-tag-option svg.icon { border-top: 1px solid #ccc; border-top-left-radius: 4px; } -[dir='rtl'] .tag-row:first-child input.key { +.ideditor[dir='rtl'] .tag-row:first-child input.key { border-top-left-radius: 0; border-top-right-radius: 4px; } @@ -2381,7 +2366,7 @@ button.raw-tag-option svg.icon { border-top-width: 0; border-left-width: 0; } -[dir='rtl'] .tag-row button { +.ideditor[dir='rtl'] .tag-row button { border-left-width: 1px; border-right-width: 0; } @@ -2399,7 +2384,7 @@ button.raw-tag-option svg.icon { .tag-row:first-child .tag-reference-button { border-top-right-radius: 4px; } -[dir='rtl'] .tag-row:first-child .tag-reference-button { +.ideditor[dir='rtl'] .tag-row:first-child .tag-reference-button { border-top-left-radius: 4px; border-top-right-radius: 0; } @@ -2407,7 +2392,7 @@ button.raw-tag-option svg.icon { .tag-row:last-child .tag-reference-button { border-bottom-right-radius: 4px; } -[dir='rtl'] .tag-row:last-child .tag-reference-button { +.ideditor[dir='rtl'] .tag-row:last-child .tag-reference-button { border-bottom-left-radius: 4px; border-bottom-right-radius: 0; } @@ -2415,7 +2400,7 @@ button.raw-tag-option svg.icon { .tag-row .tag-reference-button { border-radius: 0; } -[dir='rtl'] .tag-row .tag-reference-button { +.ideditor[dir='rtl'] .tag-row .tag-reference-button { border-left-width: 1px; border-right-width: 0; } @@ -2453,7 +2438,7 @@ img.tag-reference-wiki-image { border-radius: 4px; margin: 0 0 0 5px; } -[dir='rtl'] img.tag-reference-wiki-image { +.ideditor[dir='rtl'] img.tag-reference-wiki-image { float: left; margin: 0 5px 0 0; } @@ -2502,8 +2487,8 @@ img.tag-reference-wiki-image { padding-left: 10px; } -[dir='rtl'] .section-raw-member-editor .member-row .member-entity-name, -[dir='rtl'] .section-raw-membership-editor .member-row .member-entity-name { +.ideditor[dir='rtl'] .section-raw-member-editor .member-row .member-entity-name, +.ideditor[dir='rtl'] .section-raw-membership-editor .member-row .member-entity-name { padding-left:0; padding-right: 10px; } @@ -2511,12 +2496,12 @@ img.tag-reference-wiki-image { .form-field-input-member > input.member-role { border-radius: 0 0 0 4px; } -[dir='rtl'] .form-field-input-member > input.member-role { +.ideditor[dir='rtl'] .form-field-input-member > input.member-role { border-radius: 0 0 4px 0; } .member-incomplete .form-field-input-member > input.member-role, -[dir='rtl'] .member-incomplete .form-field-input-member > input.member-role { +.ideditor[dir='rtl'] .member-incomplete .form-field-input-member > input.member-role { border-radius: 0 0 4px 4px; } @@ -2604,8 +2589,8 @@ input.key-trap { border-right: 1px solid #ccc; border-radius: 5px 0 0 5px; } -[dir='rtl'] .note-header-icon, -[dir='rtl'] .qa-header-icon { +.ideditor[dir='rtl'] .note-header-icon, +.ideditor[dir='rtl'] .qa-header-icon { border-right: unset; border-left: 1px solid #ccc; border-radius: 0 5px 5px 0; @@ -2636,8 +2621,8 @@ input.key-trap { font-weight: bold; border-radius: 0 5px 5px 0; } -[dir='rtl'] .note-header-label, -[dir='rtl'] .qa-header-label { +.ideditor[dir='rtl'] .note-header-label, +.ideditor[dir='rtl'] .qa-header-label { border-radius: 5px 0 0 5px; } @@ -2678,7 +2663,7 @@ input.key-trap { overflow: hidden; overflow-wrap: break-word; } -[dir='rtl'] .comment-main { +.ideditor[dir='rtl'] .comment-main { padding: 10px 0 10px 10px; } @@ -2720,7 +2705,7 @@ input.key-trap { .qa-details-description-text::first-letter { text-transform: capitalize; } -[dir='rtl'] .qa-details-description-text::first-letter { +.ideditor[dir='rtl'] .qa-details-description-text::first-letter { text-transform: none; /* #5877 */ } .qa-details-subsection h4 { @@ -2780,7 +2765,7 @@ input.key-trap { border-right: 1px solid #ccc; border-radius: 5px 0 0 5px; } -[dir='rtl'] .data-header-icon { +.ideditor[dir='rtl'] .data-header-icon { border-right: unset; border-left: 1px solid #ccc; border-radius: 0 5px 5px 0; @@ -2799,7 +2784,7 @@ input.key-trap { font-weight: bold; border-radius: 0 5px 5px 0; } -[dir='rtl'] .data-header-label { +.ideditor[dir='rtl'] .data-header-label { border-radius: 5px 0 0 5px; } @@ -2822,7 +2807,7 @@ input.key-trap { position: absolute; z-index: 100; } -[dir='rtl'] .map-controls { +.ideditor[dir='rtl'] .map-controls { left: 0; right: auto; } @@ -2880,7 +2865,7 @@ div.full-screen > button:hover { .zoombuttons > button.zoom-in { border-radius: 4px 0 0 0; } -[dir='rtl'] .zoombuttons > button.zoom-in { +.ideditor[dir='rtl'] .zoombuttons > button.zoom-in { border-radius: 0 4px 0 0; } @@ -2891,7 +2876,7 @@ div.full-screen > button:hover { .geolocate-control > button { border-radius: 0 0 0 4px; } -[dir='rtl'] .geolocate-control > button { +.ideditor[dir='rtl'] .geolocate-control > button { border-radius: 0 0 4px 0; } @@ -2907,14 +2892,14 @@ div.full-screen > button:hover { .background-control > button { border-radius: 4px 0 0 0; } -[dir='rtl'] .background-control > button { +.ideditor[dir='rtl'] .background-control > button { border-radius: 0 4px 0 0; } .help-control > button { border-radius: 0 0 0 4px; } -[dir='rtl'] .help-control > button { +.ideditor[dir='rtl'] .help-control > button { border-radius: 0 0 4px 0; } @@ -2977,7 +2962,7 @@ div.full-screen > button:hover { flex: 0 0 auto; } -[dir='rtl'] .list-item-data-browse svg { +.ideditor[dir='rtl'] .list-item-data-browse svg { transform: rotateY(180deg); } @@ -2993,10 +2978,10 @@ div.full-screen > button:hover { flex: 1 1 auto; } -[dir='ltr'] .layer-list .indented label { +.ideditor[dir='ltr'] .layer-list .indented label { padding-left: 24px; } -[dir='rtl'] .layer-list .indented label { +.ideditor[dir='rtl'] .layer-list .indented label { padding-right: 24px; } @@ -3015,8 +3000,8 @@ div.full-screen > button:hover { padding-left: 4px; padding-right: 4px; } -[dir='rtl'] .map-data-pane .layer-list button, -[dir='rtl'] .background-pane .layer-list button { +.ideditor[dir='rtl'] .map-data-pane .layer-list button, +.ideditor[dir='rtl'] .background-pane .layer-list button { border-left: none; border-right: 1px solid #ccc; } @@ -3030,8 +3015,8 @@ div.full-screen > button:hover { .background-pane .layer-list button:last-of-type { border-radius: 0 3px 3px 0; } -[dir='rtl'] .map-data-pane .layer-list button:last-of-type, -[dir='rtl'] .background-pane .layer-list button:last-of-type { +.ideditor[dir='rtl'] .map-data-pane .layer-list button:last-of-type, +.ideditor[dir='rtl'] .background-pane .layer-list button:last-of-type { border-radius: 3px 0 0 3px; } @@ -3075,7 +3060,7 @@ div.full-screen > button:hover { border-left: 1px solid #ccc; background-color: rgba(0,0,0,0); } -[dir='rtl'] .issue-label .issue-info-button { +.ideditor[dir='rtl'] .issue-label .issue-info-button { border-left: 0; border-right: 1px solid #ccc; } @@ -3088,7 +3073,7 @@ div.full-screen > button:hover { .issue-label .issue-info-button:last-child { border-radius: 0 4px 4px 0; } -[dir='rtl'] .issue-label .issue-info-button:last-child { +.ideditor[dir='rtl'] .issue-label .issue-info-button:last-child { border-radius: 4px 0 0 4px; } @@ -3135,7 +3120,7 @@ button.autofix.action.active { .warnings-list .issue.severity-warning .issue-label, .issue.severity-warning .issue-fix-list, -.mode-save .warning-section { +.ideditor.mode-save .warning-section { background: #ffc; } @@ -3178,7 +3163,7 @@ button.autofix.action.active { .errors-list .issue.severity-error .issue-label, .issue.severity-error .issue-fix-list, -.mode-save .error-section { +.ideditor.mode-save .error-section { background: #ffd6d6; } @@ -3223,7 +3208,7 @@ button.autofix.action.active { font-weight: bold; padding-right: 10px; } -[dir='rtl'] .issues-option-title { +.ideditor[dir='rtl'] .issues-option-title { padding-right: 0; padding-left: 10px; } @@ -3287,7 +3272,7 @@ input.square-degrees-input { .section-entity-issues .issue .issue-label .issue-text { padding-right: 10px; } -[dir='rtl'] .section-entity-issues .issue .issue-label .issue-text { +.ideditor[dir='rtl'] .section-entity-issues .issue .issue-label .issue-text { padding-right: unset; padding-left: 10px; } @@ -3317,7 +3302,7 @@ input.square-degrees-input { li.issue-fix-item { padding: 2px 10px 2px 20px; } -[dir='rtl'] li.issue-fix-item { +.ideditor[dir='rtl'] li.issue-fix-item { padding: 2px 20px 2px 10px; } li.issue-fix-item:first-of-type { @@ -3407,7 +3392,7 @@ li.issue-fix-item:not(.actionable) .fix-icon { vertical-align: text-bottom; border-radius: 4px; } -[dir='rtl'] .display-control button { +.ideditor[dir='rtl'] .display-control button { margin-left: 0px; margin-right: 5px; } @@ -3587,7 +3572,7 @@ li.issue-fix-item:not(.actionable) .fix-icon { overflow-y: scroll; position: relative; } -[dir='rtl'] .pane-content { +.ideditor[dir='rtl'] .pane-content { padding: 10px 20px 20px 40px; } @@ -3788,7 +3773,7 @@ li.issue-fix-item:not(.actionable) .fix-icon { .inspector-hover .tag-row:first-child input.value { border-top-right-radius: 4px; } -[dir='rtl'] .inspector-hover .tag-row:first-child input.value { +.ideditor[dir='rtl'] .inspector-hover .tag-row:first-child input.value { border-top-right-radius: 0; border-top-left-radius: 4px; } @@ -3796,7 +3781,7 @@ li.issue-fix-item:not(.actionable) .fix-icon { .inspector-hover .tag-row:last-child input.value { border-bottom-right-radius: 4px; } -[dir='rtl'] .inspector-hover .tag-row:last-child input.value { +.ideditor[dir='rtl'] .inspector-hover .tag-row:last-child input.value { border-bottom-right-radius: 0; border-bottom-left-radius: 4px; } @@ -3804,7 +3789,7 @@ li.issue-fix-item:not(.actionable) .fix-icon { .inspector-hover .tag-row:last-child input.key { border-bottom-left-radius: 4px; } -[dir='rtl'] .inspector-hover .tag-row:last-child input.key { +.ideditor[dir='rtl'] .inspector-hover .tag-row:last-child input.key { border-bottom-left-radius: 0; border-bottom-right-radius: 4px; } @@ -3948,10 +3933,10 @@ img.tile-debug { border: #aaa 1px solid; box-shadow: 0 0 2em black; } -[dir='ltr'] .map-in-map { +.ideditor[dir='ltr'] .map-in-map { left: 10px; } -[dir='rtl'] .map-in-map { +.ideditor[dir='rtl'] .map-in-map { right: 10px; } @@ -4103,7 +4088,7 @@ img.tile-debug { background: none; color: #ddd; } -[dir='rtl'] .panel-title button.close { +.ideditor[dir='rtl'] .panel-title button.close { float: left; } @@ -4135,7 +4120,7 @@ img.tile-debug { margin-right: 10px; color: #fff; } -[dir='rtl'] .panel-content .button { +.ideditor[dir='rtl'] .panel-content .button { margin-right: auto; margin-left: 10px; } @@ -4143,7 +4128,7 @@ img.tile-debug { .panel-content-history .links a { margin-left: 8px; } -[dir='rtl'] .panel-content-history .links a { +.ideditor[dir='rtl'] .panel-content-history .links a { margin-left: auto; margin-right: 8px; } @@ -4314,7 +4299,7 @@ img.tile-debug { height: 30px; width: 100%; } -[dir='rtl'] .scale-block .scale { +.ideditor[dir='rtl'] .scale-block .scale { transform: scaleX(-1); } @@ -4328,7 +4313,7 @@ img.tile-debug { fill: #ccc; text-anchor: start; } -[dir='rtl'] .scale-block .scale text { +.ideditor[dir='rtl'] .scale-block .scale text { transform: scaleX(-1); } @@ -4352,7 +4337,7 @@ img.tile-debug { clear: right; overflow: hidden; } -[dir='rtl'] .map-footer-list { +.ideditor[dir='rtl'] .map-footer-list { text-align: left; clear: left; margin-left: 10px; @@ -4365,7 +4350,7 @@ img.tile-debug { padding: 5px 0 5px 5px; margin-left: 5px; } -[dir='rtl'] .map-footer-list li { +.ideditor[dir='rtl'] .map-footer-list li { float: left; border-left: none; border-right: 1px solid rgba(255,255,255,.5); @@ -4382,7 +4367,7 @@ img.tile-debug { margin-left: 0; padding-left: 0; } -[dir='rtl'] .map-footer-list li:last-child { +.ideditor[dir='rtl'] .map-footer-list li:last-child { border-right: none; } @@ -4396,12 +4381,12 @@ img.tile-debug { height: 14px; margin-top: 3px; } -[dir='ltr'] .map-footer-list a.chip .icon, -[dir='ltr'] .map-footer-list a.chip span { +.ideditor[dir='ltr'] .map-footer-list a.chip .icon, +.ideditor[dir='ltr'] .map-footer-list a.chip span { margin-right: 3px; } -[dir='rtl'] .map-footer-list a.chip .icon, -[dir='rtl'] .map-footer-list a.chip span { +.ideditor[dir='rtl'] .map-footer-list a.chip .icon, +.ideditor[dir='rtl'] .map-footer-list a.chip span { margin-left: 3px; } @@ -4420,10 +4405,10 @@ img.tile-debug { .issues-info a.chip.warnings-count { background: #DF8500; } -[dir='ltr'] .issues-info a.chip:not(:last-child) { +.ideditor[dir='ltr'] .issues-info a.chip:not(:last-child) { margin-right: 5px; } -[dir='rtl'] .issues-info a.chip:not(:last-child) { +.ideditor[dir='rtl'] .issues-info a.chip:not(:last-child) { margin-left: 5px; } @@ -4437,7 +4422,7 @@ img.tile-debug { color: #eee; flex: 1 1 auto; } -[dir='rtl'] .api-status { +.ideditor[dir='rtl'] .api-status { text-align: left; } @@ -4467,14 +4452,14 @@ img.tile-debug { border-radius: 11px; margin-left: 6px; } -[dir='rtl'] .badge { +.ideditor[dir='rtl'] .badge { margin-left: 0; margin-right: 6px; } .badge a { margin-right: 5px; } -[dir='rtl'] .badge a { +.ideditor[dir='rtl'] .badge a { margin-right: 0; margin-left: 5px; } @@ -4498,7 +4483,7 @@ img.tile-debug { background: #f00; border-radius: 9px; } -[dir='rtl'] .badge-text { +.ideditor[dir='rtl'] .badge-text { margin-left: 0; margin-right: 5px; } @@ -4799,7 +4784,7 @@ img.tile-debug { text-align: right; white-space: nowrap; } -[dir='rtl'] .modal-shortcuts .shortcut-keys { +.ideditor[dir='rtl'] .modal-shortcuts .shortcut-keys { text-align: left; } @@ -4844,19 +4829,19 @@ svg.mouseclick use.right { /* Save Mode ------------------------------------------------------- */ -.mode-save a.user-info { +.ideditor.mode-save a.user-info { display: inline-block; } -.mode-save .commit-form { +.ideditor.mode-save .commit-form { margin-bottom: 0; } -.mode-save .user-info img { +.ideditor.mode-save .user-info img { float: left; } -.mode-save h3 small.count { +.ideditor.mode-save h3 small.count { margin-right: 10px; text-align: center; float: left; @@ -4871,7 +4856,7 @@ svg.mouseclick use.right { } .note-save .field-warning, -.mode-save .field-warning { +.ideditor.mode-save .field-warning { background: #ffb; border: 1px solid #ccc; border-radius: 4px; @@ -4879,44 +4864,44 @@ svg.mouseclick use.right { } .note-save .field-warning:empty, -.mode-save .field-warning:empty { +.ideditor.mode-save .field-warning:empty { display: none; } -.mode-save .field-warning, -.mode-save .changeset-info, -.mode-save .request-review, -.mode-save .commit-info { +.ideditor.mode-save .field-warning, +.ideditor.mode-save .changeset-info, +.ideditor.mode-save .request-review, +.ideditor.mode-save .commit-info { margin-bottom: 10px; } -.mode-save .request-review label { +.ideditor.mode-save .request-review label { cursor: pointer; } -.mode-save .changeset-list { +.ideditor.mode-save .changeset-list { border: 1px solid #ccc; border-radius: 4px; background: #fff; margin-bottom: 10px; } -.mode-save .warning-section .changeset-list button { +.ideditor.mode-save .warning-section .changeset-list button { border-left: 1px solid #ccc; } -.mode-save .changeset-list li { +.ideditor.mode-save .changeset-list li { position: relative; border-top: 1px solid #ccc; padding: 5px 10px; cursor: pointer; } -.mode-save .changeset-list li:hover { +.ideditor.mode-save .changeset-list li:hover { background-color: #ececec; } -.mode-save .changeset-list .alert { +.ideditor.mode-save .changeset-list .alert { opacity: 0.5; } @@ -4944,7 +4929,7 @@ svg.mouseclick use.right { padding: 20px; } -.mode-save button.conflicts-button { +.ideditor.mode-save button.conflicts-button { float: left; } @@ -5011,7 +4996,7 @@ svg.mouseclick use.right { vertical-align: middle; margin-right: 10px; } -[dir='rtl'] .notice .zoom-to .icon { +.ideditor[dir='rtl'] .notice .zoom-to .icon { margin-left: 10px; margin-right: 0; } @@ -5198,7 +5183,7 @@ svg.mouseclick use.right { margin-left: 5px; } -[dir='rtl'] .popover-inner .shortcut { +.ideditor[dir='rtl'] .popover-inner .shortcut { margin-left: 0; margin-right: 5px; } @@ -5258,8 +5243,8 @@ li.hide + li.version .badge .tooltip { left: auto !important; right: 5px !important; } -[dir='rtl'] li:first-of-type .badge .tooltip, -[dir='rtl'] li.hide + li.version .badge .tooltip { +.ideditor[dir='rtl'] li:first-of-type .badge .tooltip, +.ideditor[dir='rtl'] li.hide + li.version .badge .tooltip { left: 5px !important; right: auto !important; } @@ -5268,8 +5253,8 @@ li.hide + li.version .badge .tooltip .popover-arrow { right: 15px !important; left: auto !important; } -[dir='rtl'] li:first-of-type .badge .tooltip .popover-arrow, -[dir='rtl'] li.hide + li.version .badge .tooltip .popover-arrow { +.ideditor[dir='rtl'] li:first-of-type .badge .tooltip .popover-arrow, +.ideditor[dir='rtl'] li.hide + li.version .badge .tooltip .popover-arrow { left: 15px !important; right: auto !important; } @@ -5423,7 +5408,7 @@ li.hide + li.version .badge .tooltip .popover-arrow { .curtain-tooltip.tooltip { text-align: left; } -[dir='rtl'] .curtain-tooltip.tooltip { +.ideditor[dir='rtl'] .curtain-tooltip.tooltip { text-align: right; } @@ -5472,7 +5457,7 @@ li.hide + li.version .badge .tooltip .popover-arrow { margin-left: -20px; margin-top: -10px; } -[dir='rtl'] .tooltip-illustration { +.ideditor[dir='rtl'] .tooltip-illustration { margin-left: auto; margin-right: -20px; } @@ -5523,6 +5508,6 @@ li.hide + li.version .badge .tooltip .popover-arrow { float: right; margin-top: -20px; } -[dir='rtl'] .list-item-photos.list-item-mapillary-map-features .request-data-link { +.ideditor[dir='rtl'] .list-item-photos.list-item-mapillary-map-features .request-data-link { float: left; } diff --git a/dist/index.html b/dist/index.html index 5deefeb0b..1680ffa75 100644 --- a/dist/index.html +++ b/dist/index.html @@ -6,8 +6,17 @@ - - + + +
@@ -30,7 +39,7 @@ function checkScript() { if (typeof iD === 'undefined' || !iD.utilDetect().support) { container.innerHTML = 'Sorry, your browser is not currently supported. Please use Potlatch 2 to edit the map.'; - container.className = 'unsupported'; + container.style.padding = '20px'; } else { var context = iD.coreContext(); diff --git a/index.html b/index.html index 0149a0823..cd699edc2 100644 --- a/index.html +++ b/index.html @@ -8,6 +8,15 @@ + @@ -29,7 +38,7 @@ function checkScript() { if (typeof iD === 'undefined' || !iD.utilDetect().support) { container.innerHTML = 'Sorry, your browser is not currently supported. Please use Potlatch 2 to edit the map.'; - container.className = 'unsupported'; + container.style.padding = '20px'; } else { var context = iD.coreContext().assetPath('dist/'); diff --git a/modules/core/context.js b/modules/core/context.js index cb23665b0..e8d85eddd 100644 --- a/modules/core/context.js +++ b/modules/core/context.js @@ -363,7 +363,7 @@ export function coreContext() { context.container = function(val) { if (!arguments.length) return _container; _container = val; - _container.classed('id-container', true); + _container.classed('ideditor', true); return context; }; let _embed; diff --git a/modules/ui/edit_menu.js b/modules/ui/edit_menu.js index d1b271b98..f39966acd 100644 --- a/modules/ui/edit_menu.js +++ b/modules/ui/edit_menu.js @@ -106,7 +106,7 @@ export function uiEditMenu(context, operations) { .classed('disabled', function(d) { return d.disabled(); }); - tooltip = d3_select('#id-container') + tooltip = d3_select('.ideditor') .append('div') .attr('class', 'popover tooltip edit-menu-tooltip'); diff --git a/modules/ui/intro/area.js b/modules/ui/intro/area.js index f381852e9..6c56072a3 100644 --- a/modules/ui/intro/area.js +++ b/modules/ui/intro/area.js @@ -470,11 +470,11 @@ export function uiIntroArea(context, reveal) { function play() { dispatch.call('done'); - reveal('#id-container', + reveal('.ideditor', t('intro.areas.play', { next: t('intro.lines.title') }), { tooltipBox: '.intro-nav-wrap .chapter-line', buttonText: t('intro.ok'), - buttonCallback: function() { reveal('#id-container'); } + buttonCallback: function() { reveal('.ideditor'); } } ); } diff --git a/modules/ui/intro/building.js b/modules/ui/intro/building.js index 86e55333b..c80f5caa4 100644 --- a/modules/ui/intro/building.js +++ b/modules/ui/intro/building.js @@ -757,11 +757,11 @@ export function uiIntroBuilding(context, reveal) { function play() { dispatch.call('done'); - reveal('#id-container', + reveal('.ideditor', t('intro.buildings.play', { next: t('intro.startediting.title') }), { tooltipBox: '.intro-nav-wrap .chapter-startEditing', buttonText: t('intro.ok'), - buttonCallback: function() { reveal('#id-container'); } + buttonCallback: function() { reveal('.ideditor'); } } ); } diff --git a/modules/ui/intro/line.js b/modules/ui/intro/line.js index d46340fdf..08b8b84cc 100644 --- a/modules/ui/intro/line.js +++ b/modules/ui/intro/line.js @@ -1036,11 +1036,11 @@ export function uiIntroLine(context, reveal) { function play() { dispatch.call('done'); - reveal('#id-container', + reveal('.ideditor', t('intro.lines.play', { next: t('intro.buildings.title') }), { tooltipBox: '.intro-nav-wrap .chapter-building', buttonText: t('intro.ok'), - buttonCallback: function() { reveal('#id-container'); } + buttonCallback: function() { reveal('.ideditor'); } } ); } diff --git a/modules/ui/intro/navigation.js b/modules/ui/intro/navigation.js index dcf72cc1f..cd7ebbaea 100644 --- a/modules/ui/intro/navigation.js +++ b/modules/ui/intro/navigation.js @@ -530,11 +530,11 @@ export function uiIntroNavigation(context, reveal) { function play() { dispatch.call('done'); - reveal('#id-container', + reveal('.ideditor', t('intro.navigation.play', { next: t('intro.points.title') }), { tooltipBox: '.intro-nav-wrap .chapter-point', buttonText: t('intro.ok'), - buttonCallback: function() { reveal('#id-container'); } + buttonCallback: function() { reveal('.ideditor'); } } ); } diff --git a/modules/ui/intro/point.js b/modules/ui/intro/point.js index d1ba5f317..741235d7e 100644 --- a/modules/ui/intro/point.js +++ b/modules/ui/intro/point.js @@ -476,11 +476,11 @@ export function uiIntroPoint(context, reveal) { function play() { dispatch.call('done'); - reveal('#id-container', + reveal('.ideditor', t('intro.points.play', { next: t('intro.areas.title') }), { tooltipBox: '.intro-nav-wrap .chapter-area', buttonText: t('intro.ok'), - buttonCallback: function() { reveal('#id-container'); } + buttonCallback: function() { reveal('.ideditor'); } } ); } diff --git a/package.json b/package.json index 704001eb2..7aad9909d 100644 --- a/package.json +++ b/package.json @@ -97,6 +97,8 @@ "object-inspect": "0.4.0", "osm-community-index": "2.0.0", "phantomjs-prebuilt": "~2.1.11", + "postcss": "^7.0.27", + "postcss-selector-prepend": "^0.5.0", "request": "^2.88.0", "rollup": "~1.31.1", "rollup-plugin-includepaths": "~0.2.3", diff --git a/scripts/build_css.js b/scripts/build_css.js index ddb2a6a28..44aae89b5 100644 --- a/scripts/build_css.js +++ b/scripts/build_css.js @@ -2,6 +2,9 @@ const colors = require('colors/safe'); const concat = require('concat-files'); const glob = require('glob'); +const fs = require('fs'); +const postcss = require('postcss'); +const prepend = require('postcss-selector-prepend'); let _currBuild = null; @@ -27,6 +30,12 @@ function buildCSS() { Promise.resolve() .then(() => doGlob('css/**/*.css')) .then(files => doConcat(files, 'dist/iD.css')) + .then(() => { + const css = fs.readFileSync('dist/iD.css', 'utf8'); + return postcss([prepend({ selector: '.ideditor ' })]) + .process(css, { from: 'dist/iD.css', to: 'dist/iD.css' }); + }) + .then(result => fs.writeFileSync('dist/iD.css', result.css)) .then(() => { console.timeEnd(END); console.log(''); @@ -58,4 +67,3 @@ function doConcat(files, output) { }); }); } - diff --git a/test/spec/ui/combobox.js b/test/spec/ui/combobox.js index e054c7c22..e8aa820e0 100644 --- a/test/spec/ui/combobox.js +++ b/test/spec/ui/combobox.js @@ -65,7 +65,7 @@ describe('uiCombobox', function() { beforeEach(function() { body = d3.select('body'); - container = body.append('div').attr('class', 'id-container'); + container = body.append('div').attr('class', 'ideditor'); context = iD.coreContext().container(container).init(); content = container.append('div'); input = content.append('input'); @@ -92,7 +92,7 @@ describe('uiCombobox', function() { input.call(combobox.data(data)); focusTypeahead(input); simulateKeypress('↓'); - expect(d3.select('.id-container > div.combobox').nodes().length).to.equal(1); + expect(d3.select('.ideditor > div.combobox').nodes().length).to.equal(1); }); it('filters entries to those matching the value', function() {