Skip to content

Commit

Permalink
Merge pull request #63 from boldtrn/update_style
Browse files Browse the repository at this point in the history
Updated the style
  • Loading branch information
Timothy Ellersiek committed Jul 17, 2019
2 parents 90e4572 + 27f58f1 commit e0546f8
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 7 deletions.
11 changes: 6 additions & 5 deletions src/L.Control.Heightgraph.css
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
.heightgraph-container {
background-color: #FFF;
background-color: rgba(250,250,250,.8);
border-radius: 10px;
display: none;
cursor: default;
Expand Down Expand Up @@ -36,8 +36,6 @@
}

.border-top {
stroke-width: 1;
stroke: #999;
fill: none;
}

Expand All @@ -52,7 +50,7 @@
}

.tick, .tick text {
fill: #999;
fill: #000;
pointer-events: none;
}

Expand All @@ -66,7 +64,6 @@
fill: none;
stroke-width: 2px;
shape-rendering: crispEdges;
stroke: lightgrey;
pointer-events: none;
}

Expand Down Expand Up @@ -115,6 +112,10 @@
stroke-width: 1px;
}

.mouse-height-box-text{
font-size: 12px;
}

.grid .tick {
pointer-events: none;
}
Expand Down
5 changes: 3 additions & 2 deletions src/L.Control.Heightgraph.js
Original file line number Diff line number Diff line change
Expand Up @@ -406,11 +406,11 @@ L.Control.Heightgraph = L.Control.extend({
this._mouseHeightFocusLabelTextElev.attr("x", layerpoint.x + 5)
.attr("y", normalizedY + 12)
.text(height + " m")
.attr("class", "tspan");
.attr("class", "tspan mouse-height-box-text");
this._mouseHeightFocusLabelTextType.attr("x", layerpoint.x + 5)
.attr("y", normalizedY + 24)
.text(type)
.attr("class", "tspan");
.attr("class", "tspan mouse-height-box-text");
var maxWidth = this._dynamicBoxSize('text.tspan')[1];
// box size should change for profile none (no type)
var maxHeight = (type === "") ? 12 + 6 : 2 * 12 + 6;
Expand Down Expand Up @@ -693,6 +693,7 @@ L.Control.Heightgraph = L.Control.extend({
.attr('class', 'x axis')
.call(this._xAxis);
this._svg.append('g')
.attr("transform", "translate(-2,0)")
.attr('class', 'y axis')
.call(this._yAxis);
},
Expand Down

0 comments on commit e0546f8

Please sign in to comment.