Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 9 additions & 1 deletion packages/chart/src/Gauge.ts
Original file line number Diff line number Diff line change
Expand Up @@ -290,7 +290,7 @@ export class Gauge extends SVGWidget {
;

this._bottomText
.style("fill", this.click !== Gauge.prototype.click ? "blue" : "black")
.style("fill", this.click !== Gauge.prototype.click ? this.titleClickColor() : this.titleColor())
.style("text-decoration", this.click !== Gauge.prototype.click ? "underline" : null)
.text(this.title())
;
Expand Down Expand Up @@ -319,6 +319,11 @@ export interface Gauge {
title(_: string): this;
titleDescription(): string;
titleDescription(_: string): this;
titleColor(): string;
titleColor(_: string): this;
titleClickColor(): string;
titleClickColor(_: string): this;

maxDiameter(): number;
maxDiameter(_: number): this;
value(): number;
Expand Down Expand Up @@ -346,6 +351,9 @@ export interface Gauge {

Gauge.prototype.publish("title", "", "string", "Title");
Gauge.prototype.publish("titleDescription", "", "string", "Title Description");
Gauge.prototype.publish("titleColor", "black", "html-color", "Color of the title text");
Gauge.prototype.publish("titleClickColor", "blue", "html-color", "Color of the title text when clickable");

Gauge.prototype.publish("maxDiameter", 128, "number", "Max Diameter");
Gauge.prototype.publish("value", 0, "number", "Value");
Gauge.prototype.publish("valueDescription", "", "string", "Value Description");
Expand Down