Hide mapillary-js attribution and just handle it in iD

(closes #4526)

What we were doing before was d3.selecting the attribution line and
inserting the capture date into it. This was confusing the viewer
(which updates asynchronously) so that the sitelink would never update.
To make things easier, we'll just hide the viewer's built in attribution
and construct the attribution line the way we want it.
This commit is contained in:
Bryan Housel
2017-11-14 11:32:42 -05:00
parent 8cb930a8ce
commit 1dd437a1f2
4 changed files with 83 additions and 56 deletions
+30 -30
View File
@@ -24,25 +24,35 @@
overflow: hidden;
}
.photo-wrapper .photo-attribution {
width: 100%;
font-size: 10px;
text-align: right;
position: absolute;
bottom: 0;
right: 0;
padding: 4px 2px;
z-index: 10;
}
.photo-attribution a,
.photo-attribution a:visited,
.photo-attribution span {
padding: 4px 2px;
color: #fff;
}
/* markers and sequences */
.viewfield-group {
pointer-events: visible;
cursor: pointer;
}
.viewfield-group * {
z-index: 50;
}
.viewfield-group.selected * {
fill: #ffee00 !important;
z-index: 60;
}
.viewfield-group.hovered * {
fill: #eebb00 !important;
z-index: 70;
}
.viewfield-group.highlighted * {
z-index: 60;
}
.viewfield-group circle {
@@ -162,11 +172,18 @@
top: -25px;
}
#mly .domRenderer .Attribution {
width: 100%;
font-size: 10px;
text-align: right;
/* we will roll our own to avoid async update issues like #4526 */
display: none;
}
.mly-wrapper .photo-attribution a:active,
.mly-wrapper .photo-attribution a:hover {
color: #35af6d;
}
.mly-wrapper .mapillary-js-dom {
z-index: 9;
}
/* OpenStreetCam viewer */
.osc-wrapper {
@@ -177,25 +194,8 @@
background-repeat: no-repeat;
}
.osc-wrapper .osc-attribution {
width: 100%;
font-size: 10px;
text-align: right;
position: absolute;
bottom: 0;
right: 0;
padding: 4px 2px;
z-index: 10;
}
.osc-attribution a,
.osc-attribution a:visited,
.osc-attribution span {
padding: 4px 2px;
color: #fff;
}
.osc-attribution a:active,
.osc-attribution a:hover {
.osc-wrapper .photo-attribution a:active,
.osc-wrapper .photo-attribution a:hover {
color: #77ddff;
}