mirror of
https://github.com/FoggedLens/iD.git
synced 2026-02-13 09:12:52 +00:00
Make sure icon fill colors can be overridden
This commit is contained in:
@@ -409,6 +409,10 @@ button[disabled].action:hover {
|
|||||||
border-radius: 3px;
|
border-radius: 3px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.icon-annotation {
|
||||||
|
color: #333;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
/* Toolbar / Persistent UI Elements
|
/* Toolbar / Persistent UI Elements
|
||||||
------------------------------------------------------- */
|
------------------------------------------------------- */
|
||||||
|
|||||||
@@ -199,6 +199,10 @@ export function svgDefs(context) {
|
|||||||
node.appendChild(
|
node.appendChild(
|
||||||
d3_select(svg.documentElement).attr('id', d).node()
|
d3_select(svg.documentElement).attr('id', d).node()
|
||||||
);
|
);
|
||||||
|
if (d !== 'iD-sprite') { // allow icon colors to be overridden..
|
||||||
|
d3_select(node).selectAll('path')
|
||||||
|
.attr('fill', 'currentColor');
|
||||||
|
}
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -143,7 +143,7 @@ export function svgImproveOSM(projection, context, dispatch) {
|
|||||||
markersEnter
|
markersEnter
|
||||||
.append('use')
|
.append('use')
|
||||||
.attr('transform', 'translate(-5.5, -21)')
|
.attr('transform', 'translate(-5.5, -21)')
|
||||||
.attr('class', 'icon')
|
.attr('class', 'icon-annotation')
|
||||||
.attr('width', '11px')
|
.attr('width', '11px')
|
||||||
.attr('height', '11px')
|
.attr('height', '11px')
|
||||||
.attr('xlink:href', function(d) {
|
.attr('xlink:href', function(d) {
|
||||||
@@ -194,8 +194,6 @@ export function svgImproveOSM(projection, context, dispatch) {
|
|||||||
function sortY(a, b) {
|
function sortY(a, b) {
|
||||||
return (a.id === selectedID) ? 1
|
return (a.id === selectedID) ? 1
|
||||||
: (b.id === selectedID) ? -1
|
: (b.id === selectedID) ? -1
|
||||||
: (a.severity === 'error' && b.severity !== 'error') ? 1
|
|
||||||
: (b.severity === 'error' && a.severity !== 'error') ? -1
|
|
||||||
: b.loc[1] - a.loc[1];
|
: b.loc[1] - a.loc[1];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -143,11 +143,11 @@ export function svgNotes(projection, context, dispatch) {
|
|||||||
.attr('y', '-22px')
|
.attr('y', '-22px')
|
||||||
.attr('xlink:href', '#iD-icon-note');
|
.attr('xlink:href', '#iD-icon-note');
|
||||||
|
|
||||||
notesEnter.selectAll('.note-annotation')
|
notesEnter.selectAll('.icon-annotation')
|
||||||
.data(function(d) { return [d]; })
|
.data(function(d) { return [d]; })
|
||||||
.enter()
|
.enter()
|
||||||
.append('use')
|
.append('use')
|
||||||
.attr('class', 'note-annotation')
|
.attr('class', 'icon-annotation')
|
||||||
.attr('width', '10px')
|
.attr('width', '10px')
|
||||||
.attr('height', '10px')
|
.attr('height', '10px')
|
||||||
.attr('x', '-3px')
|
.attr('x', '-3px')
|
||||||
|
|||||||
@@ -57,6 +57,7 @@ export function uiImproveOsmHeader() {
|
|||||||
|
|
||||||
svgEnter
|
svgEnter
|
||||||
.append('use')
|
.append('use')
|
||||||
|
.attr('class', 'icon-annotation')
|
||||||
.attr('width', '11px')
|
.attr('width', '11px')
|
||||||
.attr('height', '11px')
|
.attr('height', '11px')
|
||||||
.attr('transform', 'translate(4.5, 7)')
|
.attr('transform', 'translate(4.5, 7)')
|
||||||
|
|||||||
@@ -35,7 +35,7 @@ export function uiNoteHeader() {
|
|||||||
iconEnter
|
iconEnter
|
||||||
.append('div')
|
.append('div')
|
||||||
.attr('class', 'note-icon-annotation')
|
.attr('class', 'note-icon-annotation')
|
||||||
.call(svgIcon(statusIcon, 'note-annotation'));
|
.call(svgIcon(statusIcon, 'icon-annotation'));
|
||||||
});
|
});
|
||||||
|
|
||||||
headerEnter
|
headerEnter
|
||||||
|
|||||||
Reference in New Issue
Block a user