Commit 730d5cc6 authored by Raphael Müller's avatar Raphael Müller
Browse files

added prop for axis color

parent 6f2308b8
......@@ -11,13 +11,13 @@ Vue.component( "axis", {
template:
`
<svg :x="x" :y="y" :width="width" :height="height" ><!--:viewBox="xOffset +' '+ vOffset +' '+ width + xOffset +' '+ vOffset + height"><!-- -->
<line x1="0" :y1="2*vOffset" :x2="width" :y2="2*vOffset" style="stroke:#888;stroke-width:2" />
<line x1="0" :y1="2*vOffset" :x2="width" :y2="2*vOffset" style="stroke:this.color;stroke-width:2" />
<line x1="0" :y1="2*vOffset" x2="0" :y2="vOffset" stroke="#888" />
<line :x1="width" :y1="2*vOffset" :x2="width" :y2="vOffset" stroke="#888" />
<line x1="0" :y1="2*vOffset" x2="0" :y2="vOffset" stroke="this.color" />
<line :x1="width" :y1="2*vOffset" :x2="width" :y2="vOffset" stroke="this.color" />
<line v-for="tick in ticks" :x1="tick.panelPos" :y1="2*vOffset" :x2="tick.panelPos" :y2="vOffset+2" stroke="#888"/>
<text v-for="tick in ticks" :style="'font: '+vOffset+'px roboto;'"class="small" :x="tick.panelPos" :y="vOffset" text-anchor="middle" fill="#888">{{ tick.genomePos }}</text>
<line v-for="tick in ticks" :x1="tick.panelPos" :y1="2*vOffset" :x2="tick.panelPos" :y2="vOffset+2" stroke="this.color"/>
<text v-for="tick in ticks" :style="'font: '+vOffset+'px roboto;'"class="small" :x="tick.panelPos" :y="vOffset" text-anchor="middle" fill="this.color">{{ tick.genomePos }}</text>
</svg>
<!-- -->
`,
......@@ -31,6 +31,9 @@ Vue.component( "axis", {
height: Number,
xOffset: Number,
vOffset: Number,
color: {
default: "#888"
}
},
methods: {
genomeToPixel( pos ) {
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment