In the branch graph, uploaded images where not rendered
correctly. Fixed this by not filling the rect, instead
i've put an image over it
This commit is contained in:
Jeroen van Baarsen 2014-01-13 22:21:25 +01:00
parent 55024ed13a
commit d5bb466fe4

View file

@ -194,11 +194,14 @@ class BranchGraph
fill: @colors[commit.space]
stroke: "none"
)
r.rect(@offsetX + @unitSpace * @mspace + 10, y - 10, 20, 20).attr(
fill: "url(#{commit.author.icon})"
avatar_box_x = @offsetX + @unitSpace * @mspace + 10
avatar_box_y = y - 10
r.rect(avatar_box_x, avatar_box_y, 20, 20).attr(
stroke: @colors[commit.space]
"stroke-width": 2
)
r.image(commit.author.icon, avatar_box_x, avatar_box_y, 20, 20)
r.text(@offsetX + @unitSpace * @mspace + 35, y, commit.message.split("\n")[0]).attr(
"text-anchor": "start"
font: "14px Monaco, monospace"