Skip to content

feature_request: Graphs with color band range #1190

@mzakharo

Description

@mzakharo

I use mini-graph-card to maintain chemical levels of my Hot Tub. I need to maintain the chemical levels within a certain range:
image

There is certainly a better way of doing it, but I managed to get this working by modifying graph.js with the following code:

  getFill(path) {
    let fill = path;
    fill = '';
    fill += 'M0,0';
    fill += ` ${this.width},${this.margin[Y]}`;
    fill += ` ${this.width},${this.height}`;
    fill += ` L 0, ${this.height} z`;
    return fill;
  }

Could support for this type of graph be added to the master repository?

Metadata

Metadata

Assignees

No one assigned

    Labels

    questionFurther information is requested

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions