Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

x.axis.max with date don't work anymore #1981

Closed
pvictor opened this issue Mar 12, 2021 · 1 comment
Closed

x.axis.max with date don't work anymore #1981

pvictor opened this issue Mar 12, 2021 · 1 comment
Assignees
Labels

Comments

@pvictor
Copy link

pvictor commented Mar 12, 2021

Description

When using x.axis.max with a date for a timeserie chart an error occurs.
It worked with older versions (< 2.0.0)

Steps to check or reproduce

With latest version, if you uncomment max option it breaks : https://codepen.io/pvictor-r/pen/ExNGebL

With 1.12.11 it works: https://codepen.io/pvictor-r/pen/GRNzppO

Code to reproduce:

var chart = bb.generate({
  data: {
    x: "x",
    columns: [
      ["x", "2013-01-01", "2013-01-02", "2013-01-03", "2013-01-04", "2013-01-05", "2013-01-06"],
      ["data1", 30, 200, 100, 400, 150, 250],
      ["data2", 130, 340, 200, 500, 250, 350]
    ],
    type: "line", 
  },
  axis: {
    x: {
      max: "2013-01-04", // <- generate an error
      type: "timeseries",
      tick: {
        format: "%Y-%m-%d"
      }
    }
  },
  bindto: "#timeseriesChart"
});

Thanks!

Victor

@netil netil added the bug label Mar 15, 2021
@netil netil self-assigned this Mar 15, 2021
@netil
Copy link
Member

netil commented Mar 15, 2021

Hi @pvictor, confirmed the issue.
Thanks for the report.

netil added a commit to netil/billboard.js that referenced this issue Mar 15, 2021
Bind the context correctly when 'parseDate' is called
within .getXDomainMinMax()

Ref naver#1981
@netil netil closed this as completed in de06361 Mar 15, 2021
github-actions bot pushed a commit that referenced this issue Mar 19, 2021
# [3.0.0-next.3](3.0.0-next.2...3.0.0-next.3) (2021-03-19)

### Bug Fixes

* **axis:** fix axis.x.max error throw ([de06361](de06361)), closes [#1981](#1981)
* **axis:** fix axis.x.tick.tooltip on rotated axis ([eed2f86](eed2f86)), closes [#1990](#1990)
* **axis:** remove x axis transition during resize ([a938681](a938681)), closes [#1949](#1949)
* **tooltip:** fix linked tooltip recursive call ([b6af8ec](b6af8ec)), closes [#1979](#1979)
* **zoom:** fix zoom on latest chrome ([37edc9b](37edc9b)), closes [/github.com/d3/d3-zoom/issues/231#issuecomment-802305692](https://github.com//github.com/d3/d3-zoom/issues/231/issues/issuecomment-802305692) [#1992](#1992)

### Features

* **api:** Enhance .export() option to specify size ([3c2de80](3c2de80)), closes [#815](#815) [#1969](#1969)
github-actions bot pushed a commit that referenced this issue Mar 26, 2021
# [3.0.0](2.2.6...3.0.0) (2021-03-26)

### Bug Fixes

* **axis:** fix axis.x.max error throw ([de06361](de06361)), closes [#1981](#1981)
* **axis:** fix axis.x.tick.tooltip on rotated axis ([eed2f86](eed2f86)), closes [#1990](#1990)
* **subchart:** fix duplicated node generation on data load ([d9a5d9a](d9a5d9a)), closes [#2003](#2003)
* **zoom:** fix zoom on latest chrome ([37edc9b](37edc9b)), closes [/github.com/d3/d3-zoom/issues/231#issuecomment-802305692](https://github.com//github.com/d3/d3-zoom/issues/231/issues/issuecomment-802305692) [#1992](#1992)

### Features

* **all:** update for d3 v6 ([2752e55](2752e55)), closes [#1641](#1641)
* **api:** Enhance .export() option to specify size ([3c2de80](3c2de80)), closes [#815](#815) [#1969](#1969)
* **api:** Intent to ship subchart APIs ([5572dc9](5572dc9)), closes [#1993](#1993)
* **candlestick:** Intent to ship candlestick ([8d37bd8](8d37bd8)), closes [#76](#76) [#1167](#1167)
* **candlestick:** Intent to ship candlestick type ([42307cb](42307cb))

### BREAKING CHANGES

* **all:** - Update to work on d3 v6
- Added getPoint() to get event's position coordinate

https://github.com/d3/d3/blob/master/CHANGES.md
https://observablehq.com/d/f91cccf0cad5e9cb
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants