custom changes
This commit is contained in:
@ -134,6 +134,9 @@ export class Handler {
|
||||
rightPriceScale: {
|
||||
scaleMargins: {top: 0.3, bottom: 0.25},
|
||||
},
|
||||
leftPriceScale: {
|
||||
visible:true,
|
||||
scaleMargins:{top:.3,bottom:.25}},
|
||||
timeScale: {timeVisible: true, secondsVisible: false},
|
||||
crosshair: {
|
||||
mode: CrosshairMode.Normal,
|
||||
|
||||
@ -63,7 +63,7 @@ export class Legend {
|
||||
// }
|
||||
|
||||
makeSeriesRow(name: string, series: ISeriesApi<SeriesType>) {
|
||||
const strokeColor = '#FFF';
|
||||
const strokeColor = series.options().color;
|
||||
let openEye = `
|
||||
<path style="fill:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke:${strokeColor};stroke-opacity:1;stroke-miterlimit:4;" d="M 21.998437 12 C 21.998437 12 18.998437 18 12 18 C 5.001562 18 2.001562 12 2.001562 12 C 2.001562 12 5.001562 6 12 6 C 18.998437 6 21.998437 12 21.998437 12 Z M 21.998437 12 " transform="matrix(0.833333,0,0,0.833333,0,0)"/>
|
||||
<path style="fill:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke:${strokeColor};stroke-opacity:1;stroke-miterlimit:4;" d="M 15 12 C 15 13.654687 13.654687 15 12 15 C 10.345312 15 9 13.654687 9 12 C 9 10.345312 10.345312 9 12 9 C 13.654687 9 15 10.345312 15 12 Z M 15 12 " transform="matrix(0.833333,0,0,0.833333,0,0)"/>\`
|
||||
@ -110,7 +110,7 @@ export class Legend {
|
||||
row.appendChild(toggle)
|
||||
this.div.appendChild(row)
|
||||
|
||||
const color = series.options().baseLineColor;
|
||||
const color = series.options().color;
|
||||
this._lines.push({
|
||||
name: name,
|
||||
div: div,
|
||||
@ -217,7 +217,7 @@ export class Legend {
|
||||
const format = e.series.options().priceFormat as PriceFormatBuiltIn
|
||||
price = this.legendItemFormat(data.value, format.precision) // couldn't this just be line.options().precision?
|
||||
}
|
||||
e.div.innerHTML = `<span style="color: ${e.solid};">▨</span> ${e.name} : ${price}`
|
||||
e.div.innerHTML = `<span style="color: ${e.solid};">▨ ${e.name} : ${price}</span>`
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user